Sherlock Actionbar を実装しました。現在、動的に変化するテキストビューが 1 つあります。3 つのテキスト ビューを右端と中央に、最後のテキスト ビューを左端に設定したいのですが、どうすればこれを達成できますか? これを実装する方法はありますか?アクションバーの左端に現在表示されているテキストビューのコードです。
mActionBar = getSupportActionBar();
mActionBar.setDisplayShowHomeEnabled(false);
mActionBar.setDisplayShowTitleEnabled(false);
mInflater = LayoutInflater.from(this);
mCustomView = mInflater.inflate(R.layout.actiontext, null);
mTitleTextView = (TextView) mCustomView.findViewById(R.id.menutesttext);
mActionBar.setCustomView(mCustomView);
mActionBar.setDisplayShowCustomEnabled(true);
テキストビュー用の私のxmlファイルは
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/expand_activities_button"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_gravity="center"
android:clickable="false"
android:focusable="true"
android:addStatesFromChildren="true">
<TextView android:id="@+id/menutesttext"
android:layout_width="82dp"
android:layout_height="20dp"
android:layout_gravity="center"
android:gravity="center"
android:text="Testing"/>
</FrameLayout>
今私が欲しいのは、このフレームレイアウトに別の2つのテキストビューを設定し、アクションバーで調整できるようにすることです。
TEXTVIEW1 TEXTVIEW2 TEXTVIEW3
上記の方法で3つのテキストビューを実装したいだけです。