我开发了 MS Office 插件,它通过以下方式扩展功能区:
<customUI xmlns="http://schemas.microsoft.com/office/2006/01/customui" loadImage="GetImage" onLoad="OnRibbonLoad">
<ribbon>
<tabs>
<tab idMso="TabHome">
<group id="MyAppGroup" label="MyApp">
<splitButton id="SaveSplitButton" size="large" getEnabled="GetSaveButtonEnabled">
<menu id="SaveMenu" label="Save" itemSize="normal">
<button id="SaveMenuButton" image="save.png" label="Save to MyApp" onAction="SaveCommand" screentip="Saves the document" />
<button id="SaveAsMenuButton" label="Save to MyApp As" onAction="SaveAsCommand" screentip="Saves the document under a new name" getEnabled="GetSaveAsButtonEnabled"/>
</menu>
</splitButton>
</group>
</tab>
</tabs>
当我转到“文件”>“选项”>“自定义功能区”(在任何 Office 应用程序中)时,我希望在“主页”选项卡中看到“MyApp”组,其中一个“保存”菜单只有一个“保存到 MyApp”和一个“保存到 MyApp 为"里面的子项。但相反,我在“保存”菜单下将“ 保存到 MyApp”项加倍。
我知道如果我将菜单中的“SaveMenuButton”直接移动到 splitButton 中,那么我将摆脱这种加倍,但我需要菜单中的这两个选项。
专家!请帮忙!