summaryrefslogtreecommitdiff
path: root/gtk/gtksearchenginetracker.c
Commit message (Collapse)AuthorAgeFilesLines
* searchenginetracker: Quote fts match so it's seen as a single phraseCarlos Garnacho2016-05-051-5/+10
| | | | | | | FTS5 has a complex enough syntax that it makes not much sense to wrap in simple search boxes. https://bugzilla.gnome.org/show_bug.cgi?id=765981
* searchenginetracker: Remove astray ");" closing a functionCarlos Garnacho2015-11-231-1/+1
| | | | Sad face for me.
* searchenginetracker: Optimize direct/recursive folder lookupsCarlos Garnacho2015-11-231-7/+16
| | | | | | | | | | | | | tracker:uri-is-descendant/parent has the unfortunate side effect of rendering the collation mechanisms in the database useless, so those require full table scans to be validated. Performing these as pure string comparisons will perform much better, as those allow the underlying sqlite to rely on its own collation to perform the search, which can be significantly faster with many elements in the database. https://bugzilla.gnome.org/show_bug.cgi?id=758407
* searchenginetracker: ensure nie:url is boundCarlos Garnacho2015-11-231-1/+1
| | | | | | | This could produce strange warnings as it is currently passed to tracker:uri-is-* sparql functions, as these expect no NULLs. https://bugzilla.gnome.org/show_bug.cgi?id=758407
* searchenginetracker: Ignore NULL directoriesBenjamin Otte2015-08-011-0/+3
|
* Avoid more GFile<>uri roundtripsMatthias Clasen2015-07-271-1/+1
| | | | | | Make GtkSearchHit carry a GFile instead of an uri. Most of the search engines already have the object around, and converting to an uri and back is unnecessary extra work.
* Store locations as GFileMatthias Clasen2015-07-271-3/+5
| | | | | | It is a bit pointless to have the file chooser get a uri from an existing GFile to put in the query, only to have some of the search engines reconstruct a GFile from it.
* GtkQuery: Make API follow GTK+ conversionsMatthias Clasen2015-07-211-3/+2
| | | | | | We generally have const getters for strings, and the two users of this API were promptly leaking the (unexpected) copy they got from gtk_query_get_location and gtk_query_get_text.
* GtkSearchEngineTracker: Fix SPARQL syntaxMatthias Clasen2015-06-191-2/+2
| | | | | The function is called tracker:uri-is-descendant, not tracker-uri-is-descendant.
* GtkSearchEngineTracker: Avoid a private structMatthias Clasen2015-06-191-35/+36
| | | | We can just make this type final, and avoid the private struct.
* Avoid an unnecessary checkMatthias Clasen2015-06-191-2/+1
| | | | We create the indexed_locations array unconditionally.
* GtkSearchEngine: Avoid crawling indexed locationsMatthias Clasen2015-06-191-14/+106
| | | | | | Implement the IsIndexed callback for tracker. This requires reading settings of the tracker file miner. We are careful to avoid a hard dependency on the tracker schemas.
* GtkSearchEngine: Add recursive flagMatthias Clasen2015-06-181-3/+13
| | | | | | | Add a flag for recursive search, and implement non-recursive search in both the tracker and simple search engines. This is not currently used in the file chooser.
* search engine: Pass file infos along for hitsMatthias Clasen2015-06-181-21/+7
|
* GtkQuery: CleanupsMatthias Clasen2015-05-161-2/+2
| | | | | Strip leading underscores from GtkQuery api, and clean up the sources a bit.
* GtkSearchEngine: Drop unused functionalityMatthias Clasen2015-05-011-7/+0
|
* searchenginetracker: Keep a reference on the search engine while queryingCarlos Garnacho2015-03-031-6/+4
| | | | | | | | | The object might be destroyed when mid operation, causing crashes as the query callback still expects the object pointer to be valid. Also, remove the gdk_threads_enter/leave pairs, the callback will be executed on the caller (UI) thread, so this is not necessary. https://bugzilla.gnome.org/show_bug.cgi?id=745479
* searchenginetracker: Unify fts/non-fts queryCarlos Garnacho2015-02-281-25/+24
| | | | | This makes sure we use location_uri for both types of query, and the fts query has been made more similar to the one used by nautilus.
* tracker: Turn on ftsMatthias Clasen2015-02-281-1/+3
| | | | | | We want to match what nautilus does, and the non-fts query ignores the location, which yields somewhat broken UI in the file chooser.
* docs: use apostrophes in *n'tWilliam Jon McCann2014-02-071-1/+1
|
* gtk: Use new macros for defining private dataEmmanuele Bassi2013-07-091-7/+2
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=702996
* Change FSF AddressJavier Jardón2012-02-271-2/+1
|
* GtkSearchEngineTracker: port to tracker 0.12Matthias Clasen2011-09-121-240/+247
| | | | | | | | We simply use the Tracker DBus api here, caching and direct access that come with libtracker-sparql are probably not needed here. Based on a patch by Martyn Russell. https://bugzilla.gnome.org/show_bug.cgi?id=658272
* gtksearchenginetracker: Use non-case sensitive search for non-fts searchVincent Untz2011-06-061-2/+14
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=642773
* GtkSearchEngineTracker: avoid an unused variable warningMatthias Clasen2011-05-311-2/+5
|
* Make tracker search engine less verboseMatthias Clasen2011-05-311-10/+0
| | | | | Patch by Vincent Untz, https://bugzilla.gnome.org/show_bug.cgi?id=642768
* tracker: Include gdk.hBenjamin Otte2011-03-291-0/+1
|
* Ensure we always grab the gdk lock in async callbacksAlexander Larsson2011-03-281-0/+12
| | | | | | Async callbacks are delivered in idles, so we need to make sure we get the gdk lock before calling any gdk/gtk stuff. This was missing in a few places.
* Plug a memleak in the tracker search engineMatthias Clasen2011-02-191-1/+1
| | | | | Patch by Vincent Untz, https://bugzilla.gnome.org/show_bug.cgi?id=642771
* gtksearchenginetracker: Update to work with libtracker-sparqlMartyn Russell2010-12-091-287/+284
| | | | libtracker-sparql is available in Tracker 0.9/0.10
* Fix compilation warning: remove unused variableJavier Jardón2010-04-151-1/+0
|
* tracker-search-engine: Fixed whitespace issues and copyright/authorsMartyn Russell2010-04-131-49/+59
|
* tracker-search-engine: Improve search query to order by rank and titleMartyn Russell2010-04-131-4/+4
|
* tracker-search-engine: Fixed 0.7/0.8 issues and add 0.9 casesMartyn Russell2010-04-131-42/+42
|
* Support for tracker 0.8 stable releaseTomas Bzatek2010-04-071-4/+9
|
* search: update for tracker 0.8 APITomas Bzatek2010-03-191-35/+128
| | | | | | Tracker 0.8 series (and late 0.7.xx) introduces new API based on SPARQL query language. The queries here use fulltext search, just like with with previous tracker versions. Old tracker 0.6 support is still maintained.
* Support tracker 0.7Jürg Billeter2009-09-301-28/+67
| | | | | Make GtkSearchEngineTracker work with libtracker 0.6 and 0.7. See bug 596081.
* Include "config.h" instead of <config.h> Command used: find -nameJohan Dahlin2008-06-221-1/+1
| | | | | | | | | | | | 2008-06-21 Johan Dahlin <jdahlin@async.com.br> * *.[ch]: Include "config.h" instead of <config.h> Command used: find -name \*.[ch]|xargs perl -p -i -e 's/^#include <config.h>/#include "config.h"/g' Rubberstamped by Mitch and Tim svn path=/trunk/; revision=20669
* check that tracker is actually working before using it. Fixes bug #479197.Josselin Mouette2008-05-251-0/+15
| | | | | | | | * gtk/gtksearchenginetracker.c: (_gtk_search_engine_tracker_new): check that tracker is actually working before using it. Fixes bug #479197. svn path=/trunk/; revision=20149
* Search libtrackerclient.so.0 as libtracker changed the shared libraryEmmanuele Bassi2007-09-181-2/+8
| | | | | | | | | | 2007-09-18 Emmanuele Bassi <ebassi@gnome.org> * gtk/gtksearchenginetracker.c: Search libtrackerclient.so.0 as libtracker changed the shared library name. (#478173, Michael Kuhn) svn path=/trunk/; revision=18846
* Remove the MIME type calls and queries from the search engineEmmanuele Bassi2007-06-221-81/+18
| | | | | | | | | | | | | | 2007-06-22 Emmanuele Bassi <ebassi@gnome.org> * gtk/gtksearchenginebeagle.c: * gtk/gtksearchenginesimple.c: * gtk/gtksearchenginetracker.c: Remove the MIME type calls and queries from the search engine implementations, since we use our own GtkFileSystem to filter out basing on MIME types and we cannot query MIME types anyway. The GtkQuery private object still has MIME type, as well as location, support for future expansion. svn path=/trunk/; revision=18219
* Add search file support in the GtkFileChooser. Original patch by FedericoEmmanuele Bassi2007-05-021-0/+362
2007-05-02 Emmanuele Bassi <ebassi@gnome.org> Add search file support in the GtkFileChooser. Original patch by Federico Mena Quintero; patch updated by Matthias Clasen. See bug #344785. * gtk/gtksearchengine.[ch]: Private search engine abstraction object. * gtk/gtksearchenginebeagle.[ch]: Private search engine implementation using libbeagle (via g_module_open()). * gtk/gtksearchenginesimple.[ch]: Private search engine implementation using file tree walking. * gtk/gtksearchenginetracker.[ch]: Private earch engine implementation using libtracker (via g_module_open()). * gtk/gtkquery.[ch]: Private query object for the search engines. * gtk/gtkfilechooserprivate.h: * gtk/gtkfilechooserdefault.c: Use the GtkSearchEngine to query a search engine backend using GtkQuery; create a new operating mode, OPERATION_MODE_SEARCH, and call the common operating mode OPERATION_MODE_BROWSE; add support for virtual shortcuts inside the shortcuts model and create a new "Search" virtual shortcut. * gtk/Makefile.am: Update the build with the new files svn path=/trunk/; revision=17783