Merge lp:~sjakthol/compiz/fix-1066187 into lp:compiz/0.9.9
Status: | Merged |
---|---|
Approved by: | Daniel van Vugt |
Approved revision: | 3416 |
Merged at revision: | 3419 |
Proposed branch: | lp:~sjakthol/compiz/fix-1066187 |
Merge into: | lp:compiz/0.9.9 |
Diff against target: |
84 lines (+30/-7) 2 files modified
plugins/ezoom/src/ezoom.cpp (+22/-6) plugins/ezoom/src/ezoom.h (+8/-1) |
To merge this branch: | bzr merge lp:~sjakthol/compiz/fix-1066187 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Daniel van Vugt | Approve | ||
MC Return | Approve | ||
PS Jenkins bot | continuous-integration | Pending | |
Review via email: mp+129556@code.launchpad.net |
Commit message
Problem:
Specific Zoom Factor settings were ignored by the Enhanced Zoom Desktop
(LP: #1066187) because the values were only read once during initial load of
the plugin probably before the user defined configuration was read (and thus
it always used the default values).
Fix:
Instead of sending the (original) value of the initiated zoom level, send a
zoom level identifier. The identifier is used to determine which zoom level
the user wants and a fresh setting for that zoom level is used.
.
Description of the change
Tested the changes locally and they seem to compile and work fine. Please let me know if there's any problems with the coding style or implementation and I'll try to fix them.
Test case:
1. Open CCSM
2. Choose 'Enhanced Zoom Desktop' plugin (and make sure it's in use)
3. Go to 'Specific Zoom' tab
4. Add key bindings for Specific Zoom Level 1, 2 and 3
5. Set same values to Specific Zoom factor 2 and 3 (e.g. 0.7)
6. Press the key binding for Specific Zoom Level 2
7. Press the key binding for Specific Zoom Level 3
8. Change the zoom factors and test what happens by pressing the corresponding key bindings
You might want to keep the factor 1 at 1.00 so that you can reset the zoom once done.
Current behavior:
At (6) the screen gets zoomed in (like it should) but at (7) screen is zoomed even more (incorrect behavior, the values were the same). At (8) you'll see how the zoom for a certain level (factor 1 = 1.00, factor 2 = 0.5, factor 3 = 0.2) is always the same no matter what your input is.
Behavior with the fix:
At (6) the screen gets zoomed in (like it should) and at (7) nothing happens (correct behavior as the zoom factors were the same). At (8) the zoom clearly depends on the values you specified.
Possible problems:
Not sure if this is possible but if something outside ezoom plugin is directly calling EZoomScreen:
sampo555, great :)
Thanks a lot for your fix. I have yet to test it until I can approve it, but looks quite ok to me.
Regarding coding style: Compiz uses C++11 coding style, mixing spaces with tabs.
The first indent are 4 spaces, then a tab 8 spaces wide, then a mix of a tab and 4 spaces.
If you intend to help more with Compiz coding and want to use QTCreator, I am sure we can share the QTC settings file with you to make it easier to follow this style.
Otherwise I can take over your branch and fix the indentation there, before we merge this.
Thanks a lot for your contribution - you are very welcome to eliminate more of those nasty small bugs ;).
(I'll try to test and approve your fix ASAP.)