Common Desktop Environment: Application Builder User's Guide

To Establish Drag and Drop Behavior

  1. Choose Drag and Drop from the Editors menu of the App Builder primary window.

    The Drag and Drop Editor is displayed.

  2. Choose an Object Type.

  3. Select an object in the Objects list.

  4. Select the Drag Operations you want to be legal for the selected object.

  5. To display a special cursor when a drag operation is being performed from the selected object, type the names of graphics files in the Cursor Filename and Cursor Mask Filename fields.

  6. Select the Data Types that will be legal for drag operations.

  7. Click Drag Connection.

    The Connections Editor is displayed.

  8. Choose Dragged From as the When action in the Connections Editor.

  9. Choose Call Function as the Action Type in the Connections Editor.

  10. Type a name for the called function in the Function text field in the Connections Editor.

    This is the name of the function that will be called when a drag operation is performed. You will have to edit the stubs.c file to make the called function do something useful. See "Adding User Code to Generated Code" for information.

  11. Click Connect in the Connections Editor.

  12. Click Cancel to dismiss the Connections Editor.

  13. Select which Drop Operations will be legal.

  14. Select the Data Types that will be legal for drop operations.

  15. Check Drop on Children if you want a drop operation on a child of the selected object to be legal.

    This is relevant only if the selected object has a child which is designated as a legal drop site.

  16. Click Drop Connection to display the Connections Editor.

  17. Choose Dropped On as the When action in the Connections Editor.

  18. Choose Call Function as the Action Type in the Connections Editor.

  19. Type a name for the called function in the Function text field in the Connections Editor.

    This is the name of the function that will be called when a drop operation is performed. You will have to edit the stubs.c file to make the called function do something useful. See "Adding User Code to Generated Code" for information.

  20. Click Connect in the Connections Editor.

  21. Click Cancel to dismiss the Connections Editor.

  22. Click OK or Apply in the Drag and Drop Editor to apply the changes.

    The Drag and Drop Editor will be dismissed if you click OK.