Exemplo n.º 1
0
        static void Main()
        {
            oPATH.Init();

            Settings settings = new Settings()
            {
            };

            if (CEF.Initialize(settings) == false)
            {
                return;
            }

            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            var m = new fOther();
            var f = new fMain(m);

            CEF.RegisterScheme("local", new SchemeHandlerFactory());
            CEF.RegisterScheme("img", new ImageHandlerFactory(f));
            CEF.RegisterJsObject("api", f);
            Application.Run(f);
            //Application.Run(new fEditor("ability"));
            m.Close();
            CEF.Shutdown();
        }
Exemplo n.º 2
0
        public static void Init()
        {
            Settings settings = new Settings();

            if (CEF.Initialize(settings))
            {
                CEF.RegisterScheme("test", new SchemeHandlerFactory());
                CEF.RegisterJsObject("bound", new BoundObject());
            }
        }
Exemplo n.º 3
0
        public static void Init(IEventAggregator eventAggregator)
        {
            CefSharp.Settings settings = new CefSharp.Settings();

            if (CEF.Initialize(settings))
            {
                CEF.RegisterScheme("theme", new ThemeSchemeHandlerFactory());
                //CEF.RegisterScheme("test", new SchemeHandlerFactory());
                //CEF.RegisterJsObject("bound", new BoundObject());
                CEF.RegisterScheme("md", new MarkdownHandlerFactory(eventAggregator, () => DocDirectory));
                //CEF.RegisterJsObject("MDLink", new MDLink());
            }
        }
Exemplo n.º 4
0
        public static void Run()
        {
            Settings settings = new Settings();

            if (CEF.Initialize(settings))
            {
                CEF.RegisterScheme("play", new SchemeHandlerFactory());
                CEF.RegisterJsObject("bound", new BoundObject());

                player = new fPlayer();

                Application.Run(player);
            }
        }
Exemplo n.º 5
0
        static void Main(string[] args)
        {
            Settings        settings        = new Settings();
            BrowserSettings browserSettings = new BrowserSettings();

            if (!CEF.Initialize(settings, browserSettings))
            {
                Console.WriteLine("Couldn't initialise CEF");
                return;
            }

            CEF.RegisterScheme("test", new TestSchemeHandlerFactory());
            CEF.RegisterJsObject("bound", new BoundObject());

            Browser browser = new Browser();

            Application.Run(browser);
        }