← Back to team overview

ubuntu-sdk-bugs team mailing list archive

[Bug 1499845] Re: Expose whether an app has a visible BottomEdge

 

It is way easier to detect on an app whether it is the first run or not
than on shell. Shell would need to keep track about each app on how many
times it has been launched, and that is just not its task.

I mentioned Tutorial component simply because I do see this whole logic being tracked by it:
- is this the first launch
- show the required information over a given point with a given animation full screen

I definitely see this should be all on the app's hand and not on the
system. Apps know whether they have bottom edge and they should handle
the tutorial. No reason to do extra communication and slow the UI
interaction with that even more than we have to. Toolkit can provide the
building blocks to get this handled without extra burden for the apps.

** Changed in: ubuntu-ui-toolkit (Ubuntu)
       Status: New => Opinion

** Changed in: ubuntu-ui-toolkit (Ubuntu)
   Importance: Undecided => Wishlist

-- 
You received this bug notification because you are a member of Ubuntu
SDK bug tracking, which is subscribed to ubuntu-ui-toolkit in Ubuntu.
https://bugs.launchpad.net/bugs/1499845

Title:
  Expose whether an app has a visible BottomEdge

Status in ubuntu-ui-toolkit package in Ubuntu:
  Opinion

Bug description:
  == The Design ==

  The edge tutorial that is shown during the first-boot is getting a
  redesign [1].

  As part of it, the bottom edge tutorial screen is intended to only
  appear after a certain amount of time and only if a user is opening or
  switching to an app with a bottom edge to drag up.

  When that happens, a page appears covering the whole screen, pointing
  to the bottom and saying "Swipe from the bottom edge to manage the
  app".  Then when the user does swipe up, it fades out as the bottom is
  swiped.   I've attached a screenshot of an early mockup for this (back
  when it was designed for the App scope, not an actual app).

  Since it must cover the entire screen (and turn off the launcher and
  panel during it), it should probably be rendered by the shell (which
  is rendering the rest of the tutorial anyway).  So we have to
  coordinate between the app and the shell.

  There are two main technical difficulties in implementing this, the
  way I see it.  Detecting if the current page has a valid BottomEdge
  and synchronizing the fade-out with the bottom-edge drag.

  [1] https://docs.google.com/document/d/1pZ-Ro--
  2eaRzjZKNRoYAeDvQHMkCuyvVuPFWFQfPW4s

  == Detecting BottomEdge ==

  We need:
  1) A BottomEdge SDK component
  2) That is enabled
  3) That is attached to the bottom edge of the app
  4) That is currently being rendered (might be in a Page that isn't on top right now)
  5) That isn't obscured by some other widget or MouseArea

  #5 is going to be hard to detect in the wild west of apps from the
  store.  But one thing we could do restrict this to known-well-behaved
  apps that are shipped by default anyway.  The user is most likely to
  be in one of those early on in their phone experience anyway.

  Once the SDK can detect this situation, it needs to signal it somehow.
  Maybe the "valid-bottom-edge" state can bubble up to qtmir's
  ApplicationManager and then the shell.  Any ideas on the best way to
  do that?

  == Synchronizing fade transition ==

  I'm thinking there are two ways:

  1) Communicate from the app to the shell how far the bottom edge has
  been dragged, as it is being dragged.  Presumably via the same channel
  as we communicate that there is a valid bottom edge in the first
  place.

  2) Fake it and have the shell track the drag itself.  It then needs to
  mirror the input to the app so that it also receives the drag.

  #2 is probably easier.  Slightly brittle in case for whatever reason
  the app interferes with the drag or does something on its own that
  would desynchronize the animation.  But again, if we limit this to
  well-known apps, we can avoid that.

  == Open tasks ==

  1) Get general feedback on these ideas
  2) Determine how feasible it is for the SDK to detect a valid BottomEdge
  3) Determine the best way to signal that state from the SDK up to the shell
  4) Implement it

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-ui-toolkit/+bug/1499845/+subscriptions


References