chromium-embedded

how to load a js file and execute it on CEF

心已入冬 提交于 2021-02-19 08:45:35
问题 I use CEF(chromium ebedded Framework) load a html page: <!DOCTYPE html> <html> <head> </head> <body> <script src="phantom-limb.js" type="text/javascript"></script> </body> </html> and it works ok. now, I modify the page as follow: <!DOCTYPE html> <html> <head> </head> <body> </body> </html> and after cef loaded it, I use cef's ExecuteJavaScript method to execute the same phantom-limb.js, but nothing appear. how can I load the js file and execute, or, the js file has some limit? thx:) 回答1: As

Enable AAC support in Chromium Embedded Framework (C#)

蹲街弑〆低调 提交于 2021-02-11 12:42:55
问题 I've successfully registered widevine in my audio player, so I can log in to Spotify Web Player, but I can't play any audio track becuase the appropriate codec is still missing. As I know the web player is using AAC format so somehow I should add AAC support to CEF. Have you guys got any idea how should I do this? 回答1: You need a custom build of CEF with proprietary codecs enabled (use proprietary_codecs=true ffmpeg_branding=Chrome build flags). You can find instructions for building CEF with

DCEF3: How to get a screenshot

不想你离开。 提交于 2021-01-29 04:04:13
问题 How to get screenshot of browser in DCEF3? I create browser like this without VCL. The TakePicture method will only work if No debugger is used If ShowWindow is used var info: TCefWindowInfo; Settings: TCefBrowserSettings; begin FillChar(info, SizeOf(info), 0); info.width := width; info.height := height; FillChar(Settings, SizeOf(TCefBrowserSettings), 0); Settings.Size := SizeOf(TCefBrowserSettings); GetSettings(Settings); CefBrowserHostCreateBrowser(@info, FHandler, FDefaultUrl, @settings,

Compile Error(C2440)Using CEFbrowser & VS2015

纵然是瞬间 提交于 2020-08-10 19:18:18
问题 there. I'm new to CEFbrowser. I'm developing the download model of My CefBrowser. I've written some code but error while compiling. class CefClient : public virtual CefBase { public: /// // Return the handler for download events. If no handler is returned downloads // will not be allowed. /// /*--cef()--*/ virtual CefRefPtr<CefDownloadHandler> GetDownloadHandler(){ return this; } But VS2015 says C2440: "return":cannot convert from 'CefClient *const' to 'CefRefPtr<CefDownloadHandler>' I'm new.

CEF C++ Implementing download handler

我怕爱的太早我们不能终老 提交于 2020-07-23 08:18:05
问题 I am trying to implement the CefDownloadHandler to allow file downloads in my application. When I click a link, the javascript code will redirect the user to a the download link of an excel file. But when I run my application via the CEF, the download does not happen. I have implemented the CefDownloadHandler but that function never seems to call. Following is the code I have so far class SimpleHandler : public CefClient, public CefDisplayHandler, public CefLifeSpanHandler, public

CEF C++ Implementing download handler

自作多情 提交于 2020-07-23 08:16:22
问题 I am trying to implement the CefDownloadHandler to allow file downloads in my application. When I click a link, the javascript code will redirect the user to a the download link of an excel file. But when I run my application via the CEF, the download does not happen. I have implemented the CefDownloadHandler but that function never seems to call. Following is the code I have so far class SimpleHandler : public CefClient, public CefDisplayHandler, public CefLifeSpanHandler, public