[dali_2.0.26] Merge branch 'devel/master' 94/258394/1
authorAdam Bialogonski <adam.b@samsung.com>
Fri, 14 May 2021 10:22:18 +0000 (11:22 +0100)
committerAdam Bialogonski <adam.b@samsung.com>
Fri, 14 May 2021 10:22:18 +0000 (11:22 +0100)
Change-Id: I5b853a635e6ff1c6b1da7301c29c262b051fae22

dali-csharp-binder/src/web-view.cpp
dali-csharp-binder/src/window.cpp
packaging/dali-csharp-binder.spec

index 062a36a..9b11e1a 100755 (executable)
@@ -454,7 +454,11 @@ SWIGEXPORT const void * SWIGSTDCALL CSharp_Dali_WebView_GetFavicon(void * jarg1)
   Dali::Toolkit::ImageView* result = 0;
   {
     try {
-      result = (Dali::Toolkit::ImageView*)&(arg1)->GetFavicon();
+      Dali::Toolkit::ImageView favicon = (arg1)->GetFavicon();
+      if (favicon)
+      {
+        result = new Dali::Toolkit::ImageView((const Dali::Toolkit::ImageView &)favicon);
+      }
     } CALL_CATCH_EXCEPTION(0);
   }
   return result;
@@ -872,22 +876,27 @@ SWIGEXPORT void SWIGSTDCALL CSharp_Dali_WebView_AddDynamicCertificatePath(void *
 SWIGEXPORT void *SWIGSTDCALL CSharp_Dali_WebView_GetScreenshot(void * jarg1, void * jarg2, float jarg3) {
   Dali::Toolkit::WebView *arg1 = (Dali::Toolkit::WebView *)jarg1;
   Dali::Rect<int32_t> *arg = (Dali::Rect<int32_t> *)jarg2;
-  Dali::Toolkit::ImageView result;
+  Dali::Toolkit::ImageView* result = 0;
   {
     try {
-      result = (arg1)->GetScreenshot(*arg, jarg3);
+      Dali::Toolkit::ImageView screenshot = (arg1)->GetScreenshot(*arg, jarg3);
+      if (screenshot)
+      {
+        result = new Dali::Toolkit::ImageView((const Dali::Toolkit::ImageView &)screenshot);
+      }
     } CALL_CATCH_EXCEPTION(0);
   }
-  void * jresult =
-      new Dali::Toolkit::ImageView((const Dali::Toolkit::ImageView &)result);
-  return jresult;
+  return result;
 }
 
 using SWIG_CallbackWebViewScreenshotCaptured = void(SWIGSTDCALL *)(Dali::Toolkit::ImageView *);
 SWIG_CallbackWebViewScreenshotCaptured swig_callbackOnWebViewScreenshotCaptured;
 
 void OnWebViewScreenshotCapturedCallback(Dali::Toolkit::ImageView imageView) {
-  Dali::Toolkit::ImageView *pImageView = &imageView;
+  if (!imageView)
+    return;
+
+  Dali::Toolkit::ImageView* pImageView = &imageView;
   swig_callbackOnWebViewScreenshotCaptured(pImageView);
 }
 
index 6d689cb..46db73e 100644 (file)
@@ -1463,7 +1463,7 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_SetNotificationLevel(void * jarg
   Dali::Window arg1 ;
   Dali::WindowNotificationLevel arg2 ;
   Dali::Window *argp1 ;
-  bool result;
+  int result;
 
   argp1 = (Dali::Window *)jarg1;
   if (!argp1) {
@@ -1474,7 +1474,7 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_SetNotificationLevel(void * jarg
   arg2 = (Dali::WindowNotificationLevel)jarg2;
   {
     try {
-      result = (bool)arg1.SetNotificationLevel(arg2);
+      result = (int)arg1.SetNotificationLevel(arg2);
     } catch (std::out_of_range& e) {
       {
         SWIG_CSharpException(SWIG_IndexError, const_cast<char*>(e.what())); return 0;
@@ -1619,7 +1619,7 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_SetScreenOffMode(void * jarg1, i
   Dali::Window arg1 ;
   Dali::WindowScreenOffMode arg2 ;
   Dali::Window *argp1 ;
-  bool result;
+  int result;
 
   argp1 = (Dali::Window *)jarg1;
   if (!argp1) {
@@ -1630,7 +1630,7 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_SetScreenOffMode(void * jarg1, i
   arg2 = (Dali::WindowScreenOffMode)jarg2;
   {
     try {
-      result = (bool)arg1.SetScreenOffMode(arg2);
+      result = (int)arg1.SetScreenOffMode(arg2);
     } catch (std::out_of_range& e) {
       {
         SWIG_CSharpException(SWIG_IndexError, const_cast<char*>(e.what())); return 0;
@@ -1699,7 +1699,7 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_SetBrightness(void * jarg1, int
   Dali::Window arg1 ;
   int arg2 ;
   Dali::Window *argp1 ;
-  bool result;
+  int result;
 
   argp1 = (Dali::Window *)jarg1;
   if (!argp1) {
@@ -1710,7 +1710,7 @@ SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Dali_SetBrightness(void * jarg1, int
   arg2 = (int)jarg2;
   {
     try {
-      result = (bool)arg1.SetBrightness(arg2);
+      result = (int)arg1.SetBrightness(arg2);
     } catch (std::out_of_range& e) {
       {
         SWIG_CSharpException(SWIG_IndexError, const_cast<char*>(e.what())); return 0;
index 3706b66..cdec803 100644 (file)
@@ -21,7 +21,7 @@
 
 Name: dali2-csharp-binder
 Summary: The DALI Csharp Binder
-Version: 2.0.25
+Version: 2.0.26
 Release: 1
 Group: uifw/graphic
 License: Apache-2.0 and BSD-3-Clause and MIT