Merge lp:~vanvugt/ubuntu/quantal/compiz/upstream-expo-patch-quantal into lp:ubuntu/quantal-proposed/compiz

Proposed by Daniel van Vugt
Status: Rejected
Rejected by: Martin Pitt
Proposed branch: lp:~vanvugt/ubuntu/quantal/compiz/upstream-expo-patch-quantal
Merge into: lp:ubuntu/quantal-proposed/compiz
Diff against target: 3574 lines (+205/-3009)
3 files modified
debian/patches/100_expo_layout.patch (+0/-2907)
debian/patches/series (+0/-1)
debian/patches/ubuntu-config.patch (+205/-101)
To merge this branch: bzr merge lp:~vanvugt/ubuntu/quantal/compiz/upstream-expo-patch-quantal
Reviewer Review Type Date Requested Status
Didier Roche-Tolomelli Disapprove
Ubuntu branches Pending
Review via email: mp+136606@code.launchpad.net

Commit message

Promote 100_expo_layout.patch to the trunk so we don't have to maintain it
as a patch any more. Dropped some features even Ubuntu never used. The
remaining features merged into plugins/expo are invisible/disabled by default.
ubuntu-config.patch enables them.

Also seems to fix LP: #1059549.

Description of the change

To post a comment you must log in.
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Already reviewed, approved and landed for upstream lp:compiz

We need this in 0.9.8 however if we are to be able to fix any expo bugs during the support life of quantal.

Revision history for this message
Didier Roche-Tolomelli (didrocks) wrote :

Please reject, this is not SRUable

review: Disapprove

Unmerged revisions

3326. By Daniel van Vugt

Promote 100_expo_layout.patch to the trunk so we don't have to maintain it
as a patch any more. Dropped some features even Ubuntu never used. The
remaining features merged into plugins/expo are invisible/disabled by default.
ubuntu-config.patch enables them.

Also seems to fix LP: #1059549.

3325. By Didier Roche-Tolomelli

releasing version 1:0.9.8.4+bzr3412-0ubuntu0.1

3324. By Didier Roche-Tolomelli

releasing version 1:0.9.8.4+bzr3412-0ubuntu1

3323. By Timo Jyrinki

