aboutsummaryrefslogtreecommitdiff
path: root/lumina-fm
diff options
context:
space:
mode:
authorKen Moore <moorekou@gmail.com>2015-09-09 09:42:03 -0400
committerKen Moore <moorekou@gmail.com>2015-09-09 09:42:03 -0400
commit5badd414535fe6371d37df768d9e499f4558ff29 (patch)
tree394e9f13360cff5bcb8db0fd032a53c24eeb2199 /lumina-fm
parentMake sure to run the user-input dir path through the input fix/replacement ro... (diff)
downloadlumina-5badd414535fe6371d37df768d9e499f4558ff29.tar.gz
lumina-5badd414535fe6371d37df768d9e499f4558ff29.tar.bz2
lumina-5badd414535fe6371d37df768d9e499f4558ff29.zip
Make sure that when the last browser is closed a new one is created pointing at the users home dir.
Diffstat (limited to 'lumina-fm')
-rw-r--r--lumina-fm/MainUI.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lumina-fm/MainUI.cpp b/lumina-fm/MainUI.cpp
index 9ae681f0..49712b74 100644
--- a/lumina-fm/MainUI.cpp
+++ b/lumina-fm/MainUI.cpp
@@ -792,7 +792,6 @@ void MainUI::RemoveFiles(QStringList list){
}
void MainUI::CloseBrowser(QString ID){
- if(DWLIST.length()<2){ return; } //cannot close the last browser
//Find the tab associated with this browser first
for(int i=0; i<tabBar->count(); i++){
if(tabBar->tabWhatsThis(i)==ID){
@@ -807,6 +806,10 @@ void MainUI::CloseBrowser(QString ID){
break;
}
}
+ //If the last browser was just closed, create a new one
+ if(DWLIST.isEmpty()){
+ OpenDirs(QStringList() << QDir::homePath());
+ }
}
// ======================
bgstack15