AndroidManifest.xml
<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android"       package="com.example.android.xxxx">     <application android:persistent="true"          android:label="@string/home_title"          android:icon="@drawable/ic_launcher_home">        <activity android:name="xxxxxxxx"           android:theme="@android:style/Theme.Translucent">            <intent-filter>              <action android:name="android.intent.action.LAUCHER" />                <category android:name="android.intent.category.DEFAULT" />            </intent-filter>        </activity>    </application></manifest>  xxxxxxxx.javapackage com.example.android.xxxx; public class fpToolbar extends Activity {     @Override    public void onCreate(Bundle savedInstanceState) {       super.onCreate(savedInstanceState);       requestWindowFeature(Window.FEATURE_NO_TITLE);    LinearLayout layout2;    layout2 = new LinearLayout(this);        Button b = new Button(this);    Button b2 = new Button(this);    layout2.addView(b);    layout2.addView(b2);     layout2.setGravity(Gravity.BOTTOM | Gravity.LEFT);    layout2.setBackgroundDrawable(null);    /* 设置成透明,必须在AndroidManifest.xml中设置android:theme="@android:style/Theme.Translucent" */     b.setText("test pop.");    b2.setText("hello!");     setContentView(layout2);     }}


本文来自CSDN博客,转载请标明出处:http://blog.csdn.net/ccwwff/archive/2010/10/26/5965668.aspx

更多相关文章

  1. android 跳转到当前应用的详情页面
  2. NotificationCompat.Builder deprecated in Android(安卓)O
  3. android studio AndroidManifest.xml命名空间报错问题
  4. 点击LinearLayout使用selector改变TextView字体颜色
  5. android sqlite 实例
  6. Android: Actions for BroadcastReceiver
  7. Android(安卓)单击listview弹出popupwindow弹出框
  8. Canonical 宣布 Ubuntu for Android(安卓)项目
  9. 分析脚本文件AndroidInitProcess分析心得(1)

随机推荐

  1. Android(安卓)中使用 dlib+opencv 实现动
  2. Kotlin For Android简介——有趣实用的功
  3. Android(安卓)API Guides---Making Appli
  4. Android(安卓)分享功能,过滤掉不需要的组
  5. Android消息机制之HandlerThread
  6. 按下电源键到启动Home应用过程详解(一)
  7. Android的4种基本布局
  8. 关于Unity与Android通信与交互
  9. IOS和Android开发的一些个人感受
  10. android开发笔记之animation(一)