Solaris Common Desktop Environment: Programmer's Guide

Using Drag and Drop

To Integrate with Drag and Drop

To integrate your application with drag and drop, follow these steps:

  1. Include Dt/Dnd.h.

  2. Link to libDtsvc.

  3. As recipient:

    1. Register as a drop zone using DtDndDropRegister.

    2. Optionally, write a drop animate callback.

    3. Write a transfer callback.

  4. As source:

    1. Recognize user action (possibly requiring a modification of translation tables) and call DtDndDragStart.

    2. Write a convert callback.

    3. Write a drag finish callback.