1. 27 Jan, 2021 3 commits
    • Roman Gilg's avatar
      refactor: remove has-child function · 6e84a5cc
      Roman Gilg authored
      The function has become unnecessary as instead of providing a virtual override
      like earlier we now just check if the window is contained in the children.
      Where we need to do that, let's do it directly instead.
    • Roman Gilg's avatar
      refactor: unvirtualize functions · 82c71540
      Roman Gilg authored
      The two functions has_child and add_child have no current overload, so they
      should not be defined as being virtual.
    • Roman Gilg's avatar
      fix: determine indirect transient followers · 26d13447
      Roman Gilg authored
      The has_child function had at some point in the past an override to find
      transients X11 windows that are indirect children e.g as a child of a child
      depending on the value of a boolean trap.
      This overload was lost at some point which ultimately means that the code path
      regressed. For example Kicker submenues were as second-level children and by
      virtue of being tool-windows hidden again through update_tool_windows(..).
      This patch replaces the calls to has_child with a call to is_follower_of, which
      not only makes the overload unnecessary but is in general a better API.
  2. 18 Dec, 2020 5 commits
    • Roman Gilg's avatar
      refactor: remove Toplevel popup functions · 3592e172
      Roman Gilg authored
      The virtual member functions to get the grab status and to cancel a popup are
      removed from Toplevel and instead implemented in the transient class and
      respectively in the Wayland window child class.
    • Roman Gilg's avatar
      refactor: replace XdgShellClient with win::wayland::window · 8a88cba5
      Roman Gilg authored
      We reimplement all XdgShellClient functionality in win::wayland::window or
      alternatively as free function templates in win namespace.
      Xdg-popups are implemented as annexed transients instead of windows with
      control like xdg-toplevels are.
      The geometry handling is radically changed:
      * The flow from configure to commit is simplified.
      * Window geometry sets frame extents.
      * The buffer geometry is not cashed anymore but calculated from that.
    • Roman Gilg's avatar
      refactor: create separate Wayland subsurface representation · 537a14c8
      Roman Gilg authored
      Create a window class inherting from Toplevel that is supposed to represent in
      the future a Wayland window in general but for now stands for subsurfaces only.
    • Roman Gilg's avatar
      refactor: have transient children be public · b06e64ed
      Roman Gilg authored
      We can access it this way easily for reordering. We could also add a function
      to do that but there is not really a reason besides distrusting the consumer
      to have that. Consumers must still use the add and remove functions to
      synchronize changes besides reordering the children.
    • Roman Gilg's avatar
      feat: define annexed transient children · 1012828d
      Roman Gilg authored
      An annexed transient child is a window that does not provide controls on its
      own but should always be treated as part of their transient lead.
      This commit adds the annexed property to win::transient and template functions
      to add and remove an annexed child in the Workspace.
  3. 23 Nov, 2020 5 commits
    • Roman Gilg's avatar
      refactor: split up win header file · 514bccfc
      Roman Gilg authored
      Move functionality in separate headers to be more specific about what to
      include and reduce the danger of circular includes.
    • Roman Gilg's avatar
      refactor: use transient class in remnants · 5ed22087
      Roman Gilg authored
      Unify code paths by making use of the transient interface in remants just like
      with other windows.
      Transient relations are simply ported over. This ways emitting the
      transientChanged signal can be moved into the transient class too and we have a
      clear flow from adding a window as child to removing it again at last at the
      destruction of the remnant.
    • Roman Gilg's avatar
      refactor: standardize X11 group transient handling · 07e2dcd1
      Roman Gilg authored
      The implementation for X11 group transients was extremely old and unclean.
      This commit rebuilds it to use the common list of leads and children in
      win::transient to hanlde in a homogenous way group transients and normal
      transients with a single transient lead.
    • Roman Gilg's avatar
      refactor: store transient leads in vector · 937110d0
      Roman Gilg authored
      This is a first step to unify normal transient leads and for groups.
    • Roman Gilg's avatar
      refactor: composite transient into Toplevel · 289b78d4
      Roman Gilg authored
      Instead of providing it through the control class directly add a transient
      interface to Toplevel. This way windows without control can still be in
      transient relations.