Exemplo n.º 1
0
        static void Main()
        {
            AppDomain.CurrentDomain.Patch(harmony => {
                harmony.Patch(typeof(ApplicationModelManager).Method("CollectModelStores", Flags.StaticAnyVisibility), postfix: new HarmonyMethod(typeof(Program), nameof(CollectModelStores)));
            });
            DevExpress.ExpressApp.Win.EasyTest.EasyTestRemotingRegistration.Register();

            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
#if !NETCOREAPP3_1
            DevExpress.ExpressApp.Security.EditModelPermission.AlwaysGranted = System.Diagnostics.Debugger.IsAttached;
#endif
            if (Tracing.GetFileLocationFromSettings() == FileLocation.CurrentUserApplicationDataFolder)
            {
                Tracing.LocalUserAppDataPath = Application.LocalUserAppDataPath;
            }
            Tracing.Initialize();
            var winApplication = new TestWinApplication();

            winApplication.ConfigureConnectionString();

            try{
                winApplication.Setup();
                if (!AppDomain.CurrentDomain.UseNetFramework())
                {
                    ((IModelApplicationOptionsSkin)winApplication.Model.Options).Skin = "The Bezier";
                }
                winApplication.Start();
            }
            catch (Exception e) {
                winApplication.HandleException(e);
            }
        }
Exemplo n.º 2
0
        static void Main()
        {
            WindowsFormsSettings.LoadApplicationSettings();
            AppDomain.CurrentDomain.AssemblyResolve    += CurrentDomain_AssemblyResolve;
            Application.ThreadException                += Application_ThreadException;
            AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException;
            Application.EnableVisualStyles();
            Settings.IncreaseNumberOfLaunches();
            if (!string.IsNullOrEmpty(Settings.ApplicationSkinName))
            {
                UserLookAndFeel.Default.SkinName = Settings.ApplicationSkinName;
            }
            UserLookAndFeel.Default.StyleChanged += (s, e) =>
            {
                Settings.ApplicationSkinName = ((UserLookAndFeel)s).ActiveSkinName;
            };

            Loader = new EmbeddedAssembly();
            Loader.Load();
            Application.ApplicationExit += (s, e) =>
            {
                Settings.UpdateRunningTime();
                Settings.Save();
                BookmarkPersistManager.Instance.SaveFile();
            };
            LoadStartupExtensions();
            Application.Run(new MainForm());
        }
Exemplo n.º 3
0
        static void Main()
        {
            CultureInfo.DefaultThreadCurrentCulture   = CultureInfo.InvariantCulture;
            CultureInfo.DefaultThreadCurrentUICulture = CultureInfo.InvariantCulture;

            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(true);

            Application.ThreadException += ExceptionHandler.OnThreadException;
            AppDomain.CurrentDomain.UnhandledException += ExceptionHandler.CurrentDomain_UnhandledException;

            StartProfiling();

            WindowsFormsSettings.SetDPIAware();
            DpiAwarenessHelper.Default.SetDpiAware(DpiAwarenessKind.PerMonitorV2);

            /*
             * //Do not force DirectX on Windows 7
             * if (Environment.OSVersion.Version.Major >= 10)
             *  WindowsFormsSettings.ForceDirectXPaint();
             * else
             *  WindowsFormsSettings.ForceGDIPlusPaint();
             */

            Startup.Initialize();
            SetupDefaultValues();

            BonusSkins.Register();
            SkinManager.Default.RegisterAssembly(typeof(DevExpress.UserSkins.WinterJoy).Assembly);
            SkinManager.EnableFormSkins();

            MainView            = new MainView();
            Parameters.MainForm = MainView;
            Application.Run(MainView);
        }
