Mercurial > pidgin
comparison finch/libgnt/gntmenu.c @ 18531:da550279d390
Use gobject properties instead of hacks when creating columns in a tree.
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Sat, 14 Jul 2007 01:31:44 +0000 |
parents | 8fc91e437981 |
children | 5dd1cfc53666 9f7587b86b0d |
comparison
equal
deleted
inserted
replaced
18526:09db6fec9dce | 18531:da550279d390 |
---|---|
421 if (type == GNT_MENU_TOPLEVEL) { | 421 if (type == GNT_MENU_TOPLEVEL) { |
422 widget->priv.x = 0; | 422 widget->priv.x = 0; |
423 widget->priv.y = 0; | 423 widget->priv.y = 0; |
424 } else { | 424 } else { |
425 GNT_TREE(widget)->show_separator = FALSE; | 425 GNT_TREE(widget)->show_separator = FALSE; |
426 _gnt_tree_init_internals(GNT_TREE(widget), NUM_COLUMNS); | 426 g_object_set(G_OBJECT(widget), "columns", NUM_COLUMNS, NULL); |
427 gnt_tree_set_col_width(GNT_TREE(widget), ITEM_TRIGGER, 3); | 427 gnt_tree_set_col_width(GNT_TREE(widget), ITEM_TRIGGER, 3); |
428 gnt_tree_set_column_resizable(GNT_TREE(widget), ITEM_TRIGGER, FALSE); | 428 gnt_tree_set_column_resizable(GNT_TREE(widget), ITEM_TRIGGER, FALSE); |
429 gnt_tree_set_col_width(GNT_TREE(widget), ITEM_SUBMENU, 1); | 429 gnt_tree_set_col_width(GNT_TREE(widget), ITEM_SUBMENU, 1); |
430 gnt_tree_set_column_resizable(GNT_TREE(widget), ITEM_SUBMENU, FALSE); | 430 gnt_tree_set_column_resizable(GNT_TREE(widget), ITEM_SUBMENU, FALSE); |
431 GNT_WIDGET_UNSET_FLAGS(widget, GNT_WIDGET_NO_BORDER); | 431 GNT_WIDGET_UNSET_FLAGS(widget, GNT_WIDGET_NO_BORDER); |