aboutsummaryrefslogtreecommitdiff
path: root/src-qt5/desktop-utils/lumina-fm
diff options
context:
space:
mode:
Diffstat (limited to 'src-qt5/desktop-utils/lumina-fm')
-rw-r--r--src-qt5/desktop-utils/lumina-fm/MainUI.cpp17
-rw-r--r--src-qt5/desktop-utils/lumina-fm/MainUI.h3
-rw-r--r--src-qt5/desktop-utils/lumina-fm/MainUI.ui20
3 files changed, 30 insertions, 10 deletions
diff --git a/src-qt5/desktop-utils/lumina-fm/MainUI.cpp b/src-qt5/desktop-utils/lumina-fm/MainUI.cpp
index 8455e3aa..b2f976d2 100644
--- a/src-qt5/desktop-utils/lumina-fm/MainUI.cpp
+++ b/src-qt5/desktop-utils/lumina-fm/MainUI.cpp
@@ -302,7 +302,7 @@ void MainUI::loadSettings(){
on_actionShow_Thumbnails_triggered(); //make sure to update models too
//ui->actionView_showDirTreePane->setChecked( settings->value("showdirtree", false).toBool());
//on_actionView_showDirTreePane_triggered(); //make sure to update the models too
-
+ ui->actionVerify_File_Delete->setChecked( settings->value("showdeleteprompt", true).toBool());
//ui->actionShow_Action_Buttons->setChecked(settings->value("showactions", true).toBool() );
//on_actionShow_Action_Buttons_triggered(); //make sure to update the UI
//ui->actionShow_Thumbnails->setChecked( settings->value("showthumbnails", true).toBool() );
@@ -472,6 +472,11 @@ void MainUI::on_actionView_Hidden_Files_triggered(){
}
+void MainUI::on_actionVerify_File_Delete_triggered(){
+//Now save this setting for later
+ settings->setValue("showdeleteprompt", ui->actionView_Hidden_Files->isChecked());
+}
+
void MainUI::treeWidgetWidthChanged(float percent){
//NOTE: Percent needs to be between 0-75
if(percent > 75){ percent = 75; }
@@ -922,10 +927,12 @@ void MainUI::RemoveFiles(QStringList list){
}
//Verify permanent removal of file/dir
- QMessageBox dlgQ(QMessageBox::Question, tr("Verify Removal"), tr("WARNING: This will permanently delete the file(s) from the system!")+"\n"+tr("Are you sure you want to continue?"), QMessageBox::Yes | QMessageBox::No, this);
- dlgQ.setDetailedText(tr("Items to be removed:")+"\n\n"+names.join("\n"));
- dlgQ.exec();
- if(dlgQ.result() != QMessageBox::Yes){ return; } //cancelled
+ if(ui->actionVerify_File_Delete->isChecked()){
+ QMessageBox dlgQ(QMessageBox::Question, tr("Verify Removal"), tr("WARNING: This will permanently delete the file(s) from the system!")+"\n"+tr("Are you sure you want to continue?"), QMessageBox::Yes | QMessageBox::No, this);
+ dlgQ.setDetailedText(tr("Items to be removed:")+"\n\n"+names.join("\n"));
+ dlgQ.exec();
+ if(dlgQ.result() != QMessageBox::Yes){ return; } //cancelled
+ }
//Now remove the file/dir
qDebug() << " - Delete: "<<paths;
diff --git a/src-qt5/desktop-utils/lumina-fm/MainUI.h b/src-qt5/desktop-utils/lumina-fm/MainUI.h
index b17ec690..9eed250d 100644
--- a/src-qt5/desktop-utils/lumina-fm/MainUI.h
+++ b/src-qt5/desktop-utils/lumina-fm/MainUI.h
@@ -129,7 +129,8 @@ private slots:
void on_actionDelete_Selection_triggered();*/
void on_actionRefresh_triggered();
void on_actionView_Hidden_Files_triggered();
- //void on_actionView_showDirTreePane_triggered();
+ void on_actionVerify_File_Delete_triggered();
+ //void on_actionView_showDirTreePane_triggered();
//void on_actionShow_Action_Buttons_triggered();
void treeWidgetWidthChanged(float percent);
void on_actionShow_Thumbnails_triggered();
diff --git a/src-qt5/desktop-utils/lumina-fm/MainUI.ui b/src-qt5/desktop-utils/lumina-fm/MainUI.ui
index 5f067786..32ccd659 100644
--- a/src-qt5/desktop-utils/lumina-fm/MainUI.ui
+++ b/src-qt5/desktop-utils/lumina-fm/MainUI.ui
@@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>567</width>
- <height>415</height>
+ <height>417</height>
</rect>
</property>
<property name="windowTitle">
@@ -69,7 +69,7 @@
<x>0</x>
<y>0</y>
<width>567</width>
- <height>161</height>
+ <height>137</height>
</rect>
</property>
<layout class="QHBoxLayout" name="BrowserLayout">
@@ -116,7 +116,7 @@
<x>0</x>
<y>0</y>
<width>567</width>
- <height>28</height>
+ <height>38</height>
</rect>
</property>
<widget class="QMenu" name="menuFile">
@@ -145,9 +145,10 @@
</widget>
<addaction name="actionRefresh"/>
<addaction name="separator"/>
+ <addaction name="actionShow_Thumbnails"/>
<addaction name="actionView_Hidden_Files"/>
+ <addaction name="actionVerify_File_Delete"/>
<addaction name="separator"/>
- <addaction name="actionShow_Thumbnails"/>
<addaction name="menuView_Mode"/>
</widget>
<widget class="QMenu" name="menuBookmarks">
@@ -451,6 +452,17 @@
<string>Open as Root</string>
</property>
</action>
+ <action name="actionVerify_File_Delete">
+ <property name="checkable">
+ <bool>true</bool>
+ </property>
+ <property name="checked">
+ <bool>true</bool>
+ </property>
+ <property name="text">
+ <string>Verify File Delete</string>
+ </property>
+ </action>
</widget>
<resources/>
<connections/>
bgstack15