[pve-devel] r6195 - in pve-manager/pve2/www/manager: . dc node tree

svn-commits at proxmox.com svn-commits at proxmox.com
Wed Jun 29 07:16:52 CEST 2011


Author: dietmar
Date: 2011-06-29 07:16:52 +0200 (Wed, 29 Jun 2011)
New Revision: 6195

Modified:
   pve-manager/pve2/www/manager/Makefile.am
   pve-manager/pve2/www/manager/dc/Tasks.js
   pve-manager/pve2/www/manager/dc/UserView.js
   pve-manager/pve2/www/manager/node/NetworkView.js
   pve-manager/pve2/www/manager/node/ServiceView.js
   pve-manager/pve2/www/manager/node/Tasks.js
   pve-manager/pve2/www/manager/tree/ResourceTree.js
Log:
use getSelection() instead of getLastSelected()


Modified: pve-manager/pve2/www/manager/Makefile.am
===================================================================
--- pve-manager/pve2/www/manager/Makefile.am	2011-06-29 04:37:40 UTC (rev 6194)
+++ pve-manager/pve2/www/manager/Makefile.am	2011-06-29 05:16:52 UTC (rev 6195)
@@ -89,6 +89,7 @@
 	chown -R www-data:www-data ${DESTDIR}/${pvelibdir}
 
 clean-local:
-	-rm -rf *~ store/*~ pvemanagerlib.js
+	find . -name '*~' -exec rm {} ';'	
+	-rm -rf pvemanagerlib.js
 
 

Modified: pve-manager/pve2/www/manager/dc/Tasks.js
===================================================================
--- pve-manager/pve2/www/manager/dc/Tasks.js	2011-06-29 04:37:40 UTC (rev 6194)
+++ pve-manager/pve2/www/manager/dc/Tasks.js	2011-06-29 05:16:52 UTC (rev 6195)
@@ -28,7 +28,7 @@
 
 	var run_task_viewer = function() {
 	    var sm = me.getSelectionModel();
-	    var rec = sm.getLastSelected();
+	    var rec = sm.getSelection()[0];
 	    if (!rec)
 		return;
 

Modified: pve-manager/pve2/www/manager/dc/UserView.js
===================================================================
--- pve-manager/pve2/www/manager/dc/UserView.js	2011-06-29 04:37:40 UTC (rev 6194)
+++ pve-manager/pve2/www/manager/dc/UserView.js	2011-06-29 05:16:52 UTC (rev 6195)
@@ -25,7 +25,7 @@
 		text: 'Delete',
 		handler: function() {
 		    var sm = me.getSelectionModel();
-		    var rec = sm.getLastSelected();
+		    var rec = sm.getSelection()[0];
 		    if (!rec)
 			return;
 

Modified: pve-manager/pve2/www/manager/node/NetworkView.js
===================================================================
--- pve-manager/pve2/www/manager/node/NetworkView.js	2011-06-29 04:37:40 UTC (rev 6194)
+++ pve-manager/pve2/www/manager/node/NetworkView.js	2011-06-29 05:16:52 UTC (rev 6195)
@@ -53,7 +53,7 @@
 	var run_editor = function() {
 	    var grid = me.down('gridpanel');
 	    var sm = grid.getSelectionModel();
-	    var rec = sm.getLastSelected();
+	    var rec = sm.getSelection()[0];
 	    if (!rec)
 		return;
 
@@ -78,7 +78,7 @@
 	    handler: function(){
 		var grid = me.down('gridpanel');
 		var sm = grid.getSelectionModel();
-		var rec = sm.getLastSelected();
+		var rec = sm.getSelection()[0];
 		if (!rec)
 		    return;
 
@@ -102,7 +102,7 @@
 	var set_button_status = function() {
 	    var grid = me.down('gridpanel');
 	    var sm = grid.getSelectionModel();
-	    var rec = sm.getLastSelected();
+	    var rec = sm.getSelection()[0];
 
 	    edit_btn.setDisabled(!rec);
 	    del_btn.setDisabled(!rec);

Modified: pve-manager/pve2/www/manager/node/ServiceView.js
===================================================================
--- pve-manager/pve2/www/manager/node/ServiceView.js	2011-06-29 04:37:40 UTC (rev 6194)
+++ pve-manager/pve2/www/manager/node/ServiceView.js	2011-06-29 05:16:52 UTC (rev 6195)
@@ -24,7 +24,7 @@
 
 	var service_cmd = function(cmd) {
 	    var sm = me.getSelectionModel();
-	    var rec = sm.getLastSelected();
+	    var rec = sm.getSelection()[0];
 	    PVE.Utils.API2Request({
 		url: "/nodes/" + nodename + "/services/" + rec.data.service,
 		params: { command: cmd },
@@ -65,7 +65,7 @@
 
 	var set_button_status = function() {
 	    var sm = me.getSelectionModel();
-	    var rec = sm.getLastSelected();
+	    var rec = sm.getSelection()[0];
 
 	    if (!rec) {
 		start_btn.disable();

Modified: pve-manager/pve2/www/manager/node/Tasks.js
===================================================================
--- pve-manager/pve2/www/manager/node/Tasks.js	2011-06-29 04:37:40 UTC (rev 6194)
+++ pve-manager/pve2/www/manager/node/Tasks.js	2011-06-29 05:16:52 UTC (rev 6195)
@@ -42,7 +42,7 @@
 
 	var run_task_viewer = function() {
 	    var sm = me.getSelectionModel();
-	    var rec = sm.getLastSelected();
+	    var rec = sm.getSelection()[0];
 	    if (!rec)
 		return;
 

Modified: pve-manager/pve2/www/manager/tree/ResourceTree.js
===================================================================
--- pve-manager/pve2/www/manager/tree/ResourceTree.js	2011-06-29 04:37:40 UTC (rev 6194)
+++ pve-manager/pve2/www/manager/tree/ResourceTree.js	2011-06-29 05:16:52 UTC (rev 6195)
@@ -184,7 +184,8 @@
 	    
 	    // remember selected node (and all parents)
 	    var sm = me.getSelectionModel();
-	    var lastsel = sm.getLastSelected();
+
+	    var lastsel = sm.getSelection()[0];
 	    var parents = [];
 	    var p = lastsel;
 	    while(p && (p = p.parentNode))




More information about the pve-devel mailing list