Re: [pygtk] Segfault with popup menus

2001-11-25 Thread Colin Walters
Colin Walters <[EMAIL PROTECTED]> writes: > Paul Brannan <[EMAIL PROTECTED]> writes: > >> With this program: > > [...] > >> I have no idea what's causing self=0x0, but I suspect that's why the >> program is segfaulting. > > Works fine for me using python-gnome 1.4.1. Oops, spoke too soon, it doe

Re: [pygtk] Segfault with popup menus

2001-11-22 Thread Colin Walters
Paul Brannan <[EMAIL PROTECTED]> writes: > With this program: [...] > I have no idea what's causing self=0x0, but I suspect that's why the > program is segfaulting. Works fine for me using python-gnome 1.4.1. ___ pygtk mailing list [EMAIL PROTECTED

[pygtk] Segfault with popup menus

2001-11-19 Thread Paul Brannan
With this program: from gtk import * def button_press(widget, event): if event.button == 3: menu = GtkMenu() menu.append(GtkMenuItem('foo')) menu.append(GtkMenuItem('bar')) menu.popup(widget, None, None, event.button, event.time) window = GtkWindow(WINDOW_TOPLE

Re: [pygtk] Segfault with popup menus

2001-11-19 Thread John Finlay
Paul, Pass in None instead of widget as the first arg to menu.popup. Also need to have the menu displayed. Changes below. John from gtk import * def button_press(widget, event): if event.button == 3: menu = GtkMenu() menu.append(GtkMenuItem('foo')) menu.append(GtkMenuItem('bar'))

[pygtk] Segfault with popup menus

2001-11-19 Thread Paul Brannan
With this program: from gtk import * def button_press(widget, event): if event.button == 3: menu = GtkMenu() menu.append(GtkMenuItem('foo')) menu.append(GtkMenuItem('bar')) menu.popup(widget, None, None, event.button, event.time) window = GtkWindow(WINDOW_TOPLE