Similar to previous removals of g_cclosure_marshal_VOID__VOID we can remove
other marshallers for which are a simple G_TYPE_NONE with single parameter.
In those cases, GLib will setup both a c_marshaller and va_marshaller for
us. Before this commit, we would not get a va_marshaller because the
c_marshaller is set.
Related to GNOME/Initiatives#10
If we set c_marshaller manually, then g_signal_newv() will not setup a
va_marshaller for us. However, if we provide c_marshaller as NULL, it will
setup both the c_marshaller (to g_cclosure_marshal_VOID__VOID) and
va_marshaller (to g_cclosure_marshal_VOID__VOIDv) for us.
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.
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.
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.
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.
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.
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.
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.
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.
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
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
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