简体   繁体   English

如何在eclipse启动时以编程方式加载所需的插件

[英]How to programmatically load a desired plugin on eclipse start up

是否在SWT中有任何方法可以在eclipse IDE启动时以编程方式将我的插件设置为默认值,即当eclipse启动时,所需的插件被设置为透视。

If I remember correctly, it should be possible with setDefaultPerspective(String id) . 如果我没记错的话,应该可以使用setDefaultPerspective(String id)

You can access this via: 您可以通过以下方式访问:

PlatformUI.getWorkbench().getPerspectiveRegistry().setDefaultPerspective(id);

However , be careful when doing this. 但是 ,这样做时要小心。 I can imagine that a lot of people might uninstall your plugin, just because they are annoyed by this small change. 我可以想象很多人可能会卸载你的插件,只是因为他们对这个小小的改变感到恼火。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM