diff --git a/ChangeLog b/ChangeLog index 28948b9aa5..467fcdfb35 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,18 @@ +Sun Apr 1 08:00:13 2001 Tim Janik + + * gtk/gtkwidget.[hc]: got rid of gtk_widget_popup(), a function that + bad needs to be nuked, not just deprecated. + + * gtk/gtktooltips.c (gtk_tooltips_draw_tips): don't use + gtk_widget_popup(). + + * gtk/*.[hc]: s/activate_mnemonic/mnemonic_activate/g; + + * gtk/gtkmenufactory.[hc]: removed this long-standingly deprecated + widget. + + * docs/Changes-2.0.txt: updates. + Sun Apr 1 01:02:54 2001 Jonathan Blandford * gtk/gtktreestore.c (gtk_tree_store_sort_iter_changed): diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 28948b9aa5..467fcdfb35 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,18 @@ +Sun Apr 1 08:00:13 2001 Tim Janik + + * gtk/gtkwidget.[hc]: got rid of gtk_widget_popup(), a function that + bad needs to be nuked, not just deprecated. + + * gtk/gtktooltips.c (gtk_tooltips_draw_tips): don't use + gtk_widget_popup(). + + * gtk/*.[hc]: s/activate_mnemonic/mnemonic_activate/g; + + * gtk/gtkmenufactory.[hc]: removed this long-standingly deprecated + widget. + + * docs/Changes-2.0.txt: updates. + Sun Apr 1 01:02:54 2001 Jonathan Blandford * gtk/gtktreestore.c (gtk_tree_store_sort_iter_changed): diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 28948b9aa5..467fcdfb35 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,18 @@ +Sun Apr 1 08:00:13 2001 Tim Janik + + * gtk/gtkwidget.[hc]: got rid of gtk_widget_popup(), a function that + bad needs to be nuked, not just deprecated. + + * gtk/gtktooltips.c (gtk_tooltips_draw_tips): don't use + gtk_widget_popup(). + + * gtk/*.[hc]: s/activate_mnemonic/mnemonic_activate/g; + + * gtk/gtkmenufactory.[hc]: removed this long-standingly deprecated + widget. + + * docs/Changes-2.0.txt: updates. + Sun Apr 1 01:02:54 2001 Jonathan Blandford * gtk/gtktreestore.c (gtk_tree_store_sort_iter_changed): diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 28948b9aa5..467fcdfb35 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,18 @@ +Sun Apr 1 08:00:13 2001 Tim Janik + + * gtk/gtkwidget.[hc]: got rid of gtk_widget_popup(), a function that + bad needs to be nuked, not just deprecated. + + * gtk/gtktooltips.c (gtk_tooltips_draw_tips): don't use + gtk_widget_popup(). + + * gtk/*.[hc]: s/activate_mnemonic/mnemonic_activate/g; + + * gtk/gtkmenufactory.[hc]: removed this long-standingly deprecated + widget. + + * docs/Changes-2.0.txt: updates. + Sun Apr 1 01:02:54 2001 Jonathan Blandford * gtk/gtktreestore.c (gtk_tree_store_sort_iter_changed): diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 28948b9aa5..467fcdfb35 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,18 @@ +Sun Apr 1 08:00:13 2001 Tim Janik + + * gtk/gtkwidget.[hc]: got rid of gtk_widget_popup(), a function that + bad needs to be nuked, not just deprecated. + + * gtk/gtktooltips.c (gtk_tooltips_draw_tips): don't use + gtk_widget_popup(). + + * gtk/*.[hc]: s/activate_mnemonic/mnemonic_activate/g; + + * gtk/gtkmenufactory.[hc]: removed this long-standingly deprecated + widget. + + * docs/Changes-2.0.txt: updates. + Sun Apr 1 01:02:54 2001 Jonathan Blandford * gtk/gtktreestore.c (gtk_tree_store_sort_iter_changed): diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 28948b9aa5..467fcdfb35 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,18 @@ +Sun Apr 1 08:00:13 2001 Tim Janik + + * gtk/gtkwidget.[hc]: got rid of gtk_widget_popup(), a function that + bad needs to be nuked, not just deprecated. + + * gtk/gtktooltips.c (gtk_tooltips_draw_tips): don't use + gtk_widget_popup(). + + * gtk/*.[hc]: s/activate_mnemonic/mnemonic_activate/g; + + * gtk/gtkmenufactory.[hc]: removed this long-standingly deprecated + widget. + + * docs/Changes-2.0.txt: updates. + Sun Apr 1 01:02:54 2001 Jonathan Blandford * gtk/gtktreestore.c (gtk_tree_store_sort_iter_changed): diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 28948b9aa5..467fcdfb35 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,18 @@ +Sun Apr 1 08:00:13 2001 Tim Janik + + * gtk/gtkwidget.[hc]: got rid of gtk_widget_popup(), a function that + bad needs to be nuked, not just deprecated. + + * gtk/gtktooltips.c (gtk_tooltips_draw_tips): don't use + gtk_widget_popup(). + + * gtk/*.[hc]: s/activate_mnemonic/mnemonic_activate/g; + + * gtk/gtkmenufactory.[hc]: removed this long-standingly deprecated + widget. + + * docs/Changes-2.0.txt: updates. + Sun Apr 1 01:02:54 2001 Jonathan Blandford * gtk/gtktreestore.c (gtk_tree_store_sort_iter_changed): diff --git a/docs/Changes-2.0.txt b/docs/Changes-2.0.txt index 29ac9ea712..f834f605c4 100644 --- a/docs/Changes-2.0.txt +++ b/docs/Changes-2.0.txt @@ -206,12 +206,16 @@ Incompatible Changes from GTK+-1.2 to GTK+-2.0: #define gdk_cursor_destroy gdk_cursor_unref (Note that g_object_ref() and g_object_unref() may be used for all of - the above.) + the above _ref and _unref functions.) #define gdk_window_copy_area(drawable,gc,x,y,source_drawable,source_x,source_y,width,height) \ gdk_draw_pixmap(drawable,gc,source_drawable,source_x,source_y,x,y,width,height) #define gdk_rgb_get_cmap gdk_rgb_get_colormap + + gtk_widget_popup() was removed, it was only usable for GtkWindows, and + there the same effect can be achived by gtk_widget_set_uposition() and + gtk_widget_show(). * gdk_pixmap_foreign_new() no longer calls XFreePixmap() on the pixmap when the GdkPixmap is finalized. This change corresponds diff --git a/docs/reference/gtk/tmpl/gtk-unused.sgml b/docs/reference/gtk/tmpl/gtk-unused.sgml index 26e6b16e0e..a198a0c11e 100644 --- a/docs/reference/gtk/tmpl/gtk-unused.sgml +++ b/docs/reference/gtk/tmpl/gtk-unused.sgml @@ -717,6 +717,15 @@ produce superscript and subscript. + + + + + +@widget: the object which received the signal. +@arg1: +@Returns: + @@ -1454,6 +1463,34 @@ Set the varargs type for a fundamental type @foreign_type. fundamental type. @varargs_type: Must be a GtkType which is either structured or flag, or NONE. + + + + + +@widget: +@group_cycling: +@Returns: + + + + + + +@widget: +@x: +@y: + + + + + + +@window: +@keyval: +@modifier: +@Returns: + diff --git a/docs/reference/gtk/tmpl/gtktreestore.sgml b/docs/reference/gtk/tmpl/gtktreestore.sgml index 8215040598..db78575aa5 100644 --- a/docs/reference/gtk/tmpl/gtktreestore.sgml +++ b/docs/reference/gtk/tmpl/gtktreestore.sgml @@ -20,11 +20,13 @@ GtkTreeStore @parent: -@sort_list: @stamp: @root: @last: @n_columns: +@sort_column_id: +@sort_list: +@order: @column_headers: diff --git a/docs/reference/gtk/tmpl/gtkwidget.sgml b/docs/reference/gtk/tmpl/gtkwidget.sgml index 6b2b10024b..28ac76363e 100644 --- a/docs/reference/gtk/tmpl/gtkwidget.sgml +++ b/docs/reference/gtk/tmpl/gtkwidget.sgml @@ -571,16 +571,6 @@ GtkWidget @new_parent: - - - - - -@widget: -@x: -@y: - - @@ -1249,16 +1239,6 @@ GtkWidget @Returns: - - - - - -@widget: -@group_cycling: -@Returns: - - @@ -1332,15 +1312,6 @@ GtkWidget @var_args: - - - - - -@widget: the object which received the signal. -@arg1: -@Returns: - @@ -1609,6 +1580,15 @@ a widget changes from un-anchored to anchored or vice-versa. @event: @Returns: + + + + + +@widget: the object which received the signal. +@arg1: +@Returns: + diff --git a/docs/reference/gtk/tmpl/gtkwindow.sgml b/docs/reference/gtk/tmpl/gtkwindow.sgml index d626ca1795..e4cddd34b0 100644 --- a/docs/reference/gtk/tmpl/gtkwindow.sgml +++ b/docs/reference/gtk/tmpl/gtkwindow.sgml @@ -236,17 +236,6 @@ it's larger @Returns: - - - - - -@window: -@keyval: -@modifier: -@Returns: - - diff --git a/gtk/Makefile.am b/gtk/Makefile.am index 8ed2d8d1a1..3438377f80 100644 --- a/gtk/Makefile.am +++ b/gtk/Makefile.am @@ -121,7 +121,6 @@ gtk_public_h_sources = @STRIP_BEGIN@ \ gtkmain.h \ gtkmenu.h \ gtkmenubar.h \ - gtkmenufactory.h \ gtkmenuitem.h \ gtkmenushell.h \ gtkmessagedialog.h \ @@ -281,7 +280,6 @@ gtk_c_sources = @STRIP_BEGIN@ \ gtkmain.c \ gtkmenu.c \ gtkmenubar.c \ - gtkmenufactory.c \ gtkmenuitem.c \ gtkmenushell.c \ gtkmessagedialog.c \ diff --git a/gtk/gtk.h b/gtk/gtk.h index e762c68df9..512e9523d2 100644 --- a/gtk/gtk.h +++ b/gtk/gtk.h @@ -96,7 +96,6 @@ #include #include #include -#include #include #include #include diff --git a/gtk/gtkentry.c b/gtk/gtkentry.c index 9597e85255..b138e54bcc 100644 --- a/gtk/gtkentry.c +++ b/gtk/gtkentry.c @@ -252,7 +252,7 @@ static void gtk_entry_paste (GtkEntry *entry, static void gtk_entry_update_primary_selection (GtkEntry *entry); static void gtk_entry_do_popup (GtkEntry *entry, GdkEventButton *event); -static gboolean gtk_entry_activate_mnemonic (GtkWidget *widget, +static gboolean gtk_entry_mnemonic_activate (GtkWidget *widget, gboolean group_cycling); static GtkWidgetClass *parent_class = NULL; @@ -345,7 +345,7 @@ gtk_entry_class_init (GtkEntryClass *class) widget_class->style_set = gtk_entry_style_set; widget_class->direction_changed = gtk_entry_direction_changed; widget_class->state_changed = gtk_entry_state_changed; - widget_class->activate_mnemonic = gtk_entry_activate_mnemonic; + widget_class->mnemonic_activate = gtk_entry_mnemonic_activate; widget_class->drag_motion = gtk_entry_drag_motion; widget_class->drag_leave = gtk_entry_drag_leave; @@ -3150,7 +3150,7 @@ activate_cb (GtkWidget *menuitem, static gboolean -gtk_entry_activate_mnemonic (GtkWidget *widget, +gtk_entry_mnemonic_activate (GtkWidget *widget, gboolean group_cycling) { gtk_widget_grab_focus (widget); diff --git a/gtk/gtkitemfactory.h b/gtk/gtkitemfactory.h index e68931576a..bbe2febe6c 100644 --- a/gtk/gtkitemfactory.h +++ b/gtk/gtkitemfactory.h @@ -32,7 +32,6 @@ #include -#include /* for GtkMenuEntry */ #include /* for GtkPatternSpec */ @@ -217,6 +216,15 @@ void gtk_item_factory_set_translate_func (GtkItemFactory *ifactory, /* Compatibility functions for deprecated GtkMenuFactory code */ +typedef void (*GtkMenuCallback) (GtkWidget *widget, + gpointer user_data); +typedef struct { + gchar *path; + gchar *accelerator; + GtkMenuCallback callback; + gpointer callback_data; + GtkWidget *widget; +} GtkMenuEntry; GtkItemFactory* gtk_item_factory_from_path (const gchar *path); void gtk_item_factory_create_menu_entries (guint n_entries, GtkMenuEntry *entries); diff --git a/gtk/gtklabel.c b/gtk/gtklabel.c index 79255812d3..028b6a709e 100644 --- a/gtk/gtklabel.c +++ b/gtk/gtklabel.c @@ -123,7 +123,7 @@ static void gtk_label_select_region_index (GtkLabel *label, gint anchor_index, gint end_index); -static gboolean gtk_label_activate_mnemonic (GtkWidget *widget, +static gboolean gtk_label_mnemonic_activate (GtkWidget *widget, gboolean group_cycling); @@ -184,7 +184,7 @@ gtk_label_class_init (GtkLabelClass *class) widget_class->button_release_event = gtk_label_button_release; widget_class->motion_notify_event = gtk_label_motion; widget_class->hierarchy_changed = gtk_label_hierarchy_changed; - widget_class->activate_mnemonic = gtk_label_activate_mnemonic; + widget_class->mnemonic_activate = gtk_label_mnemonic_activate; g_object_class_install_property (G_OBJECT_CLASS(object_class), PROP_LABEL, @@ -431,13 +431,13 @@ gtk_label_new_with_mnemonic (const gchar *str) } static gboolean -gtk_label_activate_mnemonic (GtkWidget *widget, +gtk_label_mnemonic_activate (GtkWidget *widget, gboolean group_cycling) { GtkWidget *parent; if (GTK_LABEL (widget)->mnemonic_widget) - return gtk_widget_activate_mnemonic (GTK_LABEL (widget)->mnemonic_widget, group_cycling); + return gtk_widget_mnemonic_activate (GTK_LABEL (widget)->mnemonic_widget, group_cycling); /* Try to find the widget to activate by traversing the * widget's ancestry. @@ -449,7 +449,7 @@ gtk_label_activate_mnemonic (GtkWidget *widget, (!group_cycling && GTK_WIDGET_GET_CLASS (parent)->activate_signal) || (parent->parent && GTK_IS_NOTEBOOK (parent->parent)) || (GTK_IS_MENU_ITEM (parent))) - return gtk_widget_activate_mnemonic (parent, group_cycling); + return gtk_widget_mnemonic_activate (parent, group_cycling); parent = parent->parent; } @@ -509,7 +509,7 @@ gtk_label_hierarchy_changed (GtkWidget *widget) * (i.e. when the target is a #GtkEntry next to the label) you need to * set it explicitly using this function. * - * The target widget will be accelerated by emitting "activate_mnemonic" on it. + * The target widget will be accelerated by emitting "mnemonic_activate" on it. * The default handler for this signal will activate the widget if there are no * mnemonic collisions and toggle focus between the colliding widgets otherwise. **/ diff --git a/gtk/gtkmenuitem.c b/gtk/gtkmenuitem.c index d728377ba3..4c68939ecf 100644 --- a/gtk/gtkmenuitem.c +++ b/gtk/gtkmenuitem.c @@ -67,7 +67,7 @@ static void gtk_real_menu_item_toggle_size_request (GtkMenuItem *menu_item, gint *requisition); static void gtk_real_menu_item_toggle_size_allocate (GtkMenuItem *menu_item, gint allocation); -static gboolean gtk_menu_item_activate_mnemonic (GtkWidget *widget, +static gboolean gtk_menu_item_mnemonic_activate (GtkWidget *widget, gboolean group_cycling); static gint gtk_menu_item_select_timeout (gpointer data); @@ -140,7 +140,7 @@ gtk_menu_item_class_init (GtkMenuItemClass *klass) widget_class->expose_event = gtk_menu_item_expose; widget_class->show_all = gtk_menu_item_show_all; widget_class->hide_all = gtk_menu_item_hide_all; - widget_class->activate_mnemonic = gtk_menu_item_activate_mnemonic; + widget_class->mnemonic_activate = gtk_menu_item_mnemonic_activate; container_class->forall = gtk_menu_item_forall; @@ -606,7 +606,7 @@ gtk_real_menu_item_deselect (GtkItem *item) } static gboolean -gtk_menu_item_activate_mnemonic (GtkWidget *widget, +gtk_menu_item_mnemonic_activate (GtkWidget *widget, gboolean group_cycling) { if (group_cycling) diff --git a/gtk/gtkmenushell.c b/gtk/gtkmenushell.c index 5843799144..6575a80e43 100644 --- a/gtk/gtkmenushell.c +++ b/gtk/gtkmenushell.c @@ -568,7 +568,7 @@ gtk_menu_shell_key_press (GtkWidget *widget, toplevel = gtk_widget_get_toplevel (widget); if (GTK_IS_WINDOW (toplevel) && - gtk_window_activate_mnemonic (GTK_WINDOW (toplevel), + gtk_window_mnemonic_activate (GTK_WINDOW (toplevel), event->keyval, event->state)) return TRUE; diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c index 530b5de949..96b3bd5969 100644 --- a/gtk/gtknotebook.c +++ b/gtk/gtknotebook.c @@ -95,7 +95,7 @@ struct _GtkNotebookPage GtkRequisition requisition; GtkAllocation allocation; - guint activate_mnemonic_signal; + guint mnemonic_activate_signal; }; #ifdef G_DISABLE_CHECKS @@ -1977,9 +1977,9 @@ gtk_notebook_real_remove (GtkNotebook *notebook, if (GTK_WIDGET_VISIBLE (page->child) && GTK_WIDGET_VISIBLE (notebook)) need_resize = TRUE; - if (page->tab_label && page->activate_mnemonic_signal) + if (page->tab_label && page->mnemonic_activate_signal) gtk_signal_disconnect (page->tab_label, - page->activate_mnemonic_signal); + page->mnemonic_activate_signal); gtk_widget_unparent (page->child); @@ -3636,7 +3636,7 @@ gtk_notebook_page_compare_tab (gconstpointer a, } static gboolean -gtk_notebook_activate_mnemonic_switch_page (GtkWidget *child, +gtk_notebook_mnemonic_activate_switch_page (GtkWidget *child, gboolean overload, gpointer data) { @@ -3698,7 +3698,7 @@ gtk_notebook_insert_page_menu (GtkNotebook *notebook, page->allocation.height = 0; page->default_menu = FALSE; page->default_tab = FALSE; - page->activate_mnemonic_signal = 0; + page->mnemonic_activate_signal = 0; nchildren = g_list_length (notebook->children); if ((position < 0) || (position > nchildren)) @@ -3781,10 +3781,10 @@ gtk_notebook_insert_page_menu (GtkNotebook *notebook, } if (tab_label) - page->activate_mnemonic_signal = + page->mnemonic_activate_signal = gtk_signal_connect (GTK_OBJECT (tab_label), - "activate_mnemonic", - (GtkSignalFunc) gtk_notebook_activate_mnemonic_switch_page, + "mnemonic_activate", + (GtkSignalFunc) gtk_notebook_mnemonic_activate_switch_page, notebook); } diff --git a/gtk/gtksettings.c b/gtk/gtksettings.c index 5d8da2a789..7078737b21 100644 --- a/gtk/gtksettings.c +++ b/gtk/gtksettings.c @@ -234,7 +234,6 @@ gtk_settings_notify (GObject *object, g_value_init (&tmp_value, G_PARAM_SPEC_VALUE_TYPE (pspec)); g_object_get_property (object, pspec->name, &tmp_value); contents = g_strdup_value_contents (&tmp_value); -#endif switch (property_id) { @@ -252,7 +251,6 @@ gtk_settings_notify (GObject *object, break; } -#if 1 g_free (contents); g_value_unset (&tmp_value); #endif diff --git a/gtk/gtktooltips.c b/gtk/gtktooltips.c index fb25448f51..fb9a2f10ad 100644 --- a/gtk/gtktooltips.c +++ b/gtk/gtktooltips.c @@ -357,7 +357,8 @@ gtk_tooltips_draw_tips (GtkTooltips * tooltips) else y = y + widget->allocation.height + 4; - gtk_widget_popup (tooltips->tip_window, x, y); + gtk_widget_set_uposition (tooltips->tip_window, x, y); + gtk_widget_show (tooltips->tip_window); } static gint diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c index b3c485ab12..2f23111598 100644 --- a/gtk/gtkwidget.c +++ b/gtk/gtkwidget.c @@ -195,7 +195,7 @@ static gint gtk_widget_event_internal (GtkWidget *widget, static void gtk_widget_propagate_hierarchy_changed (GtkWidget *widget, gpointer client_data); -static gboolean gtk_widget_real_activate_mnemonic (GtkWidget *widget, +static gboolean gtk_widget_real_mnemonic_activate (GtkWidget *widget, gboolean group_cycling); static void gtk_widget_aux_info_destroy (GtkWidgetAuxInfo *aux_info); @@ -317,7 +317,7 @@ gtk_widget_class_init (GtkWidgetClass *klass) klass->direction_changed = gtk_widget_direction_changed; klass->add_accelerator = (void*) gtk_accel_group_handle_add; klass->remove_accelerator = (void*) gtk_accel_group_handle_remove; - klass->activate_mnemonic = gtk_widget_real_activate_mnemonic; + klass->mnemonic_activate = gtk_widget_real_mnemonic_activate; klass->grab_focus = gtk_widget_real_grab_focus; klass->event = NULL; klass->button_press_event = NULL; @@ -626,10 +626,10 @@ gtk_widget_class_init (GtkWidgetClass *klass) gtk_accel_group_create_remove (GTK_CLASS_TYPE (object_class), GTK_RUN_LAST, GTK_SIGNAL_OFFSET (GtkWidgetClass, remove_accelerator)); widget_signals[ACTIVATE_MNEMONIC] = - g_signal_newc ("activate_mnemonic", + g_signal_newc ("mnemonic_activate", GTK_CLASS_TYPE (object_class), GTK_RUN_LAST, - GTK_SIGNAL_OFFSET (GtkWidgetClass, activate_mnemonic), + GTK_SIGNAL_OFFSET (GtkWidgetClass, mnemonic_activate), accumulator_stop_handled_emission, NULL, gtk_marshal_BOOLEAN__BOOLEAN, GTK_TYPE_BOOL, 1, @@ -2391,7 +2391,7 @@ gtk_widget_accelerator_signal (GtkWidget *widget, } gboolean -gtk_widget_activate_mnemonic (GtkWidget *widget, +gtk_widget_mnemonic_activate (GtkWidget *widget, gboolean group_cycling) { gboolean handled; @@ -2410,7 +2410,7 @@ gtk_widget_activate_mnemonic (GtkWidget *widget, } static gboolean -gtk_widget_real_activate_mnemonic (GtkWidget *widget, +gtk_widget_real_mnemonic_activate (GtkWidget *widget, gboolean group_cycling) { if (!group_cycling && GTK_WIDGET_GET_CLASS (widget)->activate_signal) @@ -2813,34 +2813,6 @@ gtk_widget_reparent (GtkWidget *widget, } } -/** - * gtk_widget_popup: - * @widget: - * @x: - * @y: - * - * DEPRECATED. Completely useless function as far as we know. - * Probably does something bad. - * - **/ -void -gtk_widget_popup (GtkWidget *widget, - gint x, - gint y) -{ - g_return_if_fail (widget != NULL); - g_return_if_fail (GTK_IS_WIDGET (widget)); - - if (!GTK_WIDGET_VISIBLE (widget)) - { - if (!GTK_WIDGET_REALIZED (widget)) - gtk_widget_realize (widget); - if (!GTK_WIDGET_NO_WINDOW (widget)) - gdk_window_move (widget->window, x, y); - gtk_widget_show (widget); - } -} - /** * gtk_widget_intersect: * @widget: a #GtkWidget diff --git a/gtk/gtkwidget.h b/gtk/gtkwidget.h index 88e776692a..80018b897f 100644 --- a/gtk/gtkwidget.h +++ b/gtk/gtkwidget.h @@ -272,7 +272,7 @@ struct _GtkWidgetClass GdkModifierType accel_mods); /* Mnemonics */ - gboolean (* activate_mnemonic) (GtkWidget *widget, + gboolean (* mnemonic_activate) (GtkWidget *widget, gboolean group_cycling); /* explicit focus */ @@ -476,7 +476,7 @@ guint gtk_widget_accelerator_signal (GtkWidget *widget, void gtk_widget_lock_accelerators (GtkWidget *widget); void gtk_widget_unlock_accelerators (GtkWidget *widget); gboolean gtk_widget_accelerators_locked (GtkWidget *widget); -gboolean gtk_widget_activate_mnemonic (GtkWidget *widget, +gboolean gtk_widget_mnemonic_activate (GtkWidget *widget, gboolean group_cycling); gboolean gtk_widget_event (GtkWidget *widget, GdkEvent *event); @@ -490,9 +490,6 @@ gboolean gtk_widget_set_scroll_adjustments (GtkWidget *widget, void gtk_widget_reparent (GtkWidget *widget, GtkWidget *new_parent); -void gtk_widget_popup (GtkWidget *widget, - gint x, - gint y); gboolean gtk_widget_intersect (GtkWidget *widget, GdkRectangle *area, GdkRectangle *intersection); diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c index d5ec03dfac..901f9c76e4 100644 --- a/gtk/gtkwindow.c +++ b/gtk/gtkwindow.c @@ -876,7 +876,7 @@ gtk_window_remove_mnemonic (GtkWindow *window, } gboolean -gtk_window_activate_mnemonic (GtkWindow *window, +gtk_window_mnemonic_activate (GtkWindow *window, guint keyval, GdkModifierType modifier) { @@ -927,7 +927,7 @@ gtk_window_activate_mnemonic (GtkWindow *window, mnemonic->targets = g_slist_remove (mnemonic->targets, chosen_widget); mnemonic->targets = g_slist_append (mnemonic->targets, chosen_widget); - return gtk_widget_activate_mnemonic (chosen_widget, overloaded); + return gtk_widget_mnemonic_activate (chosen_widget, overloaded); } return FALSE; } @@ -2051,7 +2051,7 @@ gtk_window_key_press_event (GtkWidget *widget, handled = gtk_widget_event (window->focus_widget, (GdkEvent*) event); if (!handled) - handled = gtk_window_activate_mnemonic (window, + handled = gtk_window_mnemonic_activate (window, event->keyval, event->state); diff --git a/gtk/gtkwindow.h b/gtk/gtkwindow.h index e4ed83eb49..5264ccd476 100644 --- a/gtk/gtkwindow.h +++ b/gtk/gtkwindow.h @@ -181,7 +181,7 @@ void gtk_window_add_mnemonic (GtkWindow *window, void gtk_window_remove_mnemonic (GtkWindow *window, guint keyval, GtkWidget *target); -gboolean gtk_window_activate_mnemonic (GtkWindow *window, +gboolean gtk_window_mnemonic_activate (GtkWindow *window, guint keyval, GdkModifierType modifier); void gtk_window_set_mnemonic_modifier (GtkWindow *window, @@ -230,7 +230,7 @@ void gtk_window_remove_embedded_xid (GtkWindow *window, guint xid); void gtk_window_add_embedded_xid (GtkWindow *window, guint xid); -void gtk_window_reposition (GtkWindow *window, +void _gtk_window_reposition (GtkWindow *window, gint x, gint y); void _gtk_window_constrain_size (GtkWindow *window,