diff options
| author | Domrachev Alexandr <alexandr.domrachev@gmail.com> | 2009-06-18 22:47:32 +0400 | 
|---|---|---|
| committer | Domrachev Alexandr <alexandr.domrachev@gmail.com> | 2009-06-18 22:47:32 +0400 | 
| commit | 63de0263e68f31dd9535e6e92932260b0ab6111a (patch) | |
| tree | 3187da16eec1bd9cf5fc7eadc9909a7fa121e5bd | |
| parent | MainWindow::slotPrivateBrowsing fix (diff) | |
| download | rekonq-63de0263e68f31dd9535e6e92932260b0ab6111a.tar.xz | |
MainWindow::slotFind{Next, Previous} code clean
| -rw-r--r-- | src/mainwindow.cpp | 20 | 
1 files changed, 4 insertions, 16 deletions
| diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 20ee31f8..d0405ea9 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -570,15 +570,9 @@ void MainWindow::slotFindNext()      if (!currentTab() && m_lastSearch.isEmpty())          return; -    QWebPage::FindFlags options; +    QWebPage::FindFlags options = QWebPage::FindWrapsAroundDocument;      if (m_findBar->matchCase()) -    { -        options = QWebPage::FindCaseSensitively | QWebPage::FindWrapsAroundDocument; -    } -    else -    { -        options = QWebPage::FindWrapsAroundDocument; -    } +        options |= QWebPage::FindCaseSensitively;      if (!currentTab()->findText(m_lastSearch, options))      { @@ -592,15 +586,9 @@ void MainWindow::slotFindPrevious()      if (!currentTab() && m_lastSearch.isEmpty())          return; -    QWebPage::FindFlags options; +    QWebPage::FindFlags options = QWebPage::FindBackward | QWebPage::FindWrapsAroundDocument;      if (m_findBar->matchCase()) -    { -        options = QWebPage::FindCaseSensitively | QWebPage::FindBackward | QWebPage::FindWrapsAroundDocument; -    } -    else -    { -        options = QWebPage::FindBackward | QWebPage::FindWrapsAroundDocument; -    } +        options |= QWebPage::FindCaseSensitively;      if (!currentTab()->findText(m_lastSearch, options))      { | 
