From 12fad6f05f7b2183317dd35db95d479c8e44f5f5 Mon Sep 17 00:00:00 2001 From: Abderrahim Kitouni Date: Tue, 30 Nov 2010 16:12:22 +0100 Subject: [PATCH] Fix ripple animation for RTL locales The animation was invisible because it was going out of screen, also add a mirrored version of the image to the theme. https://bugzilla.gnome.org/show_bug.cgi?id=584662 --- data/Makefile.am | 3 ++- .../{corner-ripple.png => corner-ripple-ltr.png} | Bin data/theme/corner-ripple-rtl.png | Bin 0 -> 2386 bytes data/theme/gnome-shell.css | 6 +++++- js/ui/panel.js | 2 ++ 5 files changed, 9 insertions(+), 2 deletions(-) rename data/theme/{corner-ripple.png => corner-ripple-ltr.png} (100%) create mode 100644 data/theme/corner-ripple-rtl.png diff --git a/data/Makefile.am b/data/Makefile.am index b0477194c..819b15c34 100644 --- a/data/Makefile.am +++ b/data/Makefile.am @@ -24,7 +24,8 @@ dist_theme_DATA = \ theme/calendar-today.svg \ theme/close-window.svg \ theme/close.svg \ - theme/corner-ripple.png \ + theme/corner-ripple-ltr.png \ + theme/corner-ripple-rtl.png \ theme/dash-placeholder.svg \ theme/filter-selected-ltr.svg \ theme/filter-selected-rtl.svg \ diff --git a/data/theme/corner-ripple.png b/data/theme/corner-ripple-ltr.png similarity index 100% rename from data/theme/corner-ripple.png rename to data/theme/corner-ripple-ltr.png diff --git a/data/theme/corner-ripple-rtl.png b/data/theme/corner-ripple-rtl.png new file mode 100644 index 0000000000000000000000000000000000000000..26cf965f63064f996d5a2e6199bfc154f56fe24c GIT binary patch literal 2386 zcmV-Y39a^tP)gm7pL_57tSZ~(veUs9f{-AnQ^UjTq6&sMRgh5`>;X#0-g#kTA$3$d($A(%m?*iCw9(%k}x*yJxQ+ymHhL zY1#&VR4wW0Ug_yxopsJWd#}CD)t|iek84fSy~rZJoaFBUzY(Gs-M0Oc5O<_DSU`-8S2LMJL@OM>>}4kb(bRFxV3s9!?Rr09$9REgOK6N3 zL9{4O2cez8t?X(yuc`fr*v5Ge*aK|T0mIB}U8T&E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>sUE zfe|o}qE)D=SsN(=J3K0!jT)P47FT<06F{c(;i9Mz-U-9_JY zhehmVt@}s^wilAT>~Pgc>THigOav1z>)1$WC}|+6W0@`6<6i)QGeDupA~_Vxqtl1~ z3+suvH+S#e<--sEhOfMI-g~23CyR~wT>CRw2RIK(DTgT^31$(R8&Xn)G&GtBPeWQs zdj(iAoPtOluh;>GRi=9aFFN4oQOKPsbkx9hVT zXZB~aXG7?sqz%XoNf$D?z_B&Pa+VXAA4{g0?YZr_q@&~O9A}TB7p_2k`1y{pZ9je; zdK6r_az)p#U*}tY`*uwFvu*C}4F}z1(v(=K)n_QI%X-1~i$WKS&jM3m2oxbBs_m3i zm&c^k5>(gJYS|Fd^v`sKaw;Bpzy zhF#TcT(wv!8my#qHR;!i%StLIjbgBLl-z|F+8)~;Lktj&?T82+lWrc8xBYB8%B!1O zdgF(0>E7A1#e>Ubcr@?&rt9irHtfo9sHh{U43g-Si_W3WRYOT*XPqcCvekts2@R%| z)TXnI_+v}!!ao}uu- zs10abTwK*cwggQO;pfrw|2(c-xuUcG@K3z)!?*M=gJJy6c%+TBH9fdLRMexG4_{Cp z^D>EAW(zl^&Kfa^@)tS87IgyqWp^Z9cCy!qyv8jY^;pX-0Gm(H*2 z!wv;BSj46KJO-NuR^1^@s607*qoM6N<$ Ef{zodu>b%7 literal 0 HcmV?d00001 diff --git a/data/theme/gnome-shell.css b/data/theme/gnome-shell.css index e26c16249..caaa5c425 100644 --- a/data/theme/gnome-shell.css +++ b/data/theme/gnome-shell.css @@ -1280,7 +1280,11 @@ StTooltip StLabel { .ripple-box { width: 52px; height: 52px; - background-image: url("corner-ripple.png"); + background-image: url("corner-ripple-ltr.png"); +} + +.ripple-box:rtl { + background-image: url("corner-ripple-rtl.png"); } .switcher-arrow { diff --git a/js/ui/panel.js b/js/ui/panel.js index 5ef212a93..8cbceb051 100644 --- a/js/ui/panel.js +++ b/js/ui/panel.js @@ -706,6 +706,8 @@ HotCorner.prototype = { x: x, y: y }); ripple._opacity = startOpacity; + if (ripple.get_direction() == St.TextDirection.RTL) + ripple.set_anchor_point_from_gravity(Clutter.Gravity.NORTH_EAST); Tweener.addTween(ripple, { _opacity: finalOpacity, scale_x: finalScale, scale_y: finalScale,