android

Android Drag/Animation of Views

I'm not a programmer, but I'm trying to learn android development, and having a blast. Lately I've hit a fork in the road, and I don't know that any of the directions I can identify will meet all my needs. This is where you (the experts) can help ;) Endpoint: I want to have the user touch a ball, and drag it to any location on the sc...

How to display a website and a button in one activity?

I'm making an application that contains button's and those buttons control an embedded browser. My problem is that I want to see the button's and the web page in the same layout, but when i click on a button this will open a web page and don't show the button, can anyone help me? ...

Can't reach an updateSelection on my inputMethodService when using the device's Browser

Hi, I'm developing a custom keyboard and when I use the device's Web Browser for some reason the text box doesn't update it's selection. It should perform an updateSelection on my InputMethodService, and go through my method onUpdateSelection, like it does on the others applications like the sms app for example. Can anybody tell me which...

Android: read a GZIP file in the ASSETS folder

How can you read GZIP file in Android located in the "ASSETS" (or resources/raw) folder? I have tried the following code, but my stream size is always 1. GZIPInputStream fIn = new GZIPInputStream(mContext.getResources().openRawResource(R.raw.myfilegz)); int size = fIn.available(); for some reason the size is always 1. But if Idon't ...

do i need to install sqlite?

Do i need to install sqlite for android or its already installed while installing all the plugin. I was trying to run the application MJAndroid, example in O'Reilly book but i am getting error in the file where the application is trying to extend SQLiteCursor Class. EDIT This is the Error Tree.. I am an absolute beginner to android ED...

What is the difference between Android SDK 1.5 and 2.0 in terms of rendering?

I am nearly finished with the development of an Android application. But there seems to be a problem. When I started working on the project I used only the default 1.5 device resolution which is 320x480. But now when I am in the testing phase I started testing in 480x800 and 480x854 in both 1.5 and 2.0. These resolutions are not defined ...

Is it better to create the db/tables programmatically or through a .db file in assets

Hi, does Android have a "best practices" guideline on creating & populating the db/tables programmatically vs. deploying a .db file in assets? What are the pros/cons of both approaches? I have a db with big long strings in several columns, and about 50 rows, so writing the insert statements alone would take quite some space. It see...

Where is the temp folder in android device?

where is located the temp folder in the android phones??? ...

How do I write outputs to the Log in Android?

I want to write some debugging output to the log to review it with logcat. If I write something to System.out this is already displayed in logcat. What is the clean way to write to the log and add levels and tags to my output? ...

how to play native camera sound on Android

I would like to play native camera shutter sound clip on camera preview capture. I'm referring to the sound clip played when takePicture() is called. How could I that? Can someone walk me through the steps? Thanks! ...

backlight manipulation in Android

Hi Could someone show me in a snipet of code how to set the backlight always on in android ? ...

Can I use assert on Android devices?

I want to use the assert keyword in my android apps to destroy my app in some cases on the emulator, or my device during testing. Is this possible? It seems that the emulator just ignores my asserts. ...

Android Camera JpegPictureCallback with varying input data size problem when takePicture() is called

I called takePicture() and pass it a PictureCallback as a JpegPictureCallback. I'm seeing byte[] data input varies in size within onPictureTaken(). Can someone explain why this byte[]'s content size varies? I'm already setting picture size to a constant size with Camera.Parameters.setPictureSize(); Thanks! ...

loading google maps data into searchable data structure

For my CS bachelors I am doing a Senior project using android and google maps. My vision was to do a (relatively) simple Dijkstra shortest path using google maps road data. I was going to add elevation change along with 2D distance. I am doing well playing with maps in android but I am completely stumped trying to access google maps dat...

Rendering Microsoft Surface Identity Tags in Java for Android

I want to write an application for Android devices that interacts with the surface and I need to be able to have the Android device display Microsoft Surface Identity Tags. I was able to create a class to draw the Byte Tags using the Byte Tag documentation but all I could find for the Identity Tags was this MSDN documentation and it doe...

[Android] How to make a dynamic layout with clickable text, checkboxes and buttons?

Give me please an advise, I want to make a dynamic layout which contains mixed elements [text] [checkbox] [button] [text] [checkbox] [button] [text] [checkbox] [button] ...... Can you give me some sample code, please ...

Testing dialog in Android's ActivityUnitTestCase

I'm trying to test an Activity in android which will show a ProgressDialog and everything works fine in the App, however when I try to use ActivityUnitTestCase and the test causes the Activity to show the dialog it fails with this error: android.view.WindowManager$BadTokenException: Unable to add window -- token null is not for an appli...

backlight in android

Hello In my android app , I have a menu for backlight options ,and I want that when the user selects one like " during this operation " to have the backlight on during that operation. Could I be be shown a way of accomplishing this . My problem is the that I don't know how to manipulate the backlight and how to properly arrange this ...

euml2 and android wont work together

i have the problem that i need an uml editor for eclipse and i think the only good one is eUml2 but i cant use it when i have installed the android plugin. when i install both with the update mechanism, their gui elements and everything else just disapears. does anybody know this problem or has any tips for me how to solve this plugin co...

Business listing in Android App

Hello stackoverflow community! I'm trying to find a way to do a search via keywords from my Android app and then get back a list of business (name, address). Including a local business listing is a plus! Any good advice to look for it or key methods to know of? ...