Changeset View
Changeset View
Standalone View
Standalone View
effects/showpaint/showpaint.h
Show All 20 Lines | |||||
21 | #ifndef KWIN_SHOWPAINT_H | 21 | #ifndef KWIN_SHOWPAINT_H | ||
22 | #define KWIN_SHOWPAINT_H | 22 | #define KWIN_SHOWPAINT_H | ||
23 | 23 | | |||
24 | #include <kwineffects.h> | 24 | #include <kwineffects.h> | ||
25 | 25 | | |||
26 | namespace KWin | 26 | namespace KWin | ||
27 | { | 27 | { | ||
28 | 28 | | |||
29 | class ShowPaintEffect | 29 | class ShowPaintEffect : public Effect | ||
30 | : public Effect | | |||
31 | { | 30 | { | ||
31 | Q_OBJECT | ||||
32 | | ||||
32 | public: | 33 | public: | ||
33 | ShowPaintEffect(); | 34 | void paintScreen(int mask, QRegion region, ScreenPaintData &data) override; | ||
34 | ~ShowPaintEffect(); | 35 | void paintWindow(EffectWindow *w, int mask, QRegion region, WindowPaintData &data) override; | ||
35 | virtual void paintScreen(int mask, QRegion region, ScreenPaintData& data); | 36 | | ||
36 | virtual void paintWindow(EffectWindow* w, int mask, QRegion region, WindowPaintData& data); | | |||
37 | private: | 37 | private: | ||
38 | void paintGL(const QMatrix4x4 &projection); | 38 | void paintGL(const QMatrix4x4 &projection); | ||
39 | void paintXrender(); | 39 | void paintXrender(); | ||
40 | void paintQPainter(); | 40 | void paintQPainter(); | ||
41 | QRegion painted; // what's painted in one pass | 41 | | ||
42 | int color_index; | 42 | QRegion m_painted; // what's painted in one pass | ||
43 | int m_colorIndex = 0; | ||||
43 | }; | 44 | }; | ||
44 | 45 | | |||
45 | } // namespace | 46 | } // namespace KWin | ||
46 | 47 | | |||
47 | #endif | 48 | #endif |