android

How to exclude the title from theme applied to the application?

I'm using a theme for my app to set some common layout features. One of the things I change in this theme is the text style. I change the color and the size of the text in the whole app. Sadly the text in the titlebar is also changed and the result is a somewhat blurry ugly style. I don't know if it is the color or the size of the text...

Android mapView ItemizedOverlay setFocus does not work properly

Calling setFocus(null) on the ItemizedOverlay does not 'unfocus' current marker. According to the documentation: ... If the Item is not found, this is a no-op. You can also pass null to remove focus. Here's my code: MapItemizedOverlay public class MapItemizedOverlay extends ItemizedOverlay<OverlayItem> { private ArrayList<Ov...

How do I create persistent socket connection on Android?

Hi there, First off, let me say that feel free to recommend me if long lived TCP persistent connections are the way to go or persistent HTTP connections are better. I've also pre-read that instead of having a persistent connection, I can have a polling mechanism. I'm just asking in the curious interest of how can I create a persist...

applicaion and local service lifetime

As i understoond, if we have local service of some application, as soon as the application goes down, the service goes down as well - is that true? and if it is, how can we make an application to run all the time without go down? (without using Alarm manager). i though that the purpose of local service is to answer this situation: " to ...

Drawable from mdpi loading instead of hdpi

Hi, I have set up my project with different drawable directories (ldpi, mdpi and hdpi). I have a background png with two different resolutions: 320x480 in drawable-mdpi folder, and 480x800 in drawable-hdpi. Both have the same filename. When I try to load the background as a style in the manifest (using android:windowBackground in the sty...

ListView Problem in Android?

hi all, how to implement the slow adapter example in ApiDemos for multiple line list view? i want to do this for the multiple line list view when scrollstatechanged? any idea?? tutorial, sample code are most thankful. ...

What call from the Android Development Tools API should I use to poll project target loading?

I'm writing my own eclipse plug-in that integrates with the Eclipse Android Development Tools (ADT). However, I'm getting a CoreException ("Project target not loaded yet.") thrown when I attempt to call IProject.build on an Android project as part of a unit test: IProject project = importProject(...); project.build(IncrementalProjectBu...

How to add new field(s) and records to the call logs(call history) database?

I am trying to make a VoIP application and I wanted to know if it is possible to do the following with the Call Logs content provider - I want to add new Call Log records for the VoIP call along with the call logs for the regular call. How can I add new records to the existing Call logs content provider? I want to add custom fields to ...

Should keys be placed on a xml to be accessed with R.string.key?

I usually place my keys on an xml and access them with R.string.key_name but someone make me notice that I could have inline strings in the code. I feel that I might use that key in different places and if I change its name I would just rename in the xml but perhaps that doesn't make too much sense with keys. What do you think? ...

OpenGL depth buffer on Android

I'm currently learning OpenGL ES programming on Android (2.1). I started with the obligatory rotating cube. It's rotating fine but I can't get the depth buffer to work. The polygons are always displayed in the order the GL commands render them. I do this during initialization of GL: gl.glClearColor(.5f, .5f, .5f, 1); gl.glShadeModel(GL1...

LayoutInflater ignoring parameters ?

Hi, I have the following xml object representing a ImageButton <?xml version="1.0" encoding="utf-8"?> <ImageButton xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/genreCellItemId" android:layout_weight="1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="...

combining two png files in android

I have two png image files that I would like my android app to combine programmatically into one png image file and am wondering if it is possible to do so? if so, what I would like to do is just overlay them on each other to create one file. the idea behind this is that I have a handful of png files, some with a portion of the image o...

Linear layout and custom dialog

The button doesn't show in this layout(code below),image and textview are shown. I tried using relative layout but that doesn't help either. I'm testing it on 1.5 emulator. <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/layout_root" android:orientation="vertical" an...

ListAdapter to modify the datasource (which is an arraylist)

Hi Everyone, here's a problem that i've run into lately: I have a listview with a custom adapter class, the adapter takes in a listview and populates the listview with elements from it. Now, i'd like to have a button on each row of a listview to remove the item from it. How should i approach this problem? Is there a way to remotely trigg...

Android: How do I change the height of a ProgressBar?

Hi all, I was wondering what is the easiest way to change the height of a ProgressBar in Android? Thanks, Tomek ...

object array mobile development

Im currently creating a tile-based game for android. Using java via dalvik JVM. im fretting over a decision to represent objects in a particular map. should i use an id based map (2 dimensional integer array) and place game logic in a separate function in the game engine, or create an object array (2 dimensional array of game objects) an...

App starts in 1.5 emulator but doesn't in 1.6

My app works on 1.5 emulator and 1.5 device. When i try to start it on 1.6 emulator, it produces strange exceptions (doesn't even start). I don't have any 1.6 device to try this app if it works on a real device. I get some warnings in Eclipse ( warning: Ignoring InnerClasses attribute for an anonymous inner class that doesn't come with a...

Java library to render static SWF to raster image

Do you know a Java library to render static SWF file (no animation, just raster and vector images on a canvas) to PNG? I know swfrender (a part of swftools) but I need java, not C. ...

I need to use "ö","ä"."ü" in my program, but java/android won't let me

Hi all, I need my program to send a request to a server. The problem is, the server only recognizes ös,äs und üs, but JAVA and/or Android don't know them. `How can I send a request with a String like "Hermann-Löns" without JAVA/Android "changing" the ö.... Oh and btw., "oe" isn't recognized by the server too, already tried that... thx f...

Android: Is there a way to implement the barcode scanner into an app?

So I'm working on a project, and I'm wondering if there is a way I can implement the barcode scanner into my android app? So it would go from my app, open the camera and take the "picture", get the info, and go back to my app with that info? ...