On 30 sep, 17:22, Peli <[EMAIL PROTECTED]> wrote:
> I don't know if this would help you, but one way is to read the number
> of 
> sensorshttp://code.google.com/android/reference/android/hardware/SensorManag...()
> . This is 0 on the emulator, and should be some number >0 on a real
> device, provided that the device has sensors (which the G1 will have
> at least).
That indeed could work, but it's not future proof.
>
> By "name" of the device, do you mean its 
> IMEI?http://code.google.com/android/reference/android/telephony/TelephonyM...()
Actually the name like "T-Mobile G1" or something like that. WiMo
devices have such a name. Like the HTC Wizard is named: "WIZA200"
>
> Peli
>
> On Sep 30, 4:14 pm, MrSnowflake <[EMAIL PROTECTED]> wrote:
>
> > Is there a way to detect wether a activity is running on the emulator
> > or on a real device? And if so, can we detect what the name of the
> > device is?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to