I'm feeling dim...
Sven Langkamp
longamp at reallygood.de
Thu Sep 9 21:51:15 CEST 2004
Boudewijn Rempt wrote:
>On Thursday 09 September 2004 21:17, Sven Langkamp wrote:
>
>
>>Boudewijn Rempt wrote:
>>
>>
>>>But for the life of me I don't understand the following:
>>>
>>>given a method KisPainter::bitBlt(..., KisPaintDeviceSP dev,...);
>>>
>>>and a
>>>
>>>KisPaintDeviceSP dev = new KisLayer();
>>>
>>>why do I have to do
>>>
>>>bitBlt(..., dev.data(), ...); ?
>>>
>>>I know it works, but it looks wrong, and besides, I cannot figure out
>>>whose method data() is -- it looks like it comes from the shared pointer
>>>wrapper, but I cannot find it there.
>>>
>>>
>>Inherited from KisPaintDevice.
>>
>>
>
>But that's what I don't get -- normally, you use -> to get
>the methods of the shared pointered object, so . should point to
>the shared pointer wrapper. And KisPaintDevice::data() gives a
>tile manager back, not a KisPaintDevice -- which is the type of
>the parameter.
>
I was wrong. KSharedPointer.data() returns the pointer it contains which
is in this case the KisPaintDevice pointer.
More information about the kimageshop
mailing list