android

Android + OpenGl + Blender, is possible?

Is possible uses Blender (or another tool) to make easy the job in works with android+opengl? Thanks, Celso. ...

I created a UI without Rokon, but I'd like to start Rokon later to run my game, any way to do this?

I started using Rokon to create the graphical portion of my game but when it was finished I had a lot of trouble creating a menu system and doing alerts with it. Discouraged, I started over without the game engine and made a nice looking UI. When the user clicks start game I want to run Rokon to load the graphics I made, but Ive tried e...

disable application from running in background

Is there any way to disable my application from running on the background? I don't want my app to run in the background, i need to completely close it when the user a done ...

Why won't my 1.6 Android app run on a 2.0 device?

My app runs targets version 1.6 (API level 4) and runs fine on the 1.6 emulator, but when I try and run it on a 2.0 phone (api level 5) it crashes. It's throwing an exception trying to inflate one of my xml layouts. A bit more debugging revealed that it crashes when trying to load my images; they can't seem to be loaded on the device. If...

Android: is View.onClick() method invoked on main UI thread?

Say that a user clicks on a Button. Is the resulting onClick() function invoked on the main UI thread of the activity? ...

Is there a tool to analyse a J2SE app's portability to Android?

I'm looking for an easy way to identify potential issues when porting a J2SE app to Android without having to go through line by line. Ideally I'd like a tool that would flag SE classes and members for which there is no Android equivalent, but if not, a crude library level flag would be sufficient. If there's no tool, is there a J2SE li...

Android - Only Version 8 (2.2 froyo) - ssl handshake failure

The below code works with HTTP(API version 7 and 8) and HTTPS (API version 7). For HTTPS (API version 8) I get error "java.io.IOException: SSL handshake failure: Failure in SSL library, usually a protocol error" Any Idea why on version 8 alone ? The code... HttpURLConnection connection = null; BufferedReader b...

Limit text length of EditText in Android

What's the best way to limit the text length of an EditText in Android? Is there a way to do this via xml? ...

Android: Does an app only have one Context object

I'm confused about the concept of the Context class. I see that it's a base class of Activity, but the Android docs also mentions the Context storing global information about the app environment. So in my app which has 3 activities, does that mean I have 3 distinct Context objects, or do they actually refer to 1 entity? Also, what is th...

How to periodically scan for bluetooth devices on android

Hi this may sound as a stupid question.But I was unable to find any answers for this, thus posting here. I am building an indoor application which continuously scans the bluetooth dongles located at different locations in a place like a mall or library.As I move in the mall with android phone in my hand I should be able to get the neare...

Android: Possible for background thread to block until UI thread finishes operation?

Is it possible for a background thread to enqueue a message to the main UI thread's handler and block until that message has been serviced? The context for this is that I would like my remote service to service each published operation off its main UI thread, instead of the threadpool thread from which it received the IPC request. ...

Use PreferenceActivity and save preferences in ContentProvider, how?

Hello, Jeff Sharkey in this post (http://goo.gl/G3wt) shows how to create save application preferences in database by hack on PreferenceActivity. It said i can use a ContentProvider, too. Can you give me an example on how to save preferences from PreferenceActivity to ContentProvider? thanks ...

Trouble loading random image on button press

What i'm trying to do is just simply have the button load an image at random. However, the button doesn't seem to be working. When i first load the activity there it works fine and there is a random image....But when i press the button it's not loading another like i need it to. Any idea what i have wrong here? It looks fine to me :/ ...

Droid behavior unable to mute

I am working on an App where I mute and un mute the microphone (it is a requirement) via code. The App works fine with other mobiles except for Droid, are you aware of any problems with Droid. audioService.setMicrophoneMute(true); This is not working in Motorola Droid. But all other mobiles. ...

Android: changing the pressed/focused ressource by code

Hello all, I am using some tweaks that allow the user to change the UI of my application with ressources from their SDCard. That's really easy and nothing special, I just use the "setImageDrawable" or "setImageBitmap". http://developer.android.com/reference/android/widget/ImageButton.html That's really cool and all my users are happy ...

outOfMemoryException in game Android

I have been writing an android game, and I finally got everything done, and it ran perfectly fine on the emulator and on my phone, which is a rooted droid, but when I put in the marketplace I began getting reports of it force closing, I had my parents put it on their phone and it force closed when they tried to click the start button in ...

Android programming question - fork/exec in Android?

Is there a standard native Android content provider that will return data listing all of the apps currently installed on the cellphone. Something like open()/readdir() on a Linux bin directory. Given that you know an app is installed on an Android cellphone, and you know that apps name, how do you launch that app from a completely diffe...

How to do an inner join in Android?

I would like to do an inner join on my database in my Android app. Is this even possible? What about a left join? I know cursor joiner exists but the documentation isn't clear at all. Can anyone provide any further insight? Thanks ...

Url encoding in Android

How do you encode an url in Android? I thought it was like this: final String encodedURL = URLEncoder.encode(urlAsString, "UTF-8"); URL url = new URL(encodedURL); If I do the above, the http:// in urlAsString is replaced by http%3A%2F%2F in encodedURL and then I get a java.net.MalformedURLException when I use the url. Thanks! ...

android Menu Item not showing text?

I have create a single item menu, but the text does not appear when it pops up, only the icon does. Am I missing a setting. <?xml version="1.0" encoding="utf-8"?> <menu xmlns:android="http://schemas.android.com/apk/res/android"&gt; <item android:id="@+id/options_menu" android:icon="@drawable/options" android:titl...