Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » problems using default help->about dialog
problems using default help->about dialog [message #287111] Thu, 23 June 2005 23:03 Go to next message
Eclipse UserFriend
I am in the early stages of building an RCP application, and I am looking
at the default help->about dialog shown in the mail template example.
This is the example you get when you say File->New->Project->Plugin, and
you click "yes" when asked if this is an RCP. You make the choice to make
a mail template application. Anyway, the help->about dialog in the example
works perfectly, but when I go to implement it, I do not get the graphic
image on the left, or the text on the right. I copied in all the
pertinent files from the example application (the graphics in the root as
well as the icons directory, and the plugin.properties page that defines
aboutText. Then I implemented the plugin extension as done in the example
code. My plugin.xml follows:

<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin>

<extension
id="application"
point="org.eclipse.core.runtime.applications">
<application>
<run
class="medicalRCP.Application">
</run>
</application>
</extension>
<extension
point="org.eclipse.ui.perspectives">
<perspective
name="MedicalRCP Perspective"
class="medicalRCP.Perspective"
id="MedicalRCP.perspective">
</perspective>
</extension>
<extension
point="org.eclipse.ui.views">
<view
name="View"
allowMultiple="true"
icon="icons/sample2.gif"
class="medicalRCP.View"
id="MedicalRCP.view">
</view>
</extension>
<extension
id="product"
point="org.eclipse.core.runtime.products">
<product
application="MedicalRCP.application"
name="Medical application">
<property
name="aboutText"
value="%aboutText">
</property>
<property
name="windowImages"
value="icons/sample2.gif">
</property>
<property
name="aboutImage"
value="product_lg.gif">
</property>
</product>
</extension>

</plugin>


I was careful to check the names of the files mentioned in the plugin.xml
file, and every time I try this, I get the about item in the help menu,
but the example code says "about RCP Product". RCP PRoduct is the product
name mentioned in the plugin. Mine is named Medical application, but all
I get under the help menu is about. There is no name. When I debug the
code, right off the bat, in the run() method of the Application class, the
working code has a valid entry under Platform.getProduct(). I get null
when I pull product from Platform. I examined all the classes in the
example project, and mine matches in all pertinent respects as far as I
can tell. There are obvious differences in that the example code has
views and actions that are different from mine, but all the startup code
is the same.

Any ideas?

--PK
Re: problems using default help->about dialog [message #287117 is a reply to message #287111] Fri, 24 June 2005 04:35 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: stefan.renz.web.de

Hi Pierce,

I had the same problem some weeks ago. May be the problem is that you
didn't specify a plugin-id. (MedicalRCP)

Here is a fragment of my plugin.xml

<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin
id="DIP_Client"
name="DIP_Client Plug-in"
version="1.0.0"
provider-name="DaimlerChrysler TSS"
class="dcx.dip.client.rcp.DIPPlugin">


<requires>
<import plugin="org.eclipse.ui"/>
<import plugin="org.eclipse.core.runtime"/>
</requires>

<extension id="DIP-Client Application"
point="org.eclipse.core.runtime.applications">
<application>
<run class="dcx.dip.client.rcp.DIPApplication"/>
</application>
</extension>

... some perspectives, views and other stuff

<extension
point="org.eclipse.core.runtime.products"
id="product">
<product
name="DIP NCV3"
application="DIP_Client.DIP-Client Application">
<property
name="appName"
value="DIP NCV3"/>
<property
name="windowImages"
value="icons/vehiclemodel.gif"/>
<property
name="aboutText"
value="%aboutText"/>
<property
name="aboutImage"
value="icons/NCV3-Logo.gif"/>
<property
name="preferenceCustomization"
value="plugin_customization.properties"/>
</product>
</extension>
Re: problems using default help->about dialog [message #287129 is a reply to message #287117] Fri, 24 June 2005 09:51 Go to previous messageGo to next message
Eclipse UserFriend
Thanks for the suggestion Stefan, but that didn't do it. As per your
suggestion, I changed the beginning of my plugin.xml to the following:
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin id="MedicalRCP">

<extension
id="application"
point="org.eclipse.core.runtime.applications">
<application>
<run
class="medicalRCP.Application">
</run>
</application>
</extension>
...

but the behavior remained the same. The example plugin I created doesn't
have an ID either. The example plugin.xml follows:

<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin>

<extension
id="application"
point="org.eclipse.core.runtime.applications">
<application>
<run
class="mailTemplate.Application">
</run>
</application>
</extension>
<extension
point="org.eclipse.ui.perspectives">
<perspective
name="MailTemplate Perspective"
class="mailTemplate.Perspective"
id="MailTemplate.perspective">
</perspective>
</extension>
<extension
point="org.eclipse.ui.views">
<view
name="Message"
allowMultiple="true"
icon="icons/sample2.gif"
class="mailTemplate.View"
id="MailTemplate.view">
</view>
<view
name="Mailboxes"
allowMultiple="true"
icon="icons/sample3.gif"
class="mailTemplate.NavigationView"
id="MailTemplate.navigationView">
</view>
</extension>
<extension
point="org.eclipse.ui.commands">
<category
name="Mail"
id="MailTemplate.category">
</category>
<command
name="Open Mailbox"
description="Opens a mailbox"
categoryId="MailTemplate.category"
id="MailTemplate.open">
</command>
<command
name="Open Message Dialog"
description="Open a message dialog"
categoryId="MailTemplate.category"
id="MailTemplate.openMessage">
</command>
</extension>
<extension
point="org.eclipse.ui.bindings">
<key
commandId="MailTemplate.open"
schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
sequence="CTRL+2">
</key>
<key
commandId="MailTemplate.openMessage"
schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
sequence="CTRL+3">
</key>
<key
commandId="org.eclipse.ui.file.exit"
schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
sequence="CTRL+X">
</key>
</extension>
<extension
id="product"
point="org.eclipse.core.runtime.products">
<product
application="MailTemplate.application"
name="RCP Product">
<property
name="aboutText"
value="%aboutText">
</property>
<property
name="windowImages"
value="icons/sample2.gif">
</property>
<property
name="aboutImage"
value="product_lg.gif">
</property>
</product>
</extension>

</plugin>

So I am still at a loss. The online help talks about the
org.eclipse.core.runtime.products extension point, which the example and
my code uses, but theirs works and mine doesn't. For comparison to the
working plugin.xml shown above, my complete plugin.xml follows:

<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.0"?>
<plugin>

<extension
id="application"
point="org.eclipse.core.runtime.applications">
<application>
<run
class="mailTemplate.Application">
</run>
</application>
</extension>
<extension
point="org.eclipse.ui.perspectives">
<perspective
name="MailTemplate Perspective"
class="mailTemplate.Perspective"
id="MailTemplate.perspective">
</perspective>
</extension>
<extension
point="org.eclipse.ui.views">
<view
name="Message"
allowMultiple="true"
icon="icons/sample2.gif"
class="mailTemplate.View"
id="MailTemplate.view">
</view>
<view
name="Mailboxes"
allowMultiple="true"
icon="icons/sample3.gif"
class="mailTemplate.NavigationView"
id="MailTemplate.navigationView">
</view>
</extension>
<extension
point="org.eclipse.ui.commands">
<category
name="Mail"
id="MailTemplate.category">
</category>
<command
name="Open Mailbox"
description="Opens a mailbox"
categoryId="MailTemplate.category"
id="MailTemplate.open">
</command>
<command
name="Open Message Dialog"
description="Open a message dialog"
categoryId="MailTemplate.category"
id="MailTemplate.openMessage">
</command>
</extension>
<extension
point="org.eclipse.ui.bindings">
<key
commandId="MailTemplate.open"
schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
sequence="CTRL+2">
</key>
<key
commandId="MailTemplate.openMessage"
schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
sequence="CTRL+3">
</key>
<key
commandId="org.eclipse.ui.file.exit"
schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
sequence="CTRL+X">
</key>
</extension>
<extension
id="product"
point="org.eclipse.core.runtime.products">
<product
application="MailTemplate.application"
name="RCP Product">
<property
name="aboutText"
value="%aboutText">
</property>
<property
name="windowImages"
value="icons/sample2.gif">
</property>
<property
name="aboutImage"
value="product_lg.gif">
</property>
</product>
</extension>

</plugin>


Can anybody tell me what I am doing wrong here? The working example has a
value for Product in the Platform, and mine is null. I am pretty sure
that is the cause (or something in the plugin.xml is causing this), but I
cannot find it.

--PK
Re: problems using default help->about dialog [message #287134 is a reply to message #287129] Fri, 24 June 2005 10:30 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: stefan.renz.web.de

Did you also update your /META-INF/MANIFEST.MF

There is an entry that should match your non-defined plugin-ID (MedicalRCP)

This is a line of MANIFEST.MF in the mail-Plugin (fetched from eclipse
3.1).
...
Bundle-SymbolicName: mailplugin; singleton:=true
...
change it to
Bundle-SymbolicName: MedicalRCP; singleton:=true

I had to restart eclipse after this modification, because it didnt present
me the new product in the Launcher.

hope this will help you

Stefan
Re: problems using default help->about dialog [message #287141 is a reply to message #287134] Fri, 24 June 2005 11:44 Go to previous message
Eclipse UserFriend
I hadn't thought to check that, and fortunately Eclipse kept that file
up-to-date for me. I am using 3.1 M7 currently, and will upgrade to the
latest RC soon, but this problem is so "elementary" that I doubt it is a
platform problem. I am fairly sure I am doing something wrong.

At any rate, here is the MANIFEST.MF from the working mail template plugin
example:

Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: MailTemplate Plug-in
Bundle-SymbolicName: MailTemplate; singleton:=true
Bundle-Version: 1.0.0
Bundle-ClassPath: MailTemplate.jar
Bundle-Activator: mailTemplate.MailTemplatePlugin
Bundle-Localization: plugin
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime
Eclipse-AutoStart: true


Here is the MANIFEST.MF from my application:

Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: MedicalRCP Plug-in
Bundle-SymbolicName: MedicalRCP; singleton:=true
Bundle-Version: 1.0.0
Bundle-ClassPath: MedicalRCP.jar
Bundle-Activator: medicalRCP.MedicalRCPPlugin
Bundle-Vendor: Pierce Krouse
Bundle-Localization: plugin
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
Spring_12,
MySQL4_1,
Hibernate_303
Eclipse-AutoStart: true
Previous Topic:headless releng build getting null pointer?
Next Topic:eclipse and handling packages
Goto Forum:
  


Current Time: Wed Jul 30 21:33:09 EDT 2025

Powered by FUDForum. Page generated in 0.08793 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top