zoukankan      html  css  js  c++  java
  • mac版 android studio问题解决

    1.mac安装android studio

    解决方案:如果你是安装新手,可以下载androud studio boundls 和 安装环境的jdk就可以了,不需要单独在配置环境了,如果你有经验,可以单独装sdk,avd manager 等等

    2.ERROR: x86 emulation currently requires hardware acceleration!

    Please ensure Intel HAXM is properly installed and usable.
    CPU acceleration status: HAXM is not installed on this machine

    解决方案 :(1)打开 sdk manager  下载 extras 下面的intel x86 enulator accelerator

    (2)finder -》应用程序 —》android studio 显示包内容 —》sdk -》extras -》intel -》Hardware_Accelerated_Execution_Manager  安装IntelHAXM_6.1.1dmg就可以解决

    3. Only the original thread that created a view hierarchy can touch its views.

     只有主线程才能更新ui

    3.单独创建Activity入口类配置

    <activity
    android:name=".FirstActivity"
    android:label="@string/app_name" >
    <intent-filter>
    <action android:name="android.intent.action.MAIN" />

    <category android:name="android.intent.category.LAUNCHER" />
    </intent-filter>
    </activity>

    4.创建Activity

    选择calss继承 extends Activity 

    实现父类方法

    @Override
    protected void onCreate( Bundle savedInstanceState){

    super.onCreate(savedInstanceState);
    setContentView(R.layout.first_layout);

    }

    5.element shape doesn't have required attribute android

    新建的shape文档不能放到layout中去,应该放倒drawable文档里面

  • 相关阅读:
    辨析六种单例模式
    理解模板模式
    常用DOM API总结
    自我剖析——一天的效率
    对两个数组合并,并去重
    Qt 创建一个QtDesinger第三方控件
    Qt中QComboBox中自定义界面使用stylesheet实现下拉按钮独立效果
    内核对象 windows操作系统
    python之基本内容
    python之总体理解
  • 原文地址:https://www.cnblogs.com/hualuoshuijia/p/6887900.html
Copyright © 2011-2022 走看看