Posts

Showing posts with the label Eclipse

Android Emulator Error: "System UI Has Stopped"

Answer : This is still "unanswered", but it probably has been resolved. I just want to share my experience and clarify a few things, some of which may not matter. Anyway, if this helps someone else that's great. 1) I had this problem on one machine (a new, but slower machine), but not another (the faster one) when running a 4.0.3 emulator. It is not a hardware problem though, and CPU speed doesn't make a difference. 2) Both machines are fully up-to-date ADT (Eclipse 4.2.x and Android 4.2.2 (API 17) SDK environments. 3) Editing, or even Deleting the emulator and then recreating it did NOT fix it. 4) The best solution is to locate and update the config.ini file. In Windows 7 (x64) I found the config.ini file in C:\Users \ [your user name] \ .android\avd\ICS_4.0.3_API_15.avd [*see AVD names below]. NOTE: First make sure you have “show hidden files, folder, or drives” turned on in Explorer or you won't see the ".android" folder. 5) Not s...

Android How To Create Intent Filter For Custom File Extension That Does NOT Make It Part Of A Chooser For Everything On The Phone

Answer : The only way to solve this problem is add scheme and host attributes to your intent filter: <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <data android:scheme="file" /> <data android:mimeType="*/*" /> <data android:pathPattern=".*\\.tgtp" /> <data android:host="*" /> </intent-filter> That is because in documentation says that android:pathPattern only works if has an scheme and host defined. http://developer.android.com/guide/topics/manifest/data-element.html Hope it helps. I've been struggling with this quite a bit for a custom file extension, myself. After a lot of searching, I found this web page where the poster discovered that Android's patternMatcher class (which is used for the pathPattern matching in Intent-Filters) has unexpected behavior when y...

Android Min SDK Version Vs. Target SDK Version

Answer : The comment posted by the OP to the question (basically stating that the targetSDK doesn't affect the compiling of an app) is entirely wrong! Sorry to be blunt. In short, here is the purpose to declaring a different targetSDK from the minSDK: It means you are using features from a higher level SDK than your minimum, but you have ensured backwards compatibility . In other words, imagine that you want to use a feature that was only recently introduced, but that isn't critical to your application. You would then set the targetSDK to the version where this new feature was introduced and the minimum to something lower so that everyone could still use your app. To give an example, let's say you're writing an app that makes extensive use of gesture detection. However, every command that can be recognised by a gesture can also be done by a button or from the menu. In this case, gestures are a 'cool extra' but aren't required. Therefore you would set ...

Adb Server Is Out Of Date. Killing... Cannot Bind 'tcp:5037' ADB Server Didn't ACK * Failed To Start Daemon * In Ubuntu 14.04 LTS

Answer : You need to set the path of your SDK's adb into Genymotion. By default, Genymotion uses its own ADB tool (for many reasons). If the both binaries are not compatible (if your Android SDK platform tools or Genymotion has not been updated for a while) this problem happens. To solve it you can define a specific one from the Android SDK. To specify a custom ADB tool: Open Genymotion > Settings > ADB. Check Use custom Android SDK tools. Specify the path to the Android SDK by clicking Browse. Click OK. update the adb to 1.0.32 if you have 1.0.31 or lower adb version Android Debug Bridge version 1.0.31 wget -O - https://skia.googlesource.com/skia/+archive/cd048d18e0b81338c1a04b9749a00444597df394/platform_tools/android/bin/linux.tar.gz | tar -zxvf - adb sudo mv adb /usr/bin/adb sudo chmod +x /usr/bin/adb adb version Android Debug Bridge version 1.0.32 for me the problem was that I am trying to use 2 adb processes sudo apt-get remove adb android-tools-adb and...

Create A New Workspace In Eclipse

Image
Answer : I use File -> Switch Workspace -> Other... and type in my new workspace name. (EDIT: Added the composite screen shot.) Once in the new workspace, File -> Import... and under General choose "Existing Projects into Workspace. Press the Next button and then Browse for the old projects you would like to import. Check "Copy projects into workspace" to make a copy. In Window->Preferences->General->Startup and Shutdown->Workspaces , make sure that 'Prompt for Workspace on startup' is checked. Then close eclipse and reopen. Then you'll be prompted for a workspace to open. You can create a new workspace from that dialogue. Or File->Switch Workspace->Other... You can create multiple workspaces in Eclipse. You have to just specify the path of the workspace during Eclipse startup. You can even switch workspaces via File→Switch workspace. You can then import project to your workspace, copy paste project to your new workspace folder...

Building With Lombok's @Slf4j And Eclipse: Cannot Find Symbol Log

Answer : You also have to install Lombok into Eclipse. See also this answer on how to do that or check if Lombok is installed correctly. Full Disclosure: I am one of the Project Lombok developers. I got the same error even after Lombok was installed. For me the solution was to add another lombok annotation (i used @Data) to my class after which the eclipse errors went away. Perhaps this force refreshed some cache. Of course, I simply deleted the @Data annotation afterwards. I also faced the similar issue on log and @Slf4j on my STS environment. To resolve this, here is what I did on spring tool suite (sts-4.4.0.RELEASE) and lombok-1.18.10.jar (current latest version available in mavenrepository). If having maven project, ensure lombok dependency added to it. Else you need manually add the jar to your project classpath. <!-- https://mvnrepository.com/artifact/org.projectlombok/lombok --> <dependency> <groupId>org.projectlombok</groupId> <artifa...