Summary: | Reinvoking grep function should set focus to dialog if already open | ||
---|---|---|---|
Product: | [Applications] kdevelop | Reporter: | Jon Smirl <jonsmirl> |
Component: | general | Assignee: | KDevelop Developers <kdevelop-devel> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | git master | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Jon Smirl
2003-12-31 04:33:48 UTC
The grep dialog shouldn't be allowed to end up below the fullscreen kdevelop window in the first place. And on my (KDE-3.2 CVS) system I find no way of getting it below the main window. I suspect this is only possible with the old kwin implementation (pre 3.2). If that is the case, I think this is too much of a special case to be worth the hassle to try to work around. Anyone seeing this on KDE-3.2? You can do this non-full screen too. I'm on Fedora but I'm running with current kdebase and libs. Subject: kdevelop/parts/grepview CVS commit by harald: if you lose this non-modal dialog somewhere behind your main window, make sure it is brought to front when the action is called again. CCMAIL: 71532-done@bugs.kde.org M +10 -0 grepdlg.cpp 1.23 M +1 -5 grepdlg.h 1.6 --- kdevelop/parts/grepview/grepdlg.cpp #1.22:1.23 @@ -276,3 +276,13 @@ void GrepDialog::slotSearchClicked() } +void GrepDialog::show() +{ + // not beautiful, but works with all window + // managers and Qt versions + if (isVisible()) + QDialog::hide(); + QDialog::show(); + pattern_combo->setFocus(); +} + #include "grepdlg.moc" --- kdevelop/parts/grepview/grepdlg.h #1.5:1.6 @@ -49,9 +49,5 @@ public: bool recursiveFlag() const { return recursive_box->isChecked(); } - void show() - { - pattern_combo->setFocus(); - QDialog::show(); - } + void show(); #ifdef IGNORE_SCM_DIRS Why isn't the grep dialog modal with the app as it's parent? If it was modal it wouldn't have this problem. What's the advantage to the non-modal version? |