Re: [gtk-list] menuitem and optionmenu don't follow the normal tree manner



On Mon, 2 Feb 1998, Tim Janik wrote:

> 
> hi all,
> 
> 
> there is a decent problem with menuitems that have sub_menus set,
> and with the optionmenu.
> in the current fileselection widget, ian uses the option menu for
> the directory history. once you change the directory, the sub menu
> of the optionmenu is destroy and he connects a new menu to it.
> this is *supposed* to work but doesn't because we don't have the
> foreach neither the container_add/container_remove functionality
> for option menus.
> 
> i talked to peter about this a while ago, and he even wondered why
> he hadn't implemented it this way in the first place.

after implementing the container_add and container_remove
funtionality i now know why.
first, even the fileselection widget works proper now, there's
just a minor gnit ;)))

GtkMenus have their parent set to NULL (or *need* to).

for consistency with the rest of the toolkit i think it would
be best to have a function gtk_menu_set_parent() that will do the
same as gtk_widget_set_parent, but keep the parent pointer elsewhere
than widget->parent. this is needed for proper removal from the parent.
(or in other words: for proper destroy notification of the parents menu).


> 
> ---
> ciaoTJ
> 

---
ciaoTJ



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]