summaryrefslogtreecommitdiff
path: root/src/nautilus-search-engine.c
Commit message (Collapse)AuthorAgeFilesLines
* general: Uniformize case code styleAntónio Fernandes2021-07-111-0/+2
| | | | | | | | There are a few non-braced single-statement in the final cases, which have gone unnoticed until detected by a recent uncrustify update. Let's add the missing braces around single-statements even if it's the last case.
* file-utilities: Drop nautilus_file_system_is_remoteAntónio Fernandes2021-01-251-7/+3
| | | | | | | | | | | | | | | | It compares the filesystem type identifier with a hardcoded list of remote types introduced in 2015.[0] The filesystem::remote attribute has been introduced[1] to handle this, and we have been using it[2], but kept the hardcoded list in order to workaround issues with GLocalFile not setting this attribute correctly. Now that these issues have been fixed[3], we can finally drop it. [0] d3e1a71c6377343af5d61d6ded7bc4f53dfeaf53 [1] https://gitlab.gnome.org/GNOME/glib/-/commit/e57355b055217b067cd1a71340f7ea47e51d4aae [2] 99f55748ef69a68df86b9a039998ee576d59b898 [3] https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1534
* general: Run uncrustify scriptOndrej Holy2020-04-051-3/+9
| | | | | There are some style issue since the last run. Let's run it again before enabling style-check CI job.
* search-engine: Query file system to determine remotenessErnestas Kulik2018-09-251-3/+15
| | | | | | | | | | | Querying the file cache in is_recursive_search() does not guarantee that the file system field will be populated with a value, and somehow results in data races, in turn resulting in random crashes/file list corruption. Hopefully fixes https://gitlab.gnome.org/GNOME/nautilus/issues/640, closes https://gitlab.gnome.org/GNOME/nautilus/issues/632 and resolves https://gitlab.gnome.org/GNOME/nautilus/issues/602
* Undo/redo, search tests, test library and moreAlexandru Fazakas2018-08-281-5/+120
|
* search-engine: move simple engine inclusion to .c fileMarco Trevisan (Treviño)2018-07-261-0/+1
| | | | No need to keep this in the header anymore
* search-engine: add a recent-search-engine listing GtkRecentManager entriesMarco Trevisan (Treviño)2018-07-261-0/+11
| | | | | | | | | | | Using GtkRecent items as search engine source in nautilus. The main reason for this, is being able to get fast results on recently-used files from the shell search provider. This is disabled when recursive searches are disabled, as there's no need to go through for recent files if no recursive (or indexed) search is enabled as the simple engine will be already fast enough, while running this engine could be just a waste.
* search-engine: add is_recursive_search function and use itMarco Trevisan (Treviño)2018-07-261-4/+31
| | | | | | | Returns whether the search should be recursive given the location and the search engine type. Using this both in tracker and simple search engines.
* search-engine-simple: remove recursive property using query flag insteadMarco Trevisan (Treviño)2018-07-261-10/+0
| | | | | | | | | | | | Compute the recursive parameter depending on the query flag for recursivity, enabling it only if the query recursive flag is NAUTILUS_QUERY_RECURSIVE_ALWAYS, while should be disabled otherwise. At this point the "recursive" property that was set only for this search engine doesn't make any sense anymore and we can safely drop it, together with the calls that were done at search-engine level to handle this special case. We move now the responsibility to to the engine itself, more than to the model.
* search-engine: Increment providers_running earlyCarlos Garnacho2017-11-051-3/+3
| | | | | | | There are chances that providers get to finish before all are added, resulting in early calls to check_providers_status() which mess up refcount. Bumping providers_running early prevents that to happen.
* Revert "search-engine: fix search providers handling"Alexandru Pandelea2017-08-171-166/+66
| | | | | | This reverts commit 37693c427941d60634bad80dd7c2d0b3a8523cea. The patch was pushed by accident.
* search-engine: fix search providers handlingAlexandru Pandelea2017-08-151-66/+166
| | | | | | | | | | | | When starting the search providers, some provider might finish before all providers are started, so a wrong value of providers_running will be used, making Nautilus crash. To fix this, keep a queue of the started providers and whenever the value of the finised/running providers is needed, check the status of each provider. https://bugzilla.gnome.org/show_bug.cgi?id=785723
* build: Make tracker a hard dependencyBastien Nocera2017-07-181-15/+2
| | | | | | | | A large number of core features require Tracker to work, and many of the new features using Tracker don't have any fallback support, failing to build when Tracker is not available, so make tracker a hard requirement. https://bugzilla.gnome.org/show_bug.cgi?id=784940
* general: format code with newer UncrustifyCarlos Soriano2016-11-301-1/+2
| | | | | Some issues were fixed, and now we can rerun Uncrustify to format correctly more part of the code.
* search-engine: port to G_DECLARE* typeSirbu Lavinia Stefania2016-10-071-66/+109
| | | | | | | | | | | | | Currently we are using the old GObject class declarations, which have two problems. One problem is that we cannot use smart pointers like g_autoptr. The other problem is the boilerplate code generated that makes the code less readable, so harder to understand. To fix this use G_DECLARE* type. https://bugzilla.gnome.org/show_bug.cgi?id=771927
* general: run uncrustifyCarlos Soriano2016-08-291-186/+207
| | | | | | | | And make the style of Nautilus the same for all files. Hopefully we can fix all the style issues we can find in the next days, so expect a little of movement on this. https://bugzilla.gnome.org/show_bug.cgi?id=770564
* general: merge libnautilus-private to srcwip/csoriano/private-to-srcCarlos Soriano2016-04-251-0/+376
And fix make distcheck. Although libnautilus-private seem self contained, it was actually depending on the files on src/ for dnd. Not only that, but files in libnautilus-private also were depending on dnd files, which you can guess it's wrong. Before the desktop split, this was working because the files were distributed, but now was a problem since we reestructured the code, and now nautilus being a library make distcheck stop working. First solution was try to fix this inter dependency of files, but at some point I realized that there was no real point on splitting some of those files, because for example, is perfectly fine for dnd to need to access the window functions, and it's perfectly fine for the widgets in the private library to need to access to all dnd functions. So seems to me the private library of nautilus is somehow an artificial split, which provides more problems than solutions. We needed libnautilus-private to have a private library that we could isolate from extensions, but I don't think it worth given the problems it provides, and also, this not so good logical split. Right now, since with the desktop split we created a libnautilus to be used by the desktop part of nautilus, extensions have access to all the API of nautilus. We will think in future how this can be handled if we want. So for now, merge the libnautilus-private into src, and let's rethink a better logic to split the code and the private parts of nautilus than what we had. Thanks a lot to Rafael Fonseca for helping in get this done. https://bugzilla.gnome.org/show_bug.cgi?id=765543