Added some text styles for the future.

This commit is contained in:
Robert Kolner committed 2011-09-21 17:43:06 +02:00
1 parent 3dfb28a80b
commit cdafbf2258
3 files changed
+22 -11

No files matched your search

@@ -67,12 +67,6 @@ public class ProgramListActivity extends BaseDnsActivity {
} else {
row = convertView;
}
/* Apply styles: */
if (position % 2 == 0)
row.setBackgroundResource(R.color.ListItemEven);
else
row.setBackgroundResource(R.color.ListItemOdd);
final Event e = getItem(position);
@@ -92,6 +86,17 @@ public class ProgramListActivity extends BaseDnsActivity {
}
});
/* Apply styles: */
if (position % 2 == 0) {
row.setBackgroundResource(R.color.ListItemBackgroundEven);
titleView.setTextAppearance(ProgramListActivity.this, R.style.ListItemTextEven);
dateView.setTextAppearance(ProgramListActivity.this, R.style.ListItemTextEven);
} else {
row.setBackgroundResource(R.color.ListItemBackgroundOdd);
titleView.setTextAppearance(ProgramListActivity.this, R.style.ListItemTextOdd);
dateView.setTextAppearance(ProgramListActivity.this, R.style.ListItemTextOdd);
}
return row;
}
};