Toplevel::setupCompositing returns a boolean value and returns
false in the cases where it has not setup compositing.
This is used by the specialization on Client to not perform the
Client specific setup if Toplevel has not setup.
REVIEW: 104767
Workspace emits a signal when the initialization finished and
interested parties can connect to this signal to perform post
init actions. That is everything that does not have to be
performed to have a completely working Window Manager.
As an example loading the scripts is moved into this post init
phase.
REVIEW: 104580
CompositingPrefs have only be used to get the default
value when reading whether the Compositing Enabled
config option.
But CompositingPrefs always returns true which makes
it useless to create an OpenGL context for this.
REVIEW: 104752
The change to have stacking order containing
Toplevel inestead of Clients (431aad6d6994695e72697fcc3299ec2cb6f0684e)
introduced possible crashers as recognized in:
http://git.reviewboard.kde.org/r/104519/#review12714
This change fixes these issues by adding missing
null pointer checks after casting to Client.
BUG: 298669
FIXED-IN: 4.9.0
REVIEW: 104714
This enables the script wrapper objects to automatically create new
dynamic properties for Client objects so that scripts can register custom
properties.
REVIEW: 104697
Options loading is split into three parts:
* reparse configuration
* loading of non-compositing related options
* loading of composited related options not needing CompositingPrefs
At startup the reparsing of configuration is done through a Thread
to gain a little bit of less waiting.
Before something else accesses the KConfig for the first time we
wait for the thread to finish and perform the other two loading
operations of Options.
The settings depending on CompositingPrefs will only be invoked
if a compositor is going to be needed.
REVIEW: 104562
When the Workspace is shutting down the compositor is torn down
before Clients and Unmanaged are released. This means that there
is no need to create the Deleted windows.
Furthermore creating the Deleted manipulates the stacking_order
while Workspace dtor loops over this list to release all clients.
This may cause crashes.
BUG: 282933
FIXED-IN: 4.9.0
REVIEW: 104690
If workspace is exported as a context property there seem to be
issues with the signals which are not bound to a property of
WorkspaceWrapper.
This problems seems to be fixable by exporting the workspace
property as a global property on the script engine.
As a side-effect this also resolves the issue with the clientList,
so we can drop the hack again.
REVIEW: 104682
TabGroup is not (and should not be) a QObject which
makes it rather useless in scripting. In order to use
window tabs in KWin scripts the methods to interact
with tabs from Client should be used.
REVIEW: 104685
Workspace::addDeleted swaps the Client with the Deleted in the
stacking order. For Unmanaged windows the Deleted is appended
to the stacking order which is the same layer.
When the deleted is closed the window is removed from the stacking
order.
The result is that a deleted window is no longer raised above all
other clients.
REVIEW: 104519
BUG: 158262
FIXED-IN: 4.9.0
The common usage of stacking order is to loop through
the list and find a specific Client. All these usages
still need to find a Client. For that the loops are
adjusted to first cast the Toplevel into a Client and
continue if the current item is no Client.
At the moment all entries in the stacking order should
still be Clients as the Deleted are not yet added.
This allows to copy the layer to the deleted window in order to
keep the deleted window in the same layer.
Additionally a new layer is added for unmanaged windows.
This makes kwin in OpenGL2 mode more coherent with kwin_gles.
Despite some fullscreen effects they should now make the same
(pure) OpenGL calls.
REVIEW: 103804
Use setter when changing a value to ensure that signal gets emitted
and the option dependencies are applied.
Also use the default values as provided by the static getters.
REVIEW: 104561
For each option a static getter is introduced returning the
default value.
Some GL compositing related options do not have a proper default
value but depend on the actual GL driver. Sane default values are
assumed for those options.