Code example for WindowManager.LayoutParams

0
         
        mHandler.post(new Runnable() {
 
            public void run() { 
                mReady = true;
                WindowManager.LayoutParams lp = new WindowManager.LayoutParams(
                        LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT,
                        WindowManager.LayoutParams.TYPE_APPLICATION,
                        WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE
                                | WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE,
                        PixelFormat.TRANSLUCENT);
                mWindowManager.addView(mDialogText, lp);
            }}); 
    } 
     
    @Override 
    protected void onResume() { 
        super.onResume(); 
        mReady = true;
    }