ubuntu-phone team mailing list archive
-
ubuntu-phone team
-
Mailing list archive
-
Message #15817
Re: Detecting Touch apps and X-Ubuntu-Touch
On Mon, Sep 28, 2015 at 8:09 PM, Michael Terry
<michael.terry@xxxxxxxxxxxxx> wrote:
> For the pocket desktop feature, we want to be able to distinguish between
> native Touch apps and non-Touch apps, in order to be able to apply different
> lifecycle policies to them.
>
> For example, LibreOffice does not automatically save its state when it loses
> focus, as a good Touch app would. So we'd like to warn the user when
> exiting pocket desktop mode that they should go save their work.
>
> Now, whether an app was built for Touch is kind of hard to detect in theory.
> Whether it talks the Mir protocol isn't sufficient (could be a GTK app with
> the Mir backend). Whether it is a click package isn't sufficient (some
> Touch apps like System Settings are debs). At least if it is an Xmir app
> instance, we know (those are all non-Touch).
>
> Ideally, we'd have a metadata flag that indicates whether the app is
> designed for Touch and thus opts-into Touch lifecycle handling (or opts-out,
> depending on the default).
>
One remark: We have to make sure that apps cannot easily use the flag
(at least not without a manual reveiw). Otherwise, we would
open the door for apps escaping our strict lifecycle.
> Thankfully, we already have a flag that looks like it might fit. The
> desktop file flag X-Ubuntu-Touch=true is already used in unity-scope-click
> to (partly) determine which apps are shown in the App scope [1]. (Is it
> used anywhere else?)
>
> Is that flag suitable for repurposing to this use case? Any objections if I
> use that to determine whether an app was written for Touch or not?
>
In general: yes. I would like to see the proposal refined for my
remark before, though.
Thanks,
Thomas
> (We might then need to do something to make sure that LibreOffice also shows
> up in the App scope *without* setting the above flag. But that's
> manageable.)
>
> [1]
> http://bazaar.launchpad.net/~ubuntuone-control-tower/unity-scope-click/trunk/view/head:/libclickscope/click/interface.cpp#L274
>
> --
> -mt
>
> --
> Mailing list: https://launchpad.net/~ubuntu-phone
> Post to : ubuntu-phone@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~ubuntu-phone
> More help : https://help.launchpad.net/ListHelp
>
Follow ups
References