Issue 48639 - Gok open 2 instances of a pane when menu used
Summary: Gok open 2 instances of a pane when menu used
Status: CLOSED NOT_AN_OOO_ISSUE
Alias: None
Product: General
Classification: Code
Component: code (show other issues)
Version: 680m97
Hardware: All All
: P3 Trivial (vote)
Target Milestone: OOo 2.0.2
Assignee: nospam4obr
QA Contact: issues@framework
URL:
Keywords: accessibility
: 48640 (view as issue list)
Depends on:
Blocks:
 
Reported: 2005-05-03 16:45 UTC by eric.savary
Modified: 2005-05-30 14:33 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description eric.savary 2005-05-03 16:45:18 UTC
- JDS 34b + OOom97
- GOK: Menu - New - Text Document
-> 2 documentrs are created
Note: same for Open, Export and Save As dialogs
Comment 1 eric.savary 2005-05-03 16:45:46 UTC
Set accessibility keyword
Comment 2 eric.savary 2005-05-03 17:38:13 UTC
ES->OBR: please dispatch to the responsible engineers. Thanx!
Comment 3 nospam4obr 2005-05-09 09:02:59 UTC
cc'ing tbe.
Comment 4 thomas.benisch 2005-05-12 15:56:02 UTC
When performing the 'select' action of the 'File/New/Text Document' menu item
by using the Accessiblity Workbench, only one document is created.
Comment 5 nospam4obr 2005-05-17 08:59:24 UTC
What gok does is it calls XAccessibleSelection::selectAccessibleChild() on the
menu before it actually runs the action on the menu item, which currently has
the same effect as XAccessibleAction::doAccessibleAction(). So from a OOo
perspective, this call sequence appears as a duplicate call to doAccessibleAction().

The behaviour in GNOME apps is different: e.g. in gedit, a menu item shows it's
description in the status bar when selected and that's it. Unfortunatly I could
not check in Java apps, because their menu bar currently doesn't show up in
at-poke (at least for me).
Comment 6 nospam4obr 2005-05-17 09:21:19 UTC
*** Issue 48640 has been marked as a duplicate of this issue. ***
Comment 7 billhaneman 2005-05-17 14:40:17 UTC
'select' shouldn't be the same as 'activate', in this context.  For instance, if
you mouse over a menu, and the various choices prelight, they are being
'selected' but not activated.  So the implementation of
XAccessibleSelection::selectAccessibleChild() should be changed for menu items.
Comment 8 korn 2005-05-17 20:32:05 UTC
Bill, using AccessibleSelection to 'add' a menu item to the selection of it's
parent menu has always resulted in that item being activated in Java/Swing.  You
can see this with the Monkey tool.  Select a menu in the accessible tree of a
Swing app and bring up the Selection panel for it (e.g. File in SwingSet2). 
Choose a selectable child and click "Add" to add it to the selection, and that
will activate the menu item.  

This is different for things like lists of course.  But for menus we mirror the
standard GUI notion of "selecting from a menu".
Comment 9 nospam4obr 2005-05-18 05:31:00 UTC
If OOo is correctly emulating Java accessibility here, I think this issue needs
to get addressed in the gnome-java-bridge.
Comment 10 billhaneman 2005-05-18 09:21:53 UTC
Peter:those aren't the semantics of at-spi.  Selection and activation are
definitely disjoint for both menus and lists.

Similar bugs have been fixed in the past, IIRC in java-bridge for gnome too.  If
OOo isn't working correctly, then I suggest that it isn't emulating Java 100%,
since currently GOK doesn't result in multiple activations for Java menus in JDS.
Comment 11 nospam4obr 2005-05-18 10:33:31 UTC
Bill, I have just reproduced the same behavior OOo shows with jmplay and GOK:
"Menus - File - New Player" opens two new player windows. So the code in the
gnome-java-bridge that handles the different semantics of menus in at-spi and
JAA seems to got broken by some other change.
Comment 12 billhaneman 2005-05-18 11:31:31 UTC
interesting, this doesn't happen on my system (running Java 1.5.0_02 and
JMFPlayer from an old Cinnabar build (30?)
Comment 13 nospam4obr 2005-05-18 12:03:55 UTC
My system runs plain Cinnabar 35 (including java 1.5.0_03). Maybe anyone running
the same configuration can confirm ?
Comment 14 billhaneman 2005-05-18 12:17:40 UTC
Oliver - I'm seeing some inconsistencies with Java -sometimes I see the "double
activation" that you are reporting even with my JVM.  So I probably should make
some tweaks to the Java bridge.
Comment 15 eric.savary 2005-05-18 12:25:13 UTC
If it may help: yes I can exactly reproduce what Oliver is describing with the
same config (JDS 35, Gok, jmplay).
Comment 16 korn 2005-05-18 17:55:55 UTC
Bill, I don't understand the issue here.  GOK will see a File menu (for example)
that implements AccessibleSelection, and an About menu item (for example) that
implements AccessibleAction.  Telling File via AccessibleSelection to select
"About" happens to do the same thing as telling About via AccessibleAction to
"click".  

Why cannot GOK distinguish between the two and only call one of them at it's
choice?  I don't see a problem here.  What am I missing?
Comment 17 billhaneman 2005-05-18 18:05:46 UTC
well, that's not the way gok works.  The menu buttons are not special-cased in
this way, they act like other actionable items.  For a number of reasons having
to do with the way various toolkits work, you often have to select items whose
parent implements Selection before invoking an action on that item.  These two
things are totally orthogonal in at-spi.
Comment 18 korn 2005-05-18 18:31:19 UTC
Hmm... Frankly need to select an object before AccessibleAction works seems odd
to me (if not a bug).  Also calling a menu item a "menu button" seems wierd to
me - not a GUI concept for me.

But separate from that, it is still the case that in Java you (a) don't need to
select an item before you can call its Action, and (b) menu item selection ==
invocation.  If you have a strong desire for this to appear differently in
AT-SPI, then it must be dealt with in the bridge.
Comment 19 billhaneman 2005-05-18 18:58:20 UTC
on reflection Peter I don't know if it's possible to deal with this in the bridge.

The need to select before activation is the sort of thing that would be closed
instantly as NOTABUG by an app or toolkit person IMO.  It has come up a few times.

by "menu button" I am referring to the GokButton representing a menu item.
If menu item selection == invocation in Java, then the menu should not implement
AccessibleSelection, IMO, since that is redundant with AccessibleAction.  
Comment 20 nospam4obr 2005-05-23 10:22:18 UTC
I have logged CR6274349 for the jmplay issue in Cinnabar. As soos as there is a
fix for this one, we need to re-evaluate this issue again to check whether it
there is an additional Java compatibility problem in OOo. Adjusting target.
Comment 21 nospam4obr 2005-05-30 14:33:11 UTC
This issue vanished with gok 1.0.5-38 (cinnabar36).
Comment 22 nospam4obr 2005-05-30 14:33:50 UTC
Closing as "not OOo".