Gorgon Game Engine
DropTarget Class Reference

This layer acts as a drop target. More...

Inheritance diagram for DropTarget:
[legend]

Protected Member Functions

virtual bool propagate_mouseevent (Input::Mouse::EventType event, Geometry::Point location, Input::Mouse::Button button, float amount, MouseHandler &handlers) override
 Propagates a mouse event. Some events will be called directly. More...
 
- Protected Member Functions inherited from Layer
virtual void added (Layer &layer)
 Will be called when a layer is added. More...
 
void dotransformandclip (bool inverse=false)
 Performs transformation and clipping. Use inverse for reverse mapping for mouse events. More...
 
virtual void located (Layer *parent)
 Will be called when this layer is added to another. More...
 
virtual void removed (Layer &layer)
 Will be called when a layer is removed. More...
 
void reverttransformandclip ()
 Reverts previously done transformation. More...
 

Protected Attributes

std::function< void(DropTarget &, DragInfo &)> cancel
 
std::function< bool(DropTarget &, DragInfo &, Geometry::Point)> drop
 
std::function< bool(DropTarget &, Geometry::Point)> hitcheck
 
std::function< bool(DropTarget &, DragInfo &, Geometry::Point)> move
 
Geometry::Transform3D mytransform
 
std::function< void(DropTarget &, DragInfo &)> out
 
std::function< bool(DropTarget &, DragInfo &)> over
 
- Protected Attributes inherited from Layer
Geometry::Bounds bounds
 Bounds of this layer. More...
 
Containers::Collection< Layerchildren
 Child layers that this layer holds, all child layers are considered to be above current layer. More...
 
bool isvisible
 Whether this layer is visible, invisible layers will not be drawn or receive any events. More...
 
std::string name
 For debugging. More...
 
Layerparent
 Parent layer, could be nullptr. More...
 

Event handling

void SetHitCheck (std::function< bool(DropTarget &, Geometry::Point)> fn)
 Sets hit check function. More...
 
void SetHitCheck (std::function< bool(Geometry::Point)> fn)
 Sets hit check function. More...
 
template<class C_ >
void SetHitCheck (C_ &c, bool(C_::*fn)(DropTarget &, Geometry::Point))
 Sets hit check function. More...
 
template<class C_ >
void SetHitCheck (C_ &c, bool(C_::*fn)(Geometry::Point))
 Sets hit check function. More...
 
template<class C_ >
void SetHitCheck (C_ *my, bool(C_::*fn)(DropTarget &, Geometry::Point))
 Sets hit check function. More...
 
template<class C_ >
void SetHitCheck (C_ *my, bool(C_::*fn)(Geometry::Point))
 Sets hit check function. More...
 
void ResetHitCheck ()
 Removes hit check handler, default action for hit check is to return true. More...
 
void SetOver (std::function< bool(DropTarget &, DragInfo &)> fn)
 Sets over function. More...
 
void SetOver (std::function< bool(DragInfo &)> fn)
 Sets over function. More...
 
template<class C_ >
void SetOver (C_ &c, bool(C_::*fn)(DropTarget &, DragInfo &))
 Sets over function. More...
 
template<class C_ >
void SetOver (C_ &c, bool(C_::*fn)(DragInfo &))
 Sets over function. More...
 
template<class C_ >
void SetOver (C_ *my, bool(C_::*fn)(DropTarget &, DragInfo &))
 Sets over function. More...
 
template<class C_ >
void SetOver (C_ *my, bool(C_::*fn)(DragInfo &))
 Sets over function. More...
 
void ResetOver ()
 Removes over handler, default action for over is to return true. More...
 
void SetOut (std::function< void(DropTarget &, DragInfo &)> fn)
 Sets out function. More...
 
void SetOut (std::function< void(DragInfo &)> fn)
 Sets out function. More...
 
template<class C_ >
void SetOut (C_ &c, void(C_::*fn)(DropTarget &, DragInfo &))
 Sets out function. More...
 
template<class C_ >
void SetOut (C_ &c, void(C_::*fn)(DragInfo &))
 Sets out function. More...
 
template<class C_ >
void SetOut (C_ *my, void(C_::*fn)(DropTarget &, DragInfo &))
 Sets out function. More...
 
template<class C_ >
void SetOut (C_ *my, void(C_::*fn)(DragInfo &))
 Sets out function. More...
 
