Android : How Do "saved States" Work

Apr 7, 2010

I just read a pretty interesting article on how android (and i assume other OSs) work when low on memory. How is this done theoretically? Is it similar to Java's object serialization?

Android : How do "saved states" work


Android :: Different Images For Imagebutton States

Aug 23, 2009

How do I specify different images for an ImageButton when the state changes (i.e. pressed).

CODE:.................

In a standard button the color changes to orange when pressed, I'd like to change a custom image button with a different image.

View 3 Replies View Related

Android :: Skinning ImageButton And States?

Apr 8, 2010

Using this as the android:src I get no change on press except to the background which turns orange as usual:

CODE:.......................

Using it for the android:background I get no change at all when I press the button.

View 3 Replies View Related

Android :: Changing Button Text Color In Various States - Down - Disabled

Aug 12, 2010

I would like to vary the text color of a custom button that I am making depending on which state it is in (enabled, disabled, state pressed).

I know how to use an XML file to describe the different drawables that I need for the different states like so:

CODE:...........

How do I style the textColor when pressed and textColor when disabled states without resorting to a subclass of a Button?

View 3 Replies View Related

Android :: Youtube - States That Need An Upgraded Version Of Flash Player

Aug 12, 2010

Seems as if half the video's I try to watch lately will not play in the built in youtube app. And when I attempt to watch it through the browser. It states that I need an upgraded version of Flash player.

View 3 Replies View Related

Sony Ericsson Xperia X10 :: Forwarding Received Messages / Saved Contacts On Phone / Rather Contacts Saved On Sim Card?

Sep 28, 2010

Please, I need advice on how to get phone numbers saved on the phone up when forwarding received SMS or MMS! At the moment, I can only forward messages to contacts saved on Sim card!

View 5 Replies View Related

Android : Aren't Focus States Supposed To Bubble To Child Views?

Apr 19, 2010

When using a View within a View, for example an ImageView within a LinearLayout, both of which have xml drawable resources (the LinearLayout as a background) specifying PNG drawables to use for the on/off states, shouldn't children Views receive the focus state when their parent gets focus? So as far as I understand, both my LinearLayout and ImageView should be switching to their focus states right? Apparently not Or, more likely, apparently my implementation is incorrect.

The focus state works on the LinearLayout but my ImageView never receives focus.. I have both Views set to android:focusable="true".

You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

View 2 Replies View Related

HTC Hero :: Can I Pop In A Sim Card From A Carrier In States / Use That?

Nov 15, 2010

I want to use my hero in the states and canada. I am on the telus network up here and I have a simcard in my phone. can i just pop in a sim card from a carrier in the states and use that?

View 1 Replies View Related

HTC Incredible : Verizon States There Was No Update

Jul 28, 2010

I just got off the phone with a member of the verizon Wireless higher ups, Mr. Avram Polinsky, Executive Relations Coordinator at Verizon Wireless, in regards to an e-mail I sent to CEO Lowell McAdam about the July 16th update. I was told there was no update for the Incredible. The only update was for the Eris. He said there is an update being worked on but he couldn't state when that is going to be released. He said there was no update coming in the immediate future. (Guess that squashes the Froyo Rumors) I talked with him about the signal and call quality issues and he stated that HTC and Google were working on the issue. He also stated he was on the various blogs and is aware of the rumors going around. He apologized for the mis-information and stated the persons who gave the bad information about the July 16th update would be dealt with. So to sum it all up, according to Verizon Wireless Executive Relations, there was no July 16th update, it was an Eris update only, and there will be no updates in the immediate future. There is one in the works, however he has no idea when it will be released, and when it does, it will take about a week to reach everyone, so it doesn't overload the system. Just an update for those who care. I think we all knew there was no update released. Its nice to get that confirmed by Verizon Wireless Corporate though.

View 49 Replies View Related

Android :: Modify Default Button State Without Affecting Pressed And Selected States?

Oct 4, 2010

I am trying to remove an ImageButton's background in only the default state. I'd like the pressed and selected states to behave as usual so that they look correct on different devices, which use different colors for the pressed and selected states.

Is there any way to set an ImageButton's background default state's drawable without affecting the pressed and selected states?

I've tried to do this with a selector, but it does not appear to allow you to use the default drawables for some states - you have to set all the states yourself. Since there's no API to retrieve the device's default pressed/selected drawables, I don't know what to set the pressed/selected states to.

I also tried getting the StateListDrawable object for the button that the system creates when you are not using a selector and then modify it change the default state. That didn't work either.

I seems that on Android, if you want to change the drawable for one state of a button, then you must set all the states, and thus cannot preserve the default drawables for the other states. Is this correct?

