elementary / applications-menu

Applications Menu for elementary OS and the Pantheon desktop environment
https://elementary.io
GNU General Public License v3.0
104 stars 36 forks source link

AppSystem: Delay and rate limit GMenu refresh #454

Closed davidmhewitt closed 3 years ago

davidmhewitt commented 3 years ago

This helps with a couple of things:

1) When you're running system updates, the desktop file database is updated many times in quick succession. This ensures we never refresh more than once every 3 seconds during that period.

2) There's a race condition between when a new desktop file is added and when its icon is available. If we wait a bit, there's less chance of us being too quick for the icon to be ready.

Also added a null check in AppListRow to prevent some criticals in the console when a null icon does occur.