Exemplo n.º 1
0
        private void emailToolStripMenuItem_Click(object sender, EventArgs e)
        {
            int    emailIndex = contactsPane.SelectedCells[0].RowIndex;
            string email      = contactsPane.Rows[emailIndex].Cells[1].Value.ToString();

            office.Email(email, NotesOrganizer.GetAndFormatSelectedNotes());
        }
Exemplo n.º 2
0
 private static void Drop()
 {
     NotesOrganizer.area.Remove(NotesOrganizer.fakePane);
     NotesOrganizer.Align(new Point(NotesOrganizer.fakePane.Location.X, NotesOrganizer.fakePane.Location.Y));
     NotesOrganizer.area.Insert(position, NotesOrganizer.fakePane);
     currentArea             = null;
     NotesOrganizer.fakePane = null;
 }
Exemplo n.º 3
0
 private void btnExport_Click(object sender, EventArgs e)
 {
     if (NotesOrganizer.GetAndFormatSelectedNotes() != null)
     {
         office.Export(NotesOrganizer.GetAndFormatSelectedNotes());
     }
     else
     {
         InformationBox.Show("Please select at least one note by clicking on the checkbox", "Invalid Text");
     }
 }
Exemplo n.º 4
0
        private void btnColor_Click(object sender, EventArgs e)
        {
            ColorDialog cd = new ColorDialog();

            if (cd.ShowDialog() == DialogResult.OK)
            {
                NotesOrganizer.SetColor(cd.Color);
            }
            Notes.Properties.Settings.Default.UserColor = cd.Color;
            Notes.Properties.Settings.Default.Save();
        }
Exemplo n.º 5
0
        private void btnFont_Click(object sender, EventArgs e)
        {
            FontDialog fd = new FontDialog();

            if (fd.ShowDialog() == DialogResult.OK)
            {
                NotesOrganizer.SetFont(fd.Font);
            }
            Notes.Properties.Settings.Default.UserFont = fd.Font;
            Notes.Properties.Settings.Default.Save();
        }
Exemplo n.º 6
0
 public static void ManageDragPane()
 {
     if (dragging)
     {
         NotesOrganizer.fakePane = currentArea;
         NotesOrganizer.area.Remove(NotesOrganizer.fakePane);
         NotesOrganizer.fakePane.Location = NotesOrganizer.Align(NotesOrganizer.fakePane.Location);
         if (NotesOrganizer.area[position] != NotesOrganizer.fakePane)
         {
             NotesOrganizer.area.Remove(NotesOrganizer.fakePane);
             NotesOrganizer.area.Insert(position, NotesOrganizer.fakePane);
             Clean();
         }
     }
 }
Exemplo n.º 7
0
 private void btnSelectAll_Click(object sender, EventArgs e)
 {
     if (btnSelectAll.Text == "Select All")
     {
         NotesOrganizer.SelectAll(false);
         btnSelectAll.Text = "Deselect";
         btnDelete.Enabled = true;
     }
     else
     {
         NotesOrganizer.SelectAll(true);
         btnSelectAll.Text = "Select All";
         btnDelete.Enabled = false;
     }
     this.Refresh();
 }
Exemplo n.º 8
0
        private void btnDelete_Click(object sender, EventArgs e)
        {
            bool reset = false;

            for (int i = 0; i < NotesOrganizer.area.Count; i++)
            {
                if (reset)
                {
                    i     = 0;
                    reset = false;
                }

                Panel pane = NotesOrganizer.area[i];

                foreach (Control c in pane.Controls)
                {
                    if (c is CheckBox)
                    {
                        CheckBox check = (CheckBox)c;

                        if (check.Checked)
                        {
                            RemoveAtIndex(i);
                            NotesOrganizer.UpdateLocations();
                            //dont delete this, it fixes a bug
                            if (i == 0)
                            {
                                i = -1;
                            }
                            else
                            {
                                i = 0;
                            }
                            reset = true;
                        }
                    }
                }
                btnDelete.Enabled = false;
            }
            ControlManager.Refresh();
            Remind();
        }
Exemplo n.º 9
0
        new private void Update()
        {
            if (NotesOrganizer.IsExtendedView() && !NotesOrganizer.resetLocations && !pnlNoteHolder.VerticalScroll.Visible)
            {
                scroll = new Point(0, 0);
            }
            if (NotesOrganizer.scrollControlIntoView)
            {
                pnlNoteHolder.ScrollControlIntoView(NotesOrganizer.area[NotesOrganizer.area.Count - 1]);
                scroll = pnlNoteHolder.AutoScrollPosition;
                NotesOrganizer.scrollControlIntoView = false;
            }

            ShowOptions();
            ShowContacts();

            if (exit)
            {
                Application.Exit();
            }
        }
Exemplo n.º 10
0
 private void UpdateUI_Tick(object sender, EventArgs e)
 {
     Update();
     NotesOrganizer.UpdateLocations();
 }