-rw-r--r-- | korganizer/searchdialog.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/korganizer/searchdialog.cpp b/korganizer/searchdialog.cpp index cef59a2..678e1bd 100644 --- a/korganizer/searchdialog.cpp +++ b/korganizer/searchdialog.cpp @@ -25,8 +25,9 @@ #include <qlayout.h> #include <qcheckbox.h> #include <qgroupbox.h> #include <qlabel.h> +#include <qlistview.h> #include <qwhatsthis.h> #include <qlineedit.h> #include <qpushbutton.h> @@ -36,8 +37,9 @@ #include <libkdepim/kdateedit.h> #include "koglobals.h" #include "koprefs.h" +#include "klineedit.h" #include "calendarview.h" #include "koviewmanager.h" #include "searchdialog.h" @@ -56,9 +58,9 @@ SearchDialog::SearchDialog(Calendar *calendar,CalendarView *parent) searchLabel = new QLabel(topFrame); searchLabel->setText(i18n("Search for:")); subLayout->addWidget(searchLabel); - searchEdit = new QLineEdit(topFrame); + searchEdit = new KLineEdit(topFrame); subLayout->addWidget(searchEdit); QPushButton *OkButton = new QPushButton( i18n("&Find"), topFrame ); //OkButton->setDefault( true ); connect(OkButton,SIGNAL(clicked()),SLOT(doSearch())); @@ -113,8 +115,9 @@ SearchDialog::SearchDialog(Calendar *calendar,CalendarView *parent) listView = new KOListView(mCalendar,topFrame); layout->addWidget(listView); listView->readSettings(KOGlobals::config(),"SearchListView Layout"); + connect(searchEdit,SIGNAL(scrollDOWN()),SLOT(setFocusToList())); setCaption( i18n("KO/Pi Find: ")); #ifdef DESKTOP_VERSION OkButton = new QPushButton( i18n("Close"), this ); @@ -125,8 +128,12 @@ SearchDialog::SearchDialog(Calendar *calendar,CalendarView *parent) SearchDialog::~SearchDialog() { } +void SearchDialog::setFocusToList() +{ + listView->resetFocus(); +} void SearchDialog::accept() { doSearch(); } |