Beispiel #1
0
        public static bool Setup()
        {
            Console.WriteLine("Sciter " + SciterX.Version);

            #region Ion
            if (IonApp.GetStatus() != EIonStatus.ACTIVE || IonApp.IsTrial)
            {
                DlgLicense.ShowDialog();
            }
            if (IonApp.GetStatus() != EIonStatus.ACTIVE)
            {
                return(false);
            }
            UpdateControl.Setup();
            #endregion

            // Create the window
            AppWindow   = new Window();
            AppDebugger = new DebuggerHost();
            AppHost     = new Host(AppWindow);

            State.Setup();

            // Args passing
            var sv = new SciterValue();
            sv["t"] = new SciterValue(App.g_arg_t);
            sv["r"] = new SciterValue(App.g_arg_r);
            AppHost.CallFunction("View_Setup", sv);

            if (!string.IsNullOrEmpty(g_arg_page))
            {
                //MessageBox.ShowMessageBox(AppWindow, g_arg_page);
                State.LoadURL(g_arg_page);
            }

            AppWindow.CenterTopLevelWindow();
            AppWindow.Show();

#if DEBUG
            //AppHost.InvokePost(() => Tests.Run());
#endif
            return(true);
        }
Beispiel #2
0
 public SciterValue Host_IonExpando() => IonApp.GetUIExpando();