Merge change 26301 into eclair
* changes: Add aggregated badge to ContactHeaderWidget
This commit is contained in:
@@ -63,6 +63,7 @@ public class ContactHeaderWidget extends FrameLayout implements View.OnClickList
|
||||
private static final String TAG = "ContactHeaderWidget";
|
||||
|
||||
private TextView mDisplayNameView;
|
||||
private View mAggregateBadge;
|
||||
private TextView mPhoneticNameView;
|
||||
private CheckBox mStarredView;
|
||||
private FasttrackBadgeWidget mPhotoView;
|
||||
@@ -159,6 +160,8 @@ public class ContactHeaderWidget extends FrameLayout implements View.OnClickList
|
||||
|
||||
mDisplayNameView = (TextView) findViewById(R.id.name);
|
||||
mDisplayNameView.setOnLongClickListener(this);
|
||||
mAggregateBadge = findViewById(R.id.aggregate_badge);
|
||||
mAggregateBadge.setVisibility(View.GONE);
|
||||
|
||||
mPhoneticNameView = (TextView) findViewById(R.id.phonetic_name);
|
||||
|
||||
@@ -283,6 +286,13 @@ public class ContactHeaderWidget extends FrameLayout implements View.OnClickList
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Turn on/off showing of the aggregate bage element.
|
||||
*/
|
||||
public void showAggregateBadge(boolean showBagde) {
|
||||
mAggregateBadge.setVisibility(showBagde ? View.VISIBLE : View.GONE);
|
||||
}
|
||||
|
||||
/**
|
||||
* Turn on/off showing of the star element.
|
||||
*/
|
||||
|
||||
BIN
core/res/res/drawable-hdpi/ic_aggregated.png
Normal file
BIN
core/res/res/drawable-hdpi/ic_aggregated.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 883 B |
BIN
core/res/res/drawable-mdpi/ic_aggregated.png
Normal file
BIN
core/res/res/drawable-mdpi/ic_aggregated.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 671 B |
@@ -38,8 +38,24 @@
|
||||
android:layout_marginTop="5dip"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- "Name" field is locale-specific. -->
|
||||
<include layout="@layout/contact_header_name"/>
|
||||
<LinearLayout
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/aggregate_badge"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingRight="3dip"
|
||||
android:paddingTop="3dip"
|
||||
android:src="@drawable/ic_aggregated"
|
||||
/>
|
||||
|
||||
<!-- "Name" field is locale-specific. -->
|
||||
<include layout="@layout/contact_header_name"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<TextView android:id="@+id/status"
|
||||
android:layout_width="fill_parent"
|
||||
|
||||
Reference in New Issue
Block a user