public TextEdit() { InitializeComponent(); // Установка обработчиков // Ввод текста PART_textBox.PreviewTextInput += new TextCompositionEventHandler(TextBoxPreviewTextInput); // Копирование "Paste" PART_textBox.AddHandler(DataObject.PastingEvent, new DataObjectPastingEventHandler(TextBoxPasting)); PART_textBox.TextChanged += new TextChangedEventHandler(PART_textBox_TextChanged); // Обработка изменения поля Password PART_password.PasswordChanged += new RoutedEventHandler(PART_password_PasswordChanged); }
public WindowPromt(String title, Boolean isCombo = false) { InitializeComponent(); #warning Доработать // this.Owner = Program.CurrentWindow; this.ShowInTaskbar = false; this.Title = title; if (isCombo == false) { PART_comboBox.Visibility = Visibility.Collapsed; PART_textBox.Focus(); } else { PART_textBox.Visibility = Visibility.Collapsed; PART_comboBox.Focus(); } }
/// <summary> /// Установка фокуса в поле ввода /// </summary> /// <returns></returns> public new Boolean Focus() { return(PART_textBox.Focus()); }