summaryrefslogtreecommitdiff
path: root/gtk/gtksearchengine.c
Commit message (Collapse)AuthorAgeFilesLines
* Intern all signal names beforehandMatthias Clasen2015-09-121-3/+4
| | | | This avoids pointless allocations
* Avoid more GFile<>uri roundtripsMatthias Clasen2015-07-271-4/+4
| | | | | | 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.
* Actually use search results from the modelMatthias Clasen2015-07-271-0/+1
| | | | | | We didn't connect to the signals, so we never picked up any search results from the model engine. Good thing, since it was returning the wrong thing.
* GtkSearchEngine: Be more robust in cancellation casesMatthias Clasen2015-07-211-3/+3
| | | | | | | When the search is cancelled, we may end up with a tracker dbus reply coming in after the GtkSearchEngine object is already gone, and bad things happen. Prevent this by using g_signal_connect_object instead of g_signal_connect.
* file chooser: Add and use a model search engineMatthias Clasen2015-07-041-2/+55
| | | | | | This search engine reuses the GFileInfo that is already loaded for the file list, to ensure that hits from the current directory always appear promptly.
* GtkSearchEngine: Avoid a crashMatthias Clasen2015-06-191-1/+2
| | | | | | | | Add a destroy notify for the data of the callback, so we don't end up leaving a dangling pointer behind for a short while if the native engine is finalized before the simple one. This was showing up as crash when typing and backspacing in the search entry of the file chooser.
* GtkSearchEngine: Avoid crawling indexed locationsMatthias Clasen2015-06-191-4/+7
| | | | | | 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: Initialize recursive flagMatthias Clasen2015-06-191-0/+2
| | | | | Otherwise all our searches become non-recursive, which was not the intention.
* GtkSearchEngine: Add recursive flagMatthias Clasen2015-06-181-0/+26
| | | | | | | 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.
* GtkSearchEngine: Remove unused codeMatthias Clasen2015-06-181-22/+0
| | | | | Nothing ever uses or emits the hits-subtracted signal. Nautilus dropped it a few years ago. Time to follow suit.
* search engine: Pass file infos along for hitsMatthias Clasen2015-06-181-3/+46
|
* GtkFileChooser: Indicate if search comes up emptyMatthias Clasen2015-05-011-6/+0
| | | | | This is a neice touch and helps to understand what is going on.
* GtkSearchEngine: Use all search enginesMatthias Clasen2015-05-011-9/+209
| | | | | | | | | Just using tracker does not work well if you are searching in non-indexed locations, such as git checkouts or network mounts. Ideally, we'd decide the 'best' engine to use for each location. Since that is not easy to do, just run them in parallel for now, which is the same strategy that nautilus uses.
* GtkSearchEngine: Drop unused functionalityMatthias Clasen2015-05-011-9/+0
|
* Drop a redundant callMatthias Clasen2015-04-301-5/+2
| | | | g_thread_supported() is always TRUE nowadays, so drop the call.
* Formatting fixesMatthias Clasen2015-02-281-53/+53
|
* GtkSearchEngine: Add debug spewMatthias Clasen2015-02-141-4/+13
| | | | | This lets us find out which search engine implementation is in use.
* Drop a pointless functionMatthias Clasen2014-05-231-11/+0
| | | | | No need to have a finalize function if it just chains up to the parent class.
* Change FSF AddressJavier Jardón2012-02-271-2/+1
|
* Fix the buildMatthias Clasen2011-11-191-13/+1
|
* Merge libgdk and libgtkMatthias Clasen2010-12-211-2/+2
| | | | | | | | | | | This commit does a number of things: - remove some dead wchar configury from configure.ac and gdkconfig.h - repurpose gdkconfig.h as header that contains GDK_WINDOWING_foo macros for each included backend, include it in gdk.h and install it in $includedir instead of below $libdir - drop the backend from the library names - build libgdk-3.0.la as a convenience lib and include it in libgtk-3.0.la It does not yet enable building multiple backends at the same time.
* 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
* Don't bother compiling gtksearchenginebeagle.c andTor Lillqvist2008-04-021-0/+6
| | | | | | | | | | | | | 2008-04-02 Tor Lillqvist <tml@novell.com> * gtk/Makefile.am: Don't bother compiling gtksearchenginebeagle.c and gtksearchenginetracker.c on Windows. * gtk/gtksearchengine.c: Don't define HAVE_BEAGLE and HAVE_TRACKER on Windows. svn path=/trunk/; revision=19959
* Add a search engine which queries the Spotlight database on MacOS X (onlyKristian Rietveld2007-06-241-0/+9
| | | | | | | | | | | | | | | | 2007-06-24 Kristian Rietveld <kris@gtk.org> * gtk/gtksearchenginequartz.[ch]: Add a search engine which queries the Spotlight database on MacOS X (only available in 10.4 and higher). * gtk/gtksearchengine.c (_gtk_search_engine_new): try creating quartz search engine if we are on OS X. * Makefile.am: added use_quartz_sources section with new file. svn path=/trunk/; revision=18222
* Fall back to GtkSearchEngineSimple only if gthread has already beenEmmanuele Bassi2007-05-111-2/+4
| | | | | | | | | | | 2007-05-11 Emmanuele Bassi <ebassi@gnome.org> * gtk/gtksearchengine.c (_gtk_search_engine_new): Fall back to GtkSearchEngineSimple only if gthread has already been initialiased; otherwise, disable search support in the file chooser widget. (#435847) svn path=/trunk/; revision=17819
* Add search file support in the GtkFileChooser. Original patch by FedericoEmmanuele Bassi2007-05-021-0/+197
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