[prev in list] [next in list] [prev in thread] [next in thread]
List: kwin
Subject: Re: Review Request 108438: Use translucent/dialogs/background elements where possible
From: "Aaron J. Seigo" <aseigo () kde ! org>
Date: 2013-01-21 12:17:43
Message-ID: 2826233.id2JY9V9p3 () freedom
[Download RAW message or body]
[Attachment #2 (multipart/signed)]
On Wednesday, January 16, 2013 20:22:56 Martin Gräßlin wrote:
> I will look into it tomorrow again - maybe Aaron found a solution for KWin
> tells libplasma that we use compositing ;-)
i don't think we can do anything sensible for libplasma1 ...
what we need to be able to do is have the application register how to tell if
compositing is active. in the common case this would use the selection as it
does right now. but for kwin (e.g.) it would override this with its own
tracking.
this can be done a few ways. one would be to create an interface class with a
changed() signal and a bool compositing state property that can be registered
to track compositing, e.g.:
Plasma::Theme::setWindowCompositingTracker(const WindowCompositingTracker
*tracker)
only kwin (and similar) would ever need this. internally, a "standard"
tracking object would be created and used. this would mean no changes to
applications other than kwin.
this feels to me like someting that should live in libkwindowsystem. in which
case, it could even be a single class used by application code (such as
Plasma::Theme) that holds the implementation internally (so as the
implementation changes, or even is deleted, it can fallback to the selection
internally).
then Plasma::Theme and friends could drop all their own tracking of such
things and just use that singleton, which kwin could then register its own
tracking implementation with.
in fact, if there were other window system attributes other than compositing
we wanted to be able to track, we could do them all in one place here. in any
case, a draft API might look like:
CompositingState: a singleton QObject
signal changed(bool isAvailable)
property bool isAvailable
write-only CompositingTracker * (internally: a QWeakPointer)
CompositingTracker:
signal changed(bool isAvailable)
property bool isAvailable
--
Aaron J. Seigo
["signature.asc" (application/pgp-signature)]
_______________________________________________
kwin mailing list
kwin@kde.org
https://mail.kde.org/mailman/listinfo/kwin
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic