[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Newsgroup Home]
|
[news.eclipse.platform] Question about Common Navigator and drop adapter assistants
|
I've got a common navigator viewer for which I need to do some
specialized drag-and-drop handling. I'm trying to define a
CommonDropAdapterAssistant to be used for certain file types. So in my
plugin.xml I have something like this:
<dropAssistant
class="org.skyway.core.ui.navigator.SkywayDropAssistant"
id="org.skyway.core.ui.navigator.dropAssistant">
<possibleDropTargets>
<adapt type="org.skyway.core.model.Container"></adapt>
</possibleDropTargets>
</dropAssistant>
The problem is, even when the drop target can not be adapted to a
org.skyway.core.model.Container, the drop operation is allowed to proceed.
I think this is because there is always a
org.eclipse.ui.navigator.resources.ResourceDropAdapterAssistant included
(it is declared by the plugin org.eclipse.ui.navigator.resources) and
it's possibleDropTargets expression includes any target that can be
adapted to an IFile, IFolder, or IProject.
So can I have a drop assistant that controls the validation of drops on
particular files and folders? In other words, can I override this
behavior of ResourceDropAdapterAssistant for certain resources, while
keeping it in place for everything else?
Eric