Exemplo n.º 4
0
 static void Main()
 {
     Directory.SetCurrentDirectory(AppDomain.CurrentDomain.BaseDirectory);
     WindowsFormsSettings.LoadApplicationSettings();
     Application.ThreadException += Application_ThreadException;
     AppDomain.CurrentDomain.UnhandledException   += CurrentDomain_UnhandledException;
     AppDomain.CurrentDomain.FirstChanceException += CurrentDomain_FirstChanceException;
     Application.EnableVisualStyles();
     Settings.IncreaseNumberOfLaunches();
     if (!string.IsNullOrEmpty(Settings.ApplicationSkinName))
     {
         UserLookAndFeel.Default.SkinName = Settings.ApplicationSkinName;
     }
     UserLookAndFeel.Default.StyleChanged += (s, e) =>
     {
         Settings.ApplicationSkinName = ((UserLookAndFeel)s).ActiveSkinName;
     };
     if (UserSettingsManager.UserSettings.SingleInstance && Process.GetProcessesByName(Process.GetCurrentProcess().ProcessName).Length > 1)
     {
         if (Environment.GetCommandLineArgs().Length == 2)
         {
             var otherAnalogy = GetAlreadyRunningInstance();
             if (otherAnalogy != null)
             {
                 SendDataMessage(otherAnalogy, Environment.GetCommandLineArgs()[1]);
             }
         }
         else
         {
             XtraMessageBox.Show("Single instance is on. Exiting this instance", "Analogy");
         }
         return;
     }
     Application.Run(new MainForm());
 }
 static void Main()
 {
     WindowsFormsSettings.ForceDirectXPaint();
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     Application.Run(new Form1());
 }
Exemplo n.º 6
0
        static void Main(string[] args)
        {
            WindowsFormsSettings.SetDPIAware();
            // AFFINITY
            var currentProcess = Process.GetCurrentProcess();

            currentProcess.ProcessorAffinity = new System.IntPtr(1);
            //
            WindowsFormsSettings.EnableFormSkins();
            WindowsFormsSettings.DefaultLookAndFeel.SetSkinStyle("Office 2016 Colorful");
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            // check arguments
            if (args == null || args.Length == 0 || args.Length == 1 && string.IsNullOrWhiteSpace(args[0]))
            {
                Application.Run(new MainForm());
            }
            else
            {
                string workload = string.Empty;
                if (args.Length == 1 && System.IO.File.Exists(args[0].Trim()))
                {
                    workload = args[0].Trim();
                    args     = System.IO.File.ReadAllLines(workload);
                }
                args = args.Where(a => !string.IsNullOrWhiteSpace(a))
                       .Select(s => s.Trim().ToLowerInvariant()).ToArray();
                Application.Run(new RunnerForm(args, workload));
            }
        }
Exemplo n.º 7
0
        static void Main()
        {
            DevExpress.ExpressApp.Win.EasyTest.EasyTestRemotingRegistration.Register();

            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            EditModelPermission.AlwaysGranted = System.Diagnostics.Debugger.IsAttached;
            if (Tracing.GetFileLocationFromSettings() == FileLocation.CurrentUserApplicationDataFolder)
            {
                Tracing.LocalUserAppDataPath = Application.LocalUserAppDataPath;
            }
            Tracing.Initialize();
            var winApplication = new TestWinApplication();

            winApplication.Modules.Add(new WinModule());

            winApplication.RegisterInMemoryObjectSpaceProvider();
            winApplication.AlwaysUpdateOnDatabaseVersionMismatch().Subscribe();
            try {
                winApplication.Setup();
                winApplication.Start();
            }
            catch (Exception e) {
                winApplication.HandleException(e);
            }
        }
Exemplo n.º 8
0
        static void Main(string[] arguments)
        {
            WindowsFormsSettings.ApplyDemoSettings();

            /*prueba para establecimiento*/
            //FormEstablecimiento formEstablecimiento = new FormEstablecimiento(1);
            //Application.Run(formEstablecimiento);
            //ReportView form = new ReportView();
            //Application.Run(form);
            //COMPROBANTE comp = new FacturaServicio().getComprobante(4);
            //GeneradorFactura generador = new GeneradorFactura(comp);
            //generador.GenerarXML();
            //Correo c = new Correo();
            //c.enviarCorreo("*****@*****.**");
            /*pruena para aplicación general*/
            Application.Run(new LoginForm());
            DevExpress.Utils.LocalizationHelper.SetCurrentCulture(arguments);
            CultureInfo nastiCulture = (CultureInfo)Application.CurrentCulture.Clone();

            nastiCulture.NumberFormat.CurrencySymbol        = "$";
            nastiCulture.NumberFormat.CurrencyDecimalDigits = 2;
            if (CredencialUsuario.getInstancia().getUsuario() != null)
            {
                Application.Run(FormaBase.getInstancia());
            }
            //ServicioImpresion servicio = new ServicioImpresion();
            //COMPROBANTE comprobante = new FacturaServicio().getComprobante(5);
            //servicio.exportarPdf(comprobante.CODIGOTIPOCOMPROBANTE, comprobante);
        }
