Tal Nisan has uploaded a new change for review.

Change subject: webadmin: Removed redundant ui command from DataCenterListModel
......................................................................

webadmin: Removed redundant ui command from DataCenterListModel

Removed the "Activate" command from DataCenterListModel as it's not used
anymore and does nothing even if it was exposed in the ui

Change-Id: I07fb537086a186c4c203a246123086d128e09a23
Signed-off-by: Tal Nisan <tni...@redhat.com>
---
M 
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/datacenters/DataCenterListModel.java
1 file changed, 0 insertions(+), 34 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/84/28384/1

diff --git 
a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/datacenters/DataCenterListModel.java
 
b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/datacenters/DataCenterListModel.java
index 74d8d61..f167d33 100644
--- 
a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/datacenters/DataCenterListModel.java
+++ 
b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/datacenters/DataCenterListModel.java
@@ -111,18 +111,6 @@
         privateForceRemoveCommand = value;
     }
 
-    private UICommand privateActivateCommand;
-
-    public UICommand getActivateCommand()
-    {
-        return privateActivateCommand;
-    }
-
-    private void setActivateCommand(UICommand value)
-    {
-        privateActivateCommand = value;
-    }
-
     private UICommand privateGuideCommand;
 
     public UICommand getGuideCommand()
@@ -195,7 +183,6 @@
         tempVar.setIsExecutionAllowed(true);
         setForceRemoveCommand(tempVar);
         setRecoveryStorageCommand(new UICommand("RecoveryStorage", this)); 
//$NON-NLS-1$
-        setActivateCommand(new UICommand("Activate", this)); //$NON-NLS-1$
         setGuideCommand(new UICommand("Guide", this)); //$NON-NLS-1$
 
         updateActionAvailability();
@@ -529,10 +516,6 @@
             }
         }),
                 ((StoragePool) getSelectedItem()).getId());
-    }
-
-    public void activate()
-    {
     }
 
     public void onRemove()
@@ -881,19 +864,6 @@
         getGuideCommand().setIsExecutionAllowed(getGuideContext() != null
                 || (getSelectedItem() != null && getSelectedItems() != null && 
getSelectedItems().size() == 1));
 
-        getActivateCommand().setIsExecutionAllowed(items.size() > 0);
-        if (getActivateCommand().getIsExecutionAllowed())
-        {
-            for (StoragePool a : items)
-            {
-                if (a.getStatus() == StoragePoolStatus.Up || a.getStatus() == 
StoragePoolStatus.Uninitialized)
-                {
-                    getActivateCommand().setIsExecutionAllowed(false);
-                    break;
-                }
-            }
-        }
-
         getRecoveryStorageCommand().setIsExecutionAllowed(storagePoolItem != 
null && items.size() == 1
                 && !storagePoolItem.isLocal() && storagePoolItem.getStatus() 
!= StoragePoolStatus.Uninitialized);
 
@@ -956,10 +926,6 @@
         else if (command == getForceRemoveCommand())
         {
             forceRemove();
-        }
-        else if (command == getActivateCommand())
-        {
-            activate();
         }
         else if (command == getGuideCommand())
         {


-- 
To view, visit http://gerrit.ovirt.org/28384
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I07fb537086a186c4c203a246123086d128e09a23
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Tal Nisan <tni...@redhat.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to