18 lines
612 B
VB.net
18 lines
612 B
VB.net
Public Class InputExpanderV
|
|
|
|
Private Sub TextBox_PreviewKeyDown(sender As Object, e As KeyEventArgs)
|
|
If (e.Key = Key.Enter And (Keyboard.Modifiers And ModifierKeys.Shift) = ModifierKeys.Shift) Or
|
|
(e.Key = Key.V And (Keyboard.Modifiers And ModifierKeys.Control) = ModifierKeys.Control) Then
|
|
Txt.AcceptsReturn = True
|
|
Txt.TextWrapping = TextWrapping.Wrap
|
|
End If
|
|
End Sub
|
|
|
|
Private Sub Txt_IsVisibleChanged(sender As Object, e As DependencyPropertyChangedEventArgs)
|
|
If Txt.IsVisible Then
|
|
Txt.Focus()
|
|
End If
|
|
End Sub
|
|
|
|
End Class
|