← Back to team overview

touch-packages team mailing list archive

[Bug 1520164] [NEW] overlay buttons globalRect has wrong y co-ordinate (represents center of the object, rather than the top)

 

Public bug reported:

The globalRect property of an object is supposed to represent the top
left hand corner of it, along with the width and height. Taking
advantage of that fact, Autopilot calculates the middle as x, y = x+w/2,
y+h/2

This calculation seems to have been thrown off by the overlay buttons in
the camera-app. In this case the globalRect represents the center of the
object. We determined this by enabling the touch vizualisation in
Unity8:

$ apt-get install qtdbus-qt5
$ qdbus --system com.canonical.Unity.Screen / com.canonical.Unity.Screen.setTouchVisualizationEnabled true

When clicking using click_object this clicks in the center, just below
the button. If we use the globalRect co-ordinates directly (without
adding width and height) it clicks in the exact center of the button.

Note that camera-app seems to be the only application affected by this
issue at the moment.

Another note - the x, y, width and height properties (outside of
globalRect) seem to be correct.

$ system-image-cli -i
current build number: 187
device name: krillin
channel: ubuntu-touch/rc-proposed/bq-aquaris.en
last update: 2015-11-24 09:51:16
version version: 187
version ubuntu: 20151124
version device: 20151028-869191d
version custom: 20151111--36-46-vivid

** Affects: camera-app
     Importance: Undecided
         Status: New

** Affects: ubuntu-ui-toolkit (Ubuntu)
     Importance: Undecided
         Status: New

** Also affects: ubuntu-ui-toolkit (Ubuntu)
   Importance: Undecided
       Status: New

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

Title:
  overlay buttons globalRect has wrong y co-ordinate (represents center
  of the object, rather than the top)

Status in camera-app:
  New
Status in ubuntu-ui-toolkit package in Ubuntu:
  New

Bug description:
  The globalRect property of an object is supposed to represent the top
  left hand corner of it, along with the width and height. Taking
  advantage of that fact, Autopilot calculates the middle as x, y =
  x+w/2, y+h/2

  This calculation seems to have been thrown off by the overlay buttons
  in the camera-app. In this case the globalRect represents the center
  of the object. We determined this by enabling the touch vizualisation
  in Unity8:

  $ apt-get install qtdbus-qt5
  $ qdbus --system com.canonical.Unity.Screen / com.canonical.Unity.Screen.setTouchVisualizationEnabled true

  When clicking using click_object this clicks in the center, just below
  the button. If we use the globalRect co-ordinates directly (without
  adding width and height) it clicks in the exact center of the button.

  Note that camera-app seems to be the only application affected by this
  issue at the moment.

  Another note - the x, y, width and height properties (outside of
  globalRect) seem to be correct.

  $ system-image-cli -i
  current build number: 187
  device name: krillin
  channel: ubuntu-touch/rc-proposed/bq-aquaris.en
  last update: 2015-11-24 09:51:16
  version version: 187
  version ubuntu: 20151124
  version device: 20151028-869191d
  version custom: 20151111--36-46-vivid

To manage notifications about this bug go to:
https://bugs.launchpad.net/camera-app/+bug/1520164/+subscriptions


Follow ups