void ResetOut ()
 Removes out handler. More...
 
void SetMove (std::function< bool(DropTarget &, DragInfo &, Geometry::Point)> fn)
 Sets move function. More...
 
void SetMove (std::function< bool(DragInfo &, Geometry::Point)> fn)
 Sets move function. More...
 
template<class C_ >
void SetMove (C_ &c, bool(C_::*fn)(DropTarget &, DragInfo &, Geometry::Point))
 Sets move function. More...
 
template<class C_ >
void SetMove (C_ &c, bool(C_::*fn)(DragInfo &, Geometry::Point))
 Sets move function. More...
 
template<class C_ >
void SetMove (C_ *my, bool(C_::*fn)(DropTarget &, DragInfo &, Geometry::Point))
 Sets move function. More...
 
template<class C_ >
void SetMove (C_ *my, bool(C_::*fn)(DragInfo &, Geometry::Point))
 Sets move function. More...
 
void SetMove (std::function< bool(DropTarget &, DragInfo &)> fn)
 Sets move function. More...
 
void SetMove (std::function< bool(DragInfo &)> fn)
 Sets move function. More...
 
template<class C_ >
void SetMove (C_ &c, bool(C_::*fn)(DropTarget &, DragInfo &))
 Sets move function. More...
 
template<class C_ >
void SetMove (C_ &c, bool(C_::*fn)(DragInfo &))
 Sets move function. More...
 
template<class C_ >
void SetMove (C_ *my, bool(C_::*fn)(DropTarget &, DragInfo &))
 Sets move function. More...
 
template<class C_ >
void SetMove (C_ *my, bool(C_::*fn)(DragInfo &))
 Sets move function. More...
 
void ResetMove ()
 Removes move handler, default is to continue the drag operation. More...
 
void SetDrop (std::function< bool(DropTarget &, DragInfo &, Geometry::Point)> fn)
 Sets drop function. More...
 
void SetDrop (std::function< bool(DragInfo &, Geometry::Point)> fn)
 Sets drop function. More...
 
template<class C_ >
void SetDrop (C_ &c, bool(C_::*fn)(DropTarget &, DragInfo &, Geometry::Point))
 Sets drop function. More...
 
template<class C_ >
void SetDrop (C_ &c, bool(C_::*fn)(DragInfo &, Geometry::Point))
 Sets drop function. More...
 
template<class C_ >
void SetDrop (C_ *my, bool(C_::*fn)(DropTarget &, DragInfo &, Geometry::Point))
 Sets drop function. More...
 
template<class C_ >
void SetDrop (C_ *my, bool(C_::*fn)(DragInfo &, Geometry::Point))
 Sets drop function. More...
 
void SetDrop (std::function< bool(DropTarget &, DragInfo &)> fn)
 Sets drop function. More...
 
void SetDrop (std::function< bool(DragInfo &)> fn)
 Sets drop function. More...
 
template<class C_ >
void SetDrop (C_ &c, bool(C_::*fn)(DropTarget &, DragInfo &))
 Sets drop function. More...
 
template<class C_ >
void SetDrop (C_ &c, bool(C_::*fn)(DragInfo &))
 Sets drop function. More...
 
template<class C_ >
void SetDrop (C_ *my, bool(C_::*fn)(DropTarget &, DragInfo &))
 Sets drop function. More...
 
template<class C_ >
void SetDrop (C_ *my, bool(C_::*fn)(DragInfo &))
 Sets drop function. More...
 
void ResetDrop ()
 Removes drop handler, default is to cancel the drag operation. More...
 
void SetCancel (std::function< void(DropTarget &, DragInfo &)> fn)
 Sets cancel function. More...
 
void SetCancel (std::function< void(DragInfo &)> fn)
 Sets cancel function. More...
 
template<class C_ >
void SetCancel (C_ &c, void(C_::*fn)(DropTarget &, DragInfo &))
 Sets cancel function. More...
 
template<class C_ >
void SetCancel (C_ &c, void(C_::*fn)(DragInfo &))
 Sets cancel function. More...
 
template<class C_ >
void SetCancel (C_ *my, void(C_::*fn)(DropTarget &, DragInfo &))
 Sets cancel function. More...
 
template<class C_ >
void SetCancel (C_ *my, void(C_::*fn)(DragInfo &))
 Sets cancel function. More...
 
void ResetCancel ()
 Removes cancel handler. More...
 

Additional Inherited Members

- Public Member Functions inherited from Layer
 Layer ()
 Constructor that sets the layer to cover entire parent, no matter how big it is. More...
 
 Layer (const Geometry::Bounds &bounds)
 Initializing constructor. More...
 
 Layer (const Geometry::Point &location)
 Constructor that places the layer to the given location. More...
 
 Layer (const Layer &)=delete
 Copy constructor is disabled. More...
 
 Layer (Layer &&other)
 Move constructor. More...
 
virtual ~Layer ()
 Destructor. More...
 
virtual void Hide ()
 Hides this layer. More...
 
virtual bool IsVisible () const
 Returns whether this layer is effectively visible. More...
 
Layeroperator= (const Layer &)=delete
 Copy assignment is deleted. More...
 
Layeroperator= (Layer &&other)
 Move assignment. More...
 
virtual void Render ()
 Renders the current layer, default handling is to pass the request to the sub-layers. Rendering is not thread safe. More...
 
virtual void Show ()
 Displays this layer. More...
 
void Swap (Layer &other)
 Swaps two layers, mostly used for move semantics. More...
 
void Add (Layer &layer)
 Adds the given layer as a child. More...
 
void Add (Layer *layer)
 Adds the given layer as a child. More...
 
void setname (std::string value)
 For debugging. More...
 
void Insert (Layer &layer, long under)
 Inserts the given layer before the given index. More...
 
void Insert (Layer *layer, long under)
 Inserts the given layer before the given index. More...
 
void Remove (Layer &layer)
 Removes the given layer. More...
 
void Remove (Layer *layer)
 Removes the given layer. More...
 
bool HasParent () const
 Returns whether this layer has a parent. More...
 
virtual LayerGetParent () const
 Returns the parent of this layer. More...
 
LayerGetTopLevel () const
 Returns the top level layer that contains this layer. More...
 
virtual Geometry::Point TranslateToTopLevel (Geometry::Point location={0, 0}) const
 Translates the given location to the top level. More...
 
LayerGetTopLevel ()
 
Containers::Collection< Layer >::ConstIterator begin () const
 An iterator pointing to the start of the children. More...
 
Containers::Collection< Layer >::ConstIterator end () const
 An iterator pointing to the end of the children. More...
 
Containers::Collection< Layer >::ConstIterator First () const
 An iterator pointing to the start of the children. More...
 
Containers::Collection< Layer >::ConstIterator Last () const
 An iterator pointing to the last item of the children. More...
 
void PlaceBefore (int before)
 Places this layer before the given index. More...
 
void PlaceToTop ()
 Places this layer to the top of the layer stack its in. More...
 
void PlaceToBottom ()
 Places this layer to the bottom of the layer stack. More...
 
int GetOrder () const
 Gets the current order of the stack. More...
 
virtual void Move (const Geometry::Point &location)
 Moves this layer to the given location. More...
 
virtual void Move (int x, int y)
 Moves this layer to the given location. More...
 
virtual void Resize (const Geometry::Size &size)
 Resizes the layer to the given size. More...
 
virtual void Resize (int width, int height)
 Resizes the layer to the given size. More...
 
void SetWidth (int width)
 Resizes the layer to the given size. More...
 
void SetHeight (int height)
 Resizes the layer to the given size. More...
 
void SetBounds (const Geometry::Bounds &bounds)
 Sets the boundaries of this layer. More...
 
Geometry::Size GetSize () const
 Returns the size of the layer. More...
 
Geometry::Size GetCalculatedSize () const
 Returns the size of the layer. More...
 
int GetWidth () const
 Returns the width of the layer. More...
 
int GetHeight () const
 Returns the height of the layer. More...
 
Geometry::Point GetLocation () const
 Returns the current location of the layer. More...
 
int GetLeft () const
 Returns the current location of the layer. More...
 
int GetTop () const
 Returns the current location of the layer. More...
 
Geometry::Bounds GetBounds () const
 Returns the boundaries of the layer. More...
 
Geometry::Bounds GetEffectiveBounds () const
 Returns the effective boundaries of the layer. More...
 
- Public Attributes inherited from Layer
const Containers::Collection< Layer > & Children
 Sub-layers that this layer holds, all the sub-layers are considered to be above current layer. More...
 
- Static Public Attributes inherited from Layer
static const Geometry::Bounds EntireRegion
 When used as layer bounds, represents the entire region its placed in. More...
 

Detailed Description

This layer acts as a drop target.

Member Function Documentation

◆ propagate_mouseevent()

◆ ResetCancel()

void ResetCancel ( )

Removes cancel handler.

References DropTarget::cancel.

◆ ResetDrop()

void ResetDrop ( )

Removes drop handler, default is to cancel the drag operation.

References DropTarget::drop.

◆ ResetHitCheck()

void ResetHitCheck ( )

Removes hit check handler, default action for hit check is to return true.

References DropTarget::hitcheck.

◆ ResetMove()

void ResetMove ( )

Removes move handler, default is to continue the drag operation.

References DropTarget::move.

◆ ResetOut()

void ResetOut ( )

Removes out handler.

References DropTarget::out.

◆ ResetOver()

void ResetOver ( )

Removes over handler, default action for over is to return true.

References DropTarget::over.

◆ SetCancel() [1/6]

void SetCancel ( C_ &  c,
void(C_::*)(DragInfo &)  fn 
)

Sets cancel function.

If set, called whenever the DnD event that is accepted to be over this layer is canceled. This variant accepts class member function.

References DropTarget::cancel.

◆ SetCancel() [2/6]

