From e8df89377f7cd2bcbce7bd7110cd83cb75c4c0b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marco=20Trevisan=20=28Trevi=C3=B1o=29?= Date: Thu, 27 Feb 2014 08:11:16 +0100 Subject: DecorationsWindowButton: use scaled Window Button textures, enjoy the visual quality! Well, better with SVGs ;) (bzr r3680.1.81) --- plugins/unityshell/src/unityshell.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'plugins') diff --git a/plugins/unityshell/src/unityshell.cpp b/plugins/unityshell/src/unityshell.cpp index c4f8c57db..6eee23136 100644 --- a/plugins/unityshell/src/unityshell.cpp +++ b/plugins/unityshell/src/unityshell.cpp @@ -3926,7 +3926,7 @@ void UnityWindow::paintFakeDecoration(nux::Geometry const& geo, GLWindowPaintAtt if (window->actions() & CompWindowActionCloseMask) { using namespace decoration; - close_texture = DataPool::Get()->ButtonTexture(WindowButtonType::CLOSE, close_icon_state_); + close_texture = DataPool::Get()->ButtonTexture(dpi_scale, WindowButtonType::CLOSE, close_icon_state_); } if (redraw_decoration) @@ -3954,13 +3954,13 @@ void UnityWindow::paintFakeDecoration(nux::Geometry const& geo, GLWindowPaintAtt if (close_texture) { - int w = close_texture->width() * dpi_scale; - int h = close_texture->height() * dpi_scale; + int w = close_texture->width(); + int h = close_texture->height(); int x = geo.x + padding.left * dpi_scale; int y = geo.y + padding.top * dpi_scale + (height - w) / 2.0f; close_button_geo_.Set(x, y, w, h); - DrawTexture(*close_texture, attrib, transform, mask, x, y, dpi_scale); + DrawTexture(*close_texture, attrib, transform, mask, x, y); } else { -- cgit v1.2.3