2

I have a tab bar in my application, with third tab named About. When user clicks on this About tab, I want activity to be displayed with blur effect. More specifically, About activity should be on front, while previous tab should be displayed behind with blur effect. I did the following code in the about.java onCreate Method, but it opens new window and the previous windows are not being displayed.

public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        //This is the code used to add blur effect
        getWindow().setFlags(WindowManager.LayoutParams.FLAG_BLUR_BEHIND,
                WindowManager.LayoutParams.FLAG_BLUR_BEHIND);
        setContentView(R.layout.about);
}

If I do it without tab bar it works. Any suggestions on what might be going wrong or how to do it in a different way?

Monolo
  • 18,057
  • 17
  • 66
  • 103
Shah
  • 4,910
  • 10
  • 46
  • 70

1 Answers1

2

I solved the problem. I added few of the Styles in res/value/styles.xml file and added the theme in AndroidMenifest.xml file.

Oak Bytes
  • 4,489
  • 4
  • 34
  • 52
Shah
  • 4,910
  • 10
  • 46
  • 70