}
+
+ /*! Remove all bookmarks
+ */
+ void removeAllBookmark(){
+ _bookmarks.clear();
+ }
+
+
/*! Searching for list of bookmarks may take some time, so i moved it to
new thread (to avoid gui blocking), when ready bookmarksReady is emited
and result is returned after calling getBookmarks()
*/
void fetchBookmarks() {
- _bookmarksResult.clear();
- _innerListBookmarks = QtConcurrent::run(_bookmarks, &Bookmarks::list);
- _bookmarkWatcher.setFuture(_innerListBookmarks);
+ _result.clear();
+
+ stopped = false;
+ dictFin = 1;
+ bookmarkFin = 0;
+
+ if(_searchBookmarks) {
+ _innerBookmarks = QtConcurrent::run(_bookmarks,
+ &Bookmarks::searchWordList, QString("*"));
+ _bookmarkSearchWatcher.setFuture(_innerBookmarks);
+ }
}
/*! \return list of all bookmarks