37 Commits (04ab8554aacb5d39093aeb5fab0849e584b4fe82)

Author SHA1 Message Date
Thomas Lübking c240f7a012 do the hide-is-move dance w/ desktopgrid buttons
the (old) button effect windows used to be unreferenced
with the re-invocation of the effect. because we stopped
deleting/recreating the window, this approach failed and
the effect window was never deleted.

Unreferencing the window at proper occasion (see new hide
location) coked up - guess what - the exact same "texture is
junk" issue as for the QtQuick close button in present windows...

So we resort to the exact same stupid "hide by moving" solution
as we have there.

BUG: 348577
FIXED-IN: 5.4
REVIEW: 124136
9 years ago
Martin Gräßlin 3bbc9436db [kwin] Add a virtual Effect::requestedEffectChainPosition
This method replaces the X-KDE-ORDERING property in the Effect's desktop
files. This change is a preparation step for integrating the new Effect
Loader which doesn't read the ordering information. Thus it needs to be
provided by the Effect itself so that the EffectsHandler can properly
insert it into the chain.

Also for the built-in Effects on the long run it doesn't make much sense
to install the desktop files. And binary plugin effects will migrate to
json metadata which also doesn't have the KService::Ptr. Thus overall it
simplifies to read this information directly from the Effect.
11 years ago
Reza Shah 61f452723e Port KWin effects away from KAction and KShortcut to Qt5/KF5 classes.
REVIEW: 111898
11 years ago
Martin Gräßlin 7bd86505f5 Port add/remove buttons in DesktopGrid to QtQuick 2
With this change we no longer need to link QtDeclarative in the Effects.
11 years ago
Martin Gräßlin 1d2c2d5982 Use Q_SLOTS and Q_SIGNALS instead of slots and signals
Fixes compilation with Qt5/KF5 setup.
11 years ago
Martin Gräßlin 49e734f743 Change the way how effects can get mouse events
With the removal of BoxSwitch all effects which want mouse events use the
fullscreen input window. The available functionality is too complex both
in EffectsHandler and in the Effects.

With this change only fullscreen input windows are supported and all
effects share the input window. This means there is at maximum one input
window. This simplifies the code in the Effects as they don't have to
keep track of the window they created any more. In EffectsHandler it
means that only one window needs to be created, destroyed and raised.
Also it means that we can properly react on screen size changes which had
been ignored in the past. Also quite some roundtrips to X are no longer
needed as we do not need to query the window geometry when creating the
input window.

REVIEW: 110156
12 years ago
Martin Gräßlin fb65c07bf7 Use a QDeclarativeView for button views in Present Windows and Desktop Grid
Declarative UI++

REVIEW: 109409
12 years ago
Martin Gräßlin 32b6ef42b9 Strip module path from all Qt #include <>
Done with:
fixqt4headers.pl --strip-modules

REVIEW: 109176
12 years ago
Martin Gräßlin 334b4bf622 Move handling of Virtual Desktops into a VirtualDesktopManager
The ownership for virtual desktops is moved from Workspace into a new
VirtualDesktopManager. The manager is responsible for providing the count
of virtual desktops and keeping track of the currently used virtual
desktop.

All methods related to moving between desktops are also moved from
Workspace to the new manager, though all methods related to Clients on
Virtual Desktops remain in Workspace for the time being. This is to have
the new manager as independent from KWin core as possible.

An rather important change for the handling of virtual desktops is that
the count and the id of a desktop is now an unsinged integer instead of
an integer. The reason for that is that we cannot have a negative count
of desktops as well as it is not possible to be on a desktop with a
negative identifier.

In that regard it is important to remember that a Client can be on a
desktop with a negative identifier. The special value for a Client being
on all desktops is handled by using -1 as a desktop. For the time being
this is not adjusted but instead of comparing the virtual desktop ids one
should prefer to use the convenient methods like isOnDesktop and
isOnAllDesktops. This would allow in future to internally change the
representation for on all desktops.
12 years ago
Martin Gräßlin 533d57da60 Mark most ctors as explicit as reported by Krazy2 checker 12 years ago
Thomas Lübking 7775510918 fix desktopgrid window manage on VD amount change
BUG: 289747
FIXED-IN: 4.9.2
REVIEW: 106391
12 years ago
Martin Gräßlin 23f2de009b Effects can provide support information through properties
The supportInformation is extended to also read the properties
on all effects. In addition each effect can be queried just for
itself through D-Bus, e.g.:
qdbus org.kde.kwin /KWin supportInformationForEffect kwin4_effect_blur

All effects are extended to provide their configured and read
settings through properties. In some cases also important
runtime information is exposed.

REVIEW: 105977
BUG: 305338
FIXED-IN: 4.9.1
12 years ago
Thomas Lübking 494ffbdfd4 swap desktops in desktopgrid w/o swapping traversed desktops
BUG: 252699
REVIEW: 104247
FIXED-IN: 4.9
13 years ago
Martin Gräßlin 2007a7eab8 Use namespaced parameters in signals
Required to get scripting bindings working.
13 years ago
Martin Gräßlin fe4329a252 Only call active effects in the effect chain
Each effect is able to declare itself as currently being active,
that is transforming windows or painting or screen or doing anything
during the current rendered frame.

This change eliminates the hottest path inside KWin identified by
callgrind.

REVIEW: 102449
13 years ago
Thomas Lübking fa8c6cba51 forward port of a389a45ecaea2577f5162edd1485356c81263cce
prevent accidental desktop swaps

