Commit Graph
1564 Commits
Author SHA1 Message Date
Tor Hedin Brønner 2f58d796ed navigator: rewrite finish/destroy code
- Activate destination workspace if it isn't active, fake it if not.

If a «stuck» window have focus, consider it selected.

If selected window or one its transient window has focus, fake focus
handler. Otherwise activate it.
2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 7e25f9ad53 reposition clone using pointer after insertion
For some reason this is accurate
2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 69ec12c863 space: only scroll if navigating or in a grab 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 613abd2bce grab: remove scroll-event 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 32c6ad3fd2 grab: remove positionChanged 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 9fb8b0e9bb space button-press: navigate to space if clicking on background 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner f43de26ab2 navigator: always start dnd if grab is active 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner f42cee970f position clone correctly when popped out of scaled space 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 9bff4dc44c get_coords doesn't take scaling into account
Use get_pointer, and transform_stage_point for to get correct
coordinates...
2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 08f902a626 isWindowAtPoint: use correct clone coordinate 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 9dc3880b87 navigator: start dnd if in grab 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner c4808c3ba1 guard 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 245d7aa30a fix some coordinate transforms 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner fa75a40955 fix grab y position 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 4ad4899fbb better pointeroffset 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 818d90ad75 wip: grab everywhere 2020-03-08 14:48:00 +01:00
Tor Hedin Brønner 772b698e77 wip: always use fake grab 2020-03-08 14:48:00 +01:00
Ole Jørgen Brønner 99744ad970 DnD mouse cursor 2020-03-08 14:46:47 +01:00
Ole Jørgen Brønner 510a70d9a8 utils: less verbose trace functions 2020-03-08 14:46:47 +01:00
Ole Jørgen Brønner b4c023e1fb Do DnD outside mutter grab
- delay workspace change until DnD end (partial Navigator destroy)
- sync scratch window frame with clone on grab end

Bug in the wip commit fixed: (focus was not always preserved on workspace dnd)
- DnD a window
- switch to a different workspace using the workspace carousel
- drop the window

-> the DnD-window loose focus on workspace change (in step 2)

Note: Mutter enforce focus_window.workspace === active_workspace, changing focus
window if necessary.
2020-03-08 14:46:47 +01:00
Ole Jørgen Brønner b8f5733dda Ensure all windows in the space belong to the workspace before completing workspace switch
This simplifies code moving windows between workspaces without messing with the
focus. (since mutter enforce focus_window.workspace == active_workspace)

Mainly preparation for DnD fixes in the next commit.
2020-03-08 14:46:47 +01:00
Tor Hedin Brønner dd644161fd Use clones global coordinates to insert 2020-03-08 14:46:47 +01:00
Ole Jørgen Brønner e5764dfb5e wip: do DnD outside mutter grab
This is much more flexible: we can drag windows across workspaces in the
carousel, react on keybindings, scroll, etc.
2020-03-08 14:46:47 +01:00
Tor Hedin Brønner 2e407554be maximized: fix y position of eg. firefox wayland
Some windows apparently report the wrong frame.y value when they've just
been maximized, leaving us with the old incorrect value. Simply hardcode
the correct y value instead.
36.0
2020-03-07 14:25:19 +01:00
Tor Hedin Brønner f1b151524a edge overlays: Do not set when browsing workspaces 2020-03-07 13:30:10 +01:00
Tor Hedin Brønner add08a38d2 Fix top bar on enable
When unlocking the desktop with a fullscreen window focused we'd incorrectly
show the topbar.

