[Glade-users] gtk.ListStore( ) question
- From: ashats at hotmail.com (Arthur Shats)
- Subject: [Glade-users] gtk.ListStore( ) question
- Date: Fri, 8 Oct 2010 21:08:52 +0000
I have two windows created in Glade. Each window has a GtkComboBoxEntry also created in Glade. In my Python
code, on the 1st window I fill the box with items using gtk.ListStore:
store = gtk.ListStore(str)
myComboBox.set_model(store)
store.append(["Select"])
store.append(["test1"])
store.append(["test2"])
All is fine. Then I hide this window, and show my window #2 which has its own GtkComboBoxEntry and I fill it
exactly the same way (only the box name is different, myComboBoxTwo). When I execute the code, the box on the
1st window is OK, but when I go to the next window and click on the box arrow, the list is empty, but it does
seem to have the space for three items. It's like I need to do myComboBoxTwo.show(), but even if I add this
line, the list is still empty. And when I click on the empty space, it gives me a warning,
"gtk_entry_set_text: assertion `text != NULL' failed"
Any idea why the list is empty and how to fix it?
I have a separate function where I fill the list. And I call the function right before I call
myWindow2.show(). I tried calling the func before and after myWindow2.show(), but still the list is empty. I
tried to do myWindow2.show_all(), but still empty.
Thanks,
Arthur.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/glade-users/attachments/20101008/fdc83162/attachment.html
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]