android

How do I programmatically add an Android Gestures view to a custom view?

I have a custom view that works fine and I'm trying to get gestures into it. The most common technique I see is to add XML, such as this (from Android docs: <android.gesture.GestureOverlayView android:id="@+id/myGestures" android:layout_width="fill_parent" android:layout_height="0dip" android:layout_weight="1.0" /> My view i...

Is deep Java knowledge needed for Android?

Hi, I am C++ developer interested in Android. As I understand the only possibility to develop applications for Android is Java. There is NDK also, but as I can see it is just something like JNI for Java. Is it mandatory to learn Java or to have deep knowledge in Java then try Android SDK, or it would be possible to learn Java while deve...

Android Home Screen Widget Failing with EditText

Whenever I add an EditText widget to the layout of my home screen widget (confusing how the term "widget" is being used twice in the Android lexicon :-/ ), I receive the "Problem Loading Widget" error box. Here is the layout I'm attempting; if you remove the EditText, it works... < RelativeLayout android:layout_width="fil...

Android Dev Phone 3?

I'm wondering if there is any news about a "Android Dev Phone 3"? Is an updated hardware of the "Android Dev Phone 2" that is coming soon? (probably an unlocked version of the Nexus One) ...

android: open a pdf from my app using the built in pdf viewer

This was my original question: I want to be able to open a pdf file in my app using the android's built in pdf viewer app, but i dont know how to start other apps. I'm sure i have to call start activity, i just dont know how to identify the app im opening and how to pass the file to that specific app. Anyone have a...

Android - TableLayout to ExpandableListView

Is it possible to switch from a TableLayout to an ExpandableListView? How? I tried using ViewFlipper but the fact that ExpandableListView doesn't use XML threw a wrench in it. Please help! ...

Is there a JQuery alternative to JQTouch with better Android Support?

Basically looking for a JQuery plugin with better Android browser support than JQTouch. Or even an alternative Javascript framework with better mobile support. ...

Where are graphically pleasing examples of Lists

Anyone know of good code examples of how to make lists look different than your everyday average black list or more graphically pleasing than you usually see in android apps. I've looked through google code but haven't found too many. I'm looking for different and eye catching lists. I hope this question isn't too generic. Also i'm o...

Android Status Bar Notifications - Opening the correct activity when selecting a notification

I have been having a problem with a notification not opening/going to the correct activity when it has been clicked. My notification code (located in a class which extends Service): Context context = getApplicationContext(); CharSequence contentTitle = "Notification"; CharSequence contentText = "New Notification"; final ...

Forcing sound output through speaker in Android

Is there a way in Android to force output through the phone speaker, even if a headphone is plugged into the jack? I know there has to be a way because when you are talking on the phone, you can put someone on speaker phone, even if there is headphones plugged into the jack. ...

android:digits Problem

I am using the following xml to limit input to digits only in an EditText widget. The android:digits attribute uses the below array resource. Everything works great except for the fact that I can't enter the number 4 even though its in the array. Any Ideas? <EditText android:id="@+id/mynumber" android:layout_width="wrap_conte...

Organizing files on sdcard into directories

I have images uploaded on the simulated sdcard on my emulator. I downloaded them from the browser, using the long-click on each image. When I look at the file explorer in the DDMS perspective, I see that they are in the directory sdcard/download. Now if I want to download some audio files and use them in an app to, say list the titl...

unix utilities under Android

I have a smartQ V5 device running Android ( 1.6, I think) Q: I can not do simple unix things (find, more, ... ) on this device. they are not there. Do I aomehow downlooad them? apt-get is not there either; is there an alternative? ...

Android PCM Bytes

Hi I am using the AudioRecord class to analize raw pcm bytes as it comes in the mic. So thats working nicely. Now i need convert the pcm bytes into decibel. I have a formula that takes sound presure in Pa into db. db = 20 * log10(Pa/ref Pa) So the question is the bytes i am getting from audiorecorder from the buffer what is it is it...

LogCat acting patchy

The LogCat output in eclipse suddenly started weird. It sometimes shows all the output as expected. Other times it just doesn't show anything - is completely blank. After some internet research, I thought Mylyn plugin might be responsible. So I tried de-selecting "Mylyn Tasks UI" & "Mylyn Team UI" on eclipse Window --> Preferences --> G...

Serialization Performance and Google Android

I'm looking for advice to speed up serialization performance, specifically when using the Google Android. For a project I am working on, I am trying to relay a couple hundred objects from a server to the Android app, and am going through various stages to get the performance I need. First I tried a terrible XML parser that I hacked toge...

Simple reminder for Android

I'm trying to make a simple timer. package com.anta40.reminder; import java.util.Timer; import java.util.TimerTask; import android.app.Activity; import android.os.Bundle; import android.widget.RadioGroup; import android.widget.TabHost; import android.widget.TextView; import android.widget.RadioGroup.OnCheckedChangeListener; import and...

Constant Connectivity through Wi-Fi and 3G in Android

Hi All, I have a small doubt regarding network connection procedure in Android. My scenario is like, I am connecting to remote server over TCP using 3G. After it got connected, I enabled Wi-Fi. Android has switched to WiFi. And, still connection is alive with server, means there is no connection drop. Here, I want to know one thing. Wh...

How do I cancel a "drag" motion on an Android Seekbar?

I've been reading through the docs, and I cannot figure out how to cancel a "drag" on a Seekbar once the bar has been completed. For example, when I drag the bar to the end, I want an event to happen. However, if I keep my finger on the screen and drag my finger past the SeekBar, it keeps firing off that event even after I reset the pro...

How to putExtra() in Searchable Dictionary Example

Hi, based on the Searchable Dictionary sample I tried to put extra data to a different activity. public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); Spinner distance = (Spinner) findViewById(R.id.distanceSpinner); ArrayAdapter<CharSequence> adapterDistan...