[android-developers] Re: How to update the progress bar dynamically.
You may do it by useing timer. vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Spinner focus problem
Sorry, I did not undrstand, what do yo want. As I understand now, you have different quantity of invocation for spinner with focus and without it? And you don't now, have spinner focus or not? I did not investigate this problem. May be parameters of onItemSelected(AdapterView parent, View v, int position, long id) help you? Or may be it is possible change focus programmly. I did not find setFocus() function in Android. vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Accessing different API.. (aside from android.jar)
I did all as you said. But in xml file string test.TestPack.MyView works only if class MyView and it’s parents are present in pacage. If parents of MyView were got by import from my pacage, this string doesn’t work. What is the matter? Why xml file doesn't see import ? Thank’s, vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Static variables or variables, saved in Bundle?
I am very glad, that this topic got many answers. I think, that it is very important team. You probably don't want to do that. Bear in mind that Android devices will have very little RAM for running programs, compared to your average desktop or notebook PC. Use a SQLite database so you can only load into memory the bits of data you need at the moment. Or find some other way to avoid loading the big file into memory all at once, or parsing through the whole file continuously. Now I want only translate to Android those applications, which work now in WindowsCE, Palm and Symbian mobiles. All of them use dictionary about 1Mb. May be in this case it’s better to save data in SQLite database, but question is remain. What techniqes can we use for data saving? Programs may be killed off by Android if the device needs memory for newer applications or other activities. If the user restarts your application, your static variables will be empty. However, if you persisted state via the Bundle in onFreeze(), you will get that state back via a Bundle in onCreate() or onNewIntent(). My question was indeed about it. How to save my data from one call to another. Only one example of this presents in SDK Examples – Snake. I tests Snake in two variants: 1}with Bundle and 2) with static variables and got same results. When I press BACK and recall Snake I see, that in onCreate() Bundle==null ! As result, I think that it help only for temporary out from application. But static variables solve this task too ! I hope that, if my application will be killed off by Android, I got null for my static array and I shall read my file ago. But I don’t know, is it so endeed? It is very important to have posibility test this situation. I know only one vaiant. In Transition 3D, for example, after about 15 calls we get Memory Overflow. But it occurs when application works. In this case application finishes work and reurns to Home. In next call all work very well (15 times :=) ). It will be better to kill application, when it sleeps. To call ago, and get result. vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Can anybody explain collision between resources?
Now I tried use another variant. But in xml file string test.TestPack.WWView works only if class WWView and it’s parents are present in pacage. If parents of WWView were got by import from another my pacage, this string doesn’t work. What is the matter? Why xml file doesn't see import ? Thank’s, vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Can anybody explain collision between resources?
Hi,all! Can anybody explain collision between resources? I paced my application A and used it as pacage in application B. Application A - package aaa.AAA: public class NN extends ForAll ... public class ForAll extends Activity ... R.java of application A. Application B - package bbb.BBB: import aaa.AAA; public class NN_2 extends ForAll ... R.java of application B. Pacage with class ForAll and R classes of application A But I don't understand, what will be with resources? Thank's vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Static variables or variables, saved in Bundle?
Thank's for all. I read all about lifecycle, but it didn't help me :). In my application I read big file to static array. Now it is sufficient to read this file only one time. Snake example from SDK examples uses specific tecnic to save data. It do it in onFreeze(), and restore - in onCreate(). I think, may be it very important to do so. But when I removed this in Snake and used static variables, I got same result. vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Static variables or variables, saved in Bundle?
Hi, all Can anybody say, for what purpose in Snake example saveState() used? Before this function we can read: /** * Save game state so that the user does not lose anything * if the game process is killed while we are in the * background. * * @return a Bundle with this view's state */ But we can define this variables as static. When and for what purposes we have to use this technique? Why it is better, than define static variables? Thank’s vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Memory's control. How can I do it?
Hi,all! I want anderstand, what values are reported in LogCat's string INFO/dalvikvm-heap(508): GC old usage 55.3%; now 2.282MB used / 4.282MB soft max (4.377MB real max) I find, that after several restarts my application, I get Out of memory on a 551696-byte allocation. After this I can again restart my application several times (10-25). In my application I use 3D Transition. I know, that 3D Transition has bug. But in simplified variant of application with 3D Transition all is ok. I try understand, what is my problem and what is the bug of 3D Transition. I see, that in complicated variant ''real max'' grows every time. But in simplified variant ''real max'' grows several times and stops. I do't now what are this values, what values are more important and why all changes? Thank's vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] I want to load big file. What is a limit for file size?
Hi! I want to load dictionary to my application. Now I can do it for file with size 1 047 673 byte and can not load file with size 1 048 804 byte. When I increased size to this value I got IOExeption in last line: InputStream is= getAssets().open(VOCAB.txt); size = is.available(); byte[] buffer = new byte[size]; is.read(buffer); Is there limit for size? And is there difference for limits for emulator and real device? Thanks, vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: different layout XML files in one application
Hellow, Thanks for example with ViewInflate. In this post I got annswer my question about combination xml layouts and layouts, which was created programmly. Now I can create my view programmly and add anything (in my cace- ProgressBar) from xml. Regards, vitvikt --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Picture and Buttons for different screen size
Thanks, Megha The QVGA-L and QVGA-P modes are not supported in the m5 SDK. Your application may still use them, but may face some issues with layout. It is recommended to use HVGA-L and HVGA-P modes. I used it only for test. Do you know about another emulators with another screen size? You can set the layout_height programatically using the LayoutParams class.http://code.google.com/android/reference/android/widget/LinearLayout Thanks. I did it. If you want to do this programatically, try using the constructor: ProgressDialog pd = new ProgressDialog(this, android.R.styleable.Theme_progressBarStyleHorizontal); I couldn't do it. OK. Now I decided forget about ProgressBar. I used ProgressBar and ProgressDialog at the same time, when I used xml layouts, but now I decided use only ProgressDialog, if it is so difficult or unimpossible to create ProgressBar programmly. Thank you very much. Vitaly --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Picture and Buttons for different screen size
Thanks, Megha But not all is clear for me. I did not understand, is it sufficient use only xml layouts or I have to change layouts in programm (in java text)? Using only xml layouts dosn't give me desired result. If I have to change layouts in programm, I don't now how can I replace constructions in xml LinearLayout android:layout_width=fill_parent android:layout_weight=0 android:layout_height=wrap_content com.google.android.ww2.WWView android:id=@+id/ww android:layout_width=fill_parent android:layout_height=300px/ /LinearLayout to construction in java text. This cnstruction I got from Snake example. In forum I find examples of creation LinearLayout, but how can I transform android:id=@+id/ww android:layout_width=fill_parent android:layout_height=300px/ to java text? Now I have mWwView = (WWView) findViewById(R.id.ww); Thanks, Vitaly --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] Announcing the new M5 SDK! http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---