mirror of
https://github.com/cefsharp/CefSharp.git
synced 2026-12-04 19:25:01 +00:00
Update to 2272 nuget packages
Updated OnCertificateError and OnFileDialog as API changed - build now compiles
This commit is contained in:
@@ -250,7 +250,7 @@ namespace CefSharp
|
||||
return handler->OnBeforeBrowse(_browserControl, wrapper, isRedirect);
|
||||
}
|
||||
|
||||
bool ClientAdapter::OnCertificateError(cef_errorcode_t cert_error, const CefString& request_url, CefRefPtr<CefAllowCertificateErrorCallback> callback)
|
||||
bool ClientAdapter::OnCertificateError(CefRefPtr<CefBrowser> browser, cef_errorcode_t cert_error, const CefString& request_url, CefRefPtr<CefSSLInfo> ssl_info, CefRefPtr<CefAllowCertificateErrorCallback> callback)
|
||||
{
|
||||
IRequestHandler^ handler = _browserControl->RequestHandler;
|
||||
if (handler == nullptr)
|
||||
@@ -535,8 +535,8 @@ namespace CefSharp
|
||||
}
|
||||
|
||||
bool ClientAdapter::OnFileDialog(CefRefPtr<CefBrowser> browser, FileDialogMode mode, const CefString& title,
|
||||
const CefString& default_file_name, const std::vector<CefString>& accept_types,
|
||||
CefRefPtr<CefFileDialogCallback> callback)
|
||||
const CefString& default_file_path, const std::vector<CefString>& accept_filters, int selected_accept_filter,
|
||||
CefRefPtr<CefFileDialogCallback> callback)
|
||||
{
|
||||
IDialogHandler^ handler = _browserControl->DialogHandler;
|
||||
|
||||
@@ -545,14 +545,16 @@ namespace CefSharp
|
||||
return false;
|
||||
}
|
||||
|
||||
bool handled;
|
||||
List<System::String ^>^ filePaths = nullptr;
|
||||
|
||||
List<System::String ^>^ resultString = nullptr;
|
||||
if(handler->OnFileDialog(_browserControl, (CefFileDialogMode)mode, StringUtils::ToClr(title), StringUtils::ToClr(default_file_path), StringUtils::ToClr(accept_filters), selected_accept_filter, filePaths))
|
||||
{
|
||||
callback->Continue(selected_accept_filter, StringUtils::ToNative(filePaths));
|
||||
|
||||
handled = handler->OnFileDialog(_browserControl, (CefFileDialogMode)mode, StringUtils::ToClr(title), StringUtils::ToClr(default_file_name), StringUtils::ToClr(accept_types), resultString);
|
||||
callback->Continue(StringUtils::ToNative(resultString));
|
||||
return true;
|
||||
}
|
||||
|
||||
return handled;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool ClientAdapter::OnDragEnter(CefRefPtr<CefBrowser> browser, CefRefPtr<CefDragData> dragData, DragOperationsMask mask)
|
||||
|
||||
Reference in New Issue
Block a user