Titanium 在窗口的标题栏中有一个按钮

Titanium 在窗口的标题栏中有一个按钮,titanium,titanium-alloy,Titanium,Titanium Alloy,我有一个标签组,它有一个标题为“Fav”的窗口 标题占据窗口顶部的一行,但是 我想把按钮放在标题栏标题旁边 多亏了迈克S 我已经更新了代码,但它不起作用 它不显示错误,但不显示按钮 我能得到更多的提示吗?是的,你可以。窗口有一个名为的方法,右侧也有一个方法。您还可以在Alloy标记中添加导航按钮: var backButton = Ti.UI.createButton({left:0, width:80, height:25, backgroundColor:'red'}); $.byFavWi

我有一个标签组,它有一个标题为“Fav”的窗口

标题占据窗口顶部的一行,但是

我想把按钮放在标题栏标题旁边

多亏了迈克S

我已经更新了代码,但它不起作用

它不显示错误,但不显示按钮


我能得到更多的提示吗?

是的,你可以。窗口有一个名为的方法,右侧也有一个方法。

您还可以在Alloy标记中添加导航按钮:

var backButton = Ti.UI.createButton({left:0, width:80, height:25, backgroundColor:'red'});
$.byFavWin.setLeftNavButton(backButton);

流行音乐
推

非常感谢。我已经测试并更新了文章。你知道吗?
var backButton = Ti.UI.createButton({left:0, width:80, height:25, backgroundColor:'red'});
$.byFavWin.setLeftNavButton(backButton);
<Alloy>
  <TabGroup>
      <Tab>
          <Window title="Title" layout="vertical" backgroundColor="white">
              <LeftNavButton>
                  <Button>pop</Button>
              </LeftNavButton>
              <RightNavButton>
                  <Button>push</Button>
              </RightNavButton>
          </Window>
      </Tab>
  </TabGroup>
</Alloy>