VMware Cloud Community
SolidFireMike
Contributor
Contributor
Jump to solution

vCenter HTML5 plugin.xml icon

I'm converting my existing Flex plug-in to HTML 5.  I've eliminated the Flex portion and implemented the HTML5 portion.

Everything works great except for one thing.  I can't get an icon to show up.  In my plugin.xml file for the <icon> tag

I've tried

../../assets/images/Company-Icon-N-16x16.png

../assets/images/Company-Icon-N-16x16.png

/assets/images/Company-Icon-N-16x16.png

/vsphere-client/company-war-4.0.0-SNAPSHOT/assets/images/Company-Icon-N-16x16.png

company-war-4.0.0-SNAPSHOT//assets/images/Company-Icon-N-16x16.png

/vsphere-client/company-war-4.0.0-SNAPSHOT/assets/images/Company-Icon-N-16x16.png

Here's a plugin.xml snippet:

<plugin id="com.company.MyCompany">

    <!-- Global Config view -->  

   <extension id="com.company.views.global.GlobalSolidFireJS">

      <extendedPoint>vise.global.views</extendedPoint>

      <object>

         <name>Company Configuration</name>

         <icon>../../assets/images/Company-Icon-N-16x16.png</icon>

         <componentClass className="com.vmware.vsphere.client.htmlbridge.HtmlView">

            <object>

                <root>

                    <url>/vsphere-client/company-war-4.0.0-SNAPSHOT/index.html</url>

                </root>

            </object>

         </componentClass>

      </object>

      <metadata>

            <privilege>Datastore.AllocateSpace,Datastore.Browse,Datastore.Delete,Datastore.DeleteFile,Datastore.FileManagement,Datastore.Move,Datastore.Rename</privilege>

      </metadata>     

   </extension>

What's a programmer got to do to get any icon to show up?

I would prefer NOT to have a .properties file, just the path to the file.

I also noticed that the HTML5 samples in the SDK have both src/main/locale and src/main/webapp/locales/en_US directories with property files in each.

This is confusing to me.

   Best Regards,

       Michael

Reply
0 Kudos
1 Solution

Accepted Solutions
_vladi_
VMware Employee
VMware Employee
Jump to solution

Hi Mike,

This is NOT the case!

I am sorry that you received such an answer on your query, it was probably a misunderstanding.

Icons are a core feature for properly displaying plugins on the vSphere HTML Client.

The way it's done is documented in vSphere 6.5 official documentation. Please check the Programming guide and search for "plugin-icons.css" string. There are 2 separate chapters that treat this topic in addition to a full guide of ensuring plugin compatibility to a particular release.

As you are migrating now I would highly recommend using the latest vSphere Client SDK 6.7 that is public since yesterday and contains a lot of new APIs, samples and recommendations. Please check this thread: https://code.vmware.com/forums/4974#586712|4188108

Cheers,

Vladimir

View solution in original post

Reply
0 Kudos
3 Replies
SolidFireMike
Contributor
Contributor
Jump to solution

For anyone else curious about this issue, I opened a Service Ticket and got the response that plug-in icons are not supported in the HTML client...    SAD.

Reply
0 Kudos
_vladi_
VMware Employee
VMware Employee
Jump to solution

Hi Mike,

This is NOT the case!

I am sorry that you received such an answer on your query, it was probably a misunderstanding.

Icons are a core feature for properly displaying plugins on the vSphere HTML Client.

The way it's done is documented in vSphere 6.5 official documentation. Please check the Programming guide and search for "plugin-icons.css" string. There are 2 separate chapters that treat this topic in addition to a full guide of ensuring plugin compatibility to a particular release.

As you are migrating now I would highly recommend using the latest vSphere Client SDK 6.7 that is public since yesterday and contains a lot of new APIs, samples and recommendations. Please check this thread: https://code.vmware.com/forums/4974#586712|4188108

Cheers,

Vladimir

Reply
0 Kudos
SolidFireMike
Contributor
Contributor
Jump to solution

Thanks for the info.

We have icons!!

Reply
0 Kudos