Wireshark-dev: Re: [Wireshark-dev] VoIP Calls and -Graph dialog behaviour
From: "RUOFF LARS" <[email protected]>
Date: Wed, 14 Oct 2009 15:47:52 +0200
It works for me on trunk also.
I have attached a patch for dlg-utils.c which removes the transient
thing for WIN32 only.
Anders, maybe you could back-check to see if you have the pending child
dialogs issue again with this?

Lars

 

> -----Original Message-----
> From: [email protected] 
> [mailto:[email protected]] On Behalf Of RUOFF LARS
> Sent: mercredi 14 octobre 2009 13:55
> To: Developer support list for Wireshark
> Subject: Re: [Wireshark-dev] VoIP Calls and -Graph dialog behaviour
> 
> 
> Hi Anders,
> Hmm, I can't reproduce this.
> I compiled 1.3.0 with the line from gtk/dlg_utils.c commented 
> out and it works just fine.
> When I close Wireshark, all child windows close nicely.
> Will try the same on trunk as soon as I have recompiled after 
> distclean
> :-)
> 
> Lars
> 
> 
> 
> > -----Original Message-----
> > From: [email protected]
> > [mailto:[email protected]] On Behalf Of Anders 
> > Broman
> > Sent: mercredi 14 octobre 2009 12:04
> > To: Developer support list for Wireshark
> > Subject: Re: [Wireshark-dev] VoIP Calls and -Graph dialog behaviour
> > 
> > 
> >  Hi,
> > Written in a hurry :-)
> > >Is there any particular reason we need to have the windows
> > transient to
> > top level?
> > 
> > If you do not use transent and leave the child window open 
> then close 
> > wirehark The child window will remain and show a portion of 
> the main 
> > window on Windows.
> > Anders
> > -----Original Message-----
> > From: [email protected]
> > [mailto:[email protected]] On Behalf Of RUOFF LARS
> > Sent: den 14 oktober 2009 11:34
> > To: Developer support list for Wireshark
> > Subject: Re: [Wireshark-dev] VoIP Calls and -Graph dialog behaviour
> > 
> > Coming back on this subject...
> > 
> > @Jeff:
> > https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2421
> > => This ss definitevly the same issue.
> > 
> > All child dialogs are affected because all use the same function to
> > open:
> > The problem is the line in gtk/dlg_utils.c:
> >  In function dlg_window_new(const gchar *title):
> >     gtk_window_set_transient_for(GTK_WINDOW(win),
> > GTK_WINDOW(top_level));
> > 
> > Here all dialogs are made transient to the main window.
> > The info on this function
> > (http://developer.gimp.org/api/2.0/gtk/GtkWindow.html#gtk-wind
> > ow-set-tra
> > nsient-for)
> > suggests that it is good practice to to so for all child 
> dialogs, but 
> > the behaviour on Windows is unbearable!
> > When *not* called, the behaviour on Windows is: All dialogs 
> will have 
> > their own taskbar tab (grouped/ungrouped depends on your Windows 
> > settings of course), and simple click on any open window 
> space brings 
> > the window to front. I'm unhappy with the fact that taskbar 
> space is 
> > cluttered up by child windows, but I still prefer this behaviour to 
> > the current one, which is a pain for me.
> > 
> > Is there any particular reason we need to have the windows 
> transient 
> > to top level?
> > What's the behaviour on Linux/Mac/...?
> > If no consensus can be achieved, may I suggest for a preference 
> > setting?
> > 
> > Lars
> > 
> > 
> > 
> > > -----Original Message-----
> > > From: [email protected]
> > > [mailto:[email protected]] On Behalf Of
> > Jeff Morriss
> > > Sent: mercredi 16 septembre 2009 19:30
> > > To: Developer support list for Wireshark
> > > Subject: Re: [Wireshark-dev] VoIP Calls and -Graph dialog 
> behaviour
> > > 
> > > RUOFF LARS wrote:
> > > > Hi,
> > > > 
> > > > i don't know what has been changed exactly, but the VoIP
> > Calls and
> > > > -Graph dialog behaviour seems totally screwed up on 1.2.2
> > > on Windows.
> > > > 
> > > > Initial condition: Wireshark main window maximized.
> > > > Once the Voip Calls and -Graph dialogs are opened:
> > > > Click on a line in the Graph dialog.
> > > > Now try to navigate to the packet details in main window.
> > > > Clicking on the main window doesn't bring it to front.
> > > > So minimize the Graph window => minimizes ALL windows!
> > > > So it needs an additional step to maximize the main 
> window again.
> > > > Navigating back to the Graph dialog is a matter of luck:
> > > > Either you clicked on the right one of the two dialog
> > > handles that are
> > > > shown in minimized state ... or not. If you clicked on the
> > > wrong on,
> > > > you're back to Calls dialog and need first to click on the
> > > dialog to
> > > > focus it and then on the Graph dialog to bring it to front.
> > > > A nightmare!
> > > 
> > > 
> > > This bug sounds similar:
> > > 
> > > https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2421
> > > ______________________________________________________________
> > > _____________
> > > Sent via:    Wireshark-dev mailing list 
> > <[email protected]>
> > > Archives:    http://www.wireshark.org/lists/wireshark-dev
> > > Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
> > >              
> > > mailto:[email protected]?subject=unsubscribe
> > > 
> > ______________________________________________________________
> > __________
> > ___
> > Sent via:    Wireshark-dev mailing list 
> <[email protected]>
> > Archives:    http://www.wireshark.org/lists/wireshark-dev
> > Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
> >  
> > mailto:[email protected]?subject=unsubscribe
> > ______________________________________________________________
> > _____________
> > Sent via:    Wireshark-dev mailing list 
> <[email protected]>
> > Archives:    http://www.wireshark.org/lists/wireshark-dev
> > Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
> >              
> > mailto:[email protected]?subject=unsubscribe
> > 
> ______________________________________________________________
> _____________
> Sent via:    Wireshark-dev mailing list <[email protected]>
> Archives:    http://www.wireshark.org/lists/wireshark-dev
> Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
>              
> mailto:[email protected]?subject=unsubscribe
> 
Index: dlg_utils.c
===================================================================
--- dlg_utils.c	(revision 30556)
+++ dlg_utils.c	(working copy)
@@ -419,9 +419,16 @@
    * to capture, and might also simplify the job of having the GUI main
    * loop wait both for user input and packet arrival.
    */
+  /*
+   * On Windows, making the dialogs transient to top_level behaves strangely.
+   * It is not possible any more to bring the top level window to front easily.
+   * So we don't do this on Windows.
+   */
+#ifndef _WIN32
   if (top_level) {
     gtk_window_set_transient_for(GTK_WINDOW(win), GTK_WINDOW(top_level));
   }
+#endif /*_WIN32*/
 
   return win;
 }