forked from qt-creator/qt-creator
Find implementations now tell what find flags are actually supported.
This commit is contained in:
@@ -48,6 +48,12 @@ bool HelpFindSupport::isEnabled() const
|
||||
return true;
|
||||
}
|
||||
|
||||
Find::IFindSupport::FindFlags HelpFindSupport::supportedFindFlags() const
|
||||
{
|
||||
return Find::IFindSupport::FindBackward | Find::IFindSupport::FindCaseSensitively
|
||||
| Find::IFindSupport::FindWholeWords;
|
||||
}
|
||||
|
||||
QString HelpFindSupport::currentFindString() const
|
||||
{
|
||||
QTC_ASSERT(m_centralWidget, return QString());
|
||||
@@ -84,6 +90,12 @@ HelpViewerFindSupport::HelpViewerFindSupport(HelpViewer *viewer)
|
||||
{
|
||||
}
|
||||
|
||||
Find::IFindSupport::FindFlags HelpViewerFindSupport::supportedFindFlags() const
|
||||
{
|
||||
return Find::IFindSupport::FindBackward | Find::IFindSupport::FindCaseSensitively
|
||||
| Find::IFindSupport::FindWholeWords;
|
||||
}
|
||||
|
||||
QString HelpViewerFindSupport::currentFindString() const
|
||||
{
|
||||
QTC_ASSERT(m_viewer, return QString());
|
||||
|
||||
@@ -50,6 +50,8 @@ public:
|
||||
|
||||
bool isEnabled() const;
|
||||
bool supportsReplace() const { return false; }
|
||||
IFindSupport::FindFlags supportedFindFlags() const;
|
||||
|
||||
void resetIncrementalSearch() {}
|
||||
void clearResults() {}
|
||||
QString currentFindString() const;
|
||||
@@ -76,6 +78,7 @@ public:
|
||||
|
||||
bool isEnabled() const { return true; }
|
||||
bool supportsReplace() const { return false; }
|
||||
IFindSupport::FindFlags supportedFindFlags() const;
|
||||
void resetIncrementalSearch() {}
|
||||
void clearResults() {}
|
||||
QString currentFindString() const;
|
||||
|
||||
Reference in New Issue
Block a user