cannot drop on wxGrid with wxmac2.9
Riccardo Cohen
rcohen at articque.com
Mon Feb 25 05:30:55 PST 2008
yes it works with GetGridWindow().
for the windows platform : I tried to look at what happens, the
SetDropTarget called is wxWindowMSW::SetDropTarget().
If I use GetGridWindow(), I also enter wxWindowMSW::SetDropTarget(), but
probably not on the same wxWindow (m_gridWin)
For wxTextCtrl the program enters wxTextCtrl::SetDropTarget()
I don't know enough to go further. It seems to be based on
m_dropTarget->Register(m_hWnd) for windows and it may send the drop
event as long as m_hWnd is valid...
Thanks
Riccardo Cohen wrote:
> I'll check that quickly, but actually as wxGrid is a wxWindow, it
> "should" also work with wxGrid directly.
> Or maybe is it another problem with wxScrolledWindow on mac (the other
> one is that key event are not processed the same way as wxWindow)
>
> Vadim Zeitlin wrote:
>> On Fri, 22 Feb 2008 10:57:10 +0100 Riccardo Cohen
>> <rcohen at articque.com> wrote:
>>
>> RC> I try to drag and drop some file on a wxGrid, and it works on
>> windows RC> but not on mac (see code below)
>>
>> This is strange, I wouldn't expect this to work under Windows neither
>> and
>> would be really curious to know why/how does it work.
>>
>> RC> grid->SetDropTarget(new mydroptarget(this));
>>
>> I'm almost sure you need to associate the drop target with
>> grid->GetGridWindow() instead.
>>
>> Regards,
>> VZ
>>
>
--
Très cordialement,
Riccardo Cohen
-------------------------------------------
Articque
http://www.articque.com
149 av Général de Gaulle
37230 Fondettes - France
tel : 02-47-49-90-49
fax : 02-47-49-91-49
More information about the wx-users
mailing list