[Title]INST : remove extension package list in tree.
authorshihyun.kim <shihyun.kim@samsung.com>
Fri, 18 Jan 2013 04:20:51 +0000 (13:20 +0900)
committershihyun.kim <shihyun.kim@samsung.com>
Fri, 18 Jan 2013 04:20:51 +0000 (13:20 +0900)
[Desc.]* If you delete extension repository in 'Extra Repository' dialog.** remove installed packages and remove package name in tree.
[Issue]

Change-Id: Ie190f169e911c3e3073f99048f56083cafba4242

InstallManager_java/src/org/tizen/installmanager/core/SDKExtensionInfo.java
InstallManager_java/src/org/tizen/installmanager/pkg/lib/PackageManager.java

index 9ca1014..856cae6 100644 (file)
@@ -133,8 +133,10 @@ public class SDKExtensionInfo {
        private void uninstallExtraPackages(String repo) {
                boolean result = false;
 
-               PackageSet pkgs = PackageManager.getInstance().getExtensionPackages();
+               //Get installed extension packages.
+               PackageSet pkgs = PackageManager.getInstance().getInstalledExtensionPackages();
                
+               //Compare with the installed repository.
                List<String> installedExtraList = new ArrayList<String>();
                for (Package pkg : pkgs) {
                        if (pkg.getExtensionServer().equalsIgnoreCase(repo)) {
index 17887dd..8386e2d 100644 (file)
@@ -195,8 +195,8 @@ public abstract class PackageManager {
                                getRepositoryAndPackageList(SDKExtensionInfo.getInstance().getExtensionRepositories().keySet(),
                                                Style.EXTRA);
                
-               if (repoToSectionsMap != null && !repoToSectionsMap.isEmpty()) {
-                       
+               //Update extension packages.
+               if (repoToSectionsMap != null) {
                        setExtensionPackages(repoToSectionsMap);
                        setExtensionPackagesToRecentPackages();
                } else {