aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorq5sys <jt@ixsystems.com>2017-09-04 20:52:38 -0400
committerq5sys <jt@ixsystems.com>2017-09-04 20:52:38 -0400
commitec3905d61bdbd873b416e04e896a597c3730730a (patch)
tree0c9429023f9b1c433dfd3798e77dd473fff52946
parentcomment out method until its finished (diff)
downloadlumina-ec3905d61bdbd873b416e04e896a597c3730730a.tar.gz
lumina-ec3905d61bdbd873b416e04e896a597c3730730a.tar.bz2
lumina-ec3905d61bdbd873b416e04e896a597c3730730a.zip
write auto-archival methods for file manager integration
-rw-r--r--src-qt5/desktop-utils/lumina-archiver/MainUI.cpp14
-rw-r--r--src-qt5/desktop-utils/lumina-archiver/MainUI.h3
-rw-r--r--src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp1
-rw-r--r--src-qt5/desktop-utils/lumina-archiver/TarBackend.h1
4 files changed, 18 insertions, 1 deletions
diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp
index afead9af..9d220824 100644
--- a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp
+++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp
@@ -72,9 +72,11 @@ MainUI::~MainUI(){
void MainUI::LoadArguments(QStringList args){
bool burnIMG = false;
bool autoExtract = false;
+ //bool autoArchive = false;
for(int i=0; i<args.length(); i++){
if(args[i]=="--burn-img"){ burnIMG = true; continue; }
if(args[i]=="--ax"){ autoExtract = true; continue; }
+ //if(args[i]=="--aa"){ autoArchive = true; continue; }
if(QFile::exists(args[i])){
ui->label_progress->setText(tr("Opening Archive..."));
if(autoExtract){
@@ -86,6 +88,14 @@ void MainUI::LoadArguments(QStringList args){
if(burnIMG){ BurnImgToUSB(); } //Go ahead and launch the burn dialog right away
break;
}
+ //if(autoArchive){
+ //get rest of arguments
+ //for(int i=1; i<args.length(); i++){
+ // aaFileList << args[i];}
+ // now launch autoarchive method with arg list
+ // autoArchiveFiles(aaFileList);
+ // connect(BACKEND, SIGNAL(ArchivalSuccessful()), this, SLOT(close()) );
+ //}
}
}
@@ -252,6 +262,10 @@ void MainUI::autoextractFiles(){
BACKEND->startExtract(dir, true);
}
+/*
+void MainUI::autoArchiveFiles(aaFileList){
+*/
+
void MainUI::extractSelection(){
if(ui->tree_contents->currentItem()==0){ return; } //nothing selected
QList<QTreeWidgetItem*> sel = ui->tree_contents->selectedItems();
diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.h b/src-qt5/desktop-utils/lumina-archiver/MainUI.h
index 61475fb2..a2687895 100644
--- a/src-qt5/desktop-utils/lumina-archiver/MainUI.h
+++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.h
@@ -25,7 +25,7 @@ public:
void LoadArguments(QStringList);
void loadIcons();
-
+ //QStringList aaFileList;
private:
Ui::MainUI *ui;
@@ -47,6 +47,7 @@ private slots:
void remFiles();
void extractFiles();
void autoextractFiles();
+ //void autoArchiveFiles(QStringList aaFileList);
void extractSelection();
void ViewFile(QTreeWidgetItem *it);
void UpdateTree();
diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp
index 9fe735a3..e0b802a4 100644
--- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp
+++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp
@@ -262,6 +262,7 @@ void Backend::procFinished(int retcode, QProcess::ExitStatus){
}
}
if(args.contains("-x")){ result = tr("Extraction Finished"); emit ExtractSuccessful(); }
+ //if(args.contains("-aa")){ result = tr("Archival Finished"); emit ArchivalSuccessful(); }
else if(args.contains("-c")){ result = tr("Modification Finished"); }
if(needupdate){ startList(); }
else{ emit ProcessFinished(retcode==0, result); result.clear(); }
diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h
index dd08361c..d86ecf7c 100644
--- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h
+++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h
@@ -64,6 +64,7 @@ signals:
void ProcessStarting();
void ProgressUpdate(int, QString); //percentage, text
void ProcessFinished(bool, QString); //success, text
+ //void ArchivalSuccessful();
};
#endif
bgstack15