Revision: 1853 http://geany.svn.sourceforge.net/geany/?rev=1853&view=rev Author: eht16 Date: 2007-09-05 11:38:42 -0700 (Wed, 05 Sep 2007)
Log Message: ----------- Fix missing syntax colouring when saving new files.
Modified Paths: -------------- trunk/ChangeLog trunk/src/document.c
Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2007-09-05 16:22:50 UTC (rev 1852) +++ trunk/ChangeLog 2007-09-05 18:38:42 UTC (rev 1853) @@ -1,3 +1,8 @@ +2007-09-05 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de> + + * src/document.c: Fix missing syntax colouring when saving new files. + + 2007-09-05 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
* src/utils.c, src/document.c:
Modified: trunk/src/document.c =================================================================== --- trunk/src/document.c 2007-09-05 16:22:50 UTC (rev 1852) +++ trunk/src/document.c 2007-09-05 18:38:42 UTC (rev 1853) @@ -1181,7 +1181,8 @@
if (FILETYPE_ID(doc_list[idx].file_type) == GEANY_FILETYPES_ALL) { - doc_list[idx].file_type = filetypes_detect_from_file(idx); + filetype *ft = filetypes_detect_from_file(idx); + document_set_filetype(idx, ft); if (document_get_cur_idx() == idx) { app->ignore_callback = TRUE; @@ -1189,7 +1190,9 @@ app->ignore_callback = FALSE; } } - document_set_filetype(idx, doc_list[idx].file_type); + else + document_set_filetype(idx, doc_list[idx].file_type); + tm_workspace_update(TM_WORK_OBJECT(app->tm_workspace), TRUE, TRUE, FALSE); gtk_label_set_text(GTK_LABEL(doc_list[idx].tab_label), base_name); gtk_label_set_text(GTK_LABEL(doc_list[idx].tabmenu_label), base_name);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.