0

I'm trying to create a slider in android using a viewpager so followed the tutorial from developper.android.com. Now everything works fine, but there is one minor detail that bothers me; every time I launch the app, a white blank screen appear briefly before the actual slides start to appear in the screen:

enter image description hereenter image description here

I think it has something to do with setContentView() method. So how can I show the slides directly at startup and skip the blank screen.

Thanks in advance

Toni Joe
  • 7,715
  • 12
  • 50
  • 69

1 Answers1

0

Never mind guys, I found the answer in this post of stack overflow, I added this line to my style.xml file and it fixed the problem:

<item name="android:windowDisablePreview">true</item>
Community
  • 1
  • 1
Toni Joe
  • 7,715
  • 12
  • 50
  • 69