void SetCancel ( C_ &  c,
void(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets cancel function.

If set, called whenever the DnD event that is accepted to be over this layer is canceled. This variant accepts class member function.

References DropTarget::cancel.

◆ SetCancel() [3/6]

void SetCancel ( C_ *  my,
void(C_::*)(DragInfo &)  fn 
)

Sets cancel function.

If set, called whenever the DnD event that is accepted to be over this layer is canceled. This variant accepts class member function.

References DropTarget::cancel.

◆ SetCancel() [4/6]

void SetCancel ( C_ *  my,
void(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets cancel function.

If set, called whenever the DnD event that is accepted to be over this layer is canceled. This variant accepts class member function.

References DropTarget::cancel.

◆ SetCancel() [5/6]

void SetCancel ( std::function< void(DragInfo &)>  fn)

Sets cancel function.

If set, called whenever the DnD event that is accepted to be over this layer is canceled.

References DropTarget::cancel.

◆ SetCancel() [6/6]

void SetCancel ( std::function< void(DropTarget &, DragInfo &)>  fn)

Sets cancel function.

If set, called whenever the DnD event that is accepted to be over this layer is canceled.

References DropTarget::cancel.

◆ SetDrop() [1/12]

void SetDrop ( C_ &  c,
bool(C_::*)(DragInfo &)  fn 
)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled. This variant accepts class member function.

References DropTarget::drop.

◆ SetDrop() [2/12]

void SetDrop ( C_ &  c,
bool(C_::*)(DragInfo &, Geometry::Point fn 
)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled. This variant accepts class member function.

References DropTarget::drop.

◆ SetDrop() [3/12]

void SetDrop ( C_ &  c,
bool(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled. This variant accepts class member function.

References DropTarget::drop.

◆ SetDrop() [4/12]

void SetDrop ( C_ &  c,
bool(C_::*)(DropTarget &, DragInfo &, Geometry::Point fn 
)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled. This variant accepts class member function.

References DropTarget::drop.

◆ SetDrop() [5/12]

void SetDrop ( C_ *  my,
bool(C_::*)(DragInfo &)  fn 
)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled. This variant accepts class member function.

References DropTarget::drop.

◆ SetDrop() [6/12]

void SetDrop ( C_ *  my,
bool(C_::*)(DragInfo &, Geometry::Point fn 
)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled. This variant accepts class member function.

References DropTarget::drop.

◆ SetDrop() [7/12]

void SetDrop ( C_ *  my,
bool(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled. This variant accepts class member function.

References DropTarget::drop.

◆ SetDrop() [8/12]

void SetDrop ( C_ *  my,
bool(C_::*)(DropTarget &, DragInfo &, Geometry::Point fn 
)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled. This variant accepts class member function.

References DropTarget::drop.

◆ SetDrop() [9/12]

void SetDrop ( std::function< bool(DragInfo &)>  fn)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled.

References DropTarget::drop.

◆ SetDrop() [10/12]

void SetDrop ( std::function< bool(DragInfo &, Geometry::Point)>  fn)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled.

References DropTarget::drop.

◆ SetDrop() [11/12]

void SetDrop ( std::function< bool(DropTarget &, DragInfo &)>  fn)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled.

References DropTarget::drop.

◆ SetDrop() [12/12]

void SetDrop ( std::function< bool(DropTarget &, DragInfo &, Geometry::Point)>  fn)

Sets drop function.

If set, called whenever an object is dropped to this layer. Returning false from this event's handler will cause drag operation to be canceled.

References DropTarget::drop.

◆ SetHitCheck() [1/6]

void SetHitCheck ( C_ &  c,
bool(C_::*)(DropTarget &, Geometry::Point fn 
)

Sets hit check function.

When set, events only occur if hit check returns true. Events follow hit check in a sequential manner, thus, if a handler is called, this means hit check has already succeeded in the current layout. This variant accepts class member function.

References DropTarget::hitcheck.

◆ SetHitCheck() [2/6]

void SetHitCheck ( C_ &  c,
bool(C_::*)(Geometry::Point fn 
)

Sets hit check function.

When set, events only occur if hit check returns true. Events follow hit check in a sequential manner, thus, if a handler is called, this means hit check has already succeeded in the current layout. This variant accepts class member function.

References DropTarget::hitcheck.

◆ SetHitCheck() [3/6]

void SetHitCheck ( C_ *  my,
bool(C_::*)(DropTarget &, Geometry::Point fn 
)

Sets hit check function.

When set, events only occur if hit check returns true. Events follow hit check in a sequential manner, thus, if a handler is called, this means hit check has already succeeded in the current layout. This variant accepts class member function.

References DropTarget::hitcheck.

◆ SetHitCheck() [4/6]

void SetHitCheck ( C_ *  my,
bool(C_::*)(Geometry::Point fn 
)

Sets hit check function.

When set, events only occur if hit check returns true. Events follow hit check in a sequential manner, thus, if a handler is called, this means hit check has already succeeded in the current layout. This variant accepts class member function.

References DropTarget::hitcheck.

◆ SetHitCheck() [5/6]

void SetHitCheck ( std::function< bool(DropTarget &, Geometry::Point)>  fn)

Sets hit check function.

When set, events only occur if hit check returns true. Events follow hit check in a sequential manner, thus, if a handler is called, this means hit check has already succeeded in the current layout.

References DropTarget::hitcheck.

◆ SetHitCheck() [6/6]

void SetHitCheck ( std::function< bool(Geometry::Point)>  fn)

Sets hit check function.

When set, events only occur if hit check returns true. Events follow hit check in a sequential manner, thus, if a handler is called, this means hit check has already succeeded in the current layout.

References DropTarget::hitcheck.

◆ SetMove() [1/12]

void SetMove ( C_ &  c,
bool(C_::*)(DragInfo &)  fn 
)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer. This variant accepts class member function.

References DropTarget::move.

◆ SetMove() [2/12]

void SetMove ( C_ &  c,
bool(C_::*)(DragInfo &, Geometry::Point fn 
)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer. This variant accepts class member function.

References DropTarget::move.

◆ SetMove() [3/12]

void SetMove ( C_ &  c,
bool(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer. This variant accepts class member function.

References DropTarget::move.

◆ SetMove() [4/12]

void SetMove ( C_ &  c,
bool(C_::*)(DropTarget &, DragInfo &, Geometry::Point fn 
)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer. This variant accepts class member function.

References DropTarget::move.

◆ SetMove() [5/12]

void SetMove ( C_ *  my,
bool(C_::*)(DragInfo &)  fn 
)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer. This variant accepts class member function.

References DropTarget::move.

◆ SetMove() [6/12]

void SetMove ( C_ *  my,
bool(C_::*)(DragInfo &, Geometry::Point fn 
)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer. This variant accepts class member function.

References DropTarget::move.

◆ SetMove() [7/12]

void SetMove ( C_ *  my,
bool(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer. This variant accepts class member function.

References DropTarget::move.

◆ SetMove() [8/12]

void SetMove ( C_ *  my,
bool(C_::*)(DropTarget &, DragInfo &, Geometry::Point fn 
)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer. This variant accepts class member function.

References DropTarget::move.

◆ SetMove() [9/12]

void SetMove ( std::function< bool(DragInfo &)>  fn)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer.

References DropTarget::move.

◆ SetMove() [10/12]

void SetMove ( std::function< bool(DragInfo &, Geometry::Point)>  fn)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer.

References DropTarget::move.

◆ SetMove() [11/12]

void SetMove ( std::function< bool(DropTarget &, DragInfo &)>  fn)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer.

References DropTarget::move.

◆ SetMove() [12/12]

void SetMove ( std::function< bool(DropTarget &, DragInfo &, Geometry::Point)>  fn)

Sets move function.

If set, called repeatedly as long as the object is over this layer. Returning false from this event's handler will cause drag operation to move out of this layer.

References DropTarget::move.

◆ SetOut() [1/6]

void SetOut ( C_ &  c,
void(C_::*)(DragInfo &)  fn 
)

Sets out function.

If set, called whenever an object is dragged out of this layer. This event is called even if over returns false. This variant accepts class member function.

References DropTarget::out.

◆ SetOut() [2/6]

void SetOut ( C_ &  c,
void(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets out function.

If set, called whenever an object is dragged out of this layer. This event is called even if over returns false. This variant accepts class member function.

References DropTarget::out.

◆ SetOut() [3/6]

void SetOut ( C_ *  my,
void(C_::*)(DragInfo &)  fn 
)

Sets out function.

If set, called whenever an object is dragged out of this layer. This event is called even if over returns false. This variant accepts class member function.

References DropTarget::out.

◆ SetOut() [4/6]

void SetOut ( C_ *  my,
void(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets out function.

If set, called whenever an object is dragged out of this layer. This event is called even if over returns false. This variant accepts class member function.

References DropTarget::out.

◆ SetOut() [5/6]

void SetOut ( std::function< void(DragInfo &)>  fn)

Sets out function.

If set, called whenever an object is dragged out of this layer. This event is called even if over returns false.

References DropTarget::out.

◆ SetOut() [6/6]

void SetOut ( std::function< void(DropTarget &, DragInfo &)>  fn)

Sets out function.

If set, called whenever an object is dragged out of this layer. This event is called even if over returns false.

References DropTarget::out.

◆ SetOver() [1/6]

void SetOver ( C_ &  c,
bool(C_::*)(DragInfo &)  fn 
)

Sets over function.

If set, called whenever an object is dragged over this layer. If event handler returns true, source will receive over event as well. This variant accepts class member function.

References DropTarget::over.

◆ SetOver() [2/6]

void SetOver ( C_ &  c,
bool(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets over function.

If set, called whenever an object is dragged over this layer. If event handler returns true, source will receive over event as well. This variant accepts class member function.

References DropTarget::over.

◆ SetOver() [3/6]

void SetOver ( C_ *  my,
bool(C_::*)(DragInfo &)  fn 
)

Sets over function.

If set, called whenever an object is dragged over this layer. If event handler returns true, source will receive over event as well. This variant accepts class member function.

References DropTarget::over.

◆ SetOver() [4/6]

void SetOver ( C_ *  my,
bool(C_::*)(DropTarget &, DragInfo &)  fn 
)

Sets over function.

If set, called whenever an object is dragged over this layer. If event handler returns true, source will receive over event as well. This variant accepts class member function.

References DropTarget::over.

◆ SetOver() [5/6]

void SetOver ( std::function< bool(DragInfo &)>  fn)

Sets over function.

If set, called whenever an object is dragged over this layer. If event handler returns true, source will receive over event as well.

References DropTarget::over.

◆ SetOver() [6/6]

void SetOver ( std::function< bool(DropTarget &, DragInfo &)>  fn)

Sets over function.

If set, called whenever an object is dragged over this layer. If event handler returns true, source will receive over event as well.

References DropTarget::over.

Member Data Documentation

◆ cancel

std::function<void(DropTarget &, DragInfo &)> cancel
protected

◆ drop

std::function<bool(DropTarget &, DragInfo &, Geometry::Point)> drop
protected

◆ hitcheck

std::function<bool(DropTarget &, Geometry::Point)> hitcheck
protected

◆ move

std::function<bool(DropTarget &, DragInfo &, Geometry::Point)> move
protected

◆ mytransform

Geometry::Transform3D mytransform
protected

◆ out

std::function<void(DropTarget &, DragInfo &)> out
protected

◆ over

std::function<bool(DropTarget &, DragInfo &)> over
protected

The documentation for this class was generated from the following files: