protected virtual void InitWebView(Rect m_WebViewRect) { if (!(bool)this.webView) { var field = GetType().GetField("m_Parent", BindingFlags.NonPublic | BindingFlags.Instance); this.m_Parent = MyHostView.Create(field.GetValue(this)); int x = (int)m_WebViewRect.x; int y = (int)m_WebViewRect.y; int width = (int)m_WebViewRect.width; int height = (int)m_WebViewRect.height; this.webView = MyWebView.Create(); this.webView.InitWebView((GUIView)this.m_Parent.host, x, y, width, height, true); //false); this.webView.hideFlags = HideFlags.HideAndDontSave; this.SetFocus(this.m_hasFocus); } this.webView.SetDelegateObject((ScriptableObject)this); this.LoadUri(); this.SetFocus(true); }