Represents the touch surface of a BLOCKS device.
Public Member Functions | |
TouchSurface (Block &) | |
virtual | ~TouchSurface () |
Destructor. More... | |
virtual void | cancelAllActiveTouches () noexcept=0 |
Forces a touch-off message for all active touches. More... | |
virtual int | getNumberOfKeywaves () const =0 |
For the on-screen seaboard view, this will return the number of keys. More... | |
void | callListenersTouchChanged (const TouchSurface::Touch &t) |
Testing feature: this allows you to inject touches onto a touch surface. More... | |
void | addListener (Listener *) |
Adds a listener to be called when the surface is touched. More... | |
void | removeListener (Listener *) |
Removes a previously-registered listener. More... | |
Public Attributes | |
Block & | block |
The block that owns this touch surface. More... | |
Protected Attributes | |
juce::ListenerList< Listener > | listeners |
Classes | |
struct | Listener |
Receives callbacks when a touch moves or changes pressure. More... | |
struct | Touch |
Structure used to describe touch properties. More... | |
TouchSurface::TouchSurface | ( | Block & | ) |
|
virtual |
Destructor.
|
pure virtualnoexcept |
Forces a touch-off message for all active touches.
|
pure virtual |
For the on-screen seaboard view, this will return the number of keys.
For other types of touch-surface, it will return 0.
void TouchSurface::callListenersTouchChanged | ( | const TouchSurface::Touch & | t | ) |
Testing feature: this allows you to inject touches onto a touch surface.
References listeners, and TouchSurface::Listener::touchChanged().
void TouchSurface::addListener | ( | Listener * | ) |
Adds a listener to be called when the surface is touched.
void TouchSurface::removeListener | ( | Listener * | ) |
Removes a previously-registered listener.
Block& TouchSurface::block |
The block that owns this touch surface.
|
protected |
Referenced by callListenersTouchChanged().