forked from unoplatform/uno
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request unoplatform#7512 from unoplatform/dev/xygu/2021112…
…3/wasm-textbox-hitbox fix(textbox): caret cursor and click focus area on wasm
- Loading branch information
Showing
7 changed files
with
114 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
...SamplesApp/UITests.Shared/Windows_UI_Xaml_Controls/TextBox/TextBox_WithPadding_Focus.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
<UserControl | ||
x:Class="UITests.Windows_UI_Xaml_Controls.TextBox.TextBox_WithPadding_Focus" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:UITests.Windows_UI_Xaml_Controls.TextBox" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
d:DesignHeight="300" | ||
d:DesignWidth="400"> | ||
|
||
<StackPanel Spacing="8"> | ||
<TextBox x:Name="textBox1" Padding="24" /> | ||
<TextBox x:Name="textBox2" Padding="24"> | ||
<TextBox.Template> | ||
<ControlTemplate> | ||
<Grid Background="{TemplateBinding Background}" | ||
Padding="{TemplateBinding Padding}" | ||
BorderBrush="{TemplateBinding BorderBrush}" | ||
BorderThickness="{TemplateBinding BorderThickness}"> | ||
<ScrollViewer x:Name="ContentElement" | ||
HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}" | ||
HorizontalScrollMode="{TemplateBinding ScrollViewer.HorizontalScrollMode}" | ||
IsDeferredScrollingEnabled="{TemplateBinding ScrollViewer.IsDeferredScrollingEnabled}" | ||
IsHorizontalRailEnabled="{TemplateBinding ScrollViewer.IsHorizontalRailEnabled}" | ||
IsTabStop="False" | ||
IsVerticalRailEnabled="{TemplateBinding ScrollViewer.IsVerticalRailEnabled}" | ||
VerticalScrollMode="{TemplateBinding ScrollViewer.VerticalScrollMode}" | ||
VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}" | ||
VerticalAlignment="Bottom" | ||
ZoomMode="Disabled" | ||
AutomationProperties.AccessibilityView="Raw"> | ||
<ScrollViewer.RenderTransform> | ||
<CompositeTransform x:Name="ContentElement_CompositeTransform" /> | ||
</ScrollViewer.RenderTransform> | ||
</ScrollViewer> | ||
</Grid> | ||
</ControlTemplate> | ||
</TextBox.Template> | ||
</TextBox> | ||
</StackPanel> | ||
</UserControl> |
27 changes: 27 additions & 0 deletions
27
...plesApp/UITests.Shared/Windows_UI_Xaml_Controls/TextBox/TextBox_WithPadding_Focus.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.IO; | ||
using System.Linq; | ||
using System.Runtime.InteropServices.WindowsRuntime; | ||
using Uno.UI.Samples.Controls; | ||
using Windows.Foundation; | ||
using Windows.Foundation.Collections; | ||
using Windows.UI.Xaml; | ||
using Windows.UI.Xaml.Controls; | ||
using Windows.UI.Xaml.Controls.Primitives; | ||
using Windows.UI.Xaml.Data; | ||
using Windows.UI.Xaml.Input; | ||
using Windows.UI.Xaml.Media; | ||
using Windows.UI.Xaml.Navigation; | ||
|
||
namespace UITests.Windows_UI_Xaml_Controls.TextBox | ||
{ | ||
[SampleControlInfo(nameof(TextBox), nameof(TextBox_WithPadding_Focus))] | ||
public sealed partial class TextBox_WithPadding_Focus : UserControl | ||
{ | ||
public TextBox_WithPadding_Focus() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters