anjuta r4092 - in trunk: . plugins/build-basic-autotools



Author: sgranjoux
Date: Sun Jul 20 19:36:09 2008
New Revision: 4092
URL: http://svn.gnome.org/viewvc/anjuta?rev=4092&view=rev

Log:
	* plugins/build-basic-autotools/build-basic-autotools.c:
	Fix #522825: Opening files from shell disable build->compile menu


Modified:
   trunk/ChangeLog
   trunk/plugins/build-basic-autotools/build-basic-autotools.c

Modified: trunk/plugins/build-basic-autotools/build-basic-autotools.c
==============================================================================
--- trunk/plugins/build-basic-autotools/build-basic-autotools.c	(original)
+++ trunk/plugins/build-basic-autotools/build-basic-autotools.c	Sun Jul 20 19:36:09 2008
@@ -2242,13 +2242,15 @@
 	gchar *filename= NULL;
 	gchar *module = NULL;
 	gchar *label;
+	gboolean has_file = FALSE;
 	gboolean has_makefile= FALSE;
 
 	ui = anjuta_shell_get_ui (ANJUTA_PLUGIN (bb_plugin)->shell, NULL);
 	
 	DEBUG_PRINT ("Updating module UI");
-	
-	if (bb_plugin->current_editor_filename != NULL)
+
+	has_file = bb_plugin->current_editor_filename != NULL;
+	if (has_file)
 	{
 		gchar *dirname;
 		gchar *build_dirname;
@@ -2288,7 +2290,7 @@
 	action = anjuta_ui_get_action (ui, "ActionGroupBuild",
 								   "ActionBuildCompileFile");
 	label = g_strdup_printf (filename ? _("Co_mpile (%s)") : _("Co_mpile"), filename);
-	g_object_set (G_OBJECT (action), "sensitive", has_makefile,
+	g_object_set (G_OBJECT (action), "sensitive", has_file,
 					  "label", label, NULL);
 	g_free (label);
 	



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