android

Custom MapView throwing NoSuchMethodException, but it's there!

I'm trying to implement a custom MapView. Inside my MapActivity (named mainmap) I have an inner class which extends MapView: private class Lmapview extends MapView{ public Lmapview(Context context, AttributeSet attrs) { super(context, attrs); gestures = new GestureDetector(mainmap.this, new GestureListener(this)); ...

What do the Android camera zoom numbers mathematically represent?

I'm trying to write a basic augmented reality app in Android, but I'm running into some trouble doing platform-uncoupled calculations because I don't know how to interpret the zoom levels on Android. The zoom levels range from 0 - params.getMaxZoom(), but I can't find any documentation about what those zoom levels actually mean (for...

Theme.Dialog view size problems

I'm trying to create a basic AlertDialog using an activity with a theme of Theme.Dialog. However, I'm having an issue with the size of the dialog. My XML is currently this: <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent"> <TableL...

custom button: change style when pressed

I created button with some shadow using a style: <style name="test"> <item name="android:shadowColor">#FFFFFF</item> <item name="android:shadowRadius">1</item> <item name="android:shadowDx">1</item> <item name="android:shadowDy">1</item> </style> This applies a white shadow on the button's text in its normal state. I was just...

What to put at CALLBACK_URL in twitter using Oauth from my android application?

Dear Android guys. I am developing an application of Twitter -Client. i got lots of hint form this site. i write some come that is import oauth.signpost.OAuthProvider; import oauth.signpost.basic.DefaultOAuthProvider; import oauth.signpost.commonshttp.CommonsHttpOAuthConsumer; import twitter4j.Status; import twitter4j.Twitter; i...

What is the most efficient way to load my stored JPG file into the ImageView?

I have valid JPG files and now I want to load them into a layout containing an ImageView. I have code to findViewId(R.id.myimage). I followed some sample code using File but it did not work. The file is stored at /data/data/com.myapp/files/someimage.jpg. What is the easiest and efficient way to load and display? ...

Android incoming call interception , call forwarding

I would like to know how to intercept incoming calls and also how to forward them. I know there are several questions regarding this topic here and elsewhere on the net, but all the answers use the android.intent.action.PHONE_STATE action which is broadcast always after the phone begins to ring and the call screen is shown. That's why I'...

Android: Developing Plugins for media sharing

Hi Developers, We are developing plugins which convert media file as the source and convert in to other format that can be used by DLNA compatible device in android. Any help on how to deal with media and its file format and convert into DLNA file format.. Any idea will be appreciable... Thank you ...

How do I calculate the required height of a GridView that is inside of a ScrollView on Android?

I have a GridView inside of a LinearLayout inside of a ScrollView that pages in data from the server. Beneath the GridView is a button to load more data. My GridView will have an ultimate height that is larger than the screen. If I set the height of my GridView to either wrap_content or parent_fill, it sizes itself to the exact available...

buttons conditioned by supported parameters

I'd like to create a list of buttons that depend on device supported parameters ; for example, if the device's camera supports setting white balance and antibanding, then 2 corresponding buttons are displayed to allow the user to changes these settings; but if I run the same App on a device that supports only setting for white balance, t...

How do I put graphics on top of my camera preview in Android?

I see a couple of threads on this topic, but none of them seem to answer the question, so, I'm giving it another go... Very simple idea... I want to some portion of the screen to preview (and shoot) the camera and the other portions of the screen to add my own graphical elements (buttons, colorful frame around the camera preview, etc). ...

Android twitter Integration

Possible Duplicate: twitter integration on android app Hi friednds, Any one have idea how to integrate Twitter with Android Application Please suggest me way to do this. Thanx in Advance ...

Switching between Android activities

I am working on an Android application where I would want to switch between 3 activities (say Home, Map and Photo). Right now the flow is like 'Home>Map>Photo'. I would like to allow the user to switch between these 3 activities. Say if he wants to go from Photo to Map or from Photo to Home without destroying the Photo activity. What is ...

Font size mystery: why are two fields drawn using different font size?

Hi, in my Android program I am trying to draw a table. For some odd reason the first field per row is drawn using a smaller font size then the other columns. I boiled this down to the below example which one can easily copy into a layout file and then preview it in the Eclipse Android layout editor. Does anyone have an idea, WHY the fir...

android: Adding external JAR file in to android

We are making an application that needs to convert one file format to another. I am not sure whether we can add a JAR file in which we develop the code to convert the file format to our required file format, to our android project. ...

Android: How often does getLastKnownLocation(LocationManager.NETWORK_PROVIDER) return null in real life?

Do the Android users have the chance to reset the NetworkProvider, so that the location will be null? I came up with the idea, that its only possible to have that location null, after starting the device the very first time. But also than google will check the location right away for my opinion. Sure, I'm implementing a default locatio...

Good practices for building web application that can later have and mobile(Android/iPhone) version

Hi, can you advice me a book or something else containing good practices about how to build/structure a web application in a way that will be easy to extend it with an Android/iPhone version later. I am currently trying to get into Django so it will be nice if the practices are related to it, but every hint will be appreciated. ...

Problems using PieChart of achartengine

Hi all, I'm facing problems using PieChart from the achartengine library. According to the demo, the PieChart extends AbstractChart.java, not AbstractChart.class in the library. Hence, the functions buildCategoryRenderer(int[] args) and buildCategoryDataset(String arg0, double[] arg1) don't exist in the library. How does one initiate a...

Any idea how to write code that can be easily ported to iphone, android and blackberry?

I'm looking for a way to easily port content driven applications from one mobile platform to another. Currently HTML5+js seems to be the only language that can be easily reused. Can you share your experience? I'm looking for a way to go forward. ...

Set image from android.R.drawable in image view android

Hi, i know how to set image/icon from our res/drawable ImageView android:id="@+id/ImageSearch" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/android_green_3d"> If we set it directly from the code: imageView1.setImageResource(R.drawable.android_green_3d); But we can also get th...