* New upstream snapshot.
  - Avoid duplicate template instantiations of PluginClassHandler<>, at
    least for those plugins that get re-used by others. (LP: #1065815)
  - Don't try to dereference NULL, which is returned by
    ccsGConfIntegratedSettingReadValue when it gets unexpected data
    from gconf. (LP: #1056615)
  - Stop the resize border (Rectangle resize mode) from flickering
    slightly. (LP: #1068518)

3322. By Didier Roche-Tolomelli

releasing version 1:0.9.8.4+bzr3407-0ubuntu1

3321. By Didier Roche-Tolomelli

releasing version 1:0.9.8.4-0ubuntu3

3320. By Didier Roche-Tolomelli

fix as gsettings directly doesn't work

3319. By Didier Roche-Tolomelli

* debian/config, debian/compiz-gnome.migrations,
  debian/00_remove_unityshell_in_gnome_session.py:
  - For new users and users already on quantal before this fix, remove the
    local config file created if you logged in the classic session hiding the
    system one. Also, as the global default is including the unity* plugins,
    remove them from the list of plugins the first time you log in.

3318. By Didier Roche-Tolomelli

* debian/config, :
  - add the default gnome_session profile to use gsettings as the migrated
    user are on this profile (LP: #1036752). The existing migration scripts
    will upgrade the user config.

3317. By Didier Roche-Tolomelli

releasing version 1:0.9.8.4-0ubuntu2

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== removed file 'debian/patches/100_expo_layout.patch'
2--- debian/patches/100_expo_layout.patch 2012-09-13 04:59:17 +0000
3+++ debian/patches/100_expo_layout.patch 1970-01-01 00:00:00 +0000
4@@ -1,2907 +0,0 @@
5-Index: ubuntu/plugins/expo/expo.xml.in
6-===================================================================
7---- ubuntu.orig/plugins/expo/expo.xml.in 2012-09-12 22:20:42.944758828 +0800
8-+++ ubuntu/plugins/expo/expo.xml.in 2012-09-12 22:20:43.240760303 +0800
9-@@ -17,6 +17,7 @@
10- <plugin>wobbly</plugin>
11- <plugin>animation</plugin>
12- <plugin>wallpaper</plugin>
13-+ <plugin>imgpng</plugin>
14- </relation>
15- </deps>
16- <options>
17-@@ -25,7 +26,7 @@
18- <option name="expo_key" type="key">
19- <_short>Expo key</_short>
20- <_long>Engage wall expo mode key binding</_long>
21-- <default>&lt;Super&gt;e</default>
22-+ <default>&lt;Super&gt;s</default>
23- </option>
24- <option name="expo_button" type="button">
25- <_short>Expo button</_short>
26-@@ -35,8 +36,6 @@
27- <option name="expo_edge" type="edge">
28- <_short>Expo edge</_short>
29- <_long>Engage wall expo mode edge binding</_long>
30-- <default>
31-- </default>
32- </option>
33- <option name="double_click_time" type="int">
34- <_short>Double click time</_short>
35-@@ -79,7 +78,7 @@
36- <option name="zoom_time" type="float">
37- <_short>Zoom time</_short>
38- <_long>Duration of the zoomout animation</_long>
39-- <default>0.5</default>
40-+ <default>0.3</default>
41- <min>0.1</min>
42- <max>5.0</max>
43- <precision>0.1</precision>
44-@@ -130,10 +129,24 @@
45- <_name>Curve</_name>
46- </desc>
47- </option>
48-+ <option name="x_offset" type="int">
49-+ <_short>X Space</_short>
50-+ <_long> Left Side screen space of expo in pixels</_long>
51-+ <min>-1680</min>
52-+ <max>1680</max>
53-+ <default>64</default>
54-+ </option>
55-+ <option name="y_offset" type="int">
56-+ <_short>Y Space</_short>
57-+ <_long> Top Side screen space of expo in pixels</_long>
58-+ <min>-100</min>
59-+ <max>100</max>
60-+ <default>24</default>
61-+ </option>
62- <option name="distance" type="float">
63- <_short>Distance</_short>
64- <_long>Distance of the expo wall</_long>
65-- <default>0.0</default>
66-+ <default>0.005</default>
67- <min>0.0</min>
68- <max>1.0</max>
69- <precision>0.01</precision>
70-@@ -141,7 +154,7 @@
71- <option name="vp_distance" type="float">
72- <_short>Viewport distance</_short>
73- <_long>Distance between viewports</_long>
74-- <default>0.10</default>
75-+ <default>0.2</default>
76- <min>0.0</min>
77- <max>1.0</max>
78- <precision>0.01</precision>
79-@@ -192,7 +205,7 @@
80- <option name="vp_brightness" type="float">
81- <_short>Brightness</_short>
82- <_long>Inactive viewport brightness.</_long>
83-- <default>75.0</default>
84-+ <default>40.0</default>
85- <min>0.0</min>
86- <max>100.0</max>
87- <precision>0.1</precision>
88-@@ -200,18 +213,28 @@
89- <option name="vp_saturation" type="float">
90- <_short>Saturation</_short>
91- <_long>Inactive viewport saturation.</_long>
92-- <default>100.0</default>
93-+ <default>40.0</default>
94- <min>0.0</min>
95- <max>100.0</max>
96- <precision>0.1</precision>
97- </option>
98-+ <option name="selected_color" type="color">
99-+ <_short>Selected Color</_short>
100-+ <_long>Color to use when highlighting the selected viewport</_long>
101-+ <default>
102-+ <red>0xfbfb</red>
103-+ <green>0x8b8b</green>
104-+ <blue>0x0</blue>
105-+ <alpha>0xffff</alpha>
106-+ </default>
107-+ </option>
108- </subgroup>
109- <subgroup>
110- <short>Reflection</short>
111- <option name="reflection" type="bool">
112- <_short>Reflection</_short>
113- <_long>Show a reflection of the viewports on the ground</_long>
114-- <default>true</default>
115-+ <default>false</default>
116- </option>
117- <option name="ground_color1" type="color">
118- <_short>Ground color(near)</_short>
119-@@ -244,7 +267,7 @@
120- <option name="scale_factor" type="float">
121- <_short>Reflection Scale</_short>
122- <_long>Scale factor of the expo wall reflection</_long>
123-- <default>0.75</default>
124-+ <default>1.0</default>
125- <min>0.0</min>
126- <max>2.0</max>
127- <precision>0.01</precision>
128-Index: ubuntu/plugins/expo/src/expo.cpp
129-===================================================================
130---- ubuntu.orig/plugins/expo/src/expo.cpp 2012-09-12 22:09:32.323735000 +0800
131-+++ ubuntu/plugins/expo/src/expo.cpp 2012-09-12 22:29:50.643474721 +0800
132-@@ -27,6 +27,8 @@
133-
134- #include "expo.h"
135- #include "click-threshold.h"
136-+#include "wall-offset.h"
137-+#include "windows-on-viewport.h"
138- #include <math.h>
139- #ifndef USE_GLES
140- #include <GL/glu.h>
141-@@ -73,11 +75,10 @@
142-
143- if (dndState == DnDDuring || dndState == DnDStart)
144- {
145-- if (dndWindow)
146-+ if (dndWindows.size ())
147- finishWindowMovement ();
148-
149- dndState = DnDNone;
150-- dndWindow = NULL;
151-
152- action->setState (action->state () & CompAction::StateInitButton);
153- cScreen->damageScreen ();
154-@@ -113,7 +114,6 @@
155- clickTime = 0;
156-
157- dndState = DnDNone;
158-- dndWindow = NULL;
159-
160- selectedVp = screen->vp ();
161- lastSelectedVp = screen->vp ();
162-@@ -156,8 +156,8 @@
163- else
164- vpUpdateMode = VPUpdateMouseOver;
165-
166-- dndState = DnDNone;
167-- dndWindow = NULL;
168-+ dndState = DnDNone;
169-+ dndWindows.clear ();
170-
171- screen->removeAction (&optionGetDndButton ());
172- screen->removeAction (&optionGetExitButton ());
173-@@ -202,6 +202,8 @@
174- if (!expoMode)
175- return false;
176-
177-+ lastSelectedVp = selectedVp;
178-+
179- newX = selectedVp.x () + 1;
180- newY = selectedVp.y ();
181-
182-@@ -225,7 +227,7 @@
183- CompAction::State state,
184- CompOption::Vector& options)
185- {
186-- int newX, newY;
187-+ unsigned int newX, newY;
188- Window xid = CompOption::getIntOptionNamed (options, "root", 0);
189- if (xid != screen->root ())
190- return false;
191-@@ -272,53 +274,39 @@
192- void
193- ExpoScreen::finishWindowMovement ()
194- {
195-- dndWindow->syncPosition ();
196-- dndWindow->ungrabNotify ();
197--
198-- screen->moveViewport (screen->vp ().x () - selectedVp.x (),
199-- screen->vp ().y () - selectedVp.y (), true);
200--
201-- /* update saved window attributes in case we moved the
202-- window to a new viewport */
203-- if (dndWindow->saveMask () & CWX)
204-- {
205-- dndWindow->saveWc ().x = dndWindow->saveWc ().x % screen->width ();
206-- if (dndWindow->saveWc ().x < 0)
207-- dndWindow->saveWc ().x += screen->width ();
208-- }
209-- if (dndWindow->saveMask () & CWY)
210-+ foreach (CompWindow *dndWindow, dndWindows)
211- {
212-- dndWindow->saveWc ().y = dndWindow->saveWc ().y % screen->height ();
213-- if (dndWindow->saveWc ().y < 0)
214-- dndWindow->saveWc ().y += screen->height ();
215-- }
216--
217-- /* update window attibutes to make sure a moved maximized window
218-- is properly snapped to the work area */
219-- if (dndWindow->state () & MAXIMIZE_STATE)
220-- dndWindow->updateAttributes (CompStackingUpdateModeNone);
221--
222--#if 0 /* FIXME: obsolete in the meantime? */
223-- {
224-- int lastOutput;
225-- int centerX, centerY;
226-+ if (dndWindow->grabbed ())
227-+ {
228-+ dndWindow->syncPosition ();
229-+ dndWindow->ungrabNotify ();
230-
231-- /* make sure we snap to the correct output */
232-- lastOutput = s->currentOutputDev;
233-- centerX = (WIN_X (w) + WIN_W (w) / 2) % s->width;
234-- if (centerX < 0)
235-- centerX += s->width;
236-- centerY = (WIN_Y (w) + WIN_H (w) / 2) % s->height;
237-- if (centerY < 0)
238-- centerY += s->height;
239-+ screen->updateGrab (grabIndex, None);
240-
241-- s->currentOutputDev = outputDeviceForPoint (s, centerX, centerY);
242-+ screen->moveViewport (screen->vp ().x () - selectedVp.x (),
243-+ screen->vp ().y () - selectedVp.y (), true);
244-
245-- updateWindowAttributes (w, CompStackingUpdateModeNone);
246-+ /* update saved window attributes in case we moved the
247-+ window to a new viewport */
248-+ if (dndWindow->saveMask () & CWX)
249-+ {
250-+ dndWindow->saveWc ().x = dndWindow->saveWc ().x % screen->width ();
251-+ if (dndWindow->saveWc ().x < 0)
252-+ dndWindow->saveWc ().x += screen->width ();
253-+ }
254-+ if (dndWindow->saveMask () & CWY)
255-+ {
256-+ dndWindow->saveWc ().y = dndWindow->saveWc ().y % screen->height ();
257-+ if (dndWindow->saveWc ().y < 0)
258-+ dndWindow->saveWc ().y += screen->height ();
259-+ }
260-
261-- s->currentOutputDev = lastOutput;
262-+ /* update window attibutes to make sure a moved maximized window
263-+ is properly snapped to the work area */
264-+ if (dndWindow->state () & MAXIMIZE_STATE)
265-+ dndWindow->updateAttributes (CompStackingUpdateModeNone);
266-+ }
267- }
268--#endif
269- }
270-
271- void
272-@@ -402,6 +390,80 @@
273- screen->handleEvent (event);
274- }
275-
276-+bool
277-+ExpoWindow::dragged () const
278-+{
279-+ ExpoScreen *es = ExpoScreen::get (screen);
280-+
281-+ return std::find (es->dndWindows.begin (), es->dndWindows.end (), window) != es->dndWindows.end ();
282-+}
283-+
284-+const compiz::window::Geometry &
285-+ExpoWindow::absoluteGeometry () const
286-+{
287-+ const compiz::window::Geometry &relativeGeometry (window->geometry ());
288-+ mAbsoluteGeometry.set ((screen->vp ().x () * screen->width ()) + relativeGeometry.x (),
289-+ (screen->vp ().y () * screen->height ()) + relativeGeometry.y (),
290-+ relativeGeometry.width (),
291-+ relativeGeometry.height (),
292-+ relativeGeometry.border ());
293-+
294-+ return mAbsoluteGeometry;
295-+}
296-+
297-+bool
298-+ExpoWindow::isDesktopOrDock () const
299-+{
300-+ return window->type () == CompWindowTypeDesktopMask ||
301-+ window->type () == CompWindowTypeDockMask;
302-+}
303-+
304-+namespace cei = compiz::expo::impl;
305-+
306-+cei::CompizClientListGenerator::CompizClientListGenerator (CompScreen *screen) :
307-+ mScreen (screen),
308-+ mClientList (&mScreen->clientList (true)),
309-+ mClientListIterator (mClientList->begin ())
310-+{
311-+}
312-+
313-+compiz::expo::ViewportMemberWindow *
314-+cei::CompizClientListGenerator::nextClient ()
315-+{
316-+ if (mClientListIterator == mClientList->end ())
317-+ return NULL;
318-+
319-+ compiz::expo::ViewportMemberWindow *vpMemberWindow = ExpoWindow::get (*mClientListIterator);
320-+
321-+ ++mClientListIterator;
322-+
323-+ return vpMemberWindow;
324-+}
325-+
326-+bool
327-+ExpoScreen::windowsOnVp (compiz::expo::ClientListGenerator &clientList,
328-+ CompPoint &p,
329-+ const CompPoint &unprojectedCursor,
330-+ const CompSize &screenSize,
331-+ CompScreen *screen)
332-+{
333-+ return false;
334-+}
335-+
336-+namespace
337-+{
338-+ void fillInNewViewportActivityData (unsigned int vpCount,
339-+ std::vector <float> &vpActivity)
340-+ {
341-+ if (vpActivity.size () < vpCount)
342-+ {
343-+ vpActivity.resize (vpCount);
344-+ foreach (float& activity, vpActivity)
345-+ activity = 1.0f;
346-+ }
347-+ }
348-+}
349-+
350- void
351- ExpoScreen::preparePaint (int msSinceLastPaint)
352- {
353-@@ -412,33 +474,43 @@
354- else
355- expoCam = MAX (0.0, expoCam - val);
356-
357-- if (expoCam)
358-+ if (dndState == DnDDuring)
359- {
360-- unsigned int i, j, vp;
361-- unsigned int vpCount = screen->vpSize ().width () *
362-- screen->vpSize ().height ();
363-+ foreach (CompWindow *w, dndWindows)
364-+ ExpoWindow::get (w)->dndOpacity = MIN (1.0, ExpoWindow::get (w)->dndOpacity + val);
365-+ }
366-+ else if (dndState == DnDNone)
367-+ {
368-+ CompWindowList::iterator it = dndWindows.begin ();
369-
370-- if (vpActivity.size () < vpCount)
371-+ while (it != dndWindows.end ())
372- {
373-- vpActivity.resize (vpCount);
374-- foreach (float& activity, vpActivity)
375-- activity = 1.0f;
376-- }
377-+ ExpoWindow::get ((*it))->dndOpacity = MAX (0.0, ExpoWindow::get ((*it))->dndOpacity - val);
378-
379-- for (i = 0; i < (unsigned int) screen->vpSize ().width (); i++)
380-- {
381-- for (j = 0; j < (unsigned int) screen->vpSize ().height (); j++)
382-+ if (ExpoWindow::get ((*it))->dndOpacity <= 0.0f)
383- {
384-- vp = (j * screen->vpSize ().width ()) + i;
385--
386-- if (CompPoint (i, j) == selectedVp)
387-- vpActivity[vp] = MIN (1.0, vpActivity[vp] + val);
388-- else
389-- vpActivity[vp] = MAX (0.0, vpActivity[vp] - val);
390-+ dndWindows.erase (it);
391-+ it = dndWindows.begin ();
392- }
393-+ else
394-+ it++;
395- }
396-+ }
397-
398-- for (i = 0; i < 360; i++)
399-+ if (expoCam)
400-+ {
401-+ unsigned int vpCount = compiz::expo::countViewports (screen->vpSize ());
402-+
403-+ fillInNewViewportActivityData (vpCount, vpActivity);
404-+ compiz::expo::fillInNewViewportActiveData (vpCount, vpActive);
405-+
406-+ for (unsigned int i = 0; i < vpCount; i++)
407-+ if (vpActive[i])
408-+ vpActivity[i] = MIN (1.0, vpActivity[i] + val);
409-+ else
410-+ vpActivity[i] = MAX (0.0, vpActivity[i] - val);
411-+
412-+ for (int i = 0; i < 360; i++)
413- {
414- float fi = (float) i;
415-
416-@@ -509,6 +581,31 @@
417- cScreen->paint (outputs, mask);
418- }
419-
420-+namespace
421-+{
422-+ void updateViewportActiveStates (CompScreen *screen)
423-+ {
424-+ ExpoScreen *es = ExpoScreen::get (screen);
425-+
426-+ unsigned int vpCount = compiz::expo::countViewports (screen->vpSize ());
427-+ fillInNewViewportActivityData (vpCount, es->vpActivity);
428-+
429-+ for (int i = 0; i < screen->vpSize ().width (); i++)
430-+ {
431-+ for (int j = 0; j < screen->vpSize ().height (); j++)
432-+ {
433-+ compiz::expo::impl::CompizClientListGenerator clientList (screen);
434-+
435-+ compiz::expo::activeViewportsForMembers (clientList,
436-+ es->newCursor,
437-+ screen->vpSize (),
438-+ *screen,
439-+ es->vpActive);
440-+ }
441-+ }
442-+ }
443-+}
444-+
445- void
446- ExpoScreen::donePaint ()
447- {
448-@@ -539,6 +636,11 @@
449- foreach (float& vp, vpActivity)
450- if (vp != 0.0 && vp != 1.0)
451- cScreen->damageScreen ();
452-+
453-+ foreach (CompWindow *w, dndWindows)
454-+ if (ExpoWindow::get (w)->dndOpacity != 0.0f &&
455-+ ExpoWindow::get (w)->dndOpacity != 1.0f)
456-+ cScreen->damageScreen ();
457- }
458-
459- if (grabIndex && expoCam <= 0.0f && !expoMode)
460-@@ -553,10 +655,25 @@
461- switch (dndState) {
462- case DnDDuring:
463- {
464-- if (dndWindow)
465-- dndWindow->move (newCursor.x () - prevCursor.x (),
466-- newCursor.y () - prevCursor.y (),
467-- optionGetExpoImmediateMove ());
468-+ if (dndWindows.size ())
469-+ {
470-+ foreach (CompWindow *dndWindow, dndWindows)
471-+ {
472-+ if (dndWindow->grabbed ())
473-+ {
474-+ ExpoWindow *ew = ExpoWindow::get (dndWindow);
475-+
476-+ /* No need to update twice */
477-+ dndWindow->moveNotifySetEnabled (ew, false);
478-+ dndWindow->move (newCursor.x () - prevCursor.x (),
479-+ newCursor.y () - prevCursor.y (),
480-+ optionGetExpoImmediateMove ());
481-+ dndWindow->moveNotifySetEnabled (ew, true);
482-+
483-+ updateViewportActiveStates (screen);
484-+ }
485-+ }
486-+ }
487-
488- prevCursor = newCursor;
489- cScreen->damageScreen ();
490-@@ -621,13 +738,13 @@
491- break;
492-
493- dndState = DnDDuring;
494-- dndWindow = w;
495-+ dndWindows.push_back (w);
496-
497- w->grabNotify (nx, ny, 0,
498- CompWindowGrabMoveMask |
499- CompWindowGrabButtonMask);
500-
501-- screen->updateGrab (grabIndex, dragCursor);
502-+ screen->updateGrab (grabIndex, mMoveCursor);
503-
504- w->raise ();
505- w->moveInputFocusTo ();
506-@@ -762,6 +879,124 @@
507- }
508-
509- void
510-+ExpoScreen::paintViewport (const GLScreenPaintAttrib& attrib,
511-+ const GLMatrix& transform,
512-+ const CompRegion& region,
513-+ CompOutput *output,
514-+ unsigned int mask,
515-+ CompPoint vpPos,
516-+ GLVector &vpCamPos,
517-+ bool reflection)
518-+{
519-+ GLMatrix sTransform (transform);
520-+ GLMatrix sTransform2, sTransform3;
521-+ float sx = (float) screen->width () / output->width ();
522-+ float sy = (float) screen->height () / output->height ();
523-+ float vpp;
524-+ float progress = sigmoidProgress (expoCam);
525-+ unsigned int vp;
526-+ CompPoint vpSize (screen->vpSize ().width (), screen->vpSize ().height ());
527-+
528-+ const float gapY = optionGetVpDistance () * 0.1f * expoCam;
529-+ const float gapX = optionGetVpDistance () * 0.1f * screen->height () /
530-+ screen->width () * expoCam;
531-+
532-+ /* not sure this will work with different resolutions */
533-+ sTransform.translate (0.0, MAX (0, vpPos.y ()) * -(sy + gapY), 0.0f);
534-+
535-+ sTransform2 = sTransform;
536-+
537-+ /* not sure this will work with different resolutions */
538-+ if (optionGetDeform () != DeformCurve)
539-+ sTransform2.translate (MAX (0, vpPos.x ()) * (sx + gapX), 0.0f, 0.0);
540-+
541-+
542-+ if (optionGetExpoAnimation () == ExpoAnimationVortex)
543-+ sTransform2.rotate (360 * expoCam,
544-+ 0.0f, 1.0f, 2.0f * expoCam);
545-+
546-+ sTransform3 = sTransform2;
547-+
548-+ sTransform3.translate (output->x () / output->width (),
549-+ -output->y () / output->height (), 0.0);
550-+
551-+ cScreen->setWindowPaintOffset ((screen->vp ().x () - vpPos.x ()) *
552-+ screen->width (),
553-+ (screen->vp ().y () - vpPos.y ()) *
554-+ screen->height ());
555-+
556-+ vp = (vpPos.y () * vpSize.x ()) + vpPos.x ();
557-+
558-+ vpp = (expoCam * vpActivity[vp]) + (1 - expoCam);
559-+ vpp = sigmoidProgress (vpp);
560-+
561-+ vpBrightness = vpp + ((1.0 - vpp) *
562-+ optionGetVpBrightness () / 100.0);
563-+ vpSaturation = vpp + ((1.0 - vpp) *
564-+ optionGetVpSaturation () / 100.0);
565-+
566-+ paintingVp = vpPos;
567-+
568-+ if (optionGetDeform () == DeformCurve)
569-+ {
570-+ float rotateX;
571-+
572-+ sTransform3.translate (-vpCamPos[GLVector::x], 0.0f,
573-+ curveDistance - DEFAULT_Z_CAMERA);
574-+
575-+ rotateX = -vpPos.x () + interpolate (((float) vpSize.x () / 2.0) - 0.5,
576-+ screen->vp ().x (), progress);
577-+
578-+ sTransform3.rotate (curveAngle * rotateX, 0.0, 1.0, 0.0);
579-+
580-+ sTransform3.translate (vpCamPos[GLVector::x], 0.0f,
581-+ DEFAULT_Z_CAMERA - curveDistance);
582-+ }
583-+
584-+ if (paintingDndWindow)
585-+ cScreen->getWindowPaintListSetEnabled (this, true);
586-+ gScreen->glPaintTransformedOutput (attrib, sTransform3,
587-+ screen->region (), output,
588-+ mask);
589-+
590-+ if (paintingDndWindow)
591-+ cScreen->getWindowPaintListSetEnabled (this, false);
592-+
593-+ if (!reflection && !paintingDndWindow)
594-+ {
595-+ int cursor[2] = { pointerX, pointerY };
596-+
597-+ invertTransformedVertex (attrib, sTransform3,
598-+ output, cursor);
599-+
600-+ if ((cursor[0] > 0) && (cursor[0] < (int) screen->width ()) &&
601-+ (cursor[1] > 0) && (cursor[1] < (int) screen->height ()))
602-+ {
603-+ newCursor.setX (vpPos.x () * screen->width () + cursor[0]);
604-+ newCursor.setY (vpPos.y () * screen->height () + cursor[1]);
605-+
606-+ if (anyClick || dndState != DnDNone)
607-+ {
608-+ /* Used to save last viewport interaction was in */
609-+ selectedVp = vpPos;
610-+ anyClick = false;
611-+ }
612-+ }
613-+ }
614-+
615-+ /* Calculate the current viewport size */
616-+ int tl[2] = { 0, 0 };
617-+ int br[2] = { screen->width (), screen->height () };
618-+
619-+ invertTransformedVertex (attrib, sTransform3, output, tl);
620-+ invertTransformedVertex (attrib, sTransform3, output, br);
621-+
622-+ viewport_size = CompSize (br[0] - tl[0], br[1] - tl[1]);
623-+
624-+ cScreen->setWindowPaintOffset (0, 0);
625-+}
626-+
627-+void
628- ExpoScreen::paintWall (const GLScreenPaintAttrib& attrib,
629- const GLMatrix& transform,
630- const CompRegion& region,
631-@@ -772,13 +1007,11 @@
632- GLfloat vertexData[12];
633- GLushort colorData[16];
634- GLMatrix sTransformW, sTransform (transform);
635-- int i, j, vp;
636- GLenum oldFilter = gScreen->textureFilter ();
637--
638-- float sx = (float) screen->width () / output->width ();
639-- float sy = (float) screen->height () / output->height ();
640-+ float sx = (float) screen->width () / output->width ();
641-+ float sy = (float) screen->height () / output->height ();
642- float biasZ;
643-- float oScale, rotation = 0.0f, progress, vpp;
644-+ float oScale, rotation = 0.0f, progress;
645- float aspectX = 1.0f, aspectY = 1.0f;
646- GLVector cam;
647- CompPoint vpSize (screen->vpSize ().width (), screen->vpSize ().height ());
648-@@ -910,9 +1143,24 @@
649- sTransform.rotate (rotation, 0.0f, 1.0f, 0.0f);
650- sTransform.scale (aspectX, aspectY, 1.0);
651-
652-+ CompPoint offsetInScreenCoords (optionGetXOffset (),
653-+ optionGetYOffset ());
654-+ float offsetInWorldCoordX, offsetInWorldCoordY, worldScaleFactorX, worldScaleFactorY;
655-+
656-+ compiz::expo::calculateWallOffset (*output,
657-+ offsetInScreenCoords,
658-+ vpSize,
659-+ *screen,
660-+ offsetInWorldCoordX,
661-+ offsetInWorldCoordY,
662-+ worldScaleFactorX,
663-+ worldScaleFactorY,
664-+ sigmoidProgress (expoCam));
665-+
666- /* translate expo to center */
667-- sTransform.translate (vpSize.x () * sx * -0.5,
668-- vpSize.y () * sy * 0.5, 0.0f);
669-+ sTransform.translate (vpSize.x () * sx * -0.5 + offsetInWorldCoordX,
670-+ vpSize.y () * sy * 0.5 - offsetInWorldCoordY, 0.0f);
671-+ sTransform.scale (worldScaleFactorX, worldScaleFactorY, 1.0f);
672-
673- if (optionGetDeform () == DeformCurve)
674- sTransform.translate ((vpSize.x () - 1) * sx * 0.5, 0.0, 0.0);
675-@@ -936,90 +1184,29 @@
676-
677- expoActive = true;
678-
679-- for (j = 0; j < vpSize.y (); j++)
680-- {
681-- GLMatrix sTransform2 (sTransform), sTransform3;
682--
683-- for (i = 0; i < vpSize.x (); i++)
684-- {
685-- if (optionGetExpoAnimation () == ExpoAnimationVortex)
686-- sTransform2.rotate (360 * expoCam,
687-- 0.0f, 1.0f, 2.0f * expoCam);
688--
689-- sTransform3 = sTransform2;
690--
691-- sTransform3.translate (output->x () / output->width (),
692-- -output->y () / output->height (), 0.0);
693--
694-- cScreen->setWindowPaintOffset ((screen->vp ().x () - i) *
695-- screen->width (),
696-- (screen->vp ().y () - j) *
697-- screen->height ());
698--
699-- vp = (j * vpSize.x ()) + i;
700--
701-- vpp = (expoCam * vpActivity[vp]) + (1 - expoCam);
702-- vpp = sigmoidProgress (vpp);
703--
704-- vpBrightness = vpp + ((1.0 - vpp) *
705-- optionGetVpBrightness () / 100.0);
706-- vpSaturation = vpp + ((1.0 - vpp) *
707-- optionGetVpSaturation () / 100.0);
708-+ for (int j = 0; j < screen->vpSize ().height (); j++)
709-+ for (int i = 0; i < screen->vpSize().width (); i++)
710-+ paintViewport (attrib, sTransform, region, output, mask, CompPoint (i, j), vpCamPos, reflection);
711-
712-- paintingVp.set (i, j);
713-+ paintingDndWindow = true;
714-
715-- if (optionGetDeform () == DeformCurve)
716-- {
717-- float rotateX;
718--
719-- sTransform3.translate (-vpCamPos[GLVector::x], 0.0f,
720-- curveDistance - DEFAULT_Z_CAMERA);
721--
722-- rotateX = -i + interpolate (((float) vpSize.x () / 2.0) - 0.5,
723-- screen->vp ().x (), progress);
724--
725-- sTransform3.rotate (curveAngle * rotateX, 0.0, 1.0, 0.0);
726--
727-- sTransform3.translate (vpCamPos[GLVector::x], 0.0f,
728-- DEFAULT_Z_CAMERA - curveDistance);
729-- }
730--
731-- gScreen->glPaintTransformedOutput (attrib, sTransform3,
732-- screen->region (), output,
733-- mask);
734--
735-- if (!reflection)
736-- {
737-- int cursor[2] = { pointerX, pointerY };
738-+ foreach (CompWindow *dndWindow, dndWindows)
739-+ {
740-+ CompPoint vp;
741-
742-- invertTransformedVertex (attrib, sTransform3,
743-- output, cursor);
744-+ screen->viewportForGeometry (dndWindow->geometry (), vp);
745-
746-- if ((cursor[0] > 0) && (cursor[0] < (int) screen->width ()) &&
747-- (cursor[1] > 0) && (cursor[1] < (int) screen->height ()))
748-- {
749-- newCursor.setX (i * screen->width () + cursor[0]);
750-- newCursor.setY (j * screen->height () + cursor[1]);
751-+ while (vp.x () < 0)
752-+ vp.setX (screen->vpSize ().width () + vp.x ());
753-
754-- if (anyClick || dndState != DnDNone)
755-- {
756-- /* Used to save last viewport interaction was in */
757-- lastSelectedVp = selectedVp;
758-- selectedVp.set (i, j);
759-- anyClick = false;
760-- }
761-- }
762-- }
763-+ while (vp.y () < 0)
764-+ vp.setY (screen->vpSize ().height () + vp.y ());
765-
766-- /* not sure this will work with different resolutions */
767-- if (optionGetDeform () != DeformCurve)
768-- sTransform2.translate (sx + gapX, 0.0f, 0.0);
769-- }
770--
771-- /* not sure this will work with different resolutions */
772-- sTransform.translate (0.0, -(sy + gapY), 0.0f);
773-+ paintViewport (attrib, sTransform, infiniteRegion, output, mask, vp, vpCamPos, reflection);
774- }
775-
776-+ paintingDndWindow = false;
777-+
778- // glNormal3f (0.0, 0.0, -1.0);
779-
780- if (reflection)
781-@@ -1187,12 +1374,16 @@
782-
783- expoActive = false;
784-
785-- cScreen->setWindowPaintOffset (0, 0);
786--
787- gScreen->glPaintTransformedOutputSetCurrentIndex (glPaintTransformedOutputIndex);
788- gScreen->setTextureFilter (oldFilter);
789- }
790-
791-+const CompWindowList &
792-+ExpoScreen::getWindowPaintList ()
793-+{
794-+ return dndWindows;
795-+}
796-+
797- bool
798- ExpoScreen::glPaintOutput (const GLScreenPaintAttrib& attrib,
799- const GLMatrix& transform,
800-@@ -1243,10 +1434,15 @@
801-
802- bool
803- ExpoWindow::glDraw (const GLMatrix& transform,
804-- const GLWindowPaintAttrib &attrib,
805-+ const GLWindowPaintAttrib &attrib,
806- const CompRegion& region,
807- unsigned int mask)
808- {
809-+ GLMatrix wTransform (transform);
810-+ CompPoint vp;
811-+
812-+ screen->viewportForGeometry (window->geometry (), vp);
813-+
814- if (eScreen->expoCam == 0.0f)
815- return gWindow->glDraw (transform, attrib, region, mask);
816-
817-@@ -1275,8 +1471,11 @@
818- }
819- }
820-
821-- eAttrib.brightness = attrib.brightness * eScreen->vpBrightness;
822-- eAttrib.saturation = attrib.saturation * eScreen->vpSaturation;
823-+ if ((vp == eScreen->paintingVp || window->onAllViewports ()) && !eScreen->paintingDndWindow)
824-+ {
825-+ eAttrib.brightness = attrib.brightness * eScreen->vpBrightness;
826-+ eAttrib.saturation = attrib.saturation * eScreen->vpSaturation;
827-+ }
828- }
829- else
830- {
831-@@ -1287,7 +1486,79 @@
832- (1 - sigmoidProgress (eScreen->expoCam));
833- }
834-
835-- return gWindow->glDraw (transform, eAttrib, region, mask);
836-+ bool status = gWindow->glDraw (transform, eAttrib, region, mask);
837-+
838-+ if (window->type () & CompWindowTypeDesktopMask)
839-+ {
840-+ /* We want to set the geometry of the polka dots to the window
841-+ * region */
842-+ CompRegion reg = CompRegion (0, 0, window->width (), window->height ());
843-+
844-+ foreach(GLTexture * tex, eScreen->polkadots_texture)
845-+ {
846-+ GLTexture::MatrixList matl;
847-+ GLTexture::Matrix mat = tex->matrix();
848-+ CompRegion paintRegion(region);
849-+
850-+ float xScale = screen->width () / (float) eScreen->viewport_size.width ();
851-+ float yScale = screen->height () / (float) eScreen->viewport_size.height ();
852-+
853-+ mat.xx *= xScale;
854-+ mat.yy *= yScale;
855-+
856-+ /* Not sure what this does, but it is necessary
857-+ * (adjusts for scale?) */
858-+ mat.x0 -= mat.xx * reg.boundingRect().x1();
859-+ mat.y0 -= mat.yy * reg.boundingRect().y1();
860-+
861-+ matl.push_back(mat);
862-+
863-+ if (mask & PAINT_WINDOW_TRANSFORMED_MASK)
864-+ paintRegion = infiniteRegion;
865-+
866-+ /* Now allow plugins to mess with the geometry of our
867-+ * dim (so we get a nice render for things like
868-+ * wobbly etc etc */
869-+ gWindow->vertexBuffer ()->begin ();
870-+ gWindow->glAddGeometry (matl, reg, paintRegion);
871-+ if (gWindow->vertexBuffer ()->end ())
872-+ {
873-+ unsigned int glDrawTextureIndex = gWindow->glDrawTextureGetCurrentIndex ();
874-+ eAttrib.opacity = attrib.opacity * (((1.0 - eScreen->vpBrightness) + (1.0 - eScreen->vpSaturation) / 2.0));
875-+ /* Texture rendering set-up */
876-+ //eScreen->gScreen->setTexEnvMode(GL_MODULATE);
877-+ glBlendFunc (GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
878-+ /* Draw the dim texture with all of it's modified
879-+ * geometry glory */
880-+ gWindow->glDrawTextureSetCurrentIndex (MAXSHORT);
881-+ gWindow->glDrawTexture (tex, transform, eAttrib, mask |
882-+ PAINT_WINDOW_BLEND_MASK |
883-+ PAINT_WINDOW_TRANSLUCENT_MASK |
884-+ PAINT_WINDOW_TRANSFORMED_MASK);
885-+ gWindow->glDrawTextureSetCurrentIndex (glDrawTextureIndex);
886-+ /* Texture rendering tear-down */
887-+ glBlendFunc (GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
888-+ eScreen->gScreen->setTexEnvMode (GL_REPLACE);
889-+ }
890-+ }
891-+
892-+ /* Paint the outline */
893-+ if (mGlowQuads && eScreen->paintingVp == eScreen->selectedVp)
894-+ {
895-+ if (region.numRects ())
896-+ {
897-+ /* reset geometry and paint */
898-+ gWindow->vertexBuffer ()->begin ();
899-+ gWindow->vertexBuffer ()->end ();
900-+
901-+ paintGlow (transform, attrib, infiniteRegion, mask);
902-+ }
903-+ }
904-+
905-+ }
906-+
907-+ return status;
908-+
909- }
910-
911- #define EXPO_GRID_SIZE 100
912-@@ -1425,11 +1696,17 @@
913- const CompRegion& region,
914- unsigned int mask)
915- {
916-+ GLMatrix wTransform (transform);
917-+ GLWindowPaintAttrib wAttrib (attrib);
918-+ CompRegion clip (region);
919-+
920- if (eScreen->expoActive)
921- {
922- float opacity = 1.0;
923- bool hide;
924- bool zoomAnim;
925-+ CompPoint vp;
926-+ screen->viewportForGeometry (window->geometry (), vp);
927-
928- zoomAnim = eScreen->optionGetExpoAnimation () ==
929- ExpoScreen::ExpoAnimationZoom;
930-@@ -1458,9 +1735,47 @@
931-
932- if (opacity <= 0)
933- mask |= PAINT_WINDOW_NO_CORE_INSTANCE_MASK;
934-+ else
935-+ wAttrib.opacity = wAttrib.opacity * opacity;
936-+
937-+ /* Stretch maximized windows a little so that you don't
938-+ * have an awkward gap */
939-+
940-+ if (window->state () & MAXIMIZE_STATE &&
941-+ !window->border ().top)
942-+ {
943-+ CompOutput *o = &screen->outputDevs ()[screen->outputDeviceForGeometry(window->geometry())];
944-+ float yS = 1.0 + ((o->height () / (float) window->height ()) - 1.0f) * sigmoidProgress (eScreen->expoCam);
945-+ float xS = 1.0 + ((o->width () / (float) window->width ()) - 1.0f) * sigmoidProgress (eScreen->expoCam);
946-+ wTransform.translate (window->x () + window->width (),
947-+ window->y () + window->height (),
948-+ 0.0f);
949-+ wTransform.scale (xS, yS, 1.0f);
950-+ wTransform.translate (-(window->x () + window->width ()),
951-+ -(window->y () + window->height ()),
952-+ 0.0f);
953-+
954-+ if (eScreen->paintingVp != vp)
955-+ mask |= PAINT_WINDOW_NO_CORE_INSTANCE_MASK;
956-+
957-+ mask |= PAINT_WINDOW_TRANSFORMED_MASK;
958-+ }
959-+
960-+ if (std::find (eScreen->dndWindows.begin(), eScreen->dndWindows.end (), window) != eScreen->dndWindows.end ())
961-+ {
962-+ if (!eScreen->paintingDndWindow)
963-+ {
964-+ mask |= PAINT_WINDOW_NO_CORE_INSTANCE_MASK;
965-+ }
966-+ else
967-+ {
968-+ mask |= PAINT_WINDOW_TRANSFORMED_MASK;
969-+ clip = infiniteRegion;
970-+ }
971-+ }
972- }
973-
974-- return gWindow->glPaint (attrib, transform, region, mask);
975-+ return gWindow->glPaint (wAttrib, wTransform, clip, mask);
976- }
977-
978- bool
979-@@ -1489,7 +1804,7 @@
980- expoActive (false),
981- expoMode (false),
982- dndState (DnDNone),
983-- dndWindow (NULL),
984-+ dndWindows (0),
985- origVp (s->vp ()),
986- selectedVp (s->vp ()),
987- lastSelectedVp (s->vp ()),
988-@@ -1497,14 +1812,21 @@
989- clickTime (0),
990- doubleClick (false),
991- vpNormals (360 * 3),
992-- grabIndex (0)
993--{
994-+ grabIndex (0),
995-+ paintingDndWindow (false),
996-+ mGlowTextureProperties (&glowTextureProperties)
997-+{
998-+ CompString fname;
999-+ CompString pname = "expo";
1000-+ CompSize size;
1001-+
1002-+
1003- leftKey = XKeysymToKeycode (s->dpy (), XStringToKeysym ("Left"));
1004- rightKey = XKeysymToKeycode (s->dpy (), XStringToKeysym ("Right"));
1005- upKey = XKeysymToKeycode (s->dpy (), XStringToKeysym ("Up"));
1006- downKey = XKeysymToKeycode (s->dpy (), XStringToKeysym ("Down"));
1007-
1008-- dragCursor = XCreateFontCursor (screen->dpy (), XC_fleur);
1009-+ mMoveCursor = XCreateFontCursor (screen->dpy (), XC_fleur);
1010-
1011- EXPOINITBIND (ExpoKey, doExpo);
1012- EXPOTERMBIND (ExpoKey, termExpo);
1013-@@ -1522,12 +1844,58 @@
1014- ScreenInterface::setHandler (screen, false);
1015- CompositeScreenInterface::setHandler (cScreen, false);
1016- GLScreenInterface::setHandler (gScreen, false);
1017-+
1018-+ outline_texture = GLTexture::imageDataToTexture (mGlowTextureProperties->textureData,
1019-+ CompSize (mGlowTextureProperties->textureSize,
1020-+ mGlowTextureProperties->textureSize),
1021-+ GL_RGBA, GL_UNSIGNED_BYTE);
1022-+ fname = "texture_tile.png";
1023-+ polkadots_texture = GLTexture::readImageToTexture (fname, pname, polkadots_texture_size);
1024-+
1025-+ if (polkadots_texture.empty ())
1026-+ compLogMessage ("expo", CompLogLevelWarn, "failed to bind image to texture");
1027-+ else
1028-+ {
1029-+ foreach (GLTexture *tex, polkadots_texture)
1030-+ {
1031-+ tex->enable (GLTexture::Good);
1032-+ glTexParameteri (tex->target (), GL_TEXTURE_WRAP_S, GL_REPEAT);
1033-+ glTexParameteri (tex->target (), GL_TEXTURE_WRAP_T, GL_REPEAT);
1034-+ tex->disable ();
1035-+ }
1036-+ }
1037- }
1038-
1039- ExpoScreen::~ExpoScreen ()
1040- {
1041-- if (dragCursor != None)
1042-- XFreeCursor (screen->dpy (), dragCursor);
1043-+ if (mMoveCursor)
1044-+ XFreeCursor (screen->dpy (), mMoveCursor);
1045-+}
1046-+
1047-+void
1048-+ExpoWindow::moveNotify (int dx, int dy, bool immediate)
1049-+{
1050-+ window->moveNotify (dx, dy, immediate);
1051-+
1052-+ if (!ExpoScreen::get (screen)->expoActive)
1053-+ return;
1054-+
1055-+ updateViewportActiveStates (screen);
1056-+}
1057-+
1058-+void
1059-+ExpoWindow::resizeNotify(int dx, int dy, int dw, int dh)
1060-+{
1061-+ window->resizeNotify (dx, dy, dw, dh);
1062-+
1063-+ /* mGlowQuads contains positional info, so we need to recalc that */
1064-+ if (mGlowQuads)
1065-+ {
1066-+ /* FIXME: we need to find a more multitexture friendly way
1067-+ * of doing this */
1068-+ GLTexture::Matrix tMat = eScreen->outline_texture.at (0)->matrix ();
1069-+ computeGlowQuads (&tMat);
1070-+ }
1071- }
1072-
1073- ExpoWindow::ExpoWindow (CompWindow *w) :
1074-@@ -1535,10 +1903,28 @@
1075- window (w),
1076- cWindow (CompositeWindow::get (w)),
1077- gWindow (GLWindow::get (w)),
1078-- eScreen (ExpoScreen::get (screen))
1079-+ eScreen (ExpoScreen::get (screen)),
1080-+ dndOpacity (0.0f),
1081-+ mGlowQuads (NULL)
1082- {
1083- CompositeWindowInterface::setHandler (cWindow, false);
1084- GLWindowInterface::setHandler (gWindow, false);
1085-+ WindowInterface::setHandler (window, true);
1086-+
1087-+ if (window->type () & CompWindowTypeDesktopMask)
1088-+ {
1089-+ foreach (GLTexture *tex, eScreen->outline_texture)
1090-+ {
1091-+ GLTexture::Matrix mat = tex->matrix ();
1092-+ computeGlowQuads (&mat);
1093-+ }
1094-+ }
1095-+}
1096-+
1097-+ExpoWindow::~ExpoWindow ()
1098-+{
1099-+ eScreen->dndWindows.remove (window);
1100-+ computeGlowQuads (NULL);
1101- }
1102-
1103- bool
1104-Index: ubuntu/plugins/expo/src/expo.h
1105-===================================================================
1106---- ubuntu.orig/plugins/expo/src/expo.h 2012-09-08 17:26:40.599035911 +0800
1107-+++ ubuntu/plugins/expo/src/expo.h 2012-09-12 22:20:43.276760475 +0800
1108-@@ -30,6 +30,44 @@
1109- #include <opengl/opengl.h>
1110-
1111- #include "expo_options.h"
1112-+#include "glow.h"
1113-+#include "viewport-member-window.h"
1114-+#include "client-list-generator.h"
1115-+
1116-+#define WIN_REAL_X(w) (w->x () - w->border ().left)
1117-+#define WIN_REAL_Y(w) (w->y () - w->border ().top)
1118-+#define WIN_REAL_WIDTH(w) (w->width () + 2 * w->geometry ().border () + \
1119-+ w->border ().left + w->border ().right)
1120-+#define WIN_REAL_HEIGHT(w) (w->height () + 2 * w->geometry ().border () + \
1121-+ w->border ().top + w->border ().bottom)
1122-+
1123-+namespace compiz
1124-+{
1125-+ namespace expo
1126-+ {
1127-+ namespace impl
1128-+ {
1129-+ namespace ce = compiz::expo;
1130-+
1131-+ class CompizClientListGenerator :
1132-+ public ce::ClientListGenerator
1133-+ {
1134-+ public:
1135-+
1136-+ CompizClientListGenerator (CompScreen *screen);
1137-+
1138-+ void refreshClientList ();
1139-+ ViewportMemberWindow * nextClient ();
1140-+
1141-+ private:
1142-+
1143-+ CompScreen *mScreen;
1144-+ const CompWindowVector *mClientList;
1145-+ CompWindowVector::const_iterator mClientListIterator;
1146-+ };
1147-+ }
1148-+ }
1149-+}
1150-
1151- class ExpoScreen :
1152- public ScreenInterface,
1153-@@ -51,8 +89,10 @@
1154- bool glPaintOutput (const GLScreenPaintAttrib&, const GLMatrix&,
1155- const CompRegion&, CompOutput *, unsigned int);
1156- void glPaintTransformedOutput (const GLScreenPaintAttrib&,
1157-- const GLMatrix&, const CompRegion&,
1158-- CompOutput *, unsigned int);
1159-+ const GLMatrix&, const CompRegion&,
1160-+ CompOutput*, unsigned int);
1161-+
1162-+ const CompWindowList & getWindowPaintList ();
1163-
1164- bool dndInit (CompAction *, CompAction::State, CompOption::Vector&);
1165- bool dndFini (CompAction *, CompAction::State, CompOption::Vector&);
1166-@@ -62,6 +102,8 @@
1167- bool nextVp (CompAction *, CompAction::State, CompOption::Vector&);
1168- bool prevVp (CompAction *, CompAction::State, CompOption::Vector&);
1169-
1170-+ CompPoint currentViewport ();
1171-+
1172- typedef enum {
1173- DnDNone,
1174- DnDDuring,
1175-@@ -82,7 +124,7 @@
1176- bool expoMode;
1177-
1178- DnDState dndState;
1179-- CompWindow *dndWindow;
1180-+ CompWindowList dndWindows;
1181-
1182- CompPoint prevCursor;
1183- CompPoint newCursor;
1184-@@ -94,6 +136,7 @@
1185- CompPoint paintingVp;
1186-
1187- std::vector<float> vpActivity;
1188-+ std::vector<bool> vpActive;
1189- float vpBrightness;
1190- float vpSaturation;
1191-
1192-@@ -113,6 +156,17 @@
1193-
1194- CompScreen::GrabHandle grabIndex;
1195-
1196-+ GLTexture::List polkadots_texture;
1197-+ CompSize polkadots_texture_size;
1198-+ CompSize viewport_size;
1199-+
1200-+ GLTexture::List outline_texture;
1201-+ CompSize outline_texture_size;
1202-+
1203-+ bool paintingDndWindow;
1204-+
1205-+ const GlowTextureProperties *mGlowTextureProperties;
1206-+
1207- private:
1208- void moveFocusViewport (int, int);
1209- void finishWindowMovement ();
1210-@@ -123,24 +177,45 @@
1211- void paintWall (const GLScreenPaintAttrib&, const GLMatrix&,
1212- const CompRegion&, CompOutput *, unsigned int, bool);
1213-
1214-+ void paintViewport (const GLScreenPaintAttrib& attrib,
1215-+ const GLMatrix& transform,
1216-+ const CompRegion& region,
1217-+ CompOutput *output,
1218-+ unsigned int mask,
1219-+ CompPoint vpPos,
1220-+ GLVector &vpCamPos,
1221-+ bool reflection);
1222-+
1223-+ bool windowsOnVp (compiz::expo::ClientListGenerator &clientList,
1224-+ CompPoint &p,
1225-+ const CompPoint &unprojectedCursor,
1226-+ const CompSize &screenSize,
1227-+ CompScreen *screen);
1228-+
1229- KeyCode leftKey;
1230- KeyCode rightKey;
1231- KeyCode upKey;
1232- KeyCode downKey;
1233-
1234-- Cursor dragCursor;
1235-+ Cursor mMoveCursor;
1236- };
1237-
1238- class ExpoWindow :
1239-+ public compiz::expo::ViewportMemberWindow,
1240- public CompositeWindowInterface,
1241- public GLWindowInterface,
1242-+ public WindowInterface,
1243- public PluginClassHandler<ExpoWindow, CompWindow>
1244- {
1245- public:
1246- ExpoWindow (CompWindow *);
1247-+ ~ExpoWindow ();
1248-
1249- bool damageRect (bool, const CompRect&);
1250-
1251-+ void resizeNotify (int dx, int dy, int dw, int dh);
1252-+ void moveNotify (int dx, int dy, bool immediate);
1253-+
1254- bool glDraw (const GLMatrix&, const GLWindowPaintAttrib&,
1255- const CompRegion&, unsigned int);
1256- bool glPaint (const GLWindowPaintAttrib&, const GLMatrix&,
1257-@@ -150,11 +225,31 @@
1258- unsigned int, unsigned int);
1259- void glDrawTexture (GLTexture*, const GLMatrix&,
1260- const GLWindowPaintAttrib&, unsigned int);
1261-+ void
1262-+ paintGlow (const GLMatrix &transform,
1263-+ const GLWindowPaintAttrib &attrib,
1264-+ const CompRegion &paintRegion,
1265-+ unsigned int mask);
1266-+
1267-+ void
1268-+ computeGlowQuads (GLTexture::Matrix *matrix);
1269-
1270- CompWindow *window;
1271- CompositeWindow *cWindow;
1272- GLWindow *gWindow;
1273- ExpoScreen *eScreen;
1274-+
1275-+ float dndOpacity;
1276-+
1277-+ GlowQuad *mGlowQuads;
1278-+
1279-+ private:
1280-+
1281-+ bool isDesktopOrDock () const;
1282-+ bool dragged () const;
1283-+ const compiz::window::Geometry & absoluteGeometry () const;
1284-+
1285-+ mutable compiz::window::Geometry mAbsoluteGeometry;
1286- };
1287-
1288- class ExpoPluginVTable :
1289-Index: ubuntu/plugins/expo/src/glow.cpp
1290-===================================================================
1291---- /dev/null 1970-01-01 00:00:00.000000000 +0000
1292-+++ ubuntu/plugins/expo/src/glow.cpp 2012-09-12 22:20:43.280760497 +0800
1293-@@ -0,0 +1,429 @@
1294-+/**
1295-+ *
1296-+ * Compiz group plugin
1297-+ *
1298-+ * glow.cpp
1299-+ *
1300-+ * Copyright : (C) 2006-2010 by Patrick Niklaus, Roi Cohen,
1301-+ * Danny Baumann, Sam Spilsbury
1302-+ * Authors: Patrick Niklaus <patrick.niklaus@googlemail.com>
1303-+ * Roi Cohen <roico.beryl@gmail.com>
1304-+ * Danny Baumann <maniac@opencompositing.org>
1305-+ * Sam Spilsbury <smspillaz@gmail.com>
1306-+ *
1307-+ *
1308-+ * This program is free software; you can redistribute it and/or
1309-+ * modify it under the terms of the GNU General Public License
1310-+ * as published by the Free Software Foundation; either version 2
1311-+ * of the License, or (at your option) any later version.
1312-+ *
1313-+ * This program is distributed in the hope that it will be useful,
1314-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
1315-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1316-+ * GNU General Public License for more details.
1317-+ *
1318-+ **/
1319-+
1320-+#include "expo.h"
1321-+#include "group_glow.h"
1322-+
1323-+const GlowTextureProperties glowTextureProperties = {
1324-+ /* GlowTextureRectangular */
1325-+ glowTexRect, 32, 21
1326-+};
1327-+
1328-+/*
1329-+ * GroupWindow::paintGlow
1330-+ *
1331-+ * Takes our glow texture, stretches the appropriate positions in the glow texture,
1332-+ * adds those geometries (so plugins like wobby and deform this texture correctly)
1333-+ * and then draws the glow texture with this geometry (plugins like wobbly and friends
1334-+ * will automatically deform the texture based on our set geometry)
1335-+ */
1336-+
1337-+void
1338-+ExpoWindow::paintGlow (const GLMatrix &transform,
1339-+ const GLWindowPaintAttrib &attrib,
1340-+ const CompRegion &paintRegion,
1341-+ unsigned int mask)
1342-+{
1343-+ CompRegion reg;
1344-+ int i;
1345-+ GLushort colorData[4];
1346-+ const GLushort *selColorData = ExpoScreen::get (screen)->optionGetSelectedColor ();
1347-+ float alpha = (float) selColorData[3] / 65535.0f;
1348-+
1349-+ /* Premultiply color */
1350-+ colorData[0] = selColorData[0] * alpha;
1351-+ colorData[1] = selColorData[1] * alpha;
1352-+ colorData[2] = selColorData[2] * alpha;
1353-+ colorData[3] = selColorData[3];
1354-+
1355-+ gWindow->vertexBuffer ()->begin ();
1356-+
1357-+ /* There are 8 glow parts of the glow texture which we wish to paint
1358-+ * separately with different transformations
1359-+ */
1360-+ for (i = 0; i < NUM_GLOWQUADS; i++)
1361-+ {
1362-+ /* Using precalculated quads here */
1363-+ reg = CompRegion (mGlowQuads[i].mBox);
1364-+
1365-+ if (reg.boundingRect ().x1 () < reg.boundingRect ().x2 () &&
1366-+ reg.boundingRect ().y1 () < reg.boundingRect ().y2 ())
1367-+ {
1368-+ GLTexture::MatrixList matl;
1369-+ reg = CompRegion (reg.boundingRect ().x1 (),
1370-+ reg.boundingRect ().y1 (),
1371-+ reg.boundingRect ().width (),
1372-+ reg.boundingRect ().height ());
1373-+
1374-+ matl.push_back (mGlowQuads[i].mMatrix);
1375-+ /* Add color data for all 6 vertices of the quad */
1376-+ for (int n = 0; n < 6; n++)
1377-+ gWindow->vertexBuffer ()->addColors (1, colorData);
1378-+ gWindow->glAddGeometry (matl, reg, paintRegion);
1379-+ }
1380-+ }
1381-+
1382-+ if (gWindow->vertexBuffer ()->end ())
1383-+ {
1384-+ //GLScreen::get (screen)->setTexEnvMode (GL_MODULATE);
1385-+ glBlendFunc (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
1386-+
1387-+ /* we use PAINT_WINDOW_TRANSFORMED_MASK here to force
1388-+ the usage of a good texture filter */
1389-+ foreach (GLTexture *tex, ExpoScreen::get (screen)->outline_texture)
1390-+ {
1391-+ gWindow->glDrawTexture (tex, transform, attrib, mask |
1392-+ PAINT_WINDOW_BLEND_MASK |
1393-+ PAINT_WINDOW_TRANSLUCENT_MASK |
1394-+ PAINT_WINDOW_TRANSFORMED_MASK);
1395-+ }
1396-+
1397-+ glBlendFunc (GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
1398-+ GLScreen::get (screen)->setTexEnvMode (GL_REPLACE);
1399-+ }
1400-+}
1401-+
1402-+/*
1403-+ * ExpoWindow::computeGlowQuads
1404-+ *
1405-+ * This function computures the matrix transformation required for each
1406-+ * part of the glow texture which we wish to stretch to some rectangular
1407-+ * dimentions
1408-+ *
1409-+ * There are eight quads different parts of the texture which we wish to
1410-+ * paint here, the 4 sides and four corners, eg:
1411-+ *
1412-+ * ------------------
1413-+ * | 1 | 4 | 6 |
1414-+ * ------------- ------------------
1415-+ * | 1 | 4 | 6 | | | | |
1416-+ * ------------- | | | |
1417-+ * | 2 | n | 7 | -> | 2 | n | 7 |
1418-+ * ------------- | | | |
1419-+ * | 3 | 5 | 8 | | | | |
1420-+ * ------------- ------------------
1421-+ * | 3 | 5 | 8 |
1422-+ * ------------------
1423-+ *
1424-+ * In this example here, 2, 4, 5 and 7 are stretched, and the matrices for
1425-+ * each quad rect adjusted accordingly for it's size compared to the original
1426-+ * texture size.
1427-+ *
1428-+ * When we are adjusting the matrices here, the initial size of each corner has
1429-+ * a size of of "1.0f", so according to 2x2 matrix rules,
1430-+ * the scale factor is the inverse of the size of the glow (which explains
1431-+ * while you will see here that matrix->xx is (1 / glowSize)
1432-+ * where glowSize is the size the user specifies they want their glow to extend.
1433-+ * (likewise, matrix->yy is adjusted similarly for corners and for top/bottom)
1434-+ *
1435-+ * matrix->x0 and matrix->y0 here are set to be the top left edge of the rect
1436-+ * adjusted by the matrix scale factor (matrix->xx and matrix->yy)
1437-+ *
1438-+ */
1439-+void
1440-+ExpoWindow::computeGlowQuads (GLTexture::Matrix *matrix)
1441-+{
1442-+ CompRect *box;
1443-+ int x1, x2, y1, y2;
1444-+ GLTexture::Matrix *quadMatrix;
1445-+ int glowSize, glowOffset;
1446-+ CompWindow *w = window;
1447-+
1448-+ /* Passing NULL to this function frees the glow quads
1449-+ * (so the window is not painted with glow) */
1450-+
1451-+ if (matrix)
1452-+ {
1453-+ if (!mGlowQuads)
1454-+ mGlowQuads = new GlowQuad[NUM_GLOWQUADS];
1455-+ if (!mGlowQuads)
1456-+ return;
1457-+ }
1458-+ else
1459-+ {
1460-+ if (mGlowQuads)
1461-+ {
1462-+ delete[] mGlowQuads;
1463-+ mGlowQuads = NULL;
1464-+ }
1465-+ return;
1466-+ }
1467-+
1468-+ glowSize = 48;
1469-+ glowOffset = (glowSize * ExpoScreen::get (screen)->mGlowTextureProperties->glowOffset /
1470-+ ExpoScreen::get (screen)->mGlowTextureProperties->textureSize) + 1;
1471-+
1472-+ /* Top left corner */
1473-+ box = &mGlowQuads[GLOWQUAD_TOPLEFT].mBox;
1474-+ mGlowQuads[GLOWQUAD_TOPLEFT].mMatrix = *matrix;
1475-+ quadMatrix = &mGlowQuads[GLOWQUAD_TOPLEFT].mMatrix;
1476-+
1477-+ /* Set the desired rect dimentions
1478-+ * for the part of the glow we are painting */
1479-+
1480-+ x1 = WIN_REAL_X (w) - glowSize + glowOffset;
1481-+ y1 = WIN_REAL_Y (w) - glowSize + glowOffset;
1482-+
1483-+ /* 2x2 Matrix here, adjust both x and y scale factors
1484-+ * and the x and y position
1485-+ *
1486-+ * Scaling both parts of the texture in a positive direction
1487-+ * here (left to right top to bottom)
1488-+ *
1489-+ * The base position (x0 and y0) here requires us to move backwards
1490-+ * on the x and y dimentions by the calculated rect dimentions
1491-+ * multiplied by the scale factors
1492-+ */
1493-+
1494-+ quadMatrix->xx = 1.0f / glowSize;
1495-+ quadMatrix->yy = 1.0f / (glowSize);
1496-+ quadMatrix->x0 = -(x1 * quadMatrix->xx);
1497-+ quadMatrix->y0 = -(y1 * quadMatrix->yy);
1498-+
1499-+ x2 = MIN (WIN_REAL_X (w) + glowOffset,
1500-+ WIN_REAL_X (w) + (WIN_REAL_WIDTH (w) / 2));
1501-+ y2 = MIN (WIN_REAL_Y (w) + glowOffset,
1502-+ WIN_REAL_Y (w) + (WIN_REAL_HEIGHT (w) / 2));
1503-+
1504-+ *box = CompRect (x1, y1, x2 - x1, y2 - y1);
1505-+
1506-+ /* Top right corner */
1507-+ box = &mGlowQuads[GLOWQUAD_TOPRIGHT].mBox;
1508-+ mGlowQuads[GLOWQUAD_TOPRIGHT].mMatrix = *matrix;
1509-+ quadMatrix = &mGlowQuads[GLOWQUAD_TOPRIGHT].mMatrix;
1510-+
1511-+ /* Set the desired rect dimentions
1512-+ * for the part of the glow we are painting */
1513-+
1514-+ x1 = WIN_REAL_X (w) + WIN_REAL_WIDTH (w) - glowOffset;
1515-+ y1 = WIN_REAL_Y (w) - glowSize + glowOffset;
1516-+ x2 = WIN_REAL_X (w) + WIN_REAL_WIDTH (w) + glowSize - glowOffset;
1517-+
1518-+ /* 2x2 Matrix here, adjust both x and y scale factors
1519-+ * and the x and y position
1520-+ *
1521-+ * Scaling the y part of the texture in a positive direction
1522-+ * and the x part in a negative direction here
1523-+ * (right to left top to bottom)
1524-+ *
1525-+ * The base position (x0 and y0) here requires us to move backwards
1526-+ * on the y dimention and forwards on x by the calculated rect dimentions
1527-+ * multiplied by the scale factors (since we are moving forward on x we
1528-+ * need the inverse of that which is 1 - x1 * xx
1529-+ */
1530-+
1531-+ quadMatrix->xx = -1.0f / glowSize;
1532-+ quadMatrix->yy = 1.0f / glowSize;
1533-+ quadMatrix->x0 = 1.0 - (x1 * quadMatrix->xx);
1534-+ quadMatrix->y0 = -(y1 * quadMatrix->yy);
1535-+
1536-+ x1 = MAX (WIN_REAL_X (w) + WIN_REAL_WIDTH (w) - glowOffset,
1537-+ WIN_REAL_X (w) + (WIN_REAL_WIDTH (w) / 2));
1538-+ y2 = MIN (WIN_REAL_Y (w) + glowOffset,
1539-+ WIN_REAL_Y (w) + (WIN_REAL_HEIGHT (w) / 2));
1540-+
1541-+ *box = CompRect (x1, y1, x2 - x1, y2 - y1);
1542-+
1543-+ /* Bottom left corner */
1544-+ box = &mGlowQuads[GLOWQUAD_BOTTOMLEFT].mBox;
1545-+ mGlowQuads[GLOWQUAD_BOTTOMLEFT].mMatrix = *matrix;
1546-+ quadMatrix = &mGlowQuads[GLOWQUAD_BOTTOMLEFT].mMatrix;
1547-+
1548-+ x1 = WIN_REAL_X (w) - glowSize + glowOffset;
1549-+ y1 = WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) - glowOffset;
1550-+ x2 = WIN_REAL_X (w) + glowOffset;
1551-+ y2 = WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) + glowSize - glowOffset;
1552-+
1553-+ /* 2x2 Matrix here, adjust both x and y scale factors
1554-+ * and the x and y position
1555-+ *
1556-+ * Scaling the x part of the texture in a positive direction
1557-+ * and the y part in a negative direction here
1558-+ * (left to right bottom to top)
1559-+ *
1560-+ * The base position (x0 and y0) here requires us to move backwards
1561-+ * on the x dimention and forwards on y by the calculated rect dimentions
1562-+ * multiplied by the scale factors (since we are moving forward on x we
1563-+ * need the inverse of that which is 1 - y1 * yy
1564-+ */
1565-+
1566-+ quadMatrix->xx = 1.0f / glowSize;
1567-+ quadMatrix->yy = -1.0f / glowSize;
1568-+ quadMatrix->x0 = -(x1 * quadMatrix->xx);
1569-+ quadMatrix->y0 = 1.0f - (y1 * quadMatrix->yy);
1570-+
1571-+ y1 = MAX (WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) - glowOffset,
1572-+ WIN_REAL_Y (w) + (WIN_REAL_HEIGHT (w) / 2));
1573-+ x2 = MIN (WIN_REAL_X (w) + glowOffset,
1574-+ WIN_REAL_X (w) + (WIN_REAL_WIDTH (w) / 2));
1575-+
1576-+ *box = CompRect (x1, y1, x2 - x1, y2 - y1);
1577-+
1578-+ /* Bottom right corner */
1579-+ box = &mGlowQuads[GLOWQUAD_BOTTOMRIGHT].mBox;
1580-+ mGlowQuads[GLOWQUAD_BOTTOMRIGHT].mMatrix = *matrix;
1581-+ quadMatrix = &mGlowQuads[GLOWQUAD_BOTTOMRIGHT].mMatrix;
1582-+
1583-+ x1 = WIN_REAL_X (w) + WIN_REAL_WIDTH (w) - glowOffset;
1584-+ y1 = WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) - glowOffset;
1585-+ x2 = WIN_REAL_X (w) + WIN_REAL_WIDTH (w) + glowSize - glowOffset;
1586-+ y2 = WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) + glowSize - glowOffset;
1587-+
1588-+ /* 2x2 Matrix here, adjust both x and y scale factors
1589-+ * and the x and y position
1590-+ *
1591-+ * Scaling the both parts of the texture in a negative direction
1592-+ * (right to left bottom to top)
1593-+ *
1594-+ * The base position (x0 and y0) here requires us to move forwards
1595-+ * on both dimentions by the calculated rect dimentions
1596-+ * multiplied by the scale factors
1597-+ */
1598-+
1599-+ quadMatrix->xx = -1.0f / glowSize;
1600-+ quadMatrix->yy = -1.0f / glowSize;
1601-+ quadMatrix->x0 = 1.0 - (x1 * quadMatrix->xx);
1602-+ quadMatrix->y0 = 1.0 - (y1 * quadMatrix->yy);
1603-+
1604-+ x1 = MAX (WIN_REAL_X (w) + WIN_REAL_WIDTH (w) - glowOffset,
1605-+ WIN_REAL_X (w) + (WIN_REAL_WIDTH (w) / 2));
1606-+ y1 = MAX (WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) - glowOffset,
1607-+ WIN_REAL_Y (w) + (WIN_REAL_HEIGHT (w) / 2));
1608-+
1609-+ *box = CompRect (x1, y1, x2 - x1, y2 - y1);
1610-+
1611-+ /* Top edge */
1612-+ box = &mGlowQuads[GLOWQUAD_TOP].mBox;
1613-+ mGlowQuads[GLOWQUAD_TOP].mMatrix = *matrix;
1614-+ quadMatrix = &mGlowQuads[GLOWQUAD_TOP].mMatrix;
1615-+
1616-+ x1 = WIN_REAL_X (w) + glowOffset;
1617-+ y1 = WIN_REAL_Y (w) - glowSize + glowOffset;
1618-+ x2 = WIN_REAL_X (w) + WIN_REAL_WIDTH (w) - glowOffset;
1619-+ y2 = WIN_REAL_Y (w) + glowOffset;
1620-+
1621-+ /* 2x2 Matrix here, adjust both x and y scale factors
1622-+ * and the x and y position
1623-+ *
1624-+ * No need to scale the x part of the texture here, but we
1625-+ * are scaling on the y part in a positive direciton
1626-+ *
1627-+ * The base position (y0) here requires us to move backwards
1628-+ * on the x dimention and forwards on y by the calculated rect dimentions
1629-+ * multiplied by the scale factors
1630-+ */
1631-+
1632-+ quadMatrix->xx = 0.0f;
1633-+ quadMatrix->yy = 1.0f / glowSize;
1634-+ quadMatrix->x0 = 1.0;
1635-+ quadMatrix->y0 = -(y1 * quadMatrix->yy);
1636-+
1637-+ *box = CompRect (x1, y1, x2 - x1, y2 - y1);
1638-+
1639-+ /* Bottom edge */
1640-+ box = &mGlowQuads[GLOWQUAD_BOTTOM].mBox;
1641-+ mGlowQuads[GLOWQUAD_BOTTOM].mMatrix = *matrix;
1642-+ quadMatrix = &mGlowQuads[GLOWQUAD_BOTTOM].mMatrix;
1643-+
1644-+ x1 = WIN_REAL_X (w) + glowOffset;
1645-+ y1 = WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) - glowOffset;
1646-+ x2 = WIN_REAL_X (w) + WIN_REAL_WIDTH (w) - glowOffset;
1647-+ y2 = WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) + glowSize - glowOffset;
1648-+
1649-+ /* 2x2 Matrix here, adjust both x and y scale factors
1650-+ * and the x and y position
1651-+ *
1652-+ * No need to scale the x part of the texture here, but we
1653-+ * are scaling on the y part in a negative direciton
1654-+ *
1655-+ * The base position (y0) here requires us to move forwards
1656-+ * on y by the calculated rect dimentions
1657-+ * multiplied by the scale factors
1658-+ */
1659-+
1660-+ quadMatrix->xx = 0.0f;
1661-+ quadMatrix->yy = -1.0f / glowSize;
1662-+ quadMatrix->x0 = 1.0;
1663-+ quadMatrix->y0 = 1.0 - (y1 * quadMatrix->yy);
1664-+
1665-+ *box = CompRect (x1, y1, x2 - x1, y2 - y1);
1666-+
1667-+ /* Left edge */
1668-+ box = &mGlowQuads[GLOWQUAD_LEFT].mBox;
1669-+ mGlowQuads[GLOWQUAD_LEFT].mMatrix = *matrix;
1670-+ quadMatrix = &mGlowQuads[GLOWQUAD_LEFT].mMatrix;
1671-+
1672-+ x1 = WIN_REAL_X (w) - glowSize + glowOffset;
1673-+ y1 = WIN_REAL_Y (w) + glowOffset;
1674-+ x2 = WIN_REAL_X (w) + glowOffset;
1675-+ y2 = WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) - glowOffset;
1676-+
1677-+ /* 2x2 Matrix here, adjust both x and y scale factors
1678-+ * and the x and y position
1679-+ *
1680-+ * No need to scale the y part of the texture here, but we
1681-+ * are scaling on the x part in a positive direciton
1682-+ *
1683-+ * The base position (x0) here requires us to move backwards
1684-+ * on x by the calculated rect dimentions
1685-+ * multiplied by the scale factors
1686-+ */
1687-+
1688-+ quadMatrix->xx = 1.0f / glowSize;
1689-+ quadMatrix->yy = 0.0f;
1690-+ quadMatrix->x0 = -(x1 * quadMatrix->xx);
1691-+ quadMatrix->y0 = 1.0;
1692-+
1693-+ *box = CompRect (x1, y1, x2 - x1, y2 - y1);
1694-+
1695-+ /* Right edge */
1696-+ box = &mGlowQuads[GLOWQUAD_RIGHT].mBox;
1697-+ mGlowQuads[GLOWQUAD_RIGHT].mMatrix = *matrix;
1698-+ quadMatrix = &mGlowQuads[GLOWQUAD_RIGHT].mMatrix;
1699-+
1700-+ x1 = WIN_REAL_X (w) + WIN_REAL_WIDTH (w) - glowOffset;
1701-+ y1 = WIN_REAL_Y (w) + glowOffset;
1702-+ x2 = WIN_REAL_X (w) + WIN_REAL_WIDTH (w) + glowSize - glowOffset;
1703-+ y2 = WIN_REAL_Y (w) + WIN_REAL_HEIGHT (w) - glowOffset;
1704-+
1705-+ /* 2x2 Matrix here, adjust both x and y scale factors
1706-+ * and the x and y position
1707-+ *
1708-+ * No need to scale the y part of the texture here, but we
1709-+ * are scaling on the x part in a negative direciton
1710-+ *
1711-+ * The base position (x0) here requires us to move forwards
1712-+ * on x by the calculated rect dimentions
1713-+ * multiplied by the scale factors
1714-+ */
1715-+
1716-+ quadMatrix->xx = -1.0f / glowSize;
1717-+ quadMatrix->yy = 0.0f;
1718-+ quadMatrix->x0 = 1.0 - (x1 * quadMatrix->xx);
1719-+ quadMatrix->y0 = 1.0;
1720-+
1721-+ *box = CompRect (x1, y1, x2 - x1, y2 - y1);
1722-+}
1723-Index: ubuntu/plugins/expo/src/glow.h
1724-===================================================================
1725---- /dev/null 1970-01-01 00:00:00.000000000 +0000
1726-+++ ubuntu/plugins/expo/src/glow.h 2012-09-12 22:20:43.280760497 +0800
1727-@@ -0,0 +1,66 @@
1728-+/**
1729-+ *
1730-+ * Compiz group plugin
1731-+ *
1732-+ * glow.h
1733-+ *
1734-+ * Copyright : (C) 2006-2010 by Patrick Niklaus, Roi Cohen,
1735-+ * Danny Baumann, Sam Spilsbury
1736-+ * Authors: Patrick Niklaus <patrick.niklaus@googlemail.com>
1737-+ * Roi Cohen <roico.beryl@gmail.com>
1738-+ * Danny Baumann <maniac@opencompositing.org>
1739-+ * Sam Spilsbury <smspillaz@gmail.com>
1740-+ *
1741-+ *
1742-+ * This program is free software; you can redistribute it and/or
1743-+ * modify it under the terms of the GNU General Public License
1744-+ * as published by the Free Software Foundation; either version 2
1745-+ * of the License, or (at your option) any later version.
1746-+ *
1747-+ * This program is distributed in the hope that it will be useful,
1748-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
1749-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1750-+ * GNU General Public License for more details.
1751-+ *
1752-+ **/
1753-+
1754-+#ifndef _EXPO_GLOW_H
1755-+#define _EXPO_GLOW_H
1756-+
1757-+#define GLOWQUAD_TOPLEFT 0
1758-+#define GLOWQUAD_TOPRIGHT 1
1759-+#define GLOWQUAD_BOTTOMLEFT 2
1760-+#define GLOWQUAD_BOTTOMRIGHT 3
1761-+#define GLOWQUAD_TOP 4
1762-+#define GLOWQUAD_BOTTOM 5
1763-+#define GLOWQUAD_LEFT 6
1764-+#define GLOWQUAD_RIGHT 7
1765-+#define NUM_GLOWQUADS 8
1766-+
1767-+/* Represents a particular glow texture, so here
1768-+ * we have hardcoded in the texture data, the offset
1769-+ * and the size of the texture
1770-+ */
1771-+
1772-+typedef struct _GlowTextureProperties {
1773-+ char *textureData;
1774-+ int textureSize;
1775-+ int glowOffset;
1776-+} GlowTextureProperties;
1777-+
1778-+/* Each glow quad contains a 2x2 scale + positional matrix
1779-+ * (the 3rd column is not used since that is for matrix skew
1780-+ * operations which we do not care about)
1781-+ * and also a CompRect which describes the size and position of
1782-+ * the quad on the glow
1783-+ */
1784-+
1785-+class GlowQuad {
1786-+ public:
1787-+ CompRect mBox;
1788-+ GLTexture::Matrix mMatrix;
1789-+};
1790-+
1791-+extern const GlowTextureProperties glowTextureProperties;
1792-+
1793-+#endif
1794-Index: ubuntu/plugins/expo/src/group_glow.h
1795-===================================================================
1796---- /dev/null 1970-01-01 00:00:00.000000000 +0000
1797-+++ ubuntu/plugins/expo/src/group_glow.h 2012-09-12 22:20:43.280760497 +0800
1798-@@ -0,0 +1,197 @@
1799-+#ifndef _GROUP_GLOWTEX_H
1800-+#define _GROUP_GLOWTEX_H
1801-+
1802-+/**
1803-+ *
1804-+ * Compiz group plugin
1805-+ *
1806-+ * group_glow.h
1807-+ *
1808-+ * Copyright : (C) 2006-2010 by Patrick Niklaus, Roi Cohen,
1809-+ * Danny Baumann, Sam Spilsbury
1810-+ * Authors: Patrick Niklaus <patrick.niklaus@googlemail.com>
1811-+ * Roi Cohen <roico.beryl@gmail.com>
1812-+ * Danny Baumann <maniac@opencompositing.org>
1813-+ * Sam Spilsbury <smspillaz@gmail.com>
1814-+ *
1815-+ *
1816-+ * This program is free software; you can redistribute it and/or
1817-+ * modify it under the terms of the GNU General Public License
1818-+ * as published by the Free Software Foundation; either version 2
1819-+ * of the License, or (at your option) any later version.
1820-+ *
1821-+ * This program is distributed in the hope that it will be useful,
1822-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
1823-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1824-+ * GNU General Public License for more details.
1825-+ *
1826-+ **/
1827-+
1828-+/*
1829-+ * glowTex
1830-+ */
1831-+
1832-+static char glowTexRect[4097] = {
1833-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1834-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1835-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377"
1836-+ "\377\377\6\377\377\377\6\377\377\377\6\377\377\377\6\377\377\377\6\377\377"
1837-+ "\377\6\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1838-+ "\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\6\377\377\377\6\377\377"
1839-+ "\377\6\377\377\377\6\377\377\377\6\377\377\377\6\377\377\377\6\377\377\377"
1840-+ "\6\377\377\377\6\377\377\377\6\377\377\377\6\377\377\377\6\377\377\377\6"
1841-+ "\377\377\377\14\377\377\377\14\377\377\377\14\377\377\377\14\377\377\377"
1842-+ "\14\377\377\377\14\377\377\377\14\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1843-+ "\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\6\377\377\377\6\377\377\377\14"
1844-+ "\377\377\377\14\377\377\377\22\377\377\377\22\377\377\377\22\377\377\377"
1845-+ "\27\377\377\377\27\377\377\377\27\377\377\377\27\377\377\377\27\377\377\377"
1846-+ "\27\377\377\377\27\377\377\377\27\377\377\377\27\377\377\377\27\377\377\377"
1847-+ "\35\377\377\377\35\377\377\377\35\377\377\377\35\377\377\377\35\377\377\377"
1848-+ "\35\377\377\377\35\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377"
1849-+ "\377\6\377\377\377\6\377\377\377\14\377\377\377\22\377\377\377\27\377\377"
1850-+ "\377\27\377\377\377\35\377\377\377#\377\377\377'\377\377\377'\377\377\377"
1851-+ "+\377\377\377+\377\377\377+\377\377\377+\377\377\377+\377\377\377+\377\377"
1852-+ "\377+\377\377\377+\377\377\377+\377\377\3771\377\377\3771\377\377\3771\377"
1853-+ "\377\3771\377\377\3771\377\377\3771\377\377\3771\0\0\0\0\0\0\0\0\0\0\0\0"
1854-+ "\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377\22\377\377\377"
1855-+ "\27\377\377\377\35\377\377\377#\377\377\377+\377\377\3771\377\377\3776\377"
1856-+ "\377\377<\377\377\377>\377\377\377C\377\377\377I\377\377\377I\377\377\377"
1857-+ "I\377\377\377I\377\377\377I\377\377\377I\377\377\377I\377\377\377I\377\377"
1858-+ "\377L\377\377\377L\377\377\377L\377\377\377L\377\377\377L\377\377\377L\377"
1859-+ "\377\377L\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377"
1860-+ "\377\377\22\377\377\377\27\377\377\377#\377\377\377+\377\377\3776\377\377"
1861-+ "\377C\377\377\377L\377\377\377U\377\377\377]\377\377\377`\377\377\377d\377"
1862-+ "\377\377h\377\377\377k\377\377\377k\377\377\377k\377\377\377k\377\377\377"
1863-+ "k\377\377\377k\377\377\377k\377\377\377p\377\377\377p\377\377\377p\377\377"
1864-+ "\377p\377\377\377p\377\377\377p\377\377\377p\0\0\0\0\0\0\0\0\0\0\0\0\377"
1865-+ "\377\377\6\377\377\377\14\377\377\377\22\314\314\314\35\377\377\377'\377"
1866-+ "\377\3771\377\377\377>\357\357\357P\377\377\377]\363\363\363k\365\365\365"
1867-+ "v\365\365\365|\377\377\377\202\367\367\367\210\367\367\367\214\367\367\367"
1868-+ "\216\367\367\367\221\367\367\367\221\367\367\367\221\367\367\367\221\367"
1869-+ "\367\367\221\367\367\367\221\367\367\367\224\367\367\367\224\367\367\367"
1870-+ "\224\367\367\367\224\367\367\367\224\367\367\367\224\367\367\367\224\0\0"
1871-+ "\0\0\0\0\0\0\377\377\377\6\377\377\377\6\377\377\377\22\377\377\377\27\377"
1872-+ "\377\377'\377\377\3776\377\377\377I\377\377\377Y\377\377\377k\376\376\376"
1873-+ "y\377\377\377\210\377\377\377\224\377\377\377\235\377\377\377\245\377\377"
1874-+ "\377\253\377\377\377\255\377\377\377\262\377\377\377\262\377\377\377\263"
1875-+ "\377\377\377\263\377\377\377\263\377\377\377\263\377\377\377\263\377\377"
1876-+ "\377\266\377\377\377\266\377\377\377\266\377\377\377\266\377\377\377\266"
1877-+ "\377\377\377\266\377\377\377\266\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377"
1878-+ "\14\377\377\377\27\377\377\377#\377\377\3771\377\377\377I\377\377\377]\377"
1879-+ "\377\377r\377\377\377\205\377\377\377\231\377\377\377\247\377\377\377\263"
1880-+ "\377\377\377\275\377\377\377\304\377\377\377\310\377\377\377\313\377\377"
1881-+ "\377\316\377\377\377\320\377\377\377\320\377\377\377\320\377\377\377\320"
1882-+ "\377\377\377\320\377\377\377\320\377\377\377\322\377\377\377\322\377\377"
1883-+ "\377\322\377\377\377\322\377\377\377\322\377\377\377\322\377\377\377\322"
1884-+ "\0\0\0\0\377\377\377\6\377\377\377\6\377\377\377\22\377\377\377\35\377\377"
1885-+ "\377+\377\377\377>\377\377\377Y\377\377\377r\377\377\377\210\376\376\376"
1886-+ "\237\377\377\377\262\377\377\377\302\377\377\377\313\377\377\377\324\377"
1887-+ "\377\377\332\376\376\376\336\377\377\377\341\377\377\377\342\377\377\377"
1888-+ "\344\377\377\377\344\377\377\377\344\377\377\377\344\377\377\377\344\377"
1889-+ "\377\377\344\377\377\377\345\377\377\377\345\377\377\377\345\377\377\377"
1890-+ "\345\377\377\377\345\377\377\377\345\377\377\377\345\0\0\0\0\377\377\377"
1891-+ "\6\377\377\377\14\377\377\377\27\377\377\377#\377\377\3776\377\377\377P\377"
1892-+ "\377\377k\377\377\377\205\376\376\376\237\372\372\372\266\377\377\377\307"
1893-+ "\373\373\373\325\373\373\373\337\374\374\374\345\374\374\374\352\374\374"
1894-+ "\374\355\374\374\374\357\374\374\374\360\374\374\374\361\374\374\374\361"
1895-+ "\374\374\374\362\374\374\374\362\374\374\374\362\374\374\374\362\374\374"
1896-+ "\374\362\374\374\374\362\374\374\374\362\374\374\374\362\374\374\374\362"
1897-+ "\374\374\374\362\374\374\374\362\0\0\0\0\377\377\377\6\377\377\377\14\377"
1898-+ "\377\377\35\377\377\377+\377\377\377C\377\377\377]\377\377\377|\377\377\377"
1899-+ "\231\377\377\377\263\377\377\377\307\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1900-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1901-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377"
1902-+ "\377\377\6\377\377\377\22\324\324\324#\377\377\3771\377\377\377L\363\363"
1903-+ "\363k\377\377\377\210\377\377\377\247\377\377\377\302\377\377\377\325\0\0"
1904-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1905-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1906-+ "\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377\22\377\377"
1907-+ "\377#\377\377\377<\377\377\377U\377\377\377v\377\377\377\226\377\377\377"
1908-+ "\263\377\377\377\315\377\377\377\337\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1909-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1910-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377"
1911-+ "\6\377\377\377\14\377\377\377\27\377\377\377'\377\377\377>\377\377\377]\377"
1912-+ "\377\377|\370\370\370\237\377\377\377\275\373\373\373\325\377\377\377\345"
1913-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1914-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1915-+ "\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377\27\377"
1916-+ "\377\377+\377\377\377C\377\377\377`\377\377\377\202\377\377\377\247\377\377"
1917-+ "\377\304\377\377\377\332\377\377\377\352\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1918-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1919-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377"
1920-+ "\377\6\377\377\377\14\377\377\377\27\377\377\377+\377\377\377C\377\377\377"
1921-+ "d\377\377\377\210\377\377\377\253\377\377\377\310\376\376\376\336\374\374"
1922-+ "\374\355\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1923-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1924-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377"
1925-+ "\35\377\377\377+\377\377\377I\377\377\377h\377\377\377\214\377\377\377\260"
1926-+ "\377\377\377\313\374\374\374\342\374\374\374\357\0\0\0\0\0\0\0\0\0\0\0\0"
1927-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1928-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1929-+ "\377\377\377\6\377\377\377\14\377\377\377\35\342\342\3421\377\377\377I\377"
1930-+ "\377\377k\377\377\377\216\377\377\377\262\377\377\377\316\374\374\374\344"
1931-+ "\377\377\377\360\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1932-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1933-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377"
1934-+ "\377\377\35\377\377\3771\377\377\377L\377\377\377k\377\377\377\221\377\377"
1935-+ "\377\263\377\377\377\320\377\377\377\344\377\377\377\361\0\0\0\0\0\0\0\0"
1936-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1937-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1938-+ "\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377\35\377\377\3771\377\377"
1939-+ "\377L\377\377\377k\377\377\377\221\377\377\377\263\377\377\377\320\377\377"
1940-+ "\377\344\374\374\374\362\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1941-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1942-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377"
1943-+ "\14\377\377\377\35\377\377\3771\377\377\377L\364\364\364p\377\377\377\221"
1944-+ "\372\372\372\266\377\377\377\320\374\374\374\345\377\377\377\362\0\0\0\0"
1945-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1946-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1947-+ "\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377\35\377\377\377"
1948-+ "1\377\377\377L\377\377\377p\377\377\377\221\377\377\377\266\373\373\373\322"
1949-+ "\377\377\377\345\377\377\377\362\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1950-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1951-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377"
1952-+ "\377\377\14\377\377\377\35\377\377\3771\377\377\377L\377\377\377p\377\377"
1953-+ "\377\221\377\377\377\266\373\373\373\322\377\377\377\345\377\377\377\362"
1954-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1955-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1956-+ "\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377\35\377"
1957-+ "\377\3771\377\377\377L\377\377\377p\377\377\377\221\377\377\377\266\373\373"
1958-+ "\373\322\377\377\377\345\377\377\377\362\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1959-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1960-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377"
1961-+ "\377\6\377\377\377\14\377\377\377\35\377\377\3771\377\377\377L\377\377\377"
1962-+ "p\367\367\367\224\377\377\377\266\377\377\377\322\377\377\377\345\374\374"
1963-+ "\374\362\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1964-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1965-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377"
1966-+ "\35\377\377\3771\377\377\377L\377\377\377p\367\367\367\224\377\377\377\266"
1967-+ "\377\377\377\322\377\377\377\345\374\374\374\362\0\0\0\0\0\0\0\0\0\0\0\0"
1968-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1969-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1970-+ "\377\377\377\6\377\377\377\14\377\377\377\35\377\377\3771\377\377\377L\377"
1971-+ "\377\377p\367\367\367\224\377\377\377\266\377\377\377\322\377\377\377\345"
1972-+ "\374\374\374\362\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1973-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1974-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377"
1975-+ "\377\377\35\377\377\3771\377\377\377L\377\377\377p\367\367\367\224\377\377"
1976-+ "\377\266\377\377\377\322\377\377\377\345\374\374\374\362\0\0\0\0\0\0\0\0"
1977-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1978-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1979-+ "\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377\35\377\377\3771\377\377"
1980-+ "\377L\377\377\377p\367\367\367\224\377\377\377\266\377\377\377\322\377\377"
1981-+ "\377\345\374\374\374\362\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1982-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1983-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377"
1984-+ "\14\377\377\377\35\377\377\3771\377\377\377L\377\377\377p\367\367\367\224"
1985-+ "\377\377\377\266\377\377\377\322\377\377\377\345\374\374\374\362\0\0\0\0"
1986-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1987-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1988-+ "\0\0\0\0\0\0\0\0\377\377\377\6\377\377\377\14\377\377\377\35\377\377\377"
1989-+ "1\377\377\377L\377\377\377p\367\367\367\224\377\377\377\266\377\377\377\322"
1990-+ "\377\377\377\345\374\374\374\362\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1991-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
1992-+ "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0",
1993-+};
1994-+
1995-+#endif
1996-Index: ubuntu/plugins/expo/src/wall_offset/CMakeLists.txt
1997-===================================================================
1998---- /dev/null 1970-01-01 00:00:00.000000000 +0000
1999-+++ ubuntu/plugins/expo/src/wall_offset/CMakeLists.txt 2012-09-12 22:20:43.280760497 +0800
2000-@@ -0,0 +1,33 @@
2001-+include_directories (
2002-+ ${CMAKE_CURRENT_SOURCE_DIR}/include
2003-+ ${CMAKE_CURRENT_SOURCE_DIR}/src
2004-+ ${Boost_INCLUDE_DIRS}
2005-+ ${GLIBMM_INCLUDE_DIRS}
2006-+)
2007-+
2008-+link_directories (${GLIBMM_LIBRARY_DIRS} ${COMPIZ_LIBRARY_DIRS})
2009-+
2010-+set (
2011-+ PRIVATE_HEADERS
2012-+ ${CMAKE_CURRENT_SOURCE_DIR}/include/wall-offset.h
2013-+)
2014-+
2015-+set (
2016-+ SRCS
2017-+ ${CMAKE_CURRENT_SOURCE_DIR}/src/wall-offset.cpp
2018-+)
2019-+
2020-+add_library (
2021-+ compiz_expo_wall_offset STATIC
2022-+ ${SRCS}
2023-+ ${PRIVATE_HEADERS}
2024-+)
2025-+
2026-+if (COMPIZ_BUILD_TESTING)
2027-+ add_subdirectory ( ${CMAKE_CURRENT_SOURCE_DIR}/tests )
2028-+endif (COMPIZ_BUILD_TESTING)
2029-+
2030-+target_link_libraries (
2031-+ compiz_expo_wall_offset
2032-+ compiz_core
2033-+)
2034-Index: ubuntu/plugins/expo/src/wall_offset/include/wall-offset.h
2035-===================================================================
2036---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2037-+++ ubuntu/plugins/expo/src/wall_offset/include/wall-offset.h 2012-09-12 22:20:43.280760497 +0800
2038-@@ -0,0 +1,43 @@
2039-+/**
2040-+ * Copyright © 2012 Canonical Ltd.
2041-+ *
2042-+ * Authors:
2043-+ * Sam Spilsbury <sam.spilsbury@canonical.com>
2044-+ *
2045-+ * This program is free software; you can redistribute it and/or
2046-+ * modify it under the terms of the GNU General Public License
2047-+ * as published by the Free Software Foundation; either version 2
2048-+ * of the License, or (at your option) any later version.
2049-+ *
2050-+ * This program is distributed in the hope that it will be useful,
2051-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
2052-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2053-+ * GNU General Public License for more details.
2054-+ *
2055-+ **/
2056-+
2057-+#ifndef _COMPIZ_EXPO_WALL_OFFSET_H
2058-+#define _COMPIZ_EXPO_WALL_OFFSET_H
2059-+
2060-+#include <core/point.h>
2061-+#include <core/size.h>
2062-+#include <core/rect.h>
2063-+
2064-+namespace compiz
2065-+{
2066-+ namespace expo
2067-+ {
2068-+ void
2069-+ calculateWallOffset (const CompRect &output,
2070-+ const CompPoint &offsetInScreenCoords,
2071-+ const CompPoint &vpSize,
2072-+ const CompSize &screenSize,
2073-+ float &offsetInWorldX,
2074-+ float &offsetInWorldY,
2075-+ float &worldScaleFactorX,
2076-+ float &worldScaleFactorY,
2077-+ float animationProgress);
2078-+ }
2079-+}
2080-+
2081-+#endif
2082-Index: ubuntu/plugins/expo/src/wall_offset/src/wall-offset.cpp
2083-===================================================================
2084---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2085-+++ ubuntu/plugins/expo/src/wall_offset/src/wall-offset.cpp 2012-09-12 22:20:43.280760497 +0800
2086-@@ -0,0 +1,55 @@
2087-+/**
2088-+ * Copyright © 2012 Canonical Ltd.
2089-+ *
2090-+ * Authors:
2091-+ * Sam Spilsbury <sam.spilsbury@canonical.com>
2092-+ *
2093-+ * This program is free software; you can redistribute it and/or
2094-+ * modify it under the terms of the GNU General Public License
2095-+ * as published by the Free Software Foundation; either version 2
2096-+ * of the License, or (at your option) any later version.
2097-+ *
2098-+ * This program is distributed in the hope that it will be useful,
2099-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
2100-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2101-+ * GNU General Public License for more details.
2102-+ *
2103-+ **/
2104-+#include "wall-offset.h"
2105-+
2106-+namespace compiz
2107-+{
2108-+ namespace expo
2109-+ {
2110-+ void
2111-+ calculateWallOffset (const CompRect &output,
2112-+ const CompPoint &offsetInScreenCoords,
2113-+ const CompPoint &vpSize,
2114-+ const CompSize &screenSize,
2115-+ float &offsetInWorldX,
2116-+ float &offsetInWorldY,
2117-+ float &worldScaleFactorX,
2118-+ float &worldScaleFactorY,
2119-+ float animationProgress)
2120-+ {
2121-+ const float sx = screenSize.width () / static_cast <float> (output.width ());
2122-+ const float sy = screenSize.height () / static_cast <float> (output.height ());
2123-+ offsetInWorldX = 0.0;
2124-+ offsetInWorldY = 0.0;
2125-+ worldScaleFactorX = 1.0f;
2126-+ worldScaleFactorY = 1.0f;
2127-+
2128-+ if (output.left () == 0)
2129-+ {
2130-+ offsetInWorldX = ((vpSize.x () * sx) / ((float) output.width ()) * (offsetInScreenCoords.x ()) * animationProgress);
2131-+ worldScaleFactorX = 1.0f - ((float) (offsetInScreenCoords.x ()) / (float) (output.width ())) * animationProgress;
2132-+ }
2133-+
2134-+ if (output.top () == 0)
2135-+ {
2136-+ offsetInWorldY = ((vpSize.y () * sy) / ((float) output.height ()) * (offsetInScreenCoords.y ()) * animationProgress);
2137-+ worldScaleFactorY = 1.0f - ((float) (offsetInScreenCoords.y ()) / (float) output.height ()) * animationProgress;
2138-+ }
2139-+ }
2140-+ }
2141-+}
2142-Index: ubuntu/plugins/expo/src/wall_offset/tests/CMakeLists.txt
2143-===================================================================
2144---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2145-+++ ubuntu/plugins/expo/src/wall_offset/tests/CMakeLists.txt 2012-09-12 22:20:43.280760497 +0800
2146-@@ -0,0 +1,19 @@
2147-+if (NOT GTEST_FOUND)
2148-+ message ("Google Test not found - cannot build tests!")
2149-+ set (COMPIZ_BUILD_TESTING OFF)
2150-+endif (NOT GTEST_FOUND)
2151-+
2152-+include_directories (${GTEST_INCLUDE_DIRS})
2153-+
2154-+link_directories (${COMPIZ_LIBRARY_DIRS})
2155-+
2156-+add_executable (compiz_test_expo_wall_offset
2157-+ ${CMAKE_CURRENT_SOURCE_DIR}/test-expo-wall-offset.cpp)
2158-+
2159-+target_link_libraries (compiz_test_expo_wall_offset
2160-+ compiz_expo_wall_offset
2161-+ ${GTEST_BOTH_LIBRARIES}
2162-+ ${CMAKE_THREAD_LIBS_INIT} # Link in pthread.
2163-+ )
2164-+
2165-+compiz_discover_tests (compiz_test_expo_wall_offset COVERAGE compiz_expo_wall_offset)
2166-Index: ubuntu/plugins/expo/src/wall_offset/tests/test-expo-wall-offset.cpp
2167-===================================================================
2168---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2169-+++ ubuntu/plugins/expo/src/wall_offset/tests/test-expo-wall-offset.cpp 2012-09-12 22:20:43.280760497 +0800
2170-@@ -0,0 +1,263 @@
2171-+/*
2172-+ * Copyright © 2012 Canonical Ltd.
2173-+ *
2174-+ * Permission to use, copy, modify, distribute, and sell this software
2175-+ * and its documentation for any purpose is hereby granted without
2176-+ * fee, provided that the above copyright notice appear in all copies
2177-+ * and that both that copyright notice and this permission notice
2178-+ * appear in supporting documentation, and that the name of
2179-+ * Canonical Ltd. not be used in advertising or publicity pertaining to
2180-+ * distribution of the software without specific, written prior permission.
2181-+ * Canonical Ltd. makes no representations about the suitability of this
2182-+ * software for any purpose. It is provided "as is" without express or
2183-+ * implied warranty.
2184-+ *
2185-+ * CANONICAL, LTD. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
2186-+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
2187-+ * NO EVENT SHALL CANONICAL, LTD. BE LIABLE FOR ANY SPECIAL, INDIRECT OR
2188-+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
2189-+ * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
2190-+ * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
2191-+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
2192-+ *
2193-+ * Authored by: Sam Spilsbury <sam.spilsbury@canonical.com>
2194-+ */
2195-+#include <tr1/tuple>
2196-+#include <gtest/gtest.h>
2197-+#include "wall-offset.h"
2198-+
2199-+using ::testing::WithParamInterface;
2200-+using ::testing::ValuesIn;
2201-+using ::testing::Combine;
2202-+using ::testing::Range;
2203-+
2204-+class ExpoWallOffsetTest :
2205-+ public ::testing::Test
2206-+{
2207-+ protected:
2208-+
2209-+ float offsetInWorldX;
2210-+ float offsetInWorldY;
2211-+ float worldScaleFactorX;
2212-+ float worldScaleFactorY;
2213-+};
2214-+
2215-+namespace
2216-+{
2217-+ const unsigned int nAnimationsBegin = 0;
2218-+ const unsigned int nAnimationSteps = 20;
2219-+
2220-+ struct OffsetAnimationParameters
2221-+ {
2222-+ float offsetInWorldX;
2223-+ float offsetInWorldY;
2224-+ float worldScaleFactorX;
2225-+ float worldScaleFactorY;
2226-+ };
2227-+
2228-+ struct OffsetParameters
2229-+ {
2230-+ float offsetX;
2231-+ float offsetY;
2232-+ int vpSizeWidth;
2233-+ int vpSizeHeight;
2234-+ int screenWidth;
2235-+ int screenHeight;
2236-+ int outputWidth;
2237-+ int outputHeight;
2238-+ OffsetAnimationParameters animationParameters[20];
2239-+ };
2240-+
2241-+ const OffsetParameters testingOffsetParameters[] =
2242-+ {
2243-+ {
2244-+ 0,
2245-+ 0,
2246-+ 1,
2247-+ 1,
2248-+ 100,
2249-+ 100,
2250-+ 100,
2251-+ 100,
2252-+ {
2253-+ { 0, 0, 1.0, 1.0 },
2254-+ { 0, 0, 1.0, 1.0 },
2255-+ { 0, 0, 1.0, 1.0 },
2256-+ { 0, 0, 1.0, 1.0 },
2257-+ { 0, 0, 1.0, 1.0 },
2258-+ { 0, 0, 1.0, 1.0 },
2259-+ { 0, 0, 1.0, 1.0 },
2260-+ { 0, 0, 1.0, 1.0 },
2261-+ { 0, 0, 1.0, 1.0 },
2262-+ { 0, 0, 1.0, 1.0 },
2263-+ { 0, 0, 1.0, 1.0 },
2264-+ { 0, 0, 1.0, 1.0 },
2265-+ { 0, 0, 1.0, 1.0 },
2266-+ { 0, 0, 1.0, 1.0 },
2267-+ { 0, 0, 1.0, 1.0 },
2268-+ { 0, 0, 1.0, 1.0 },
2269-+ { 0, 0, 1.0, 1.0 },
2270-+ { 0, 0, 1.0, 1.0 },
2271-+ { 0, 0, 1.0, 1.0 },
2272-+ { 0, 0, 1.0, 1.0 }
2273-+ }
2274-+ },
2275-+ /* Monitor 1280x800, Screen: 1280x800, Viewport Layout: 2x2, Offset: 32, 24 */
2276-+ {
2277-+ 32,
2278-+ 24,
2279-+ 2,
2280-+ 2,
2281-+ 1280,
2282-+ 800,
2283-+ 1280,
2284-+ 800,
2285-+ {
2286-+ { 0, 0, 1, 1 },
2287-+ { 0.0025000001769512892, 0.0011718750465661287, 0.99874997138977051, 0.99906247854232788 },
2288-+ { 0.0050000003539025784, 0.0023437500931322575, 0.99750000238418579, 0.99812501668930054 },
2289-+ { 0.0075000002980232239, 0.0035156251396983862, 0.9962499737739563, 0.99718749523162842 },
2290-+ { 0.010000000707805157, 0.0046875001862645149, 0.99500000476837158, 0.9962499737739563 },
2291-+ { 0.012500000186264515, 0.005859375, 0.99374997615814209, 0.99531251192092896 },
2292-+ { 0.015000000596046448, 0.0070312502793967724, 0.99250000715255737, 0.99437499046325684 },
2293-+ { 0.017500000074505806, 0.0082031246274709702, 0.99124997854232788, 0.99343752861022949 },
2294-+ { 0.020000001415610313, 0.0093750003725290298, 0.99000000953674316, 0.99250000715255737 },
2295-+ { 0.022499999031424522, 0.01054687425494194, 0.98874998092651367, 0.99156248569488525 },
2296-+ { 0.02500000037252903, 0.01171875, 0.98750001192092896, 0.99062502384185791 },
2297-+ { 0.027500001713633537, 0.01289062574505806, 0.98624998331069946, 0.98968750238418579 },
2298-+ { 0.030000001192092896, 0.014062500558793545, 0.98500001430511475, 0.98874998092651367 },
2299-+ { 0.032499998807907104, 0.015234374441206455, 0.98374998569488525, 0.98781251907348633 },
2300-+ { 0.035000000149011612, 0.01640624925494194, 0.98250001668930054, 0.98687499761581421 },
2301-+ { 0.037500001490116119, 0.017578125, 0.98124998807907104, 0.98593747615814209 },
2302-+ { 0.040000002831220627, 0.01875000074505806, 0.98000001907348633, 0.98500001430511475 },
2303-+ { 0.042500000447034836, 0.019921876490116119, 0.97874999046325684, 0.98406249284744263 },
2304-+ { 0.044999998062849045, 0.021093748509883881, 0.97750002145767212, 0.98312497138977051 },
2305-+ { 0.047499999403953552, 0.02226562425494194, 0.97624999284744263, 0.98218750953674316 }
2306-+ }
2307-+ },
2308-+ /* Monitor 1280x1024, Screen: 2560x1024, Viewport Layout: 2x2, Offset: 32, 24 */
2309-+ {
2310-+ 32,
2311-+ 24,
2312-+ 2,
2313-+ 2,
2314-+ 2560,
2315-+ 1024,
2316-+ 1280,
2317-+ 1024,
2318-+ {
2319-+ { 0, 0, 1, 1 },
2320-+ { 0.0050000003539025784, 0.001500000013038516, 0.99874997138977051, 0.99906247854232788 },
2321-+ { 0.010000000707805157, 0.0030000000260770321, 0.99750000238418579, 0.99812501668930054 },
2322-+ { 0.015000000596046448, 0.0045000002719461918, 0.9962499737739563, 0.99718749523162842 },
2323-+ { 0.020000001415610313, 0.0060000000521540642, 0.99500000476837158, 0.9962499737739563 },
2324-+ { 0.02500000037252903, 0.0074999998323619366, 0.99374997615814209, 0.99531251192092896 },
2325-+ { 0.030000001192092896, 0.0090000005438923836, 0.99250000715255737, 0.99437499046325684 },
2326-+ { 0.035000000149011612, 0.010499999858438969, 0.99124997854232788, 0.99343752861022949 },
2327-+ { 0.040000002831220627, 0.012000000104308128, 0.99000000953674316, 0.99250000715255737 },
2328-+ { 0.044999998062849045, 0.013499999418854713, 0.98874998092651367, 0.99156248569488525 },
2329-+ { 0.05000000074505806, 0.014999999664723873, 0.98750001192092896, 0.99062502384185791 },
2330-+ { 0.055000003427267075, 0.016499999910593033, 0.98624998331069946, 0.98968750238418579 },
2331-+ { 0.060000002384185791, 0.018000001087784767, 0.98500001430511475, 0.98874998092651367 },
2332-+ { 0.064999997615814209, 0.019499998539686203, 0.98374998569488525, 0.98781251907348633 },
2333-+ { 0.070000000298023224, 0.020999999716877937, 0.98250001668930054, 0.98687499761581421 },
2334-+ { 0.075000002980232239, 0.022499999031424522, 0.98124998807907104, 0.98593747615814209 },
2335-+ { 0.080000005662441254, 0.024000000208616257, 0.98000001907348633, 0.98500001430511475 },
2336-+ { 0.085000000894069672, 0.025499999523162842, 0.97874999046325684, 0.98406249284744263 },
2337-+ { 0.08999999612569809, 0.026999998837709427, 0.97750002145767212, 0.98312497138977051 },
2338-+ { 0.094999998807907104, 0.028499998152256012, 0.97624999284744263, 0.98218750953674316 }
2339-+ }
2340-+ },
2341-+ };
2342-+
2343-+ typedef std::tr1::tuple <OffsetParameters, unsigned int> AnimParam;
2344-+}
2345-+
2346-+class ExpoWallOffsetTestAnimations :
2347-+ public ExpoWallOffsetTest,
2348-+ public ::testing::WithParamInterface <AnimParam>
2349-+{
2350-+ public:
2351-+
2352-+ void
2353-+ RecordProperty (const char *name, float value)
2354-+ {
2355-+ ::testing::Message message;
2356-+ message << value;
2357-+ Test::RecordProperty (name, message.GetString ().c_str ());
2358-+ }
2359-+};
2360-+
2361-+TEST_P (ExpoWallOffsetTestAnimations, TestAnimationValues)
2362-+{
2363-+ const OffsetParameters &offset (std::tr1::get <0> (GetParam ()));
2364-+ const unsigned int &index (std::tr1::get <1> (GetParam ()));
2365-+
2366-+ RecordProperty ("outputWidth", offset.outputWidth);
2367-+ RecordProperty ("outputHeight", offset.outputHeight);
2368-+ RecordProperty ("screenWidth", offset.screenWidth);
2369-+ RecordProperty ("screenHeight", offset.screenHeight);
2370-+ RecordProperty ("offsetX", offset.offsetX);
2371-+ RecordProperty ("offsetY", offset.offsetY);
2372-+
2373-+ RecordProperty ("expected.offsetInWorldX", offset.animationParameters[index].offsetInWorldX);
2374-+ RecordProperty ("expected.offsetInWorldY", offset.animationParameters[index].offsetInWorldY);
2375-+ RecordProperty ("expected.worldScaleFactorX", offset.animationParameters[index].worldScaleFactorX);
2376-+ RecordProperty ("expected.worldScaleFactorY", offset.animationParameters[index].worldScaleFactorY);
2377-+
2378-+ compiz::expo::calculateWallOffset (CompRect (0,
2379-+ 0,
2380-+ offset.outputWidth,
2381-+ offset.outputWidth),
2382-+ CompPoint (offset.offsetX,
2383-+ offset.offsetY),
2384-+ CompPoint (offset.vpSizeWidth,
2385-+ offset.vpSizeHeight),
2386-+ CompSize (offset.screenWidth,
2387-+ offset.screenHeight),
2388-+ offsetInWorldX,
2389-+ offsetInWorldY,
2390-+ worldScaleFactorX,
2391-+ worldScaleFactorY,
2392-+ index / static_cast <float> (nAnimationSteps));
2393-+
2394-+ RecordProperty ("offsetInWorldX", offsetInWorldX);
2395-+ RecordProperty ("offsetInWorldY", offsetInWorldY);
2396-+ RecordProperty ("worldScaleFactorX", worldScaleFactorX);
2397-+ RecordProperty ("worldScaleFactorY", worldScaleFactorY);
2398-+
2399-+ EXPECT_EQ (offsetInWorldX, offset.animationParameters[index].offsetInWorldX);
2400-+ EXPECT_EQ (offsetInWorldY, offset.animationParameters[index].offsetInWorldY);
2401-+ EXPECT_EQ (worldScaleFactorX, offset.animationParameters[index].worldScaleFactorX);
2402-+ EXPECT_EQ (worldScaleFactorY, offset.animationParameters[index].worldScaleFactorY);
2403-+}
2404-+
2405-+TEST_F (ExpoWallOffsetTest, TestNoOffsetIfOutputIsNotOrigin)
2406-+{
2407-+ compiz::expo::calculateWallOffset (CompRect (1,
2408-+ 1,
2409-+ 100,
2410-+ 100),
2411-+ CompPoint (100,
2412-+ 100),
2413-+ CompPoint (1,
2414-+ 1),
2415-+ CompSize (100,
2416-+ 100),
2417-+ offsetInWorldX,
2418-+ offsetInWorldY,
2419-+ worldScaleFactorX,
2420-+ worldScaleFactorY,
2421-+ 1.0);
2422-+
2423-+ EXPECT_EQ (offsetInWorldX, 0.0f);
2424-+ EXPECT_EQ (offsetInWorldY, 0.0f);
2425-+ EXPECT_EQ (worldScaleFactorX, 1.0f);
2426-+ EXPECT_EQ (worldScaleFactorY, 1.0f);
2427-+}
2428-+
2429-+INSTANTIATE_TEST_CASE_P (ExpoAnimationOffsetTest,
2430-+ ExpoWallOffsetTestAnimations,
2431-+ Combine (ValuesIn (testingOffsetParameters),
2432-+ Range (nAnimationsBegin,
2433-+ nAnimationSteps)));
2434-Index: ubuntu/plugins/expo/CMakeLists.txt
2435-===================================================================
2436---- ubuntu.orig/plugins/expo/CMakeLists.txt 2012-09-08 17:26:40.599035911 +0800
2437-+++ ubuntu/plugins/expo/CMakeLists.txt 2012-09-12 22:20:43.300760590 +0800
2438-@@ -1,7 +1,16 @@
2439- find_package (Compiz REQUIRED)
2440- include (CompizPlugin)
2441-
2442-+set (COMPIZ_EXPO_PLUGIN_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/src)
2443-+
2444- add_subdirectory (src/click_threshold)
2445- include_directories (src/click_threshold/include)
2446-+add_subdirectory (src/wall_offset)
2447-+include_directories (src/wall_offset/include)
2448-+add_subdirectory (src/windows_on_viewport)
2449-+include_directories (src/windows_on_viewport/include)
2450-
2451--compiz_plugin (expo PLUGINDEPS composite opengl LIBRARIES compiz_expo_click_threshold)
2452-+compiz_plugin (expo PLUGINDEPS composite opengl LIBRARIES
2453-+ compiz_expo_click_threshold
2454-+ compiz_expo_wall_offset
2455-+ compiz_expo_windows_on_viewport)
2456-Index: ubuntu/plugins/expo/src/windows_on_viewport/CMakeLists.txt
2457-===================================================================
2458---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2459-+++ ubuntu/plugins/expo/src/windows_on_viewport/CMakeLists.txt 2012-09-12 22:20:43.300760590 +0800
2460-@@ -0,0 +1,36 @@
2461-+include_directories (
2462-+ ${CMAKE_CURRENT_SOURCE_DIR}/include
2463-+ ${CMAKE_CURRENT_SOURCE_DIR}/src
2464-+ ${COMPIZ_INCLUDE_DIRS}
2465-+ ${COMPIZ_EXPO_PLUGIN_SOURCE_DIR}
2466-+ ${Boost_INCLUDE_DIRS}
2467-+ ${GLIBMM_INCLUDE_DIRS}
2468-+)
2469-+
2470-+link_directories (${GLIBMM_LIBRARY_DIRS} ${COMPIZ_LIBRARY_DIRS})
2471-+
2472-+set (
2473-+ PRIVATE_HEADERS
2474-+ ${CMAKE_CURRENT_SOURCE_DIR}/include/windows-on-viewport.h
2475-+)
2476-+
2477-+set (
2478-+ SRCS
2479-+ ${CMAKE_CURRENT_SOURCE_DIR}/src/windows-on-viewport.cpp
2480-+)
2481-+
2482-+add_library (
2483-+ compiz_expo_windows_on_viewport STATIC
2484-+ ${SRCS}
2485-+ ${PRIVATE_HEADERS}
2486-+)
2487-+
2488-+if (COMPIZ_BUILD_TESTING)
2489-+ add_subdirectory ( ${CMAKE_CURRENT_SOURCE_DIR}/tests )
2490-+endif (COMPIZ_BUILD_TESTING)
2491-+
2492-+target_link_libraries (
2493-+ compiz_expo_windows_on_viewport
2494-+ compiz_window_geometry
2495-+ compiz_core
2496-+)
2497-Index: ubuntu/plugins/expo/src/windows_on_viewport/include/windows-on-viewport.h
2498-===================================================================
2499---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2500-+++ ubuntu/plugins/expo/src/windows_on_viewport/include/windows-on-viewport.h 2012-09-12 22:31:06.807852402 +0800
2501-@@ -0,0 +1,43 @@
2502-+/**
2503-+ * Copyright © 2012 Canonical Ltd.
2504-+ *
2505-+ * Authors:
2506-+ * Sam Spilsbury <sam.spilsbury@canonical.com>
2507-+ *
2508-+ * This program is free software; you can redistribute it and/or
2509-+ * modify it under the terms of the GNU General Public License
2510-+ * as published by the Free Software Foundation; either version 2
2511-+ * of the License, or (at your option) any later version.
2512-+ *
2513-+ * This program is distributed in the hope that it will be useful,
2514-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
2515-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2516-+ * GNU General Public License for more details.
2517-+ *
2518-+ **/
2519-+#ifndef _COMPIZ_EXPO_WINDOWS_ON_VIEWPORT_H
2520-+#define _COMPIZ_EXPO_WINDOWS_ON_VIEWPORT_H
2521-+
2522-+#include <core/point.h>
2523-+#include <core/size.h>
2524-+#include <core/rect.h>
2525-+#include "client-list-generator.h"
2526-+
2527-+namespace compiz
2528-+{
2529-+ namespace expo
2530-+ {
2531-+ unsigned int countViewports (const CompSize &vpSize);
2532-+
2533-+ void fillInNewViewportActiveData (unsigned int vpCount,
2534-+ std::vector <bool> &vpActive);
2535-+
2536-+ void activeViewportsForMembers (compiz::expo::ClientListGenerator &clientList,
2537-+ const CompPoint &cursor,
2538-+ const CompSize &vpSize,
2539-+ const CompSize &screenSize,
2540-+ std::vector <bool> &viewportActiveStates);
2541-+ }
2542-+}
2543-+
2544-+#endif
2545-Index: ubuntu/plugins/expo/src/windows_on_viewport/src/windows-on-viewport.cpp
2546-===================================================================
2547---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2548-+++ ubuntu/plugins/expo/src/windows_on_viewport/src/windows-on-viewport.cpp 2012-09-12 22:20:43.300760590 +0800
2549-@@ -0,0 +1,80 @@
2550-+/**
2551-+ * Copyright © 2012 Canonical Ltd.
2552-+ *
2553-+ * Authors:
2554-+ * Sam Spilsbury <sam.spilsbury@canonical.com>
2555-+ *
2556-+ * This program is free software; you can redistribute it and/or
2557-+ * modify it under the terms of the GNU General Public License
2558-+ * as published by the Free Software Foundation; either version 2
2559-+ * of the License, or (at your option) any later version.
2560-+ *
2561-+ * This program is distributed in the hope that it will be useful,
2562-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
2563-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2564-+ * GNU General Public License for more details.
2565-+ *
2566-+ **/
2567-+#include <cstdio>
2568-+#include <algorithm>
2569-+#include "windows-on-viewport.h"
2570-+#include "viewport-member-window.h"
2571-+
2572-+namespace compiz
2573-+{
2574-+ namespace expo
2575-+ {
2576-+ unsigned int countViewports (const CompSize &vpSize)
2577-+ {
2578-+ return vpSize.width () * vpSize.height ();
2579-+ }
2580-+
2581-+ void fillInNewViewportActiveData (unsigned int vpCount,
2582-+ std::vector <bool> &vpActive)
2583-+ {
2584-+ if (vpActive.size () < vpCount)
2585-+ {
2586-+ unsigned int last = vpActive.size () - 1;
2587-+ vpActive.resize (vpCount);
2588-+ for (unsigned int i = last; i < vpActive.size (); i++)
2589-+ vpActive[i] = false;
2590-+ }
2591-+ }
2592-+
2593-+ void activeViewportsForMembers (compiz::expo::ClientListGenerator &clientList,
2594-+ const CompPoint &cursor,
2595-+ const CompSize &vpSize,
2596-+ const CompSize &screenSize,
2597-+ std::vector <bool> &viewportActiveStates)
2598-+ {
2599-+ compiz::expo::ViewportMemberWindow *vpMemberWindow = clientList.nextClient ();
2600-+
2601-+ fillInNewViewportActiveData (countViewports (vpSize), viewportActiveStates);
2602-+ std::fill_n (viewportActiveStates.begin (), viewportActiveStates.size (), false);
2603-+
2604-+ while (vpMemberWindow)
2605-+ {
2606-+ if (!vpMemberWindow->isDesktopOrDock ())
2607-+ {
2608-+ CompPoint viewport;
2609-+
2610-+ /* If this is a dragged window, use the cursor position */
2611-+ if (vpMemberWindow->dragged ())
2612-+ viewport.set (cursor.x () / screenSize.width (),
2613-+ cursor.y () / screenSize.height ());
2614-+ else
2615-+ {
2616-+ const compiz::window::Geometry &geom = vpMemberWindow->absoluteGeometry ();
2617-+ viewport.set (geom.centerX () / screenSize.width (),
2618-+ geom.centerY () / screenSize.height ());
2619-+ }
2620-+
2621-+ unsigned int vpIndex = vpSize.width () * viewport.y () + viewport.x ();
2622-+ viewportActiveStates[vpIndex] = true;
2623-+ }
2624-+
2625-+ vpMemberWindow = clientList.nextClient ();
2626-+ }
2627-+ }
2628-+ }
2629-+}
2630-Index: ubuntu/plugins/expo/src/windows_on_viewport/tests/CMakeLists.txt
2631-===================================================================
2632---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2633-+++ ubuntu/plugins/expo/src/windows_on_viewport/tests/CMakeLists.txt 2012-09-12 22:20:43.300760590 +0800
2634-@@ -0,0 +1,22 @@
2635-+if (NOT GTEST_FOUND)
2636-+ message ("Google Test not found - cannot build tests!")
2637-+ set (COMPIZ_BUILD_TESTING OFF)
2638-+endif (NOT GTEST_FOUND)
2639-+
2640-+include_directories (${GTEST_INCLUDE_DIRS})
2641-+include_directories (${CMAKE_EXPO_PLUGIN_SOURCE_DIR})
2642-+
2643-+link_directories (${COMPIZ_LIBRARY_DIRS})
2644-+
2645-+add_executable (compiz_test_expo_windows_on_viewport
2646-+ ${CMAKE_CURRENT_SOURCE_DIR}/test-windows-on-viewport.cpp)
2647-+
2648-+target_link_libraries (compiz_test_expo_windows_on_viewport
2649-+ compiz_expo_windows_on_viewport
2650-+ ${GTEST_BOTH_LIBRARIES}
2651-+ ${CMAKE_THREAD_LIBS_INIT} # Link in pthread.
2652-+ ${GMOCK_LIBRARY}
2653-+ ${GMOCK_MAIN_LIBRARY}
2654-+ )
2655-+
2656-+compiz_discover_tests (compiz_test_expo_windows_on_viewport COVERAGE compiz_expo_windows_on_viewport)
2657-Index: ubuntu/plugins/expo/src/windows_on_viewport/tests/test-windows-on-viewport.cpp
2658-===================================================================
2659---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2660-+++ ubuntu/plugins/expo/src/windows_on_viewport/tests/test-windows-on-viewport.cpp 2012-09-12 22:20:43.304760606 +0800
2661-@@ -0,0 +1,149 @@
2662-+/*
2663-+ * Copyright © 2012 Canonical Ltd.
2664-+ *
2665-+ * Permission to use, copy, modify, distribute, and sell this software
2666-+ * and its documentation for any purpose is hereby granted without
2667-+ * fee, provided that the above copyright notice appear in all copies
2668-+ * and that both that copyright notice and this permission notice
2669-+ * appear in supporting documentation, and that the name of
2670-+ * Canonical Ltd. not be used in advertising or publicity pertaining to
2671-+ * distribution of the software without specific, written prior permission.
2672-+ * Canonical Ltd. makes no representations about the suitability of this
2673-+ * software for any purpose. It is provided "as is" without express or
2674-+ * implied warranty.
2675-+ *
2676-+ * CANONICAL, LTD. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
2677-+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
2678-+ * NO EVENT SHALL CANONICAL, LTD. BE LIABLE FOR ANY SPECIAL, INDIRECT OR
2679-+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
2680-+ * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
2681-+ * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
2682-+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
2683-+ *
2684-+ * Authored by: Sam Spilsbury <sam.spilsbury@canonical.com>
2685-+ */
2686-+#include <gtest/gtest.h>
2687-+#include <gmock/gmock.h>
2688-+#include "windows-on-viewport.h"
2689-+#include "client-list-generator.h"
2690-+#include "viewport-member-window.h"
2691-+
2692-+using ::testing::InSequence;
2693-+using ::testing::Return;
2694-+using ::testing::ReturnNull;
2695-+using ::testing::ReturnRef;
2696-+
2697-+namespace
2698-+{
2699-+ namespace ce = compiz::expo;
2700-+
2701-+ class MockViewportMemberWindow :
2702-+ public ce::ViewportMemberWindow
2703-+ {
2704-+ public:
2705-+
2706-+ MOCK_CONST_METHOD0 (absoluteGeometry, const compiz::window::Geometry & ());
2707-+ MOCK_CONST_METHOD0 (isDesktopOrDock, bool ());
2708-+ MOCK_CONST_METHOD0 (dragged, bool ());
2709-+ };
2710-+
2711-+ class MockClientListGenerator :
2712-+ public ce::ClientListGenerator
2713-+ {
2714-+ public:
2715-+
2716-+ MOCK_METHOD0 (nextClient, ce::ViewportMemberWindow * ());
2717-+ };
2718-+}
2719-+
2720-+class ExpoWindowsOnViewportTest :
2721-+ public ::testing::Test
2722-+{
2723-+ protected:
2724-+
2725-+ MockClientListGenerator mockClientListGenerator;
2726-+ std::vector <bool> activeStates;
2727-+};
2728-+
2729-+namespace
2730-+{
2731-+ const CompSize vpSize (2, 2);
2732-+ const CompSize screenSize (1000, 1000);
2733-+}
2734-+
2735-+TEST_F (ExpoWindowsOnViewportTest, TestNoDocksMakeViewportsActive)
2736-+{
2737-+ MockViewportMemberWindow mockViewportMembers[1];
2738-+ InSequence s;
2739-+
2740-+ EXPECT_CALL (mockClientListGenerator, nextClient ()).WillOnce (Return (&mockViewportMembers[0]));
2741-+ EXPECT_CALL (mockViewportMembers[0], isDesktopOrDock ()).WillOnce (Return (true));
2742-+ EXPECT_CALL (mockClientListGenerator, nextClient ()).WillOnce (ReturnNull ());
2743-+
2744-+ compiz::expo::activeViewportsForMembers (mockClientListGenerator,
2745-+ CompPoint (1, 1),
2746-+ vpSize,
2747-+ screenSize,
2748-+ activeStates);
2749-+
2750-+ ASSERT_EQ (activeStates.size (), vpSize.width () * vpSize.height ());
2751-+ EXPECT_EQ (activeStates[0], false);
2752-+ EXPECT_EQ (activeStates[1], false);
2753-+ EXPECT_EQ (activeStates[2], false);
2754-+ EXPECT_EQ (activeStates[3], false);
2755-+}
2756-+
2757-+TEST_F (ExpoWindowsOnViewportTest, TestGrabbedWindowUsesCursorPosition)
2758-+{
2759-+ MockViewportMemberWindow mockViewportMembers[1];
2760-+ InSequence s;
2761-+
2762-+ EXPECT_CALL (mockClientListGenerator, nextClient ()).WillOnce (Return (&mockViewportMembers[0]));
2763-+ EXPECT_CALL (mockViewportMembers[0], isDesktopOrDock ()).WillOnce (Return (false));
2764-+ EXPECT_CALL (mockViewportMembers[0], dragged ()).WillOnce (Return (true));
2765-+ EXPECT_CALL (mockClientListGenerator, nextClient ()).WillOnce (ReturnNull ());
2766-+
2767-+ compiz::expo::activeViewportsForMembers (mockClientListGenerator,
2768-+ CompPoint (screenSize.width () * 1.5,
2769-+ screenSize.height () * 1.5),
2770-+ vpSize,
2771-+ screenSize,
2772-+ activeStates);
2773-+
2774-+ ASSERT_EQ (activeStates.size (), vpSize.width () * vpSize.height ());
2775-+ EXPECT_EQ (activeStates[0], false);
2776-+ EXPECT_EQ (activeStates[1], false);
2777-+ EXPECT_EQ (activeStates[2], false);
2778-+ EXPECT_EQ (activeStates[3], true); // 2,2 has the cursor of a dragged window
2779-+}
2780-+
2781-+TEST_F (ExpoWindowsOnViewportTest, TestUngrabbedWindowUsesGeometry)
2782-+{
2783-+ MockViewportMemberWindow mockViewportMembers[1];
2784-+ InSequence s;
2785-+
2786-+ compiz::window::Geometry vpMemberGeometry1 (screenSize.width () * 1.1,
2787-+ screenSize.height () * 1.1,
2788-+ screenSize.width () / 2,
2789-+ screenSize.height () / 2,
2790-+ 0);
2791-+
2792-+ EXPECT_CALL (mockClientListGenerator, nextClient ()).WillOnce (Return (&mockViewportMembers[0]));
2793-+ EXPECT_CALL (mockViewportMembers[0], isDesktopOrDock ()).WillOnce (Return (false));
2794-+ EXPECT_CALL (mockViewportMembers[0], dragged ()).WillOnce (Return (false));
2795-+ EXPECT_CALL (mockViewportMembers[0], absoluteGeometry ()).WillOnce (ReturnRef (vpMemberGeometry1));
2796-+ EXPECT_CALL (mockClientListGenerator, nextClient ()).WillOnce (ReturnNull ());
2797-+
2798-+ compiz::expo::activeViewportsForMembers (mockClientListGenerator,
2799-+ CompPoint (screenSize.width () * 1.5,
2800-+ screenSize.height () * 1.5),
2801-+ vpSize,
2802-+ screenSize,
2803-+ activeStates);
2804-+
2805-+ ASSERT_EQ (activeStates.size (), vpSize.width () * vpSize.height ());
2806-+ EXPECT_EQ (activeStates[0], false);
2807-+ EXPECT_EQ (activeStates[1], false);
2808-+ EXPECT_EQ (activeStates[2], false);
2809-+ EXPECT_EQ (activeStates[3], true); // 2,2 has a window on it
2810-+}
2811-Index: ubuntu/plugins/expo/src/client-list-generator.h
2812-===================================================================
2813---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2814-+++ ubuntu/plugins/expo/src/client-list-generator.h 2012-09-12 22:20:43.304760606 +0800
2815-@@ -0,0 +1,45 @@
2816-+/*
2817-+ * Copyright © 2012 Canonical Ltd.
2818-+ *
2819-+ * Permission to use, copy, modify, distribute, and sell this software
2820-+ * and its documentation for any purpose is hereby granted without
2821-+ * fee, provided that the above copyright notice appear in all copies
2822-+ * and that both that copyright notice and this permission notice
2823-+ * appear in supporting documentation, and that the name of
2824-+ * Canonical Ltd. not be used in advertising or publicity pertaining to
2825-+ * distribution of the software without specific, written prior permission.
2826-+ * Canonical Ltd. makes no representations about the suitability of this
2827-+ * software for any purpose. It is provided "as is" without express or
2828-+ * implied warranty.
2829-+ *
2830-+ * CANONICAL, LTD. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
2831-+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
2832-+ * NO EVENT SHALL CANONICAL, LTD. BE LIABLE FOR ANY SPECIAL, INDIRECT OR
2833-+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
2834-+ * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
2835-+ * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
2836-+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
2837-+ *
2838-+ * Authored by: Sam Spilsbury <sam.spilsbury@canonical.com>
2839-+ */
2840-+#ifndef _COMPIZ_EXPO_CLIENT_LIST_GENERATOR_H
2841-+#define _COMPIZ_EXPO_CLIENT_LIST_GENERATOR_H
2842-+
2843-+namespace compiz
2844-+{
2845-+ namespace expo
2846-+ {
2847-+ class ViewportMemberWindow;
2848-+
2849-+ class ClientListGenerator
2850-+ {
2851-+ public:
2852-+
2853-+ virtual ~ClientListGenerator () {};
2854-+ virtual ViewportMemberWindow * nextClient () = 0;
2855-+ };
2856-+ }
2857-+}
2858-+#endif
2859-+
2860-+
2861-Index: ubuntu/plugins/expo/src/viewport-member-window.h
2862-===================================================================
2863---- /dev/null 1970-01-01 00:00:00.000000000 +0000
2864-+++ ubuntu/plugins/expo/src/viewport-member-window.h 2012-09-12 22:20:43.304760606 +0800
2865-@@ -0,0 +1,46 @@
2866-+/*
2867-+ * Copyright © 2012 Canonical Ltd.
2868-+ *
2869-+ * Permission to use, copy, modify, distribute, and sell this software
2870-+ * and its documentation for any purpose is hereby granted without
2871-+ * fee, provided that the above copyright notice appear in all copies
2872-+ * and that both that copyright notice and this permission notice
2873-+ * appear in supporting documentation, and that the name of
2874-+ * Canonical Ltd. not be used in advertising or publicity pertaining to
2875-+ * distribution of the software without specific, written prior permission.
2876-+ * Canonical Ltd. makes no representations about the suitability of this
2877-+ * software for any purpose. It is provided "as is" without express or
2878-+ * implied warranty.
2879-+ *
2880-+ * CANONICAL, LTD. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
2881-+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
2882-+ * NO EVENT SHALL CANONICAL, LTD. BE LIABLE FOR ANY SPECIAL, INDIRECT OR
2883-+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
2884-+ * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
2885-+ * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
2886-+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
2887-+ *
2888-+ * Authored by: Sam Spilsbury <sam.spilsbury@canonical.com>
2889-+ */
2890-+#ifndef _COMPIZ_EXPO_VIEWPORT_MEMBER_WINDOW_H
2891-+#define _COMPIZ_EXPO_VIEWPORT_MEMBER_WINDOW_H
2892-+
2893-+#include <core/windowgeometry.h>
2894-+
2895-+namespace compiz
2896-+{
2897-+ namespace expo
2898-+ {
2899-+ class ViewportMemberWindow
2900-+ {
2901-+ public:
2902-+
2903-+ virtual ~ViewportMemberWindow () {};
2904-+ virtual const compiz::window::Geometry & absoluteGeometry () const = 0;
2905-+ virtual bool dragged () const = 0;
2906-+ virtual bool isDesktopOrDock () const = 0;
2907-+ };
2908-+ }
2909-+}
2910-+
2911-+#endif
2912
2913=== modified file 'debian/patches/series'
2914--- debian/patches/series 2012-10-09 11:02:28 +0000
2915+++ debian/patches/series 2012-11-28 09:52:53 +0000
2916@@ -6,5 +6,4 @@
2917 ccsm_add_first_run_warning.patch
2918 ccsm_disable_unity_checkbox.patch
2919 99_valid_ccsm_desktop_file.patch
2920-100_expo_layout.patch
2921 unity_support_test.patch
2922
2923=== modified file 'debian/patches/ubuntu-config.patch'
2924--- debian/patches/ubuntu-config.patch 2012-08-27 19:12:22 +0000
2925+++ debian/patches/ubuntu-config.patch 2012-11-28 09:52:53 +0000
2926@@ -1,7 +1,9 @@
2927 === modified file 'metadata/core.xml.in'
2928---- old/metadata/core.xml.in 2012-03-09 16:13:05 +0000
2929-+++ new/metadata/core.xml.in 2012-07-27 12:41:52 +0000
2930-@@ -138,7 +138,7 @@
2931+Index: new/metadata/core.xml.in
2932+===================================================================
2933+--- old/metadata/core.xml.in 2012-11-23 18:54:15.673949000 +0800
2934++++ new/metadata/core.xml.in 2012-11-23 18:54:59.307064517 +0800
2935+@@ -139,7 +139,7 @@
2936 <option name="focus_prevention_match" type="match">
2937 <_short>Focus Prevention Windows</_short>
2938 <_long>Focus prevention windows</_long>
2939@@ -10,7 +12,7 @@
2940 </option>
2941 </group>
2942 <group>
2943-@@ -173,7 +173,7 @@
2944+@@ -174,7 +174,7 @@
2945 <option name="minimize_window_key" type="key">
2946 <_short>Minimize Window</_short>
2947 <_long>Minimize active window</_long>
2948@@ -19,7 +21,7 @@
2949 </option>
2950 <option name="minimize_window_button" type="button">
2951 <_short>Minimize Window</_short>
2952-@@ -182,12 +182,12 @@
2953+@@ -183,12 +183,12 @@
2954 <option name="maximize_window_key" type="key">
2955 <_short>Maximize Window</_short>
2956 <_long>Maximize active window</_long>
2957@@ -34,7 +36,7 @@
2958 </option>
2959 <option name="maximize_window_horizontally_key" type="key">
2960 <_short>Maximize Window Horizontally</_short>
2961-@@ -210,7 +210,7 @@
2962+@@ -211,7 +211,7 @@
2963 <option name="show_desktop_key" type="key">
2964 <_short>Show Desktop</_short>
2965 <_long>Hide all windows and focus desktop</_long>
2966@@ -43,7 +45,7 @@
2967 </option>
2968 <option name="show_desktop_edge" type="edge">
2969 <_short>Show Desktop</_short>
2970-@@ -220,6 +220,7 @@
2971+@@ -221,6 +221,7 @@
2972 <option name="toggle_window_maximized_key" type="key">
2973 <_short>Toggle Window Maximized</_short>
2974 <_long>Toggle active window maximized</_long>
2975@@ -51,7 +53,7 @@
2976 </option>
2977 <option name="toggle_window_maximized_button" type="button">
2978 <_short>Toggle Window Maximized</_short>
2979-@@ -244,14 +245,14 @@
2980+@@ -245,14 +246,14 @@
2981 <option name="hsize" type="int">
2982 <_short>Horizontal Virtual Size</_short>
2983 <_long>Screen size multiplier for horizontal virtual size</_long>
2984@@ -68,11 +70,11 @@
2985 <min>1</min>
2986 <max>32</max>
2987 </option>
2988-
2989-=== modified file 'plugins/animation/animation.xml.in'
2990---- old/plugins/animation/animation.xml.in 2012-05-16 17:40:41 +0000
2991-+++ new/plugins/animation/animation.xml.in 2012-07-27 12:41:52 +0000
2992-@@ -35,7 +35,7 @@
2993+Index: new/plugins/animation/animation.xml.in
2994+===================================================================
2995+--- old/plugins/animation/animation.xml.in 2012-11-23 18:54:15.673949000 +0800
2996++++ new/plugins/animation/animation.xml.in 2012-11-23 18:54:59.307064517 +0800
2997+@@ -36,7 +36,7 @@
2998 <extensible/>
2999 <sort start="2"/>
3000 <default>
3001@@ -81,7 +83,7 @@
3002 <value>animation:Fade</value>
3003 <value>animation:Fade</value>
3004 </default>
3005-@@ -47,9 +47,9 @@
3006+@@ -48,9 +48,9 @@
3007 <min>50</min>
3008 <max>4000</max>
3009 <default>
3010@@ -94,7 +96,7 @@
3011 </default>
3012 </option>
3013 <option name="open_matches" type="list">
3014-@@ -57,8 +57,8 @@
3015+@@ -58,8 +58,8 @@
3016 <_long>The windows that will be animated.</_long>
3017 <type>match</type>
3018 <default>
3019@@ -105,7 +107,7 @@
3020 <value>(type=Tooltip | Notification | Utility) &amp; !(name=compiz) &amp; !(title=notify-osd)</value>
3021 </default>
3022 </option>
3023-@@ -101,7 +101,7 @@
3024+@@ -102,7 +102,7 @@
3025 <extensible/>
3026 <sort start="2"/>
3027 <default>
3028@@ -114,7 +116,7 @@
3029 <value>animation:Fade</value>
3030 <value>animation:Fade</value>
3031 </default>
3032-@@ -113,9 +113,9 @@
3033+@@ -114,9 +114,9 @@
3034 <min>50</min>
3035 <max>4000</max>
3036 <default>
3037@@ -127,7 +129,7 @@
3038 </default>
3039 </option>
3040 <option name="close_matches" type="list">
3041-@@ -123,8 +123,8 @@
3042+@@ -124,8 +124,8 @@
3043 <_long>The windows that will be animated.</_long>
3044 <type>match</type>
3045 <default>
3046@@ -138,7 +140,7 @@
3047 <value>(type=Tooltip | Notification | Utility) &amp; !(name=compiz) &amp; !(title=notify-osd)</value>
3048 </default>
3049 </option>
3050-@@ -167,7 +167,7 @@
3051+@@ -168,7 +168,7 @@
3052 <extensible/>
3053 <sort start="2"/>
3054 <default>
3055@@ -147,7 +149,7 @@
3056 </default>
3057 </option>
3058 <option name="minimize_durations" type="list">
3059-@@ -177,7 +177,7 @@
3060+@@ -178,7 +178,7 @@
3061 <min>50</min>
3062 <max>4000</max>
3063 <default>
3064@@ -156,7 +158,7 @@
3065 </default>
3066 </option>
3067 <option name="minimize_matches" type="list">
3068-@@ -282,7 +282,7 @@
3069+@@ -341,7 +341,7 @@
3070 <extensible/>
3071 <sort start="1"/>
3072 <default>
3073@@ -165,7 +167,7 @@
3074 </default>
3075 </option>
3076 <option name="focus_durations" type="list">
3077-@@ -292,7 +292,7 @@
3078+@@ -351,7 +351,7 @@
3079 <min>50</min>
3080 <max>4000</max>
3081 <default>
3082@@ -174,7 +176,7 @@
3083 </default>
3084 </option>
3085 <option name="focus_matches" type="list">
3086-@@ -326,7 +326,7 @@
3087+@@ -385,7 +385,7 @@
3088 <option name="time_step" type="int">
3089 <_short>Animation Time Step</_short>
3090 <_long>The amount of time in milliseconds between each render of the animation. The higher the number, the jerkier the movements become.</_long>
3091@@ -183,7 +185,7 @@
3092 <min>1</min>
3093 <max>400</max>
3094 </option>
3095-@@ -414,7 +414,7 @@
3096+@@ -473,7 +473,7 @@
3097 <option name="glide2_away_position" type="float">
3098 <_short>Away Position</_short>
3099 <_long>Closeness of window to camera at the end of the animation (1.0: Close to camera, -2.0: Away from camera).</_long>
3100@@ -192,7 +194,7 @@
3101 <min>-2</min>
3102 <max>1</max>
3103 <precision>0.05</precision>
3104-@@ -422,7 +422,7 @@
3105+@@ -481,7 +481,7 @@
3106 <option name="glide2_away_angle" type="float">
3107 <_short>Away Angle</_short>
3108 <_long>Angle of window at the end of the animation.</_long>
3109@@ -201,7 +203,7 @@
3110 <min>-540</min>
3111 <max>540</max>
3112 <precision>5</precision>
3113-@@ -627,7 +627,7 @@
3114+@@ -686,7 +686,7 @@
3115 <option name="zoom_springiness" type="float">
3116 <_short>Springiness</_short>
3117 <_long>How spring-like the Zoom animation should be.</_long>
3118@@ -210,11 +212,11 @@
3119 <min>0</min>
3120 <max>1</max>
3121 <precision>0.01</precision>
3122-
3123-=== modified file 'plugins/decor/decor.xml.in'
3124---- old/plugins/decor/decor.xml.in 2012-06-24 09:00:27 +0000
3125-+++ new/plugins/decor/decor.xml.in 2012-07-27 12:41:52 +0000
3126-@@ -30,7 +30,7 @@
3127+Index: new/plugins/decor/decor.xml.in
3128+===================================================================
3129+--- old/plugins/decor/decor.xml.in 2012-11-23 18:54:15.673949000 +0800
3130++++ new/plugins/decor/decor.xml.in 2012-11-23 18:54:59.307064517 +0800
3131+@@ -31,7 +31,7 @@
3132 <option name="active_shadow_opacity" type="float">
3133 <_short>Shadow Opacity</_short>
3134 <_long>Drop shadow opacity</_long>
3135@@ -223,7 +225,7 @@
3136 <min>0.01</min>
3137 <max>6.0</max>
3138 <precision>0.01</precision>
3139-@@ -65,7 +65,7 @@
3140+@@ -66,7 +66,7 @@
3141 <option name="inactive_shadow_radius" type="float">
3142 <_short>Shadow Radius</_short>
3143 <_long>Drop shadow radius</_long>
3144@@ -232,7 +234,7 @@
3145 <min>0.1</min>
3146 <max>13.0</max>
3147 <precision>0.1</precision>
3148-@@ -73,7 +73,7 @@
3149+@@ -74,7 +74,7 @@
3150 <option name="inactive_shadow_opacity" type="float">
3151 <_short>Shadow Opacity</_short>
3152 <_long>Drop shadow opacity</_long>
3153@@ -241,7 +243,7 @@
3154 <min>0.01</min>
3155 <max>6.0</max>
3156 <precision>0.01</precision>
3157-@@ -100,7 +100,7 @@
3158+@@ -101,7 +101,7 @@
3159 <option name="command" type="string">
3160 <_short>Command</_short>
3161 <_long>Decorator command line that is executed if no decorator is already running.</_long>
3162@@ -250,22 +252,125 @@
3163 </option>
3164 <option name="mipmap" type="bool">
3165 <_short>Mipmap</_short>
3166-
3167-=== modified file 'plugins/expo/expo.xml.in'
3168---- old/plugins/expo/expo.xml.in 2012-05-16 17:40:58 +0000
3169-+++ new/plugins/expo/expo.xml.in 2012-07-27 12:41:52 +0000
3170-@@ -36,7 +36,6 @@
3171+Index: new/plugins/expo/expo.xml.in
3172+===================================================================
3173+--- old/plugins/expo/expo.xml.in 2012-11-23 18:54:15.673949000 +0800
3174++++ new/plugins/expo/expo.xml.in 2012-11-23 18:55:22.875064959 +0800
3175+@@ -17,6 +17,7 @@
3176+ <plugin>wobbly</plugin>
3177+ <plugin>animation</plugin>
3178+ <plugin>wallpaper</plugin>
3179++ <plugin>imgpng</plugin>
3180+ </relation>
3181+ </deps>
3182+ <options>
3183+@@ -25,7 +26,7 @@
3184+ <option name="expo_key" type="key">
3185+ <_short>Expo key</_short>
3186+ <_long>Engage wall expo mode key binding</_long>
3187+- <default>&lt;Super&gt;e</default>
3188++ <default>&lt;Super&gt;s</default>
3189+ </option>
3190+ <option name="expo_button" type="button">
3191+ <_short>Expo button</_short>
3192+@@ -35,9 +36,6 @@
3193+ <option name="expo_edge" type="edge">
3194 <_short>Expo edge</_short>
3195 <_long>Engage wall expo mode edge binding</_long>
3196- <default>
3197+- <default>
3198 - <edge name="TopLeft"/>
3199- </default>
3200+- </default>
3201 </option>
3202 <option name="double_click_time" type="int">
3203-
3204-=== modified file 'plugins/ezoom/ezoom.xml.in'
3205---- old/plugins/ezoom/ezoom.xml.in 2012-05-16 17:40:27 +0000
3206-+++ new/plugins/ezoom/ezoom.xml.in 2012-07-27 12:41:52 +0000
3207+ <_short>Double click time</_short>
3208+@@ -80,7 +78,7 @@
3209+ <option name="zoom_time" type="float">
3210+ <_short>Zoom time</_short>
3211+ <_long>Duration of the zoomout animation</_long>
3212+- <default>0.5</default>
3213++ <default>0.3</default>
3214+ <min>0.1</min>
3215+ <max>5.0</max>
3216+ <precision>0.1</precision>
3217+@@ -134,17 +132,17 @@
3218+ <option name="x_offset" type="int">
3219+ <_short>X Offset</_short>
3220+ <_long>X offset in pixels</_long>
3221+- <default>0</default>
3222++ <default>64</default>
3223+ </option>
3224+ <option name="y_offset" type="int">
3225+ <_short>Y Offset</_short>
3226+ <_long>Y offset in pixels</_long>
3227+- <default>0</default>
3228++ <default>24</default>
3229+ </option>
3230+ <option name="distance" type="float">
3231+ <_short>Distance</_short>
3232+ <_long>Distance of the expo wall</_long>
3233+- <default>0.0</default>
3234++ <default>0.005</default>
3235+ <min>0.0</min>
3236+ <max>1.0</max>
3237+ <precision>0.01</precision>
3238+@@ -152,7 +150,7 @@
3239+ <option name="vp_distance" type="float">
3240+ <_short>Viewport distance</_short>
3241+ <_long>Distance between viewports</_long>
3242+- <default>0.10</default>
3243++ <default>0.2</default>
3244+ <min>0.0</min>
3245+ <max>1.0</max>
3246+ <precision>0.01</precision>
3247+@@ -203,7 +201,7 @@
3248+ <option name="vp_brightness" type="float">
3249+ <_short>Brightness</_short>
3250+ <_long>Inactive viewport brightness.</_long>
3251+- <default>75.0</default>
3252++ <default>40.0</default>
3253+ <min>0.0</min>
3254+ <max>100.0</max>
3255+ <precision>0.1</precision>
3256+@@ -211,7 +209,7 @@
3257+ <option name="vp_saturation" type="float">
3258+ <_short>Saturation</_short>
3259+ <_long>Inactive viewport saturation.</_long>
3260+- <default>100.0</default>
3261++ <default>40.0</default>
3262+ <min>0.0</min>
3263+ <max>100.0</max>
3264+ <precision>0.1</precision>
3265+@@ -223,7 +221,7 @@
3266+ <red>0xfbfb</red>
3267+ <green>0x8b8b</green>
3268+ <blue>0x0</blue>
3269+- <alpha>0x0</alpha>
3270++ <alpha>0xffff</alpha>
3271+ </default>
3272+ </option>
3273+ </subgroup>
3274+@@ -232,7 +230,7 @@
3275+ <option name="reflection" type="bool">
3276+ <_short>Reflection</_short>
3277+ <_long>Show a reflection of the viewports on the ground</_long>
3278+- <default>true</default>
3279++ <default>false</default>
3280+ </option>
3281+ <option name="ground_color1" type="color">
3282+ <_short>Ground color(near)</_short>
3283+@@ -265,7 +263,7 @@
3284+ <option name="scale_factor" type="float">
3285+ <_short>Reflection Scale</_short>
3286+ <_long>Scale factor of the expo wall reflection</_long>
3287+- <default>0.75</default>
3288++ <default>1.0</default>
3289+ <min>0.0</min>
3290+ <max>2.0</max>
3291+ <precision>0.01</precision>
3292+Index: new/plugins/ezoom/ezoom.xml.in
3293+===================================================================
3294+--- old/plugins/ezoom/ezoom.xml.in 2012-11-23 18:54:15.673949000 +0800
3295++++ new/plugins/ezoom/ezoom.xml.in 2012-11-23 18:54:59.307064517 +0800
3296 @@ -29,7 +29,6 @@
3297 <option type="button" name="zoom_in_button">
3298 <_short>Zoom In</_short>
3299@@ -299,11 +404,11 @@
3300 </option>
3301 </subgroup>
3302 </group>
3303-
3304-=== modified file 'plugins/fade/fade.xml.in'
3305---- old/plugins/fade/fade.xml.in 2011-06-27 13:32:58 +0000
3306-+++ new/plugins/fade/fade.xml.in 2012-07-27 12:41:52 +0000
3307-@@ -9,6 +9,7 @@
3308+Index: new/plugins/fade/fade.xml.in
3309+===================================================================
3310+--- old/plugins/fade/fade.xml.in 2012-11-23 18:54:15.673949000 +0800
3311++++ new/plugins/fade/fade.xml.in 2012-11-23 18:54:59.307064517 +0800
3312+@@ -10,6 +10,7 @@
3313 </requirement>
3314 <relation type="after">
3315 <plugin>decor</plugin>
3316@@ -311,7 +416,7 @@
3317 </relation>
3318 <relation type="before">
3319 <plugin>cube</plugin>
3320-@@ -49,7 +50,7 @@
3321+@@ -50,7 +51,7 @@
3322 <option name="window_match" type="match">
3323 <_short>Fade windows</_short>
3324 <_long>Windows that should be fading</_long>
3325@@ -320,11 +425,11 @@
3326 </option>
3327 <option name="visual_bell" type="bell">
3328 <_short>Visual Bell</_short>
3329-
3330-=== modified file 'plugins/gnomecompat/gnomecompat.xml.in'
3331---- old/plugins/gnomecompat/gnomecompat.xml.in 2010-12-07 05:03:07 +0000
3332-+++ new/plugins/gnomecompat/gnomecompat.xml.in 2012-07-27 12:41:52 +0000
3333-@@ -52,6 +52,7 @@
3334+Index: new/plugins/gnomecompat/gnomecompat.xml.in
3335+===================================================================
3336+--- old/plugins/gnomecompat/gnomecompat.xml.in 2012-11-23 18:54:15.673949000 +0800
3337++++ new/plugins/gnomecompat/gnomecompat.xml.in 2012-11-23 18:54:59.307064517 +0800
3338+@@ -53,6 +53,7 @@
3339 <option name="run_command_terminal_key" type="key">
3340 <_short>Open a terminal</_short>
3341 <_long>Open a terminal</_long>
3342@@ -332,10 +437,10 @@
3343 </option>
3344 </group>
3345 </options>
3346-
3347-=== modified file 'plugins/grid/grid.xml.in'
3348---- old/plugins/grid/grid.xml.in 2012-05-16 17:43:21 +0000
3349-+++ new/plugins/grid/grid.xml.in 2012-07-27 12:41:52 +0000
3350+Index: new/plugins/grid/grid.xml.in
3351+===================================================================
3352+--- old/plugins/grid/grid.xml.in 2012-11-23 18:54:15.673949000 +0800
3353++++ new/plugins/grid/grid.xml.in 2012-11-23 18:54:59.307064517 +0800
3354 @@ -23,17 +23,16 @@
3355 <option name="put_center_key" type="key">
3356 <_short>Put Center</_short>
3357@@ -364,11 +469,11 @@
3358 </option>
3359 <option name="put_restore_key" type="key">
3360 <_short>Restore</_short>
3361-
3362-=== modified file 'plugins/place/place.xml.in'
3363---- old/plugins/place/place.xml.in 2011-10-13 14:36:35 +0000
3364-+++ new/plugins/place/place.xml.in 2012-07-27 12:41:52 +0000
3365-@@ -19,8 +19,8 @@
3366+Index: new/plugins/place/place.xml.in
3367+===================================================================
3368+--- old/plugins/place/place.xml.in 2012-11-23 18:54:15.673949000 +0800
3369++++ new/plugins/place/place.xml.in 2012-11-23 18:54:59.307064517 +0800
3370+@@ -20,8 +20,8 @@
3371 <option name="mode" type="int">
3372 <_short>Placement Mode</_short>
3373 <_long>Algorithm to use for window placement</_long>
3374@@ -379,10 +484,10 @@
3375 <max>5</max>
3376 <desc>
3377 <value>0</value>
3378-
3379-=== modified file 'plugins/resize/resize.xml.in'
3380---- old/plugins/resize/resize.xml.in 2011-05-01 20:59:20 +0000
3381-+++ new/plugins/resize/resize.xml.in 2012-07-27 12:41:52 +0000
3382+Index: new/plugins/resize/resize.xml.in
3383+===================================================================
3384+--- old/plugins/resize/resize.xml.in 2012-11-23 18:54:15.673949000 +0800
3385++++ new/plugins/resize/resize.xml.in 2012-11-23 18:54:59.307064517 +0800
3386 @@ -28,7 +28,7 @@
3387 <option name="mode" type="int">
3388 <_short>Default Resize Mode</_short>
3389@@ -427,11 +532,11 @@
3390 </default>
3391 </option>
3392 <subgroup>
3393-
3394-=== modified file 'plugins/scale/scale.xml.in'
3395---- old/plugins/scale/scale.xml.in 2011-09-19 13:00:51 +0000
3396-+++ new/plugins/scale/scale.xml.in 2012-07-27 12:42:13 +0000
3397-@@ -18,14 +18,14 @@
3398+Index: new/plugins/scale/scale.xml.in
3399+===================================================================
3400+--- old/plugins/scale/scale.xml.in 2012-11-23 18:54:15.673949000 +0800
3401++++ new/plugins/scale/scale.xml.in 2012-11-23 18:54:59.307064517 +0800
3402+@@ -19,14 +19,14 @@
3403 <option name="spacing" type="int">
3404 <_short>Spacing</_short>
3405 <_long>Space between windows</_long>
3406@@ -448,7 +553,7 @@
3407 <min>0.1</min>
3408 <max>50</max>
3409 <precision>0.1</precision>
3410-@@ -33,7 +33,7 @@
3411+@@ -34,7 +34,7 @@
3412 <option name="timestep" type="float">
3413 <_short>Timestep</_short>
3414 <_long>Scale timestep</_long>
3415@@ -457,7 +562,7 @@
3416 <min>0.1</min>
3417 <max>50</max>
3418 <precision>0.1</precision>
3419-@@ -46,7 +46,7 @@
3420+@@ -47,7 +47,7 @@
3421 <option name="opacity" type="int">
3422 <_short>Opacity</_short>
3423 <_long>Amount of opacity in percent</_long>
3424@@ -466,7 +571,7 @@
3425 <min>0</min>
3426 <max>100</max>
3427 </option>
3428-@@ -55,7 +55,7 @@
3429+@@ -56,7 +56,7 @@
3430 <_long>Overlay an icon on windows once they are scaled</_long>
3431 <min>0</min>
3432 <max>2</max>
3433@@ -475,7 +580,7 @@
3434 <desc>
3435 <value>0</value>
3436 <_name>None</_name>
3437-@@ -96,7 +96,7 @@
3438+@@ -97,7 +97,7 @@
3439 <_long>Selects where windows are scaled if multiple output devices are used.</_long>
3440 <min>0</min>
3441 <max>1</max>
3442@@ -484,7 +589,7 @@
3443 <desc>
3444 <value>0</value>
3445 <_name>On current output device</_name>
3446-@@ -112,7 +112,7 @@
3447+@@ -113,7 +113,7 @@
3448 <option name="key_bindings_toggle" type="bool">
3449 <_short>Key Bindings Toggle Scale Mode</_short>
3450 <_long>Key bindings toggle scale mode instead of enabling it when pressed and disabling it when released.</_long>
3451@@ -493,7 +598,7 @@
3452 </option>
3453 <option name="button_bindings_toggle" type="bool">
3454 <_short>Button Bindings Toggle Scale Mode</_short>
3455-@@ -122,15 +122,12 @@
3456+@@ -123,15 +123,12 @@
3457 <option name="initiate_edge" type="edge">
3458 <_short>Initiate Window Picker</_short>
3459 <_long>Layout and start transforming windows</_long>
3460@@ -510,7 +615,7 @@
3461 </option>
3462 <option name="initiate_button" type="button">
3463 <_short>Initiate Window Picker</_short>
3464-@@ -178,7 +175,7 @@
3465+@@ -179,7 +176,7 @@
3466 <option name="show_desktop" type="bool">
3467 <_short>Click Desktop to Show Desktop</_short>
3468 <_long>Enter Show Desktop mode when Desktop is clicked during Scale</_long>
3469@@ -519,11 +624,11 @@
3470 </option>
3471 </group>
3472 </options>
3473-
3474-=== modified file 'plugins/staticswitcher/staticswitcher.xml.in'
3475---- old/plugins/staticswitcher/staticswitcher.xml.in 2012-05-16 17:40:16 +0000
3476-+++ new/plugins/staticswitcher/staticswitcher.xml.in 2012-07-27 12:41:52 +0000
3477-@@ -10,7 +10,6 @@
3478+Index: new/plugins/staticswitcher/staticswitcher.xml.in
3479+===================================================================
3480+--- old/plugins/staticswitcher/staticswitcher.xml.in 2012-11-23 18:54:15.673949000 +0800
3481++++ new/plugins/staticswitcher/staticswitcher.xml.in 2012-11-23 18:54:59.307064517 +0800
3482+@@ -11,7 +11,6 @@
3483 <relation type="after">
3484 <plugin>composite</plugin>
3485 <plugin>opengl</plugin>
3486@@ -531,7 +636,7 @@
3487 <plugin>compiztoolbox</plugin>
3488 <plugin>decor</plugin>
3489 </relation>
3490-@@ -139,12 +138,12 @@
3491+@@ -140,12 +139,12 @@
3492 <option name="auto_change_vp" type="bool">
3493 <_short>Auto Change Viewport</_short>
3494 <_long>Change to the viewport of the selected window while switching</_long>
3495@@ -546,7 +651,7 @@
3496 <min>0.0</min>
3497 <max>2.0</max>
3498 <precision>0.05</precision>
3499-@@ -152,7 +151,7 @@
3500+@@ -153,7 +152,7 @@
3501 <option name="mouse_select" type="bool">
3502 <_short>Allow Mouse Selection</_short>
3503 <_long>Allow selection of windows from the switcher window with the mouse</_long>
3504@@ -555,7 +660,7 @@
3505 </option>
3506 </group>
3507 <group>
3508-@@ -160,14 +159,14 @@
3509+@@ -161,14 +160,14 @@
3510 <option name="saturation" type="int">
3511 <_short>Saturation</_short>
3512 <_long>Amount of saturation in percent</_long>
3513@@ -572,7 +677,7 @@
3514 <min>0</min>
3515 <max>100</max>
3516 </option>
3517-@@ -191,7 +190,7 @@
3518+@@ -192,7 +191,7 @@
3519 <option name="mipmap" type="bool">
3520 <_short>Mipmap</_short>
3521 <_long>Generate mipmaps when possible for higher quality scaling</_long>
3522@@ -581,7 +686,7 @@
3523 </option>
3524 <option name="row_align" type="int">
3525 <_short>Row Alignment</_short>
3526-@@ -220,7 +219,7 @@
3527+@@ -221,7 +220,7 @@
3528 <option name="bring_to_front" type="bool">
3529 <_short>Bring To Front</_short>
3530 <_long>Bring selected window to front</_long>
3531@@ -590,7 +695,7 @@
3532 </option>
3533 <_short>Selected Window Highlight</_short>
3534 <option name="highlight_mode" type="int">
3535-@@ -228,7 +227,7 @@
3536+@@ -229,7 +228,7 @@
3537 <_long>Mode for highlighting the currently selected window</_long>
3538 <min>0</min>
3539 <max>2</max>
3540@@ -599,10 +704,10 @@
3541 <desc>
3542 <value>0</value>
3543 <_name>None</_name>
3544-
3545-=== modified file 'plugins/vpswitch/vpswitch.xml.in'
3546---- old/plugins/vpswitch/vpswitch.xml.in 2012-05-16 17:40:51 +0000
3547-+++ new/plugins/vpswitch/vpswitch.xml.in 2012-07-27 12:41:52 +0000
3548+Index: new/plugins/vpswitch/vpswitch.xml.in
3549+===================================================================
3550+--- old/plugins/vpswitch/vpswitch.xml.in 2012-11-23 18:54:15.673949000 +0800
3551++++ new/plugins/vpswitch/vpswitch.xml.in 2012-11-23 18:54:59.307064517 +0800
3552 @@ -95,13 +95,11 @@
3553 <option name="next_button" type="button">
3554 <_short>Move Next</_short>
3555@@ -617,10 +722,10 @@
3556 <internal/>
3557 </option>
3558 <option name="initiate_button" type="button">
3559-
3560-=== modified file 'plugins/wall/wall.xml.in'
3561---- old/plugins/wall/wall.xml.in 2012-05-16 17:41:07 +0000
3562-+++ new/plugins/wall/wall.xml.in 2012-07-27 12:41:52 +0000
3563+Index: new/plugins/wall/wall.xml.in
3564+===================================================================
3565+--- old/plugins/wall/wall.xml.in 2012-11-23 18:54:15.673949000 +0800
3566++++ new/plugins/wall/wall.xml.in 2012-11-23 18:54:59.311064517 +0800
3567 @@ -31,12 +31,12 @@
3568 <option name="miniscreen" type="bool">
3569 <_short>Show Live Viewport Previews</_short>
3570@@ -768,4 +873,3 @@
3571 </option>
3572 <option name="edgeflip_dnd" type="bool">
3573 <_short>Edge Flip DnD</_short>
3574-

Subscribers

People subscribed via source and target branches