Exemplo n.º 9
0
        static void Main()
        {
            DevExpress.Data.CurrencyDataController.DisableThreadingProblemsDetection = true;
            //SettingsStore.ApplicationDirectory = Path.GetDirectoryName(Application.ExecutablePath);
            WindowsFormsSettings.DefaultFont  = new System.Drawing.Font("Segoe UI", 9);
            WindowsFormsSettings.ScrollUIMode = ScrollUIMode.Desktop;
            UserLookAndFeel.Default.SetSkinStyle(SettingsStore.Default.SelectedThemeName);
            WindowsFormsSettings.FormThickBorder = true;
            if (UserLookAndFeel.Default.SkinName == "The Bezier")
            {
                if (string.IsNullOrEmpty(SettingsStore.Default.SelectedPaletteName))
                {
                    SettingsStore.Default.SelectedPaletteName = "VS Light";
                }
                var skin = CommonSkins.GetSkin(UserLookAndFeel.Default);
                DevExpress.Utils.Svg.SvgPalette pallete = skin.CustomSvgPalettes[SettingsStore.Default.SelectedPaletteName];
                skin.SvgPalettes[Skin.DefaultSkinPaletteName].SetCustomPalette(pallete);
                LookAndFeelHelper.ForceDefaultLookAndFeelChanged();
            }
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(true);

            WindowsFormsSettings.ForceDirectXPaint();

            ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;
            CheckShowApiKeysForm();

            //Settings
            Ticker.UseHtmlString = false;

            Application.Run(new MainForm());
        }
Exemplo n.º 10
0
        static void Main(string[] arguments)
        {
            WindowsFormsSettings.LoadApplicationSettings();
            DevExpress.ExpressApp.Utils.ImageLoader.Instance.UseSvgImages = true;
#if DEBUG
            DevExpress.ExpressApp.Win.EasyTest.EasyTestRemotingRegistration.Register();
#endif
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            EditModelPermission.AlwaysGranted = System.Diagnostics.Debugger.IsAttached;
            Tracing.LocalUserAppDataPath      = Application.LocalUserAppDataPath;
            Tracing.Initialize();

            SimpleProjectManagerWindowsFormsApplication winApplication = new SimpleProjectManagerWindowsFormsApplication();
            // Refer to the https://documentation.devexpress.com/eXpressAppFramework/CustomDocument112680.aspx help article for more details on how to provide a custom splash form.
            //winApplication.SplashScreen = new DevExpress.ExpressApp.Win.Utils.DXSplashScreen("YourSplashImage.png");
            if (System.Diagnostics.Debugger.IsAttached && winApplication.CheckCompatibilityType == CheckCompatibilityType.DatabaseSchema)
            {
                winApplication.DatabaseUpdateMode = DatabaseUpdateMode.UpdateDatabaseAlways;
            }
            try {
                winApplication.Setup();
                winApplication.Start();
            } catch (Exception e) {
                winApplication.HandleException(e);
            }
        }
Exemplo n.º 11
0
        void Run(string[] args)
        {
#if EASYTEST
            DevExpress.ExpressApp.Win.EasyTest.EasyTestRemotingRegistration.Register();
#endif
            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            EditModelPermission.AlwaysGranted = System.Diagnostics.Debugger.IsAttached;

            InitializeTracing();
            InitGlobalStatics();

            using (var winApplication = CreateApplication())
            {
                try
                {
                    winApplication.Setup();
                    winApplication.Start();
                }
                catch (Exception e)
                {
                    winApplication.HandleException(e);
                }
            }
        }
