Skip to content

Commit

Permalink
disable hover effect, add basic keyboard support
Browse files Browse the repository at this point in the history
  • Loading branch information
rjocoleman committed Nov 29, 2023
1 parent 9b9eb6a commit 86afba9
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ build:
--extra-source=icons/ \
--extra-source=tailscale.js \
--extra-source=timeout.js \
--extra-source=compat.js; \
--extra-source=compat.js \
--extra-source=stylesheet.css; \
mv $(EXTENSION_DIR).shell-extension.zip ../$(BUNDLE_PATH)

install:
Expand Down
3 changes: 3 additions & 0 deletions [email protected]/extension.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ const TailscaleDeviceItem = GObject.registerClass(
_init(icon_name, text, subtitle, onClick, onLongClick) {
super._init({
activate: onClick,
can_focus: true,
});

const icon = new St.Icon({
Expand Down Expand Up @@ -321,6 +322,7 @@ const ScrollablePopupMenu = GObject.registerClass(
super._init({
hover: false,
activate: false,
can_focus: false,
});

this.scrollView = new St.ScrollView({
Expand All @@ -333,6 +335,7 @@ const ScrollablePopupMenu = GObject.registerClass(
this.box = new St.BoxLayout({ width: 300, vertical: true });
this.scrollView.add_actor(this.box);
this.actor.add_actor(this.scrollView);
this.actor.add_style_class_name('scrollable-popup-menu');

this.scrollView.connect('scroll-event', this._onScrollEvent.bind(this));

Expand Down
3 changes: 3 additions & 0 deletions [email protected]/stylesheet.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.scrollable-popup-menu {
background-color: transparent !important;
}

0 comments on commit 86afba9

Please sign in to comment.