public OnlineSettingsForm(Application applicationConfiguration)
        {
            InitializeComponent();

            this.applicationConfiguration = applicationConfiguration;
            workingApplicationConfiguration = ObjectCopier.CloneObject<Application, Application>(applicationConfiguration);
        }
Example #2
0
 public StrategiesForm(Strategy strategyConfiguration, List<CryptoCoin> knownCoins, 
     Application applicationConfiguration)
 {
     InitializeComponent();
     this.strategyConfiguration = strategyConfiguration;
     this.applicationConfiguration = applicationConfiguration;
     this.knownCoins = knownCoins;
 }
Example #3
0
        public MinerSettingsForm(MultiMiner.Engine.Data.Configuration.Xgminer minerConfiguration, Application applicationConfiguration)
        {
            InitializeComponent();
            this.minerConfiguration = minerConfiguration;
            this.workingMinerConfiguration = ObjectCopier.CloneObject<MultiMiner.Engine.Data.Configuration.Xgminer, MultiMiner.Engine.Data.Configuration.Xgminer>(minerConfiguration);

            this.applicationConfiguration = applicationConfiguration;
            this.workingApplicationConfiguration = ObjectCopier.CloneObject<Application, Application>(applicationConfiguration);
        }
        public AdvancedSettingsForm(Application applicationConfiguration, Paths pathConfiguration)
        {
            InitializeComponent();

            this.applicationConfiguration = applicationConfiguration;
            workingApplicationConfiguration = ObjectCopier.CloneObject<Application, Application>(applicationConfiguration);

            this.pathConfiguration = pathConfiguration;
            workingPathConfiguration = ObjectCopier.CloneObject<Paths, Paths>(pathConfiguration);

            if (String.IsNullOrEmpty(workingApplicationConfiguration.LogFilePath))
                workingApplicationConfiguration.LogFilePath = ApplicationPaths.AppDataPath();

            if (String.IsNullOrEmpty(workingPathConfiguration.SharedConfigPath))
                workingPathConfiguration.SharedConfigPath = ApplicationPaths.AppDataPath();
        }
Example #5
0
        static void Main()
        {
            using (Mutex mutex = new Mutex(false, "Global\\" + appGuid))
            {
                if (!mutex.WaitOne(0, false))
                {
                    Paths pathConfig = new Paths();
                    pathConfig.LoadPathConfiguration();
                    Data.Configuration.Application appConfig = new Data.Configuration.Application();
                    appConfig.LoadApplicationConfiguration(pathConfig.SharedConfigPath);
                    if (!appConfig.AllowMultipleInstances)
                        return;
                }

                RunApplication();
            }
        }
Example #6
0
        static void Main()
        {
            using (Mutex mutex = new Mutex(false, "Global\\" + appGuid))
            {
                if (!mutex.WaitOne(0, false))
                {
                    Paths pathConfig = new Paths();
                    pathConfig.LoadPathConfiguration();
                    Data.Configuration.Application appConfig = new Data.Configuration.Application();
                    appConfig.LoadApplicationConfiguration(pathConfig.SharedConfigPath);
                    if (!appConfig.AllowMultipleInstances)
                    {
                        return;
                    }
                }

                RunApplication();
            }
        }