Ejemplo n.º 1
0
        private void BtnBack_Click(object sender, EventArgs e)
        {
            copyBool = false;
            BunifuTransition transition = new BunifuTransition();

            transition.HideSync(pnlCopy, true, BunifuAnimatorNS.Animation.VertBlind);
        }
Ejemplo n.º 2
0
        private void btnBackWipe_Click(object sender, EventArgs e)
        {
            wipeBool = false;
            BunifuTransition transition = new BunifuTransition();

            transition.HideSync(pnlWipe, true, BunifuAnimatorNS.Animation.VertBlind);
        }
Ejemplo n.º 3
0
        private void btnNo_Click(object sender, EventArgs e)
        {
            removeBool = false;

            BunifuTransition transition = new BunifuTransition();

            transition.HideSync(pnlAreYouSure, true, BunifuAnimatorNS.Animation.VertBlind);
        }
Ejemplo n.º 4
0
 private void OffAllPanel(BunifuTransition animation)
 {
     for (int i = 0; i < panels.Count && panels[i].Visible == true; ++i)
     {
         animation.HideSync(BtnContents[i]);
         panels[i].Visible = false;
     }
 }
Ejemplo n.º 5
0
        private void Giris_FormClosing(object sender, FormClosingEventArgs e)
        {
            BunifuTransition transition = new BunifuTransition();

            transition.TimeStep         = 0.003f;
            transition.MaxAnimationTime = 25000;
            transition.HideSync(panel1, false, BunifuAnimatorNS.Animation.Mosaic);
        }
Ejemplo n.º 6
0
        private void Giris_Activated(object sender, EventArgs e)
        {
            BunifuTransition transition = new BunifuTransition();

            transition.TimeStep         = 0.003f;
            transition.MaxAnimationTime = 25000;
            transition.ShowSync(panel1, false, BunifuAnimatorNS.Animation.Particles);
        }
Ejemplo n.º 7
0
        private void tmrCopy_Tick(object sender, EventArgs e)
        {
            BunifuTransition transition = new BunifuTransition();

            transition.HideSync(pnlCopied, true, BunifuAnimatorNS.Animation.VertSlide);

            tmrCopy.Enabled = false;
        }
Ejemplo n.º 8
0
        private void aceptar_Click(object sender, EventArgs e)
        {
            BunifuTransition t = new BunifuTransition();

            t.AnimationType    = AnimationType.HorizSlide;
            t.MaxAnimationTime = 1000;
            t.ShowSync(contentConfirm);
            t.Dispose();
        }
Ejemplo n.º 9
0
        private void btnBackSettings_Click(object sender, EventArgs e)
        {
            settingsBool = false;

            pnlSettings.BringToFront();

            BunifuTransition transition = new BunifuTransition();

            transition.HideSync(pnlSettings, true, BunifuAnimatorNS.Animation.VertBlind);
        }
Ejemplo n.º 10
0
        private void btnCancel_Click(object sender, EventArgs e)
        {
            viewModel.AddNew = false;

            BunifuTransition transition = new BunifuTransition();

            transition.HideSync(pnlAddNewEntry, true, BunifuAnimatorNS.Animation.VertBlind);

            PassEntryResetText();
        }
Ejemplo n.º 11
0
        private void btnDelete_Click(object sender, EventArgs e)
        {
            removeBool = false;

            lstInfo.Items.Remove(lstInfo.SelectedItem);

            BunifuTransition transition = new BunifuTransition();

            transition.HideSync(pnlAreYouSure, true, BunifuAnimatorNS.Animation.VertBlind);

            SaveAndEncrypt();
        }
