开发者

activities perspective issue

I created a sample plugin which needs to hide the java perspective. For that I used activities. The problems what happends is,it is hiding from the perspectives,but it is there still in the (recent opened perspectives). How can I hide it from there also? Following is my code.

  <extension
     point="org.eclipse.ui.activiti开发者_如何学Goes">
  <activity
        id="com.example.activities.hideperspective"
        name="Hide Perspective">
  </activity>
  <activityPatternBinding
        activityId="com.example.activities.hideperspective"
        isEqualityPattern="false"
        pattern="com.example.activities.hideperspective/org.eclipse.jdt.ui.JavaPerspective">
  </activityPatternBinding>

Is this the right way what I have implemented? One more thing, This hiding of perspective I am calling when I click a Button on the toolbar. That the that buttons location is also getting changed. some kind of refresh on the toolbar.

I have attached the screenshot as well.

activities perspective issue


The activityPatternBinding is plugin.id/perspective.id, where the plugin.id is the ID of the plugin that contributed the perspective, not com.example.activities.hideperspective. Also, it does look like an equality pattern.

Also, activities will show something (like a perspective) if any activity that points to that perspective is enabled. So setting one activity to enabled=false might not get rid of the perspective.

And finally, activities won't shut a perspective that is already open. It just removes it from the "Open Perspective" dialog/shortcuts.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