Exemplo n.º 1
0
 public novy_Vodomer(int id, meric v, dum zobrazovany, pridat pridani)
 {
     InitializeComponent();
     label5.Text      = id.ToString();
     voda             = v;
     voda.typ         = Typ_merice.Vodomer;
     this.zobrazovany = zobrazovany;
     this.pridani     = pridani;
     this.ControlBox  = false;
 }
Exemplo n.º 2
0
        public void nacti_schema_domu(string vybrany)
        {
            System.Xml.Serialization.XmlSerializer reader = new System.Xml.Serialization.XmlSerializer(typeof(dum_ulozeni));
            System.IO.StreamReader file     = new System.IO.StreamReader(vybrany);
            dum_ulozeni            overview = (dum_ulozeni)reader.Deserialize(file);

            file.Close();
            this.zobrazovany = new dum(overview, this.panel1, this);
            //zakazat další úpravy domu
            this.zobrazovany.ulozeny = true;
            zakazat_upravy();
        }
Exemplo n.º 3
0
 public dum_ulozeni(dum ukladany_dum)
 {
     this.popis                       = ukladany_dum.popis;
     this.byty                        = ukladany_dum.byty;
     this.celkovy_elektrina           = ukladany_dum.celkovy_elektrina;
     this.celkovy_voda                = ukladany_dum.celkovy_voda;
     this.celkovy_plyn                = ukladany_dum.Celkovy_Plyn;
     this.spolecne_prostory_elektrina = ukladany_dum.spolecne_prostory_elektrina;
     this.spolecne_prostory_plyn      = ukladany_dum.spolecne_prostory_plyn;
     this.spolecne_prostory_voda      = ukladany_dum.spolecne_prostory_voda;
     this.dalsi_vodomery              = ukladany_dum.dalsi_vodomery;
     this.cesta                       = ukladany_dum.cesta;
     //this.Byty = ukladany_dum.Byty;
     this.ceny_energii = ukladany_dum.ceny_energii;
     this.id_pro_dum   = ukladany_dum.id_pro_dum;
 }
Exemplo n.º 4
0
        private void novýDůmToolStripMenuItem_Click(object sender, EventArgs e)
        {
            novy_Dum novy = new novy_Dum();

            zobrazovany         = new dum(this, this.panel1);
            zobrazovany.ulozeny = false;
            novy.novy_dum       = zobrazovany;
            novy.ShowDialog();

            if (zobrazovany != null)
            {
                zobrazovany.zobraz_dum();
                this.uložDůmToolStripMenuItem.Enabled   = true;
                this.přidatBytToolStripMenuItem.Enabled = true;
            }
        }
Exemplo n.º 5
0
 private void button2_Click(object sender, EventArgs e)
 {
     novy_dum = null;
     Close();
 }