Re: How to determine firefox icon?
- From: "Jasper St. Pierre" <jstpierre mecheye net>
- To: Stefano Ciancio <s ciancio gmail com>
- Cc: gnome-shell-list gnome org
- Subject: Re: How to determine firefox icon?
- Date: Thu, 2 Feb 2012 11:38:22 -0500
Try: appSys.lookup_heuristic_basename('firefox.desktop');
On Thu, Feb 2, 2012 at 11:14 AM, Stefano Ciancio <s ciancio gmail com> 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<s ciancio gmail com>
>> 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
>>> gnome-shell-list gnome org
>>> http://mail.gnome.org/mailman/listinfo/gnome-shell-list
>>>
>>
>>
> _______________________________________________
> gnome-shell-list mailing list
> gnome-shell-list gnome org
> http://mail.gnome.org/mailman/listinfo/gnome-shell-list
--
Jasper
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]