From 86374729c42dae85147d207d03903a949b27ef43 Mon Sep 17 00:00:00 2001 From: John Reck Date: Tue, 19 Jul 2011 16:10:23 -0700 Subject: Remove size from phone snapshot layout Bug: 5045575 Change-Id: Ibb15cf18214d3fd2b7ddcb4b3dceebf9ba43104c --- src/com/android/browser/BrowserSnapshotPage.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/com/android/browser/BrowserSnapshotPage.java') diff --git a/src/com/android/browser/BrowserSnapshotPage.java b/src/com/android/browser/BrowserSnapshotPage.java index a0ec5e980..095387968 100644 --- a/src/com/android/browser/BrowserSnapshotPage.java +++ b/src/com/android/browser/BrowserSnapshotPage.java @@ -218,8 +218,10 @@ public class BrowserSnapshotPage extends Fragment implements TextView title = (TextView) view.findViewById(R.id.title); title.setText(cursor.getString(SNAPSHOT_TITLE)); TextView size = (TextView) view.findViewById(R.id.size); - int stateLen = cursor.getInt(SNAPSHOT_VIEWSTATE_LENGTH); - size.setText(String.format("%.2fMB", stateLen / 1024f / 1024f)); + if (size != null) { + int stateLen = cursor.getInt(SNAPSHOT_VIEWSTATE_LENGTH); + size.setText(String.format("%.2fMB", stateLen / 1024f / 1024f)); + } long timestamp = cursor.getLong(SNAPSHOT_DATE_CREATED); TextView date = (TextView) view.findViewById(R.id.date); DateFormat dateFormat = DateFormat.getDateInstance(DateFormat.SHORT); -- cgit v1.2.3