0.9.2 «Put» plugin sends window in wrong direction
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Compiz |
Triaged
|
Low
|
Sam Spilsbury | ||
compiz-fusion-plugins-main (Ubuntu) |
Triaged
|
Low
|
Unassigned |
Bug Description
Tested using 9 horizontal viewports on Maverick and Natty.
Currently using compiz-
When on viewport 1, using the Put plugin's 'send to viewport' command to send to viewport 8 will send the window in the wrong direction where it will get stuck past the edge of the screen - it never reaches viewport 8. Other combinations have the similar effects.
The issue seems to be in put.cpp function getDistance, case PutViewport. The calculation assumes the viewports wrap and it can send windows around 'the short way', but this doesn't work. I have commented out lines as follows:
/* take the shortest horizontal path to the destination viewport */
hDirection = (vpX - s->vp ().x ());
// if (hDirection > (int) s->vpSize ().width () / 2)
// hDirection = (hDirection - s->vpSize ().width ());
// else if (hDirection < - ((int) s->vpSize ().width ()) / 2)
// hDirection = (hDirection + s->vpSize ().width ());
and this seems to fix the issue.
Related branches
- Andrea Azzarone: Needs Fixing
- PS Jenkins bot (community): Needs Fixing (continuous-integration)
- Marco Trevisan (Treviño): Pending requested
- Unity Team: Pending requested
-
Diff: 23 lines (+0/-10)1 file modifiedplugins/put/src/put.cpp (+0/-10)
Changed in compiz-put-plugin: | |
status: | New → In Progress |
importance: | Undecided → Low |
assignee: | nobody → Sam Spilsbury (smspillaz) |
milestone: | none → 0.9.5.2 |
Changed in compiz-fusion-plugins-main (Ubuntu): | |
status: | New → Triaged |
importance: | Undecided → Low |
Changed in compiz: | |
assignee: | nobody → Sam Spilsbury (smspillaz) |
importance: | Undecided → Low |
status: | New → In Progress |
Changed in compiz: | |
status: | In Progress → Fix Committed |
no longer affects: | compiz-put-plugin |
Changed in compiz: | |
status: | Fix Committed → Triaged |