예제 #1
0
파일: frmMain.cs 프로젝트: topoulos/Kode
        public frmMain()
        {
            InitializeComponent();
            var iniReader      = new IniReader(Resx.iniFileName);
            var config         = new SetupConfig();
            var rpcCommand     = new RpcCommand(config.GetKodiIP());
            var kodi           = new Kodi(rpcCommand);
            var yamahaCommand  = new YamahaCommand();
            var soapCommand    = new SoapCommand();
            var yamahaResponse = new YamahaResponse();
            var avReceiver     = new AVReceiver(yamahaCommand, soapCommand, yamahaResponse);
            mediator           = new Mediator(kodi, avReceiver, iniReader);

            RegisterButtons();

            mediator.SetStripColors();
        }
예제 #2
0
파일: frmOptions.cs 프로젝트: topoulos/Kode
 public frmOptions()
 {
     InitializeComponent();
     IIniReader reader = new IniReader(Resx.iniFileName);
     IIniWriter writer = new IniWriter(Resx.iniFileName);
     mediator = new OptionsMediator(writer, reader);
     mediator.Register(this.txtKodiIP);
     mediator.Register(this.txtKodiPort);
     mediator.Register(this.txtYamahaIP);
     mediator.Register(this.btnSave);
     mediator.Register(this.txtHdmi1);
     mediator.Register(this.txtHdmi2);
     mediator.Register(this.txtHdmi3);
     mediator.Register(this.txtHdmi4);
     mediator.Register(this.txtVaux);
     mediator.Register(this.txtBackcolor);
     mediator.Register(this.txtForecolor);
 }
예제 #3
0
 public SetupConfig()
 {
     reader = new IniReader(Resx.iniFileName);
     writer = new IniWriter(Resx.iniFileName);
 }