Code review comment for lp:~mzanetti/unity8/fix-focus-on-app-launch

Revision history for this message
Daniel d'Andrada (dandrader) wrote :

On 04/04/2017 13:37, Michael Zanetti wrote:
>> """
>> root.focus = false;
>> """
>>
>> This looks redundant. I think code should be caring about whom to give focus
>> to, not in explicitly unfocusing the item that's losing it as this is the
>> side-effect of focusing someone else anyway. Is that really needed?
> yes... I just moved it a bit from where it was before... currently the launcher works in a way that when it is closed it unfocuses itself and in shell we have:
>
> Launcher { onFocusChanged: if (!focus) stage.focus = true }
>
> so that's kinda ok for here... I do certainly agree that in general this needs to be consolidated in a way eventually.

Maybe something like this would be a step in the right direction:

Launcher { onClosed: stage.focus = true }

« Back to merge proposal