%ignore *::SetPositionInheritanceMode(PositionInheritanceMode);
%ignore *::GetKeyValue(SizeType) const;
%ignore *::TypeInfo::GetCreator() const;
+%ignore Dali::Stage::TouchedSignal;
%rename(ParentOriginTop) Dali::ParentOrigin::TOP;
%rename(ParentOriginBottom) Dali::ParentOrigin::BOTTOM;
%include <dali/public-api/events/pinch-gesture.h>
%include <dali/public-api/events/tap-gesture-detector.h>
%include <dali/public-api/events/tap-gesture.h>
-%include <dali/public-api/events/touch-event.h>
%include <dali/public-api/animation/alpha-function.h>
%include <dali/public-api/animation/key-frames.h>
//%template(ActorTouchEventSignal) Dali::Signal<bool (Dali::Actor, const Dali::TouchEvent&)>;
%template(ActorTouchDataSignal) Dali::Signal<bool (Dali::Actor, const Dali::TouchData&)>;
%template(ActorHoverSignal) Dali::Signal<bool (Dali::Actor, const Dali::HoverEvent&)>;
-%template(ActorWheelEventSignal) Dali::Signal<bool (Dali::Actor, const Dali::WheelEvent&)>;
+%template(ActorWheelSignal) Dali::Signal<bool (Dali::Actor, const Dali::WheelEvent&)>;
%template(ActorSignal) Dali::Signal<void (Dali::Actor)>;
%template(KeyEventSignal) Dali::Signal<void (const Dali::KeyEvent&)>;
//%template(TouchEventSignal) Dali::Signal<void (const Dali::TouchEvent&)>;
%template(TouchSignal) Dali::Signal<void (const Dali::TouchData&)>;
-%template(StageWheelEventSignal) Dali::Signal<void (const Dali::WheelEvent&)>;
+%template(StageWheelSignal) Dali::Signal<void (const Dali::WheelEvent&)>;
%template(AngleThresholdPair) std::pair<Dali::Radian, Dali::Radian>;
%template(PanGestureDetectedSignal) Dali::Signal<void (Dali::Actor, const Dali::PanGesture&)>;
%template(PinchGestureDetectedSignal) Dali::Signal<void (Dali::Actor, const Dali::PinchGesture&)>;
%}
%enddef
+%define DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION_RENAME( NameSpace, ClassName, NewClassName )
+%typemap(csfinalize) NameSpace::ClassName %{
+ ~NewClassName() {
+ DisposeQueue.Instance.Add(this);
+ }
+%}
+%enddef
+
+%define DALI_CREATE_CUSTOM_DISPOSE_FUNCTION_RENAME( NameSpace, ClassName, NewClassName )
+%typemap(csdestruct, methodname="Dispose", methodmodifiers="public") NameSpace::ClassName %{{
+ if (!Stage.IsInstalled()) {
+ DisposeQueue.Instance.Add(this);
+ return;
+ }
+
+ lock(this) {
+ if (swigCPtr.Handle != global::System.IntPtr.Zero) {
+ if (swigCMemOwn) {
+ swigCMemOwn = false;
+ NDalicPINVOKE.delete_##NewClassName(swigCPtr);
+ }
+ swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
+ }
+ global::System.GC.SuppressFinalize(this);
+ }
+ }
+%}
+%enddef
+
+%define DALI_CREATE_CUSTOM_DISPOSE_DERIVED_FUNCTION_RENAME( NameSpace, ClassName, NewClassName )
+%typemap(csdestruct_derived, methodname="Dispose", methodmodifiers="public") NameSpace::ClassName %{{
+ if (!Stage.IsInstalled()) {
+ DisposeQueue.Instance.Add(this);
+ return;
+ }
+
+ lock(this) {
+ if (swigCPtr.Handle != global::System.IntPtr.Zero) {
+ if (swigCMemOwn) {
+ swigCMemOwn = false;
+ NDalicPINVOKE.delete_##NewClassName(swigCPtr);
+ }
+ swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
+ }
+ global::System.GC.SuppressFinalize(this);
+ base.Dispose();
+ }
+ }
+%}
+%enddef
+
%define DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION_VIDEOVIEWSIGNAL( NameSpace, ClassName )
%typemap(csfinalize) NameSpace::ClassName %{
~VideoViewSignal() {
%define DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION_STAGESIGNAL( NameSpace, ClassName )
%typemap(csfinalize) NameSpace::ClassName %{
- ~StageWheelEventSignal() {
+ ~StageWheelSignal() {
DisposeQueue.Instance.Add(this);
}
%}
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
- NDalicPINVOKE.delete_StageWheelEventSignal(swigCPtr);
+ NDalicPINVOKE.delete_StageWheelSignal(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION( Dali, LongPressGestureDetector );
DALI_CREATE_CUSTOM_DISPOSE_DERIVED_FUNCTION( Dali, LongPressGestureDetector );
-DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION( Dali, KeyEvent );
-DALI_CREATE_CUSTOM_DISPOSE_FUNCTION( Dali, KeyEvent );
+DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION_RENAME( Dali, KeyEvent, Key );
+DALI_CREATE_CUSTOM_DISPOSE_FUNCTION_RENAME( Dali, KeyEvent, Key );
+DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION_RENAME( Dali, HoverEvent, Hover );
+DALI_CREATE_CUSTOM_DISPOSE_FUNCTION_RENAME( Dali, HoverEvent, Hover );
DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION( Dali, TouchEvent );
DALI_CREATE_CUSTOM_DISPOSE_FUNCTION( Dali, TouchEvent );
-DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION( Dali, WheelEvent );
-DALI_CREATE_CUSTOM_DISPOSE_FUNCTION( Dali, WheelEvent );
+DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION_RENAME( Dali, WheelEvent, Wheel );
+DALI_CREATE_CUSTOM_DISPOSE_FUNCTION_RENAME( Dali, WheelEvent, Wheel );
DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION( Dali, Renderer );
DALI_CREATE_CUSTOM_DISPOSE_DERIVED_FUNCTION( Dali, Renderer );
DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION( Dali, TouchPoint );
DALI_CREATE_CUSTOM_DISPOSE_FUNCTION( Dali, TouchPoint );
-DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION( Dali, TouchData );
-DALI_CREATE_CUSTOM_DISPOSE_DERIVED_FUNCTION( Dali, TouchData );
+DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION_RENAME( Dali, TouchData, Touch );
+DALI_CREATE_CUSTOM_DISPOSE_DERIVED_FUNCTION_RENAME( Dali, TouchData, Touch );
DALI_CREATE_CUSTOM_DESTRUCTOR_FUNCTION( Dali, Application );
DALI_CREATE_CUSTOM_DISPOSE_DERIVED_FUNCTION( Dali, Application );
%ignore *::Button::SetUnselectedImage(const std::string &);
%ignore Dali::Toolkit::DevelVisual::Type;
%ignore Dali::Toolkit::DevelVisual::Property::Type;
+%ignore Dali::Toolkit::AccessibilityManager::AccessibilityActionScrollSignalType;
%rename(View) Dali::Toolkit::Control;
%rename(ViewImpl) Dali::Toolkit::Internal::Control;
%template(ItemContainer) std::vector<std::pair<unsigned int, Dali::Actor>>;
%template(ActorContainer) std::vector<Dali::Actor>;
%template(AccessibilityActionSignal) Dali::Signal<bool(Dali::Toolkit::AccessibilityManager&)>;
-%template(AccessibilityActionScrollSignal) Dali::Signal<bool(Dali::Toolkit::AccessibilityManager&, const Dali::TouchEvent&)>;
%template(AccessibilityFocusOvershotSignal) Dali::Signal<void(Dali::Actor, Dali::Toolkit::AccessibilityManager::FocusOvershotDirection)>;
%template(FocusChangedSignal) Dali::Signal<void(Dali::Actor, Dali::Actor)>;
%template(FocusGroupChangedSignal) Dali::Signal<void(Dali::Actor, bool)>;
%template(ScrollableSignal) Dali::Signal< void(const Dali::Vector2&)>;
%template(TextEditorSignal) Dali::Signal<void(Dali::Toolkit::TextEditor)>;
%template(TextFieldSignal) Dali::Signal<void(Dali::Toolkit::TextField)>;
-%template(ControlKeyEventSignal) Dali::Signal<bool(Dali::Toolkit::Control, const Dali::KeyEvent&)>;
+%template(ControlKeySignal) Dali::Signal<bool(Dali::Toolkit::Control, const Dali::KeyEvent&)>;
%template(KeyInputFocusSignal) Dali::Signal<void(Dali::Toolkit::Control)>;
%template(VideoViewSignal) Dali::Signal<void(Dali::Toolkit::VideoView&)>;
%template(SliderValueChangedSignal) Dali::Signal<bool(Dali::Toolkit::Slider, float)>;
%include devel-properties.i
%include gestures/hover.i
-
+%include gestures/gesture.i
+%include gestures/long-press-gesture.i
+%include gestures/pan-gesture.i
+%include gestures/tap-gesture.i
+%include gestures/pinch-gesture.i
+%include gestures/wheel.i
+%include gestures/touch.i
+%include gestures/key.i
%include dali-core.i
%include dali-adaptor.i
* @brief Event arguments that passed via ActionScroll signal
*
*/
+/*
+ // To be replaced by a new event that takes Touch
public class ActionScrollEventArgs : EventArgs
{
private AccessibilityManager _accessibilityManager;
}
}
}
+*/
/**
* @brief Event arguments that passed via ActionPageUp signal
private DaliEventHandlerWithReturnType<object,ActionStartStopEventArgs,bool> _accessibilityManagerActionStartStopEventHandler;
private ActionStartStopEventCallbackDelegate _accessibilityManagerActionStartStopEventCallbackDelegate;
+/*
+ // To be replaced by a new event that takes Touch
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
private delegate bool ActionScrollEventCallbackDelegate(IntPtr accessibilityManager, IntPtr touchEvent);
private DaliEventHandlerWithReturnType<object,ActionScrollEventArgs,bool> _accessibilityManagerActionScrollEventHandler;
private ActionScrollEventCallbackDelegate _accessibilityManagerActionScrollEventCallbackDelegate;
+*/
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
private delegate void FocusChangedEventCallbackDelegate(IntPtr actor1, IntPtr actor2);
return false;
}
+/*
+ // To be replaced by a new event that takes Touch
public event DaliEventHandlerWithReturnType<object,ActionScrollEventArgs,bool> ActionScroll
{
add
}
return false;
}
+*/
public event DaliEventHandler<object,FocusChangedEventArgs> FocusChanged
{
}
/**
- * @brief Event arguments that passed via KeyEvent signal
+ * @brief Event arguments that passed via Key signal
*
*/
public class KeyEventArgs : EventArgs
{
private View _view;
- private KeyEvent _keyEvent;
+ private Key _key;
/**
- * @brief View - is the view that recieves the keyevent.
+ * @brief View - is the view that recieves the key.
*
*/
public View View
}
/**
- * @brief KeyEvent - is the keyevent sent to the View.
+ * @brief Key - is the key sent to the View.
*
*/
- public KeyEvent KeyEvent
+ public Key Key
{
get
{
- return _keyEvent;
+ return _key;
}
set
{
- _keyEvent = value;
+ _key = value;
}
}
}
public class TouchEventArgs : EventArgs
{
private View _view;
- private TouchData _touchData;
+ private Touch _touch;
/**
* @brief View - is the view that is being touched
}
/**
- * @brief TouchData - contains the information of touch points
+ * @brief Touch - contains the information of touch points
*
*/
- public TouchData TouchData
+ public Touch Touch
{
get
{
- return _touchData;
+ return _touch;
}
set
{
- _touchData = value;
+ _touch = value;
}
}
}
* @brief Event arguments that passed via Hover signal
*
*/
- public class HoverArgs : EventArgs
+ public class HoverEventArgs : EventArgs
{
- private View _view;
- private Hover _hover;
+ private View _view;
+ private Hover _hover;
/**
* @brief View - is the view that is being hovered
*/
public class WheelEventArgs : EventArgs
{
- private View _view;
- private WheelEvent _wheelEvent;
+ private View _view;
+ private Wheel _wheel;
/**
* @brief View - is the view that is being wheeled
}
/**
- * @brief WheelEvent - store a wheel rolling type : MOUSE_WHEEL or CUSTOM_WHEEL
+ * @brief Wheel - store a wheel rolling type : MOUSE_WHEEL or CUSTOM_WHEEL
*
*/
- public WheelEvent WheelEvent
+ public Wheel Wheel
{
get
{
- return _wheelEvent;
+ return _wheel;
}
set
{
- _wheelEvent = value;
+ _wheel = value;
}
}
}
private KeyInputFocusLostCallbackDelegate _KeyInputFocusLostCallbackDelegate;
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
- private delegate bool KeyCallbackDelegate(IntPtr control, IntPtr keyEvent);
- private DaliEventHandlerWithReturnType<object,KeyEventArgs,bool> _KeyEventHandler;
+ private delegate bool KeyCallbackDelegate(IntPtr control, IntPtr key);
+ private DaliEventHandlerWithReturnType<object,KeyEventArgs,bool> _KeyHandler;
private KeyCallbackDelegate _KeyCallbackDelegate;
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
private OnRelayoutEventCallbackDelegate _viewOnRelayoutEventCallbackDelegate;
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
- private delegate bool TouchCallbackDelegate(IntPtr view, IntPtr touchData);
- private DaliEventHandlerWithReturnType<object,TouchEventArgs,bool> _viewTouchDataEventHandler;
- private TouchCallbackDelegate _viewTouchDataCallbackDelegate;
+ private delegate bool TouchCallbackDelegate(IntPtr view, IntPtr touch);
+ private DaliEventHandlerWithReturnType<object,TouchEventArgs,bool> _viewTouchHandler;
+ private TouchCallbackDelegate _viewTouchCallbackDelegate;
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
private delegate bool HoverCallbackDelegate(IntPtr view, IntPtr hover);
- private DaliEventHandlerWithReturnType<object,HoverArgs,bool> _viewHoverHandler;
+ private DaliEventHandlerWithReturnType<object,HoverEventArgs,bool> _viewHoverHandler;
private HoverCallbackDelegate _viewHoverCallbackDelegate;
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
- private delegate bool WheelEventCallbackDelegate(IntPtr view, IntPtr wheelEvent);
- private DaliEventHandlerWithReturnType<object,WheelEventArgs,bool> _viewWheelEventHandler;
- private WheelEventCallbackDelegate _viewWheelEventCallbackDelegate;
+ private delegate bool WheelCallbackDelegate(IntPtr view, IntPtr wheel);
+ private DaliEventHandlerWithReturnType<object,WheelEventArgs,bool> _viewWheelHandler;
+ private WheelCallbackDelegate _viewWheelCallbackDelegate;
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
private delegate void OnStageEventCallbackDelegate(IntPtr control);
if (_KeyInputFocusGainedEventHandler == null)
{
_KeyInputFocusGainedEventHandler += value;
- Console.WriteLine("View Keyevent EVENT Locked....");
+ Console.WriteLine("View Key EVENT Locked....");
_KeyInputFocusGainedCallbackDelegate = new KeyInputFocusGainedCallbackDelegate(OnKeyInputFocusGained);
this.KeyInputFocusGainedSignal().Connect(_KeyInputFocusGainedCallbackDelegate);
}
private void OnKeyInputFocusGained(IntPtr view)
{
KeyInputFocusGainedEventArgs e = new KeyInputFocusGainedEventArgs();
- Console.WriteLine("View Keyevent ....");
+ Console.WriteLine("View Key ....");
// Populate all members of "e" (KeyInputFocusGainedEventArgs) with real data
e.View = Dali.View.GetViewFromPtr(view);
/**
* @brief Event for KeyPressed signal which can be used to subscribe/unsubscribe the event handler
- * (in the type of KeyEventEventHandler-DaliEventHandlerWithReturnType<object,KeyEventArgs,bool>)
+ * (in the type of KeyHandler-DaliEventHandlerWithReturnType<object,KeyEventArgs,bool>)
* provided by the user. KeyPressed signal is emitted when key event is received.
*/
public event DaliEventHandlerWithReturnType<object,KeyEventArgs,bool> KeyPressed
lock(this)
{
// Restricted to only one listener
- if (_KeyEventHandler == null)
+ if (_KeyHandler == null)
{
- _KeyEventHandler += value;
+ _KeyHandler += value;
- _KeyCallbackDelegate = new KeyCallbackDelegate(OnKeyEvent);
+ _KeyCallbackDelegate = new KeyCallbackDelegate(OnKey);
this.KeyEventSignal().Connect(_KeyCallbackDelegate);
}
}
{
lock(this)
{
- if (_KeyEventHandler != null)
+ if (_KeyHandler != null)
{
this.KeyEventSignal().Disconnect(_KeyCallbackDelegate);
}
- _KeyEventHandler -= value;
+ _KeyHandler -= value;
}
}
}
- private bool OnKeyEvent(IntPtr view, IntPtr keyEvent)
+ private bool OnKey(IntPtr view, IntPtr key)
{
KeyEventArgs e = new KeyEventArgs();
// Populate all members of "e" (KeyEventArgs) with real data
e.View = Dali.View.GetViewFromPtr(view);
- e.KeyEvent = Dali.KeyEvent.GetKeyEventFromPtr(keyEvent);
+ e.Key = Dali.Key.GetKeyFromPtr(key);
- if (_KeyEventHandler != null)
+ if (_KeyHandler != null)
{
//here we send all data to user event handlers
- return _KeyEventHandler(this, e);
+ return _KeyHandler(this, e);
}
return false;
/**
* @brief Event for Touched signal which can be used to subscribe/unsubscribe the event handler
- * (in the type of TouchEventHandler-DaliEventHandlerWithReturnType<object,TouchEventArgs,bool>)
+ * (in the type of TouchHandler-DaliEventHandlerWithReturnType<object,TouchEventArgs,bool>)
* provided by the user. Touched signal is emitted when touch input is received.
*/
public event DaliEventHandlerWithReturnType<object,TouchEventArgs,bool> Touched
lock(this)
{
// Restricted to only one listener
- if (_viewTouchDataEventHandler == null)
+ if (_viewTouchHandler == null)
{
- _viewTouchDataEventHandler += value;
+ _viewTouchHandler += value;
Console.WriteLine("View Touch EVENT LOCKED....");
- _viewTouchDataCallbackDelegate = new TouchCallbackDelegate(OnTouch);
- this.TouchSignal().Connect(_viewTouchDataCallbackDelegate);
+ _viewTouchCallbackDelegate = new TouchCallbackDelegate(OnTouch);
+ this.TouchSignal().Connect(_viewTouchCallbackDelegate);
}
}
}
{
lock(this)
{
- if (_viewTouchDataEventHandler != null)
+ if (_viewTouchHandler != null)
{
- this.TouchSignal().Disconnect(_viewTouchDataCallbackDelegate);
+ this.TouchSignal().Disconnect(_viewTouchCallbackDelegate);
}
- _viewTouchDataEventHandler -= value;
+ _viewTouchHandler -= value;
}
}
}
// Callback for View TouchSignal
- private bool OnTouch(IntPtr view, IntPtr touchData)
+ private bool OnTouch(IntPtr view, IntPtr touch)
{
TouchEventArgs e = new TouchEventArgs();
Console.WriteLine("View Touch EVENT....");
// Populate all members of "e" (TouchEventArgs) with real data
e.View = View.GetViewFromPtr(view);
- e.TouchData = Dali.TouchData.GetTouchDataFromPtr(touchData);
+ e.Touch = Dali.Touch.GetTouchFromPtr(touch);
- if (_viewTouchDataEventHandler != null)
+ if (_viewTouchHandler != null)
{
//here we send all data to user event handlers
- return _viewTouchDataEventHandler(this, e);
+ return _viewTouchHandler(this, e);
}
return false;
/**
* @brief Event for Hovered signal which can be used to subscribe/unsubscribe the event handler
- * (in the type of HoverHandler-DaliEventHandlerWithReturnType<object,HoverArgs,bool>)
+ * (in the type of HoverHandler-DaliEventHandlerWithReturnType<object,HoverEventArgs,bool>)
* provided by the user. Hovered signal is emitted when hover input is received.
*/
- public event DaliEventHandlerWithReturnType<object,HoverArgs,bool> Hovered
+ public event DaliEventHandlerWithReturnType<object,HoverEventArgs,bool> Hovered
{
add
{
// Callback for View Hover signal
private bool OnHover(IntPtr view, IntPtr hover)
{
- HoverArgs e = new HoverArgs();
+ HoverEventArgs e = new HoverEventArgs();
- // Populate all members of "e" (HoverArgs) with real data
+ // Populate all members of "e" (HoverEventArgs) with real data
e.View = View.GetViewFromPtr(view);
e.Hover = Dali.Hover.GetHoverFromPtr(hover);
/**
* @brief Event for WheelMoved signal which can be used to subscribe/unsubscribe the event handler
- * (in the type of WheelEventHandler-DaliEventHandlerWithReturnType<object,WheelEventArgs,bool>)
+ * (in the type of WheelHandler-DaliEventHandlerWithReturnType<object,WheelEventArgs,bool>)
* provided by the user. WheelMoved signal is emitted when wheel event is received.
*/
public event DaliEventHandlerWithReturnType<object,WheelEventArgs,bool> WheelMoved
lock(this)
{
// Restricted to only one listener
- if (_viewWheelEventHandler == null)
+ if (_viewWheelHandler == null)
{
- _viewWheelEventHandler += value;
+ _viewWheelHandler += value;
Console.WriteLine("View Wheel EVENT LOCKED....");
- _viewWheelEventCallbackDelegate = new WheelEventCallbackDelegate(OnWheelEvent);
- this.WheelEventSignal().Connect(_viewWheelEventCallbackDelegate);
+ _viewWheelCallbackDelegate = new WheelCallbackDelegate(OnWheel);
+ this.WheelEventSignal().Connect(_viewWheelCallbackDelegate);
}
}
}
{
lock(this)
{
- if (_viewWheelEventHandler != null)
+ if (_viewWheelHandler != null)
{
- this.WheelEventSignal().Disconnect(_viewWheelEventCallbackDelegate);
+ this.WheelEventSignal().Disconnect(_viewWheelCallbackDelegate);
}
- _viewWheelEventHandler -= value;
+ _viewWheelHandler -= value;
}
}
}
// Callback for View Wheel signal
- private bool OnWheelEvent(IntPtr view, IntPtr wheelEvent)
+ private bool OnWheel(IntPtr view, IntPtr wheel)
{
WheelEventArgs e = new WheelEventArgs();
Console.WriteLine("View Wheel EVENT ....");
// Populate all members of "e" (WheelEventArgs) with real data
e.View = View.GetViewFromPtr(view);
- e.WheelEvent = Dali.WheelEvent.GetWheelEventFromPtr(wheelEvent);
+ e.Wheel = Dali.Wheel.GetWheelFromPtr(wheel);
- if (_viewWheelEventHandler != null)
+ if (_viewWheelHandler != null)
{
//here we send all data to user event handlers
- return _viewWheelEventHandler(this, e);
+ return _viewWheelHandler(this, e);
}
return false;
*/
public class TouchEventArgs : EventArgs
{
- private TouchData _touchData;
+ private Touch _touch;
/**
- * @brief TouchData - contains the information of touch points
+ * @brief Touch - contains the information of touch points
*
*/
- public TouchData TouchData
+ public Touch Touch
{
get
{
- return _touchData;
+ return _touch;
}
set
{
- _touchData = value;
+ _touch = value;
}
}
}
- private event EventHandler<TouchEventArgs> _stageTouchEventHandler;
+ private event EventHandler<TouchEventArgs> _stageTouchHandler;
private EventCallbackDelegateType1<IntPtr> _stageTouchCallbackDelegate;
/**
* (i.e. the down & up touch events only).
*
*/
- public event EventHandler<TouchEventArgs> TouchEvent
+ public event EventHandler<TouchEventArgs> Touch
{
add
{
lock(this)
{
- _stageTouchEventHandler += value;
+ _stageTouchHandler += value;
_stageTouchCallbackDelegate = OnStageTouch;
this.TouchSignal().Connect(_stageTouchCallbackDelegate);
}
{
lock(this)
{
- if (_stageTouchEventHandler != null)
+ if (_stageTouchHandler != null)
{
this.TouchSignal().Disconnect(_stageTouchCallbackDelegate);
}
- _stageTouchEventHandler -= value;
+ _stageTouchHandler -= value;
}
}
}
if( data != null )
{
- e.TouchData = TouchData.GetTouchDataFromPtr( data );
+ e.Touch = Dali.Touch.GetTouchFromPtr( data );
}
- if (_stageTouchEventHandler != null)
+ if (_stageTouchHandler != null)
{
- _stageTouchEventHandler(this, e);
+ _stageTouchHandler(this, e);
}
}
-
/**
- * @brief WheelEvent arguments that passed via Wheel signal
+ * @brief Wheel arguments that passed via Wheel signal
*
*/
public class WheelEventArgs : EventArgs
{
- private WheelEvent _wheelEvent;
+ private Wheel _wheel;
/**
- * @brief WheelEvent - store a wheel rolling type MOUSE_WHEEL or CUSTOM_WHEEL
+ * @brief Wheel - store a wheel rolling type MOUSE_WHEEL or CUSTOM_WHEEL
*
*/
- public WheelEvent WheelEvent
+ public Wheel Wheel
{
get
{
- return _wheelEvent;
+ return _wheel;
}
set
{
- _wheelEvent = value;
+ _wheel = value;
}
}
}
- private event EventHandler<WheelEventArgs> _stageWheelEventHandler;
+ private event EventHandler<WheelEventArgs> _stageWheelHandler;
private EventCallbackDelegateType1<IntPtr> _stageWheelCallbackDelegate;
/**
- * @brief Event for WheelEvent signal which can be used to subscribe/unsubscribe the event handler
- * WheelEvent signal is emitted is emitted when wheel event is received.
+ * @brief Event for Wheel signal which can be used to subscribe/unsubscribe the event handler
+ * Wheel signal is emitted is emitted when wheel event is received.
*
*/
- public event EventHandler<WheelEventArgs> WheelEvent
+ public event EventHandler<WheelEventArgs> Wheel
{
add
{
lock(this)
{
- _stageWheelEventHandler += value;
+ _stageWheelHandler += value;
_stageWheelCallbackDelegate = OnStageWheel;
this.WheelEventSignal().Connect(_stageWheelCallbackDelegate);
}
{
lock(this)
{
- if (_stageWheelEventHandler != null)
+ if (_stageWheelHandler != null)
{
this.WheelEventSignal().Disconnect(_stageWheelCallbackDelegate);
}
- _stageWheelEventHandler -= value;
+ _stageWheelHandler -= value;
}
}
}
if( data != null )
{
- e.WheelEvent = Dali.WheelEvent.GetWheelEventFromPtr( data );
+ e.Wheel = Dali.Wheel.GetWheelFromPtr( data );
}
- if (_stageWheelEventHandler != null)
+ if (_stageWheelHandler != null)
{
- _stageWheelEventHandler(this, e);
+ _stageWheelHandler(this, e);
}
}
/**
- * @brief Event arguments that passed via KeyEvent signal
+ * @brief Event arguments that passed via Key signal
*
*/
public class KeyEventArgs : EventArgs
{
- private KeyEvent _keyEvent;
+ private Key _key;
/**
- * @brief KeyEvent - is the keyevent sent to Stage.
+ * @brief Key - is the keyevent sent to Stage.
*
*/
- public KeyEvent KeyEvent
+ public Key Key
{
get
{
- return _keyEvent;
+ return _key;
}
set
{
- _keyEvent = value;
+ _key = value;
}
}
}
- private event EventHandler<KeyEventArgs> _stageKeyEventHandler;
+ private event EventHandler<KeyEventArgs> _stageKeyHandler;
private EventCallbackDelegateType1<IntPtr> _stageKeyCallbackDelegate;
/**
- * @brief Event for KeyEvent signal which can be used to subscribe/unsubscribe the event handler
- * KeyEvent signal is emitted is emitted when key event is received.
+ * @brief Event for Key signal which can be used to subscribe/unsubscribe the event handler
+ * Key signal is emitted is emitted when key event is received.
*
*/
- public event EventHandler<KeyEventArgs> KeyEvent
+ public event EventHandler<KeyEventArgs> Key
{
add
{
lock(this)
{
- _stageKeyEventHandler += value;
+ _stageKeyHandler += value;
_stageKeyCallbackDelegate = OnStageKey;
this.KeyEventSignal().Connect(_stageKeyCallbackDelegate);
}
{
lock(this)
{
- if (_stageKeyEventHandler != null)
+ if (_stageKeyHandler != null)
{
this.KeyEventSignal().Disconnect(_stageKeyCallbackDelegate);
}
- _stageKeyEventHandler -= value;
+ _stageKeyHandler -= value;
}
}
}
if( data != null )
{
- e.KeyEvent = Dali.KeyEvent.GetKeyEventFromPtr( data );
+ e.Key = Dali.Key.GetKeyFromPtr( data );
}
- if (_stageKeyEventHandler != null)
+ if (_stageKeyHandler != null)
{
//here we send all data to user event handlers
- _stageKeyEventHandler(this, e);
+ _stageKeyHandler(this, e);
}
}
--- /dev/null
+%rename(GestureType) Dali::Gesture::Type;
+%rename(StateType) Dali::Gesture::State;
+
+%csmethodmodifiers Dali::Gesture::type "private";
+%csmethodmodifiers Dali::Gesture::state "private";
+%csmethodmodifiers Dali::Gesture::time "private";
+
+%typemap(cscode) Dali::Gesture %{
+ public Gesture.GestureType Type
+ {
+ get
+ {
+ return type;
+ }
+ }
+
+ public Gesture.StateType State
+ {
+ get
+ {
+ return state;
+ }
+ }
+
+ public uint Time
+ {
+ get
+ {
+ return time;
+ }
+ }
+%}
\ No newline at end of file
return ret;
}
- public uint GetTime() {
- return time;
+ public uint Time
+ {
+ get
+ {
+ return time;
+ }
}
public int GetDeviceId(uint point) {
--- /dev/null
+%rename(Key) Dali::KeyEvent;
+%rename(StateType) Dali::KeyEvent::State;
+
+%csmethodmodifiers Dali::KeyEvent::keyPressedName "private";
+%csmethodmodifiers Dali::KeyEvent::keyPressed "private";
+%csmethodmodifiers Dali::KeyEvent::keyCode "private";
+%csmethodmodifiers Dali::KeyEvent::keyModifier "private";
+%csmethodmodifiers Dali::KeyEvent::time "private";
+%csmethodmodifiers Dali::KeyEvent::state "private";
+
+%typemap(cscode) Dali::KeyEvent %{
+ public static Key GetKeyFromPtr(global::System.IntPtr cPtr) {
+ Key ret = new Key(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public string KeyPressedName
+ {
+ get
+ {
+ return keyPressedName;
+ }
+ }
+
+ public string KeyPressed
+ {
+ get
+ {
+ return keyPressed;
+ }
+ }
+
+ public int KeyCode
+ {
+ get
+ {
+ return keyCode;
+ }
+ }
+
+ public int KeyModifier
+ {
+ get
+ {
+ return keyModifier;
+ }
+ }
+
+ public uint Time
+ {
+ get
+ {
+ return time;
+ }
+ }
+
+ public Key.StateType State
+ {
+ get
+ {
+ return state;
+ }
+ }
+%}
\ No newline at end of file
--- /dev/null
+%csmethodmodifiers Dali::LongPressGesture::numberOfTouches "private";
+%csmethodmodifiers Dali::LongPressGesture::screenPoint "private";
+%csmethodmodifiers Dali::LongPressGesture::localPoint "private";
+
+%typemap(cscode) Dali::LongPressGesture %{
+ public static LongPressGesture GetLongPressGestureFromPtr(global::System.IntPtr cPtr) {
+ LongPressGesture ret = new LongPressGesture(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public uint NumberOfTouches
+ {
+ get
+ {
+ return numberOfTouches;
+ }
+ }
+
+ public Vector2 ScreenPoint
+ {
+ get
+ {
+ return screenPoint;
+ }
+ }
+
+ public Vector2 LocalPoint
+ {
+ get
+ {
+ return localPoint;
+ }
+ }
+%}
\ No newline at end of file
--- /dev/null
+%csmethodmodifiers Dali::PanGesture::velocity "private";
+%csmethodmodifiers Dali::PanGesture::displacement "private";
+%csmethodmodifiers Dali::PanGesture::position "private";
+%csmethodmodifiers Dali::PanGesture::screenVelocity "private";
+%csmethodmodifiers Dali::PanGesture::screenDisplacement "private";
+%csmethodmodifiers Dali::PanGesture::screenPosition "private";
+%csmethodmodifiers Dali::PanGesture::numberOfTouches "private";
+
+%typemap(cscode) Dali::PanGesture %{
+ public static PanGesture GetPanGestureFromPtr(global::System.IntPtr cPtr) {
+ PanGesture ret = new PanGesture(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public Vector2 Velocity
+ {
+ get
+ {
+ return velocity;
+ }
+ }
+
+ public Vector2 Displacement
+ {
+ get
+ {
+ return displacement;
+ }
+ }
+
+ public Vector2 Position
+ {
+ get
+ {
+ return position;
+ }
+ }
+
+ public Vector2 ScreenVelocity
+ {
+ get
+ {
+ return screenVelocity;
+ }
+ }
+
+ public Vector2 ScreenDisplacement
+ {
+ get
+ {
+ return screenDisplacement;
+ }
+ }
+
+ public Vector2 ScreenPosition
+ {
+ get
+ {
+ return screenPosition;
+ }
+ }
+
+ public uint NumberOfTouches
+ {
+ get
+ {
+ return numberOfTouches;
+ }
+ }
+%}
\ No newline at end of file
--- /dev/null
+%csmethodmodifiers Dali::PinchGesture::scale "private";
+%csmethodmodifiers Dali::PinchGesture::speed "private";
+%csmethodmodifiers Dali::PinchGesture::screenCenterPoint "private";
+%csmethodmodifiers Dali::PinchGesture::localCenterPoint "private";
+
+%typemap(cscode) Dali::PinchGesture %{
+ public static PinchGesture GetPinchGestureFromPtr(global::System.IntPtr cPtr) {
+ PinchGesture ret = new PinchGesture(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public float Scale
+ {
+ get
+ {
+ return scale;
+ }
+ }
+
+ public float Speed
+ {
+ get
+ {
+ return speed;
+ }
+ }
+
+ public Vector2 ScreenCenterPoint
+ {
+ get
+ {
+ return screenCenterPoint;
+ }
+ }
+
+ public Vector2 LocalCenterPoint
+ {
+ get
+ {
+ return localCenterPoint;
+ }
+ }
+%}
\ No newline at end of file
--- /dev/null
+%csmethodmodifiers Dali::TapGesture::numberOfTaps "private";
+%csmethodmodifiers Dali::TapGesture::numberOfTouches "private";
+%csmethodmodifiers Dali::TapGesture::screenPoint "private";
+%csmethodmodifiers Dali::TapGesture::localPoint "private";
+
+%typemap(cscode) Dali::TapGesture %{
+ public static TapGesture GetTapGestureFromPtr(global::System.IntPtr cPtr) {
+ TapGesture ret = new TapGesture(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public uint NumberOfTaps
+ {
+ get
+ {
+ return numberOfTaps;
+ }
+ }
+
+ public uint NumberOfTouches
+ {
+ get
+ {
+ return numberOfTouches;
+ }
+ }
+
+ public Vector2 ScreenPoint
+ {
+ get
+ {
+ return screenPoint;
+ }
+ }
+
+ public Vector2 LocalPoint
+ {
+ get
+ {
+ return localPoint;
+ }
+ }
+%}
\ No newline at end of file
--- /dev/null
+%rename(Touch) Dali::TouchData;
+
+%typemap(cscode) Dali::TouchData %{
+ public static Touch GetTouchFromPtr(global::System.IntPtr cPtr) {
+ Touch ret = new Touch(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+%}
\ No newline at end of file
--- /dev/null
+%rename(Wheel) Dali::WheelEvent;
+%rename(WheelType) Dali::WheelEvent::Type;
+
+%csmethodmodifiers Dali::WheelEvent::type "private";
+%csmethodmodifiers Dali::WheelEvent::direction "private";
+%csmethodmodifiers Dali::WheelEvent::modifiers "private";
+%csmethodmodifiers Dali::WheelEvent::point "private";
+%csmethodmodifiers Dali::WheelEvent::z "private";
+%csmethodmodifiers Dali::WheelEvent::timeStamp "private";
+
+%typemap(cscode) Dali::WheelEvent %{
+ public static Wheel GetWheelFromPtr(global::System.IntPtr cPtr) {
+ Wheel ret = new Wheel(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public Wheel.WheelType Type
+ {
+ get
+ {
+ return type;
+ }
+ }
+
+ public int Direction
+ {
+ get
+ {
+ return direction;
+ }
+ }
+
+ public uint Modifiers
+ {
+ get
+ {
+ return modifiers;
+ }
+ }
+
+ public Vector2 Point
+ {
+ get
+ {
+ return point;
+ }
+ }
+
+ public int Z
+ {
+ get
+ {
+ return z;
+ }
+ }
+
+ public uint TimeStamp
+ {
+ get
+ {
+ return timeStamp;
+ }
+ }
+%}
\ No newline at end of file
* Required to get access to any data passed as a parameter in a Signal ( in C# they are delegate parameters).
* E.g.
*
- * CREATE_CSHARP_WRAPPER_FROM_C_PTR_FUNCTION( TouchData );
- * Creates a function called GetTouchDataFromPtr which allows you to:
+ * CREATE_CSHARP_WRAPPER_FROM_C_PTR_FUNCTION( Touch );
+ * Creates a function called GetTouchFromPtr which allows you to:
*
* static void OnStageTouched(IntPtr data)
* {
- * TouchData touchData = TouchData.GetTouchDataFromPtr( data );
+ * Touch touch = Touch.GetTouchFromPtr( data );
* }
*
* ## means concat in a SWIG macro
DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, Image );
DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, ResourceImage );
DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, Animation );
-DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, TouchEvent );
-DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, TouchData );
-DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, WheelEvent );
-DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, KeyEvent );
-DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, LongPressGesture );
-DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, PanGesture );
-DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, PinchGesture );
-DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, TapGesture );
DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, PropertyNotification );
DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, BaseHandle );
DALI_CREATE_C_PTR_TO_CSHARP_FUNCTION( Dali, RefObject );
UpdateStartImages(_myRating);
// Enable pan gesture detection
- EnableGestureDetection(Gesture.Type.Pan);
+ EnableGestureDetection(Gesture.GestureType.Pan);
_myDragEnabled = true; // Allow dragging by default (can be disabled)
}
// Only handle pan gesture if dragging is allowed
if(_myDragEnabled)
{
- switch (gesture.state)
+ switch (gesture.State)
{
- case Gesture.State.Started:
+ case Gesture.StateType.Started:
{
_gestureDisplacement = new Vector3(0.0f, 0.0f, 0.0f);
_currentValue = 0;
break;
}
- case Gesture.State.Continuing:
+ case Gesture.StateType.Continuing:
{
// Calculate the rating according to pan desture displacement
- _gestureDisplacement.X += gesture.displacement.X;
+ _gestureDisplacement.X += gesture.Displacement.X;
int delta = (int)Math.Ceiling(_gestureDisplacement.X / 40.0f);
_currentValue = _myRating + delta;
Console.WriteLine("Customized Application Initialize event handler");
Stage stage = Stage.Instance;
stage.BackgroundColor = Color.White;
- stage.TouchEvent += OnStageTouched;
+ stage.Touch += OnStageTouched;
// Add a _text label to the stage
_text = new TextLabel("Hello Mono World");
public void OnStageTouched(object sender, Stage.TouchEventArgs e)
{
// Only animate the _text label when touch down happens
- if( e.TouchData.GetState(0) == PointStateType.DOWN )
+ if( e.Touch.GetState(0) == PointStateType.DOWN )
{
Console.WriteLine("Customized Stage Touch event handler");
// Create a new _animation
Log("Customized Application Initialize event handler");
stage = Stage.Instance;
stage.BackgroundColor = Color.Cyan;
- stage.TouchEvent += OnStageTouched;
- stage.WheelEvent += OnStageWheelMoved;
- stage.KeyEvent += OnStageKeyPressed;
+ stage.Touch += OnStageTouched;
+ stage.Wheel += OnStageWheelMoved;
+ stage.Key += OnStageKeyPressed;
//stage.EventProcessingFinished += OnStageEventProcessingFinished;
layer = stage.GetDefaultLayer();
public void OnStageKeyPressed(object sender, Stage.KeyEventArgs e)
{
Log("OnStageKeyEventOccured()!");
- Log("keyPressedName=" + e.KeyEvent.keyPressedName);
- Log("state=" + e.KeyEvent.state);
+ Log("keyPressedName=" + e.Key.KeyPressedName);
+ Log("state=" + e.Key.State);
}
public void OnStageWheelMoved(object sender, Stage.WheelEventArgs e)
{
Log("OnStageWheelEventOccured()!");
- Log("direction=" + e.WheelEvent.direction);
- Log("type=" + e.WheelEvent.type);
+ Log("direction=" + e.Wheel.Direction);
+ Log("type=" + e.Wheel.Type);
}
// Callback for stage touched signal handling
public void OnStageTouched(object sender, Stage.TouchEventArgs e)
{
- Log("OnStageTouched()! e.TouchData.GetState(0)=" + e.TouchData.GetState(0) );
+ Log("OnStageTouched()! e.TouchData.GetState(0)=" + e.Touch.GetState(0));
}
public void MainLoop()
Console.WriteLine("View TOUCH EVENT callback....");
// Only animate the _text label when touch down happens
- if( e.TouchData.GetState(0) == PointStateType.DOWN )
+ if( e.Touch.GetState(0) == PointStateType.DOWN )
{
Console.WriteLine("Customized Stage Touch event handler");
// Create a new _animation
Log("Initialize() is called!");
Stage stage = Stage.GetCurrent();
stage.BackgroundColor = Color.White;
- stage.TouchEvent += OnStageTouched;
- stage.TouchEvent += OnStageTouched2;
+ stage.Touch += OnStageTouched;
+ stage.Touch += OnStageTouched2;
//stage.EventProcessingFinished += OnEventProcessingFinished;
- stage.WheelEvent += OnStageWheelEvent;
+ stage.Wheel += OnStageWheelEvent;
// Add a _text label to the stage
_text = new TextLabel("Hello Mono World");
public void OnStageTouched(object source, Stage.TouchEventArgs e)
{
// Only animate the _text label when touch down happens
- if( e.TouchData.GetState(0) == PointStateType.DOWN )
+ if( e.Touch.GetState(0) == PointStateType.DOWN )
{
Log("OnStageTouched() is called! PointStateType.DOWN came!");
myCount++;
// Callback for stage touched signal handling
public void OnStageTouched2(object source, Stage.TouchEventArgs e)
{
- Log("OnStageTouched2() is called!state="+ e.TouchData.GetState(0) );
+ Log("OnStageTouched2() is called!state="+ e.Touch.GetState(0) );
}
public void OnEventProcessingFinished(object source)
viewWrapperImpl.OnPropertySet = new ViewWrapperImpl.OnPropertySetDelegate(OnPropertySet);
viewWrapperImpl.OnSizeSet = new ViewWrapperImpl.OnSizeSetDelegate(OnSizeSet);
viewWrapperImpl.OnSizeAnimation = new ViewWrapperImpl.OnSizeAnimationDelegate(OnSizeAnimation);
- viewWrapperImpl.OnTouchEvent = new ViewWrapperImpl.OnTouchEventDelegate(OnTouchEvent);
+ viewWrapperImpl.OnTouch = new ViewWrapperImpl.OnTouchDelegate(OnTouch);
viewWrapperImpl.OnHover = new ViewWrapperImpl.OnHoverDelegate(OnHover);
- viewWrapperImpl.OnKeyEvent = new ViewWrapperImpl.OnKeyEventDelegate(OnKeyEvent);
- viewWrapperImpl.OnWheelEvent = new ViewWrapperImpl.OnWheelEventDelegate(OnWheelEvent);
+ viewWrapperImpl.OnKey = new ViewWrapperImpl.OnKeyDelegate(OnKey);
+ viewWrapperImpl.OnWheel = new ViewWrapperImpl.OnWheelDelegate(OnWheel);
viewWrapperImpl.OnRelayout = new ViewWrapperImpl.OnRelayoutDelegate(OnRelayout);
viewWrapperImpl.OnSetResizePolicy = new ViewWrapperImpl.OnSetResizePolicyDelegate(OnSetResizePolicy);
viewWrapperImpl.GetNaturalSize = new ViewWrapperImpl.GetNaturalSizeDelegate(GetNaturalSize);
* @endcode
* @param[in] type The gesture type(s) to enable.
*/
- public void EnableGestureDetection(Gesture.Type type)
+ public void EnableGestureDetection(Gesture.GestureType type)
{
viewWrapperImpl.EnableGestureDetection(type);
}
* @param[in] type The gesture type(s) to disable.
* @see EnableGetureDetection
*/
- public void DisableGestureDetection(Gesture.Type type)
+ public void DisableGestureDetection(Gesture.GestureType type)
{
viewWrapperImpl.DisableGestureDetection(type);
}
/**
* @brief Called by the KeyInputFocusManager to emit key event signals.
*
- * @param[in] keyEvent The key event.
+ * @param[in] key The key event.
* @return True if the event was consumed.
*/
- public bool EmitKeyEventSignal(KeyEvent keyEvent)
+ public bool EmitKeyEventSignal(Key key)
{
- return viewWrapperImpl.EmitKeyEventSignal(keyEvent);
+ return viewWrapperImpl.EmitKeyEventSignal(key);
}
/**
*
* @brief Called after a touch-event is received by the owning actor.
*
- * @param[in] event The touch event
+ * @param[in] touch The touch event
* @return True if the event should be consumed.
* @note CustomViewBehaviour.REQUIRES_TOUCH_EVENTS must be enabled during construction. See CustomView(ViewWrapperImpl.CustomViewBehaviour behaviour).
*/
- public virtual bool OnTouchEvent(TouchEvent touchEvent)
+ public virtual bool OnTouch(Touch touch)
{
return false; // Do not consume
}
/**
* @brief Called after a key-event is received by the actor that has had its focus set.
*
- * @param[in] event the Key Event
+ * @param[in] key the Key Event
* @return True if the event should be consumed.
*/
- public virtual bool OnKeyEvent(KeyEvent keyEvent)
+ public virtual bool OnKey(Key key)
{
return false; // Do not consume
}
/**
* @brief Called after a wheel-event is received by the owning actor.
*
- * @param[in] event The wheel event
+ * @param[in] wheel The wheel event
* @return True if the event should be consumed.
* @note CustomViewBehaviour.REQUIRES_WHEEL_EVENTS must be enabled during construction. See CustomView(ViewWrapperImpl.CustomViewBehaviour behaviour).
*/
- public virtual bool OnWheelEvent(WheelEvent wheelEvent)
+ public virtual bool OnWheel(Wheel wheel)
{
return false; // Do not consume
}
* @brief This method should be overridden by deriving classes when they wish to respond the accessibility
* touch event.
*
- * @param[in] touchEvent The touch event.
+ * @param[in] touch The touch event.
* @return true if the touch event has been consumed by this control
*/
- public virtual bool OnAccessibilityTouch(TouchEvent touchEvent)
+ public virtual bool OnAccessibilityTouch(Touch touch)
{
return false;
}
public delegate void OnPropertySetDelegate(int index, Property.Value propertyValue);
public delegate void OnSizeSetDelegate(Vector3 targetSize);
public delegate void OnSizeAnimationDelegate(Animation animation, Vector3 targetSize);
- public delegate bool OnTouchEventDelegate(TouchEvent touchEvent);
+ public delegate bool OnTouchDelegate(Touch touch);
public delegate bool OnHoverDelegate(Hover hover);
- public delegate bool OnKeyEventDelegate(KeyEvent keyEvent);
- public delegate bool OnWheelEventDelegate(WheelEvent wheelEvent);
+ public delegate bool OnKeyDelegate(Key key);
+ public delegate bool OnWheelDelegate(Wheel wheel);
public delegate void OnRelayoutDelegate(Vector2 size, RelayoutContainer container);
public delegate void OnSetResizePolicyDelegate(ResizePolicyType policy, DimensionType dimension);
public delegate Vector3 GetNaturalSizeDelegate();
public delegate void OnStyleChangeDelegate(StyleManager styleManager, StyleChangeType change);
public delegate bool OnAccessibilityActivatedDelegate();
public delegate bool OnAccessibilityPanDelegate(PanGesture gestures);
- public delegate bool OnAccessibilityTouchDelegate(TouchEvent touchEvent);
+ public delegate bool OnAccessibilityTouchDelegate(Touch touch);
public delegate bool OnAccessibilityValueChangeDelegate(bool isIncrease);
public delegate bool OnAccessibilityZoomDelegate();
public delegate void OnKeyInputFocusGainedDelegate();
public OnPropertySetDelegate OnPropertySet;
public OnSizeSetDelegate OnSizeSet;
public OnSizeAnimationDelegate OnSizeAnimation;
- public OnTouchEventDelegate OnTouchEvent;
+ public OnTouchDelegate OnTouch;
public OnHoverDelegate OnHover;
- public OnKeyEventDelegate OnKeyEvent;
- public OnWheelEventDelegate OnWheelEvent;
+ public OnKeyDelegate OnKey;
+ public OnWheelDelegate OnWheel;
public OnRelayoutDelegate OnRelayout;
public OnSetResizePolicyDelegate OnSetResizePolicy;
public GetNaturalSizeDelegate GetNaturalSize;
Delegate4 = new DelegateViewWrapperImpl_4(DirectorOnPropertySet);
Delegate5 = new DelegateViewWrapperImpl_5(DirectorOnSizeSet);
Delegate6 = new DelegateViewWrapperImpl_6(DirectorOnSizeAnimation);
- Delegate7 = new DelegateViewWrapperImpl_7(DirectorOnTouchEvent);
+ Delegate7 = new DelegateViewWrapperImpl_7(DirectorOnTouch);
Delegate8 = new DelegateViewWrapperImpl_8(DirectorOnHover);
- Delegate9 = new DelegateViewWrapperImpl_9(DirectorOnKeyEvent);
- Delegate10 = new DelegateViewWrapperImpl_10(DirectorOnWheelEvent);
+ Delegate9 = new DelegateViewWrapperImpl_9(DirectorOnKey);
+ Delegate10 = new DelegateViewWrapperImpl_10(DirectorOnWheel);
Delegate11 = new DelegateViewWrapperImpl_11(DirectorOnRelayout);
Delegate12 = new DelegateViewWrapperImpl_12(DirectorOnSetResizePolicy);
Delegate13 = new DelegateViewWrapperImpl_13(DirectorGetNaturalSize);
OnSizeAnimation(new Animation(animation, false), new Vector3(targetSize, false));
}
- private bool DirectorOnTouchEvent(global::System.IntPtr arg0)
+ private bool DirectorOnTouch(global::System.IntPtr arg0)
{
- return OnTouchEvent(new TouchEvent(arg0, false));
+ return OnTouch(new Touch(arg0, false));
}
private bool DirectorOnHover(global::System.IntPtr arg0)
return OnHover(new Hover(arg0, false));
}
- private bool DirectorOnKeyEvent(global::System.IntPtr arg0)
+ private bool DirectorOnKey(global::System.IntPtr arg0)
{
- return OnKeyEvent(new KeyEvent(arg0, false));
+ return OnKey(new Key(arg0, false));
}
- private bool DirectorOnWheelEvent(global::System.IntPtr arg0)
+ private bool DirectorOnWheel(global::System.IntPtr arg0)
{
- return OnWheelEvent(new WheelEvent(arg0, false));
+ return OnWheel(new Wheel(arg0, false));
}
private void DirectorOnRelayout(global::System.IntPtr size, global::System.IntPtr container)
return OnAccessibilityPan(new PanGesture(gesture, false));
}
- private bool DirectorOnAccessibilityTouch(global::System.IntPtr touchEvent)
+ private bool DirectorOnAccessibilityTouch(global::System.IntPtr touch)
{
- return OnAccessibilityTouch(new TouchEvent(touchEvent, false));
+ return OnAccessibilityTouch(new Touch(touch, false));
}
private bool DirectorOnAccessibilityValueChange(bool isIncrease)
public delegate void DelegateViewWrapperImpl_24(global::System.IntPtr styleManager, int change);
public delegate bool DelegateViewWrapperImpl_25();
public delegate bool DelegateViewWrapperImpl_26(global::System.IntPtr gesture);
- public delegate bool DelegateViewWrapperImpl_27(global::System.IntPtr touchEvent);
+ public delegate bool DelegateViewWrapperImpl_27(global::System.IntPtr touch);
public delegate bool DelegateViewWrapperImpl_28(bool isIncrease);
public delegate bool DelegateViewWrapperImpl_29();
public delegate void DelegateViewWrapperImpl_30();