View 1 Replies View Related

Motorola Droid X :: GPS Location Is 2 States Off / Get Correct?

Oct 24, 2010

So my gps location puts me close to 500 miles away from my actual location. Ive pulled battery, turned gps off n on, turned location settings off n on and I still cant get it to locate me correctly....any tips?

View 2 Replies View Related

Samsung Galaxy S :: Can I Use Australian Phone In United States

Aug 16, 2010

I'm leaving for the US from Australia tomorrow, and I want to use my Galaxy S (on Optus here) with a prepaid sim there. Does anyone know if the cell bands are compatible or if I should use one carrier over another? I used AT&T there before moving here and most of my family there has it, so I'd prefer that if my Galaxy S has the same cell bands.

View 1 Replies View Related

HTC Droid Eris :: Password Screen Locks And When Asks For User Name And Password It States Invalid User Name / Password

Mar 3, 2010

I have had this same problem happen twice to me on 2 different phones on 2 different Verizon accounts!

The password screen locks and when it asks for the user name and password it states invalid user name / password!

Is this a known problem since when I called and talked to both Verizon and HTC the only thing they could tell me was to do a hard reset and they weren't aware of this problem?

View 1 Replies View Related

Android :: Saved Game Files

Feb 24, 2010

Where are 'Saved Game Files' kept? Internal memory or SD Card? Whats the best way to save 'saved games files'? for when I have to do a factory restore or Rom upgrades. For instance Robo Defence which is going to take me years to play and get to level 2000, will still be playing this in my grave, lol. What I was thinking is that I would backup my SD card to my PC, reinstall the game then copy files back from my SD Card or do I have to install a backup App like 'mybackuppro' to specifically back these type of things up?

View 1 Replies View Related

Android :: Where Selected Wallpaper Saved?

Feb 10, 2009

When a wallpaper is set (either from the Wallpaper Gallery or from Pictures) where is the wallpaper that is selected saved? Is there a directory where this is saved? Is there a Database where this information is saved? who handles this? Is it the wallpaper service? What if I wanted to have multiple wallpapers and have the service rotate through each of them based on some setting - every 1 hour for example - what do I need to change in order to do that?

View 7 Replies View Related

Android :: Preferences Not Saved When Resume App

Jan 22, 2009

I'm having this problem with one of my apps where some people are reporting that their preferences are not being saved when they close and resume the app. The preferences theyre talking about happen to be actual Preferences (i.e. the built-in preferences manager for an activity). They say they're not doing anything special, just exiting the app and going back to it. Does anyone know why the prefs wouldn't be saved for only this select few people? I'm at a complete loss.

View 10 Replies View Related

Android :: Contacts Saved Through Some App Funmobile / What Its Name?

Apr 19, 2009

I got my phone stolen last night

I had all my contacts saved through some app
funmobile
or like fubmobile
I CANT REMEMBER THE NAME.

View 4 Replies View Related

Android : Can't Figure Out How To Recover URI Where It Is Saved

Apr 4, 2010

I'm trying to use the built in camera to capture a video but when I specify the URI I want the file saved to (using videoCaptureIntent.putExtra (MediaStore.EXTRA_OUTPUT, Uri.fromFile (fileLocation)); ) the 'Retake' and 'Play' buttons crash my app. I am trying to switch and let the Intent store the file where it wants but I can't figure out how to recover the URI where it is saved to. The docs say this:

"The caller may pass in an extra EXTRA_OUTPUT to control where the video is written. If EXTRA_OUTPUT is not present the video will be written to the standard location for videos, and the Uri of that location will be returned in the data field of the Uri." But what is "the data field of the Uri"?

View 3 Replies View Related

Android :: Way To Test OnCreate With Saved Bundle?

Jun 10, 2010

My app launches the camera to allow the user to capture a picture. Sometimes this causes the OS will kill my App to free up memory for the camera. Once the picture is taken, my app starts back up where it left off using the Bundle I saved in onSaveInstanceState(). My app had a bug where in the code that restores the state. Is there anyway that I can simulate or test this case to make sure I am restoring correctly now? It seems I am having trouble making this happen when I want to test it.

View 4 Replies View Related

Android :: Know Data Successfully Saved On Server?

Aug 30, 2010

In my application I am sending data to server if I had not pressed back button when data is sending to server then data is successfully saved on server and new screen (one created in layout folder) is displayed which says data is stored. But at the time of sending data if i pressed back button then also data successfully saved on server but I can't see that new screen that data is stored on server. How to handle this situation?

View 5 Replies View Related

