[gnome-shell/overlay-design02] Make sure we show the information button when a new item appears under the pointer



commit 84865f416dd93e314221a2937539550aba7fb228
Author: Marina Zhurakhinskaya <marinaz redhat com>
Date:   Thu Jun 25 15:31:09 2009 -0400

    Make sure we show the information button when a new item appears under the pointer
    
    Update the code for checking a display item under the pointer to expect
    the item itself rather than its child to be returned by stage_get_actor_at_pos().
    
    This code is now used to display an information button when an item is
    drawn under the pointer, so update the comment accordingly.

 js/ui/genericDisplay.js |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/js/ui/genericDisplay.js b/js/ui/genericDisplay.js
index a5e089a..af4eb0d 100644
--- a/js/ui/genericDisplay.js
+++ b/js/ui/genericDisplay.js
@@ -530,13 +530,13 @@ GenericDisplay.prototype = {
         Mainloop.timeout_add(5, 
                              Lang.bind(this,
                                        function() {
-                                           // Check if the pointer is over one of the items and display the preview pop-up if it is.
+                                           // Check if the pointer is over one of the items and display the information button if it is.
                                            let [child, x, y, mask] = Gdk.Screen.get_default().get_root_window().get_pointer();
                                            let global = Shell.Global.get();
                                            let actor = global.stage.get_actor_at_pos(Clutter.PickMode.REACTIVE,
                                                                                      x, y);
                                            if (actor != null) {
-                                               let item = this._findDisplayedByActor(actor.get_parent());
+                                               let item = this._findDisplayedByActor(actor);
                                                if (item != null) {
                                                    item.onDrawnUnderPointer();
                                                }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]