android

Android Development: How Can I Add Syntax Highlighting Features

Hello, I want to add syntax highlighting to my application. I'll be using syntax highlighting with PHP, HTML, CSS, XML and JavaScript. How can I do this? I have a TextChanger set up on my EditText, which I want to use so that the syntax highlighting process occurs when the EditText gets changed. I'm new to Android development and only...

Seeking cause of Android 'ERROR/CameraInput(57): Unsupported parameter(...' in LogCat output

I am finding Android's MediaRecorder to be very tempermental. I have an application where I have been successful recording, but I see the following LogCat ouput: 09-30 11:34:09.143: ERROR/CameraInput(57): Unsupported parameter(x-pvmf/media-input-node/cap-config-interface;valtype=key_specific_value) 09-30 11:34:09.143: ERROR/CameraInpu...

Android: compass + distance in a listview.

Hello, I guess you have all tried "Google Places" in Maps. This is a list of POI close to you. I really would like to do the same feature in my application with a list of GPS coordinates, but that seem really complicated. Making the listview with the distance and the little arrow is very easy, but I cannot understand how to update thi...

Android ExpandableListView does not work (Black/Empty Screen)

Hi @ll, i try to build a ExpandableListView with a own ExpandableListAdapter but the ExpandableListView is not visible in my activity :-( Below you find my Source-Code. Thanks for your help :-) Greetings, Kangee Here the Code from the activity: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceS...

How to differentiate between a fling and a touch?

I have a ListView inside of a ViewFlipper which I am flipping when the user swipes across the screen. Clicking on a ListView will open the browser. Sometimes when I am swiping, it gets detected as a touch on the ListView and will open the browser. This can be annoying. How can I prevent this from happening? class MyGestureDetector exten...

Showing multiple activities on one screen?

Hi there, I have an interesting problem and I was looking for a solution; Hoping that someone here can help me out. (I did read through related questions on this topic but they have solutions which are not relevant to my situation). Details are: I have two activities. One is a simple list view to list available audio tracks. Another ...

How can I improve the alignment of my TextView?

Right-most textview is causing some alignment issues. I'm not sure how I can alleviate this? ...

Android browser to Google Map app with multiple pins

I've got a website that runs in the android browser. And I'm able to launch the google maps app on the android, and passing it a pin using the geo: uri. No problem there. However, now I'm wanting to send a list of pins to the app, all from my website. I'm not pushing this out as an app, so I don't have the java intents, etc. And I ...

Android Emulator substituting GPS position

Hello i have app which ask every 5second for GPS position but it allways returns same position. I have tried substitite position in DDMS or by telnet (geo fix ... ...) But allway it return initial postion. Whats wrong? public class App09_GPS_RepeatedAsking extends Activity { TextView tv1; /** Called when the activity is first created. *...

Android: change display content when wipe on the screen

I want to change the lower half of the screen when the user wipes with the finger, but got no idea how to start. The upper half with sone TextViews should stay fixed. Do I need more then one activity, or can I just change the layout portion on the lower half? Thanks for any hint! ...

Android Splash screen for "Application" class

Hi, I have an Android app where I've extended the base Application class in order to set up some global variables. public class MyApplication extends Application { private ArrayList<ModelClass> master_list; // global variable 1 private DataBaseHelper db_helper; // global variable 2 @Override public void onCreate() { super.onCre...

Android 1.6 SDK LocalFileContentProvider file exists but catches

I can't seem to get check if a file exists or not - it always catches, even if it does exists; what am I doing wrong? The file exists in file:///data/data/com.generic.name/files/testImageView.html private static String url = "/testImageView.html"; private static String uri; @Override public void onCreate(Bundle icicle)...

Android: how to combine the paths of two shapes and remove overlap?

Hi all, I want to create a speech balloon type shape, where there is a rectangle or ellipse with a triangular shape jutting out of it. How I'm attempting to do this is to create a Path object that combines the triangle with the other shape (round rect). I'm doing it as follows: Path path = new Path(); // Create triangular segment Po...

android code for streaming shoutcast stream breaks in 2.2

The following code works fine on Android 2.1update1 - package com.troubadorian.android.teststreaming; import android.app.Activity; import android.content.Context; import android.os.Bundle; import android.util.Log; import android.view.View; import android.view.ViewGroup; import android.view.Window; import android.view.animation.Anima...

How to work with android different resolutions?

Hi How large should be the image in pixels to fit all resolutions? 480x800 or 480x854? I need to do different image resolutions for all folders:drawable-hdpi , drawable-ldpi, drawable-mdpi?and if so, which resolutions are used? Thanks ...

AndEngine & SurfaceView (CameraPreview)

How do you add a SurfaceView showing the camera preview as the background of the BaseGameActivity of AndEngine (Physics Example). @Override public Scene onLoadScene() { mBackgroundView = new PreviewView(this); addContentView(mBackgroundView, new LayoutParams( Layout...

Android: Clickable property traps onClick event

In my XML layout if I set a view to have clickable="true" then the onClickListener registered to that view doesn't fire the onClick method. If I set the clickable property to "false" then it works fine. Does setting the clickable property to "true" trap the on click events? Is there a way that I can make them propagate through? The r...

Android - How to load HelloWorld app onto my Phone?

I made an Android Hello world app and I'm trying to load it onto my HTC Incredible. I believe it has 2.2 (how do I confirm that?) Anyway, Eclipse gives me this message and then brings up the window in the screenshot below. Automatic Target Mode: Unable to detect device compatibility. Please select a target device. I'm on Ubun...

Android not playing HTML5 video on HTTPS

I am using HTML5 element to play a sample.mp4. It plays fine if using HTTP protocol. If I change the URL to use HTTPS, it will give error "Sorry, this video cannot be played." The SSL certificate is valid. I have tried on both IIS and Apache server. <video src="sample.mp4" id="myvideo" /> <a href="javascript:void(0)" onclick="document....

Android: softkeyboard control on HTC desire

I posted a question earlier today which was well answered by commonsware. I wanted a numeric keypad that had a go or done button that closed and executed a calculation class. Thanks to a tip from commonware on where to start I got this working beautifully on the emulator. Then I came to load it on to my HTC desire for testing and it does...