Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable building with CEF 6834 (Chromium 132) and 6943 (133) #473

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions browser-app.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,11 @@ CefRefPtr<CefV8Value> CefValueToCefV8Value(CefRefPtr<CefValue> value)
result->SetValue((int)i, CefValueToCefV8Value(list->GetValue(i)));
}
} break;
#if !defined(_WIN32) && CHROME_VERSION_BUILD >= 6943
case VTYPE_NUM_VALUES:
result = CefV8Value::CreateNull();
break;
#endif
}
return result;
}
Expand Down
10 changes: 7 additions & 3 deletions browser-client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,13 @@ CefResourceRequestHandler::ReturnValue BrowserClient::OnBeforeResourceLoad(CefRe
}
#endif

bool BrowserClient::OnBeforePopup(CefRefPtr<CefBrowser>, CefRefPtr<CefFrame>, const CefString &, const CefString &,
cef_window_open_disposition_t, bool, const CefPopupFeatures &, CefWindowInfo &,
CefRefPtr<CefClient> &, CefBrowserSettings &, CefRefPtr<CefDictionaryValue> &, bool *)
bool BrowserClient::OnBeforePopup(CefRefPtr<CefBrowser>, CefRefPtr<CefFrame>,
#if CHROME_VERSION_BUILD >= 6834
int,
#endif
const CefString &, const CefString &, cef_window_open_disposition_t, bool,
const CefPopupFeatures &, CefWindowInfo &, CefRefPtr<CefClient> &,
CefBrowserSettings &, CefRefPtr<CefDictionaryValue> &, bool *)
{
/* block popups */
return true;
Expand Down
3 changes: 3 additions & 0 deletions browser-client.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,9 @@ class BrowserClient : public CefClient,

/* CefLifeSpanHandler */
virtual bool OnBeforePopup(CefRefPtr<CefBrowser> browser, CefRefPtr<CefFrame> frame,
#if CHROME_VERSION_BUILD >= 6834
int popup_id,
#endif
const CefString &target_url, const CefString &target_frame_name,
cef_window_open_disposition_t target_disposition, bool user_gesture,
const CefPopupFeatures &popupFeatures, CefWindowInfo &windowInfo,
Expand Down
3 changes: 3 additions & 0 deletions cef-headers.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@
#include <include/cef_parser.h>
#include <include/cef_scheme.h>
#include <include/cef_version.h>
#if CHROME_VERSION_BUILD >= 6943
#include <include/cef_version_info.h>
#endif
#include <include/cef_render_process_handler.h>
#include <include/cef_request_context_handler.h>
#include <include/cef_jsdialog_handler.h>
Expand Down
12 changes: 8 additions & 4 deletions panel/browser-panel-client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,14 @@ void QCefBrowserClient::OnLoadError(CefRefPtr<CefBrowser> browser, CefRefPtr<Cef
}

/* CefLifeSpanHandler */
bool QCefBrowserClient::OnBeforePopup(CefRefPtr<CefBrowser>, CefRefPtr<CefFrame>, const CefString &target_url,
const CefString &, CefLifeSpanHandler::WindowOpenDisposition, bool,
const CefPopupFeatures &, CefWindowInfo &windowInfo, CefRefPtr<CefClient> &,
CefBrowserSettings &, CefRefPtr<CefDictionaryValue> &, bool *)
bool QCefBrowserClient::OnBeforePopup(CefRefPtr<CefBrowser>, CefRefPtr<CefFrame>,
#if CHROME_VERSION_BUILD >= 6834
int,
#endif
const CefString &target_url, const CefString &,
CefLifeSpanHandler::WindowOpenDisposition, bool, const CefPopupFeatures &,
CefWindowInfo &windowInfo, CefRefPtr<CefClient> &, CefBrowserSettings &,
CefRefPtr<CefDictionaryValue> &, bool *)
{
if (allowAllPopups) {
#ifdef _WIN32
Expand Down
3 changes: 3 additions & 0 deletions panel/browser-panel-client.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ class QCefBrowserClient : public CefClient,

/* CefLifeSpanHandler */
virtual bool OnBeforePopup(CefRefPtr<CefBrowser> browser, CefRefPtr<CefFrame> frame,
#if CHROME_VERSION_BUILD >= 6834
int popup_id,
#endif
const CefString &target_url, const CefString &target_frame_name,
CefLifeSpanHandler::WindowOpenDisposition target_disposition, bool user_gesture,
const CefPopupFeatures &popupFeatures, CefWindowInfo &windowInfo,
Expand Down