~azzar1/unity/fix-trash-li-blocking

« back to all changes in this revision

Viewing changes to plugins/unityshell/src/compizminimizedwindowhandler.h

  • Committer: Daniel van Vugt
  • Date: 2012-03-14 06:24:18 UTC
  • mfrom: (2108 unity)
  • mto: This revision was merged to the branch mainline in revision 2146.
  • Revision ID: daniel.van.vugt@canonical.com-20120314062418-nprucpbr0m7qky5e
MergedĀ latestĀ lp:unity

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
#include <core/core.h>
27
27
#include "minimizedwindowhandler.h"
28
28
#include "comptransientfor.h"
 
29
#include <memory>
29
30
 
30
31
// Will be merged back into compiz
31
32
namespace compiz {
67
68
  typedef std::list <Type *> List;
68
69
protected:
69
70
 
70
 
  virtual std::vector<unsigned int> getTransients ();
 
71
  std::vector<unsigned int> getTransients ();
71
72
 
72
73
private:
73
74
 
158
159
    {
159
160
      Window *w = Window::get (win);
160
161
      if (!w->mMinimizeHandler)
161
 
        w->mMinimizeHandler = new Type (win);
 
162
        w->mMinimizeHandler.reset (new Type (win));
162
163
      w->mMinimizeHandler->minimize ();
163
164
    }
164
165
  }
241
242
      if (w && w->mMinimizeHandler)
242
243
      {
243
244
        w->mMinimizeHandler->unminimize ();
244
 
        delete w->mMinimizeHandler;
245
 
        w->mMinimizeHandler = NULL;
 
245
        w->mMinimizeHandler.reset ();
246
246
      }
247
247
    }
248
248
  }
324
324
    if (w)
325
325
    {
326
326
      Window *pw = Window::get (w);
327
 
      Type *compizMinimizeHandler = pw->mMinimizeHandler;
 
327
      Type *compizMinimizeHandler = pw->mMinimizeHandler.get ();
328
328
 
329
329
      /* Restore and re-save input shape and remove */
330
330
      if (compizMinimizeHandler)