[gedit] modelines: actually apply the modeline when we activate the view extension.



commit 2c0e104ce090148d362dff0fbac23b471ecc4536
Author: Ignacio Casal Quinteiro <icq gnome org>
Date:   Thu Sep 8 21:20:54 2011 +0200

    modelines: actually apply the modeline when we activate the view extension.
    
    File may be already loaded or saved when we activate the extension.

 plugins/modelines/gedit-modeline-plugin.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/plugins/modelines/gedit-modeline-plugin.c b/plugins/modelines/gedit-modeline-plugin.c
index 82936c0..3d55701 100644
--- a/plugins/modelines/gedit-modeline-plugin.c
+++ b/plugins/modelines/gedit-modeline-plugin.c
@@ -164,6 +164,8 @@ gedit_modeline_plugin_activate (GeditViewActivatable *activatable)
 
 	plugin = GEDIT_MODELINE_PLUGIN (activatable);
 
+	modeline_parser_apply_modeline (GTK_SOURCE_VIEW (plugin->priv->view));
+
 	doc = gtk_text_view_get_buffer (GTK_TEXT_VIEW (plugin->priv->view));
 
 	plugin->priv->document_loaded_handler_id =



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