Added screenNumber() and addRepaint(QRegion) to effects API
svn path=/trunk/KDE/kdebase/workspace/; revision=822215
This commit is contained in:
parent
0b7a501577
commit
d515abb82c
5 changed files with 22 additions and 0 deletions
|
@ -284,6 +284,13 @@ void Workspace::addRepaint( const QRect& r )
|
||||||
repaints_region += r;
|
repaints_region += r;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Workspace::addRepaint( const QRegion& r )
|
||||||
|
{
|
||||||
|
if( !compositing())
|
||||||
|
return;
|
||||||
|
repaints_region += r;
|
||||||
|
}
|
||||||
|
|
||||||
void Workspace::addRepaintFull()
|
void Workspace::addRepaintFull()
|
||||||
{
|
{
|
||||||
if( !compositing())
|
if( !compositing())
|
||||||
|
|
10
effects.cpp
10
effects.cpp
|
@ -537,6 +537,11 @@ void EffectsHandlerImpl::addRepaint( const QRect& r )
|
||||||
Workspace::self()->addRepaint( r );
|
Workspace::self()->addRepaint( r );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void EffectsHandlerImpl::addRepaint( const QRegion& r )
|
||||||
|
{
|
||||||
|
Workspace::self()->addRepaint( r );
|
||||||
|
}
|
||||||
|
|
||||||
void EffectsHandlerImpl::addRepaint( int x, int y, int w, int h )
|
void EffectsHandlerImpl::addRepaint( int x, int y, int w, int h )
|
||||||
{
|
{
|
||||||
Workspace::self()->addRepaint( x, y, w, h );
|
Workspace::self()->addRepaint( x, y, w, h );
|
||||||
|
@ -552,6 +557,11 @@ int EffectsHandlerImpl::numScreens() const
|
||||||
return Workspace::self()->numScreens();
|
return Workspace::self()->numScreens();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int EffectsHandlerImpl::screenNumber( const QPoint& pos ) const
|
||||||
|
{
|
||||||
|
return Workspace::self()->screenNumber( pos );
|
||||||
|
}
|
||||||
|
|
||||||
QRect EffectsHandlerImpl::clientArea( clientAreaOption opt, int screen, int desktop ) const
|
QRect EffectsHandlerImpl::clientArea( clientAreaOption opt, int screen, int desktop ) const
|
||||||
{
|
{
|
||||||
return Workspace::self()->clientArea( opt, screen, desktop );
|
return Workspace::self()->clientArea( opt, screen, desktop );
|
||||||
|
|
|
@ -85,9 +85,11 @@ class EffectsHandlerImpl : public EffectsHandler
|
||||||
|
|
||||||
virtual void addRepaintFull();
|
virtual void addRepaintFull();
|
||||||
virtual void addRepaint( const QRect& r );
|
virtual void addRepaint( const QRect& r );
|
||||||
|
virtual void addRepaint( const QRegion& r );
|
||||||
virtual void addRepaint( int x, int y, int w, int h );
|
virtual void addRepaint( int x, int y, int w, int h );
|
||||||
virtual int activeScreen() const;
|
virtual int activeScreen() const;
|
||||||
virtual int numScreens() const;
|
virtual int numScreens() const;
|
||||||
|
virtual int screenNumber( const QPoint& pos ) const;
|
||||||
virtual QRect clientArea( clientAreaOption, int screen, int desktop ) const;
|
virtual QRect clientArea( clientAreaOption, int screen, int desktop ) const;
|
||||||
virtual QRect clientArea( clientAreaOption, const EffectWindow* c ) const;
|
virtual QRect clientArea( clientAreaOption, const EffectWindow* c ) const;
|
||||||
virtual QRect clientArea( clientAreaOption, const QPoint& p, int desktop ) const;
|
virtual QRect clientArea( clientAreaOption, const QPoint& p, int desktop ) const;
|
||||||
|
|
|
@ -477,6 +477,7 @@ class KWIN_EXPORT EffectsHandler
|
||||||
virtual QString desktopName( int desktop ) const = 0;
|
virtual QString desktopName( int desktop ) const = 0;
|
||||||
virtual int activeScreen() const = 0; // Xinerama
|
virtual int activeScreen() const = 0; // Xinerama
|
||||||
virtual int numScreens() const = 0; // Xinerama
|
virtual int numScreens() const = 0; // Xinerama
|
||||||
|
virtual int screenNumber( const QPoint& pos ) const = 0; // Xinerama
|
||||||
virtual QRect clientArea( clientAreaOption, int screen, int desktop ) const = 0;
|
virtual QRect clientArea( clientAreaOption, int screen, int desktop ) const = 0;
|
||||||
virtual QRect clientArea( clientAreaOption, const EffectWindow* c ) const = 0;
|
virtual QRect clientArea( clientAreaOption, const EffectWindow* c ) const = 0;
|
||||||
virtual QRect clientArea( clientAreaOption, const QPoint& p, int desktop ) const = 0;
|
virtual QRect clientArea( clientAreaOption, const QPoint& p, int desktop ) const = 0;
|
||||||
|
@ -515,6 +516,7 @@ class KWIN_EXPORT EffectsHandler
|
||||||
**/
|
**/
|
||||||
virtual void addRepaintFull() = 0;
|
virtual void addRepaintFull() = 0;
|
||||||
virtual void addRepaint( const QRect& r ) = 0;
|
virtual void addRepaint( const QRect& r ) = 0;
|
||||||
|
virtual void addRepaint( const QRegion& r ) = 0;
|
||||||
virtual void addRepaint( int x, int y, int w, int h ) = 0;
|
virtual void addRepaint( int x, int y, int w, int h ) = 0;
|
||||||
|
|
||||||
CompositingType compositingType() const;
|
CompositingType compositingType() const;
|
||||||
|
|
|
@ -317,6 +317,7 @@ class Workspace : public QObject, public KDecorationDefines
|
||||||
// when adding repaints caused by a window, you probably want to use
|
// when adding repaints caused by a window, you probably want to use
|
||||||
// either Toplevel::addRepaint() or Toplevel::addWorkspaceRepaint()
|
// either Toplevel::addRepaint() or Toplevel::addWorkspaceRepaint()
|
||||||
void addRepaint( const QRect& r );
|
void addRepaint( const QRect& r );
|
||||||
|
void addRepaint( const QRegion& r );
|
||||||
void addRepaint( int x, int y, int w, int h );
|
void addRepaint( int x, int y, int w, int h );
|
||||||
// creates XComposite overlay window, call initOverlay() afterwards
|
// creates XComposite overlay window, call initOverlay() afterwards
|
||||||
bool createOverlay();
|
bool createOverlay();
|
||||||
|
|
Loading…
Reference in a new issue