Add "added" information to the Apk list in AppDetails if available

Just place it below the status for the time being until a more pleasing
layout can be created.
This commit is contained in:
Kevin Everets 2012-07-16 15:05:42 -04:00
parent d6015fe77c
commit 6d0b5d2d8e
2 changed files with 15 additions and 1 deletions

View File

@ -40,4 +40,11 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_width="wrap_content" /> android:layout_width="wrap_content" />
<TextView android:id="@+id/added"
android:textSize="12sp"
android:layout_below="@id/status"
android:layout_alignParentLeft="true"
android:layout_height="wrap_content"
android:layout_width="wrap_content" />
</RelativeLayout> </RelativeLayout>

View File

@ -117,8 +117,15 @@ public class AppDetails extends ListActivity {
} else { } else {
buildtype.setText("bin"); buildtype.setText("bin");
} }
TextView added = (TextView) v.findViewById(R.id.added);
if (apk.added != null && !apk.added.equals("")) {
added.setVisibility(View.VISIBLE);
added.setText(apk.added);
} else {
added.setVisibility(View.GONE);
}
if (!compatChecker.isCompatible(apk)) { if (!compatChecker.isCompatible(apk)) {
View[] views = { v, version, status, size, buildtype }; View[] views = { v, version, status, size, buildtype, added };
for (View view : views) { for (View view : views) {
view.setEnabled(false); view.setEnabled(false);
} }