Commit cd2dab29 authored by Eike Ziller's avatar Eike Ziller

Implement "search again" for find usages (C++)

Change-Id: Ia3dc174c64da9194401883a1a989a712cb7aaed8
Reviewed-by: default avatarLeandro Melo <leandro.melo@nokia.com>
parent 570dbb2d
This diff is collapsed.
......@@ -58,6 +58,13 @@ class CppModelManagerInterface;
namespace CppTools {
namespace Internal {
class CppFindReferencesParameters
{
public:
CPlusPlus::LookupContext context;
CPlusPlus::Symbol *symbol;
};
class CppFindReferences: public QObject
{
Q_OBJECT
......@@ -83,13 +90,17 @@ private Q_SLOTS:
void cancel();
void openEditor(const Find::SearchResultItem &item);
void onReplaceButtonClicked(const QString &text, const QList<Find::SearchResultItem> &items);
void searchAgain();
private:
void findAll_helper(Find::SearchResult *search,
CPlusPlus::Symbol *symbol, const CPlusPlus::LookupContext &context);
void findUsages(CPlusPlus::Symbol *symbol, const CPlusPlus::LookupContext &context,
const QString &replacement, bool replace);
void findAll_helper(Find::SearchResult *search);
CPlusPlus::DependencyTable dependencyTable() const;
void setDependencyTable(const CPlusPlus::DependencyTable &newTable);
void createWatcher(const QFuture<CPlusPlus::Usage> &future, Find::SearchResult *search);
bool findSymbol(CppFindReferencesParameters *parameters,
const CPlusPlus::Snapshot &snapshot);
private:
QPointer<CPlusPlus::CppModelManagerInterface> _modelManager;
......@@ -102,4 +113,6 @@ private:
} // namespace Internal
} // namespace CppTools
Q_DECLARE_METATYPE(CppTools::Internal::CppFindReferencesParameters)
#endif // CPPFINDREFERENCES_H
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment