mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-05 03:20:08 +01:00
Move the setting of the emulation level to before the WebView is created. Add note about resetting it to default.
This commit is contained in:
@@ -17,8 +17,14 @@ class TestPanel(wx.Panel):
|
||||
|
||||
sizer = wx.BoxSizer(wx.VERTICAL)
|
||||
btnSizer = wx.BoxSizer(wx.HORIZONTAL)
|
||||
|
||||
webview.WebView.MSWSetEmulationLevel(webview.WEBVIEWIE_EMU_IE11)
|
||||
self.wv = webview.WebView.New(self)
|
||||
webview.WebView.MSWSetEmulationLevel(level=webview.WEBVIEWIE_EMU_IE11)
|
||||
|
||||
# The emulation level is a persistent per-user per-application value. If
|
||||
# you would like to reset it back to the default (no-emulation) then
|
||||
# it can be done by calling this:
|
||||
webview.WebView.MSWSetEmulationLevel(webview.WEBVIEWIE_EMU_DEFAULT)
|
||||
|
||||
self.Bind(webview.EVT_WEBVIEW_NAVIGATING, self.OnWebViewNavigating, self.wv)
|
||||
self.Bind(webview.EVT_WEBVIEW_LOADED, self.OnWebViewLoaded, self.wv)
|
||||
|
||||
Reference in New Issue
Block a user