Run fixTopBar after all spaces have been fully setup to fix it.
2020-03-07 13:26:16 +01:00
Tor Hedin Brønner 4f9383a430 Fix top bar on notify::fullscreen
If there's already a fullscreen window in the workspace, gnome-shell
won't trigger a hide on the topbar. Meaning fixTopBar won't run
automatically, so we need to run on any fullscreen changes.
2020-03-07 13:26:16 +01:00
Tor Hedin Brønner 108f7202ff edge overlays: hide when selecting a maximized window 2020-03-02 16:27:18 +01:00
Tor Hedin Brønner 5727ea94cf Space.isVisible: Work correctly with fullscreen windows 2020-03-01 18:55:42 +01:00
Tor Hedin Brønner a7da294946 Space.isVisible: use current, not future, coordinates 2020-03-01 18:54:54 +01:00
Tor Hedin Brønner 5dcee36d71 Polish up animate down for fullscreen windows
- Simply move the fullscreen clone if not visible
- Do not start a new animation one is already in progress
- Do not run animateDown when starting navigation
2020-03-01 18:54:27 +01:00
Tor Hedin Brønner 0c3f71d94d selection highlight: add rounded border 2020-03-01 18:13:05 +01:00
Ole Jørgen Brønner 8971ae73e3 Wayland-safe(r) override-redirect check
It looks like mutter doesn't maintain override_redirect on wayland windows (ie.
it doesn't try to emulate the X11-only(?) concept)

This caused many menues (eg. gtk menues) to be registered by us (creating clone,
registering resize signals, etc.)

Particularily noticable in libreoffice - the menus was very delayed and
sometimes didn't show up at all. (Observed in GS 3.34.3, libreoffice 6.2.6.2)

(TOOLTIP is checked preemptively)
2020-02-28 21:13:10 +01:00
Tor Hedin Brønner 069f687fcd readme: Update for 3.36 support 2020-02-27 15:35:02 +01:00
Tor Hedin Brønner 7916c610fd Merge pull request #254 from paperwm/gnome-shell-3.36
Gnome shell 3.36
2020-02-27 15:34:10 +01:00
Tor Hedin Brønner 1db0e1b6d4 animateDown: use workArea
This fixes some visual bugs when navigating secondary monitors with top
bar on primary.
2020-02-27 15:00:53 +01:00
Tor Hedin Brønner 233999f9d7 Space.workArea: Move most logic here 2020-02-27 15:00:53 +01:00
Tor Hedin Brønner 123a1f9f46 layout: do not move maximized windows in y direction
Ideally we want to do this with fullscreen windows too, but it currently
becomes a bit messy due to top bar transparency.
2020-02-27 14:59:46 +01:00
Tor Hedin Brønner bb503675a0 Fix top bar visibility on insert/remove window 2020-02-27 12:37:27 +01:00
konni 616d7712fa add resize functions to inc/dec height/width (#255) 2020-02-25 16:55:52 +01:00
Tor Hedin Brønner 806e304fe4 metadata: register 3.36 support 2020-02-25 10:44:00 +01:00
Tor Hedin Brønner a817e55502 3.36: Add support for warping pointer in wayland 2020-02-25 10:44:00 +01:00
Tor Hedin Brønner dce11d0c8b liveAltTab: fix abort 2020-02-25 10:44:00 +01:00
Tor Hedin Brønner aa76906d0f kludges: fix for 3.35.90
TouchpadWorkspaceSwitchAction no longer exists
2020-02-25 10:44:00 +01:00
Tor Hedin Brønner 5c89890b18 workaround strange move_frame bug in 3.35...
For some reason after a successful `move_frame`, and `position-changed`,
the window is moved back to it's original position. This only happens
sporadically...

Anyway, just do the simply thing and make sure all `position-changed`
signals are correct.

NOTE: need a grab guard or something for non-clutter dnd
2020-02-25 10:44:00 +01:00
Tor Hedin Brønner f0b9d21ced navigator: fix escape 2020-02-25 10:44:00 +01:00
Tor Hedin Brønner 5e94080e1d Fix and update workspace menu for 3.36
Upstream updated the menu style (and together with that some styles we
relied on). Fix it and make the look inline with the new upstream menus.
2020-02-25 10:44:00 +01:00
Tor Hedin Brønner a948b9b325 workspace menu: Fix signals for 3.35.2 2020-02-25 10:44:00 +01:00
Tor Hedin Brønner 335a623be7 Polyfill Clutter.Vertex 2020-02-25 10:44:00 +01:00
Tor Hedin Brønner 4ef1db8704 Polyfill actor.reparent/raise/raise_top
3.35.2 removed these deprecated methods, but the replacement is a bit
wieldy, so lets just polyfill.
2020-02-25 10:44:00 +01:00