Android disable activity
How can I make an activity temporarily not touchable and not focusable ? ...
How can I make an activity temporarily not touchable and not focusable ? ...
I'm trying to zoom in on a Google MapView on step in the oncreateMethod of my Activity. Everytime I try to zoom the map via the mapController I get an IllegalArgumentException: 04-15 10:16:51.012: ERROR/AndroidRuntime(528): java.lang.RuntimeException: Unable to start activity ComponentInfo{android.client/android.client.ui.showstores.Sto...
Hi, I'm trying to call a thread on a button click (btn_more) but i cant get it right. The thread is to get some data and update the images. The problem i have is if i only update 4 or 5 images then it works fine. But if i load more than 5 images i will get a force close. At times when the internet is slow I will face the same problem to...
Hi , Is there a way to automatically trigger the installation process of a just downloaded apk ? Currently after I download the package , nothing happens unless I click the package ,in which case the packege installer is launched ! The tomcat server from where I download the package has in the web.xml file the following : <mime...
hi sir i am new in android i am developing uploadImage in sdcard save bytearray in .net webservices public class ImageTest extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main)...
I want to refer to a static Java variable in my styles.xml, is that possible? Here's a pseudo-xml example: <style name="Artwork"> <item name="android:background">@drawable/border_{Constants.MY_COLOR}</item> </style> ...
Hi guys, I'm just writing an App for displaying the route between two coords (lat, long) in google maps view. Displaying an single coord (even with a marker) works fine, but how to do this with 2 ones and the route between them? I must admit that I'm quite new to Android and the maps-API... ...
Hi i have this Query: private Cursor getContacts(CharSequence constraint) { boolean hasConstrains = constraint != null && constraint.length() != 0; Uri uri = ContactsContract.Contacts.CONTENT_URI; String[] projection = new String[]{ContactsContract.Contacts._ID, ContactsContract.Contacts.DISPLAY_NAME }; String sele...
I'm trying to generate a custom dialog in Android. I create my Dialog like this: dialog = new Dialog(this); dialog.setContentView(R.layout.my_dialog); Everythings works fine except for the title of the Dialog. Even if I don't set the title of the dialog the dialog popup has a blank space at the position of the dialog. Is there any ...
Hi All, I have four images in the Gallery View. When we do swipe from left to right or right to left the Gallery View moves all the images i.e if I swipe from left to right from the first image then it will move to all the four images. What I want is that when I swipe it should only move to the next image. Can someone let me know how ...
So I have a language setting in my application. When the language is switched, I would like all the textviews etc to change language immediately. Currently I just change the locale in the configuration, so the language has changed when the user restarts the activity. An ugly solution to my problem would be to make each textview load the...
I have the Button defined as follows: <Button android:drawableTop="@drawable/ico" android:gravity="center" android:id="@+id/StartButton2x2" android:text="@string/Widget2x2StartBtnLabel" android:layout_width="0dip" android:layout_height="fill_parent" android:layout_weight="1" android:background="@drawable/widgetbtn_bg" /> The...
What is the best way to evaluate simple conditional statements like: "a>b" ? "x-4<10+y & y>x" ? Expressions are loaded from external file. Variables are set in application. Syntax used is not essential. It may be "&" or "and" or any other supported with language/library. I need to take different action depending on result of evaluat...
Hi to all, I am trying to compile ffmpeg for a android. I have found several posts on this theme but non of these seems to work. If tried to build ffmpeg like it is posted on [1]. Did anybody successfully compile ffmpeg using theses tutorial? I am not sure how to realize step 4 to 5. STEP4: Configuring ... STEP5: cd to your ND...
when I put the setContentView in thread as below, it crashes while running in emulator. new Thread(){ public void run() { setContentView(R.layout.main_layout); } }.start(); ...
Dear, Currently i am using ContentObserver on the Uri ContentResolver contentResolver = context.getContentResolver(); SMSObserver m_SMSObserver = new SMSObserver(context); contentResolver.registerContentObserver(Uri.parse("content://sms"), true, m_SMSObserver); in this manner onChange method call in both the cases i.e incoming and ou...
I am using below code where , i want to show dialog in front and loading content in background but not able to do the same . Please advise. dialog = ProgressDialog.show(this, "", "Loading. Please wait...", true); runOnUiThread(new Runnable(){ public void run() { setContentView(R.layout.main_layout); dialog.dismiss(); } }); ...
Hi' Is there a piece of code I could write to be notified when a download finishes in android, and be able to execute some custom actions on this event ? ...
In my desperation with trying to get LiveFolders working, I have tried the following in my LiveFolder ContentProvider: public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, String sortOrder) { MatrixCursor mc = new MatrixCursor(new String[] { LiveFolders._ID, LiveFolders.NAME, LiveFolder...
Hi there, I just wanted to know if there is some kind of class to use the multitouch features of android 2.1. Specifically I am trying to implement pinch-zoom and was wondering if I always have to measure the distance between two touch events and calculate the zoom level on my own? Thanks, chris ...