Mac dropdown menu bug in 3.3.1?

Thus spake Cattlesquat:

When I CTRL+click on a marker to get the contextual menu for it the
marker gets deselected. This seems to be why the menu item does not
execute on the marker.

This is an example of why we have to check isPopupTrigger() when we’re
doing other things than just putting up context menus.

So… I suspect now that you’re right… but how did this ever work before
3.3.0 in that case? I added the isPopupTrigger() checks in a commit on 19
May of this year. There was no version of VASSAL prior to 3.3.0-beta4
which had them.


J.

Before 3.3.0 we were using Java 8 and all its now-deprecated-ass stuff like isMetaDown() which acted as an ill-conceived but largely functional shortcut for detecting context menus and right-clickiness in one untidy package. It was when we went back to take out all the deprecated stuff that this was all introduced.

If you’re swamped I’m happy to go have a rip through this stuff and make an initial PR. Or happy to do a forensic review on one you do.

Thus spake Cattlesquat:

If you’re swamped I’m happy to go have a rip through this stuff and make
an initial PR. Or happy to do a forensic review on one you do.

I’ll have something for you to look at later this evening. Almost all
the mouse handlers we have aren’t for the map and do just one thing,
so I should be able to rip through those fairly quickly.


J.

I’ve checked through all the uses of MouseEvent we have. A number of classes I was able to exclude immediately because they have mouse listeners which only show a context menu or do nothing at all. Here’s a list of the remaining classes which deal with MouseEvents:

AboutWindow
ActionButton
ChooseComponentDialog
ConfigureTree
DragBuffer
ExtensionTree
FreeRoator
GlobalMap
GridEditor
ImagePicker
KeyBufferer
LOS_Thread
Map
MapCenterer
ModuleManagerWindow
MultiRoll
PieceDefiner
PieceMover
PieceSlot
PolygonEditor
PropertySheet
RegionGrid
RoomInteractionControlsInitializer
ServerAddressBook
SplashScreen
StackExpander
TranslateWindow

Some of these might be fine as-is, but I couldn’t tell from 15 seconds of looking. Some definitely need adjustment.

PieceMover, KeyBufferer (and I guess Map) will be the most important/delicate/complex/godawful, and will eliminate 98% of the bugs.

See PR 79: github.com/vassalengine/vassal/pull/79

If you’re having this problem, please try this build and let us know if it restores the behavior from 3.2.17 for you:

vassalengine.org/~uckelman/t … macosx.dmg

Yes, this seems to fix the Ctrl/Click issue.

i.e. Pressing Control-Click gives me the same result as two-finger press on the trackpad; i.e. “right-click” behaviour - piece is selected and dropdown menu appears. When chosen, a menu option effects the clicked-on piece.

Perhaps coincidence (different build?) but a separate issue that I reported on 3.3.1 development variants does not replicate in -313. I will update my posting about that.

“Perhaps coincidence (different build?) but a separate issue that I reported on 3.3.1 development variants does not replicate in -313. I will update my posting about that.”

Sorry, I spoke too soon. Specifically testing, I soon found that this seperate issue does in fact persist (nothing to do with dropdown menu bug). I updated the bug retracker record accordingly.