CCBUG: 220088
14 years ago
Martin Gräßlin f213b7da70 Drop KWin::TimeLine from kwineffects
The KWin::TimeLine class was only a small wrapper around QTimeLine
without adding anything to QTimeLine what is not present in QTimeLine.
The initial idea was to make it possible to provide more curve shapes.
This is now obsoleted by Qt shipping more useful curves with QTimeLine.

So let's clean up a little bit and use QTimeLine directly instead of
the small wrapper.

All effects are adjusted to use QTimeLine directly.
14 years ago
Martin Gräßlin 911098ee76 WindowGeometryShapeChanged becomes a signal 14 years ago
Martin Gräßlin 747afb4225 NumberDesktopsChanged becomes a signal
TODO: connect DesktopChangeOSD also to the signal
14 years ago
Martin Gräßlin e355700e6e EffectsHandler emits windowDeleted signal
Workspace emits a deletedRemoved signal which the EffectsHandlerImpl translates
into a windowDeleted signal.
14 years ago
Martin Gräßlin 0b85768ec5 EffectsHandler emits windowClosed signal
Client and Unmanaged use a signal to notify that they are about to be closed.
The EffectsHandlerImpl is connected to those signals and emits the appropriate
windowClosed signal to which the effects are connected.
14 years ago
Martin Gräßlin ab6f2ba1fd EffectsHandler emits windowAdded signal
All previously existing windowAdded methods are renamed to slotWindowAdded.
EffectsHandlerImpl is connected to Workspace's clientAdded signal, which is
emitted a little bit earlier than the previous direct method call. This might
change behavior.
Another signal is added to Workspace to signal that an unmanaged is added.
14 years ago
Martin Gräßlin b3a5639967 EffectsHandler and Effect become QObjects
This is in preparation for allowing to connect effects with signals and slots.
14 years ago
Martin Gräßlin b265537962 Drop dependency to libplasma from kwineffects library
Since the EffectFrames have been moved into KWin core nothing in the
Effects lib actually used Plasma. The only remaining method is moved
to core as it's not used in the Effects. The Effects itself still
link against Plasma, so nothing changes for them.

The Plasma includes in the kwineffects header seemed to pull in
quite some additional headers, so the includes in some effects have
to be adjusted (most often KConfigGroup). This should speed up the
compilation of the library and the effects.
14 years ago
Martin Gräßlin 0a7e48f7aa KWin uses kdelibs coding style. 14 years ago
Thomas Lübking 6356c736f8 catch dangeling pointer in the desktopbutton hash
BUG: 244813

svn path=/trunk/KDE/kdebase/workspace/; revision=1187537
14 years ago
Martin Gräßlin 8f82499f21 Add a plasma based widget to add and remove desktops in desktop grid.
svn path=/trunk/KDE/kdebase/workspace/; revision=1108240
15 years ago
Martin Gräßlin 9a86e83d6e Set the transformed geometry in WindowMotionManager when a window is dropped to a desktop in grid. This way the window does not jump to a random position on mouse release.
svn path=/trunk/KDE/kdebase/workspace/; revision=1104672
15 years ago
Martin Gräßlin 54c264bba0 Rearrange windows when the gemoetry changes in both pw and dg in pw mode.
BUG: 228829

svn path=/trunk/KDE/kdebase/workspace/; revision=1103206
15 years ago
Martin Gräßlin e833c61fc3 Improve moving windows in desktop grid when present windows enabled.
* on drag start rearrange windows in old desktop
 * while moving having window attached to mouse cursor
 * on drop rearrange windows in new desktop

svn path=/trunk/KDE/kdebase/workspace/; revision=1049583
15 years ago
Martin Gräßlin 3859fff0de Desktop Grid uses Present Windows to lay out the windows on a desktop
FEATURE: 165745

svn path=/trunk/KDE/kdebase/workspace/; revision=1049548
15 years ago
Martin Gräßlin e49064c356 Check the dndEventDelay in Desktop Grid so that a click with moving does not move the window but activate the desktop.
BUG: 211041

svn path=/trunk/KDE/kdebase/workspace/; revision=1037445
15 years ago
Thomas Lübking 5522bc2e0e add feature: move (swap) desktops
svn path=/trunk/KDE/kdebase/workspace/; revision=1015448
15 years ago
Martin Gräßlin 69b8e33fce Check for the global shortcut in the effects so that the shortcut actually toggles the effect. This is a workaround needed because the keyboard grab disables the global shortcut.
FEATURE: 156155

svn path=/trunk/KDE/kdebase/workspace/; revision=946787
16 years ago
Martin Gräßlin 92484573f2 Effects can be activated at more than one electric border.
FEATURE: 180548

svn path=/trunk/KDE/kdebase/workspace/; revision=946404
16 years ago
Lucas Murray 1e91a66fd2 Added support for unstyled and frameless EffectFrames. Converted all
effects that display text or boxes to use the class. Minor speed
increase in XRender mode for those effects and a massive increase in
OpenGL mode (Double framerate in present windows in my case).

svn path=/trunk/KDE/kdebase/workspace/; revision=929951
16 years ago
Lucas Murray 846496d2c1 Cleaned up the effects/ directory by moving each individual effect into
its own directory, cleaned up the effect config macros and renamed
"MakeTransparent" to "Translucency" so that it matches its visible name.

svn path=/trunk/KDE/kdebase/workspace/; revision=921749
16 years ago