Exemplo n.º 12
0
        static void Main()
        {
            //DevExpress.Data.CurrencyDataController.DisableThreadingProblemsDetection = true;
            WindowsFormsSettings.DefaultFont  = new System.Drawing.Font("Segoe UI", 9);
            WindowsFormsSettings.ScrollUIMode = ScrollUIMode.Desktop;
            UserLookAndFeel.Default.SetSkinStyle(SettingsStore.Default.SelectedThemeName);
            WindowsFormsSettings.FormThickBorder = true;
            if (UserLookAndFeel.Default.SkinName == "The Bezier")
            {
                if (string.IsNullOrEmpty(SettingsStore.Default.SelectedPaletteName))
                {
                    SettingsStore.Default.SelectedPaletteName = "Gloom Gloom";
                }
                var skin = CommonSkins.GetSkin(UserLookAndFeel.Default);
                DevExpress.Utils.Svg.SvgPalette pallete = skin.CustomSvgPalettes[SettingsStore.Default.SelectedPaletteName];
                skin.SvgPalettes[Skin.DefaultSkinPaletteName].SetCustomPalette(pallete);
                LookAndFeelHelper.ForceDefaultLookAndFeelChanged();
            }
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(true);

            WindowsFormsSettings.ForceDirectXPaint();

            Application.Run(new MainForm());
        }
Exemplo n.º 13
0
        static void Main()
        {
            DevExpress.ExpressApp.Win.EasyTest.EasyTestRemotingRegistration.Register();

            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
#if !NETCOREAPP3_1
            EditModelPermission.AlwaysGranted = System.Diagnostics.Debugger.IsAttached;
#endif
            if (Tracing.GetFileLocationFromSettings() == FileLocation.CurrentUserApplicationDataFolder)
            {
                Tracing.LocalUserAppDataPath = Application.LocalUserAppDataPath;
            }
            Tracing.Initialize();
            var winApplication = new TestWinApplication();

            winApplication.ConfigureConnectionString();

            try{
                winApplication.Setup();
                if (!AppDomain.CurrentDomain.UseNetFramework())
                {
                    ((IModelApplicationOptionsSkin)winApplication.Model.Options).Skin = "The Bezier";
                }

                ((SecurityStrategyComplex)winApplication.Security).IsGranted(new AdministrativePermissionRequest());
                winApplication.Start();
            }
            catch (Exception e) {
                winApplication.HandleException(e);
            }
        }
