mirror of
https://github.com/parchlinux/calamares.git
synced 2025-06-29 18:35:37 -04:00
[packagechooser] Build AppStream Pool first
- Don't build a Pool for each PackageItem loaded - Do make it load all languages instead of only the current one
This commit is contained in:
parent
0a92ef7655
commit
d8af11adee
3 changed files with 24 additions and 10 deletions
|
@ -96,7 +96,7 @@ fromComponent( AppStream::Component& component )
|
|||
}
|
||||
|
||||
PackageItem
|
||||
fromAppStream( const QVariantMap& item_map )
|
||||
fromAppStream( AppStream::Pool& pool, const QVariantMap& item_map )
|
||||
{
|
||||
QString appstreamId = CalamaresUtils::getString( item_map, "appstream" );
|
||||
if ( appstreamId.isEmpty() )
|
||||
|
@ -106,13 +106,6 @@ fromAppStream( const QVariantMap& item_map )
|
|||
}
|
||||
cDebug() << "Loading AppStream data for" << appstreamId;
|
||||
|
||||
AppStream::Pool pool;
|
||||
if ( !pool.load() )
|
||||
{
|
||||
cWarning() << "AppStream load failed" << pool.lastError();
|
||||
return PackageItem();
|
||||
}
|
||||
|
||||
auto itemList = pool.componentsById( appstreamId );
|
||||
if ( itemList.count() < 1 )
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue