Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tab shortcuts to cycle "take" windows (improves #808) #810

Merged
merged 9 commits into from
Mar 31, 2024
7 changes: 4 additions & 3 deletions navigator.js
Original file line number Diff line number Diff line change
@@ -294,10 +294,11 @@ class NavigatorClass {
this.takeHint = new St.Label({ style_class: 'take-window-hint' });
this.takeHint.clutter_text.set_markup(
`<i>• release keys to return all taken windows</i>
<i>• press <span foreground="#6be67b">spacebar</span> to return the last taken window</i>
<i>• press <span foreground="#6be67b">tab</span> to cycle forward through taken windows</i>
<i>• press <span foreground="#6be67b">grave</span> to cycle backward through taken windows</i>
<i>• press <span foreground="#6be67b">spacebar</span> to return the last taken window</i>
<i>• press <span foreground="#6be67b">q</span> to close all taken windows</i>`);
<i>• press <span foreground="#6be67b">q</span> to close all taken windows</i>`
);

navigating = true;

@@ -345,7 +346,7 @@ class NavigatorClass {
if (show) {
// set position on stage, take into account monitor
const monitor = this.space.monitor;
const x = monitor.x + monitor.width - 387;
const x = monitor.x + monitor.width - 380;
const y = monitor.height - 118;

this.takeHint.opacity = 0;
4 changes: 2 additions & 2 deletions tiling.js
Original file line number Diff line number Diff line change
@@ -4893,9 +4893,9 @@ export function takeWindow(metaWindow, space, { navigator }) {
}));
metaWindow.clone.set_position(point.x, point.y);
let x = Math.round(space.monitor.x + space.monitor.width -
(0.1 * space.monitor.width * (1 + navigator._moving.length)));
(0.08 * space.monitor.width * (1 + navigator._moving.length)));
let y = Math.round(space.monitor.y + space.monitor.height * 2 / 3) +
20 * navigator._moving.length;
16 * navigator._moving.length;
animateWindow(metaWindow);
Easer.addEase(metaWindow.clone,
{