[gedit] Forze to guess again the content type when setting the uri.



commit 61d704714da7d05bf65c43bc6ffcbd31b44afa9d
Author: Ignacio Casal Quinteiro <icq gnome org>
Date:   Mon Nov 23 13:31:18 2009 +0100

    Forze to guess again the content type when setting the uri.
    
    gedit_document_set_uri is used normally to rename a file so if the
    user changed the extension of the file we need to guess again the content type.

 gedit/gedit-document.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
---
diff --git a/gedit/gedit-document.c b/gedit/gedit-document.c
index 8507f97..ccbb1bd 100644
--- a/gedit/gedit-document.c
+++ b/gedit/gedit-document.c
@@ -896,6 +896,7 @@ gedit_document_set_uri (GeditDocument *doc,
 			const gchar   *uri)
 {
 	set_uri (doc, uri);
+	set_content_type (doc, NULL);
 }
 
 /* Never returns NULL */



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