Consistently use GdkModifierType. (#66950, Mark Patton)

Tue Jan 29 21:50:28 2002  Owen Taylor  <otaylor@redhat.com>

        * gtk/gtkaccelmap.[ch] gtk/gtkbindings.[ch] gtk/gtkwidget.[ch]:
        Consistently use GdkModifierType. (#66950, Mark Patton)

        * gtk/gtkimagemenuitem.c (gtk_image_menu_item_new_from_stock):
        For consistency with gtk_button_new_from_stock(), fall back
        to gtk_image_menu_item_new_with_mnemnonic(). (#65944,
        Havoc Pennington)

        * gtk/gtkitemfactory.[ch] (gtk_item_factory_path_from_widget):
        Make G_CONST_RETURN. (#68527, Matt Wilson)
This commit is contained in:
Owen Taylor 2002-01-30 03:07:14 +00:00 committed by Owen Taylor
parent 36655ffa79
commit a75a0d494b
16 changed files with 138 additions and 46 deletions

View File

@ -1,3 +1,16 @@
Tue Jan 29 21:50:28 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkaccelmap.[ch] gtk/gtkbindings.[ch] gtk/gtkwidget.[ch]:
Consistently use GdkModifierType. (#66950, Mark Patton)
* gtk/gtkimagemenuitem.c (gtk_image_menu_item_new_from_stock):
For consistency with gtk_button_new_from_stock(), fall back
to gtk_image_menu_item_new_with_mnemnonic(). (#65944,
Havoc Pennington)
* gtk/gtkitemfactory.[ch] (gtk_item_factory_path_from_widget):
Make G_CONST_RETURN. (#68527, Matt Wilson)
Tue Jan 29 20:56:13 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtk[vh]scale.c (gtk_[vh]scale_new_with_range): Document

View File

@ -1,3 +1,16 @@
Tue Jan 29 21:50:28 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkaccelmap.[ch] gtk/gtkbindings.[ch] gtk/gtkwidget.[ch]:
Consistently use GdkModifierType. (#66950, Mark Patton)
* gtk/gtkimagemenuitem.c (gtk_image_menu_item_new_from_stock):
For consistency with gtk_button_new_from_stock(), fall back
to gtk_image_menu_item_new_with_mnemnonic(). (#65944,
Havoc Pennington)
* gtk/gtkitemfactory.[ch] (gtk_item_factory_path_from_widget):
Make G_CONST_RETURN. (#68527, Matt Wilson)
Tue Jan 29 20:56:13 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtk[vh]scale.c (gtk_[vh]scale_new_with_range): Document

View File

@ -1,3 +1,16 @@
Tue Jan 29 21:50:28 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkaccelmap.[ch] gtk/gtkbindings.[ch] gtk/gtkwidget.[ch]:
Consistently use GdkModifierType. (#66950, Mark Patton)
* gtk/gtkimagemenuitem.c (gtk_image_menu_item_new_from_stock):
For consistency with gtk_button_new_from_stock(), fall back
to gtk_image_menu_item_new_with_mnemnonic(). (#65944,
Havoc Pennington)
* gtk/gtkitemfactory.[ch] (gtk_item_factory_path_from_widget):
Make G_CONST_RETURN. (#68527, Matt Wilson)
Tue Jan 29 20:56:13 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtk[vh]scale.c (gtk_[vh]scale_new_with_range): Document

View File

@ -1,3 +1,16 @@
Tue Jan 29 21:50:28 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkaccelmap.[ch] gtk/gtkbindings.[ch] gtk/gtkwidget.[ch]:
Consistently use GdkModifierType. (#66950, Mark Patton)
* gtk/gtkimagemenuitem.c (gtk_image_menu_item_new_from_stock):
For consistency with gtk_button_new_from_stock(), fall back
to gtk_image_menu_item_new_with_mnemnonic(). (#65944,
Havoc Pennington)
* gtk/gtkitemfactory.[ch] (gtk_item_factory_path_from_widget):
Make G_CONST_RETURN. (#68527, Matt Wilson)
Tue Jan 29 20:56:13 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtk[vh]scale.c (gtk_[vh]scale_new_with_range): Document

View File

@ -1,3 +1,16 @@
Tue Jan 29 21:50:28 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkaccelmap.[ch] gtk/gtkbindings.[ch] gtk/gtkwidget.[ch]:
Consistently use GdkModifierType. (#66950, Mark Patton)
* gtk/gtkimagemenuitem.c (gtk_image_menu_item_new_from_stock):
For consistency with gtk_button_new_from_stock(), fall back
to gtk_image_menu_item_new_with_mnemnonic(). (#65944,
Havoc Pennington)
* gtk/gtkitemfactory.[ch] (gtk_item_factory_path_from_widget):
Make G_CONST_RETURN. (#68527, Matt Wilson)
Tue Jan 29 20:56:13 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtk[vh]scale.c (gtk_[vh]scale_new_with_range): Document

View File

@ -1,3 +1,16 @@
Tue Jan 29 21:50:28 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkaccelmap.[ch] gtk/gtkbindings.[ch] gtk/gtkwidget.[ch]:
Consistently use GdkModifierType. (#66950, Mark Patton)
* gtk/gtkimagemenuitem.c (gtk_image_menu_item_new_from_stock):
For consistency with gtk_button_new_from_stock(), fall back
to gtk_image_menu_item_new_with_mnemnonic(). (#65944,
Havoc Pennington)
* gtk/gtkitemfactory.[ch] (gtk_item_factory_path_from_widget):
Make G_CONST_RETURN. (#68527, Matt Wilson)
Tue Jan 29 20:56:13 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtk[vh]scale.c (gtk_[vh]scale_new_with_range): Document

View File

@ -1,3 +1,16 @@
Tue Jan 29 21:50:28 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkaccelmap.[ch] gtk/gtkbindings.[ch] gtk/gtkwidget.[ch]:
Consistently use GdkModifierType. (#66950, Mark Patton)
* gtk/gtkimagemenuitem.c (gtk_image_menu_item_new_from_stock):
For consistency with gtk_button_new_from_stock(), fall back
to gtk_image_menu_item_new_with_mnemnonic(). (#65944,
Havoc Pennington)
* gtk/gtkitemfactory.[ch] (gtk_item_factory_path_from_widget):
Make G_CONST_RETURN. (#68527, Matt Wilson)
Tue Jan 29 20:56:13 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtk[vh]scale.c (gtk_[vh]scale_new_with_range): Document

View File

@ -125,9 +125,9 @@ _gtk_accel_path_is_valid (const gchar *accel_path)
* "&lt;Gimp-Toolbox&gt;/File/Dialogs/Tool Options...".
*/
void
gtk_accel_map_add_entry (const gchar *accel_path,
guint accel_key,
guint accel_mods)
gtk_accel_map_add_entry (const gchar *accel_path,
guint accel_key,
GdkModifierType accel_mods)
{
AccelEntry *entry;
@ -589,7 +589,7 @@ static void
accel_map_print (gpointer data,
const gchar *accel_path,
guint accel_key,
guint accel_mods,
GdkModifierType accel_mods,
gboolean changed)
{
GString *gstring = g_string_new (changed ? NULL : "; ");

View File

@ -29,14 +29,14 @@ G_BEGIN_DECLS
typedef void (*GtkAccelMapForeach) (gpointer data,
const gchar *accel_path,
guint accel_key,
guint accel_mods,
GdkModifierType accel_mods,
gboolean changed);
/* --- public API --- */
void gtk_accel_map_add_entry (const gchar *accel_path,
guint accel_key,
guint accel_mods);
GdkModifierType accel_mods);
gboolean gtk_accel_map_lookup_entry (const gchar *accel_path,
GtkAccelKey *key);
gboolean gtk_accel_map_change_entry (const gchar *accel_path,

View File

@ -109,9 +109,9 @@ binding_entries_compare (gconstpointer a,
}
static GtkBindingEntry*
binding_entry_new (GtkBindingSet *binding_set,
guint keyval,
guint modifiers)
binding_entry_new (GtkBindingSet *binding_set,
guint keyval,
GdkModifierType modifiers)
{
GtkBindingEntry *entry;
@ -222,8 +222,8 @@ binding_entry_destroy (GtkBindingEntry *entry)
}
static GtkBindingEntry*
binding_ht_lookup_list (guint keyval,
guint modifiers)
binding_ht_lookup_list (guint keyval,
GdkModifierType modifiers)
{
GtkBindingEntry lookup_entry = { 0 };
@ -237,9 +237,9 @@ binding_ht_lookup_list (guint keyval,
}
static GtkBindingEntry*
binding_ht_lookup_entry (GtkBindingSet *set,
guint keyval,
guint modifiers)
binding_ht_lookup_entry (GtkBindingSet *set,
guint keyval,
GdkModifierType modifiers)
{
GtkBindingEntry lookup_entry = { 0 };
GtkBindingEntry *entry;
@ -542,7 +542,7 @@ gtk_binding_set_find (const gchar *set_name)
gboolean
gtk_binding_set_activate (GtkBindingSet *binding_set,
guint keyval,
guint modifiers,
GdkModifierType modifiers,
GtkObject *object)
{
GtkBindingEntry *entry;
@ -564,7 +564,7 @@ gtk_binding_set_activate (GtkBindingSet *binding_set,
void
gtk_binding_entry_clear (GtkBindingSet *binding_set,
guint keyval,
guint modifiers)
GdkModifierType modifiers)
{
GtkBindingEntry *entry;
@ -583,7 +583,7 @@ gtk_binding_entry_clear (GtkBindingSet *binding_set,
void
gtk_binding_entry_remove (GtkBindingSet *binding_set,
guint keyval,
guint modifiers)
GdkModifierType modifiers)
{
GtkBindingEntry *entry;
@ -600,7 +600,7 @@ gtk_binding_entry_remove (GtkBindingSet *binding_set,
void
gtk_binding_entry_add_signall (GtkBindingSet *binding_set,
guint keyval,
guint modifiers,
GdkModifierType modifiers,
const gchar *signal_name,
GSList *binding_args)
{
@ -678,7 +678,7 @@ gtk_binding_entry_add_signall (GtkBindingSet *binding_set,
void
gtk_binding_entry_add_signal (GtkBindingSet *binding_set,
guint keyval,
guint modifiers,
GdkModifierType modifiers,
const gchar *signal_name,
guint n_args,
...)
@ -920,7 +920,7 @@ gtk_binding_entries_sort_patterns (GtkBindingEntry *entries,
gboolean
gtk_bindings_activate (GtkObject *object,
guint keyval,
guint modifiers)
GdkModifierType modifiers)
{
GtkBindingEntry *entries;
GtkWidget *widget;
@ -1002,7 +1002,7 @@ static guint
gtk_binding_parse_signal (GScanner *scanner,
GtkBindingSet *binding_set,
guint keyval,
guint modifiers)
GdkModifierType modifiers)
{
gchar *signal;
guint expected_token = 0;
@ -1161,7 +1161,7 @@ gtk_binding_parse_bind (GScanner *scanner,
GtkBindingSet *binding_set)
{
guint keyval = 0;
guint modifiers = 0;
GdkModifierType modifiers = 0;
g_return_val_if_fail (scanner != NULL, G_TOKEN_ERROR);

View File

@ -65,7 +65,7 @@ struct _GtkBindingEntry
/* key portion
*/
guint keyval;
guint modifiers;
GdkModifierType modifiers;
GtkBindingSet *binding_set;
guint destroyed : 1;
@ -101,18 +101,18 @@ GtkBindingSet* gtk_binding_set_by_class(gpointer object_class);
GtkBindingSet* gtk_binding_set_find (const gchar *set_name);
gboolean gtk_bindings_activate (GtkObject *object,
guint keyval,
guint modifiers);
GdkModifierType modifiers);
gboolean gtk_binding_set_activate (GtkBindingSet *binding_set,
guint keyval,
guint modifiers,
GdkModifierType modifiers,
GtkObject *object);
#define gtk_binding_entry_add gtk_binding_entry_clear
void gtk_binding_entry_clear (GtkBindingSet *binding_set,
guint keyval,
guint modifiers);
GdkModifierType modifiers);
void gtk_binding_entry_add_signal (GtkBindingSet *binding_set,
guint keyval,
guint modifiers,
GdkModifierType modifiers,
const gchar *signal_name,
guint n_args,
...);
@ -126,10 +126,10 @@ void gtk_binding_set_add_path (GtkBindingSet *binding_set,
void gtk_binding_entry_remove (GtkBindingSet *binding_set,
guint keyval,
guint modifiers);
GdkModifierType modifiers);
void gtk_binding_entry_add_signall (GtkBindingSet *binding_set,
guint keyval,
guint modifiers,
GdkModifierType modifiers,
const gchar *signal_name,
GSList *binding_args);
guint gtk_binding_parse_binding (GScanner *scanner);

View File

@ -393,7 +393,7 @@ gtk_image_menu_item_new_from_stock (const gchar *stock_id,
}
else
{
item = gtk_image_menu_item_new_with_label (stock_id);
item = gtk_image_menu_item_new_with_mnemonic (stock_id);
gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item), image);
}

View File

@ -586,14 +586,15 @@ gtk_item_factory_from_widget (GtkWidget *widget)
* gtk_item_factory_path_from_widget:
* @widget: a widget
* @returns: the full path to @widget if it been created by an item factory,
* %NULL otherwise
* %NULL otherwise. This value is owned by GTK+ and must not be
* modified or freed.
*
* If @widget has been created by an item factory, returns the full path
* to it. (The full path of a widget is the concatenation of the factory
* path specified in gtk_item_factory_new() with the path specified in the
* #GtkItemFactoryEntry from which the widget was created.)
*/
gchar*
G_CONST_RETURN gchar*
gtk_item_factory_path_from_widget (GtkWidget *widget)
{
g_return_val_if_fail (GTK_IS_WIDGET (widget), NULL);

View File

@ -143,8 +143,8 @@ void gtk_item_factory_add_foreign (GtkWidget *accel_widget,
guint keyval,
GdkModifierType modifiers);
GtkItemFactory* gtk_item_factory_from_widget (GtkWidget *widget);
gchar* gtk_item_factory_path_from_widget (GtkWidget *widget);
GtkItemFactory* gtk_item_factory_from_widget (GtkWidget *widget);
G_CONST_RETURN gchar* gtk_item_factory_path_from_widget (GtkWidget *widget);
GtkWidget* gtk_item_factory_get_item (GtkItemFactory *ifactory,
const gchar *path);

View File

@ -2603,12 +2603,12 @@ widget_new_accel_closure (GtkWidget *widget,
* instead.
*/
void
gtk_widget_add_accelerator (GtkWidget *widget,
const gchar *accel_signal,
GtkAccelGroup *accel_group,
guint accel_key,
guint accel_mods,
GtkAccelFlags accel_flags)
gtk_widget_add_accelerator (GtkWidget *widget,
const gchar *accel_signal,
GtkAccelGroup *accel_group,
guint accel_key,
GdkModifierType accel_mods,
GtkAccelFlags accel_flags)
{
GClosure *closure;
GSignalQuery query;
@ -2659,10 +2659,10 @@ gtk_widget_add_accelerator (GtkWidget *widget,
* gtk_widget_add_accelerator().
*/
gboolean
gtk_widget_remove_accelerator (GtkWidget *widget,
GtkAccelGroup *accel_group,
guint accel_key,
guint accel_mods)
gtk_widget_remove_accelerator (GtkWidget *widget,
GtkAccelGroup *accel_group,
guint accel_key,
GdkModifierType accel_mods)
{
GtkAccelGroupEntry *ag_entry;
GList *slist, *clist;

View File

@ -482,12 +482,12 @@ void gtk_widget_add_accelerator (GtkWidget *widget,
const gchar *accel_signal,
GtkAccelGroup *accel_group,
guint accel_key,
guint accel_mods,
GdkModifierType accel_mods,
GtkAccelFlags accel_flags);
gboolean gtk_widget_remove_accelerator (GtkWidget *widget,
GtkAccelGroup *accel_group,
guint accel_key,
guint accel_mods);
GdkModifierType accel_mods);
void _gtk_widget_set_accel_path (GtkWidget *widget,
const gchar *accel_path,
GtkAccelGroup *accel_group);