From: huayong.xu Date: Wed, 19 Jan 2022 10:30:35 +0000 (+0800) Subject: Set http response body in binary format. X-Git-Tag: dali_2.1.9~2^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c075e3167eb11dd0e9fc173c9d1d556e9218c55e;p=platform%2Fcore%2Fuifw%2Fdali-csharp-binder.git Set http response body in binary format. Change-Id: I9265054da0e9e2437c097d4214534c7354a49331 --- diff --git a/dali-csharp-binder/src/web-view-wrap.cpp b/dali-csharp-binder/src/web-view-wrap.cpp index 7c90f55..b72ff7b 100755 --- a/dali-csharp-binder/src/web-view-wrap.cpp +++ b/dali-csharp-binder/src/web-view-wrap.cpp @@ -2526,42 +2526,35 @@ SWIGEXPORT bool SWIGSTDCALL CSharp_Dali_WebRequestInterceptor_AddResponseHeaders return ret; } -SWIGEXPORT bool SWIGSTDCALL CSharp_Dali_WebRequestInterceptor_AddResponseBody(void * jarg1, const char *jarg2, uint32_t jarg3) { +SWIGEXPORT bool SWIGSTDCALL CSharp_Dali_WebRequestInterceptor_AddResponseBody(void * jarg1, const int8_t * jarg2, uint32_t jarg3) { Dali::WebEngineRequestInterceptor* arg1 = (Dali::WebEngineRequestInterceptor*)jarg1; bool ret = false; - std::string arg2_str(jarg2); { try { - ret = (arg1)->AddResponseBody(arg2_str, jarg3); + ret = (arg1)->AddResponseBody(jarg2, jarg3); } CALL_CATCH_EXCEPTION(0); } return ret; } -SWIGEXPORT bool SWIGSTDCALL CSharp_Dali_WebRequestInterceptor_AddResponse(void * jarg1, const char * jarg2, const char * jarg3, uint32_t jarg4) { +SWIGEXPORT bool SWIGSTDCALL CSharp_Dali_WebRequestInterceptor_AddResponse(void * jarg1, const char * jarg2, const int8_t * jarg3, uint32_t jarg4) { Dali::WebEngineRequestInterceptor* arg1 = (Dali::WebEngineRequestInterceptor*)jarg1; bool ret = false; std::string arg2_str(jarg2); - std::string arg3_str(jarg3); { try { - ret = (arg1)->AddResponse(arg2_str, arg3_str, jarg4); + ret = (arg1)->AddResponse(arg2_str, jarg3, jarg4); } CALL_CATCH_EXCEPTION(0); } return ret; } -SWIGEXPORT bool SWIGSTDCALL CSharp_Dali_WebRequestInterceptor_WriteResponseChunk(void * jarg1, const char * jarg2, uint32_t jarg3) { +SWIGEXPORT bool SWIGSTDCALL CSharp_Dali_WebRequestInterceptor_WriteResponseChunk(void * jarg1, const int8_t * jarg2, uint32_t jarg3) { Dali::WebEngineRequestInterceptor* arg1 = (Dali::WebEngineRequestInterceptor*)jarg1; bool ret = false; - std::string arg2_str; - if (jarg2) - { - arg2_str = std::string(jarg2); - } { try { - ret = (arg1)->WriteResponseChunk(arg2_str, jarg3); + ret = (arg1)->WriteResponseChunk(jarg2, jarg3); } CALL_CATCH_EXCEPTION(0); } return ret;