GNOME Bugzilla – Bug 655831
iconGrid: allow St.Bin as BaseIcon content
Last modified: 2015-03-05 10:18:46 UTC
BaseIcon currently accepts only a ClutterTexture as content. It'd be nice to allow St.Bin too so a spinner animation (like the one displayed in the top bar when an application is starting) could be displayed while loading the item thumbnail for instance.
This could be useful for SearchProviders providing results that can take a while to load, like downloading thumbnails from internet.
Created attachment 193659 [details] [review] iconGrid: allow St.Bin as BaseIcon content
Created attachment 193660 [details] [review] search: spinner animation in DummySearchProvider Code sample showing how to display a spinner animation in the results icon grid while loading of the item thumbnail is being deferred.
(In reply to comment #2) > Created an attachment (id=193659) [details] [review] > iconGrid: allow St.Bin as BaseIcon content This patch is more of a proof-of-concept, I don't like much the use of instanceof. I'd like to get feedback on this though, any suggestion?
I'd be really happy to get some feedback on this issue/patch. Would you please have a look Jasper?
(In reply to comment #5) > I'd be really happy to get some feedback on this issue/patch. Would you please > have a look Jasper? I really just don't understand why a lot of this is necessary.
One example use-case is to display in a grid spinning animations while items load in the background (involving thumbnail download/caching). To implement this I'd like to use panel.AnimatedIcon: icon = new IconGrid.BaseIcon(resultMeta['name']); icon.spinner = new Panel.AnimatedIcon('process-working.svg', Panel.PANEL_ICON_SIZE); icon.createIcon = function(size) { icon.spinner.actor.show(); // this is a bin. return icon.spinner.actor; }; So the grid item icon is actually a bin containing another bin but I can't see the actual icon. Now I wonder if this could actually be an issue related with the size allocation of the icon! I'll dig this a bit further.
(In reply to comment #7) > One example use-case is to display in a grid spinning animations while items > load in the background (involving thumbnail download/caching). Why not add spinner support directly to BaseIcon? I'd feel a lot better with such a change than making Base*Icon* a generic container ... > To implement this I'd like to use panel.AnimatedIcon: When used elsewhere, AnimatedIcon should probably be moved elsewhere.
(In reply to comment #8) > (In reply to comment #7) > > One example use-case is to display in a grid spinning animations while items > > load in the background (involving thumbnail download/caching). > > Why not add spinner support directly to BaseIcon? I'd feel a lot better with > such a change than making Base*Icon* a generic container ... > Good idea! I'll give this a try. > > > To implement this I'd like to use panel.AnimatedIcon: > > When used elsewhere, AnimatedIcon should probably be moved elsewhere. Alright.
Comment on attachment 193659 [details] [review] iconGrid: allow St.Bin as BaseIcon content Marking rejected as per comments
Review of attachment 193659 [details] [review]: Really marking rejected as per comments
Review of attachment 193660 [details] [review]: Not a proposed patch, marking rejected to get off review list
No movement on this in over three years, doesn't seem useful to keep open ...