Guake / Guake/guake

Guake stays on top when focus is lost and "stay on top" is false

Open
#1,731 3 comments 2 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
4.7k
Forks
604
PR merge metrics
No merged PRs in 30d

Description

**Steps to reproduce**

1. Configure guake so that "Stay on top" is disabled.
2. Open any application/window
3. Show guake (F12 for me)
4. Click on the background window

**Expected behavior**

Guake loses focus and moves to the background, but does not hide.

**Actual behavior**

Guake loses focus, and momentarily moves to the background. However, it immediately comes back to the foreground, but not focused.

-------------------------------------------------------------------------------
This appears to be caused by `FullscreenManager.set_window_state()`. If I comment out the `Gdk.WindowState.WITHDRAWN` block, guake properly loses focus.
```
--- a/guake/utils.py
+++ b/guake/utils.py
@@ -165,11 +165,11 @@ class FullscreenManager():
self.window_state = window_state
setattr(self.window, self.FULLSCREEN_ATTR, bool(window_state & Gdk.WindowState.FULLSCREEN))

- if not window_state & Gdk.WindowState.WITHDRAWN:
- if self.is_fullscreen():
- self.fullscreen()
- else:
- self.unfullscreen()
+ #if not window_state & Gdk.WindowState.WITHDRAWN:
+ # if self.is_fullscreen():
+ # self.fullscreen()
+ # else:
+ # self.unfullscreen()

def fullscreen(self):
self.window.fullscreen()
```
-------------------------------------------------------------------------------
$ guake --support

Guake Version: 3.7.0

Vte Version: 0.56.4

Vte Runtime Version: 0.56.4

--------------------------------------------------
GTK+ Version: 3.24.13

GDK Backend: GdkX11.X11Display

--------------------------------------------------
Desktop Session: Cinnamon 4.4.8

--------------------------------------------------
Display: :0

RGBA visual: True

Composited: True

* Monitor: 0 - SHP DP-4
* Geometry: 1920 x 1080 % 2 at 0, 0
* Size: 346 x 194 mm²
* Primary: True
* Refresh rate: 60.00 Hz
* Subpixel layout: unknown

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.