XML视角的目标ID

huangapple go评论28阅读模式
英文:

Target ID for XML Perspective

问题

I want my views to be available only when the XML perspective is chosen. I know I can specify this by changing the target ID of the view in the plugin.xml file, but I cannot find the target ID for the XML perspective. Does anyone know the target ID for the XML perspective?



英文:

I am creating an eclipse PDE plugin with multiple views. I want my views to be available only when the XML perspective is chosen. I know I can specify this by changing the target ID of the view in the plugin.xml file, but I cannot find the target ID for the XML perspective. Does anyone know the target ID for the XML perspective?

   <extension
         point="org.eclipse.ui.perspectiveExtensions">
      <perspectiveExtension
            targetID="org.eclipse.jdt.ui.JavaPerspective">
         <view
               id="asher.views.id.SampleView"
               relative="org.eclipse.ui.views.ProblemView"
               relationship="right"
               ratio="0.5">
         </view>
      </perspectiveExtension>

答案1

得分: 0

你的视图将始终在每个视角中可用,但你要查找的 ID 是 "org.eclipse.wst.xml.ui.perspective"。你可以在 https://github.com/eclipse/webtools.sourceediting/blob/9a52e4d9b40b6340b0e2c72ee523bf603881cfb1/xml/bundles/org.eclipse.wst.xml.ui/plugin.xml#L1489 找到它的声明。

英文:

Your view will always be available in every perspective, but the ID you're looking for is "org.eclipse.wst.xml.ui.perspective". You can find where it's declared at https://github.com/eclipse/webtools.sourceediting/blob/9a52e4d9b40b6340b0e2c72ee523bf603881cfb1/xml/bundles/org.eclipse.wst.xml.ui/plugin.xml#L1489

huangapple
  • 本文由 发表于 2020年7月29日 05:21:33
  • 转载请务必保留本文链接:https://go.coder-hub.com/63142945.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定