Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 11 additions & 5 deletions src/AppButton.js
Original file line number Diff line number Diff line change
Expand Up @@ -127,11 +127,17 @@ export default function AppButton({ appInfo, content_type, entry, window }) {
});
}

if (
(keyname === "Return" || keyname === "space") &&
modifier_state & Gdk.ModifierType.CONTROL_MASK
) {
open(false);
if (keyname === "Return" || keyname === "space" || /^\d$/.test(keyname)) {
if (modifier_state & Gdk.ModifierType.ALT_MASK) {
popupActionsMenu({
appInfo,
popoverMenu,
location: entry.get_text(),
});
} else {
open(!(modifier_state & Gdk.ModifierType.CONTROL_MASK));
}
controller_key.set_state(Gtk.EventSequenceState.CLAIMED);

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TypeError: controller_key.set_state is not a function

}
},
);
Expand Down
5 changes: 0 additions & 5 deletions src/window.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,6 @@ export default function Window({ application, file }) {
button?.grab_focus();
return !!button;
});
eventController.connect("key-released", (self, keyval) => {
const button = getButtonForKeyval(keyval);
button?.activate();
return !!button;
});

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your version doesn't do the same thing as this.

This highlights the entry before opening the browsing showing the user which browser is gonna open before Juncton closes. It's subtitle but you should be able to tell the difference.

Please revert

window.add_controller(eventController);

function copyToClipboard() {
Expand Down