mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Mac: Add off-screen rendering support (issue #518).
- Build with the 10.7 SDK (set GYP_DEFINES='mac_sdk=10.7') to include Retina support in the cefclient OSR example. git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1226 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@@ -290,6 +290,16 @@ void CefBrowserHostCToCpp::WasHidden(bool hidden) {
|
||||
hidden);
|
||||
}
|
||||
|
||||
void CefBrowserHostCToCpp::NotifyScreenInfoChanged() {
|
||||
if (CEF_MEMBER_MISSING(struct_, notify_screen_info_changed))
|
||||
return;
|
||||
|
||||
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
||||
|
||||
// Execute
|
||||
struct_->notify_screen_info_changed(struct_);
|
||||
}
|
||||
|
||||
void CefBrowserHostCToCpp::Invalidate(const CefRect& dirtyRect,
|
||||
PaintElementType type) {
|
||||
if (CEF_MEMBER_MISSING(struct_, invalidate))
|
||||
|
@@ -57,6 +57,7 @@ class CefBrowserHostCToCpp
|
||||
virtual bool IsWindowRenderingDisabled() OVERRIDE;
|
||||
virtual void WasResized() OVERRIDE;
|
||||
virtual void WasHidden(bool hidden) OVERRIDE;
|
||||
virtual void NotifyScreenInfoChanged() OVERRIDE;
|
||||
virtual void Invalidate(const CefRect& dirtyRect,
|
||||
PaintElementType type) OVERRIDE;
|
||||
virtual void SendKeyEvent(const CefKeyEvent& event) OVERRIDE;
|
||||
|
@@ -82,6 +82,27 @@ bool CefRenderHandlerCToCpp::GetScreenPoint(CefRefPtr<CefBrowser> browser,
|
||||
return _retval?true:false;
|
||||
}
|
||||
|
||||
bool CefRenderHandlerCToCpp::GetScreenInfo(CefRefPtr<CefBrowser> browser,
|
||||
CefScreenInfo& screen_info) {
|
||||
if (CEF_MEMBER_MISSING(struct_, get_screen_info))
|
||||
return false;
|
||||
|
||||
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
||||
|
||||
// Verify param: browser; type: refptr_diff
|
||||
DCHECK(browser.get());
|
||||
if (!browser.get())
|
||||
return false;
|
||||
|
||||
// Execute
|
||||
int _retval = struct_->get_screen_info(struct_,
|
||||
CefBrowserCppToC::Wrap(browser),
|
||||
&screen_info);
|
||||
|
||||
// Return type: bool
|
||||
return _retval?true:false;
|
||||
}
|
||||
|
||||
void CefRenderHandlerCToCpp::OnPopupShow(CefRefPtr<CefBrowser> browser,
|
||||
bool show) {
|
||||
if (CEF_MEMBER_MISSING(struct_, on_popup_show))
|
||||
|
@@ -40,6 +40,8 @@ class CefRenderHandlerCToCpp
|
||||
CefRect& rect) OVERRIDE;
|
||||
virtual bool GetScreenPoint(CefRefPtr<CefBrowser> browser, int viewX,
|
||||
int viewY, int& screenX, int& screenY) OVERRIDE;
|
||||
virtual bool GetScreenInfo(CefRefPtr<CefBrowser> browser,
|
||||
CefScreenInfo& screen_info) OVERRIDE;
|
||||
virtual void OnPopupShow(CefRefPtr<CefBrowser> browser, bool show) OVERRIDE;
|
||||
virtual void OnPopupSize(CefRefPtr<CefBrowser> browser,
|
||||
const CefRect& rect) OVERRIDE;
|
||||
|
Reference in New Issue
Block a user