mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-10 10:50:10 +00:00
Rename function parameters from index to index_ to prevent clash with BSD
Tue Jun 1 23:14:46 2004 Matthias Clasen <maclas@gmx.de> * gtk/gtktoolbar.h: * gtk/gtktoolbar.c: * gtk/gtkentrycompletion.h: * gtk/gtkentrycompletion.c: * gtk/gtkcombobox.h: * gtk/gtkcombobox.c: Rename function parameters from index to index_ to prevent clash with BSD index(). (#143001)
This commit is contained in:
parent
018511c3aa
commit
d5f3cb1409
10
ChangeLog
10
ChangeLog
@ -1,3 +1,13 @@
|
||||
Tue Jun 1 23:00:20 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtktoolbar.h:
|
||||
* gtk/gtktoolbar.c:
|
||||
* gtk/gtkentrycompletion.h:
|
||||
* gtk/gtkentrycompletion.c:
|
||||
* gtk/gtkcombobox.h:
|
||||
* gtk/gtkcombobox.c: Rename function parameters from
|
||||
index to index_ to prevent clash with BSD index(). (#143001)
|
||||
|
||||
Tue Jun 1 22:45:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkmenu.c (get_accel_path): Handle accel_closure being
|
||||
|
@ -1,3 +1,13 @@
|
||||
Tue Jun 1 23:00:20 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtktoolbar.h:
|
||||
* gtk/gtktoolbar.c:
|
||||
* gtk/gtkentrycompletion.h:
|
||||
* gtk/gtkentrycompletion.c:
|
||||
* gtk/gtkcombobox.h:
|
||||
* gtk/gtkcombobox.c: Rename function parameters from
|
||||
index to index_ to prevent clash with BSD index(). (#143001)
|
||||
|
||||
Tue Jun 1 22:45:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkmenu.c (get_accel_path): Handle accel_closure being
|
||||
|
@ -1,3 +1,13 @@
|
||||
Tue Jun 1 23:00:20 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtktoolbar.h:
|
||||
* gtk/gtktoolbar.c:
|
||||
* gtk/gtkentrycompletion.h:
|
||||
* gtk/gtkentrycompletion.c:
|
||||
* gtk/gtkcombobox.h:
|
||||
* gtk/gtkcombobox.c: Rename function parameters from
|
||||
index to index_ to prevent clash with BSD index(). (#143001)
|
||||
|
||||
Tue Jun 1 22:45:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkmenu.c (get_accel_path): Handle accel_closure being
|
||||
|
@ -1,3 +1,13 @@
|
||||
Tue Jun 1 23:00:20 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtktoolbar.h:
|
||||
* gtk/gtktoolbar.c:
|
||||
* gtk/gtkentrycompletion.h:
|
||||
* gtk/gtkentrycompletion.c:
|
||||
* gtk/gtkcombobox.h:
|
||||
* gtk/gtkcombobox.c: Rename function parameters from
|
||||
index to index_ to prevent clash with BSD index(). (#143001)
|
||||
|
||||
Tue Jun 1 22:45:42 2004 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkmenu.c (get_accel_path): Handle accel_closure being
|
||||
|
@ -1948,13 +1948,13 @@ gtk_combo_box_menu_destroy (GtkComboBox *combo_box)
|
||||
|
||||
static void
|
||||
gtk_combo_box_item_get_size (GtkComboBox *combo_box,
|
||||
gint index,
|
||||
gint index_,
|
||||
gint *cols,
|
||||
gint *rows)
|
||||
{
|
||||
GtkTreeIter iter;
|
||||
|
||||
gtk_tree_model_iter_nth_child (combo_box->priv->model, &iter, NULL, index);
|
||||
gtk_tree_model_iter_nth_child (combo_box->priv->model, &iter, NULL, index_);
|
||||
|
||||
if (cols)
|
||||
{
|
||||
@ -3372,7 +3372,7 @@ gtk_combo_box_get_active (GtkComboBox *combo_box)
|
||||
/**
|
||||
* gtk_combo_box_set_active:
|
||||
* @combo_box: A #GtkComboBox.
|
||||
* @index: An index in the model passed during construction, or -1 to have
|
||||
* @index_: An index in the model passed during construction, or -1 to have
|
||||
* no active item.
|
||||
*
|
||||
* Sets the active item of @combo_box to be the item at @index.
|
||||
@ -3381,16 +3381,16 @@ gtk_combo_box_get_active (GtkComboBox *combo_box)
|
||||
*/
|
||||
void
|
||||
gtk_combo_box_set_active (GtkComboBox *combo_box,
|
||||
gint index)
|
||||
gint index_)
|
||||
{
|
||||
g_return_if_fail (GTK_IS_COMBO_BOX (combo_box));
|
||||
/* -1 means "no item selected" */
|
||||
g_return_if_fail (index >= -1);
|
||||
g_return_if_fail (index_ >= -1);
|
||||
|
||||
if (combo_box->priv->active_item == index)
|
||||
if (combo_box->priv->active_item == index_)
|
||||
return;
|
||||
|
||||
gtk_combo_box_set_active_internal (combo_box, index);
|
||||
gtk_combo_box_set_active_internal (combo_box, index_);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -83,7 +83,7 @@ void gtk_combo_box_set_add_tearoffs (GtkComboBox *combo_box,
|
||||
/* get/set active item */
|
||||
gint gtk_combo_box_get_active (GtkComboBox *combo_box);
|
||||
void gtk_combo_box_set_active (GtkComboBox *combo_box,
|
||||
gint index);
|
||||
gint index_);
|
||||
gboolean gtk_combo_box_get_active_iter (GtkComboBox *combo_box,
|
||||
GtkTreeIter *iter);
|
||||
void gtk_combo_box_set_active_iter (GtkComboBox *combo_box,
|
||||
|
@ -972,10 +972,10 @@ gtk_entry_completion_insert_action (GtkEntryCompletion *completion,
|
||||
/**
|
||||
* gtk_entry_completion_insert_action_text:
|
||||
* @completion: A #GtkEntryCompletion.
|
||||
* @index: The index of the item to insert.
|
||||
* @index_: The index of the item to insert.
|
||||
* @text: Text of the item to insert.
|
||||
*
|
||||
* Inserts an action in @completion's action item list at position @index
|
||||
* Inserts an action in @completion's action item list at position @index_
|
||||
* with text @text. If you want the action item to have markup, use
|
||||
* gtk_entry_completion_insert_action_markup().
|
||||
*
|
||||
@ -983,57 +983,57 @@ gtk_entry_completion_insert_action (GtkEntryCompletion *completion,
|
||||
*/
|
||||
void
|
||||
gtk_entry_completion_insert_action_text (GtkEntryCompletion *completion,
|
||||
gint index,
|
||||
gint index_,
|
||||
const gchar *text)
|
||||
{
|
||||
g_return_if_fail (GTK_IS_ENTRY_COMPLETION (completion));
|
||||
g_return_if_fail (text != NULL);
|
||||
|
||||
gtk_entry_completion_insert_action (completion, index, text, FALSE);
|
||||
gtk_entry_completion_insert_action (completion, index_, text, FALSE);
|
||||
}
|
||||
|
||||
/**
|
||||
* gtk_entry_completion_insert_action_markup:
|
||||
* @completion: A #GtkEntryCompletion.
|
||||
* @index: The index of the item to insert.
|
||||
* @index_: The index of the item to insert.
|
||||
* @markup: Markup of the item to insert.
|
||||
*
|
||||
* Inserts an action in @completion's action item list at position @index
|
||||
* Inserts an action in @completion's action item list at position @index_
|
||||
* with markup @markup.
|
||||
*
|
||||
* Since: 2.4
|
||||
*/
|
||||
void
|
||||
gtk_entry_completion_insert_action_markup (GtkEntryCompletion *completion,
|
||||
gint index,
|
||||
gint index_,
|
||||
const gchar *markup)
|
||||
{
|
||||
g_return_if_fail (GTK_IS_ENTRY_COMPLETION (completion));
|
||||
g_return_if_fail (markup != NULL);
|
||||
|
||||
gtk_entry_completion_insert_action (completion, index, markup, TRUE);
|
||||
gtk_entry_completion_insert_action (completion, index_, markup, TRUE);
|
||||
}
|
||||
|
||||
/**
|
||||
* gtk_entry_completion_delete_action:
|
||||
* @completion: A #GtkEntryCompletion.
|
||||
* @index: The index of the item to Delete.
|
||||
* @index_: The index of the item to Delete.
|
||||
*
|
||||
* Deletes the action at @index from @completion's action list.
|
||||
* Deletes the action at @index_ from @completion's action list.
|
||||
*
|
||||
* Since: 2.4
|
||||
*/
|
||||
void
|
||||
gtk_entry_completion_delete_action (GtkEntryCompletion *completion,
|
||||
gint index)
|
||||
gint index_)
|
||||
{
|
||||
GtkTreeIter iter;
|
||||
|
||||
g_return_if_fail (GTK_IS_ENTRY_COMPLETION (completion));
|
||||
g_return_if_fail (index >= 0);
|
||||
g_return_if_fail (index_ >= 0);
|
||||
|
||||
gtk_tree_model_iter_nth_child (GTK_TREE_MODEL (completion->priv->actions),
|
||||
&iter, NULL, index);
|
||||
&iter, NULL, index_);
|
||||
gtk_list_store_remove (completion->priv->actions, &iter);
|
||||
}
|
||||
|
||||
|
@ -62,7 +62,7 @@ struct _GtkEntryCompletionClass
|
||||
GtkTreeModel *model,
|
||||
GtkTreeIter *iter);
|
||||
void (* action_activated) (GtkEntryCompletion *completion,
|
||||
gint index);
|
||||
gint index_);
|
||||
|
||||
/* Padding for future expansion */
|
||||
void (*_gtk_reserved0) (void);
|
||||
@ -91,13 +91,13 @@ gint gtk_entry_completion_get_minimum_key_length (GtkEntryComplet
|
||||
void gtk_entry_completion_complete (GtkEntryCompletion *completion);
|
||||
|
||||
void gtk_entry_completion_insert_action_text (GtkEntryCompletion *completion,
|
||||
gint index,
|
||||
gint index_,
|
||||
const gchar *text);
|
||||
void gtk_entry_completion_insert_action_markup (GtkEntryCompletion *completion,
|
||||
gint index,
|
||||
gint index_,
|
||||
const gchar *markup);
|
||||
void gtk_entry_completion_delete_action (GtkEntryCompletion *completion,
|
||||
gint index);
|
||||
gint index_);
|
||||
|
||||
/* convenience */
|
||||
void gtk_entry_completion_set_text_column (GtkEntryCompletion *completion,
|
||||
|
@ -2013,11 +2013,12 @@ logical_to_physical (GtkToolbar *toolbar,
|
||||
* gtk_toolbar_set_drop_highlight_item:
|
||||
* @toolbar: a #GtkToolbar
|
||||
* @tool_item: a #GtkToolItem, or %NULL to turn of highlighting
|
||||
* @index: a position on @toolbar
|
||||
* @index_: a position on @toolbar
|
||||
*
|
||||
* Highlights @toolbar to give an idea of what it would look like
|
||||
* if @item was added to @toolbar at position indicated by @index. If @item
|
||||
* is %NULL, highlighting is turned off. In that case @index is ignored.
|
||||
* if @item was added to @toolbar at the position indicated by @index_.
|
||||
* If @item is %NULL, highlighting is turned off. In that case @index_
|
||||
* is ignored.
|
||||
*
|
||||
* The @tool_item passed to this function must not be part of any widget
|
||||
* hierarchy. When an item is set as drop highlight item it can not
|
||||
@ -2029,7 +2030,7 @@ logical_to_physical (GtkToolbar *toolbar,
|
||||
void
|
||||
gtk_toolbar_set_drop_highlight_item (GtkToolbar *toolbar,
|
||||
GtkToolItem *tool_item,
|
||||
gint index)
|
||||
gint index_)
|
||||
{
|
||||
ToolbarContent *content;
|
||||
GtkToolbarPrivate *priv;
|
||||
@ -2060,8 +2061,8 @@ gtk_toolbar_set_drop_highlight_item (GtkToolbar *toolbar,
|
||||
}
|
||||
|
||||
n_items = gtk_toolbar_get_n_items (toolbar);
|
||||
if (index < 0 || index > n_items)
|
||||
index = n_items;
|
||||
if (index_ < 0 || index_ > n_items)
|
||||
index_ = n_items;
|
||||
|
||||
if (tool_item != priv->highlight_tool_item)
|
||||
{
|
||||
@ -2077,15 +2078,15 @@ gtk_toolbar_set_drop_highlight_item (GtkToolbar *toolbar,
|
||||
GTK_WIDGET (toolbar));
|
||||
}
|
||||
|
||||
index = logical_to_physical (toolbar, index);
|
||||
index_ = logical_to_physical (toolbar, index_);
|
||||
|
||||
content = g_list_nth_data (priv->content, index);
|
||||
content = g_list_nth_data (priv->content, index_);
|
||||
|
||||
if (index > 0)
|
||||
if (index_ > 0)
|
||||
{
|
||||
ToolbarContent *prev_content;
|
||||
|
||||
prev_content = g_list_nth_data (priv->content, index - 1);
|
||||
prev_content = g_list_nth_data (priv->content, index_ - 1);
|
||||
|
||||
if (prev_content && toolbar_content_is_placeholder (prev_content))
|
||||
content = prev_content;
|
||||
@ -2099,7 +2100,7 @@ gtk_toolbar_set_drop_highlight_item (GtkToolbar *toolbar,
|
||||
|
||||
content = toolbar_content_new_tool_item (toolbar,
|
||||
GTK_TOOL_ITEM (placeholder),
|
||||
TRUE, index);
|
||||
TRUE, index_);
|
||||
gtk_widget_show (placeholder);
|
||||
}
|
||||
|
||||
|
@ -162,7 +162,7 @@ gint gtk_toolbar_get_drop_index (GtkToolbar *toolbar,
|
||||
gint y);
|
||||
void gtk_toolbar_set_drop_highlight_item (GtkToolbar *toolbar,
|
||||
GtkToolItem *tool_item,
|
||||
gint index);
|
||||
gint index_);
|
||||
|
||||
/* internal functions */
|
||||
gchar * _gtk_toolbar_elide_underscores (const gchar *original);
|
||||
|
Loading…
Reference in New Issue
Block a user