using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace TFSBuildManager
{
    public partial class ConfigurationForm : Form
    {
        public ConfigurationForm(string title)
        {
            InitializeComponent();
            Text = title;
        }

        public ConfigurationForm(string title, string flavor, string platform)
        {
            InitializeComponent();
            Text = title;
            cmbFlavor.Text = flavor;
            cmbPlatform.Text = platform;

        }

        private void cmbFlavor_TextChanged(object sender, EventArgs e)
        {
            btnOK.Enabled = (((cmbFlavor.Text != String.Empty) && (cmbFlavor.Text != null)) &&
                ((cmbPlatform.Text != String.Empty) && (cmbPlatform.Text != null)));
        }

        private void cmbPlatform_TextChanged(object sender, EventArgs e)
        {
            btnOK.Enabled = (((cmbFlavor.Text != String.Empty) && (cmbFlavor.Text != null)) &&
                ((cmbPlatform.Text != String.Empty) && (cmbPlatform.Text != null)));
        }

        private string flavor;

        public string Flavor
        {
            get { return flavor; }
        }

        private string platform;

        public string Platfrom
        {
            get { return platform; }
        }

        private void btnOK_Click(object sender, EventArgs e)
        {
            flavor = cmbFlavor.Text;
            platform = cmbPlatform.Text;
        }
    }
}