gdesklets status icon should support a11y

Bug #229506 reported by idefix
4
Affects Status Importance Assigned to Milestone
gDesklets
Fix Released
Medium
gDesklets Core Team

Bug Description

Steps to reproduce:
1. Run gdesklets to make this app running and the icon is showing the notification area.
2. Press <Alt><Ctrl><Tab> to move focus onto bottom panel.
3. Press <Arrow> to move focus onto gdesklets icon in notification area.
4. Press <Shift><F10> to popup right click menu.

Expected result:
The right click menu can popup, the accessx keys works for notification area.

Actual result:
User can move focus into notification area, but <shift><F10> doesn't work.

This is a very basic a11y functionality that all gnome based application should support, and we can support it with tiny modification of code.

See attached patch:
in main/Trayicon.py
the button event is filter by a if statement.
if (button == 3):
            self.__menu.popup(None, None, None, button, time)
Actually, the if statement is redundancy, as the work has already done by gtkstatusicon. remove the if statement will not affect the behaviors of the statusicon.
However, the keyboard event is button == 0 and has been filtered by the if statement. After remove the if statement, we can fix the problem.

I also added position function into popup function to ensure the menu is pop up at the correct position when control with keyboard
 self.__menu.popup(None, None, gtk.status_icon_position_menu, button, time, self.__trayicon)

the select_first is used when navigate with keyboard, to disable the automatically highlight on the first menu item

Revision history for this message
idefix (chris-wang) wrote :
Revision history for this message
Bjoern Koch (h.humpel) wrote :

Just pushed to bzr 0.3x (rev. 105).

Changed in gdesklets:
assignee: nobody → h.humpel
importance: Undecided → Wishlist
status: New → Fix Committed
Revision history for this message
Bjoern Koch (h.humpel) wrote :

Re-opening this one again....

I am not sure what is the reason why the Status Icon stopped working (here) but I _guess_ it is because of the switch to gtk.StatusIcon.

ANYWAY, using "if (button == 0):" stopped working here. In fact, the icon shows up, but there is no menu attached to it. Furthermore the icon disappeared as soon as any desklet is started (yes, it only shows up when NO desklet is loaded at all).
Switching back to "if (button == 3):" seems to work fine here (Status Icon with menu, with or without loaded desklets).

I am not sure either how this all affects the rest of the opening posting now.
So I am going to change things back to "if (button == 3):" in bzr and re-open this one again (triaged) for further discussions etc.

Changed in gdesklets:
status: Fix Committed → Triaged
Revision history for this message
Bjoern Koch (h.humpel) wrote :

Strange things happening here...
OK, now the Status Icon starts up with menu etc., but ONLY as long as no desklet is started. Starting desklets now won't affect the Status Icon.
BUT when the deamon is started including some desklets the Status Icon pops up for a second (or less) in the notification area before it disappears again.
No clue what's going on here... :/.

Bjoern Koch (h.humpel)
Changed in gdesklets:
milestone: none → release-of-0.36.3
Bjoern Koch (h.humpel)
Changed in gdesklets:
assignee: Bjoern Koch (h.humpel) → gDesklets Core Team (gdesklets-core-team)
importance: Wishlist → Medium
status: Triaged → Confirmed
Revision history for this message
Bjoern Koch (h.humpel) wrote :

The patch in bug #151880 seems to have fixed all the problems.

Fix committed in rev. #143.

Changed in gdesklets:
status: Confirmed → Fix Committed
Bjoern Koch (h.humpel)
Changed in gdesklets:
status: Fix Committed → Fix Released
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.