[android-developers] How to show scrollbar for a customizing view which is not drawn whole content

2012-08-29 Thread xeagle
I implement a customizing view and draw the content of view in "onDraw()". I draw only one page of content in "onDraw()". Now, I need show a scrollbar for this view. As I know, any view can support scrollbar. However, you must draw whole content of the view in "onDraw()" and use "scrollTo()" t

[android-developers] How to analyze the change of native memory allocation

2011-11-24 Thread xeagle
Hi, I use DDMS's native heap tool to analyze the memory allocation of native code. This tool is very useful. However, I'd like know newly created native memory when I do something on my phone. It seems that DDMS does not have this functionality. I heard that java's memory tool can compare 2 hprof

[android-developers] How to analyze memory usage of an app

2011-11-13 Thread xeagle
Hi, I try to debug an application which has an out of memory error. The app cannot allocate 3Mbytes in some condition. I analyze the adb log, there are some debug output of dalvikvm as below: dalvikvm: GC_FOR_MALLOC freed <1K, 47% free 4781K/8967K, external 55469K/57517K, paused 64ms dalvikvm: GC

[android-developers] what's the unit of "setStrokeWidth()" (dp or pixel)

2011-04-25 Thread xeagle
Hi, I need draw a "dotted line" in my app. I use codes below: Paint paint = new Paint(); paint.setColor(0xff00b900); paint.setStyle(Paint.Style.STROKE); paint.setStrokeWidth(1); paint.setPathEffect(new DashPathEffect(new float[] {5, 5, 5, 5}, 1)); ca

[android-developers] Could I show a text with dashed-line in TextView or EditText

2011-04-20 Thread xeagle
Hi, Android support rich editor. A underlined text can be shown in EditText view by using "UnderlineSpan". Now I'd like show a dashed under-line instead. Could I implement this effect? Thanks! -- You received this message because you are subscribed to the Google Groups "Android Developers" gro

[android-developers] which path will system load a JNI library from

2011-02-16 Thread xeagle
Hi, In my app, I'm using "System.loadLibrary()" to load my JNI library. It should load library from "/data/data/myapp/lib/". Then I add a invocation of "System.getenv("LD_LIBRARY_PATH")", and found that this system env is "/system/lib/". Does that means that system will load library from "/system/

[android-developers] which path will system load a JNI library from

2011-02-15 Thread xeagle
Hi, In my app, I'm using "System.loadLibrary()" to load my JNI library. It should load library from "/data/data/myapp/lib/". Then I add a invocation of "System.getenv("LD_LIBRARY_PATH")", and found that this system env is "/system/lib/". Does that means that system will load library from "/system/

[android-developers] Can I sign my app after it is built with platform

2011-01-23 Thread xeagle
Hi, I read in SDK doc, "Note that you can sign an .apk multiple times with different keys." I build my app with Android platform (not using SDK), and then sign the result apk with my private certificate. I'd like know that whether my apk contains right certificate. Is there any problem with my apk

[android-developers] Re: Could I exec some codes after my app is installed

2011-01-18 Thread xeagle
updated to a new version, not when my app is installed first time. Is that right? Thanks! On Jan 18, 5:32 pm, xeagle wrote: > Hi, > > When my app is downloaded from Market and installed, could some code > be executed? I'd like do something after my app is installed. Is there

[android-developers] Could I exec some codes after my app is installed

2011-01-18 Thread xeagle
Hi, When my app is downloaded from Market and installed, could some code be executed? I'd like do something after my app is installed. Is there any callback? Thanks He Chuan -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this

[android-developers] About "run app after installation using PACKAGE_ADDED or other mechanism"

2011-01-18 Thread xeagle
Can current version of Android allow an app to be told when it is updated? Thanks! -- Forwarded message -- From: Dianne Hackborn Date: Jul 25 2009, 1:02 am Subject: run app after installation using PACKAGE_ADDED or other mechanism? To: Android Developers I don't understand what

[android-developers] Does Android provide API to enable my IME

2011-01-16 Thread xeagle
Hi, I'd like my IME is enabled when settings of my IME is launched so that user do not need go to "Lanuage & Keyboard settings". Does Android provide this kind of API? -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group,

[android-developers] Re: Can "package installer" access private file of an app

2011-01-11 Thread xeagle
d readable.  The system itself doesn't have > permission to access your data unless you explicitly allow it.  See the flag > on Context to request a file you open  be world readable. > > > > On Tue, Jan 11, 2011 at 7:24 PM, xeagle wrote: > > I meet an issue when using b

[android-developers] Re: Can "package installer" access private file of an app

2011-01-11 Thread xeagle
: > You need to make the file world readable.  The system itself doesn't have > permission to access your data unless you explicitly allow it.  See the flag > on Context to request a file you open  be world readable. > > > > On Tue, Jan 11, 2011 at 7:24 PM, xeagle wrote: >

[android-developers] Can "package installer" access private file of an app

2011-01-11 Thread xeagle
I meet an issue when using below method. It works if apk file is put on sdcard. However, if there is no sdcard on phone, app must put apk file at "/data/data//xxx", package installer fail to install the apk because file in "/data/data//xxx" only has private permission. How do you deal with this iss

[android-developers] Does Market support installing multiple apks

2011-01-09 Thread xeagle
Hi, My application contains several apks. I'd like upload my app to android Market. If user download my app, can all of these apks be installed? Thanks! -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to an

[android-developers] Should I use "synchronized" for a boolean variable

2010-10-18 Thread xeagle
Hi, I use a boolean variable "flag" both in main and child thread. This "flag" is used to notify child thread to exit. I only use simple operation, e.g., "flag=false", "if (flag) {}". As I know, in java, "get and set a boolean variable" is atomic. So "synchronized" is not needed for variable "flag

[android-developers] How to determine size of a custom view

2010-02-02 Thread xeagle
Hi, I create a custom view "MyExpandedView". The size of this view should not be fixed, its size should be calculated at runtime. Shall I use "View.measure()" and "View.onMeasure()"? Or other method? Thank for your help! Note this custome view is in a ViewGroup. My layout file is below: http://s

[android-developers] Re: System.setProperty() cannot change system property in Android

2009-09-23 Thread xeagle
Thanks! Is there any other java API which can change system property? On Sep 23, 1:20 pm, "Mark Murphy" wrote: > > I use Java API "System.setProperty()" to set a system property.  After > > invoke "System.setProperty()", API "System.getProperty()" can return > > the value just I set. However, wh

[android-developers] System.setProperty() cannot change system property in Android

2009-09-22 Thread xeagle
I use Java API "System.setProperty()" to set a system property. After invoke "System.setProperty()", API "System.getProperty()" can return the value just I set. However, when I use command "adb shell getprop" to verify, it shows that this property is not set at all. Do I wrongly understand API "S