![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Android内容
文章平均质量分 50
2770843230
这个作者很懒,什么都没留下…
展开
-
FragmentActivity和Activity的区别
Android API文档: FragmentActivity is a special activity provided in the Support Library to handle fragments on system versions older than API level 11. If the lowest system version you support is API l转载 2016-04-27 10:04:47 · 796 阅读 · 0 评论 -
android 获取版本信息
private void getAppVersionInfo(){ try { PackageInfo pinfo = this.getPackageManager().getPackageInfo( this.getPackageName(), PackageManager.GET_CONFIGURATIONS);原创 2017-01-09 17:30:34 · 210 阅读 · 0 评论 -
android获取分辨率和密度
private void getDisplayMetrics(){ WindowManager wm = (WindowManager) getApplicationContext().getSystemService(Context.WINDOW_SERVICE); final int rotation = wm.getDefaultDisplay().getRotation原创 2017-01-09 17:27:59 · 292 阅读 · 0 评论 -
android 定时器的例子
初始化 timerHandler = new Handler(); serverRefresh = new ServerRefresh(); 1,启动定时器 private void setRefresh() { if (timerHandler != null && serverRefresh != null) { timerHandler .postDe原创 2017-01-03 15:52:57 · 353 阅读 · 0 评论 -
android 自定义广播
首先先定义一个广播action 广播actiong String flag = “android.intent.action.MyBorad” 1,接收广播 private void startReceiver() { broadcastManager = LocalBroadcastManager.getInstance(getActivity()); intentF原创 2017-01-03 15:25:11 · 266 阅读 · 0 评论 -
android 自定义弹出窗口
首先自定义一个布局文件 http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:background="@color/white" android:orientation="vertical"原创 2017-01-03 15:14:31 · 582 阅读 · 0 评论 -
android shape设置背景风格为圆角
http://schemas.android.com/apk/res/android"> android:topLeftRadius="10dp" android:topRightRadius="10dp" />原创 2017-01-03 14:27:20 · 368 阅读 · 0 评论 -
android 点击按键背景发生变化
btn_style.xml http://schemas.android.com/apk/res/android"> btn_pressed.xml http://schemas.android.com/apk/res/android">原创 2017-01-03 14:05:29 · 333 阅读 · 0 评论 -
http://blog.csdn.net/dxxs19/article/details/53572833
一、PopupWindow: Android 7.0之前,在指定位置弹出popupwindow可以用showAsDropDown(View anchor, int xoff, int yoff),showAtLocation(View parent, int gravity, int x, int y)。但在android 7.0上,用showAsDropDown()在popupwindo转载 2017-06-24 13:12:30 · 219 阅读 · 0 评论