Exemplo n.º 1
0
        // This opens the Find & Replace subwindow
        public void OpenFindAndReplace()
        {
            if (findreplaceform == null)
            {
                findreplaceform = new ScriptFindReplaceForm();
            }

            try
            {
                if (findreplaceform.Visible)
                {
                    findreplaceform.Focus();
                }
                else
                {
                    findreplaceform.Show(this.ParentForm);
                }

                if (ActiveTab.SelectionEnd != ActiveTab.SelectionStart)
                {
                    findreplaceform.SetFindText(ActiveTab.GetSelectedText());
                }
            }
            catch (Exception)
            {
                // If we can't pop up the find/replace form right now, thats just too bad.
            }
        }
Exemplo n.º 2
0
 // This closed the Find & Replace subwindow
 public void CloseFindReplace(bool closing)
 {
     if (findreplaceform != null)
     {
         if (!closing)
         {
             findreplaceform.Close();
         }
         findreplaceform = null;
     }
 }