protected member variable mScrollX not accessible to subclasses of ViewGroup

by Marco Nelissen » Fri, 02 Oct 2009 22:17:54 GMT


Sponsored Links
 


Does it actually fail to build, or are you just talking about the
syntax highlighting?
mScrollX is a protected member of View, so should be accessible to any subclass.

--~--~---------~--~----~------------~-------~--~----~



protected member variable mScrollX not accessible to subclasses of ViewGroup

by Romain Guy » Fri, 02 Oct 2009 23:36:36 GMT


 mScrollX is not part of the public API. Use getScrollX() and
scrollBy()/scrollTo() to change it.







-- 
Romain Guy
Android framework engineer
romain...@android.com

Note: please don't send private questions to me, as I don't have time
to provide private support.  All such questions should be posted on
public forums, where I and others can see and answer them

--~--~---------~--~----~------------~-------~--~----~


Sponsored Links


Other Threads

1. how to get image data from browser using share to?

i want to share image from browser,my application can get the image
uri using"getIntent().getExtras().get(Intent.EXTRA_STREAM)":
uri:content://htcbrowser/share_image/data/data/com.android.browser/
app_sharedimage/images.jpeg?image/jpeg.but i find that the priviledge
of the  specified file only allow the owner user to read and write,how
to read the file in my application?

my english is poor,very 3ks.

-- 

2. uploading image + optional tags via HTTP POST

I found this bit of code.  Not put it to use yet, but looks good to
go.  The "data" object is the byte[] representing the image.

 PostMethod method;
                try {
                        HttpClient client = new HttpClient();
 
client.getHttpConnectionManager().getParams().setConnectionTimeout(
                                        5000);
                        method = new PostMethod(urlString);

                        Part[] parts = {
                                        new FilePart("videoFile", new
ByteArrayPartSource(
                                                        "videoFile",
data)),
                                        new StringPart("videoName",
filename) };
                        method.setRequestEntity(new
MultipartRequestEntity(parts, method
                                        .getParams()));
                        client.executeMethod(method);
                        response = method.getResponseBodyAsString();
                        method.releaseConnection();
                } catch (Exception ex) {
                        Log.v(TAG, "Exception", ex);
                } finally {
                        method.releaseConnection();
                }



> 

3. Retrieving GRP Coordinates, getting errors with getLastKnownLocation and requestLocationUpdates

4. Which thread invokes SensorEventListener.onSensorChanged

5. Redraw ListActivity with invalidate or postinvalidate onActivityResult not working

6. RingtoneManager getRingtone sometimes returns null

7. Custom view, instantiated in XML, overridden onDraw, canvas size outside allocated space.