[android] [bookmarks] fonts

This commit is contained in:
AlexeiVitenko 2013-01-07 03:20:30 +03:00 committed by Alex Zolotarev
parent 027b8a9717
commit d9ef112d5b
3 changed files with 6 additions and 17 deletions

View file

@ -7,14 +7,6 @@
android:paddingRight="5dp"
android:paddingTop="15dp" >
<TextView
android:id="@+id/psi_set_size"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:textSize="20sp" />
<TextView
android:id="@+id/psi_name"
android:layout_width="wrap_content"
@ -22,8 +14,7 @@
android:layout_alignParentLeft="true"
android:layout_centerVertical="true"
android:layout_marginLeft="5dp"
android:layout_toLeftOf="@id/psi_set_size"
android:singleLine="true"
android:textSize="25sp" />
android:textAppearance="?android:attr/textAppearanceLarge"/>
</RelativeLayout>

View file

@ -28,7 +28,8 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_toLeftOf="@id/pi_arrow" />
android:layout_toLeftOf="@id/pi_arrow"
android:textAppearance="?android:attr/textAppearanceSmall" />
<TextView
android:id="@+id/pi_name"
@ -39,6 +40,6 @@
android:layout_toRightOf="@id/pi_pin_color"
android:singleLine="true"
android:text="sdkfjsdokfjsdfosdjfisdofjsdoifjsdofji"
android:textSize="25sp" />
android:textAppearance="?android:attr/textAppearanceLarge" />
</RelativeLayout>

View file

@ -27,25 +27,22 @@ public class BookmarkCategoriesAdapter extends AbstractBookmarkCategoryAdapter
if (convertView == null)
{
convertView = LayoutInflater.from(getContext()).inflate(R.layout.bmk_category_item, null);
convertView.setTag(new PinSetHolder((TextView) convertView.findViewById(R.id.psi_name), (TextView) convertView.findViewById(R.id.psi_set_size)));
convertView.setTag(new PinSetHolder((TextView) convertView.findViewById(R.id.psi_name)));
}
PinSetHolder psh = (PinSetHolder) convertView.getTag();
BookmarkCategory set = getItem(position);
psh.name.setText(set.getName() + " ("+String.valueOf(set.getSize())+")");
//psh.size.setText();
return convertView;
}
static class PinSetHolder
{
TextView name;
TextView size;
public PinSetHolder(TextView name, TextView size)
public PinSetHolder(TextView name)
{
super();
this.name = name;
this.size = size;
}
}