Try: appSys.lookup_heuristic_basename('firefox.desktop');
On Thu, Feb 2, 2012 at 11:14 AM, Stefano Ciancio <[email protected]> wrote:
> In Fedora 16 it doesn't work.
>
> JS ERROR: !!! message = '"app is null"'
>
> where app is:
>
> let app = appSys.lookup_app('firefox.desktop');
>
>
>
>
> On 02/02/2012 05:09 PM, Jasper St. Pierre wrote:
>>
>> 'firefox.desktop' should work, as we strip all vendor prefixes.
>>
>> On Thu, Feb 2, 2012 at 11:07 AM, Stefano Ciancio<[email protected]>
>> wrote:
>>>
>>> Hi all,
>>>
>>> I need to determine, in an extension, the firefox icon to show it in
>>> shell
>>> result overview.
>>>
>>> I am using this piece of code:
>>>
>>> getResultMeta: function(resultId) {
>>> let appSys = Shell.AppSystem.get_default();
>>> let app = appSys.lookup_app('mozilla-firefox.desktop');
>>>
>>> let bookmark_name = resultId.name;
>>>
>>> return { 'id': resultId,
>>> 'name': bookmark_name,
>>> 'createIcon': function(size) {
>>> return
>>> app.create_icon_texture(size);
>>> }
>>> };
>>> },
>>>
>>> but the string 'mozilla-firefox.desktop' is not correct for some distro.
>>>
>>> What is the correct method to determine the firefox icon?
>>>
>>> Thanks.
>>>
>>>
>>>
>>> _______________________________________________
>>> gnome-shell-list mailing list
>>> [email protected]
>>> http://mail.gnome.org/mailman/listinfo/gnome-shell-list
>>>
>>
>>
> _______________________________________________
> gnome-shell-list mailing list
> [email protected]
> http://mail.gnome.org/mailman/listinfo/gnome-shell-list
--
Jasper
_______________________________________________
gnome-shell-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/gnome-shell-list