0

我编写了一个 Eclipse 插件,当它在开发运行时运行时运行良好,但是在创建更新站点并安装后,行为发生了变化。

在大多数情况下,该功能确实有效,只是似乎无法显示 2 个对话框。第一个是从 org.eclipse.jface.dialogs.PopupDialog 子类化的弹出对话框。第二个是 org.eclipse.jface.dialogs.Dialog 的子类。

这些对话框周围的其余代码似乎根本不存在,所以我认为这两个环境(开发运行时和安装的运行时)之间存在差异,这会阻止插件找到正确的类/正确显示它们。

我尝试将 org.eclipse.jface.dialogs 包添加到插件清单中,但是我找不到导入到代码中的确切包。我可以导入org.eclipse.jface.databinding.dialog,但显然不是同一个包。但是,我可以将 org.eclipse.jface 添加为插件的 feature.xml 的依赖项。这显然对我的问题没有影响。

由于它在开发中按预期工作并且我找不到任何错误消息,我不知道下一步该做什么。任何人都可以建议我可能会出错的地方吗?

亚当

* 根据要求提供更多信息* 在开发时,我将插件作为 Eclipse 应用程序运行。然后我构建了我的更新站点并将其安装到我的 RTC 版本的 Eclipse 中。正是在这一点上,它停止了工作。

当插件安装到 Eclipse 中时,它肯定会启动。我已经从 OSGi 控制台和运行它确认了这一点。对话框周围的代码执行正常。在上下文中,我有一个类进行一些 XML 处理,显示一个对话框,允许用户更改一些变量,然后继续处理。在插件的安装版本中,代码使用默认值运行start-finish,即不显示我的对话框。

在我的插件的 Manifest.MF 中,我尝试将 org.eclipse.jface 插件添加到依赖项选项卡,但它似乎没有解决问题。

我不确定 Eclipse 错误日志。我不确定在哪里可以找到这个。

我的插件的清单:

Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: RTC Scripter
Bundle-SymbolicName: RTC_Scripter;singleton:=true
Bundle-Version: 2.0.0.qualifier
Bundle-Activator: com.ibm.cics.dev.rtcscripter.Activator
Require-Bundle: org.eclipse.core.resources;bundle-version="3.6.2";visibility:=reexport,
 org.eclipse.ui,
 org.eclipse.core.runtime,
 com.ibm.team.concert;bundle-version="3.0.0",
 com.ibm.team.log4j.ui;bundle-version="1.1.0",
 com.ibm.team.process.client;bundle-version="1.2.0",
 com.ibm.team.process.common;bundle-version="1.2.0",
 com.ibm.team.repository.client;bundle-version="1.1.0",
 com.ibm.team.repository.common;bundle-version="1.1.0",
 com.ibm.team.repository.common.json;bundle-version="1.1.0",
 com.ibm.team.repository.common.remoteaccess;bundle-version="1.1.0",
 com.ibm.team.repository.common.remoteaccess.auth;bundle-version="1.1.0",
 com.ibm.team.repository.common.serialize;bundle-version="1.1.0",
 com.ibm.team.repository.common.transport;bundle-version="1.1.0",
 com.ibm.team.rtc.common;bundle-version="3.0.0",
 com.ibm.team.rtc.common.scriptengine;bundle-version="2.1.0",
 com.ibm.team.workitem.client;bundle-version="2.2.0",
 com.ibm.team.workitem.common;bundle-version="2.3.0",
 org.eclipse.ui.console;bundle-version="3.5.0",
 com.ibm.team.foundation.client;bundle-version="1.1.0",
 RTC_Scripter_EMF.editor;bundle-version="2.0.0";visibility:=reexport
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Bundle-ActivationPolicy: lazy
Export-Package: com.ibm.cics.dev.rtcscripter.util.export
Import-Package: org.eclipse.core.resources
4

1 回答 1

0

首先检查链接或插件安装程序,了解版本和您使用的 Eclipse。因为有很多日食所以它必须是合适的。

于 2012-06-27T09:10:50.933 回答