Use init and clear for GMutex and GCond
[projects/chimara/chimara.git] / libchimara / input.c
index 3a4babf2dedf24e5f63f1e7254bb3bf5b57a9c3b..c54fe8bf68f4ba1802687d5c3fc0c6a0aedc3f1f 100644 (file)
@@ -143,10 +143,7 @@ text_grid_request_line_event_common(winid_t win, glui32 maxlen, gboolean insert,
        gtk_entry_set_has_frame(GTK_ENTRY(win->input_entry), FALSE);
        GtkBorder border = { 0, 0, 0, 0 };
 
-       /* COMPAT: */
-#if GTK_CHECK_VERSION(2,10,0)
        gtk_entry_set_inner_border(GTK_ENTRY(win->input_entry), &border);
-#endif
     gtk_entry_set_max_length(GTK_ENTRY(win->input_entry), win->input_length);
     gtk_entry_set_width_chars(GTK_ENTRY(win->input_entry), win->input_length);
 
@@ -444,10 +441,10 @@ on_shutdown_key_press_event(GtkWidget *widget, GdkEventKey *event, winid_t win)
                g_node_traverse(priv->root_window, G_IN_ORDER, G_TRAVERSE_LEAVES, -1, (GNodeTraverseFunc)turn_off_handler, NULL);
        
        /* Signal the Glk library that it can shut everything down now */
-       g_mutex_lock(priv->shutdown_lock);
-       g_cond_signal(priv->shutdown_key_pressed);
-       g_mutex_unlock(priv->shutdown_lock);
-       
+       g_mutex_lock(&priv->shutdown_lock);
+       g_cond_signal(&priv->shutdown_key_pressed);
+       g_mutex_unlock(&priv->shutdown_lock);
+
        return TRUE; /* block the event */
 }