Skip to content

Resize plugin does not handle tiling (i.e. unmaximizing) via tile_request #838

@valpackett

Description

@valpackett

Describe the bug
Unlike move, which (in plugins/common/wayfire/plugins/common/move-snap-helper.hpp) uses view->tile_request(0), resize does view->set_tiled(0).

tile_request emits the view-tile-request signal which is handled by grid. So by not using it, resize doesn't let grid know the latest information. As a result, when untiling a view via right-click resize, the next grid snapping of the view won't work correctly, there will be a weird offset to the positioning!

Sadly the easy fix (just changing which function resize calls) has a side effect: a weird snap at the beginning of an untiling resize — I guess we also need the adjust_around_grab part of the move-snap-helper.

To Reproduce
Steps to reproduce the behavior:

  1. Snap a window to the top
  2. Resize (via button binding) to unmaximize
  3. Try to snap again, observe weird offset

Screenshots or stacktrace
https://dl.unrelenting.technology/wf-snap-wtf.mp4 (only shows the offset itself, recorded before I understood the bug)

Wayfire version
git

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions