Merge lp:~muktupavels/compiz/fix-icon-size-in-switcher into lp:compiz/0.9.12

Proposed by Alberts Muktupāvels
Status: Merged
Approved by: Stephen M. Webb
Approved revision: 3959
Merged at revision: 3959
Proposed branch: lp:~muktupavels/compiz/fix-icon-size-in-switcher
Merge into: lp:compiz/0.9.12
Diff against target: 16 lines (+4/-2)
1 file modified
plugins/switcher/src/switcher.cpp (+4/-2)
To merge this branch: bzr merge lp:~muktupavels/compiz/fix-icon-size-in-switcher
Reviewer Review Type Date Requested Status
Stephen M. Webb Approve
Dmitry Shachnev Approve
Review via email: mp+265900@code.launchpad.net

Commit message

Change icon size back to 48px in application switcher plugin.

Description of the change

Change icon size back to 48px in application switcher plugin.

To post a comment you must log in.
Revision history for this message
Dmitry Shachnev (mitya57) wrote :

I would just store the constant in float to avoid casting, but this is fine as well (compiler should optimize it anyway).

review: Approve
Revision history for this message
Stephen M. Webb (bregma) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'plugins/switcher/src/switcher.cpp'
2--- plugins/switcher/src/switcher.cpp 2014-11-21 13:52:50 +0000
3+++ plugins/switcher/src/switcher.cpp 2015-07-25 20:04:23 +0000
4@@ -892,8 +892,10 @@
5 int y,
6 GLTexture *icon)
7 {
8- sAttrib.xScale = (float) ICON_SIZE / icon->width ();
9- sAttrib.yScale = (float) ICON_SIZE / icon->height ();
10+ const unsigned short SWITCHER_ICON_SIZE = 48;
11+
12+ sAttrib.xScale = (float) SWITCHER_ICON_SIZE / icon->width ();
13+ sAttrib.yScale = (float) SWITCHER_ICON_SIZE / icon->height ();
14 if (sAttrib.xScale < sAttrib.yScale)
15 sAttrib.yScale = sAttrib.xScale;
16 else

Subscribers

People subscribed via source and target branches