user1324936
user1324936

Reputation: 2187

Android Indeterminate Progress Bar not animated

I want a infinite progress bar like here under Activity Indicatior, Activity bar

http://www.google.de/imgres?um=1&hl=de&client=firefox-a&hs=H9I&tbo=d&rls=org.mozilla:de:official&biw=1280&bih=697&tbm=isch&tbnid=AX0X8So5n4iiPM:&imgrefurl=http://developer.android.com/design/building-blocks/progress.html&docid=8Hr06JHpY9T3rM&imgurl=http://developer.android.com/design/media/progress_download.png&w=760&h=348&ei=bDDgULSzELL64QTa74DgBg&zoom=1&iact=rc&dur=318&sig=116802181569187224100&page=2&tbnh=143&tbnw=265&start=35&ndsp=40&ved=1t:429,r:51,s:0,i:243&tx=131&ty=39

My implementation is not animated and not spinning. What is wrong? Thanks

<ProgressBar
    android:id="@+id/progressBar"
    style="?android:attr/progressBarStyleHorizontal"
    android:layout_width="match_parent"
    android:layout_height="wrap_content" />

Upvotes: 7

Views: 9236

Answers (2)

Wops
Wops

Reputation: 993

here's my xml, it works fine:

<ProgressBar
    android:id="@+id/progressBar1"
    style="?android:attr/progressBarStyleLarge"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_centerHorizontal="true"
    android:layout_centerVertical="true" />

Upvotes: 1

Darwind
Darwind

Reputation: 7371

Add android:indeterminate="true" to your xml - that should fix it.

Upvotes: 14

Related Questions