U7: declare plugin_api 28, bind middle-click, translate the bar tooltip #16
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "upgrade/u7-gestures"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The bump buys one thing
plugin_api.hdeclares 26 feature constants; only seven are consulted anywhere in the shell,and every one gates a manifest key, never a script binding. Of everything this upgrade
wanted, only
kWidgetGestureActions(14) is enforced, atplugin_manifest.cpp:589-594.Verified live earlier in this wave with a scratch plugin declaring
plugin_api = 3:So PRs #11-#15 -- argv, the scroll viewport, closures, the module split, the context menu --
all landed at API 3 and none needed this. The declaration goes to 28 here, for gestures.
Why only
middlePluginWidgetcreates its own input area accepting left/right/middle and dispatches them tothe
onClick/onRightClick/onMiddleClickglobals (plugin_widget.cpp:152-173). The baralready claims left and right in Lua. Which wins when a gesture also claims a button is not
something I could establish: the probe showed a
ui.buttoninside the plugin's treeshadows the gesture, but that is a different mechanism from the widget-level globals, and
settling it needs real pointer events. The display was asleep, so that test could not run.
middle = "settings-open-widget"needs no such ruling -- nothing claims middle -- and itmatches what every built-in widget binds.
Rebinding without editing the manifest
[widget.actions]has no "call a Lua function" form:widget_action.cpp:26-56parses a valueas
none,exec <cmd>, or an IPC verb. A gesture reaches plugin code only by dispatching backin, so
onIpcis the rebinding surface and its event names are public API:The suite pins
onIpc's argv againstonClick's own, not a literal -- a literal would bea third spelling both could drift away from together.
The bar's first translation key
Deferred since PR #7: the panel translated the
(untagged)sentinel and the bar rendered itverbatim, so in a non-English locale the two surfaces disagreed about the same interval (panel
"sin etiqueta", bar "(untagged)"). The bar had no
noctalia.trcall at all; now it has one,using the panel's key.
setTooltipwas afunction() endstub that discarded its argument, so no test could havecaught this. It captures now.
Gates
Mutations
onIpctoggle event renamedonIpctoggle opens the panel insteadM4 and M5 first died on a missing
togglePanelstub rather than an assertion, which meant thepanelroute was uncovered. Stubbed and asserted; M5 now fails attest.luau:858.Not verified, and how to close it
The
middlegesture has never been clicked.noctalia plugins lintdoes not validate gesturekeys or verbs -- the probe confirmed
double_leftlints clean and fails only at dispatch -- sothe manifest being accepted is not proof the binding fires. After merge the resolved set
appears in the journal as
[DBG] [bar.actions] widget.timew: middle=settings-open-widget,which proves resolution; firing needs a real middle-click.
yuris referenced this pull request2026-09-02 03:32:02 +00:00