How to create a DialogFragment without title?

后端 未结 6 1808
时光说笑
时光说笑 2020-11-29 15:50

I\'m creating a DialogFragment to show some help messages regarding my app. Everything works fine besides one thing: There is a black stripe at the top of the window that sh

6条回答
  •  -上瘾入骨i
    2020-11-29 16:18

    Set the style to Theme_Holo_Dialog_NoActionBar:

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setStyle(STYLE_NORMAL, android.R.style.Theme_Holo_Dialog_NoActionBar);
    }
    

提交回复
热议问题