Chrom browser to access the effect:
public void InitBrowser ()
{
Var setting=new CefSettings
{
The Locale="useful - CN",
//CachePath="CHBrowser/BrowserCache",
AcceptLanguageList="useful - CN, useful;
q=0.8,LocalesDirPath="CHBrowser/localeDir",
LogFile="CHBrowser/LogData",
PersistSessionCookies=true,
UserAgent="Mozilla/5.0 (Windows NT 6.1; Win64; X64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36 ",
UserDataPath="CHBrowser/userData"
};
Setting. CefCommandLineArgs. Add (" disable - gpu ", "1");
CefSharpSettings. LegacyJavascriptBindingEnabled=true;
///initializes the
Cef. The Initialize (setting);
The WebBrowser=new ChromiumWebBrowser (" XXXXXX ");
WebBrowser. RegisterJsObject (" PortSIP PortSIP, new BindingOptions () {} CamelCaseJavascriptNames=false).
The WebBrowser. The Dock=DockStyle. The Fill;
The WebBrowser. The Dock=DockStyle. The Fill;
This. Controls. The Add (WebBrowser);
The WebBrowser. MenuHandler=new MenuHandler ();
Setting. CefCommandLineArgs. Add (" no - proxy server ", "1");
The WebBrowser. FrameLoadEnd +=Web_FrameLoadEnd;
The WebBrowser. DragHandler=new DragHandler ();
}