Example #1
0
        private void listClient_MouseDoubleClick_1(object sender, MouseEventArgs e)
        {
            int index = this.listClient.IndexFromPoint(e.Location);

            if (index != ListBox.NoMatches)
            {
                SingletonShop shop = SingletonShop.Instance;
                if (!shop.shopOpen())
                {
                    new Shop().Show();
                }
                shop.setClient(clienti.ElementAt(index - 1));
                this.Hide();
            }
        }
Example #2
0
 private void Factura_Load(object sender, EventArgs e)
 {
     shop          = SingletonShop.Instance;
     client        = shop.getClient();
     produseAlim   = shop.getProdAlimentare();
     cantAlim      = shop.getCantAlim();
     produseNealim = shop.getProdNealimentare();
     cantNealim    = shop.getCantNealim();
     img           = new Bitmap(pictureFactura.Width, pictureFactura.Height);
     g             = Graphics.FromImage(img);
     fLogo         = new Font("Times New Roman", 20, FontStyle.Bold);
     fHeader       = new Font("Times New Roman", 12, FontStyle.Bold);
     fText         = new Font("Times New Roman", 10);
     deseneaza();
 }
Example #3
0
 private void Shop_Load(object sender, EventArgs e)
 {
     shop          = SingletonShop.Instance;
     produseAlim   = new List <ProdAlimentar>();
     produseNealim = new List <ProdNealimentar>();
     alege.Items.Add("-");
     alege.SelectedIndex = 0;
     alege.Items.Add("Produse alimentare");
     alege.Items.Add("Produse nealimentare");
     img   = new Bitmap(scanCode.Width, scanCode.Height);
     g     = Graphics.FromImage(img);
     myPen = new Pen(Brushes.Black, 2.0f);
     f     = new Font("Times New Roman", 15, GraphicsUnit.Pixel);
     hideAll();
 }