Mir
Public Member Functions | List of all members
miral::WorkspacePolicy Class Reference

Advise changes to workspaces. More...

#include <workspace_policy.h>

Inheritance diagram for miral::WorkspacePolicy:
[legend]

Public Member Functions

virtual ~WorkspacePolicy ()=default
 
 WorkspacePolicy ()=default
 
 WorkspacePolicy (WorkspacePolicy const &)=delete
 
WorkspacePolicyoperator= (WorkspacePolicy const &)=delete
 
notification of WM events that the policy may need to track.

These calls happen "under lock" and are wrapped by the usual WindowManagementPolicy::advise_begin(), advise_end() calls.

They should not call WindowManagerTools::invoke_under_lock()

virtual void advise_adding_to_workspace (std::shared_ptr< Workspace > const &workspace, std::vector< Window > const &windows)
 Notification that windows are being added to a workspace. More...
 
virtual void advise_removing_from_workspace (std::shared_ptr< Workspace > const &workspace, std::vector< Window > const &windows)
 Notification that windows are being removed from a workspace. More...
 

Detailed Description

Advise changes to workspaces.

Note
This interface is intended to be implemented by a WindowManagementPolicy implementation, we can't add these functions directly to that interface without breaking ABI (the vtab could be incompatible). When initializing the window manager this interface will be detected by dynamic_cast and registered accordingly.

Constructor & Destructor Documentation

◆ ~WorkspacePolicy()

virtual miral::WorkspacePolicy::~WorkspacePolicy ( )
virtualdefault

◆ WorkspacePolicy() [1/2]

miral::WorkspacePolicy::WorkspacePolicy ( )
default

◆ WorkspacePolicy() [2/2]

miral::WorkspacePolicy::WorkspacePolicy ( WorkspacePolicy const &  )
delete

Member Function Documentation

◆ advise_adding_to_workspace()

virtual void miral::WorkspacePolicy::advise_adding_to_workspace ( std::shared_ptr< Workspace > const &  workspace,
std::vector< Window > const &  windows 
)
virtual

Notification that windows are being added to a workspace.

These windows are ordered with parents before children, and form a single tree rooted at the first element.

Parameters
workspacethe workspace
windowsthe windows

◆ advise_removing_from_workspace()

virtual void miral::WorkspacePolicy::advise_removing_from_workspace ( std::shared_ptr< Workspace > const &  workspace,
std::vector< Window > const &  windows 
)
virtual

Notification that windows are being removed from a workspace.

These windows are ordered with parents before children, and form a single tree rooted at the first element.

Parameters
workspacethe workspace
windowsthe windows

◆ operator=()

WorkspacePolicy& miral::WorkspacePolicy::operator= ( WorkspacePolicy const &  )
delete

The documentation for this class was generated from the following file:

Copyright © 2012-2017 Canonical Ltd.
Generated on Wed Oct 11 15:14:10 UTC 2017