[Bug 1078694] Re: Modal dialog broken on Unity

2013-01-15 Thread Vadim Zeitlin
This bug is absolutely trivial to reproduce, here is a minimal GTK+
program which shows it:

#include gtk/gtk.h

static void activate_test(GtkMenuItem*, GtkWindow* window)
{
GtkWidget* dialog = gtk_message_dialog_new(window, GTK_DIALOG_MODAL,
GTK_MESSAGE_INFO, GTK_BUTTONS_OK, a message, NULL);
gtk_dialog_run(GTK_DIALOG(dialog));
gtk_widget_destroy(dialog);
}

int main(int argc, char** argv)
{
gtk_init(argc, argv);
GtkWidget* window = gtk_window_new(GTK_WINDOW_TOPLEVEL);

GtkWidget* menu = gtk_menu_new();
GtkWidget* mi = gtk_menu_item_new_with_mnemonic(_Test);
g_signal_connect(mi, activate, G_CALLBACK(activate_test), window);
gtk_menu_shell_append(GTK_MENU_SHELL(menu), mi);

mi = gtk_menu_item_new_with_mnemonic(E_xit);
g_signal_connect(mi, activate, G_CALLBACK (gtk_main_quit), NULL);
gtk_menu_shell_append(GTK_MENU_SHELL(menu), mi);
mi = gtk_menu_item_new_with_mnemonic(_File);
gtk_menu_item_set_submenu(GTK_MENU_ITEM(mi), menu);

GtkWidget* menubar = gtk_menu_bar_new();
gtk_menu_shell_append(GTK_MENU_SHELL(menubar), mi);
gtk_widget_show_all(menubar);
gtk_container_add(GTK_CONTAINER(window), menubar);

g_signal_connect(window, destroy, G_CALLBACK(gtk_main_quit), NULL);
gtk_widget_show(window);
gtk_main();
return 0;
}

The menu stays enabled while the message box is shown and so multiple
message boxes can be opened.

Ubuntu behaviour here totally breaks the application logic and is
incompatible with GTK+ on all the other systems. It's amazing that this
is apparently not considered to be a problem at all.

** Changed in: compiz (Ubuntu)
   Status: Expired = Confirmed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/appmenu-gtk/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1078694] Re: Modal dialog broken on Unity

2013-01-15 Thread Vadim Zeitlin
This is related to the global menu and not compiz.

** Package changed: compiz (Ubuntu) = appmenu-gtk (Ubuntu)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/appmenu-gtk/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1078694] Re: Modal dialog broken on Unity

2013-01-15 Thread Lars Uebernickel
*** This bug is a duplicate of bug 674605 ***
https://bugs.launchpad.net/bugs/674605

Thanks for reporting this bug. I'm marking it as a duplicate of bug
#674605

** This bug has been marked a duplicate of bug 674605
   Transient window wrongly shows menus for its parent

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/appmenu-gtk/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1078694] Re: Modal dialog broken on Unity

2013-01-14 Thread Launchpad Bug Tracker
[Expired for compiz (Ubuntu) because there has been no activity for 60
days.]

** Changed in: compiz (Ubuntu)
   Status: Incomplete = Expired

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1078694] Re: Modal dialog broken on Unity

2012-11-15 Thread raananb
To reproduce this bug, use the sample provided with wxWidgets (2.9.4).
Build wxWidgets, then 'make' the sample 'dialogs' under the resuting
build (GCCBuildReleaseGTKUnicode  GCCBuildDebugGTKUnicode in my case).

When the resulting 'dialogs' application is launched, select any entry
in the Dialogs menu. You will notice that you can continue to select the
same or other entries at will, while normally the menu should be
disabled after the first dialog is displayed.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1078694] Re: Modal dialog broken on Unity

2012-11-15 Thread Vadim Zeitlin
The relevant code inside wxWidgets is in
http://trac.wxwidgets.org/browser/wxWidgets/trunk/src/gtk/dialog.cpp#L102
and uses gtk_window_set_transient_for() and gtk_window_set_modal() which
doesn't seem to be enough when using Ubuntu global menu bar. Presumably
gtk_dialog_run() works (otherwise more people would have complained
about this already) but it's not flexible enough to be used in
wxWidgets.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


Re: [Bug 1078694] Re: Modal dialog broken on Unity

2012-11-15 Thread raananb
Le 15/11/2012 13:17, Vadim Zeitlin a écrit :
 The relevant code inside wxWidgets is in
 http://trac.wxwidgets.org/browser/wxWidgets/trunk/src/gtk/dialog.cpp#L102
 and uses gtk_window_set_transient_for() and gtk_window_set_modal() which
 doesn't seem to be enough when using Ubuntu global menu bar. Presumably
 gtk_dialog_run() works (otherwise more people would have complained
 about this already) but it's not flexible enough to be used in
 wxWidgets.

I looked at dialog.cpp: I added the patch 'if (wxOpenModalDialogsCount) 
return(0);' at the beginning of ShowModal() and this effectively stops 
duplicate dialogs being issued from the menu. It does not stop issuing 
wxMessageBox when a dialog is displayed though.

I dont know what to look for otherwise in this file.

raanan

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1078694] Re: Modal dialog broken on Unity

2012-11-14 Thread raananb
** Package changed: ubuntu = unity (Ubuntu)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/unity/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1078694] Re: Modal dialog broken on Unity

2012-11-14 Thread Daniel van Vugt
Sorry, but we can't help with this until we can reproduce it. Please
provide a test program to help us reproduce the problem, or detailed
instructions for how to.

** Package changed: unity (Ubuntu) = compiz (Ubuntu)

** Changed in: compiz (Ubuntu)
   Status: New = Incomplete

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1078694

Title:
  Modal dialog broken on Unity

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/1078694/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs