i have a view in relativeleayout , I want to change the place of the view to the middle of relativeleayout: what I do ?
the xml :
<RelativeLayout
android:id="@+id/partieoption"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:weightSum="6"
android:orientation="horizontal" >
<ImageView
android:id="@+id/photo2"
android:src="@drawable/loglog"
android:layout_width="50dp"
android:layout_height="50dp"
/>
</RelativeLayout>
and
RelativeLayout partieoption = (RelativeLayout) findViewById(R.id.partieoption);
ImageView x = (ImageView) findViewById(R.id.photo2);