fmi
fmi

Reputation: 512

My spinner isn't visible while using an imageview

I have a TabView in android. The first tab has an Image and a Spinner. The Spinner is a simple list that shows up in the first tab if there is no image, but disappears when the Image is there.

Update: I've figured out that the imageView is 'pushing' the spinner out of the frame. I just needed to make my image a "background view"

Thanks for the help

Upvotes: 1

Views: 147

Answers (2)

Adil Soomro
Adil Soomro

Reputation: 37729

It seems that you are using

LinearLayout

as base Layout which hosts ImageView and Spinner.

the default orientation of LinearLayout is horizontal..

change it to vertical just by adding

android:orientation="vertical"

to <LinearLayout > tag

Upvotes: 3

Raj
Raj

Reputation: 1872

keep the spinner inside a Layout (ex. FrameLayout) and set the image as background for that Layout.

Upvotes: 3

Related Questions