android-emulator

Android/samsung galaxy S emulator

南笙酒味 提交于 2019-12-21 05:37:12
问题 Is there a way, to try my project on a samsung galaxy emulator, or something like that? My project work on HTC Legend, but its crashes on that device. How i can set up a samsung galaxy s on android/eclipse? I set up a W800/854 2.2 AVD but it work.. but on the samsung phone it was a crash.. 回答1: The odd thing with Galaxy S is the presence of two external storages. This can not be emulated in AVD. More over current Android SDK lacks support for two storages. At least this was the issue with my

Why I can not set onClickListener for a button in a dialog view?

拥有回忆 提交于 2019-12-21 05:36:14
问题 I have a custom dialog which described below. My Custom Dialog layout ( *my_dialog.xml* ) which only contain a "dismiss" button: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center_horizontal" > <Button android:id="@+id/dismiss_btn" android:layout_width="100dip" android:layout_height="30dip" android:layout_centerHorizontal="true"

java.lang.RuntimeException: createWindowSurface failed EGL_BAD_ALLOC in android

◇◆丶佛笑我妖孽 提交于 2019-12-21 05:16:36
问题 I created customized Galaxy S4 AVD with 1080x1920 for my application. I can able to run my application in that AVD. After few seconds its blinking and its throws some error like this. 02-05 12:06:39.809: E/EGL_emulation(829): rcCreateWindowSurface returned 0 02-05 12:06:39.809: E/EGL_emulation(829): tid 829: eglCreateWindowSurface(631): error 0x3003 (EGL_BAD_ALLOC) 02-05 12:06:39.819: D/AndroidRuntime(829): Shutting down VM 02-05 12:06:39.819: W/dalvikvm(829): threadid=1: thread exiting with

Error running emulator on android

浪尽此生 提交于 2019-12-21 05:06:20
问题 I'm trying to run a phonegap app on android and when i run the command phonegap run android --emulator --verbose I am getting this error Running command "getprop emu.uuid" on emulator-5554... How do i fix this, any ideas? I tried opening it via both command line and android studio emulator hands in both. 回答1: I have found that if I manually start the AVD before issuing the run command then I do not get this error. Also I found that running an older version of android solves this issue. I do

android execution in emulator or device?

放肆的年华 提交于 2019-12-21 05:06:16
问题 Is there any way to know if my application is running on the emulator or on the device ? 回答1: I am using this code snippet which works on both Intel and ARM emulators: if (Build.MODEL.contains("google_sdk") || Build.MODEL.contains("Emulator") || Build.MODEL.contains("Android SDK")) { RunsInEmulator = true; } 回答2: Secure.getString(getContentResolver(), Secure.ANDROID_ID); (where Secure is android.provider.Settings.Secure ) That value will be null on the emulator, non-null on devices. 来源: https

Android emulator doesn't use Windows host file?

空扰寡人 提交于 2019-12-21 04:32:13
问题 m3 http://img245.imageshack.us/img245/461/65254534.jpg Chrome using the windows' HOST file: m1 http://img266.imageshack.us/img266/9380/59750633.jpg Android emulator: m2 http://img821.imageshack.us/img821/7363/19470766.jpg edit "On Windows, the emulator obtains the addresses by calling the GetNetworkParams() API. Note that this usually means that the emulator ignores the content of your "hosts" file (/etc/hosts on Linux/OS X, %WINDOWS%/system32/HOSTS on Windows)." how can I use static IPs in

How to divide screen into three parts vertically?

三世轮回 提交于 2019-12-21 04:16:40
问题 I have screen with ScrollView and three different LinearLayouts . One LinearLayout contains a Spinner and second contains ListView and third contains two Buttons ( horizontal ). I want to display a screen that contains 3 LinearLayouts always displayed at bottom of screen and 1 LinearLayout always displayed on top. In middle part , i want to display ListView content. So that on whole screen there is no blank space present. I want to create screen for multiple devices which has different sizes.

Android 2.2 - How do I detect if I am installed on the SDCard or not?

六月ゝ 毕业季﹏ 提交于 2019-12-21 04:05:05
问题 I am writing an android app that stores a lot of media files. They are not the type (and are far too many) to clutter up the users notification or other media directories, but they also must be user-updatable, so I can't put them in the resources. I can use getExternalFilesDir to get a path on the sdcard, but I only want to do that if the app itself is installed on the sdcard. If the app is installed internally, I want to put the media in the internal memory. So how can I determine if my app

adb: error: remote object '/data/data/com.me.myproject' does not exist

人走茶凉 提交于 2019-12-21 03:42:16
问题 1. Added adb path to ~/.bash_profile export PATH="/Users/myname/Library/Android/sdk/platform-tools:$PATH" 2. Logged in to emulator adb -s emulator-5554 shell 3. changed permission of the app folder and parent folder chmod 777 /data/data/com.me.myproject chmod 777 /data/data 4. Still can not get stuff from outside. Why? adb -s emulator-5554 pull /data/data/com.me.myproject 回答1: I had the same problem and I did this: adb shell run-as com.yourPackageName (not rooted device) cp 'database/file_you

AVD Emulator stuck on loading screen in Android Studio

早过忘川 提交于 2019-12-21 03:25:35
问题 I decided to try Android Studio 2.0 having used Eclipse in the past but I'm having considerable difficulty getting the AVD to load correctly. I've done quite a bit of googling and research into the problem, both here on SO and Google.So far nothing has worked. The emulator simply hangs on the android load-up screen ever time I try to run it. I've seen it advised to use Genymotion but I would first prefer to resolve the issue natively in Android Studio to feel confident going forward using the