Author: lslezak
Date: Mon Jun 13 15:56:20 2011
New Revision: 64325
URL: http://svn.opensuse.org/viewcvs/yast?rev=64325&view=rev
Log:
properly count to be downloaded packages (bnc#683977)
Modified:
branches/tmp/lslezak/SP2/packager/package/yast2-packager.changes
branches/tmp/lslezak/SP2/packager/src/modules/PackageSlideShow.ycp
Modified: branches/tmp/lslezak/SP2/packager/package/yast2-packager.changes
URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/lslezak/SP2/packager/package/yast2-packager.changes?rev=64325&r1=64324&r2=64325&view=diff
==============================================================================
--- branches/tmp/lslezak/SP2/packager/package/yast2-packager.changes (original)
+++ branches/tmp/lslezak/SP2/packager/package/yast2-packager.changes Mon Jun 13 15:56:20 2011
@@ -1,4 +1,9 @@
-------------------------------------------------------------------
+Mon Jun 13 13:28:56 UTC 2011 - lslezak@suse.cz
+
+- properly count to be downloaded packages (bnc#683977)
+
+-------------------------------------------------------------------
Thu Jun 9 12:05:27 UTC 2011 - lslezak@suse.cz
- correctly display download progress in DownloadInAdvance
Modified: branches/tmp/lslezak/SP2/packager/src/modules/PackageSlideShow.ycp
URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/lslezak/SP2/packager/src/modules/PackageSlideShow.ycp?rev=64325&r1=64324&r2=64325&view=diff
==============================================================================
--- branches/tmp/lslezak/SP2/packager/src/modules/PackageSlideShow.ycp (original)
+++ branches/tmp/lslezak/SP2/packager/src/modules/PackageSlideShow.ycp Mon Jun 13 15:56:20 2011
@@ -390,6 +390,10 @@
integer packages_to_download(listsrc_mapping)
{
+ // src_mapping contains only enabled repos, get indices of the enabled repos here
+ // and remap enabled index to the global repo ID
+ list<integer> enabled_sources = Pkg::SourceGetCurrent(true);
+
y2milestone("Packages to download input: %1", src_mapping);
integer ret = 0;
@@ -400,7 +404,7 @@
if (size(media_mapping) > 0)
{
// check if the repository is remote
- string repo_url = Pkg::SourceGeneralData(i)["url"]:"";
+ string repo_url = Pkg::SourceGeneralData(enabled_sources[i]:-1)["url"]:"";
string repo_schema = tolower(URL::Parse(repo_url)["scheme"]:"");
if (contains(["http", "https", "ftp", "sftp"], repo_schema))
@@ -412,7 +416,7 @@
}
);
- y2milestone("Downloading %1 packages from remote repository %2", total, i);
+ y2milestone("Downloading %1 packages from remote repository %2", total, enabled_sources[i]:-1);
ret = ret + total;
}
}
--
To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org
For additional commands, e-mail: yast-commit+help@opensuse.org