fix broken handling of input from pipes in list dialog (Fixes bug
2007-05-27 Lucas Rocha <lucasr@gnome.org> * src/tree.c: fix broken handling of input from pipes in list dialog (Fixes bug #343684). svn path=/trunk/; revision=1221
This commit is contained in:
parent
5868adac75
commit
b2459f3b6e
@ -1,3 +1,8 @@
|
|||||||
|
2007-05-27 Lucas Rocha <lucasr@gnome.org>
|
||||||
|
|
||||||
|
* src/tree.c: fix broken handling of input from pipes in list
|
||||||
|
dialog (Fixes bug #343684).
|
||||||
|
|
||||||
2007-05-27 Lucas Rocha <lucasr@gnome.org>
|
2007-05-27 Lucas Rocha <lucasr@gnome.org>
|
||||||
|
|
||||||
* src/text.c: correctly handle UTF-8 input text in the text info
|
* src/text.c: correctly handle UTF-8 input text in the text info
|
||||||
|
10
src/tree.c
10
src/tree.c
@ -94,13 +94,13 @@ zenity_tree_handle_stdin (GIOChannel *channel,
|
|||||||
{
|
{
|
||||||
static GtkTreeView *tree_view;
|
static GtkTreeView *tree_view;
|
||||||
GtkTreeModel *model;
|
GtkTreeModel *model;
|
||||||
GtkTreeIter iter;
|
static GtkTreeIter iter;
|
||||||
static gint column_count = 0;
|
static gint column_count = 0;
|
||||||
static gint row_count = 0;
|
static gint row_count = 0;
|
||||||
static gint n_columns;
|
static gint n_columns;
|
||||||
static gboolean editable;
|
static gboolean editable;
|
||||||
static gboolean toggles;
|
static gboolean toggles;
|
||||||
static gboolean first_time = FALSE;
|
static gboolean first_time = TRUE;
|
||||||
|
|
||||||
tree_view = GTK_TREE_VIEW (data);
|
tree_view = GTK_TREE_VIEW (data);
|
||||||
n_columns = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (tree_view), "n_columns"));
|
n_columns = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (tree_view), "n_columns"));
|
||||||
@ -109,8 +109,8 @@ zenity_tree_handle_stdin (GIOChannel *channel,
|
|||||||
|
|
||||||
model = gtk_tree_view_get_model (tree_view);
|
model = gtk_tree_view_get_model (tree_view);
|
||||||
|
|
||||||
if (!first_time) {
|
if (first_time) {
|
||||||
first_time = TRUE;
|
first_time = FALSE;
|
||||||
gtk_list_store_append (GTK_LIST_STORE (model), &iter);
|
gtk_list_store_append (GTK_LIST_STORE (model), &iter);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -174,7 +174,7 @@ zenity_tree_handle_stdin (GIOChannel *channel,
|
|||||||
GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
|
GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
|
||||||
}
|
}
|
||||||
|
|
||||||
column_count ++;
|
column_count++;
|
||||||
|
|
||||||
} while (g_io_channel_get_buffer_condition (channel) == G_IO_IN);
|
} while (g_io_channel_get_buffer_condition (channel) == G_IO_IN);
|
||||||
g_string_free (string, TRUE);
|
g_string_free (string, TRUE);
|
||||||
|
Reference in New Issue
Block a user