[packagechoose] Remove the *package* member

The single-values *package* member in a PackageItem was not used,
so remove it -- to show that it really isn't used. This is prep-
work for putting the package name *back*, as multi-valued,
and using the *packages* module.
This commit is contained in:
Adriaan de Groot 2021-04-13 12:29:06 +02:00
parent 2a9205ebd9
commit 59ea88f1ad
2 changed files with 1 additions and 9 deletions

View File

@ -35,23 +35,19 @@ roleNames()
PackageItem::PackageItem() {} PackageItem::PackageItem() {}
PackageItem::PackageItem( const QString& a_id, PackageItem::PackageItem( const QString& a_id,
const QString& a_package,
const QString& a_name, const QString& a_name,
const QString& a_description ) const QString& a_description )
: id( a_id ) : id( a_id )
, package( a_package )
, name( a_name ) , name( a_name )
, description( a_description ) , description( a_description )
{ {
} }
PackageItem::PackageItem( const QString& a_id, PackageItem::PackageItem( const QString& a_id,
const QString& a_package,
const QString& a_name, const QString& a_name,
const QString& a_description, const QString& a_description,
const QString& screenshotPath ) const QString& screenshotPath )
: id( a_id ) : id( a_id )
, package( a_package )
, name( a_name ) , name( a_name )
, description( a_description ) , description( a_description )
, screenshot( screenshotPath ) , screenshot( screenshotPath )
@ -60,7 +56,6 @@ PackageItem::PackageItem( const QString& a_id,
PackageItem::PackageItem::PackageItem( const QVariantMap& item_map ) PackageItem::PackageItem::PackageItem( const QVariantMap& item_map )
: id( CalamaresUtils::getString( item_map, "id" ) ) : id( CalamaresUtils::getString( item_map, "id" ) )
, package( CalamaresUtils::getString( item_map, "package" ) )
, name( CalamaresUtils::Locale::TranslatedString( item_map, "name" ) ) , name( CalamaresUtils::Locale::TranslatedString( item_map, "name" ) )
, description( CalamaresUtils::Locale::TranslatedString( item_map, "description" ) ) , description( CalamaresUtils::Locale::TranslatedString( item_map, "description" ) )
, screenshot( CalamaresUtils::getString( item_map, "screenshot" ) ) , screenshot( CalamaresUtils::getString( item_map, "screenshot" ) )

View File

@ -31,8 +31,6 @@ const NamedEnumTable< PackageChooserMode >& roleNames();
struct PackageItem struct PackageItem
{ {
QString id; QString id;
// FIXME: unused
QString package;
CalamaresUtils::Locale::TranslatedString name; CalamaresUtils::Locale::TranslatedString name;
CalamaresUtils::Locale::TranslatedString description; CalamaresUtils::Locale::TranslatedString description;
QPixmap screenshot; QPixmap screenshot;
@ -44,7 +42,7 @@ struct PackageItem
* This constructor sets all the text members, * This constructor sets all the text members,
* but leaves the screenshot blank. Set that separately. * but leaves the screenshot blank. Set that separately.
*/ */
PackageItem( const QString& id, const QString& package, const QString& name, const QString& description ); PackageItem( const QString& id, const QString& name, const QString& description );
/** @brief Creates a PackageItem from given strings. /** @brief Creates a PackageItem from given strings.
* *
@ -53,7 +51,6 @@ struct PackageItem
* a filesystem path, whatever QPixmap understands. * a filesystem path, whatever QPixmap understands.
*/ */
PackageItem( const QString& id, PackageItem( const QString& id,
const QString& package,
const QString& name, const QString& name,
const QString& description, const QString& description,
const QString& screenshotPath ); const QString& screenshotPath );