X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;f=gtk%2Fsrc%2Fcallbacks.c;h=d69992fae1058395630dc108de47ef95304f4fe3;hb=2cea0d49ba2d6aa6ba96d575b47d2d313515be11;hp=0eeae277d0f05d74ada1cf5fd643195c38a43127;hpb=d392fbab97c1eb7317132896bacdba0b2dfa007b;p=handbrake-jp%2Fhandbrake-jp-git.git diff --git a/gtk/src/callbacks.c b/gtk/src/callbacks.c index 0eeae277..d69992fa 100644 --- a/gtk/src/callbacks.c +++ b/gtk/src/callbacks.c @@ -1368,7 +1368,7 @@ submit_job(GValue *settings) { static gint unique_id = 1; gchar *type, *modified, *preset; - GValue *path; + const GValue *path; gboolean preset_modified; g_debug("submit_job"); @@ -1915,7 +1915,7 @@ ghb_log_cb(GIOChannel *source, GIOCondition cond, gpointer data) buffer = gtk_text_view_get_buffer (textview); // I would like to auto-scroll the window when the scrollbar // is at the bottom, - // must determining whether the insert point is at + // must determine whether the insert point is at // the bottom of the window window = gtk_text_view_get_window(textview, GTK_TEXT_WINDOW_TEXT); if (window != NULL) @@ -1938,15 +1938,20 @@ ghb_log_cb(GIOChannel *source, GIOCondition cond, gpointer data) gtk_text_buffer_insert(buffer, &iter, text, -1); if (bottom) { - //gtk_text_view_scroll_to_iter(textview, &iter, 0, FALSE, 0, 0); - mark = gtk_text_buffer_get_insert (buffer); + gtk_text_buffer_get_end_iter(buffer, &iter); + mark = gtk_text_buffer_create_mark(buffer, NULL, &iter, FALSE); gtk_text_view_scroll_mark_onscreen(textview, mark); + gtk_text_buffer_delete_mark(buffer, mark); } g_io_channel_write_chars (ud->activity_log, text, length, &length, NULL); + g_io_channel_flush(ud->activity_log, NULL); if (ud->job_activity_log) + { g_io_channel_write_chars (ud->job_activity_log, text, length, &length, NULL); + g_io_channel_flush(ud->job_activity_log, NULL); + } g_free(text); } if (status != G_IO_STATUS_NORMAL) @@ -2179,7 +2184,7 @@ chapter_edited_cb( -1); gtk_tree_model_get(GTK_TREE_MODEL(store), &iter, 0, &index, -1); - GValue *chapters; + const GValue *chapters; GValue *chapter; chapters = ghb_settings_get_value(ud->settings, "chapter_list");