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
=== modified file 'plugins/switcher/src/switcher.cpp'
--- plugins/switcher/src/switcher.cpp 2014-11-21 13:52:50 +0000
+++ plugins/switcher/src/switcher.cpp 2015-07-25 20:04:23 +0000
@@ -892,8 +892,10 @@
892 int y,892 int y,
893 GLTexture *icon)893 GLTexture *icon)
894{894{
895 sAttrib.xScale = (float) ICON_SIZE / icon->width ();895 const unsigned short SWITCHER_ICON_SIZE = 48;
896 sAttrib.yScale = (float) ICON_SIZE / icon->height ();896
897 sAttrib.xScale = (float) SWITCHER_ICON_SIZE / icon->width ();
898 sAttrib.yScale = (float) SWITCHER_ICON_SIZE / icon->height ();
897 if (sAttrib.xScale < sAttrib.yScale)899 if (sAttrib.xScale < sAttrib.yScale)
898 sAttrib.yScale = sAttrib.xScale;900 sAttrib.yScale = sAttrib.xScale;
899 else901 else

Subscribers

People subscribed via source and target branches