diff --git a/appIcons.js b/appIcons.js index 88a4bbb..73c1650 100644 --- a/appIcons.js +++ b/appIcons.js @@ -828,7 +828,10 @@ export const TaskbarAppIcon = GObject.registerClass({ else buttonAction = SETTINGS.get_string('middle-click-action'); } - else if (button && button == 1) { + // fixed issue #1676 by checking for button 0 or 1 to also handle touchscreen + // input, probably not the proper fix as i'm not aware button 0 should exist + // but from using this fix for months it seems to not create any issues + else if (typeof button === 'number' && (button == 0 || button == 1)) { let now = global.get_current_time() doubleClick = now - this.lastClick < DOUBLE_CLICK_DELAY_MS diff --git a/panel.js b/panel.js index a971914..9f8a261 100644 --- a/panel.js +++ b/panel.js @@ -1061,6 +1061,11 @@ export const Panel = GObject.registerClass({ this._setShowDesktopButtonStyle(); + this._showDesktopButton.connect('touch-event', (actor, event) => { + if (event.type() == Clutter.EventType.TOUCH_BEGIN) { + this._onShowDesktopButtonPress(); + } + }); this._showDesktopButton.connect('button-press-event', () => this._onShowDesktopButtonPress()); this._showDesktopButton.connect('enter-event', () => { this._showDesktopButton.add_style_class_name(this._getBackgroundBrightness() ?