[rkward-cvs] SF.net SVN: rkward:[2600] trunk/rkward

tfry at users.sourceforge.net tfry at users.sourceforge.net
Wed Aug 5 20:01:27 UTC 2009


Revision: 2600
          http://rkward.svn.sourceforge.net/rkward/?rev=2600&view=rev
Author:   tfry
Date:     2009-08-05 20:01:26 +0000 (Wed, 05 Aug 2009)

Log Message:
-----------
Add load / unload packages action to workspace menu (with icon; same as settings->configure packages, internally)

Modified Paths:
--------------
    trunk/rkward/ChangeLog
    trunk/rkward/rkward/misc/rkstandardicons.cpp
    trunk/rkward/rkward/misc/rkstandardicons.h
    trunk/rkward/rkward/rkward.cpp
    trunk/rkward/rkward/rkward.h
    trunk/rkward/rkward/rkwardui.rc

Modified: trunk/rkward/ChangeLog
===================================================================
--- trunk/rkward/ChangeLog	2009-08-05 11:08:10 UTC (rev 2599)
+++ trunk/rkward/ChangeLog	2009-08-05 20:01:26 UTC (rev 2600)
@@ -1,3 +1,4 @@
+- Add shortcut to the load / unload packages dialog also in the workspace menu
 - Make toolbar buttons configurable
 - Fixed: Console window would sometimes remain in partially active state after piping commands
 

Modified: trunk/rkward/rkward/misc/rkstandardicons.cpp
===================================================================
--- trunk/rkward/rkward/misc/rkstandardicons.cpp	2009-08-05 11:08:10 UTC (rev 2599)
+++ trunk/rkward/rkward/misc/rkstandardicons.cpp	2009-08-05 20:01:26 UTC (rev 2600)
@@ -43,6 +43,8 @@
 	icons[ActionRunSelection] = QIcon (rkward_icon_base + "run_selection.png");
 	icons[ActionCDToScript] = KIcon ("folder-txt");
 
+	icons[ActionConfigurePackages] = KIcon ("utilities-file-archiver");
+
 	icons[ActionDeleteRow] = KIcon ("no");
 	icons[ActionInsertRow] = KIcon ("edit-add");
 	icons[ActionDeleteVar] = icons[ActionDeleteRow];
@@ -67,7 +69,7 @@
 	icons[ObjectList] = QIcon (rkward_icon_base + "list.png");
 	icons[ObjectFunction] = QIcon (rkward_icon_base + "function.png");
 	icons[ObjectEnvironment] = KIcon ("konqueror");
-	icons[ObjectPackageEnvironment] = KIcon ("utilities-file-archiver");
+	icons[ObjectPackageEnvironment] = icons[ActionConfigurePackages];
 	icons[ObjectMatrix] = QIcon (rkward_icon_base + "matrix.png");
 	icons[ObjectDataFrame] = KIcon ("x-office-spreadsheet");
 	icons[ObjectDataNumeric] = QIcon (rkward_icon_base + "data-numeric.png");

Modified: trunk/rkward/rkward/misc/rkstandardicons.h
===================================================================
--- trunk/rkward/rkward/misc/rkstandardicons.h	2009-08-05 11:08:10 UTC (rev 2599)
+++ trunk/rkward/rkward/misc/rkstandardicons.h	2009-08-05 20:01:26 UTC (rev 2600)
@@ -43,6 +43,8 @@
 		ActionRunSelection,
 		ActionCDToScript,
 
+		ActionConfigurePackages,
+
 		ActionDeleteRow,
 		ActionInsertRow,
 		ActionDeleteVar,

Modified: trunk/rkward/rkward/rkward.cpp
===================================================================
--- trunk/rkward/rkward/rkward.cpp	2009-08-05 11:08:10 UTC (rev 2599)
+++ trunk/rkward/rkward/rkward.cpp	2009-08-05 20:01:26 UTC (rev 2600)
@@ -310,7 +310,7 @@
 void RKWardMainWindow::initActions()
 {  
 	RK_TRACE (APP);
-	QAction *action;
+	KAction *action;
 
 	// TODO: is there a way to insert actions between standard actions without having to give all standard actions custom ids?
 	new_data_frame = actionCollection ()->addAction ("new_data_frame", this, SLOT (slotNewDataFrame ()));
@@ -351,9 +351,15 @@
 	fileQuit = actionCollection ()->addAction (KStandardAction::Quit, "file_quitx", this, SLOT(close()));
 	fileQuit->setStatusTip (i18n ("Quits the application"));
 
-	file_load_libs = actionCollection ()->addAction ("file_load_libs", this, SLOT (slotFileLoadLibs()));
-	file_load_libs->setText (i18n ("Configure Packages"));
+	// These two currently do the same thing
+	action = actionCollection ()->addAction ("load_unload_libs", this, SLOT (slotFileLoadLibs()));
+	action->setText (i18n ("Load / Unload Packages"));
+	action->setIcon (RKStandardIcons::getIcon (RKStandardIcons::ActionConfigurePackages));
 
+	action = actionCollection ()->addAction ("configure_packages", this, SLOT (slotFileLoadLibs()));
+	action->setText (i18n ("Configure Packages"));
+	action->setIcon (RKStandardIcons::getIcon (RKStandardIcons::ActionConfigurePackages));
+
 	setStandardToolBarMenuEnabled (true);
 	createStandardStatusBarAction ();
 

Modified: trunk/rkward/rkward/rkward.h
===================================================================
--- trunk/rkward/rkward/rkward.h	2009-08-05 11:08:10 UTC (rev 2599)
+++ trunk/rkward/rkward/rkward.h	2009-08-05 20:01:26 UTC (rev 2600)
@@ -164,7 +164,6 @@
 	KAction* fileSaveWorkspace;
 	KAction* fileSaveWorkspaceAs;
 	KAction* fileQuit;
-	KAction* file_load_libs;
 	KAction* close_all_editors;
 	KAction* new_data_frame;
 	KAction* new_command_editor;

Modified: trunk/rkward/rkward/rkwardui.rc
===================================================================
--- trunk/rkward/rkward/rkwardui.rc	2009-08-05 11:08:10 UTC (rev 2599)
+++ trunk/rkward/rkward/rkwardui.rc	2009-08-05 20:01:26 UTC (rev 2600)
@@ -1,5 +1,5 @@
 <!DOCTYPE kpartgui>
-<kpartgui name="rkward" version="0.5.1">
+<kpartgui name="rkward" version="52">
 <MenuBar>
 	<!-- The Main Window ui.rc is the only one, where merging happens, reliably. That is, why we need to define
 	     a lot of merge points, here, which can then be used be mdi windows and their children.
@@ -27,6 +27,8 @@
 		<Action name="file_open_recentx"/>
 		<Action name="file_savex"/>
 		<Action name="file_save_asx"/>
+		<Separator/>
+		<Action name="load_unload_libs"/>
 	</Menu>
 
 	<!-- These menus are actually defined in KParts. We also declare them here, to avoid menus jumping around -->
@@ -65,7 +67,7 @@
 	</Menu>
 	
 	<Menu name="settings"><text>&Settings</text>
-		<Action name="file_load_libs"/>
+		<Action name="configure_packages"/>
 		<Action name="configure"/>
 	</Menu>
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the rkward-tracker mailing list