获取整个Activity的layout FrameLayout frameLayout = getWindow().getDecorView().findViewById(android.R.id.content);