Fix uninitialized memory and logic error in PaintRedirector
The refactoring of Compositor starting with b1739c3 caused some regressions due to variables in Workspace and Compositor not being initialized. Furthermore there was a boolean logic error in PaintRedirector causing the decorations not to paint. BUG: 305875
This commit is contained in:
parent
ab1f0bb749
commit
7a1fe42be0
3 changed files with 10 additions and 1 deletions
|
@ -87,7 +87,14 @@ Compositor::Compositor(QObject* workspace)
|
|||
: QObject(workspace)
|
||||
, m_suspended(!options->isUseCompositing())
|
||||
, m_blocked(false)
|
||||
, cm_selection(NULL)
|
||||
, vBlankInterval(0)
|
||||
, fpsInterval(0)
|
||||
, m_xrrRefreshRate(0)
|
||||
, forceUnredirectCheck(false)
|
||||
, m_finishing(false)
|
||||
, m_timeSinceLastVBlank(0)
|
||||
, m_nextFrameDelay(0)
|
||||
, m_scene(NULL)
|
||||
{
|
||||
connect(&unredirectTimer, SIGNAL(timeout()), SLOT(delayedCheckUnredirect()));
|
||||
|
|
|
@ -82,7 +82,7 @@ bool PaintRedirector::eventFilter(QObject* o, QEvent* e)
|
|||
break;
|
||||
}
|
||||
case QEvent::Paint: {
|
||||
if (Workspace::self()->compositingActive()) {
|
||||
if (!Workspace::self()->compositingActive()) {
|
||||
return false;
|
||||
}
|
||||
if (!recursionCheck) {
|
||||
|
|
|
@ -105,6 +105,7 @@ Workspace::Workspace(bool restore)
|
|||
#ifdef KWIN_BUILD_SCREENEDGES
|
||||
, m_screenEdgeOrientation(0)
|
||||
#endif
|
||||
, m_compositor(NULL)
|
||||
// Unsorted
|
||||
, active_popup(NULL)
|
||||
, active_popup_client(NULL)
|
||||
|
@ -482,6 +483,7 @@ void Workspace::init()
|
|||
Workspace::~Workspace()
|
||||
{
|
||||
delete m_compositor;
|
||||
m_compositor = NULL;
|
||||
blockStackingUpdates(true);
|
||||
|
||||
// TODO: grabXServer();
|
||||
|
|
Loading…
Reference in a new issue