Ejemplo n.º 12
0
        private void txtPass_KeyPress(object sender, KeyPressEventArgs e)
        {
            if (e.KeyChar == (char)Keys.Enter)
            {
                HideAll();

                e.Handled = true;

                if (!File.Exists(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass/pass.set")))
                {
                    //first start
                    string plaintext       = txtPass.Text;                                  //user's pass
                    string passPhrase      = new NetworkCredential("", SecString).Password; //pass to encrypt
                    string encryptedstring = StringCipher.Encrypt(plaintext, passPhrase);   //encrypted pass

                    SavePassword(encryptedstring);                                          //create folder and write encrypted pass there

                    iconTick.Visible   = true;
                    pnlContent.Visible = true;
                    pnlContent.Hide();

                    BunifuTransition transition = new BunifuTransition();
                    transition.ShowSync(pnlContent, true, BunifuAnimatorNS.Animation.Transparent);
                }
                else
                {
                    if (txtPass.Text == GetDecryptedPassword())
                    {
                        iconTick.Visible   = true;
                        pnlContent.Visible = true;
                        pnlContent.Hide();

                        //TODO: May be serialization?
                        using (StreamReader r = new StreamReader(File.Open(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass/info.enc"), FileMode.Open)))
                        {
                            string line;
                            while ((line = r.ReadLine()) != null)
                            {
                                lstInfo.Items.Add(StringCipher.Decrypt(line, new NetworkCredential("", SecString).Password));
                            }
                        }

                        BunifuTransition transition = new BunifuTransition();
                        transition.ShowSync(pnlContent, true, BunifuAnimatorNS.Animation.Transparent);
                    }
                    else
                    {
                        flash            = 0;
                        tmrFlash.Enabled = true;
                    }
                }
            }
        }
Ejemplo n.º 13
0
        private void btnCopyAll_Click(object sender, EventArgs e)
        {
            try
            {
                tmrCopy.Enabled = true;

                Clipboard.SetText(lstInfo.SelectedItem.ToString());

                BunifuTransition transition = new BunifuTransition();
                transition.ShowSync(pnlCopied, true, BunifuAnimatorNS.Animation.VertSlide);
            }
            catch { }
        }
Ejemplo n.º 14
0
        private void btnCopyUser_Click(object sender, EventArgs e)
        {
            try
            {
                tmrCopy.Enabled = true;

                Clipboard.SetText(lstInfo.SelectedItem.ToString().Substring(lstInfo.SelectedItem.ToString().LastIndexOf("User: "******", Pass: "******"User: ") - 6));

                BunifuTransition transition = new BunifuTransition();
                transition.ShowSync(pnlCopied, true, BunifuAnimatorNS.Animation.VertSlide);
            }
            catch { }
        }
Ejemplo n.º 15
0
        private void TransitionThread(Panel panel, bool state)
        {
            BunifuTransition transition = new BunifuTransition();

            if (state)
            {
                transition.Show(panel, false, Animation.HorizSlide);
            }
            else
            {
                transition.Hide(panel, false, Animation.HorizSlide);
            }
        }
Ejemplo n.º 16
0
        private void btnAddEntry_Click(object sender, EventArgs e)
        {
            if (txtNameEntry.Text != "" && txtUserEntry.Text != "" && txtPassEntry.Text != "")
            {
                viewModel.AddNew = false;

                lstInfo.Items.Add(txtNameEntry.Text + " - " + "User: "******", " + "Pass: " + txtPassEntry.Text);

                BunifuTransition transition = new BunifuTransition();
                transition.HideSync(pnlAddNewEntry, true, BunifuAnimatorNS.Animation.VertBlind);
                PassEntryResetText();
            }

            SaveAndEncrypt();
        }
Ejemplo n.º 17
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            pnlAddNewEntry.BringToFront();
            BunifuTransition transition = new BunifuTransition();

            if (!viewModel.AddNew)
            {
                viewModel.AddNew = true;
                transition.ShowSync(pnlAddNewEntry, true, BunifuAnimatorNS.Animation.VertSlide);
            }
            else
            {
                viewModel.AddNew = false;
                transition.HideSync(pnlAddNewEntry, true, BunifuAnimatorNS.Animation.VertBlind);
            }
        }
Ejemplo n.º 18
0
        private void btnWipeAll1_Click(object sender, EventArgs e)
        {
            pnlWipe.BringToFront();
            BunifuTransition transition = new BunifuTransition();

            if (!viewModel.wipeBool)
            {
                viewModel.wipeBool = true;
                transition.ShowSync(pnlWipe, true, BunifuAnimatorNS.Animation.VertBlind);
            }
            else
            {
                viewModel.wipeBool = false;
                transition.HideSync(pnlWipe, true, BunifuAnimatorNS.Animation.VertBlind);
            }
        }
Ejemplo n.º 19
0
        private void btnRemove_Click(object sender, EventArgs e)
        {
            pnlAreYouSure.BringToFront();

            if (!removeBool)
            {
                removeBool = true;
                BunifuTransition transition = new BunifuTransition();
                transition.ShowSync(pnlAreYouSure, true, BunifuAnimatorNS.Animation.VertBlind);
            }
            else
            {
                removeBool = false;
                BunifuTransition transition = new BunifuTransition();
                transition.HideSync(pnlAreYouSure, true, BunifuAnimatorNS.Animation.VertBlind);
            }
        }
Ejemplo n.º 20
0
        private void btnCopy_Click(object sender, EventArgs e)
        {
            pnlCopy.BringToFront();

            if (!copyBool)
            {
                copyBool = true;
                BunifuTransition transition = new BunifuTransition();
                transition.ShowSync(pnlCopy, true, BunifuAnimatorNS.Animation.VertBlind);
            }
            else
            {
                copyBool = false;
                BunifuTransition transition = new BunifuTransition();
                transition.HideSync(pnlCopy, true, BunifuAnimatorNS.Animation.VertBlind);
            }
        }
Ejemplo n.º 21
0
        private void tmrMainProgress_Tick(object sender, EventArgs e)
        {
            if (mainProgress.Value < 100)
            {
                mainProgress.Value += 2;
            }
            else
            {
                tmrMainProgress.Stop();

                BunifuTransition transition = new BunifuTransition();
                frmContent       frm        = new frmContent();
                frm.Location = this.Location;
                frm.TopMost  = true;
                frm.Show();
                this.Hide();
                frm.TopMost = false;
            }
        }
Ejemplo n.º 22
0
 private void tmrBlink_Tick(object sender, EventArgs e)
 {
     if (IsBlink)
     {
         IsBlink             = false;
         lblText.ForeColor   = Color.Yellow;
         lblSholat.ForeColor = Color.Yellow;
         BunifuTransition transition = new BunifuTransition();
         transition.ShowSync(cpProgress, false, Animation.Particles);
     }
     else
     {
         IsBlink             = true;
         lblText.ForeColor   = Color.White;
         lblSholat.ForeColor = Color.White;
         BunifuTransition transition = new BunifuTransition();
         transition.HideSync(cpProgress, false, Animation.Particles);
     }
 }
Ejemplo n.º 23
0
        private void btnRemove_Click(object sender, EventArgs e)
        {
            if (lstInfo.Items.Count == 0)
            {
                return;
            }

            pnlAreYouSure.BringToFront();
            BunifuTransition transition = new BunifuTransition();

            if (!viewModel.removeBool)
            {
                viewModel.removeBool = true;
                transition.ShowSync(pnlAreYouSure, true, BunifuAnimatorNS.Animation.VertBlind);
            }
            else
            {
                viewModel.removeBool = false;
                transition.HideSync(pnlAreYouSure, true, BunifuAnimatorNS.Animation.VertBlind);
            }
        }
Ejemplo n.º 24
0
 public PnContentQs(Panel panelRoot, BunifuTransition animation, ZoomImg zoomImg)
 {
     this.panelRoot = panelRoot;
     this.animation = animation;
     this.zoomImg   = zoomImg;
 }
        private void MostrarConAnimacion(Control control)
        {
            BunifuTransition transition = new BunifuTransition();

            transition.ShowSync(control, false, Animation.VertSlide);
        }
Ejemplo n.º 26
0
        private void MostrarConAnimacion(Control control, Animation tipo)
        {
            BunifuTransition transition = new BunifuTransition();

            transition.ShowSync(control, false, tipo);
        }
Ejemplo n.º 27
0
        private void EsconderConAnimacion(Control control, Animation tipo)
        {
            BunifuTransition transition = new BunifuTransition();

            transition.HideSync(control, false, tipo);
        }
Ejemplo n.º 28
0
        private void txtPass_KeyPress(object sender, KeyPressEventArgs e)
        {
            if (e.KeyChar == (char)Keys.Enter)
            {
                HideAll();

                e.Handled = true;

                if (!File.Exists(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass/pass.set")))
                {
                    string plaintext = txtPass.Text;

                    string encryptedstring = "";
                    string decryptedstring = "";

                    encryptedstring = StringCipher.Encrypt(plaintext, new NetworkCredential("", SecString).Password);
                    decryptedstring = StringCipher.Decrypt(encryptedstring, new NetworkCredential("", SecString).Password);

                    string pathPass = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass/pass.key");
                    string pathInfo = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass/info.enc");

                    Directory.CreateDirectory(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass"));

                    var fileStream1 = File.Create(pathPass);
                    fileStream1.Close();
                    var fileStream2 = File.Create(pathInfo);
                    fileStream2.Close();

                    TextWriter tw = new StreamWriter(pathPass);
                    tw.WriteLine(encryptedstring);
                    tw.Close();

                    try
                    {
                        File.Encrypt(pathPass);
                        File.Encrypt(pathInfo);
                    }
                    catch { }

                    var fileStream3 = File.Create(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass/pass.set"));
                    fileStream3.Close();

                    iconTick.Visible   = true;
                    pnlContent.Visible = true;
                    pnlContent.Hide();

                    BunifuTransition transition = new BunifuTransition();
                    transition.ShowSync(pnlContent, true, BunifuAnimatorNS.Animation.Transparent);
                }
                else
                {
                    string encryptedstring = "";
                    string decryptedstring = "";

                    encryptedstring = File.ReadAllText(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass/pass.key"));
                    decryptedstring = StringCipher.Decrypt(encryptedstring, new NetworkCredential("", SecString).Password);

                    if (txtPass.Text == decryptedstring)
                    {
                        iconTick.Visible   = true;
                        pnlContent.Visible = true;
                        pnlContent.Hide();

                        using (StreamReader r = new StreamReader(File.Open(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "CPass/info.enc"), FileMode.Open)))
                        {
                            string line;
                            while ((line = r.ReadLine()) != null)
                            {
                                lstInfo.Items.Add(StringCipher.Decrypt(line, new NetworkCredential("", SecString).Password));
                            }
                        }

                        BunifuTransition transition = new BunifuTransition();
                        transition.ShowSync(pnlContent, true, BunifuAnimatorNS.Animation.Transparent);
                    }
                    else
                    {
                        flash            = 0;
                        tmrFlash.Enabled = true;
                    }
                }
            }
        }