summaryrefslogtreecommitdiff
authorskyhusker <skyhusker>2005-04-10 21:19:22 (UTC)
committer skyhusker <skyhusker>2005-04-10 21:19:22 (UTC)
commitd133e1f4c2b820ca428438cb17f5477190d268b1 (patch) (side-by-side diff)
treeaa078c18de7bef76f37af9133f413f8bff478a1e
parenta6670730bf0b36b243303e581c4a80d29851c12b (diff)
downloadopie-d133e1f4c2b820ca428438cb17f5477190d268b1.zip
opie-d133e1f4c2b820ca428438cb17f5477190d268b1.tar.gz
opie-d133e1f4c2b820ca428438cb17f5477190d268b1.tar.bz2
Move to home directory on startup. Fixes bug #1614.
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-console/mainwindow.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/noncore/apps/opie-console/mainwindow.cpp b/noncore/apps/opie-console/mainwindow.cpp
index 21de5c0..eaa78c8 100644
--- a/noncore/apps/opie-console/mainwindow.cpp
+++ b/noncore/apps/opie-console/mainwindow.cpp
@@ -509,12 +509,17 @@ void MainWindow::slotProfile( int id) {
create( prof );
}
void MainWindow::create( const Profile& prof ) {
+ char *homeDir = getenv("HOME");
+
+ if ( homeDir )
+ ::chdir( homeDir );
+
if(m_curSession)
if(m_curSession->transferDialog()) m_curSession->transferDialog()->hide();
Session *ses = manager()->fromProfile( prof, tabWidget() );
if((!ses) || (!ses->layer()) || (!ses->widgetStack()))