无法掩盖,合金钛标题栏 [英] Can't hide titlebar Titanium with Alloy

查看:165
本文介绍了无法掩盖,合金钛标题栏的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经encounterd使用MVC合金钛Appcelerator的一个问题。这个问题包含以下(见图片)

我无法取出,其中应用程序名称和标志是发现黑条。我在设备上运行的应用程序(谷歌Nexus,没有仿真)

我曾尝试以下删除此:

XML:

 <&合金GT;
    <窗​​GT;
    < /窗GT;
< /铝合金>

TSS:

 窗口:
{
    navBarHidden:真实,
    全屏:真实,
    的backgroundColor:橙色
    orientationModes:[Ti.UI.PORTRAIT]
}

TiApp.XML:

 <状态栏式>默认< /状态栏式>
<状态栏隐藏>真< /状态栏隐藏>
<全屏>真< /全屏>
<导航栏隐藏>真< /导航栏隐藏>

但这些选项都在努力隐藏此黑条。在iPhone模拟器它仅通过设置该属性删除导航栏全屏

还有其他的选择,得到这个了?在此先感谢!


解决方案

难道是展示也许是动作条?试着隐藏它。


  

要修改的主题隐藏操作栏:


  
  

      
  1. 自定义主题文件添加到您的项目:

  2.   

  
  

平台/安卓/ RES /价值/ custom_theme.xml:


 <?XML版本=1.0编码=UTF-8&GT?; <资源>
    <样式名称=Theme.NoActionBar父=@风格/ Theme.Titanium>
        !< - 根据父主题,这可以被称为机器人:windowActionBar代替windowActionBar - >
        <项目名称=windowActionBar>假LT; /项目>
    < /风格> < /资源>

来自 http://docs.appcelerator.com/titanium/ 3.0 /#!/引导/ Android_Action_Bar

I have encounterd a problem in Titanium Appcelerator using Alloy MVC. This problem contains the following(see image)

I can't remove the black bar where the app name and logo is found. I am running the app on a device(Google Nexus, no simulator)

I have tried the following to remove this:

XML:

<Alloy>
    <Window>
    </Window>
</Alloy>

TSS:

"Window":
{
    navBarHidden:true,
    fullscreen:true,
    backgroundColor:"Orange",
    orientationModes:[Ti.UI.PORTRAIT],
}

TiApp.XML:

<statusbar-style>default</statusbar-style>
<statusbar-hidden>true</statusbar-hidden>
<fullscreen>true</fullscreen>
<navbar-hidden>true</navbar-hidden>

But none of these options are working to hide this black bar. In the iOS simulator it does remove the navigation bar by only setting the property fullscreen to true

Are there other options to get this away? Thanks in advance!

解决方案

Is it the ActionBar that's showing perhaps? Try hiding it.

To modify the theme to hide the action bar:

  1. Add a custom theme file to your project:

platform/android/res/values/custom_theme.xml:

<?xml version="1.0" encoding="utf-8"?> <resources>
    <style name="Theme.NoActionBar" parent="@style/Theme.Titanium">
        <!-- Depending on the parent theme, this may be called android:windowActionBar instead of windowActionBar -->
        <item name="windowActionBar">false</item>
    </style> </resources>

Taken from: http://docs.appcelerator.com/titanium/3.0/#!/guide/Android_Action_Bar

这篇关于无法掩盖,合金钛标题栏的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