GP SoftwareTwitter
Opus FAQsManualCommandsObjects

Context menu on button


#1

I created a three buttons button.
A left click opens a folder in the same tab and the right click opens that folder in a new tab.
But I would like to display the context menu of that folder when I right click the button (like what happens when you right click on a drive letter from a 'Go DRIVEBUTTONS' button), and have a middle click open the folder in a new tab.
Is it possible to display the context menu of a certain folder on a button (I know the middle click part is possible)?


#2

Go PATH="C:\xyz" CONTEXT on a normal button (not a three button) will turn into something which shows the context menu when you right-click it, and goes to the folder when you left-click it.

(The Go command's CONTEXT argument is currently hidden/undocumented, but is what Go DRIVEBUTTONS generates internally. It's possible this may stop working in the future, or we may document it and make it officially supported.)


#3

Thanks, that works.
Followup question though, if this can't be used in a three buttons button is there an other way to have the folder open in a new tab with a middle mouse click?
I've tried multifunc and multifunctab but that removes the right click context menu.


#4

AFAIK there isn't a way to combine both at the moment, except maybe by having a script on the right-click action which causes the context menu to appear. (Not sure how easy that is to do from a script, though. Scripts can show their own menus but I don't know if there is a way to make them show the context menu for a file without generating the contents of the menu.)