Android : App Go After Barcode Scan / Get Saved To SD - On Phone?

Dec 22, 2009

i seriously just scanned every barcode too! but does it get saved to my SD or does is saved on the phone?

View 1 Replies View Related

Android :: Save Old Saved VM Messages To Device Or Your Computer

Jun 20, 2010

I have a few saved voicemails that I want to keep. How can I best save them to my phone or save them to my computer. Save maybe as a Mp3 or Wav file. Or even email them as an attachment?

View 6 Replies View Related

Android :: Clear Saved Searches From Aps Market Screen?

Nov 21, 2009

Does anyone know of a way to clear the saved searches from the aps market screen?

View 3 Replies View Related

Android :: How Can Display Saved Data When Restart Activity

Oct 6, 2010

In my Project I want to play audio files in mediaplayer and displays progressbar. If I exit the application then also player have to play audio file. If I restart The Activity
I have to display progress bar with last activity progress.

Here I tried using onSaveInstanceState() method. But I cant display progress bar with last progress. when I exit the activity player is playing but when I restart activity it stopped and displayed new view without any progress and saved data.

View 1 Replies View Related

Android :: How Runtime Error Logs Are Saved In Device

Oct 30, 2010

While debugging, Log.d() or Log.e() methods come to LogCat, but how do I capture the runtime error or trace log on the Android device when it is not connected to the development environment ?

View 1 Replies View Related

Android :: APIDemos 8 PersistenceState - Where Is The Persistent Text Saved

Jul 21, 2010

In the class PersistentState.java the prefs variable gets the saved/typed text from prior sessions here, on line 106 into restoredText.

Where does the getString method get the saved/typed text?

CODE:............

View 1 Replies View Related

Android :: Launching Intent Not Working On Saved Image File

Jun 2, 2010

First of all let me say that this questions is slightly connected to another question by me. Actually it was created because of that. I have the following code to write a bitmap downloaded from the net to a file in the sd card:

// Get image from url
URL u = new URL(url);
HttpGet httpRequest = new HttpGet(u.toURI());
HttpClient httpclient = new DefaultHttpClient();
HttpResponse response = (HttpResponse) httpclient.execute(httpRequest);
HttpEntity entity = response.getEntity();
BufferedHttpEntity bufHttpEntity = new BufferedHttpEntity(entity);
InputStream instream = bufHttpEntity.getContent();
Bitmap bmImg = BitmapFactory.decodeStream(instream);
instream.close();

// Write image to a file in sd card
File posterFile = new File(Environment.getExternalStorageDirectory().getAbsolutePath()+"/Android/data/com.myapp/files/image.jpg");
posterFile.createNewFile();
BufferedOutputStream out = new BufferedOutputStream(new FileOutputStream(posterFile));
Bitmap mutable = Bitmap.createScaledBitmap(bmImg,bmImg.getWidth(),bmImg.getHeight(),true);
mutable.compress(Bitmap.CompressFormat.JPEG, 100, out);
out.flush();
out.close();

// Launch default viewer for the file
Intent intent = new Intent();
intent.setAction(android.content.Intent.ACTION_VIEW);
intent.setDataAndType(Uri.parse(posterFile.getAbsolutePath()),"image/*");
((Activity) getContext()).startActivity(intent);

