Exemplo n.º 1
0
        private void InitializePhiddleCore()
        {
            phiddle = new PhiddleCore();
            screen  = new ScreenServiceMac(Window);
            phiddle.Services.AddSingleton(screen);
            phiddle.Services.AddSingleton <SettingsService <AppInputMac> >();

            phiddle.Initialize();
            Window.Phiddle = phiddle;
        }
Exemplo n.º 2
0
        private void InitializePhiddleCore()
        {
            // Create the Core, add our services and initialize Core with it
            phiddle = new PhiddleCore();
            phiddle.Services.AddSingleton(screen);
            phiddle.Services.AddSingleton <LoggingService>();
            phiddle.Services.AddSingleton <SettingsService <AppInputWin> >();
            phiddle.Initialize();

            // Get the services we need right away
            Log = PhiddleCore.ServiceProvider.GetRequiredService <LoggingService>();
            var settingsService = PhiddleCore.ServiceProvider.GetRequiredService <SettingsService <AppInputWin> >();

            appInput = settingsService.Settings;

            if (!settingsService.Loaded & settingsService.IsDefault)
            {
                Log.Warning("InitializePhiddleCore", "Could not load settings for App Input, using defaults");
            }
        }