Eclipse RCP fireSelectionChanged 从非 SWT 客户端
我有以下问题: 我有一个可以在其中运行任意客户端的框架。假设您有一个非 swt/非 swing 客户端,并且您想要向工作台调用 fireselectionchanged 事件。这可能吗? 再次。我无法在我的插件中获取编辑器/查看器或其他内容!
非常感谢
I have the following problem:
I have a framework in which arbitrary clients can run. Imagine you have a non-swt/non-swing client and you want to invoke a fireselectionchanged event to the Workbench. Is that possible somehow.
Once again. I am not able to get the edior/viewer or something else in my plugin!
Thank you very much
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在任何给定时间只能有一个 选择提供程序 每个工作台窗口/页面,它是由活动 工作台部分< /a>.因此,只能从视图或编辑器提供选择并通知选择更改。
虽然可以访问当前活动部件的选择提供程序并将选择设置为它...
...但不能保证 (1) 当时存在活动部件并且 (2) 活动部件的选择提供程序部分支持您想要提供的选择类型。
At any given time there can be only one selection provider per workbench window/page and it's the one provided by active workbench part. Hence, it's only possible to provide selection and notify selection change from a view or an editor.
While it is possible to access the selection provider of current active part and set selection to it...
...it's not guaranteed that (1) there is an active part at the time and that (2) the selection provider of the active part supports the type of selection that you want to provide.