src: Refactored TokenLocation classes to SourceLocation classes

* Removed TokenLocationLine
* decoupled TokenLocationFile from TokenLocationCollection
* save vector of Token ids to SourceLocation
* refactored SourceLocationFile::getFilteredByLines()
* refactored snippet creation
This commit is contained in:
Eberhard Graether
2017-03-25 02:05:48 +01:00
parent 4c64822504
commit 4e9ba897ac
53 changed files with 1453 additions and 1796 deletions
+2 -2
View File
@@ -105,7 +105,7 @@ void QtCodeView::setFileState(const FilePath filePath, FileState state)
}
void QtCodeView::showActiveSnippet(
const std::vector<Id>& activeTokenIds, std::shared_ptr<TokenLocationCollection> collection, bool scrollTo)
const std::vector<Id>& activeTokenIds, std::shared_ptr<SourceLocationCollection> collection, bool scrollTo)
{
m_doShowActiveSnippetFunctor(activeTokenIds, collection, scrollTo);
}
@@ -241,7 +241,7 @@ void QtCodeView::doSetFileState(const FilePath filePath, FileState state)
}
void QtCodeView::doShowActiveSnippet(
const std::vector<Id>& activeTokenIds, std::shared_ptr<TokenLocationCollection> collection, bool scrollTo)
const std::vector<Id>& activeTokenIds, std::shared_ptr<SourceLocationCollection> collection, bool scrollTo)
{
m_widget->showActiveSnippet(activeTokenIds, collection, scrollTo);
}