Need DBus API to get current co-ordinates of the Pointer

Bug #1630337 reported by Omer Akram
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
unity8 (Ubuntu)
New
Undecided
Unassigned

Bug Description

The autopilot tool(using evdev) moves the mouse cursor on screen relative to its current position. This works fine in X11 as there are ways to easily get the co-ordinates of the cursor, but under Mir that does not work as we have no way to get the pointer' co-ordinates.

We need this API to port autopilot to work under Mir based desktop.

ProblemType: Bug
DistroRelease: Ubuntu 16.10
Package: unity8 8.14+16.10.20160922-0ubuntu2
Uname: Linux 4.7.0-040700-generic x86_64
ApportVersion: 2.20.3-0ubuntu7
Architecture: amd64
CurrentDesktop: Unity:Unity7
Date: Tue Oct 4 22:42:50 2016
InstallationDate: Installed on 2016-09-21 (12 days ago)
InstallationMedia: Ubuntu 16.10 "Yakkety Yak" - Alpha amd64 (20160921)
JournalErrors:
 Error: command ['journalctl', '-b', '--priority=warning', '--lines=1000'] failed with exit code 1: Hint: You are currently not seeing messages from other users and the system.
       Users in the 'systemd-journal' group can see all messages. Pass -q to
       turn off this notice.
 No journal files were opened due to insufficient permissions.
SourcePackage: unity8
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Omer Akram (om26er) wrote :
Revision history for this message
Omer Akram (om26er) wrote :

I am attaching a sample code that works under X, to get that to work under Mir, we only need to get cursor co-ordinates from unity8, then we only need to update get_cursor_position() method.

it requires python-evdev, python3-autopilot and python3-xlib installed.

Revision history for this message
Omer Akram (om26er) wrote :

There are a few points that I would like to point here that I and mzanetti discussed.

Mike wanted for us to talk to the unity8 proxy object to get details of the pointer co-ordinates to screen orientation but there are a few reasons that I believe we should not be going by that path.

1. The tool i.e. Autopilot should only rely on APIs and not on internal details of the unity8 server.
2. We don't want to restart unity8 to enable testability for autopilot to work. Restarting unity8 would only make sense if we were testing unity8 itself.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.