Exemplo n.º 14
0
        static void Main()
        {
            WindowsFormsSettings.ForceDirectXPaint();

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

            BonusSkins.Register();
            SkinManager.EnableFormSkins();

            if (MasterDatabase.KeyFileExists && MasterDatabase.Connected)
            {
                Application.Run(new Controls.XtraForm1());
            }
            else
            {
                if (!MasterDatabase.KeyFileExists)
                {
                    XtraMessageBox.Show("Missing mandatory file 'Master.key'", "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                }
                else if (!MasterDatabase.Connected)
                {
                    string text = System.String.Format("Could not connect to '{0}' on '{1}'",
                                                       MasterDatabase.SqlConnection.Database,
                                                       MasterDatabase.SqlConnection.DataSource);

                    XtraMessageBox.Show(text, "Error", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                }
            }
        }
Exemplo n.º 15
0
        public static void Main(string[] args)
        {
            DevExpress.ExpressApp.FrameworkSettings.DefaultSettingsCompatibilityMode = DevExpress.ExpressApp.FrameworkSettingsCompatibilityMode.Latest;

            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            DevExpress.Utils.ToolTipController.DefaultController.ToolTipType = DevExpress.Utils.ToolTipType.SuperTip;
            if (Tracing.GetFileLocationFromSettings() == DevExpress.Persistent.Base.FileLocation.CurrentUserApplicationDataFolder)
            {
                Tracing.LocalUserAppDataPath = Application.LocalUserAppDataPath;
            }
            Tracing.Initialize();


            var winApplication = new MailClientWindowsFormsApplication();

#if DEBUG
            if (System.Diagnostics.Debugger.IsAttached && winApplication.CheckCompatibilityType == CheckCompatibilityType.DatabaseSchema)
            {
                winApplication.DatabaseUpdateMode = DatabaseUpdateMode.UpdateDatabaseAlways;
            }
#endif
            try
            {
                winApplication.Setup();
                winApplication.Start();
            }
            catch (Exception e)
            {
                winApplication.StopSplash();
                winApplication.HandleException(e);
            }
        }
Exemplo n.º 16
0
 private static void Main(string[] args)
 {
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     ApplicationStartup.Initialize();
     WindowsFormsSettings.SetDPIAware();
     Application.Run(IoC.Resolve <ITestPresenter>().View as Form);
 }
Exemplo n.º 17
0
        protected override void CalcDayCells()
        {
            DayCells.Clear();
            RowCount    = GetCellRowCount();
            ColumnCount = GetCellColumnCount();

            var rightToLeftLayout = WindowsFormsSettings.GetIsRightToLeftLayout(Calendar);
            var y = DayCellsBounds.Y;

            for (var iRow = 0; iRow < RowCount; ++iRow)
            {
                var x = rightToLeftLayout ? DayCellsBounds.Right - ActualCellSize.Width : DayCellsBounds.X;
                for (var iCol = 0; iCol < ColumnCount; ++iCol)
                {
                    bool correctDate;

                    if (iRow == 0)
                    {
                        if (iCol < PenaltyIndex)
                        {
                            x += rightToLeftLayout ? -ActualCellSize.Width : ActualCellSize.Width;
                            continue;
                        }
                    }

                    DateTime date;
                    try
                    {
                        date = CalcDate(iRow, iCol, out correctDate);
                    }
                    catch
                    {
                        iRow = RowCount;
                        break;
                    }

                    if (correctDate && CanAddDate(date))
                    {
                        var dayCell = (PersianCalendarCellViewInfo)CreateDayCell(date);
                        dayCell.UpdateVisualState();
                        dayCell.Bounds        = CalcCellBounds(x, y);
                        dayCell.Text          = GetCellText(date, iRow, iCol);
                        dayCell.ContentBounds = CalcDayCellContentBounds(dayCell.Bounds);
                        dayCell.CalculateTextBounds();
                        dayCell.Row    = iRow;
                        dayCell.Column = iCol;

                        UpdateDayCell(dayCell);
                        DayCells.Add(dayCell);
                        CalendarInfo.AddCellToNavigationGrid(dayCell, Row, Column, iRow, iCol);
                    }

                    x += rightToLeftLayout ? -ActualCellSize.Width : ActualCellSize.Width;
                }

                y += ActualCellSize.Height;
            }
        }
Exemplo n.º 18
0
        public static void Main()
        {
            var sw = new Stopwatch();

            sw.Start();
#if EASYTEST
            DevExpress.ExpressApp.Win.EasyTest.EasyTestRemotingRegistration.Register();
#endif
            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            EditModelPermission.AlwaysGranted = System.Diagnostics.Debugger.IsAttached;
            if (Tracing.GetFileLocationFromSettings() == DevExpress.Persistent.Base.FileLocation.CurrentUserApplicationDataFolder)
            {
                Tracing.LocalUserAppDataPath = Application.LocalUserAppDataPath;
            }
            Tracing.Initialize();
            PreCacheDemoWindowsFormsApplication winApplication = new PreCacheDemoWindowsFormsApplication();

            // Refer to the https://documentation.devexpress.com/eXpressAppFramework/CustomDocument112680.aspx help article for more details on how to provide a custom splash form.
            //winApplication.SplashScreen = new DevExpress.ExpressApp.Win.Utils.DXSplashScreen("YourSplashImage.png");
            if (ConfigurationManager.ConnectionStrings["ConnectionString"] != null)
            {
                winApplication.ConnectionString = ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString;
            }
#if EASYTEST
            if (ConfigurationManager.ConnectionStrings["EasyTestConnectionString"] != null)
            {
                winApplication.ConnectionString = ConfigurationManager.ConnectionStrings["EasyTestConnectionString"].ConnectionString;
            }
#endif
#if DEBUG
            if (System.Diagnostics.Debugger.IsAttached && winApplication.CheckCompatibilityType == CheckCompatibilityType.DatabaseSchema)
            {
                winApplication.DatabaseUpdateMode = DatabaseUpdateMode.UpdateDatabaseAlways;
            }
#endif
            try
            {
                winApplication.Setup();
                winApplication.ShowViewStrategy.StartupWindowLoad += (s, e) =>
                {
                    var schedulerWindow = (Form)((WinShowViewStrategyBase)s).Inspectors.OfType <WinWindow>().First().Template;

                    schedulerWindow.Shown += (s2, e2) =>
                    {
                        sw.Stop();
                        WinApplication.Messaging.Show("Time", $"Start-Time: {sw.Elapsed}");
                    };
                };
                winApplication.Start();
            }
            catch (Exception e)
            {
                winApplication.HandleException(e);
            }
        }
Exemplo n.º 19
0
 static void Main()
 {
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     WindowsFormsSettings.SetDPIAware();
     DevExpress.Skins.SkinManager.EnableFormSkins();
     WindowsFormsSettings.ScrollUIMode = ScrollUIMode.Touch;
     Application.Run(new Map());
 }
Exemplo n.º 20
0
        public static void Main(string[] args)
        {
            DevExpress.ExpressApp.FrameworkSettings.DefaultSettingsCompatibilityMode = DevExpress.ExpressApp.FrameworkSettingsCompatibilityMode.Latest;

            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            DevExpress.Utils.ToolTipController.DefaultController.ToolTipType = DevExpress.Utils.ToolTipType.SuperTip;
        }
 static void Main()
 {
     WindowsFormsSettings.SetDPIAware();
     WindowsFormsSettings.AllowDpiScale  = true;
     WindowsFormsSettings.AllowAutoScale = DevExpress.Utils.DefaultBoolean.True;
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     Application.Run(new Form1());
 }
Exemplo n.º 22
0
        static void Main()
        {
            WindowsFormsSettings.ForceDirectXPaint();
            UserLookAndFeel.Default.SetSkinStyle(SkinSvgPalette.Office2019Colorful);
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            Application.Run(new Form1());
        }
Exemplo n.º 23
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            //Enable title bar skinning
            WindowsFormsSettings.EnableFormSkins();
            WindowsFormsSettings.EnableMdiFormSkins();
            Application.Run(new Form1());
        }
Exemplo n.º 24
0
 protected internal virtual void SetupPredefinedConstraints()
 {
     if (!WindowsFormsSettings.GetAllowDefaultSvgImages())
     {
         foreach (BarItem item in this.ribbonControl1.Items)
         {
             item.ImageOptions.SvgImage = null;
         }
     }
 }
Exemplo n.º 25
0
        static void Main()
        {
            WindowsFormsSettings.LoadApplicationSettings();

            WindowsFormsSettings.ForceDirectXPaint();
            WindowsFormsSettings.EnableFormSkins();

            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.Run(new SRLoaderForm());
        }
Exemplo n.º 26
0
        private static void Main()
        {
#if EASYTEST
            DevExpress.ExpressApp.Win.EasyTest.EasyTestRemotingRegistration.Register();
#endif
            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            ToolTipController.DefaultController.ToolTipType = ToolTipType.SuperTip;
            if (Tracing.GetFileLocationFromSettings() == FileLocation.CurrentUserApplicationDataFolder)
            {
                Tracing.LocalUserAppDataPath = Application.LocalUserAppDataPath;
            }
            Tracing.Initialize();
            var winApplication = new Creatures3WindowsFormsApplication();
            winApplication.GetSecurityStrategy().RegisterEFAdapterProviders();
            if (ConfigurationManager.ConnectionStrings["ConnectionString"] != null)
            {
                winApplication.ConnectionString =
                    ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString;
            }
#if EASYTEST
            if (ConfigurationManager.ConnectionStrings["EasyTestConnectionString"] != null)
            {
                winApplication.ConnectionString =
                    ConfigurationManager.ConnectionStrings["EasyTestConnectionString"].ConnectionString;
            }
#endif
#if DEBUG
            if (Debugger.IsAttached && winApplication.CheckCompatibilityType == CheckCompatibilityType.DatabaseSchema)
            {
                winApplication.DatabaseUpdateMode = DatabaseUpdateMode.UpdateDatabaseAlways;
            }
#endif
            try
            {
                if (!WinMigrationHelper.CheckMigrationVersionAndUpgradeIfNeeded())
                {
                }
                else
                {
                    winApplication.Setup();
                    winApplication.Start();
                }

                //winApplication.Setup();
                //winApplication.Start();
            }
            catch (Exception e)
            {
                winApplication.StopSplash();
                winApplication.HandleException(e);
            }
        }
Exemplo n.º 27
0
        static void Main()
        {
#if EASYTEST
            DevExpress.ExpressApp.Win.EasyTest.EasyTestRemotingRegistration.Register();
#endif
            WindowsFormsSettings.LoadApplicationSettings();
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            EditModelPermission.AlwaysGranted = System.Diagnostics.Debugger.IsAttached;
            if (Tracing.GetFileLocationFromSettings() == DevExpress.Persistent.Base.FileLocation.CurrentUserApplicationDataFolder)
            {
                Tracing.LocalUserAppDataPath = Application.LocalUserAppDataPath;
            }
            Tracing.Initialize();
            LabelPrintingWindowsFormsApplication winApplication = new LabelPrintingWindowsFormsApplication();
            SecurityStrategy security = (SecurityStrategy)winApplication.Security;
            security.RegisterXPOAdapterProviders();
            if (ConfigurationManager.ConnectionStrings["ConnectionString"] != null)
            {
                winApplication.ConnectionString = ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString;
            }
#if EASYTEST
            if (ConfigurationManager.ConnectionStrings["EasyTestConnectionString"] != null)
            {
                winApplication.ConnectionString = ConfigurationManager.ConnectionStrings["EasyTestConnectionString"].ConnectionString;
            }
#endif
#if DEBUG
            if (System.Diagnostics.Debugger.IsAttached && winApplication.CheckCompatibilityType == CheckCompatibilityType.DatabaseSchema)
            {
                winApplication.DatabaseUpdateMode = DatabaseUpdateMode.UpdateDatabaseAlways;
            }
#endif
            try {
                DateTime StartDate = new DateTime(2020, 6, 16);
                DateTime EndDate   = DateTime.Today;
                var      s         = (EndDate - StartDate).TotalDays;
                if (s > 15)
                {
                    MessageBox.Show("Please make pending payment!", "Error");
                    winApplication.StopSplash();
                }
                else
                {
                    winApplication.Setup();
                    winApplication.Start();
                }
            }
            catch (Exception e) {
                winApplication.StopSplash();
                winApplication.HandleException(e);
            }
        }
Exemplo n.º 28
0
 static void Main()
 {
     WindowsFormsSettings.ForceDirectXPaint();
     Thread.CurrentThread.CurrentCulture = new CultureInfo("en-US");
     WindowsFormsSettings.SetDPIAware();
     DevExpress.Utils.AppearanceObject.DefaultFont = new Font("Segoe UI", 8.5F, FontStyle.Regular);
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     SkinManager.EnableFormSkins();
     UserLookAndFeel.Default.SetStyle(LookAndFeelStyle.Skin, false, false, "The Bezier");
     Application.Run(new StockMarketView());
 }
Exemplo n.º 29
0
        static void Main()
        {
            WindowsFormsSettings.ForceDirectXPaint();
            Application.SetCompatibleTextRenderingDefault(false);
            //((DevExpress.LookAndFeel.Design.UserLookAndFeelDefault)DevExpress.LookAndFeel.Design.UserLookAndFeelDefault.Default).LoadSettings(() => { });
            DevExpress.Utils.BrowserEmulationHelper.DisableBrowserEmulation(System.Reflection.Assembly.GetEntryAssembly().GetName().Name);

            BonusSkins.Register();
            SkinManager.EnableFormSkins();
            CustomSkinHelper.UpdateSkin();
            Application.EnableVisualStyles();
            Application.Run(new MainForm(new DmModel()));
        }
Exemplo n.º 30
0
        public static void Init()
        {
            WindowsFormsSettings.ForceDirectXPaint();
            WindowsFormsSettings.EnableFormSkins();
            WindowsFormsSettings.DefaultLookAndFeel.SetSkinStyle(SkinSvgPalette.Bezier.DarkTurquoise);
            var fs = WindowsFormsSettings.DefaultFont.Size;

            WindowsFormsSettings.DefaultFont = new System.Drawing.Font("Segoe UI", fs);

            MVVMContext.RegisterXtraMessageBoxService();
            MVVMContext.RegisterOpenFileDialogService();
            MVVMContext.RegisterSaveFileDialogService();
        }