Changeset 109c737


Ignore:
Timestamp:
03/05/14 08:33:02 (10 months ago)
Author:
Ken Moore <ken@…>
Branches:
master, releng/10.0.1, releng/10.0.2, releng/10.0.3, releng/10.1
Children:
4f9718b, 65e10ad
Parents:
0ed0d02
Message:

Add a new "Classic Backup" dialog for customizing the home-dir archive and providing status updates while it is running.

Location:
src-qt4/life-preserver/lp-gui
Files:
3 added
4 edited

Legend:

Unmodified
Added
Removed
  • src-qt4/life-preserver/lp-gui/LPGUtils.cpp

    r8b3a780 r109c737  
    142142 
    143143bool LPGUtils::revertFile(QString oldPath, QString newPath){ 
     144  qDebug() << "Reverting file:" << oldPath << " -> " << newPath; 
    144145  bool ok = QFile::copy(oldPath,newPath); 
    145146  //return the path to the new file if the copy was successful 
     
    149150    QFileInfo FI(oldPath); 
    150151      system( QString("chown "+FI.owner()+":"+FI.group()+" "+newPath).toUtf8() ); 
     152  }else{ 
     153    qDebug() << " - Error: Could not copy file"; 
    151154  } 
    152155  return ok; 
  • src-qt4/life-preserver/lp-gui/LPMain.cpp

    rec61e8e r109c737  
    2121  //Initialize the waitbox pointer 
    2222  waitBox = 0; 
     23  //Initialize the classic dialog pointer 
     24  classicDLG = 0; 
    2325  //Create the basic/advanced view options 
    2426  viewBasic = new QRadioButton(tr("Basic"), ui->menuView); 
     
    522524  QString user = act->text(); 
    523525  qDebug() << "Compress Home Dir:" << user; 
     526  //Start up the Classic Dialog 
     527  bool recreate = false; 
     528  if(classicDLG == 0){ recreate = true; } 
     529  if(recreate){ 
     530    classicDLG = new LPClassic(this); 
     531    classicDLG->setHomeDir("/usr/home/"+user); 
     532    classicDLG->show(); 
     533  }else if(!classicDLG->running){ 
     534    classicDLG->setHomeDir("/usr/home/"+user); //move to the alternate user dir 
     535  } 
     536  classicDLG->raise(); 
     537  classicDLG->show(); 
     538  /* 
    524539  //Prompt for the package name 
    525540  QString pkgName = user+"-"+QDateTime::currentDateTime().toString("yyyyMMdd-hhmm"); 
     
    538553    qDebug() << "Package created at:" << pkgPath; 
    539554    QMessageBox::information(this,tr("Package Success"), tr("The home directory package was successfully created.")+"\n\n"+pkgPath); 
    540   }        
     555  } 
     556  */ 
    541557} 
    542558 
  • src-qt4/life-preserver/lp-gui/LPMain.h

    rec61e8e r109c737  
    2323#include "LPWizard.h" 
    2424#include "LPConfig.h" 
     25#include "LPClassic.h" 
    2526 
    2627namespace Ui{ 
     
    4748        QTimer *timer; 
    4849        QSettings *settings; 
     50        LPClassic *classicDLG; 
    4951 
    5052        void showErrorDialog(QString title, QString message, QString errors); 
  • src-qt4/life-preserver/lp-gui/lp-gui.pro

    rd9190b1 r109c737  
    1010                LPConfig.h \ 
    1111                LPMain.h \ 
    12                 LPGUtils.h 
     12                LPGUtils.h \ 
     13                LPClassic.h 
    1314                 
    1415SOURCES += main.cpp \ 
     
    1718                LPConfig.cpp \ 
    1819                LPMain.cpp \ 
    19                 LPGUtils.cpp 
     20                LPGUtils.cpp \ 
     21                LPClassic.cpp 
    2022 
    2123RESOURCES += lPreserve.qrc 
     
    2325FORMS   = LPWizard.ui \ 
    2426        LPConfig.ui \ 
    25         LPMain.ui 
     27        LPMain.ui \ 
     28        LPClassic.ui 
    2629 
    2730TARGET=life-preserver 
Note: See TracChangeset for help on using the changeset viewer.