Go to file
Jonas Dreßler 68e3f74ffd search: Don't use max number of results if allocation width is 0
Since commit 1a27ff6130 we use the
allocation width of the GridSearchResults actor to calculate the max
number of results that can be shown for this search provider.

On the first run of the search, when no previous (cached) allocation is
available for the actor of GridSearchResults, the allocation width used
in `_getMaxDisplayedResults` will be 0, which in turn will make
`updateSearch` filter out all results returned by the search provider.

Now if this search provider is the only search provider that's enabled,
after calling `updateSearch`, the `SearchResults` class will call
`_updateSearchProgress` to check if any results are visible, assume
nothing was found and therefore hide the scrollView. This in turn causes
the GridSearchResults actor to not get a new allocation, which prevents
our code to fixup the max number of results on `notify::allocation` from
working: The number will continue to be 0 and we'll never show any
results.

To fix this regression, return -1 in `_getMaxDisplayedResults` if the
allocation width is 0 to inform `updateSearch` that we can't calculate
the maximum number yet and interpret a return value of -1 as "show all
results" in `updateSearch`. The same problem would probably also appear
if the allocation width is anything between 0 and the width of the
iconGrid with one icon in it, although this might as well be a valid
width in case a very small screen is used or with very large icons. So
let's only check for a width of 0 and hope the GridSearchResults actor
won't get weird temporary allocations in that range.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/672
2019-08-08 17:37:12 +00:00
.gitlab-ci ci: Make eslint wrapper script usable outside gitlab's CI 2019-07-31 23:28:43 +02:00
.settings Clean out some eclipse artefacts 2019-02-13 04:39:26 +01:00
data dateMenu: Stop accessing app settings directly 2019-08-08 17:41:46 +02:00
docs/reference docs: Fix interface prefix for D-Bus docs 2019-07-25 15:56:20 +02:00
js search: Don't use max number of results if allocation width is 0 2019-08-08 17:37:12 +00:00
lint lint: Allow marking variables/arguments as unused 2019-07-24 00:28:45 +02:00
man man: Update project website 2018-01-07 21:39:18 +01:00
meson build: Run postinstall script where necessary 2018-04-09 19:19:33 +00:00
po Update Indonesian translation 2019-08-06 10:49:56 +00:00
src shell/app-system: Monitor for icon theme changes 2019-08-08 15:22:44 +00:00
subprojects gvc: Update submodule to up-to-date version 2019-02-28 21:59:08 +01:00
test Add convert_xml test 2019-03-04 20:55:15 +00:00
tests tests: Add Params.parse() unit tests 2019-07-05 18:28:26 +02:00
tools build: Remove Canberra dependency 2019-01-09 23:09:18 +00:00
.eslintrc.json lint: Tweak the whitelist of globals 2019-07-12 16:01:07 +00:00
.gitignore Ignore '.vscode' folder for users of that editor 2019-04-02 17:37:31 +00:00
.gitlab-ci.yml ci: Remove path limitation of js60 check 2019-07-25 22:37:22 +02:00
.gitmodules submodules: Replace non-functional git.gnome.org URL by GNOME Gitlab URL 2018-09-25 08:41:30 +02:00
cldr2json.py Fix override for fr-CA 2019-03-04 20:55:15 +00:00
config.h.meson Add check_cloexec_fds debug command 2018-07-30 23:11:41 +00:00
COPYING Changed obsolete FSF postal address. 2014-01-08 04:35:14 +07:00
gnome-shell.doap Replace Bugzilla by Gitlab URL in DOAP file 2018-12-15 23:26:54 +01:00
HACKING.md docs: Update animation section 2019-08-07 18:40:49 +02:00
meson_options.txt Remove the browser plugin 2018-12-31 13:25:05 -06:00
meson.build meson: Avoid using relative paths to po directory 2019-08-05 21:38:51 +00:00
NEWS Bump version to 3.33.4 2019-07-20 17:47:10 +02:00
README.md README.md: Add contribution section 2019-02-13 20:37:39 +01:00
README.mdwn Add basic documentation 2019-03-04 20:55:15 +00:00

GNOME Shell

GNOME Shell provides core user interface functions for the GNOME 3 desktop, like switching to windows and launching applications. GNOME Shell takes advantage of the capabilities of modern graphics hardware and introduces innovative user interface concepts to provide a visually attractive and easy to use experience.

For more information about GNOME Shell, including instructions on how to build GNOME Shell from source and how to get involved with the project, see the project wiki.

Bugs should be reported to the GNOME bug tracking system.

Contributing

To contribute, open merge requests at https://gitlab.gnome.org/GNOME/gnome-shell.

Commit messages should follow the GNOME commit message guidelines. We require an URL to either an issue or a merge request in each commit.

License

GNOME Shell is distributed under the terms of the GNU General Public License, version 2 or later. See the COPYING file for details.