diff options
Diffstat (limited to 'src/gui')
| -rw-r--r-- | src/gui/menus/view.c | 14 | ||||
| -rw-r--r-- | src/gui/status.c | 7 | 
2 files changed, 13 insertions, 8 deletions
diff --git a/src/gui/menus/view.c b/src/gui/menus/view.c index 0bcc2fe..511d9db 100644 --- a/src/gui/menus/view.c +++ b/src/gui/menus/view.c @@ -192,8 +192,20 @@ static void mcb_view_change_support(GtkRadioMenuItem *menuitem, GMenuBar *bar)          view = GPOINTER_TO_UINT(g_object_get_data(G_OBJECT(iter->data), "kind_of_view")); +        /** +         * La hiérarchie des composants empilés est la suivante : +         * +         *  - GtkBlockView / GtkGraphView / GtkSourceView +         *  - GtkViewport +         *  - GtkScrolledWindow +         *  - GtkNotebook +         *  - GtkDockStation +         * +         */ +          vpanel = g_editor_item_get_current_view(G_EDITOR_ITEM(bar)); -        station = gtk_widget_get_parent(GTK_WIDGET(vpanel));    /* ScrollWindow */ +        station = gtk_widget_get_parent(GTK_WIDGET(vpanel));    /* GtkViewport */ +        station = gtk_widget_get_parent(GTK_WIDGET(station));   /* ScrollWindow */          station = gtk_widget_get_parent(station);   /* NoteBook */          station = gtk_widget_get_parent(station);   /* DockStation */ diff --git a/src/gui/status.c b/src/gui/status.c index 50424de..c059f4e 100644 --- a/src/gui/status.c +++ b/src/gui/status.c @@ -169,10 +169,6 @@ GEditorItem *g_status_info_new(GObject *ref)  static void update_status_info_for_view(GStatusInfo *info, GtkViewPanel *view)  { -    printf("new view :: %p\n", view); - -    //track_caret_address_on_buffer_views -      if (info->caret_instance != NULL)      {          g_signal_handlers_disconnect_by_func(info->caret_instance, @@ -186,9 +182,6 @@ static void update_status_info_for_view(GStatusInfo *info, GtkViewPanel *view)                           G_CALLBACK(track_caret_address_on_buffer_views),                           info); -    else -        return; -      info->caret_instance = G_OBJECT(view);      g_object_ref(info->caret_instance);  | 
