From 489c7bff5c54c35e7156a99337d538e08f3aab7f Mon Sep 17 00:00:00 2001 From: Doug Zongker Date: Fri, 25 Feb 2011 14:45:08 -0800 Subject: show Build.SERIAL in settings > about > status For wifi-only devices, this may be the only way we have to identify the device. Change-Id: I70c09e4cdb101282e5d085bcab3f57c890bc7a98 Bug: 3490911 --- src/com/android/settings/deviceinfo/Status.java | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/com/android/settings/deviceinfo/Status.java') diff --git a/src/com/android/settings/deviceinfo/Status.java b/src/com/android/settings/deviceinfo/Status.java index f171c81d9..2dd6ecdfc 100644 --- a/src/com/android/settings/deviceinfo/Status.java +++ b/src/com/android/settings/deviceinfo/Status.java @@ -25,6 +25,7 @@ import android.content.res.Resources; import android.net.wifi.WifiInfo; import android.net.wifi.WifiManager; import android.os.BatteryManager; +import android.os.Build; import android.os.Bundle; import android.os.Handler; import android.os.Message; @@ -78,6 +79,7 @@ public class Status extends PreferenceActivity { private static final String KEY_BATTERY_LEVEL = "battery_level"; private static final String KEY_WIFI_MAC_ADDRESS = "wifi_mac_address"; private static final String KEY_BT_ADDRESS = "bt_address"; + private static final String KEY_SERIAL_NUMBER = "serial_number"; private static final int EVENT_SIGNAL_STRENGTH_CHANGED = 200; private static final int EVENT_SERVICE_STATE_CHANGED = 300; @@ -236,6 +238,13 @@ public class Status extends PreferenceActivity { setWifiStatus(); setBtStatus(); + + String serial = Build.SERIAL; + if (serial != null && !serial.equals("")) { + setSummaryText(KEY_SERIAL_NUMBER, serial); + } else { + removePreferenceFromScreen(KEY_SERIAL_NUMBER); + } } @Override -- cgit v1.2.3