Skip to content

Right click does not behave correctly to display context menu #391

Description

@badetitou

I am playing with context menu and I discover that menu does not appear with classic right click but you need to have a pressed right click (on mac, magic touchbar).
This issue is reflected by the test SpButtonAdapterTest>>#testRightClickShowsMenu.

In my opinion, a classic right click should work to display the menu. I believe it is an issue in Toplo now, but it might be handle maybe in Spec-Toplo

The below snippet allows one to replicate the issue easily

application := SpApplication new.
application useBackend: #Toplo.
button := SpButtonPresenter new.
button application: application.
menu := SpMenuPresenter new 
		addGroup: [ :aGroup |
			aGroup addItem: [ :anItem |
				anItem name: 'Item Group 1'; action: [ "action here" ] ] ];
		addGroup: [ :aGroup |
			aGroup addItem: [ :anItem |
				anItem name: 'Item Group 2'; action: [ "action here" ] ] ].
button contextMenu: (menu).

button open.


BlSpace simulateClickOn: button adapter widget.
BlSpace simulateSecondaryClickOn: button adapter widget.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions