Alright,
let me take a look. It will take a bit of time to get into this.

On Thu, Aug 19, 2010 at 10:43 AM, Mark Carter <mjc1...@googlemail.com> wrote:
> Thanks Satya. I saw that example and tried it out but its pretty clear
> that the content observers and dataset observers are being set on the
> wrapped MatrixCursor which is discarded as soon as setInternalCursor()
> is called...
>
> On Aug 19, 3:53 pm, Satya Komatineni <satya.komatin...@gmail.com>
> wrote:
>> Mark,
>> It has been a while I looked into this when I researched this stuff
>> for Live Folders chapter in "Pro Android 2" book.
>> I have some source code from the book here at the following URL. See
>> if this helps
>>
>> http://www.satyakomatineni.com/akc/display?url=DisplayNoteIMPURL&repo...
>>
>> Satya Komatinenihttp://www.satyakomatineni.comhttp://www.androidbook.com
>>
>>
>>
>>
>>
>> On Thu, Aug 19, 2010 at 3:22 AM, Mark Carter <mjc1...@googlemail.com> wrote:
>> > I want to implement Cursor so that it wraps another Cursor (probably
>> > MatrixCursor) and can swap out the wrapped Cursor as necessary.
>>
>> > I've tried two approaches:
>>
>> > 1. Subclass CursorWrapper. The problem with this is that any calls to
>> > registerX/unregisterX methods land on the wrapped cursor. Therefore,
>> > instead, the wrapping cursor needs to maintain these observers and how
>> > they are notified. This gets messy.
>>
>> > 2. Subclass AbstractCursor and override some methods to actually get
>> > the data from another cursor (the MatrixCursor). This is also tricky
>> > because you are trying to juggle two cursors as one. This just feels
>> > *wrong*.
>>
>> > Any thoughts?
>>
>> > --
>> > 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+unsubscr...@googlegroups.com
>> > For more options, visit this group at
>> >http://groups.google.com/group/android-developers?hl=en
>>
>> --
>
> --
> 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+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en



-- 
Satya Komatineni
http://www.satyakomatineni.com
http://www.androidbook.com

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to