[bijiben/popover] EdidtorToolbar: hide when needed



commit 253e114a617b8b29d2395acf694c5073f93b6e86
Author: Pierre-Yves Luyten <py luyten fr>
Date:   Fri Mar 28 22:23:51 2014 +0100

    EdidtorToolbar: hide when needed
    
    Popover is now longer modal. Hide it whenever needed.

 src/bjb-editor-toolbar.c |   15 ++++++++-------
 1 files changed, 8 insertions(+), 7 deletions(-)
---
diff --git a/src/bjb-editor-toolbar.c b/src/bjb-editor-toolbar.c
index c2e824b..02c9800 100644
--- a/src/bjb-editor-toolbar.c
+++ b/src/bjb-editor-toolbar.c
@@ -84,10 +84,11 @@ bjb_editor_toolbar_fade_in (BjbEditorToolbar *self)
 }
 
 
-/* This is not needed as long as we keep popover modal */
+
 static void
 bjb_editor_toolbar_fade_out (BjbEditorToolbar *self)
 {
+  gtk_widget_hide (self->priv->widget);
 }
 
 
@@ -453,21 +454,21 @@ bjb_editor_toolbar_constructed (GObject *obj)
 
   g_signal_connect (priv->toolbar_bold,"clicked",
                     G_CALLBACK(bold_button_callback), self);
-  gtk_widget_add_accelerator (priv->toolbar_bold,
+/*  gtk_widget_add_accelerator (priv->toolbar_bold,
                               "activate", priv->accel, GDK_KEY_b,
-                              GDK_CONTROL_MASK, GTK_ACCEL_VISIBLE);
+                              GDK_CONTROL_MASK, GTK_ACCEL_VISIBLE);*/
 
   g_signal_connect (priv->toolbar_italic,"clicked",
                     G_CALLBACK(italic_button_callback), self);
-  gtk_widget_add_accelerator (priv->toolbar_italic,
+/*  gtk_widget_add_accelerator (priv->toolbar_italic,
                               "activate", priv->accel, GDK_KEY_i,
-                              GDK_CONTROL_MASK, GTK_ACCEL_VISIBLE);
+                              GDK_CONTROL_MASK, GTK_ACCEL_VISIBLE);*/
 
   g_signal_connect (priv->toolbar_strike,"clicked",
                     G_CALLBACK(strike_button_callback), self);
-  gtk_widget_add_accelerator (priv->toolbar_strike,
+/*  gtk_widget_add_accelerator (priv->toolbar_strike,
                               "activate", priv->accel, GDK_KEY_s,
-                              GDK_CONTROL_MASK, GTK_ACCEL_VISIBLE);
+                              GDK_CONTROL_MASK, GTK_ACCEL_VISIBLE);*/
 
   g_signal_connect (priv->toolbar_link,"clicked",
                     G_CALLBACK(link_callback), self);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]