-rw-r--r-- | noncore/apps/odict/dingwidget.cpp | 4 | ||||
-rw-r--r-- | noncore/apps/odict/searchmethoddlg.cpp | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/noncore/apps/odict/dingwidget.cpp b/noncore/apps/odict/dingwidget.cpp index ac7c321..5939000 100644 --- a/noncore/apps/odict/dingwidget.cpp +++ b/noncore/apps/odict/dingwidget.cpp @@ -30,2 +30,3 @@ #include <qtextbrowser.h> +#include <stdlib.h> // for getenv @@ -33,3 +34,4 @@ DingWidget::DingWidget(QWidget *parent, QString word, QTextBrowser *browser_top, { - QFile file( "/home/carsten/opie/opie/noncore/apps/odict/eng_ita.dic" ); + QString opie_dir = getenv("OPIEDIR"); + QFile file( opie_dir+"/noncore/apps/odict/eng_ita.dic" ); QStringList lines; diff --git a/noncore/apps/odict/searchmethoddlg.cpp b/noncore/apps/odict/searchmethoddlg.cpp index 203c663..8a14703 100644 --- a/noncore/apps/odict/searchmethoddlg.cpp +++ b/noncore/apps/odict/searchmethoddlg.cpp @@ -28,2 +28,3 @@ #include <qlineedit.h> +#include <qdir.h> @@ -92,3 +93,3 @@ void SearchMethodDlg::slotBrowse() { - itemName=OFileDialog::getOpenFileName( OFileSelector::EXTENDED,"/home/carsten" ); + itemName=OFileDialog::getOpenFileName( OFileSelector::EXTENDED,QDir::homeDirPath()); dictFileLE->setText( itemName ); |