logic: reduce access to filesystem while indexing

* use canonical filepath cache in cxx indexer
* made constructors of FilePath explicit
* use FilePath at more places instead of string
* forward declares FilePath wherever possible
This commit is contained in:
malte_langkabel
2017-05-04 10:55:16 +02:00
parent 55d3f9c189
commit 054b8fab17
156 changed files with 656 additions and 444 deletions
+5 -5
View File
@@ -88,7 +88,7 @@ void QtBookmarkView::setCreateButtonState(const CreateButtonState& state)
m_createButtonState = state;
m_createBookmarkButton->setIcon(utility::createButtonIcon(
ResourcePaths::getGuiPath() + "bookmark_view/images/edit_bookmark_icon.png",
ResourcePaths::getGuiPath().str() + "bookmark_view/images/edit_bookmark_icon.png",
"search/button"
));
@@ -105,7 +105,7 @@ void QtBookmarkView::setCreateButtonState(const CreateButtonState& state)
m_createBookmarkButton->setEnabled(true);
m_createBookmarkButton->setIcon(utility::createButtonIcon(
ResourcePaths::getGuiPath() + "bookmark_view/images/bookmark_active.png",
ResourcePaths::getGuiPath().str() + "bookmark_view/images/bookmark_active.png",
"search/button"
));
}
@@ -240,7 +240,7 @@ void QtBookmarkView::displayBookmarkEditor(std::shared_ptr<Bookmark> bookmark, c
void QtBookmarkView::setStyleSheet()
{
m_widget->setStyleSheet(utility::getStyleSheet(ResourcePaths::getGuiPath() + "bookmark_view/bookmark_view.css").c_str());
m_widget->setStyleSheet(utility::getStyleSheet(ResourcePaths::getGuiPath().concat(FilePath("bookmark_view/bookmark_view.css"))).c_str());
}
void QtBookmarkView::refreshStyle()
@@ -251,12 +251,12 @@ void QtBookmarkView::refreshStyle()
m_showBookmarksButton->setFixedHeight(height);
m_createBookmarkButton->setIcon(utility::createButtonIcon(
ResourcePaths::getGuiPath() + "bookmark_view/images/edit_bookmark_icon.png",
ResourcePaths::getGuiPath().str() + "bookmark_view/images/edit_bookmark_icon.png",
"search/button"
));
m_showBookmarksButton->setIcon(utility::createButtonIcon(
ResourcePaths::getGuiPath() + "bookmark_view/images/bookmark_list_icon.png",
ResourcePaths::getGuiPath().str() + "bookmark_view/images/bookmark_list_icon.png",
"search/button"
));
}