Skip to content

Commit

Permalink
Drop obsolete adaptation and device key support
Browse files Browse the repository at this point in the history
  • Loading branch information
Bernd Wachter committed Apr 1, 2013
1 parent 56fb038 commit 72c2ff6
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 31 deletions.
12 changes: 0 additions & 12 deletions libssu/ssudeviceinfo.cpp
Expand Up @@ -285,18 +285,6 @@ QHash<QString, QString> SsuDeviceInfo::variableSection(QString section){
return result;
}

bool SsuDeviceInfo::getValue(const QString& key, QString& value){
if (boardMappings->contains(deviceVariant()+"/"+key)){
value = boardMappings->value(deviceVariant()+"/"+key).toString();
return true;
}
else if (boardMappings->contains(deviceModel()+"/"+key)){
value = boardMappings->value(deviceModel()+"/"+key).toString();
return true;
}
return false;
}

void SsuDeviceInfo::setDeviceModel(QString model){
if (model == "")
cachedModel = "";
Expand Down
4 changes: 0 additions & 4 deletions libssu/ssudeviceinfo.h
Expand Up @@ -83,10 +83,6 @@ class SsuDeviceInfo: public QObject {
*/
QVariant value(const QString &key, const QVariant &value=QVariant());

/**
* Get a key from an adaptation section. Deprecated, don't use.
*/
bool getValue(const QString& key, QString& value);

private:
SsuSettings *boardMappings;
Expand Down
15 changes: 0 additions & 15 deletions libssu/ssurepomanager.cpp
Expand Up @@ -220,24 +220,9 @@ QString SsuRepoManager::url(QString repoName, bool rndRepo,
if (parametersOverride.contains("model"))
deviceInfo.setDeviceModel(parametersOverride.value("model"));

// read adaptation from settings, in case it can't be determined from
// board mappings. this is obsolete, and will be dropped soon
if (settings->contains("adaptation"))
repoParameters.insert("adaptation", settings->value("adaptation").toString());

repoParameters.insert("deviceFamily", deviceInfo.deviceFamily());
repoParameters.insert("deviceModel", deviceInfo.deviceModel());

// Those keys have now been obsoleted by generic variables, support for
// it will be removed soon
QStringList keys;
keys << "chip" << "adaptation" << "vendor";
foreach(QString key, keys){
QString value;
if (deviceInfo.getValue(key,value))
repoParameters.insert(key, value);
}

repoName = deviceInfo.adaptationVariables(repoName, &repoParameters);

// Domain variables
Expand Down

0 comments on commit 72c2ff6

Please sign in to comment.