Home » U++ Library support » U++ Library : Other (not classified elsewhere) » draganddrop does not work
Re: draganddrop does not work [message #49793 is a reply to message #49792] |
Mon, 07 May 2018 17:55  |
Oblivion
Messages: 1226 Registered: August 2007
|
Senior Contributor |
|
|
Quote:Though there is one problem
void maintradetesterwindow::WithdataLayoutEx::DragAndDrop(Point p, PasteClip& d)
{
if(IsDragAndDropSource())
return;
Ctrl* c = GetDragAndDropTarget();
DUMP(c);
if (c!=nullptr)
if (c==&m->datasource_info.analyse)
{
if(AcceptFiles(d)) {
Vector<String> files2 = GetFiles(d);
m->analyse_a_file(files2[0]);
}
}
}
In general you don't need to manually handle them.
And frankly, I never needed to use GetDragAndDropTarget().
If you need to handle them manually either process the clip according to its data type, or override the given ctrl's DragAndDrop() method. That's it.
Best regards.
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Mon, 07 May 2018 18:27] Report message to a moderator
|
|
|
Goto Forum:
Current Time: Sat Aug 23 10:18:54 CEST 2025
Total time taken to generate the page: 0.03718 seconds
|