Exemplo n.º 1
0
        public void setupButtons()
        {
            ConfigCar tmpConfig = this.configCar;

            if (tmpConfig.butterfly_doors == 0)
            {
                disableButterflyButtons();
            }

            if (tmpConfig.doors == 0)
            {
                disableDoorsButtons();
            }

            if (tmpConfig.engine == 0)
            {
                disableEngineButtons();
            }

            if (tmpConfig.clutch == 0)
            {
                disableClutchButtons();
            }

            if (tmpConfig.hood_car == 0)
            {
                disableHoodButtons();
            }

            if (tmpConfig.trunk_car == 0)
            {
                disableTrunkButtons();
            }
        }
Exemplo n.º 2
0
        private void dataConfigCar_CellContentClick(object sender, DataGridViewCellEventArgs e)
        {
            int numberLineInTable = e.RowIndex;

            string json_message = dataConfigCar[5, numberLineInTable].Value.ToString();

            ConfigCar cc = JsonConvert.DeserializeObject <ConfigCar>(json_message);

            FormConfigCar nextWindow = new FormConfigCar(cc);

            nextWindow.ShowDialog();
        }
Exemplo n.º 3
0
 public FormConfigCar(ConfigCar car)
 {
     InitializeComponent();
     this.configCar = car;
     setupButtons();
 }