After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 147623 - Main Menu moves even after move operation has been ended
Main Menu moves even after move operation has been ended
Status: RESOLVED FIXED
Product: gnome-panel
Classification: Other
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Panel Maintainers
Panel Maintainers
: 145288 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2004-07-15 05:18 UTC by Arvind S N
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch should fix the bug (2.82 KB, patch)
2004-07-15 05:19 UTC, Arvind S N
needs-work Details | Review

Description Arvind S N 2004-07-15 05:18:25 UTC
Move the Main Menu  (right click,  move)
Click to stop the move
Move the mouse pointer over the panel, the Main Menu button moves.

Attaching the patch in a minute
Comment 1 Arvind S N 2004-07-15 05:19:01 UTC
Created attachment 29542 [details] [review]
Patch should fix the bug
Comment 2 Mark McLoughlin 2004-07-15 07:05:15 UTC
This doesn't look right to me - when the PanelWidget grabs the pointer, it
should make sure to handle all pointer/button events and make sure the actual
widgets don't get the event - i.e. I'd expect the fix to be in panel-widget.c.

Its all a bit of a mess (the existing code) and I can't figure out what's going
on at a glance. Not sure what broke here. What I've noticed too is that when you
finish moving a launcher like this it depresses when you move the pointer back
over it - probably a related issue.
Comment 3 Arvind S N 2004-07-15 10:48:23 UTC
Mark: The button-press-event callback in panel-widget.c was never going through.
So, doing g_signal_connect () instead of g_signal_connect_after() fixes it.

I am not sure what we might break with this but we do manage to fix are as below.

a) The current problem in this bug report
b) The launcher button getting depressed after the move operation (in the
toolkit sense ie ;-))
c) The problem report in bug #145288

--- gnome-panel/gnome-panel/panel-widget.c      Sat Feb 14 16:06:56 2004
+++ gnome-panel-new/gnome-panel/panel-widget.c  Thu Jul 15 16:10:39 2004
@@ -2361,7 +2361,7 @@ bind_top_applet_events (GtkWidget *widge
                          NULL);

        /* connect-after so that we stop the propogation of the event */
-       g_signal_connect_after (widget, "button-press-event",
+     g_signal_connect (widget, "button-press-event",
                                G_CALLBACK (panel_widget_applet_button_press_event),
                                NULL);

What do you think ?
Comment 4 Arvind S N 2004-07-15 11:17:48 UTC
okay, the g_signal_connect_after went in as a part of fix for bug #123819.  Just
tested that again, even with the change above that bug does not occur.
Comment 5 Arvind S N 2004-07-15 11:36:17 UTC
hmm, sorry for spamming, this change fixes bug #143908,  not sure what other
stuff it fixes ;-)
Comment 6 Arvind S N 2004-07-26 10:39:51 UTC
*** Bug 145288 has been marked as a duplicate of this bug. ***
Comment 7 Mark McLoughlin 2004-07-30 08:11:54 UTC
Okay, if your confident this is right, go ahead with it on HEAD and close out
all the bugs it fixes etc.
Comment 8 Arvind S N 2004-07-30 14:19:41 UTC
Checked in to HEAD. Thanks 
 
2004-07-30  Arvind Samptur  <arvind.samptur@wipro.com> 
 
        * panel-widget.c: (bind_top_applet_events): For the 
        button-press-event do a g_signal_connect () 
        instead of a g_signal_connect_after (). 
        This event was not going through PanelWidget 
        because of which the actual widgets were getting 
        the events. Thus exhibiting strange behaviours. 
        Fixes #147623, #143908,#145288 etc