From: Richard Huang Date: Mon, 3 Oct 2016 14:18:17 +0000 (+0100) Subject: Manual binding for KeyboardFocusManager X-Git-Tag: dali_1.2.9~5^2 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=commitdiff_plain;h=e993d9e43d664478f12a4c3037ae4dd3eb8133bd Manual binding for KeyboardFocusManager Change-Id: I52061d64c2c900d06693da828b1a91133b08b36a --- diff --git a/plugins/dali-swig/Makefile.am b/plugins/dali-swig/Makefile.am index 48e0d93..9a4c8d6 100644 --- a/plugins/dali-swig/Makefile.am +++ b/plugins/dali-swig/Makefile.am @@ -12,24 +12,28 @@ # See the License for the specific language governing permissions and # limitations under the License. -CLEANFILES = cpp/dali_wrap.* csharp/*.cs *.so *.dll \ +CLEANFILES = automatic/cpp/dali_wrap.* automatic/csharp/*.cs *.so *.dll \ + manual/cpp/*.o \ examples/*.so examples/*.dll examples/*.exe -BUILT_SOURCES = cpp/dali_wrap.cpp cpp/dali_wrap.h +BUILT_SOURCES = automatic/cpp/dali_wrap.cpp automatic/cpp/dali_wrap.h if HAVE_MCS if BUILD_MCS all-local: libNDalic.so NDali.dll -libNDalic.so: cpp/dali_wrap.o - g++ -shared cpp/dali_wrap.o -o libNDalic.so $(DALICORE_LIBS) $(DALIADAPTOR_LIBS) $(DALITOOLKIT_LIBS) +libNDalic.so: automatic/cpp/dali_wrap.o manual/cpp/keyboard_focus_manager_wrap.o + g++ -shared automatic/cpp/dali_wrap.o manual/cpp/keyboard_focus_manager_wrap.o -o libNDalic.so $(DALICORE_LIBS) $(DALIADAPTOR_LIBS) $(DALITOOLKIT_LIBS) -cpp/dali_wrap.o: $(BUILT_SOURCES) - g++ -c -fpic $(CXXFLAGS) $(DALICORE_CFLAGS) $(DALIADAPTOR_CFLAGS) $(DALITOOLKIT_CFLAGS) cpp/dali_wrap.cpp -o cpp/dali_wrap.o +automatic/cpp/dali_wrap.o: $(BUILT_SOURCES) + g++ -c -fpic $(CXXFLAGS) $(DALICORE_CFLAGS) $(DALIADAPTOR_CFLAGS) $(DALITOOLKIT_CFLAGS) automatic/cpp/dali_wrap.cpp -o automatic/cpp/dali_wrap.o + +manual/cpp/keyboard_focus_manager_wrap.o: $(BUILT_SOURCES) + g++ -c -fpic $(CXXFLAGS) $(DALICORE_CFLAGS) $(DALIADAPTOR_CFLAGS) $(DALITOOLKIT_CFLAGS) manual/cpp/keyboard_focus_manager_wrap.cpp -o manual/cpp/keyboard_focus_manager_wrap.o NDali.dll: $(BUILT_SOURCES) - $(MCS) -nologo -target:library -out:NDali.dll csharp/*.cs + $(MCS) -nologo -target:library -out:NDali.dll automatic/csharp/*.cs manual/csharp/*.cs check-local: examples/dali-test.exe \ examples/hello-world.exe \ @@ -51,25 +55,25 @@ endif # use swig to generate the CS wrapper code # then call our property-wrapper to inject DALi property getters / setters $(BUILT_SOURCES): SWIG/*.i - rm -f csharp/*.cs - $(SWIG) -csharp -c++ -outdir csharp \ - $(DALI_CFLAGS) $(DALICORE_CFLAGS) $(DALIADAPTOR_CFLAGS) $(DALITOOLKIT_CFLAGS) -namespace Dali -o cpp/dali_wrap.cpp SWIG/dali.i + rm -f automatic/csharp/*.cs + $(SWIG) -csharp -c++ -outdir automatic/csharp \ + $(DALI_CFLAGS) $(DALICORE_CFLAGS) $(DALIADAPTOR_CFLAGS) $(DALITOOLKIT_CFLAGS) -namespace Dali -o automatic/cpp/dali_wrap.cpp SWIG/dali.i ./property-wrapper.rb ./constructor-generator.rb dist-hook: $(BUILT_SOURCES) - mkdir -p $(distdir)/cpp - cp ./cpp/dali_wrap.cpp $(distdir)/cpp - cp ./cpp/dali_wrap.h $(distdir)/cpp - cp ./cpp/DaliWrapper.h ./cpp/DaliWrapper.cpp $(distdir)/cpp - cp ./cpp/stdafx.h $(distdir)/cpp - mkdir -p $(distdir)/csharp - cp ./csharp/*.csproj $(distdir)/csharp - cp ./csharp/*.cs $(distdir)/csharp + mkdir -p $(distdir)/automatic/cpp + cp ./automatic/cpp/*.cpp $(distdir)/automatic/cpp + cp ./automatic/cpp/*.h $(distdir)/automatic/cpp + mkdir -p $(distdir)/manual/cpp + cp ./manual/cpp/*.cpp $(distdir)/manual/cpp + cp ./manual/cpp/*.h $(distdir)/manual/cpp + mkdir -p $(distdir)/automatic/csharp + cp ./automatic/csharp/*.cs $(distdir)/automatic/csharp + mkdir -p $(distdir)/manual/csharp + cp ./manual/csharp/*.cs $(distdir)/manual/csharp mkdir -p $(distdir)/examples cp ./examples/*.csproj $(distdir)/examples cp ./examples/*.cs $(distdir)/examples -EXTRA_DIST = \ - swig.cmd diff --git a/plugins/dali-swig/SWIG/dali-toolkit.i b/plugins/dali-swig/SWIG/dali-toolkit.i index 1a9c001..19c1d4e 100644 --- a/plugins/dali-swig/SWIG/dali-toolkit.i +++ b/plugins/dali-swig/SWIG/dali-toolkit.i @@ -32,7 +32,6 @@ %ignore *::ImageView(Dali::Internal::CustomActor*); %ignore *::ItemView(Internal::ItemView&); %ignore *::ItemView(Dali::Internal::CustomActor*); -%ignore *::KeyboardFocusManager(Internal::KeyboardFocusManager*); %ignore *::Model3dView(Internal::Model3dView&); %ignore *::Model3dView(Dali::Internal::CustomActor*); %ignore *::PageTurnLandscapeView(Internal::PageTurnLandscapeView&); @@ -184,7 +183,6 @@ typedef Dali::IntrusivePtr RulerPtr; %include %include %include -%include %include %include %include @@ -208,7 +206,6 @@ typedef Dali::IntrusivePtr RulerPtr; %template(AccessibilityActionScrollSignal) Dali::Signal; %template(AccessibilityFocusOvershotSignal) Dali::Signal; %template(FocusChangedSignal) Dali::Signal; -%template(KeyboardPreFocusChangeSignal) Dali::Signal; %template(FocusGroupChangedSignal) Dali::Signal; %template(StyleChangedSignal) Dali::Signal; %template(ButtonSignal) Dali::Signal; diff --git a/plugins/dali-swig/SWIG/dali.i b/plugins/dali-swig/SWIG/dali.i index 15bd0e3..781a4ba 100644 --- a/plugins/dali-swig/SWIG/dali.i +++ b/plugins/dali-swig/SWIG/dali.i @@ -53,7 +53,6 @@ #include #include - #include #include #include diff --git a/plugins/dali-swig/SWIG/signals.i b/plugins/dali-swig/SWIG/signals.i index 7eb190a..e7aa444 100644 --- a/plugins/dali-swig/SWIG/signals.i +++ b/plugins/dali-swig/SWIG/signals.i @@ -330,18 +330,9 @@ DALI_SIGNAL_2_PARAM( Dali::Actor, Dali::Toolkit::AccessibilityManager::FocusOver // Signal< bool ( Dali::Toolkit::AccessibilityManager&, const Dali::TouchEvent& ) > DALI_SIGNAL_2_PARAM_RETURN( bool ,Dali::Toolkit::AccessibilityManager&, const Dali::TouchEvent&); -// Signal< void ( Dali::Actor, Dali::Toolkit::AccessibilityManager::FocusOvershotDirection) > -//DALI_SIGNAL_2_PARAM( Dali::Actor, Dali::Toolkit::AccessibilityManager::FocusOvershotDirection ); - // Signal< void ( Dali::Toolkit::StyleManager, Dali::StyleChange::Type) > DALI_SIGNAL_2_PARAM( Dali::Toolkit::StyleManager, Dali::StyleChange::Type); -// Signal< void ( Dali::Actor, Dali::Toolkit::AccessibilityManager::FocusOvershotDirection )> -//DALI_SIGNAL_2_PARAM( Dali::Actor, Dali::Toolkit::AccessibilityManager::FocusOvershotDirection ); - -// Signal< Dali::Actor ( Dali::Actor, Dali::Actor, Dali::Actor, Dali::Toolkit::Control::KeyboardFocus::Direction) > -DALI_SIGNAL_3_PARAM_RETURN( Dali::Actor, Dali::Actor, Dali::Actor, Dali::Toolkit::Control::KeyboardFocus::Direction); - // void Signal< Dali::Actor, bool >; DALI_SIGNAL_2_PARAM( Dali::Actor, bool); diff --git a/plugins/dali-swig/cpp/DaliWrapper.cpp b/plugins/dali-swig/automatic/cpp/DaliWrapper.cpp similarity index 100% rename from plugins/dali-swig/cpp/DaliWrapper.cpp rename to plugins/dali-swig/automatic/cpp/DaliWrapper.cpp diff --git a/plugins/dali-swig/cpp/DaliWrapper.h b/plugins/dali-swig/automatic/cpp/DaliWrapper.h similarity index 100% rename from plugins/dali-swig/cpp/DaliWrapper.h rename to plugins/dali-swig/automatic/cpp/DaliWrapper.h diff --git a/plugins/dali-swig/cpp/stdafx.h b/plugins/dali-swig/automatic/cpp/stdafx.h similarity index 100% rename from plugins/dali-swig/cpp/stdafx.h rename to plugins/dali-swig/automatic/cpp/stdafx.h diff --git a/plugins/dali-swig/csharp/.gitignore b/plugins/dali-swig/automatic/csharp/.gitignore similarity index 100% rename from plugins/dali-swig/csharp/.gitignore rename to plugins/dali-swig/automatic/csharp/.gitignore diff --git a/plugins/dali-swig/constructor-generator.rb b/plugins/dali-swig/constructor-generator.rb index cb5cf25..c8876df 100755 --- a/plugins/dali-swig/constructor-generator.rb +++ b/plugins/dali-swig/constructor-generator.rb @@ -60,7 +60,7 @@ def init fullPath = pn.to_s $rootPath = fullPath.slice(0..( fullPath.index('/dali-toolkit'))) - $daliCSharpPath = $rootPath + "dali-toolkit/plugins/dali-swig/csharp" + $daliCSharpPath = $rootPath + "dali-toolkit/plugins/dali-swig/automatic/csharp" puts("--------------------------------------------") puts("Modifying constructors for DALi C# files ") puts("E.g. modify TextLabel::New() ==> new TextLabel() ") diff --git a/plugins/dali-swig/manual/cpp/common.h b/plugins/dali-swig/manual/cpp/common.h new file mode 100644 index 0000000..7011fc2 --- /dev/null +++ b/plugins/dali-swig/manual/cpp/common.h @@ -0,0 +1,185 @@ +#ifndef CSHARP_COMMON +#define CSHARP_COMMON +#endif + +#define SWIG_DIRECTORS + +#include + +#define SWIGSTDCALL + +/* attribute recognised by some compilers to avoid 'unused' warnings */ +#ifndef SWIGUNUSED +# if defined(__GNUC__) +# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)) +# define SWIGUNUSED __attribute__ ((__unused__)) +# else +# define SWIGUNUSED +# endif +# elif defined(__ICC) +# define SWIGUNUSED __attribute__ ((__unused__)) +# else +# define SWIGUNUSED +# endif +#endif + +/* internal SWIG method */ +#ifndef SWIGINTERN +# define SWIGINTERN static SWIGUNUSED +#endif + +#ifndef SWIGEXPORT +# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__) +# if defined(STATIC_LINKED) +# define SWIGEXPORT +# else +# define SWIGEXPORT __declspec(dllexport) +# endif +# else +# if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY) +# define SWIGEXPORT __attribute__ ((visibility("default"))) +# else +# define SWIGEXPORT +# endif +# endif +#endif + +#include +#include +#include + +/* Errors in SWIG */ +#define SWIG_UnknownError -1 +#define SWIG_IOError -2 +#define SWIG_RuntimeError -3 +#define SWIG_IndexError -4 +#define SWIG_TypeError -5 +#define SWIG_DivisionByZero -6 +#define SWIG_OverflowError -7 +#define SWIG_SyntaxError -8 +#define SWIG_ValueError -9 +#define SWIG_SystemError -10 +#define SWIG_AttributeError -11 +#define SWIG_MemoryError -12 +#define SWIG_NullReferenceError -13 + +/* Support for throwing C# exceptions from C/C++. There are two types: + * Exceptions that take a message and ArgumentExceptions that take a message and a parameter name. */ +typedef enum { + SWIG_CSharpApplicationException, + SWIG_CSharpArithmeticException, + SWIG_CSharpDivideByZeroException, + SWIG_CSharpIndexOutOfRangeException, + SWIG_CSharpInvalidCastException, + SWIG_CSharpInvalidOperationException, + SWIG_CSharpIOException, + SWIG_CSharpNullReferenceException, + SWIG_CSharpOutOfMemoryException, + SWIG_CSharpOverflowException, + SWIG_CSharpSystemException +} SWIG_CSharpExceptionCodes; + +typedef enum { + SWIG_CSharpArgumentException, + SWIG_CSharpArgumentNullException, + SWIG_CSharpArgumentOutOfRangeException +} SWIG_CSharpExceptionArgumentCodes; + +typedef void (SWIGSTDCALL* SWIG_CSharpExceptionCallback_t)(const char *); +typedef void (SWIGSTDCALL* SWIG_CSharpExceptionArgumentCallback_t)(const char *, const char *); + +typedef struct { + SWIG_CSharpExceptionCodes code; + SWIG_CSharpExceptionCallback_t callback; +} SWIG_CSharpException_t; + +typedef struct { + SWIG_CSharpExceptionArgumentCodes code; + SWIG_CSharpExceptionArgumentCallback_t callback; +} SWIG_CSharpExceptionArgument_t; + +static SWIG_CSharpException_t SWIG_csharp_exceptions[] = { + { SWIG_CSharpApplicationException, NULL }, + { SWIG_CSharpArithmeticException, NULL }, + { SWIG_CSharpDivideByZeroException, NULL }, + { SWIG_CSharpIndexOutOfRangeException, NULL }, + { SWIG_CSharpInvalidCastException, NULL }, + { SWIG_CSharpInvalidOperationException, NULL }, + { SWIG_CSharpIOException, NULL }, + { SWIG_CSharpNullReferenceException, NULL }, + { SWIG_CSharpOutOfMemoryException, NULL }, + { SWIG_CSharpOverflowException, NULL }, + { SWIG_CSharpSystemException, NULL } +}; + +static SWIG_CSharpExceptionArgument_t SWIG_csharp_exceptions_argument[] = { + { SWIG_CSharpArgumentException, NULL }, + { SWIG_CSharpArgumentNullException, NULL }, + { SWIG_CSharpArgumentOutOfRangeException, NULL } +}; + +static void SWIGUNUSED SWIG_CSharpSetPendingException(SWIG_CSharpExceptionCodes code, const char *msg) { + SWIG_CSharpExceptionCallback_t callback = SWIG_csharp_exceptions[SWIG_CSharpApplicationException].callback; + if ((size_t)code < sizeof(SWIG_csharp_exceptions)/sizeof(SWIG_CSharpException_t)) { + callback = SWIG_csharp_exceptions[code].callback; + } + callback(msg); +} + +static void SWIGUNUSED SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpExceptionArgumentCodes code, const char *msg, const char *param_name) { + SWIG_CSharpExceptionArgumentCallback_t callback = SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentException].callback; + if ((size_t)code < sizeof(SWIG_csharp_exceptions_argument)/sizeof(SWIG_CSharpExceptionArgument_t)) { + callback = SWIG_csharp_exceptions_argument[code].callback; + } + callback(msg, param_name); +} + +SWIGINTERN void SWIG_CSharpException(int code, const char *msg) { + if (code == SWIG_ValueError) { + SWIG_CSharpExceptionArgumentCodes exception_code = SWIG_CSharpArgumentOutOfRangeException; + SWIG_CSharpSetPendingExceptionArgument(exception_code, msg, 0); + } else { + SWIG_CSharpExceptionCodes exception_code = SWIG_CSharpApplicationException; + switch(code) { + case SWIG_MemoryError: + exception_code = SWIG_CSharpOutOfMemoryException; + break; + case SWIG_IndexError: + exception_code = SWIG_CSharpIndexOutOfRangeException; + break; + case SWIG_DivisionByZero: + exception_code = SWIG_CSharpDivideByZeroException; + break; + case SWIG_IOError: + exception_code = SWIG_CSharpIOException; + break; + case SWIG_OverflowError: + exception_code = SWIG_CSharpOverflowException; + break; + case SWIG_RuntimeError: + case SWIG_TypeError: + case SWIG_SyntaxError: + case SWIG_SystemError: + case SWIG_UnknownError: + default: + exception_code = SWIG_CSharpApplicationException; + break; + } + SWIG_CSharpSetPendingException(exception_code, msg); + } +} + + +#include + + +#define SWIGSTDCALL + + +#include +#include + +using namespace Dali; +using namespace Dali::Toolkit; + + diff --git a/plugins/dali-swig/manual/cpp/keyboard_focus_manager_wrap.cpp b/plugins/dali-swig/manual/cpp/keyboard_focus_manager_wrap.cpp new file mode 100644 index 0000000..d2a017c --- /dev/null +++ b/plugins/dali-swig/manual/cpp/keyboard_focus_manager_wrap.cpp @@ -0,0 +1,781 @@ +#ifndef CSHARP_KEYBOARD_FOCUS_MANAGER +#define CSHARP_KEYBOARD_FOCUS_MANAGER +#endif + +#include "common.h" + +SWIGINTERN bool Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__Empty(Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > const *self){ + return self->Empty(); + } +SWIGINTERN std::size_t Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__GetConnectionCount(Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > const *self){ + return self->GetConnectionCount(); + } +SWIGINTERN void Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__Connect(Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *self,Dali::Actor (*func)(Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction)){ + return self->Connect( func ); + } +SWIGINTERN void Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__Disconnect(Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *self,Dali::Actor (*func)(Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction)){ + self->Disconnect( func ); + } +SWIGINTERN Dali::Actor Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__Emit(Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *self,Dali::Actor arg1,Dali::Actor arg2,Dali::Toolkit::Control::KeyboardFocus::Direction arg3){ + return self->Emit( arg1, arg2, arg3 ); + } + +#ifdef __cplusplus +extern "C" { +#endif + +SWIGEXPORT void * SWIGSTDCALL CSharp_new_KeyboardFocusManager() { + void * jresult; + Dali::Toolkit::KeyboardFocusManager *result = 0 ; + + { + try { + result = (Dali::Toolkit::KeyboardFocusManager *)new Dali::Toolkit::KeyboardFocusManager(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void SWIGSTDCALL CSharp_delete_KeyboardFocusManager(void * jarg1) { + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + delete arg1; + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardFocusManager_Get() { + void * jresult; + Dali::Toolkit::KeyboardFocusManager result; + + { + try { + result = Dali::Toolkit::KeyboardFocusManager::Get(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = new Dali::Toolkit::KeyboardFocusManager((const Dali::Toolkit::KeyboardFocusManager &)result); + return jresult; +} + + +SWIGEXPORT unsigned int SWIGSTDCALL CSharp_KeyboardFocusManager_SetCurrentFocusActor(void * jarg1, void * jarg2) { + unsigned int jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Actor arg2; + Dali::Actor *argp2 ; + bool result; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + argp2 = (Dali::Actor *)jarg2; + if (!argp2) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::Actor", 0); + return 0; + } + arg2 = *argp2; + { + try { + result = (bool)(arg1)->SetCurrentFocusActor(arg2); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardFocusManager_GetCurrentFocusActor(void * jarg1) { + void * jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Actor result; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + result = (arg1)->GetCurrentFocusActor(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = new Dali::Actor((const Dali::Actor &)result); + return jresult; +} + + +SWIGEXPORT unsigned int SWIGSTDCALL CSharp_KeyboardFocusManager_MoveFocus(void * jarg1, int jarg2) { + unsigned int jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Toolkit::Control::KeyboardFocus::Direction arg2; + bool result; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + arg2 = (Dali::Toolkit::Control::KeyboardFocus::Direction)jarg2; + { + try { + result = (bool)(arg1)->MoveFocus(arg2); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = result; + return jresult; +} + + +SWIGEXPORT void SWIGSTDCALL CSharp_KeyboardFocusManager_ClearFocus(void * jarg1) { + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + (arg1)->ClearFocus(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return; + }; + } + } +} + + +SWIGEXPORT void SWIGSTDCALL CSharp_KeyboardFocusManager_SetFocusGroupLoop(void * jarg1, unsigned int jarg2) { + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0; + bool arg2; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + arg2 = jarg2 ? true : false; + { + try { + (arg1)->SetFocusGroupLoop(arg2); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } +} + + +SWIGEXPORT unsigned int SWIGSTDCALL CSharp_KeyboardFocusManager_GetFocusGroupLoop(void * jarg1) { + unsigned int jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + bool result; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + result = (bool)((Dali::Toolkit::KeyboardFocusManager const *)arg1)->GetFocusGroupLoop(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = result; + return jresult; +} + + +SWIGEXPORT void SWIGSTDCALL CSharp_KeyboardFocusManager_SetAsFocusGroup(void * jarg1, void * jarg2, unsigned int jarg3) { + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Actor arg2 ; + bool arg3 ; + Dali::Actor *argp2 ; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + argp2 = (Dali::Actor *)jarg2; + if (!argp2) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::Actor", 0); + return ; + } + arg2 = *argp2; + arg3 = jarg3 ? true : false; + { + try { + (arg1)->SetAsFocusGroup(arg2,arg3); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } +} + + +SWIGEXPORT unsigned int SWIGSTDCALL CSharp_KeyboardFocusManager_IsFocusGroup(void * jarg1, void * jarg2) { + unsigned int jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Actor arg2 ; + Dali::Actor *argp2 ; + bool result; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + argp2 = (Dali::Actor *)jarg2; + if (!argp2) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::Actor", 0); + return 0; + } + arg2 = *argp2; + { + try { + result = (bool)((Dali::Toolkit::KeyboardFocusManager const *)arg1)->IsFocusGroup(arg2); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardFocusManager_GetFocusGroup(void * jarg1, void * jarg2) { + void * jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Actor arg2 ; + Dali::Actor *argp2 ; + Dali::Actor result; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + argp2 = (Dali::Actor *)jarg2; + if (!argp2) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::Actor", 0); + return 0; + } + arg2 = *argp2; + { + try { + result = (arg1)->GetFocusGroup(arg2); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = new Dali::Actor((const Dali::Actor &)result); + return jresult; +} + + +SWIGEXPORT void SWIGSTDCALL CSharp_KeyboardFocusManager_SetFocusIndicatorActor(void * jarg1, void * jarg2) { + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Actor arg2 ; + Dali::Actor *argp2 ; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + argp2 = (Dali::Actor *)jarg2; + if (!argp2) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::Actor", 0); + return ; + } + arg2 = *argp2; + { + try { + (arg1)->SetFocusIndicatorActor(arg2); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardFocusManager_GetFocusIndicatorActor(void * jarg1) { + void * jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Actor result; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + result = (arg1)->GetFocusIndicatorActor(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = new Dali::Actor((const Dali::Actor &)result); + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardFocusManager_PreFocusChangeSignal(void * jarg1) { + void * jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Toolkit::KeyboardFocusManager::PreFocusChangeSignalType *result = 0 ; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + result = (Dali::Toolkit::KeyboardFocusManager::PreFocusChangeSignalType *) &(arg1)->PreFocusChangeSignal(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardFocusManager_FocusChangedSignal(void * jarg1) { + void * jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Toolkit::KeyboardFocusManager::FocusChangedSignalType *result = 0 ; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + result = (Dali::Toolkit::KeyboardFocusManager::FocusChangedSignalType *) &(arg1)->FocusChangedSignal(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardFocusManager_FocusGroupChangedSignal(void * jarg1) { + void * jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Toolkit::KeyboardFocusManager::FocusGroupChangedSignalType *result = 0 ; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + result = (Dali::Toolkit::KeyboardFocusManager::FocusGroupChangedSignalType *) &(arg1)->FocusGroupChangedSignal(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardFocusManager_FocusedActorEnterKeySignal(void * jarg1) { + void * jresult ; + Dali::Toolkit::KeyboardFocusManager *arg1 = (Dali::Toolkit::KeyboardFocusManager *) 0 ; + Dali::Toolkit::KeyboardFocusManager::FocusedActorEnterKeySignalType *result = 0 ; + + arg1 = (Dali::Toolkit::KeyboardFocusManager *)jarg1; + { + try { + result = (Dali::Toolkit::KeyboardFocusManager::FocusedActorEnterKeySignalType *) &(arg1)->FocusedActorEnterKeySignal(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = (void *)result; + return jresult; +} + + + +SWIGEXPORT unsigned int SWIGSTDCALL CSharp_KeyboardPreFocusChangeSignal_Empty(void * jarg1) { + unsigned int jresult ; + Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *) 0 ; + bool result; + + arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *)jarg1; + { + try { + result = (bool)Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__Empty((Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > const *)arg1); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = result; + return jresult; +} + + +SWIGEXPORT unsigned long SWIGSTDCALL CSharp_KeyboardPreFocusChangeSignal_GetConnectionCount(void * jarg1) { + unsigned long jresult ; + Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *) 0 ; + std::size_t result; + + arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *)jarg1; + { + try { + result = Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__GetConnectionCount((Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > const *)arg1); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = (unsigned long)result; + return jresult; +} + +typedef void* (SWIGSTDCALL* SWIG_CallbackKbPreFocusChange)(void *, void *, int); +SWIG_CallbackKbPreFocusChange swig_callbackOnKbPreFocusChange; + +Dali::Actor OnKbPreFocusChangeCallback(Dali::Actor current, Dali::Actor proposed, Dali::Toolkit::Control::KeyboardFocus::Direction direction) +{ + Dali::Actor *actorp; + Dali::Actor actor; + + actorp = (Dali::Actor *)swig_callbackOnKbPreFocusChange((void *)¤t, (void *)&proposed, direction); + actor = *actorp; + + return actor; +} + +SWIGEXPORT void SWIGSTDCALL CSharp_KeyboardPreFocusChangeSignal_Connect(void * jarg1, SWIG_CallbackKbPreFocusChange callbackOnKbPreFocusChange) { + + swig_callbackOnKbPreFocusChange = callbackOnKbPreFocusChange; + + Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *) 0 ; + Dali::Actor (*arg2)(Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) = (Dali::Actor (*)(Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction)) 0 ; + + arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *)jarg1; + arg2 = (Dali::Actor (*)(Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction))OnKbPreFocusChangeCallback; + + { + try { + Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__Connect(arg1,arg2); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } +} + + +SWIGEXPORT void SWIGSTDCALL CSharp_KeyboardPreFocusChangeSignal_Disconnect(void * jarg1, void * jarg2) { + Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *) 0 ; + Dali::Actor (*arg2)(Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) = (Dali::Actor (*)(Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction)) 0 ; + + arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *)jarg1; + arg2 = (Dali::Actor (*)(Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction))jarg2; + { + try { + Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__Disconnect(arg1,arg2); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_KeyboardPreFocusChangeSignal_Emit(void * jarg1, void * jarg2, void * jarg3, int jarg4) { + void * jresult ; + Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *) 0 ; + Dali::Actor arg2 ; + Dali::Actor arg3 ; + Dali::Toolkit::Control::KeyboardFocus::Direction arg4 ; + Dali::Actor *argp2 ; + Dali::Actor *argp3 ; + Dali::Actor result; + + arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *)jarg1; + argp2 = (Dali::Actor *)jarg2; + if (!argp2) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::Actor", 0); + return 0; + } + arg2 = *argp2; + argp3 = (Dali::Actor *)jarg3; + if (!argp3) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::Actor", 0); + return 0; + } + arg3 = *argp3; + arg4 = (Dali::Toolkit::Control::KeyboardFocus::Direction)jarg4; + { + try { + result = Dali_Signal_Sl_Dali_Actor_Sp_Dali_Actor_Sc_Dali_Actor_Sc_Dali_Toolkit_Control_KeyboardFocus_Direction_SP__Sg__Emit(arg1,arg2,arg3,arg4); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = new Dali::Actor((const Dali::Actor &)result); + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_new_KeyboardPreFocusChangeSignal() { + void * jresult ; + Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *result = 0 ; + + { + try { + result = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *)new Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) >(); + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void SWIGSTDCALL CSharp_delete_KeyboardPreFocusChangeSignal(void * jarg1) { + Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *) 0 ; + + arg1 = (Dali::Signal< Dali::Actor (Dali::Actor,Dali::Actor,Dali::Toolkit::Control::KeyboardFocus::Direction) > *)jarg1; + { + try { + delete arg1; + } catch (std::out_of_range& e) { + { + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; + }; + } catch (std::exception& e) { + { + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } +} + +SWIGEXPORT Dali::BaseHandle * SWIGSTDCALL CSharp_KeyboardFocusManager_SWIGUpcast(Dali::Toolkit::KeyboardFocusManager *jarg1) { + return (Dali::BaseHandle *)jarg1; +} + +#ifdef __cplusplus +} +#endif + diff --git a/plugins/dali-swig/manual/csharp/KeyboardFocusManager.cs b/plugins/dali-swig/manual/csharp/KeyboardFocusManager.cs new file mode 100644 index 0000000..59241fb --- /dev/null +++ b/plugins/dali-swig/manual/csharp/KeyboardFocusManager.cs @@ -0,0 +1,540 @@ +namespace Dali { + +using System; +using System.Runtime.InteropServices; + +public class KeyboardFocusManager : BaseHandle { + private global::System.Runtime.InteropServices.HandleRef swigCPtr; + + internal KeyboardFocusManager(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicManualPINVOKE.KeyboardFocusManager_SWIGUpcast(cPtr), cMemoryOwn) { + swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); + } + + internal static global::System.Runtime.InteropServices.HandleRef getCPtr(KeyboardFocusManager obj) { + return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; + } + + ~KeyboardFocusManager() { + Dispose(); + } + + public override void Dispose() { + lock(this) { + if (swigCPtr.Handle != global::System.IntPtr.Zero) { + if (swigCMemOwn) { + swigCMemOwn = false; + NDalicManualPINVOKE.delete_KeyboardFocusManager(swigCPtr); + } + swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); + } + global::System.GC.SuppressFinalize(this); + base.Dispose(); + } + } + + +/** + * @brief Event arguments that passed via FocusChanged signal + * + */ +public class FocusChangedEventArgs : EventArgs +{ + private Actor _actorCurrent; + private Actor _actorNext; + + /** + * @brief Actor - is the original focused Actor + * + */ + public Actor ActorCurrent + { + get + { + return _actorCurrent; + } + set + { + _actorCurrent = value; + } + } + + /** + * @brief Actor - is the current focused Actor + * + */ + public Actor ActorNext + { + get + { + return _actorNext; + } + set + { + _actorNext = value; + } + } +} + +/** + * @brief Event arguments that passed via FocusGroupChanged signal + * + */ +public class FocusGroupChangedEventArgs : EventArgs +{ + private Actor _currentFocusedActor; + private bool _forwardDirection; + + /** + * @brief Actor - is the current focused Actor + * + */ + public Actor CurrentFocusedActor + { + get + { + return _currentFocusedActor; + } + set + { + _currentFocusedActor = value; + } + } + + /** + * @brief ForwardDirection - is the direction (forward or backward) in which to move the focus next + * + */ + public bool ForwardDirection + { + get + { + return _forwardDirection; + } + set + { + _forwardDirection = value; + } + } +} + +/** + * @brief Event arguments that passed via FocusedActorEnterKey signal + * + */ +public class FocusedActorEnterKeyEventArgs : EventArgs +{ + private Actor _actor; + + /** + * @brief Actor - is the current focused Actor which has the enter key pressed on it. + * + */ + public Actor Actor + { + get + { + return _actor; + } + set + { + _actor = value; + } + } +} + +/** + * @brief Event arguments that passed via PreFocusChange signal + * + */ +public class PreFocusChangeEventArgs : EventArgs +{ + private Actor _current; + private Actor _proposed; + private Control.KeyboardFocus.Direction _direction; + + /** + * @brief Actor - is the current focused Actor. + * + */ + public Actor Current + { + get + { + return _current; + } + set + { + _current = value; + } + } + + /** + * @brief Actor - is the proposed focused Actor. + * + */ + public Actor Proposed + { + get + { + return _proposed; + } + set + { + _proposed = value; + } + } + + /** + * @brief Direction - is the direction of Focus change. + * + */ + public Control.KeyboardFocus.Direction Direction + { + get + { + return _direction; + } + set + { + _direction = value; + } + } +} + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + public delegate void FocusChangedEventHandler(object source, FocusChangedEventArgs e); + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + public delegate void FocusGroupChangedEventHandler(object source, FocusGroupChangedEventArgs e); + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + public delegate void FocusedActorEnterKeyEventHandler(object source, FocusedActorEnterKeyEventArgs e); + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + public delegate Actor PreFocusChangeEventHandler(object source, PreFocusChangeEventArgs e); + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + public delegate IntPtr PreFocusChangeEventCallbackDelegate(IntPtr current, IntPtr proposed, Control.KeyboardFocus.Direction direction); + private PreFocusChangeEventHandler _keyboardFocusManagerPreFocusChangeEventHandler; + private PreFocusChangeEventCallbackDelegate _keyboardFocusManagerPreFocusChangeEventCallbackDelegate; + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + private delegate void FocusChangedEventCallbackDelegate(IntPtr actorCurrent, IntPtr actorNext); + private FocusChangedEventHandler _keyboardFocusManagerFocusChangedEventHandler; + private FocusChangedEventCallbackDelegate _keyboardFocusManagerFocusChangedEventCallbackDelegate; + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + private delegate void FocusGroupChangedEventCallbackDelegate(IntPtr currentFocusedActor, bool forwardDirection); + private FocusGroupChangedEventHandler _keyboardFocusManagerFocusGroupChangedEventHandler; + private FocusGroupChangedEventCallbackDelegate _keyboardFocusManagerFocusGroupChangedEventCallbackDelegate; + + [UnmanagedFunctionPointer(CallingConvention.StdCall)] + private delegate void FocusedActorEnterKeyEventCallbackDelegate(IntPtr actor); + private FocusedActorEnterKeyEventHandler _keyboardFocusManagerFocusedActorEnterKeyEventHandler; + private FocusedActorEnterKeyEventCallbackDelegate _keyboardFocusManagerFocusedActorEnterKeyEventCallbackDelegate; + + public event PreFocusChangeEventHandler PreFocusChange + { + add + { + lock(this) + { + // Restricted to only one listener + if (_keyboardFocusManagerPreFocusChangeEventHandler == null) + { + _keyboardFocusManagerPreFocusChangeEventHandler += value; + + _keyboardFocusManagerPreFocusChangeEventCallbackDelegate = new PreFocusChangeEventCallbackDelegate(OnPreFocusChange); + this.PreFocusChangeSignal().Connect(_keyboardFocusManagerPreFocusChangeEventCallbackDelegate); + } + } + } + + remove + { + lock(this) + { + if (_keyboardFocusManagerPreFocusChangeEventHandler != null) + { + this.PreFocusChangeSignal().Disconnect(_keyboardFocusManagerPreFocusChangeEventCallbackDelegate); + } + + _keyboardFocusManagerPreFocusChangeEventHandler -= value; + } + } + } + + // Callback for KeyboardFocusManager PreFocusChangeSignal + private IntPtr OnPreFocusChange(IntPtr current, IntPtr proposed, Control.KeyboardFocus.Direction direction) + { + Actor actor = null; + PreFocusChangeEventArgs e = new PreFocusChangeEventArgs(); + + // Populate all members of "e" (PreFocusChangeEventArgs) with real data + e.Current = Actor.GetActorFromPtr(current); + e.Proposed = Actor.GetActorFromPtr(proposed); + e.Direction = direction; + + if (_keyboardFocusManagerPreFocusChangeEventHandler != null) + { + //here we send all data to user event handlers + actor = _keyboardFocusManagerPreFocusChangeEventHandler(this, e); + } + + return actor.GetPtrfromActor(); + } + + /** + * @brief Event for FocusChanged signal which can be used to subscribe/unsubscribe the event handler + * (in the type of FocusChangedEventHandler) provided by the user. + * FocusChanged signal is emitted after the current focused actor has been changed. + */ + public event FocusChangedEventHandler FocusChanged + { + add + { + lock(this) + { + // Restricted to only one listener + if (_keyboardFocusManagerFocusChangedEventHandler == null) + { + _keyboardFocusManagerFocusChangedEventHandler += value; + + _keyboardFocusManagerFocusChangedEventCallbackDelegate = new FocusChangedEventCallbackDelegate(OnFocusChanged); + this.FocusChangedSignal().Connect(_keyboardFocusManagerFocusChangedEventCallbackDelegate); + } + } + } + + remove + { + lock(this) + { + if (_keyboardFocusManagerFocusChangedEventHandler != null) + { + this.FocusChangedSignal().Disconnect(_keyboardFocusManagerFocusChangedEventCallbackDelegate); + } + + _keyboardFocusManagerFocusChangedEventHandler -= value; + } + } + } + + // Callback for KeyboardFocusManager FocusChangedSignal + private void OnFocusChanged(IntPtr actorCurrent, IntPtr actorNext) + { + FocusChangedEventArgs e = new FocusChangedEventArgs(); + + // Populate all members of "e" (FocusChangedEventArgs) with real data + e.ActorCurrent = Actor.GetActorFromPtr(actorCurrent); + e.ActorNext = Actor.GetActorFromPtr(actorNext); + + if (_keyboardFocusManagerFocusChangedEventHandler != null) + { + //here we send all data to user event handlers + _keyboardFocusManagerFocusChangedEventHandler(this, e); + } + } + + /** + * @brief Event for FocusGroupChanged signal which can be used to subscribe/unsubscribe the event handler + * (in the type of FocusGroupChangedEventHandler) provided by the user. + * FocusGroupChanged signal is emitted when the focus group has been changed. + */ + public event FocusGroupChangedEventHandler FocusGroupChanged + { + add + { + lock(this) + { + // Restricted to only one listener + if (_keyboardFocusManagerFocusGroupChangedEventHandler == null) + { + _keyboardFocusManagerFocusGroupChangedEventHandler += value; + + _keyboardFocusManagerFocusGroupChangedEventCallbackDelegate = new FocusGroupChangedEventCallbackDelegate(OnFocusGroupChanged); + this.FocusGroupChangedSignal().Connect(_keyboardFocusManagerFocusGroupChangedEventCallbackDelegate); + } + } + } + + remove + { + lock(this) + { + if (_keyboardFocusManagerFocusGroupChangedEventHandler != null) + { + this.FocusGroupChangedSignal().Disconnect(_keyboardFocusManagerFocusGroupChangedEventCallbackDelegate); + } + + _keyboardFocusManagerFocusGroupChangedEventHandler -= value; + } + } + } + + // Callback for KeyboardFocusManager FocusGroupChangedSignal + private void OnFocusGroupChanged(IntPtr currentFocusedActor, bool forwardDirection) + { + FocusGroupChangedEventArgs e = new FocusGroupChangedEventArgs(); + + // Populate all members of "e" (FocusGroupChangedEventArgs) with real data + e.CurrentFocusedActor = Actor.GetActorFromPtr(currentFocusedActor); + e.ForwardDirection = forwardDirection; + + if (_keyboardFocusManagerFocusGroupChangedEventHandler != null) + { + //here we send all data to user event handlers + _keyboardFocusManagerFocusGroupChangedEventHandler(this, e); + } + } + + /** + * @brief Event for FocusedActorEnterKeyPressed signal which can be used to subscribe/unsubscribe the event handler + * (in the type of FocusedActorEnterKeyEventHandler) provided by the user. + * FocusedActorEnterKeyPressed signal is emitted when the current focused actor has the enter key pressed on it. + */ + public event FocusedActorEnterKeyEventHandler FocusedActorEnterKeyPressed + { + add + { + lock(this) + { + // Restricted to only one listener + if (_keyboardFocusManagerFocusedActorEnterKeyEventHandler == null) + { + _keyboardFocusManagerFocusedActorEnterKeyEventHandler += value; + + _keyboardFocusManagerFocusedActorEnterKeyEventCallbackDelegate = new FocusedActorEnterKeyEventCallbackDelegate(OnFocusedActorEnterKey); + this.FocusedActorEnterKeySignal().Connect(_keyboardFocusManagerFocusedActorEnterKeyEventCallbackDelegate); + } + } + } + + remove + { + lock(this) + { + if (_keyboardFocusManagerFocusedActorEnterKeyEventHandler != null) + { + this.FocusedActorEnterKeySignal().Disconnect(_keyboardFocusManagerFocusedActorEnterKeyEventCallbackDelegate); + } + + _keyboardFocusManagerFocusedActorEnterKeyEventHandler -= value; + } + } + } + + // Callback for KeyboardFocusManager FocusedActorEnterKeySignal + private void OnFocusedActorEnterKey(IntPtr actor) + { + FocusedActorEnterKeyEventArgs e = new FocusedActorEnterKeyEventArgs(); + + // Populate all members of "e" (FocusedActorEnterKeyEventArgs) with real data + e.Actor = Actor.GetActorFromPtr(actor); + + if (_keyboardFocusManagerFocusedActorEnterKeyEventHandler != null) + { + //here we send all data to user event handlers + _keyboardFocusManagerFocusedActorEnterKeyEventHandler(this, e); + } + } + + public KeyboardFocusManager() : this(NDalicManualPINVOKE.new_KeyboardFocusManager(), true) { + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + + public static KeyboardFocusManager Get() { + KeyboardFocusManager ret = new KeyboardFocusManager(NDalicManualPINVOKE.KeyboardFocusManager_Get(), true); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public bool SetCurrentFocusActor(Actor actor) { + bool ret = NDalicManualPINVOKE.KeyboardFocusManager_SetCurrentFocusActor(swigCPtr, Actor.getCPtr(actor)); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public Actor GetCurrentFocusActor() { + Actor ret = new Actor(NDalicManualPINVOKE.KeyboardFocusManager_GetCurrentFocusActor(swigCPtr), true); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public bool MoveFocus(Control.KeyboardFocus.Direction direction) { + bool ret = NDalicManualPINVOKE.KeyboardFocusManager_MoveFocus(swigCPtr, (int)direction); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public void ClearFocus() { + NDalicManualPINVOKE.KeyboardFocusManager_ClearFocus(swigCPtr); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + + public void SetFocusGroupLoop(bool enabled) { + NDalicManualPINVOKE.KeyboardFocusManager_SetFocusGroupLoop(swigCPtr, enabled); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + + public bool GetFocusGroupLoop() { + bool ret = NDalicManualPINVOKE.KeyboardFocusManager_GetFocusGroupLoop(swigCPtr); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public void SetAsFocusGroup(Actor actor, bool isFocusGroup) { + NDalicManualPINVOKE.KeyboardFocusManager_SetAsFocusGroup(swigCPtr, Actor.getCPtr(actor), isFocusGroup); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + + public bool IsFocusGroup(Actor actor) { + bool ret = NDalicManualPINVOKE.KeyboardFocusManager_IsFocusGroup(swigCPtr, Actor.getCPtr(actor)); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public Actor GetFocusGroup(Actor actor) { + Actor ret = new Actor(NDalicManualPINVOKE.KeyboardFocusManager_GetFocusGroup(swigCPtr, Actor.getCPtr(actor)), true); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public void SetFocusIndicatorActor(Actor indicator) { + NDalicManualPINVOKE.KeyboardFocusManager_SetFocusIndicatorActor(swigCPtr, Actor.getCPtr(indicator)); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + + public Actor GetFocusIndicatorActor() { + Actor ret = new Actor(NDalicManualPINVOKE.KeyboardFocusManager_GetFocusIndicatorActor(swigCPtr), true); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public KeyboardPreFocusChangeSignal PreFocusChangeSignal() { + KeyboardPreFocusChangeSignal ret = new KeyboardPreFocusChangeSignal(NDalicManualPINVOKE.KeyboardFocusManager_PreFocusChangeSignal(swigCPtr), false); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public FocusChangedSignal FocusChangedSignal() { + FocusChangedSignal ret = new FocusChangedSignal(NDalicManualPINVOKE.KeyboardFocusManager_FocusChangedSignal(swigCPtr), false); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public FocusGroupChangedSignal FocusGroupChangedSignal() { + FocusGroupChangedSignal ret = new FocusGroupChangedSignal(NDalicManualPINVOKE.KeyboardFocusManager_FocusGroupChangedSignal(swigCPtr), false); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public ActorSignal FocusedActorEnterKeySignal() { + ActorSignal ret = new ActorSignal(NDalicManualPINVOKE.KeyboardFocusManager_FocusedActorEnterKeySignal(swigCPtr), false); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + +} + +} diff --git a/plugins/dali-swig/manual/csharp/KeyboardPreFocusChangeSignal.cs b/plugins/dali-swig/manual/csharp/KeyboardPreFocusChangeSignal.cs new file mode 100644 index 0000000..ecdc832 --- /dev/null +++ b/plugins/dali-swig/manual/csharp/KeyboardPreFocusChangeSignal.cs @@ -0,0 +1,74 @@ +using System; + +namespace Dali { + +public delegate IntPtr SwigDelegateKeyboardPreFocusChangeSignal(IntPtr current, IntPtr proposed, Control.KeyboardFocus.Direction direction); + +public class KeyboardPreFocusChangeSignal : global::System.IDisposable { + private global::System.Runtime.InteropServices.HandleRef swigCPtr; + protected bool swigCMemOwn; + + internal KeyboardPreFocusChangeSignal(global::System.IntPtr cPtr, bool cMemoryOwn) { + swigCMemOwn = cMemoryOwn; + swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); + } + + internal static global::System.Runtime.InteropServices.HandleRef getCPtr(KeyboardPreFocusChangeSignal obj) { + return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; + } + + ~KeyboardPreFocusChangeSignal() { + Dispose(); + } + + public virtual void Dispose() { + lock(this) { + if (swigCPtr.Handle != global::System.IntPtr.Zero) { + if (swigCMemOwn) { + swigCMemOwn = false; + NDalicManualPINVOKE.delete_KeyboardPreFocusChangeSignal(swigCPtr); + } + swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); + } + global::System.GC.SuppressFinalize(this); + } + } + + public bool Empty() { + bool ret = NDalicManualPINVOKE.KeyboardPreFocusChangeSignal_Empty(swigCPtr); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public uint GetConnectionCount() { + uint ret = NDalicManualPINVOKE.KeyboardPreFocusChangeSignal_GetConnectionCount(swigCPtr); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public void Connect(KeyboardFocusManager.PreFocusChangeEventCallbackDelegate func) { + NDalicManualPINVOKE.KeyboardPreFocusChangeSignal_Connect(swigCPtr, func); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + + public void Disconnect(System.Delegate func) { + System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate(func); + { + NDalicManualPINVOKE.KeyboardPreFocusChangeSignal_Disconnect(swigCPtr, new System.Runtime.InteropServices.HandleRef(this, ip)); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + } + + public Actor Emit(Actor arg1, Actor arg2, Control.KeyboardFocus.Direction arg3) { + Actor ret = new Actor(NDalicManualPINVOKE.KeyboardPreFocusChangeSignal_Emit(swigCPtr, Actor.getCPtr(arg1), Actor.getCPtr(arg2), (int)arg3), true); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } + + public KeyboardPreFocusChangeSignal() : this(NDalicManualPINVOKE.new_KeyboardPreFocusChangeSignal(), true) { + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + +} + +} diff --git a/plugins/dali-swig/manual/csharp/ManualPINVOKE.cs b/plugins/dali-swig/manual/csharp/ManualPINVOKE.cs new file mode 100644 index 0000000..48196e3 --- /dev/null +++ b/plugins/dali-swig/manual/csharp/ManualPINVOKE.cs @@ -0,0 +1,85 @@ +namespace Dali { + +class NDalicManualPINVOKE { + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_new_KeyboardFocusManager")] + public static extern global::System.IntPtr new_KeyboardFocusManager(); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_delete_KeyboardFocusManager")] + public static extern void delete_KeyboardFocusManager(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_Get")] + public static extern global::System.IntPtr KeyboardFocusManager_Get(); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_SetCurrentFocusActor")] + public static extern bool KeyboardFocusManager_SetCurrentFocusActor(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_GetCurrentFocusActor")] + public static extern global::System.IntPtr KeyboardFocusManager_GetCurrentFocusActor(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_MoveFocus")] + public static extern bool KeyboardFocusManager_MoveFocus(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_ClearFocus")] + public static extern void KeyboardFocusManager_ClearFocus(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_SetFocusGroupLoop")] + public static extern void KeyboardFocusManager_SetFocusGroupLoop(global::System.Runtime.InteropServices.HandleRef jarg1, bool jarg2); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_GetFocusGroupLoop")] + public static extern bool KeyboardFocusManager_GetFocusGroupLoop(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_SetAsFocusGroup")] + public static extern void KeyboardFocusManager_SetAsFocusGroup(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, bool jarg3); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_IsFocusGroup")] + public static extern bool KeyboardFocusManager_IsFocusGroup(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_GetFocusGroup")] + public static extern global::System.IntPtr KeyboardFocusManager_GetFocusGroup(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_SetFocusIndicatorActor")] + public static extern void KeyboardFocusManager_SetFocusIndicatorActor(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_GetFocusIndicatorActor")] + public static extern global::System.IntPtr KeyboardFocusManager_GetFocusIndicatorActor(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_PreFocusChangeSignal")] + public static extern global::System.IntPtr KeyboardFocusManager_PreFocusChangeSignal(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_FocusChangedSignal")] + public static extern global::System.IntPtr KeyboardFocusManager_FocusChangedSignal(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_FocusGroupChangedSignal")] + public static extern global::System.IntPtr KeyboardFocusManager_FocusGroupChangedSignal(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_FocusedActorEnterKeySignal")] + public static extern global::System.IntPtr KeyboardFocusManager_FocusedActorEnterKeySignal(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardPreFocusChangeSignal_Empty")] + public static extern bool KeyboardPreFocusChangeSignal_Empty(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardPreFocusChangeSignal_GetConnectionCount")] + public static extern uint KeyboardPreFocusChangeSignal_GetConnectionCount(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardPreFocusChangeSignal_Connect")] + public static extern void KeyboardPreFocusChangeSignal_Connect(global::System.Runtime.InteropServices.HandleRef jarg1, KeyboardFocusManager.PreFocusChangeEventCallbackDelegate delegate1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardPreFocusChangeSignal_Disconnect")] + public static extern void KeyboardPreFocusChangeSignal_Disconnect(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardPreFocusChangeSignal_Emit")] + public static extern global::System.IntPtr KeyboardPreFocusChangeSignal_Emit(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_new_KeyboardPreFocusChangeSignal")] + public static extern global::System.IntPtr new_KeyboardPreFocusChangeSignal(); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_delete_KeyboardPreFocusChangeSignal")] + public static extern void delete_KeyboardPreFocusChangeSignal(global::System.Runtime.InteropServices.HandleRef jarg1); + + [global::System.Runtime.InteropServices.DllImport("NDalic", EntryPoint="CSharp_KeyboardFocusManager_SWIGUpcast")] + public static extern global::System.IntPtr KeyboardFocusManager_SWIGUpcast(global::System.IntPtr jarg1); + +} + +} diff --git a/plugins/dali-swig/property-wrapper.rb b/plugins/dali-swig/property-wrapper.rb index 5e60919..8e76da6 100755 --- a/plugins/dali-swig/property-wrapper.rb +++ b/plugins/dali-swig/property-wrapper.rb @@ -180,7 +180,7 @@ end def writePropertiesToCSharpFile( daliClass ) # open the CSharp file autogenerated by SWIG - swigFiles = $daliSwigPath + "/csharp/" + swigFiles = $daliSwigPath + "/automatic/csharp/" fileName =(swigFiles+daliClass.name) + ".cs" @@ -219,7 +219,7 @@ end def writeChildPropertiesToCSharpFile( daliClass ) # open the CSharp file autogenerated by SWIG - swigFiles = $daliSwigPath + "/csharp/" + swigFiles = $daliSwigPath + "/automatic/csharp/" # Add all the child properties to Control fileName = (swigFiles+"Control") + ".cs" diff --git a/plugins/dali-swig/swig.cmd b/plugins/dali-swig/swig.cmd deleted file mode 100644 index adc59ba..0000000 --- a/plugins/dali-swig/swig.cmd +++ /dev/null @@ -1 +0,0 @@ -swig -csharp -c++ -outdir ./csharp -namespace Dali -o ./cpp/dali_wrap.cpp ./SWIG/dali.i