Module tool

This module exports a base class for you to extend in order to implement a custom tool class.

class Tool

Your custom tool class should inherit from this class. You only need to override the methods that you actually use.

Abstract Methods

activate()
deactivate(view)
draw(view)
getExtents()
getInstructorContentDirectory()
getMenu(menu)
onCancel(reason, view)
onKeyDown(key, repeat, flags, view)
onKeyUp(key, repeat, flags, view)
onLButtonDoubleClick(flags, x, y, view)
onLButtonDown(flags, x, y, view)
onLButtonUp(flags, x, y, view)
onMButtonDoubleClick(flags, x, y, view)
onMButtonDown(flags, x, y, view)
onMButtonUp(flags, x, y, view)
onMouseEnter(view)
onMouseLeave(view)
onMouseMove(flags, x, y, view)
onRButtonDoubleClick(flags, x, y, view)
onRButtonDown(flags, x, y, view)
onRButtonUp(flags, x, y, view)
onReturn(view)
onSetCursor()
onUserText(view)
resume(view)
suspend(view)