Re: Custom GridView becomes Scroll-less

by Justin Anderson » Thu, 17 Mar 2011 00:09:11 GMT

Sponsored Links
 I have run into a similar issue with doing this on a Gallery view...  I
believe it is related to a bug in Android 2.1 and up.  Here is a link to my
StackOverflow question that has yet to be successfully answered (but there
have been some answers that may help in your case: 

Justin Anderson
MagouyaWare Developer 


Other Threads

1. Custom xfer modes for Paint/Canvas?


I'm writing an image editing application, making use of the Bitmap and
Canvas classes, and I need to edit the colors of pixels in specific
ways for some operations. For example, I'd like to be able to XOR
pixel values and create a multiply filter that works the same way as
in desktop image software.

With the current Porter Duff modes available (http://
that you set with Paint.setXfermode(..) I can't do either of these as
the XOR mode and multiply mode available don't treat alpha values the
way that I want. For example, the XOR operation should just XOR all
the bits together and not perform any calculations based on the alpha
value (Canvas does the latter when XOR is set).

My solution at the moment is to dump the two bitmaps I'm working with
to int arrays, perform the operation by hand using the int arrays (NDK
use would speed this up) and the copy the int arrays back. This is
slow and cumbersome and also means I can't e.g. use operations like
Canvas.drawBitmap with the filters I want.

Is it possible to introduce my own Porter Duff modes (e.g. using the
NDK)? This would be a much more elegant solution for me.

I'd appreciate any advice on alternative solutions too. As far as I'm
aware, it isn't possible to modify the contents of Bitmap objects
directly without copying to int arrays first.



2. Grab phonebook-contacts via ContactsContract-API


I'm totally stuck with the ContactsContract-API. Point is that I want
only mess around with the Contacts saved in the "local" phonebook. But
it seems that every vendor but its own account_type for those
And its even worse. The AccountManager isn't even aware of all
For example on my HTC Desire with HTC Sense, the account_type all
local contacts are saved in is: But when I grab
a list of all available accounts from the AccountManager: This account
is not in the list!?
I also tested it on a Samsung Galaxy. Same here: The AccountManager is
not aware of the account_type used for local phonebookcontacts.

The whole story is that I wan't to write a app to sync my locale
phonebook with OpenXchange.

I guess I got that whole new ContactsContract-API wrong, but I don't
see any other way, then using RawContacts. Due to that I have to care
about the account_type, which is in fact a total mess.

Hopefully someone can point me in the right direction. Every hint is
highly appreciated.


3. Edittext max characters - not set max

4. ENHANCEMENT: Allow java public static finals to be referenced from XML

5. Sending AVRCP play command, getting spammed with broadcast

6. Pretty sure Google Analytics for Android not working

7. Tablet support up to 2.2