X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-csharp-binder%2Fsrc%2Fapplication.cpp;h=445873d4a0b687e87dd190682e9b001c234f7eb0;hb=810f6d578fad7c8f5b5bf346d4df96a4784fdbce;hp=6870c848a9309ef2df03da7f151d3ae513317920;hpb=3aa616da3ffa8d894caffe6b99375a216363ba53;p=platform%2Fcore%2Fuifw%2Fdali-csharp-binder.git diff --git a/dali-csharp-binder/src/application.cpp b/dali-csharp-binder/src/application.cpp index 6870c84..445873d 100755 --- a/dali-csharp-binder/src/application.cpp +++ b/dali-csharp-binder/src/application.cpp @@ -1,4 +1,4 @@ -/** Copyright (c) 2017 Samsung Electronics Co., Ltd. +/** Copyright (c) 2019 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -19,17 +19,52 @@ #endif #include "common.h" +#include "string" #include #include +#include /* Callback for returning strings to C# without leaking memory */ typedef char * (SWIGSTDCALL* SWIG_CSharpStringHelperCallback)(const char *); extern SWIG_CSharpStringHelperCallback SWIG_csharp_string_callback; - +namespace +{ // keep argcs and argv so they're always available to DALi -int argC = 1; -char **argV = NULL; +int gArgC = 0; +char** gArgV = nullptr; +} // unnamed namespace + +SWIGINTERN bool Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__Empty(Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > const *self){ + return self->Empty(); +} +SWIGINTERN std::size_t Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__GetConnectionCount(Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > const *self){ + return self->GetConnectionCount(); +} +SWIGINTERN void Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__Connect(Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *self,void (*func)(Dali::DeviceStatus::Battery::Status)){ + self->Connect( func ); +} +SWIGINTERN void Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__Disconnect(Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *self,void (*func)(Dali::DeviceStatus::Battery::Status)){ + self->Disconnect( func ); +} +SWIGINTERN void Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__Emit(Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *self,Dali::DeviceStatus::Battery::Status arg){ + self->Emit( arg ); +} +SWIGINTERN bool Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__Empty(Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > const *self){ + return self->Empty(); +} +SWIGINTERN std::size_t Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__GetConnectionCount(Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > const *self){ + return self->GetConnectionCount(); +} +SWIGINTERN void Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__Connect(Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *self,void (*func)(Dali::DeviceStatus::Memory::Status)){ + self->Connect( func ); +} +SWIGINTERN void Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__Disconnect(Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *self,void (*func)(Dali::DeviceStatus::Memory::Status)){ + self->Disconnect( func ); +} +SWIGINTERN void Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__Emit(Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *self,Dali::DeviceStatus::Memory::Status arg){ + self->Emit( arg ); +} SWIGINTERN bool Dali_Signal_Sl_void_Sp_Dali_Application_SA__SP__Sg__Empty(Dali::Signal< void (Dali::Application &) > const *self){ return self->Empty(); @@ -87,12 +122,17 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_0() { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = new Dali::Application((const Dali::Application &)result); return jresult; } @@ -100,33 +140,22 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_0() { SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_1(int jarg1) { void * jresult ; - int *arg1 = (int *) 0 ; - char ***arg2 ; - Dali::Application result; + Dali::Application result; { - // Todo generate argv data from the C# args - char **array; // two dimensional array - int numStrings = 1; // number of strings - int stringLength = 30; // max string length. - array = (char **)malloc( (numStrings + 1 )* sizeof(char *) ); - argV = array; - - // allocate the string data - for( int i=0; i < numStrings; i++) - { - array[i]=(char *)malloc( stringLength * sizeof(char *) ); - } - array[ numStrings ] = NULL; // we allocated +1 for hold the NULL part - - strcpy( array[0], "dali-csharp-app"); - - arg1 = &argC; - arg2 = &argV; + std::string app_name = "dali-csharp-app"; + int stringLength = app_name.length(); + gArgC = 1; + gArgV = new char*[gArgC + 1]; + gArgV[0] = new char[stringLength + 1]; + + strncpy(gArgV[0], app_name.c_str(), stringLength); + gArgV[0][stringLength] = '\0'; + gArgV[1] = NULL; } { try { - result = Dali::Application::New(arg1,arg2); + result = Dali::Application::New( &gArgC, &gArgV ); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -135,12 +164,17 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_1(int jarg1) { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = new Dali::Application((const Dali::Application &)result); return jresult; } @@ -148,40 +182,32 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_1(int jarg1) { SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_2(int jarg1, char * jarg3) { void * jresult ; - int *arg1 = (int *) 0 ; - char ***arg2 ; - std::string *arg3 = 0 ; - Dali::Application result; + std::string *arg3 = 0; + Dali::Application result; { - // Todo generate argv data from the C# args - char **array; // two dimensional array - int numStrings = 1; // number of strings - int stringLength = 30; // max string length. - array = (char **)malloc( (numStrings + 1 )* sizeof(char *) ); - argV = array; - - // allocate the string data - for( int i=0; i < numStrings; i++) - { - array[i]=(char *)malloc( stringLength * sizeof(char *) ); - } - array[ numStrings ] = NULL; // we allocated +1 for hold the NULL part - - strcpy( array[0], "dali-csharp-app"); - - arg1 = &argC; - arg2 = &argV; + std::string app_name = "dali-csharp-app"; + int stringLength = app_name.length(); + gArgC = 1; + gArgV = new char*[gArgC + 1]; + gArgV[0] = new char[stringLength + 1]; + + strncpy(gArgV[0], app_name.c_str(), stringLength); + gArgV[0][stringLength] = '\0'; + gArgV[1] = NULL; } if (!jarg3) { SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "null string", 0); + delete []gArgV[0]; + delete []gArgV; + gArgV = nullptr; return 0; } std::string arg3_str(jarg3); arg3 = &arg3_str; { try { - result = Dali::Application::New(arg1,arg2,(std::string const &)*arg3); + result = Dali::Application::New( &gArgC, &gArgV, (std::string const &)*arg3 ); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -190,12 +216,17 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_2(int jarg1, cha { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = new Dali::Application((const Dali::Application &)result); //argout typemap for const std::string& @@ -206,42 +237,105 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_2(int jarg1, cha SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_3(int jarg1, char * jarg3, int jarg4) { void * jresult ; + Dali::Application::WINDOW_MODE arg4; + + Dali::Application result; + { + std::string app_name = "dali-csharp-app"; + int stringLength = app_name.length(); + gArgC = 1; + gArgV = new char*[gArgC + 1]; + gArgV[0] = new char[stringLength + 1]; + + strncpy(gArgV[0], app_name.c_str(), stringLength); + gArgV[0][stringLength] = '\0'; + gArgV[1] = NULL; + } + if (!jarg3) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "null string", 0); + delete []gArgV[0]; + delete []gArgV; + gArgV = nullptr; + return 0; + } + std::string arg3(jarg3); + arg4 = (Dali::Application::WINDOW_MODE)jarg4; + { + try { + result = Dali::Application::New( &gArgC, &gArgV, 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = new Dali::Application((const Dali::Application &)result); + + //argout typemap for const std::string& + + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__MANUAL_4(int jarg1, char * jarg2, char * jarg3, int jarg4) { + void * jresult ; int *arg1 = (int *) 0 ; char ***arg2 ; - std::string *arg3 = 0 ; Dali::Application::WINDOW_MODE arg4 ; Dali::Application result; - { // Todo generate argv data from the C# args - char **array; // two dimensional array - int numStrings = 1; // number of strings - int stringLength = 30; // max string length. - array = (char **)malloc( (numStrings + 1 )* sizeof(char *) ); - argV = array; + int index = 0; + int length = 0; + char *retPtr = NULL; + char *nextPtr; - // allocate the string data - for( int i=0; i < numStrings; i++) + gArgV = new char*[jarg1 + 1]; + + for(retPtr = strtok_r(jarg2, " ", &nextPtr); + retPtr != NULL && index < jarg1; + retPtr = strtok_r(NULL, " ", &nextPtr)) { - array[i]=(char *)malloc( stringLength * sizeof(char *) ); + length = 0; + length = strlen(retPtr); + gArgV[ index ] = new char[ length + 1 ]; + strncpy( gArgV[ index ], retPtr, length ); + gArgV[ index ][ length ] = '\0'; + index++; + } + + while( index < jarg1 ) + { + //if jarg1 - index >1, maybe cause error. + gArgV[index] = NULL; + index++; } - array[ numStrings ] = NULL; // we allocated +1 for hold the NULL part - strcpy( array[0], "dali-csharp-app"); + gArgV[jarg1] = NULL; + gArgC = jarg1; - arg1 = &argC; - arg2 = &argV; - } - if (!jarg3) { - SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "null string", 0); - return 0; + arg1 = &gArgC; + arg2 = &gArgV; } - std::string arg3_str(jarg3); - arg3 = &arg3_str; + + std::string arg3(jarg3); arg4 = (Dali::Application::WINDOW_MODE)jarg4; { try { - result = Dali::Application::New(arg1,arg2,(std::string const &)*arg3,arg4); + result = Dali::Application::New( arg1, arg2, arg3, arg4); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -250,6 +344,10 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_3(int jarg1, cha { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; @@ -257,13 +355,9 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_3(int jarg1, cha } } jresult = new Dali::Application((const Dali::Application &)result); - - //argout typemap for const std::string& - return jresult; } - SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_new_Application__SWIG_0() { void * jresult ; Dali::Application *result = 0 ; @@ -279,12 +373,17 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_new_Application__SWIG_0() { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (void *)result; return jresult; } @@ -311,12 +410,17 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_new_Application__SWIG_1(void * jarg1) { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (void *)result; return jresult; } @@ -345,12 +449,17 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_Assign(void * jarg1, void { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (void *)result; return jresult; } @@ -363,6 +472,15 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_delete_Application(void * jarg1) { { try { delete arg1; + if( gArgV ) + { + // free string data + for( int i=0; i < gArgC+1; i++) + { + delete [] gArgV[i]; + } + delete [] gArgV; + } } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; @@ -371,12 +489,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_delete_Application(void * jarg1) { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -395,12 +518,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_MainLoop__SWIG_0(void * jarg { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -427,12 +555,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_MainLoop__SWIG_1(void * jarg { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -451,12 +584,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_Lower(void * jarg1) { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -475,12 +613,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_Quit(void * jarg1) { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -503,12 +646,17 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_Application_AddIdle(void * jarg1 { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = result; return jresult; } @@ -531,16 +679,78 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_GetWindow(void * jarg1) { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = new Dali::Window((const Dali::Window &)result); return jresult; } +SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_Application_GetWindowsListSize() { + unsigned int jresult ; + Dali::WindowContainer result; + { + try { + result = Dali::Adaptor::Get().GetWindows(); + jresult = result.size(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + return jresult; +} + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_GetWindowsFromList(uint jarg1) { + void * jresult ; + uint index = jarg1; + Dali::WindowContainer result; + + { + try { + result = Dali::Adaptor::Get().GetWindows(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = new Dali::Window((const Dali::Window &)result[index]); + return jresult; +} SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_ReplaceWindow(void * jarg1, void * jarg2, char * jarg3) { Dali::Application *arg1 = (Dali::Application *) 0 ; @@ -572,6 +782,10 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_ReplaceWindow(void * jarg1, { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; @@ -579,6 +793,7 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_ReplaceWindow(void * jarg1, } } + //argout typemap for const std::string& } @@ -599,52 +814,582 @@ SWIGEXPORT char * SWIGSTDCALL CSharp_Dali_Application_GetResourcePath() { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = SWIG_csharp_string_callback((&result)->c_str()); return jresult; } - -SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_SetViewMode(void * jarg1, int jarg2) { +SWIGEXPORT char * SWIGSTDCALL CSharp_Dali_Application_GetRegion(void * jarg1) { + char * jresult ; Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::ViewMode arg2 ; + std::string result; arg1 = (Dali::Application *)jarg1; - arg2 = (Dali::ViewMode)jarg2; { try { - (arg1)->SetViewMode(arg2); + result = (arg1)->GetRegion(); } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = SWIG_csharp_string_callback((&result)->c_str()); + return jresult; } -SWIGEXPORT int SWIGSTDCALL CSharp_Dali_Application_GetViewMode(void * jarg1) { - int jresult ; +SWIGEXPORT char * SWIGSTDCALL CSharp_Dali_Application_GetLanguage(void * jarg1) { + char * jresult ; Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::ViewMode result; + std::string result; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (arg1)->GetLanguage(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = SWIG_csharp_string_callback((&result)->c_str()); + return jresult; +} + +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_SetViewMode(void * jarg1, int jarg2) { + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::ViewMode arg2 ; + + arg1 = (Dali::Application *)jarg1; + arg2 = (Dali::ViewMode)jarg2; + { + try { + (arg1)->SetViewMode(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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } + +} + + +SWIGEXPORT int SWIGSTDCALL CSharp_Dali_Application_GetViewMode(void * jarg1) { + int jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::ViewMode result; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::ViewMode)((Dali::Application const *)arg1)->GetViewMode(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (int)result; + return jresult; +} + + +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_SetStereoBase(void * jarg1, float jarg2) { + Dali::Application *arg1 = (Dali::Application *) 0 ; + float arg2 ; + + arg1 = (Dali::Application *)jarg1; + arg2 = (float)jarg2; + { + try { + (arg1)->SetStereoBase(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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + }; + } + } + +} + + +SWIGEXPORT float SWIGSTDCALL CSharp_Dali_Application_GetStereoBase(void * jarg1) { + float jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + float result; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (float)((Dali::Application const *)arg1)->GetStereoBase(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_InitSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppSignalType *) &(arg1)->InitSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_TerminateSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppSignalType *) &(arg1)->TerminateSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_PauseSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppSignalType *) &(arg1)->PauseSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_ResumeSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppSignalType *) &(arg1)->ResumeSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_ResetSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppSignalType *) &(arg1)->ResetSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_ResizeSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppSignalType *) &(arg1)->ResizeSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_AppControlSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppControlSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppControlSignalType *) &(arg1)->AppControlSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_LanguageChangedSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppSignalType *) &(arg1)->LanguageChangedSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_RegionChangedSignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::AppSignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::AppSignalType *) &(arg1)->RegionChangedSignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_LowBatterySignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::LowBatterySignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::LowBatterySignalType *) &(arg1)->LowBatterySignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + + jresult = (void *)result; + return jresult; +} + + +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_LowMemorySignal(void * jarg1) { + void * jresult ; + Dali::Application *arg1 = (Dali::Application *) 0 ; + Dali::Application::LowMemorySignalType *result = 0 ; + + arg1 = (Dali::Application *)jarg1; + { + try { + result = (Dali::Application::LowMemorySignalType *) &(arg1)->LowMemorySignal(); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = (void *)result; + return jresult; +} - arg1 = (Dali::Application *)jarg1; + +SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_Application_LowBatterySignalType_Empty(void * jarg1) { + unsigned int jresult ; + Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *) 0 ; + bool result; + + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *)jarg1; { try { - result = (Dali::ViewMode)((Dali::Application const *)arg1)->GetViewMode(); + result = (bool)Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__Empty((Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > const *)arg1); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -653,136 +1398,157 @@ SWIGEXPORT int SWIGSTDCALL CSharp_Dali_Application_GetViewMode(void * jarg1) { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } - jresult = (int)result; + + jresult = result; return jresult; } -SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_SetStereoBase(void * jarg1, float jarg2) { - Dali::Application *arg1 = (Dali::Application *) 0 ; - float arg2 ; +SWIGEXPORT unsigned long SWIGSTDCALL CSharp_Dali_Application_LowBatterySignalType_GetConnectionCount(void * jarg1) { + unsigned long jresult ; + Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *) 0 ; + std::size_t result; - arg1 = (Dali::Application *)jarg1; - arg2 = (float)jarg2; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *)jarg1; { try { - (arg1)->SetStereoBase(arg2); + result = Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__GetConnectionCount((Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > const *)arg1); } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (unsigned long)result; + return jresult; } -SWIGEXPORT float SWIGSTDCALL CSharp_Dali_Application_GetStereoBase(void * jarg1) { - float jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - float result; +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_LowBatterySignalType_Connect(void * jarg1, void * jarg2) { + Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *) 0 ; + void (*arg2)(Dali::DeviceStatus::Battery::Status) = (void (*)(Dali::DeviceStatus::Battery::Status)) 0 ; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *)jarg1; + arg2 = (void (*)(Dali::DeviceStatus::Battery::Status))jarg2; { try { - result = (float)((Dali::Application const *)arg1)->GetStereoBase(); + Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__Connect(arg1,arg2); } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } - jresult = result; - return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_InitSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_LowBatterySignalType_Disconnect(void * jarg1, void * jarg2) { + Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *) 0 ; + void (*arg2)(Dali::DeviceStatus::Battery::Status) = (void (*)(Dali::DeviceStatus::Battery::Status)) 0 ; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *)jarg1; + arg2 = (void (*)(Dali::DeviceStatus::Battery::Status))jarg2; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->InitSignal(); + Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__Disconnect(arg1,arg2); } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } - jresult = (void *)result; - return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_TerminateSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_LowBatterySignalType_Emit(void * jarg1, void * jarg2) { + Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *) 0 ; + Dali::DeviceStatus::Battery::Status arg2 ; + Dali::DeviceStatus::Battery::Status *argp2 ; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *)jarg1; + argp2 = (Dali::DeviceStatus::Battery::Status *)jarg2; + if (!argp2) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::DeviceStatus::Battery::Status", 0); + return ; + } + arg2 = *argp2; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->TerminateSignal(); + Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Battery_Status_SP__Sg__Emit(arg1,arg2); } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } - jresult = (void *)result; - return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_PauseSignal(void * jarg1) { +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_new_LowBatterySignalType() { void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; + Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *result = 0 ; - arg1 = (Dali::Application *)jarg1; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->PauseSignal(); + result = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *)new Dali::Signal< void (Dali::DeviceStatus::Battery::Status) >(); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -791,54 +1557,59 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_PauseSignal(void * jarg1) { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (void *)result; return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_ResumeSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_delete_LowBatterySignalType(void * jarg1) { + Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *) 0 ; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Battery::Status) > *)jarg1; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->ResumeSignal(); + delete arg1; } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } - jresult = (void *)result; - return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_ResetSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; +SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_Application_LowMemorySignalType_Empty(void * jarg1) { + unsigned int jresult ; + Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *) 0 ; + bool result; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *)jarg1; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->ResetSignal(); + result = (bool)Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__Empty((Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > const *)arg1); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -847,26 +1618,30 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_ResetSignal(void * jarg1) { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } - jresult = (void *)result; + jresult = result; return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_ResizeSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; +SWIGEXPORT unsigned long SWIGSTDCALL CSharp_Dali_Application_LowMemorySignalType_GetConnectionCount(void * jarg1) { + unsigned long jresult ; + Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *) 0 ; + std::size_t result; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *)jarg1; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->ResizeSignal(); + result = Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__GetConnectionCount((Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > const *)arg1); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -875,110 +1650,124 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_ResizeSignal(void * jarg1) { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } - jresult = (void *)result; + jresult = (unsigned long)result; return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_AppControlSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppControlSignalType *result = 0 ; +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_LowMemorySignalType_Connect(void * jarg1, void * jarg2) { + Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *) 0 ; + void (*arg2)(Dali::DeviceStatus::Memory::Status) = (void (*)(Dali::DeviceStatus::Memory::Status)) 0 ; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *)jarg1; + arg2 = (void (*)(Dali::DeviceStatus::Memory::Status))jarg2; { try { - result = (Dali::Application::AppControlSignalType *) &(arg1)->AppControlSignal(); + Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__Connect(arg1,arg2); } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } - jresult = (void *)result; - return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_LanguageChangedSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_LowMemorySignalType_Disconnect(void * jarg1, void * jarg2) { + Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *) 0 ; + void (*arg2)(Dali::DeviceStatus::Memory::Status) = (void (*)(Dali::DeviceStatus::Memory::Status)) 0 ; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *)jarg1; + arg2 = (void (*)(Dali::DeviceStatus::Memory::Status))jarg2; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->LanguageChangedSignal(); + Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__Disconnect(arg1,arg2); } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } - jresult = (void *)result; - return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_RegionChangedSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_LowMemorySignalType_Emit(void * jarg1, void * jarg2) { + Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *) 0 ; + Dali::DeviceStatus::Memory::Status arg2 ; + Dali::DeviceStatus::Memory::Status *argp2 ; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *)jarg1; + argp2 = (Dali::DeviceStatus::Memory::Status *)jarg2; + if (!argp2) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::DeviceStatus::Memory::Status", 0); + return ; + } + arg2 = *argp2; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->RegionChangedSignal(); + Dali_Signal_Sl_void_Sp_Dali_DeviceStatus_Memory_Status_SP__Sg__Emit(arg1,arg2); } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } - jresult = (void *)result; - return jresult; } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_BatteryLowSignal(void * jarg1) { +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_new_LowMemorySignalType() { void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; + Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *result = 0 ; - arg1 = (Dali::Application *)jarg1; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->BatteryLowSignal(); + result = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *)new Dali::Signal< void (Dali::DeviceStatus::Memory::Status) >(); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -987,6 +1776,10 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_BatteryLowSignal(void * ja { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; @@ -998,31 +1791,31 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_BatteryLowSignal(void * ja } -SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_MemoryLowSignal(void * jarg1) { - void * jresult ; - Dali::Application *arg1 = (Dali::Application *) 0 ; - Dali::Application::AppSignalType *result = 0 ; +SWIGEXPORT void SWIGSTDCALL CSharp_Dali_Application_delete_LowMemorySignalType(void * jarg1) { + Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *) 0 ; - arg1 = (Dali::Application *)jarg1; + arg1 = (Dali::Signal< void (Dali::DeviceStatus::Memory::Status) > *)jarg1; { try { - result = (Dali::Application::AppSignalType *) &(arg1)->MemoryLowSignal(); + delete arg1; } catch (std::out_of_range& e) { { - SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return ; }; } catch (std::exception& e) { { - SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; + SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; + }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; }; } catch (...) { { - SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } - jresult = (void *)result; - return jresult; } @@ -1043,12 +1836,17 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_ApplicationSignal_Empty(void * j { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = result; return jresult; } @@ -1071,12 +1869,17 @@ SWIGEXPORT unsigned long SWIGSTDCALL CSharp_Dali_ApplicationSignal_GetConnection { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (unsigned long)result; return jresult; } @@ -1099,12 +1902,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_ApplicationSignal_Connect(void * jarg1, { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -1125,12 +1933,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_ApplicationSignal_Disconnect(void * jarg { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -1155,12 +1968,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_ApplicationSignal_Emit(void * jarg1, voi { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -1179,12 +1997,17 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_new_ApplicationSignal() { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (void *)result; return jresult; } @@ -1205,12 +2028,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_delete_ApplicationSignal(void * jarg1) { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -1231,12 +2059,17 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_ApplicationControlSignal_Empty(v { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = result; return jresult; } @@ -1259,12 +2092,17 @@ SWIGEXPORT unsigned long SWIGSTDCALL CSharp_Dali_ApplicationControlSignal_GetCon { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (unsigned long)result; return jresult; } @@ -1287,12 +2125,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_ApplicationControlSignal_Connect(void * { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -1313,12 +2156,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_ApplicationControlSignal_Disconnect(void { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -1345,12 +2193,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_ApplicationControlSignal_Emit(void * jar { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -1369,12 +2222,17 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_new_ApplicationControlSignal() { { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = (void *)result; return jresult; } @@ -1395,12 +2253,17 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_delete_ApplicationControlSignal(void * j { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return ; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return ; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return ; }; } } + } @@ -1410,7 +2273,6 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_4(int jarg1, cha void * jresult ; int *arg1 = (int *) 0 ; char ***arg2 ; - std::string *arg3 = 0 ; Dali::Application::WINDOW_MODE arg4 ; Dali::PositionSize arg5 ; Dali::PositionSize *argp5 ; @@ -1422,26 +2284,35 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_4(int jarg1, cha int numStrings = 1; // number of strings int stringLength = 30; // max string length. array = (char **)malloc( (numStrings + 1 )* sizeof(char *) ); - argV = array; + if(!array) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "array is null", 0); + return 0; + } + gArgV = array; // allocate the string data for( int i=0; i < numStrings; i++) { - array[i]=(char *)malloc( stringLength * sizeof(char *) ); + array[i]=(char *)malloc( stringLength * sizeof(char) ); } array[ numStrings ] = NULL; // we allocated +1 for hold the NULL part - strcpy( array[0], "dali-csharp-app"); + std::string temp = "dali-csharp-app"; + + if(!array[0]) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "array[0] is null", 0); + return 0; + } + array[0][temp.copy(array[0], strlen(array[0])-1)] = '\0'; - arg1 = &argC; - arg2 = &argV; + arg1 = &gArgC; + arg2 = &gArgV; } if (!jarg3) { SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "null string", 0); return 0; } - std::string arg3_str(jarg3); - arg3 = &arg3_str; + std::string arg3(jarg3); arg4 = (Dali::Application::WINDOW_MODE)jarg4; argp5 = (Dali::PositionSize *)jarg5; if (!argp5) { @@ -1451,7 +2322,7 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_4(int jarg1, cha arg5 = *argp5; { try { - result = Dali::Application::New(arg1,arg2,(std::string const &)*arg3,arg4,arg5); + result = Dali::Application::New( arg1, arg2, arg3, arg4, arg5 ); } catch (std::out_of_range& e) { { SWIG_CSharpException(SWIG_IndexError, const_cast(e.what())); return 0; @@ -1460,18 +2331,98 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New__SWIG_4(int jarg1, cha { SWIG_CSharpException(SWIG_RuntimeError, const_cast(e.what())); return 0; }; + } catch (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; } catch (...) { { SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; }; } } + jresult = new Dali::Application((const Dali::Application &)result); return jresult; } +SWIGEXPORT void * SWIGSTDCALL CSharp_Dali_Application_New_WithWindowSizePosition(int jarg1, char * jarg2, char * jarg3, int jarg4, void * jarg5) { + void * jresult ; + int *arg1 = (int *) 0 ; + char ***arg2 ; + Dali::Application::WINDOW_MODE arg4 ; + Dali::PositionSize arg5 ; + Dali::PositionSize *argp5 ; + Dali::Application result; + { + int index = 0; + int length = 0; + char *retPtr = NULL; + char *nextPtr; + + gArgV = new char*[jarg1 + 1]; + + for(retPtr = strtok_r(jarg2, " ", &nextPtr); + retPtr != NULL && index < jarg1; + retPtr = strtok_r(NULL, " ", &nextPtr)) + { + length = 0; + length = strlen(retPtr); + gArgV[ index ] = new char[ length + 1 ]; + strncpy( gArgV[ index ], retPtr, length ); + gArgV[ index ][ length ] = '\0'; + index++; + } + + while( index < jarg1 ) + { + //if jarg1 - index >1, maybe cause error. + gArgV[index] = NULL; + index++; + } + + gArgV[jarg1] = NULL; + gArgC = jarg1; + + arg1 = &gArgC; + arg2 = &gArgV; + } + + std::string arg3(jarg3); + arg4 = (Dali::Application::WINDOW_MODE)jarg4; + argp5 = (Dali::PositionSize *)jarg5; + if (!argp5) { + SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null Dali::PositionSize", 0); + return 0; + } + arg5 = *argp5; + { + try { + result = Dali::Application::New( arg1, arg2, arg3, arg4, arg5 ); + } 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 (Dali::DaliException e) { + { + SWIG_CSharpException(SWIG_UnknownError, e.condition); return 0; + }; + } catch (...) { + { + SWIG_CSharpException(SWIG_UnknownError, "unknown error"); return 0; + }; + } + } + jresult = new Dali::Application((const Dali::Application &)result); + return jresult; +} + #ifdef __cplusplus }