Skip to content

Commit b7524d8

Browse files
mmstickjackpot51
authored andcommitted
fix: Disallow showing active hint if window is not focused
1 parent 3e207a7 commit b7524d8

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

src/window.ts

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -247,11 +247,9 @@ export class ShellWindow {
247247
}
248248

249249
is_maximized(): boolean {
250-
let maximized = this.meta.get_maximized() !== 0;
251-
return maximized;
250+
return this.meta.get_maximized() !== 0
252251
}
253252

254-
255253
/**
256254
* Window is maximized, 0 gapped or smart gapped
257255
*/
@@ -419,10 +417,10 @@ export class ShellWindow {
419417
let border = this.border;
420418

421419
const permitted = () => {
422-
return !this.meta.is_fullscreen() &&
423-
(!this.is_single_max_screen() || this.is_snap_edge()) &&
424-
!this.meta.minimized &&
425-
this.same_workspace()
420+
return this.ext.focus_window() == this
421+
&& !this.meta.is_fullscreen()
422+
&& (!this.is_single_max_screen() || this.is_snap_edge())
423+
&& !this.meta.minimized
426424
}
427425

428426
if (permitted()) {

0 commit comments

Comments
 (0)