private void Button_Replace_Click(object sender, EventArgs e) { WritebackOptions(); if (IsSelectionSearch) { if (IsTextSelected(selection)) { ReplaceInSelection(); } } else { using (AsynchronousWaitDialog monitor = AsynchronousWaitDialog.ShowWaitDialog("Search", true)) { SearchReplaceManager.Replace(monitor); } } Focus(); }
void ReplaceButtonClicked(object sender, EventArgs e) { WritebackOptions(); if (IsSelectionSearch) { if (selection.IsTextSelected) { ReplaceInSelection(); } } else { using (AsynchronousWaitDialog monitor = AsynchronousWaitDialog.ShowWaitDialog("Search", true)) { monitor.Progress = double.NaN; // progress not implemented, use indeterminate progress SearchReplaceManager.Replace(monitor); } } Focus(); }