dojo tabbar是通过编程创建的,但没有固定在正确的位置
我以编程方式创建了一个dojo选项卡栏,并设置了fixed:“bottom”属性,但选项卡栏是在现有文档下方创建的,而不是固定在窗口底部。在我完成另一个视图的性能转换后,它正确地固定在底部 我是这样做的:dojo tabbar是通过编程创建的,但没有固定在正确的位置,dojo,fixed,tabbar,dojox.mobile,Dojo,Fixed,Tabbar,Dojox.mobile,我以编程方式创建了一个dojo选项卡栏,并设置了fixed:“bottom”属性,但选项卡栏是在现有文档下方创建的,而不是固定在窗口底部。在我完成另一个视图的性能转换后,它正确地固定在底部 我是这样做的: function createTabbar() { var tabBar = new dojox.mobile.TabBar({id:"tabContainer", barType : "tabBar", fixed: "bottom"}).placeAt
function createTabbar() {
var tabBar = new dojox.mobile.TabBar({id:"tabContainer", barType : "tabBar", fixed: "bottom"}).placeAt(dijit.byId("mobileView"));
var tabBarButtonNodes = new dojox.mobile.TabBarButton({label:"Knoten", id:"tabBarButtonNodes", moveTo:"divNodes0", icon1 : "img/nodes_60.png", icon2 : "img/nodes_60.png"}).placeAt(tabBar.domNode);
var tabBarButtonInfo = new dojox.mobile.TabBarButton({label:"Info", id:"tabBarButtonInfo", moveTo:"divInfo", icon1 : "img/info_60.png", icon2 : "img/info_60.png"}).placeAt(tabBar.domNode);
var tabBarButtonLogin = new dojox.mobile.TabBarButton({label:"Login", id:"tabBarButtonLogin", moveTo:"divLogin", icon1 : "img/login_60.png", icon2 : "img/login_60.png"}).placeAt(tabBar.domNode);
var teest = dijit.byId("divInfo");
tabBar.resize();
}
我还需要调整其他大小吗?如文件所述,“固定”标志仅适用于dojox/mobile/ScrollableView。有两种情况:整个应用程序级别的页眉/页脚,以及给定ScrollableView级别的本地页眉/页脚。您可以在此处找到详细信息:
- 本地视图页眉/页脚:
- 全局应用程序页眉/页脚:
Adrian我已经找到了解决问题的方法,不再需要以编程方式生成选项卡栏。无论如何谢谢你!