当前位置: 首页>>代码示例>>C#>>正文


C# WebView.Focus方法代码示例

本文整理汇总了C#中WebView.Focus方法的典型用法代码示例。如果您正苦于以下问题:C# WebView.Focus方法的具体用法?C# WebView.Focus怎么用?C# WebView.Focus使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在WebView的用法示例。


在下文中一共展示了WebView.Focus方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Browser

		public Browser(Guid id, string url, int width, int height)
		{
			Id = id;
			_width = width;
			_height = height;
			webView = WebCore.CreateWebView(width, height);
			webView.ResizeComplete += webView_ResizeComplete;
			webView.IsDirtyChanged += webView_IsDirtyChanged;
			//webView.SelectLocalFiles += webView_SelectLocalFiles;
			webView.CursorChanged += webView_CursorChanged;
			webView.LoadCompleted += new EventHandler(webView_LoadCompleted);
			webView.LoadURL(url);
			webView.Focus();
		}
开发者ID:Azerothian,项目名称:Illisian.Niva,代码行数:14,代码来源:Browser.cs

示例2: UIView

        public UIView(ICore core, UIType menuType, int width, int height, UIFlags flags, bool transparent)
            : base(core)
        {
            webCore = core.GetService<IUIManagerService>().GetWebCore();
            this.menuType = menuType;
            this.width = width;
            this.height = height;
            this.flags = flags;
            this.isTransparent = transparent;
            isLoading = false;
            pageLoaded = false;
            webTextureID = TextureFactory.CreateTexture(width, height, isTransparent);
            hudPosX = 0;
            hudPosY = 0;
            hud = new TVScreen2DImmediate();
            Keyboard = core.GetService<IKeyboardService>();
            Mouse = core.GetService<IMouseService>();
            JoyStick = core.GetService<IJoyStickService>();
            Gamepad = core.GetService<IGamepadsService>();

            CanculateHudPosition(flags);

            View = webCore.CreateWebView(width, height, isTransparent, true);
            View.OnFinishLoading += OnFinishLoading;
            View.OnCallback += OnCallback;
            View.Focus();

            buttonClickSound = Core.GetService<ISoundManagerService>().Load2DSound(Path.Combine(Application.StartupPath, @"Data\Sounds\menu\button_click.mp3"));
            buttonFocusSound = Core.GetService<ISoundManagerService>().Load2DSound(Path.Combine(Application.StartupPath, @"Data\Sounds\menu\button_focus.mp3"));
            Core.GetService<ISoundManagerService>().SetVolume(buttonClickSound, 0.5f);
            Core.GetService<ISoundManagerService>().SetVolume(buttonFocusSound, 0.5f);
        }
开发者ID:zulis,项目名称:Cubica,代码行数:32,代码来源:UIView.cs


注:本文中的WebView.Focus方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。