diff options
author | Miroslav Šulc <fordfrog@gentoo.org> | 2009-06-19 19:33:22 +0000 |
---|---|---|
committer | Miroslav Šulc <fordfrog@gentoo.org> | 2009-06-19 19:33:22 +0000 |
commit | 322ea9de8ab01300cb1c37d0a1bdc2676d957ffe (patch) | |
tree | 9d99108d0cd196dad26acbee3d1e271f6b71c291 /dev-util/netbeans/files | |
parent | Require pyinotify >=0.7.1 (thanks to a.peyser). (diff) | |
download | gentoo-2-322ea9de8ab01300cb1c37d0a1bdc2676d957ffe.tar.gz gentoo-2-322ea9de8ab01300cb1c37d0a1bdc2676d957ffe.tar.bz2 gentoo-2-322ea9de8ab01300cb1c37d0a1bdc2676d957ffe.zip |
File removed but for some reason not committed as removed
Diffstat (limited to 'dev-util/netbeans/files')
-rw-r--r-- | dev-util/netbeans/files/6.7/autoupdate.ui.fix.patch | 112 |
1 files changed, 0 insertions, 112 deletions
diff --git a/dev-util/netbeans/files/6.7/autoupdate.ui.fix.patch b/dev-util/netbeans/files/6.7/autoupdate.ui.fix.patch deleted file mode 100644 index ac610be1f34c..000000000000 --- a/dev-util/netbeans/files/6.7/autoupdate.ui.fix.patch +++ /dev/null @@ -1,112 +0,0 @@ -diff -r 5fb0d903fe36 autoupdate.ui/src/org/netbeans/modules/autoupdate/ui/Unit.java ---- a/autoupdate.ui/src/org/netbeans/modules/autoupdate/ui/Unit.java Mon Jun 08 19:00:44 2009 +0200 -+++ b/autoupdate.ui/src/org/netbeans/modules/autoupdate/ui/Unit.java Tue Jun 09 10:43:27 2009 +0200 -@@ -262,7 +262,7 @@ - - private UpdateElement installEl = null; - private UpdateElement backupEl = null; -- private boolean isUninstallAllowed ; -+ private Boolean alternateMarked; - - public static boolean isOperationAllowed (UpdateUnit uUnit, UpdateElement element, OperationContainer<OperationSupport> container) { - return container.canBeAdded (uUnit, element); -@@ -285,11 +285,23 @@ - } else { - container = Containers.forUninstall (); - } -- this.isUninstallAllowed = isOperationAllowed (this.updateUnit, installEl, container); -+ if (isOperationAllowed (this.updateUnit, installEl, container)) { -+ alternateMarked = null; -+ } else { -+ alternateMarked = false; -+ } - initState(); -+ } -+ -+ public boolean isUninstallAllowed() { -+ return alternateMarked == null; - } - - public boolean isMarked () { -+ if (alternateMarked != null) { -+ return alternateMarked; -+ } -+ - OperationContainer container = null; - if (UpdateManager.TYPE.CUSTOM_HANDLED_COMPONENT == updateUnit.getType ()) { - container = Containers.forCustomUninstall (); -@@ -301,16 +313,20 @@ - - public void setMarked (boolean marked) { - assert marked != isMarked (); -- OperationContainer container = null; -- if (UpdateManager.TYPE.CUSTOM_HANDLED_COMPONENT == updateUnit.getType ()) { -- container = Containers.forCustomUninstall (); -+ if (isUninstallAllowed()) { -+ OperationContainer container = null; -+ if (UpdateManager.TYPE.CUSTOM_HANDLED_COMPONENT == updateUnit.getType ()) { -+ container = Containers.forCustomUninstall (); -+ } else { -+ container = Containers.forUninstall (); -+ } -+ if (marked) { -+ container.add (updateUnit, installEl); -+ } else { -+ container.remove (installEl); -+ } - } else { -- container = Containers.forUninstall (); -- } -- if (marked) { -- container.add (updateUnit, installEl); -- } else { -- container.remove (installEl); -+ alternateMarked = marked; - } - } - -@@ -340,15 +356,6 @@ - return new SpecificationVersion (unit1.getInstalledVersion ()).compareTo (new SpecificationVersion (unit2.getInstalledVersion ())); - } - return Unit.compareDisplayVersions (u1, u2); -- } -- -- @Override -- public boolean canBeMarked () { -- if (super.canBeMarked ()) { -- return isUninstallAllowed ; -- } else { -- return false; -- } - } - - public String getInstalledVersion () { -diff -r 5fb0d903fe36 autoupdate.ui/src/org/netbeans/modules/autoupdate/ui/UnitTab.java ---- a/autoupdate.ui/src/org/netbeans/modules/autoupdate/ui/UnitTab.java Mon Jun 08 19:00:44 2009 +0200 -+++ b/autoupdate.ui/src/org/netbeans/modules/autoupdate/ui/UnitTab.java Tue Jun 09 10:43:27 2009 +0200 -@@ -1178,6 +1178,25 @@ - focusTable (); - } - } -+ -+ @Override -+ public void tableDataChanged (Collection<Unit> units) { -+ if (units.size() == 0) { -+ setEnabled(false); -+ return; -+ } -+ for (Unit u : units) { -+ if (u instanceof Unit.Installed) { -+ Unit.Installed inst = (Unit.Installed)u; -+ if (!inst.isUninstallAllowed()) { -+ setEnabled(false); -+ return; -+ } -+ } -+ } -+ setEnabled (true); -+ } -+ - } - - private class UpdateAction extends TabAction { |