A few notes. I am creating the "mutable" bitmap after seeing someone using it and it seems to work better than without it. And I am using the parse method on the Uri class and not the fromFile because in my code I am calling these in different places and when I am creating the intent I have a string path instead of a file. Now for my problem. The file gets created. The intent launches a dialog asking me to select a viewer. I have 3 viewers installed. The Astro image viewer, the default media gallery (I have a milstone on 2.1 but on the milestone the 2.1 update did not include the 3d gallery so it's the old one) and the 3d gallery from the nexus one (I found the apk in the wild). Now when I launch the 3 viewers the following happen:

Astro image viewer: The activity launches but I see nothing but a black screen.
Media Gallery: I get an exception dialog shown "The application MediaGallery (process com.motorola.gallery) has stoppedunexpectedly. Please try again" with a force close option.
3D gallery: Everything works as it should.

When I try to simply open the file using the Astro file manager (browse to it and simply click) I get the same option dialog but this time things are different:
Astro image viewer: Everything works as it should.
Media Gallery: Everything works as it should.
3D gallery: The activity launches but I see nothing but a black screen.

As you can see everything is a complete mess. I have no idea why this happens but it happens like this every single time. It's not a random bug. Am I missing something when I am creating the intent? Or when I am creating the image file? As noted in the comment here is the part of interest in adb logcat. Also I should note that I changed the way I create the image file. Since I want to create a file that reflects an online file I simply download it instead of creating a Bitmap and then creating the file (this was done because at some point I needed the Bitmap but now I do it the other way around). The problems persist thought and are exactly the same:

I/ActivityManager(18852): Starting
activity: Intent {
act=android.intent.action.VIEW
dat=/sdcard/Android/data/com.myapp/files/image.jpg
typ=image/* flg=0x3800000
cmp=com.motorola.gallery/.ViewImage }
I/ActivityManager(18852): Start proc
com.motorola.gallery:ViewImage for
activity
com.motorola.gallery/.ViewImage:
pid=29187 uid=10017 gids={3003, 1015}
I/dalvikvm(29187): Debugger thread not
active, ignoring DDM send
(t=0x41504e4d l=38)
I/dalvikvm(29187): Debugger thread not
active, ignoring DDM send
(t=0x41504e4d l=64)
I/ActivityManager(18852): Process
com.handcent.nextsms (pid 29174) has died.
I/ViewImage(29187): In View Image
onCreate!
D/AndroidRuntime(29187): Shutting down VM
W/dalvikvm(29187): threadid=3: thread
exiting with uncaught exception
(group=0x4001b170)
E/AndroidRuntime(29187): Uncaught
handler: thread main exiting due to
uncaught exception
E/AndroidRuntime(29187):
java.lang.RuntimeException: Unable to
start activity
ComponentInfo{com.motorola.gallery/com.motorola.gallery.ViewImage}:
java.lang.NullPointerException
E/AndroidRuntime(29187): at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2496)
E/AndroidRuntime(29187): at
android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2512)
E/AndroidRuntime(29187): at
android.app.ActivityThread.access$2200(ActivityThread.java:119)
E/AndroidRuntime(29187): at
android.app.ActivityThread$H.handleMessage(ActivityThread.java:1863)
E/AndroidRuntime(29187): at
android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime(29187): at
android.os.Looper.loop(Looper.java:123)
E/AndroidRuntime(29187): at
android.app.ActivityThread.main(ActivityThread.java:4363)
E/AndroidRuntime(29187): at
java.lang.reflect.Method.invokeNative(Native
Method)
E/AndroidRuntime(29187): at
java.lang.reflect.Method.invoke(Method.java:521)
E/AndroidRuntime(29187): at
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
E/AndroidRuntime(29187): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
E/AndroidRuntime(29187): at
dalvik.system.NativeStart.main(Native Method)
E/AndroidRuntime(29187): Caused by:
java.lang.NullPointerException
E/AndroidRuntime(29187): at
com.motorola.gallery.ImageManager.allImages(ImageManager.java:5621)
E/AndroidRuntime(29187): at
com.motorola.gallery.ImageManager.getSingleImageListByUri(ImageManager.java:5515)
E/AndroidRuntime(29187): at
com.motorola.gallery.ViewImage.onCreate(ViewImage.java:1801)
E/AndroidRuntime(29187): at
android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
E/AndroidRuntime(29187): at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2459)
E/AndroidRuntime(29187): ... 11 more

View 3 Replies View Related

Android :: Adding Bookmark To Saved HTML Files In Browser

Nov 20, 2009

I wanted to be able to use my Google bookmarks on my Droid. I found a program that imports them to the phone, but it replaces everything and I didn't want all those bookmarks in my browser. I exported my Google bookmarks to a HTML file and stored it on my SD card in the download folder and named it bookmarks.htm. I then went into the Droid browser and typed the following URL: content://com.android.htmlfileprovider/sdcard/download/bookmarks.htm

I then created a bookmark of the link.

Now, I open my browser, click on the bookmark, and all my Google Bookmark sites are displayed as links in order listed under their categories.

View 1 Replies View Related

Android :: Updating Our Applicatoin On The Market Deletes The Saved SharedPreferences

Mar 9, 2009

We have an online multiplayer game that saves some login information in the SharedPreferences. Our app is copy protected and everything was going really well until this weekend when we released an update for it. It seems that at least some of the people are having their SharedPreferences deleted when they updated too the new app. As you can imagine our users are furious because they're all loosing their profiles, and our ranking is dropping fast.

We've tried to reproduce this a hundreds ways but are unable. We're wondering if this could be related to installing a copy protected app over a copy protected app? Since that's the only situation we haven't tested and can't test.

View 8 Replies View Related

Android :: Directions To Install Apk App Saved On Computer But Not On Droid Market?

Jul 25, 2010

Does anyone know where there are directions to install an Apk application saved on the computer but not on the Android market?

I tried HTC sync and it says there was a parser package error.

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved