diff options
author | Ken Moore <ken@pcbsd.org> | 2016-09-08 11:59:41 -0400 |
---|---|---|
committer | Ken Moore <ken@pcbsd.org> | 2016-09-08 11:59:41 -0400 |
commit | 4e0f8f0ce417ec473489a0986054847d6279482e (patch) | |
tree | 22b8ce358b5f3cbd585cdb713e4794e32a3ddf93 /src-qt5/desktop-utils | |
parent | Add the backend class/functions for using GIT within lumina-fm. (diff) | |
download | lumina-4e0f8f0ce417ec473489a0986054847d6279482e.tar.gz lumina-4e0f8f0ce417ec473489a0986054847d6279482e.tar.bz2 lumina-4e0f8f0ce417ec473489a0986054847d6279482e.zip |
When saving a new .desktop file in lumina-textedit: make sure the dir exists first.
Diffstat (limited to 'src-qt5/desktop-utils')
-rw-r--r-- | src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp b/src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp index 1fc136de..56b72a3c 100644 --- a/src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp @@ -233,6 +233,7 @@ void MainUI::on_push_save_clicked(){ if(INFO.filePath().isEmpty()){ //Need to prompt for where to save the file and what to call it QString appdir = QString(getenv("XDG_DATA_HOME"))+"/applications/"; + if(!QFile::exists(appdir)){ QDir dir; dir.mkpath(appdir); } QString filePath = QFileDialog::getSaveFileName(this, tr("Save Application File"), appdir, tr("Application Registrations (*.desktop)") ); if(filePath.isEmpty()){ return; } if(!filePath.endsWith(".desktop")){ filePath.append(".desktop"); } |