//获取屏幕长宽WindowManager wm = (WindowManager) context.getSystemService(Context.WINDOW_SERVICE);wm.getDefaultDisplay().getHeight();wm.getDefaultDisplay().getWidth();//获取status bar高度View rootView  = view.getRootView();Rect r = new Rect();rootView.getWindowVisibleDisplayFrame(r);return r.top;//设置全屏//xml<style name="style_Fullscreen">      <item name="android:windowFullscreen">true</item>      <item name="android:windowNoTitle">true</item></style>//java codethis.requestWindowFeature(Window.FEATURE_NO_TITLE); this.getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,    WindowManager.LayoutParams.FLAG_FULLSCREEN); 

更多相关文章

  1. Android 获得屏幕宽高的三种方式
  2. Android实现屏幕截图并保存截图到指定文件
  3. 【Android Training - 02】适配不同的屏幕[Lesson 1 - 支持不同
  4. ANDROID锁屏后解锁屏幕宽高反过来了
  5. Android -- 状态栏高度
  6. android   点击屏幕让软件盘消失
  7. androidscreencast 屏幕录像

随机推荐

  1. Android开发教程 如何优化andriod布局
  2. android 判断是否有可用网络
  3. Create Native iOS, Android, Mac and Wi
  4. Android(安卓)Thread线程
  5. 获取Android系统信息
  6. android sqlite 图片保存和读出
  7. android SQLite数据库基本操作示例
  8. android使用GPS
  9. android 虚拟摇杆绘制
  10. Android 加载服务器上的图片