Skip to content
Browse files

Merge branch 'master' of github.com:pcbsd/pcbsd

  • Loading branch information...
2 parents ad36b59 + 68b1db6 commit 3a00741b42265acce4520b59733982b6b6a4ea35 @kmoore134 kmoore134 committed Mar 5, 2014
Showing with 14 additions and 0 deletions.
  1. +14 −0 src-qt4/life-preserver/lp-gui/LPMain.cpp
View
14 src-qt4/life-preserver/lp-gui/LPMain.cpp
@@ -239,6 +239,16 @@ void LPMain::updateTabs(){
QString cds = ui->combo_datasets->currentText();
ui->combo_datasets->clear();
QStringList dslist = POOLDATA.subsets();
+ dslist.sort();
+ //Now move the home directories to the top of the list
+ int moved = 0;
+ for(int i=0; i<dslist.length(); i++){ //make sure it stays in alphabetical order
+ if(dslist[i].startsWith("/usr/home/")){
+ dslist.move(i,moved);
+ moved++;
+ i--; //make sure to not miss any items from moving
+ }
+ }
ui->combo_datasets->addItems(dslist);
int dsin = dslist.indexOf(cds);
if(dsin >= 0){ ui->combo_datasets->setCurrentIndex(dsin); }
@@ -292,6 +302,10 @@ void LPMain::updateDataset(){
if(max < 0){ max = 0; ui->slider_snapshots->setEnabled(false); }
ui->slider_snapshots->setMaximum(max);
ui->slider_snapshots->setValue(max); //most recent snapshot
+ int interval = 1; //one tick per snapshot
+ if( max > 20 ){ interval = max / 20; } //show 20 ticks
+ ui->slider_snapshots->setTickInterval(interval);
+
updateSnapshot();
}else{
ui->slider_snapshots->setEnabled(false);

0 comments on commit 3a00741

Please sign in to comment.
Something went wrong with that request. Please try again.