Fixed bug in text grid line input that obscured a new bug in the multisession code...
authorPhilip Chimento <philip.chimento@gmail.com>
Sun, 13 Sep 2009 18:44:57 +0000 (18:44 +0000)
committerPhilip Chimento <philip.chimento@gmail.com>
Sun, 13 Sep 2009 18:44:57 +0000 (18:44 +0000)
git-svn-id: http://lassie.dyndns-server.com/svn/gargoyle-gtk@123 ddfedd41-794f-dd11-ae45-00112f111e67

libchimara/input.c
tests/main.c

index ab1eef52de587023d18f79cd14ec81fa5abcfb06..8ab3f41fce4a03a8bdaad1137e93f334fd18a389 100644 (file)
@@ -493,7 +493,7 @@ static int
 flush_text_grid(winid_t win)
 {
        VALID_WINDOW(win, return 0);
-       g_return_val_if_fail(win->type == wintype_TextBuffer, 0);
+       g_return_val_if_fail(win->type == wintype_TextGrid, 0);
 
        GtkTextBuffer *buffer = gtk_text_view_get_buffer( GTK_TEXT_VIEW(win->widget) );
        
@@ -554,6 +554,6 @@ on_input_entry_activate(GtkEntry *input_entry, winid_t win)
        g_signal_handler_block( G_OBJECT(win->widget), win->keypress_handler );
 
        int chars_written = flush_text_grid(win);
-       event_throw(CHIMARA_GLK(gtk_widget_get_ancestor(GTK_WIDGET(input_entry), CHIMARA_TYPE_GLK)), evtype_LineInput, win, chars_written, 0);
+       event_throw(CHIMARA_GLK(gtk_widget_get_ancestor(win->widget, CHIMARA_TYPE_GLK)), evtype_LineInput, win, chars_written, 0);
 }
 
index 94755c8a6c2b0c33fbc74b270caa4cccd5e6a56c..5fbd624ab529c65e8f2a227f27e9a165585fb7e7 100644 (file)
@@ -154,7 +154,7 @@ main(int argc, char *argv[])
        g_object_unref( G_OBJECT(builder) );
        g_object_unref( G_OBJECT(uimanager) );
 
-    if( !chimara_glk_run(CHIMARA_GLK(glk), "../interpreters/frotz/.libs/frotz.so", argc, argv, &error) ) {
+    if( !chimara_glk_run(CHIMARA_GLK(glk), ".libs/gridtest.so"/*"../interpreters/frotz/.libs/frotz.so"*/, argc, argv, &error) ) {
                error_dialog(GTK_WINDOW(window), error, "Error starting Glk library: ");
                return 1;
        }