Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add a variant of SsuRepoManager::repos() reading rndmode from configu…
…ration
  • Loading branch information
Bernd Wachter committed Sep 7, 2015
1 parent ffc891e commit d402afe
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
11 changes: 11 additions & 0 deletions libssu/ssurepomanager.cpp
Expand Up @@ -123,6 +123,17 @@ int SsuRepoManager::remove(QString repo){
return 0;
}

QStringList SsuRepoManager::repos(int filter){
SsuDeviceInfo deviceInfo;
SsuCoreConfig *ssuSettings = SsuCoreConfig::instance();
bool rnd = false;

if ((ssuSettings->deviceMode() & Ssu::RndMode) == Ssu::RndMode)
rnd = true;

return repos(rnd, deviceInfo, filter);
}

QStringList SsuRepoManager::repos(bool rnd, int filter){
SsuDeviceInfo deviceInfo;

Expand Down
5 changes: 5 additions & 0 deletions libssu/ssurepomanager.h
Expand Up @@ -65,6 +65,11 @@ class SsuRepoManager: public QObject {
/**
* Collect the list of repositories from different submodules
*/
QStringList repos(int filter=Ssu::NoFilter);
/**
* Collect the list of repositories from different submodules.
* This form allows overriding rnd mode setting.
*/
QStringList repos(bool rnd, int filter=Ssu::NoFilter);
/**
* Collect the list of repositories from different submodules.
Expand Down

0 comments on commit d402afe

Please sign in to comment.