개정판 8bd25583
issue #0003 SearchPanel TextBox Clear Button 추가
Change-Id: I04b3cdc33a1d95a16d589af292983295c0870847
KCOM/App.xaml | ||
---|---|---|
7 | 7 |
<Application.Resources> |
8 | 8 |
<ResourceDictionary> |
9 | 9 |
<ResourceDictionary.MergedDictionaries> |
10 |
<ResourceDictionary Source="/Telerik.Windows.Controls;component/Themes/FontResources.xaml"/> |
|
10 | 11 |
<ResourceDictionary Source="Resources\Theme_Color.xaml"/> |
11 | 12 |
<ResourceDictionary Source="Resources\DecodeImageTemplate.xaml"/> |
12 | 13 |
<ResourceDictionary Source="Resources\Theme_CustomControl.xaml"/> |
13 | 14 |
<ResourceDictionary Source="Resources\SimpleLIstViewStyle.xaml"/> |
15 |
<ResourceDictionary Source="Resources\ClearTextBoxStyle.xaml"/> |
|
14 | 16 |
<ResourceDictionary Source="Assets\RadGridViewStyleResourceDictionary.xaml"/> |
15 | 17 |
<ResourceDictionary Source="Messenger\StyleDictionary.xaml"/> |
16 | 18 |
<ResourceDictionary Source="/MarkupToPDF;component/themes/generic.xaml"/> |
... | ... | |
24 | 26 |
<ResourceDictionary Source="/Telerik.Windows.Themes.VisualStudio2013;component/Themes/System.Windows.xaml"/> |
25 | 27 |
<ResourceDictionary Source="/Telerik.Windows.Themes.VisualStudio2013;component/Themes/Telerik.Windows.Controls.xaml"/> |
26 | 28 |
<ResourceDictionary Source="/Telerik.Windows.Themes.VisualStudio2013;component/Themes/Telerik.Windows.Controls.Input.xaml"/> |
29 |
|
|
27 | 30 |
<!--<ResourceDictionary Source="/Telerik.Windows.Themes.VisualStudio2013;component/Themes/Telerik.Windows.Controls.RibbonView.xaml"/>--> |
28 | 31 |
<!--<ResourceDictionary Source="/Telerik.Windows.Themes.VisualStudio2013;component/Themes/Telerik.Windows.Controls.Docking.xaml"/>--> |
29 | 32 |
</ResourceDictionary.MergedDictionaries> |
KCOM/Controls/SearchPanel.xaml | ||
---|---|---|
28 | 28 |
<ColumnDefinition Width="8*"/> |
29 | 29 |
<ColumnDefinition Width="2*"/> |
30 | 30 |
</Grid.ColumnDefinitions> |
31 |
<telerik:RadMaskedTextInput Mask="" HorizontalAlignment="Stretch" Margin="2,0" AcceptsReturn="False" EmptyContent="Input Search Text" IsClearButtonVisible="True" Background="#FFF3F3F3" BorderThickness="0.5" VerticalContentAlignment="Center" x:Name="tbSearch"/> |
|
31 |
<TextBox HorizontalAlignment="Stretch" Style="{StaticResource ClearTextBoxStyle}" Margin="2,0" telerik:StyleManager.Theme="Office2016" AcceptsReturn="False" Background="#FFF3F3F3" BorderThickness="0.5" VerticalContentAlignment="Center" x:Name="tbSearch" IsTabStop="True"/> |
|
32 |
<!--<telerik:RadMaskedTextInput Mask="" |
|
33 |
HorizontalAlignment="Stretch" Margin="2,0" AcceptsReturn="False" EmptyContent="Input Search Text" IsClearButtonVisible="True" Background="#FFF3F3F3" BorderThickness="0.5" VerticalContentAlignment="Center" x:Name="tbSearch" IsTabStop="True"/>--> |
|
32 | 34 |
<Button Content="Search" Grid.Column="1" Padding="5" Background="#3d3d3d" Foreground="White" x:Name="btnSearch"/> |
33 | 35 |
</Grid> |
34 | 36 |
<GroupBox Header="Option List"> |
... | ... | |
106 | 108 |
telerik:StyleManager.Theme="Office2016" IsIndeterminate="False" /> |
107 | 109 |
</StackPanel> |
108 | 110 |
</Grid> |
111 |
<!--Visibility="{Binding Instance.IsDownloadOriginal, Converter={StaticResource InvertedBooleanToVisibilityConverter}}"--> |
|
109 | 112 |
<Border Background="Black" Grid.RowSpan="2" Opacity="0.7" Margin="-10" x:Name="border_Overlap" |
110 |
Visibility="{Binding Instance.IsDownloadOriginal, Converter={StaticResource InvertedBooleanToVisibilityConverter}}"
|
|
113 |
Visibility="Hidden"
|
|
111 | 114 |
DataContext="{DynamicResource viewDataModel}"> |
112 | 115 |
<StackPanel VerticalAlignment="Center"> |
113 | 116 |
<TextBlock x:Name="tlDonwloadState" Text="원활한 검색을 위해 데이터를 준비합니다" Foreground="White" HorizontalAlignment="Center" Margin="0,10" FontWeight="Bold"/> |
KCOM/Controls/SearchPanel.xaml.cs | ||
---|---|---|
56 | 56 |
worker.RunWorkerCompleted += Worker_RunWorkerCompleted; |
57 | 57 |
|
58 | 58 |
this.DataContext = this; |
59 |
|
|
60 | 59 |
/* |
61 | 60 |
if (Common.ViewerDataModel.Instance.searchPDF ==null) |
62 | 61 |
{ |
KCOM/Events/Event_KeyEvent.cs | ||
---|---|---|
216 | 216 |
this.dzMainMenu.searchPane.IsPinned = true; |
217 | 217 |
if (ViewerDataModel.Instance.searchPDF != null) |
218 | 218 |
{ |
219 |
this.dzMainMenu.searchPanel_Instance.tbSearch.Focus(); |
|
219 |
Application.Current.Dispatcher.BeginInvoke(new Action(() => |
|
220 |
{ |
|
221 |
this.dzMainMenu.searchPanel_Instance.tbSearch.Focusable = true; |
|
222 |
this.dzMainMenu.searchPanel_Instance.tbSearch.Focus(); |
|
223 |
Keyboard.Focus(this.dzMainMenu.searchPanel_Instance.tbSearch); |
|
224 |
}), System.Windows.Threading.DispatcherPriority.Render); |
|
220 | 225 |
} |
221 | 226 |
else |
222 | 227 |
{ |
KCOM/KCOM.csproj | ||
---|---|---|
452 | 452 |
<SubType>Designer</SubType> |
453 | 453 |
<Generator>MSBuild:Compile</Generator> |
454 | 454 |
</Page> |
455 |
<Page Include="Resources\ClearTextBoxStyle.xaml"> |
|
456 |
<SubType>Designer</SubType> |
|
457 |
<Generator>MSBuild:Compile</Generator> |
|
458 |
</Page> |
|
455 | 459 |
<Page Include="Resources\DecodeImageTemplate.xaml"> |
456 | 460 |
<SubType>Designer</SubType> |
457 | 461 |
<Generator>MSBuild:Compile</Generator> |
KCOM/Resources/ClearTextBoxStyle.xaml | ||
---|---|---|
1 |
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
|
2 |
xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" |
|
3 |
xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity" |
|
4 |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
|
5 |
<!--Control colors.--> |
|
6 |
<Color x:Key="WindowColor">#FFE8EDF9</Color> |
|
7 |
<Color x:Key="ContentAreaColorLight">#FFC5CBF9</Color> |
|
8 |
<Color x:Key="ContentAreaColorDark">#FF7381F9</Color> |
|
9 |
|
|
10 |
<Color x:Key="DisabledControlLightColor">#FFE8EDF9</Color> |
|
11 |
<Color x:Key="DisabledControlDarkColor">#FFC5CBF9</Color> |
|
12 |
<Color x:Key="DisabledForegroundColor">#FF888888</Color> |
|
13 |
|
|
14 |
<Color x:Key="SelectedBackgroundColor">#FFC5CBF9</Color> |
|
15 |
<Color x:Key="SelectedUnfocusedColor">#FFDDDDDD</Color> |
|
16 |
|
|
17 |
<Color x:Key="ControlLightColor">White</Color> |
|
18 |
<Color x:Key="ControlMediumColor">#FF7381F9</Color> |
|
19 |
<Color x:Key="ControlDarkColor">#FF211AA9</Color> |
|
20 |
|
|
21 |
<Color x:Key="ControlMouseOverColor">#FF3843C4</Color> |
|
22 |
<Color x:Key="ControlPressedColor">#FF211AA9</Color> |
|
23 |
|
|
24 |
|
|
25 |
<Color x:Key="GlyphColor">#FF444444</Color> |
|
26 |
<Color x:Key="GlyphMouseOver">sc#1, 0.004391443, 0.002428215, 0.242281124</Color> |
|
27 |
|
|
28 |
<!--Border colors--> |
|
29 |
<Color x:Key="BorderLightColor">#FFCCCCCC</Color> |
|
30 |
<Color x:Key="BorderMediumColor">#FF888888</Color> |
|
31 |
<Color x:Key="BorderDarkColor">#FF444444</Color> |
|
32 |
|
|
33 |
<Color x:Key="PressedBorderLightColor">#FF888888</Color> |
|
34 |
<Color x:Key="PressedBorderDarkColor">#FF444444</Color> |
|
35 |
|
|
36 |
<Color x:Key="DisabledBorderLightColor">#FFAAAAAA</Color> |
|
37 |
<Color x:Key="DisabledBorderDarkColor">#FF888888</Color> |
|
38 |
|
|
39 |
<Color x:Key="DefaultBorderBrushDarkColor">Black</Color> |
|
40 |
|
|
41 |
<!--Control-specific resources.--> |
|
42 |
<Color x:Key="HeaderTopColor">#FFC5CBF9</Color> |
|
43 |
<Color x:Key="DatagridCurrentCellBorderColor">Black</Color> |
|
44 |
<Color x:Key="SliderTrackDarkColor">#FFC5CBF9</Color> |
|
45 |
|
|
46 |
<Color x:Key="NavButtonFrameColor">#FF3843C4</Color> |
|
47 |
|
|
48 |
<LinearGradientBrush x:Key="MenuPopupBrush" |
|
49 |
EndPoint="0.5,1" |
|
50 |
StartPoint="0.5,0"> |
|
51 |
<GradientStop Color="{DynamicResource ControlLightColor}" |
|
52 |
Offset="0" /> |
|
53 |
<GradientStop Color="{DynamicResource ControlMediumColor}" |
|
54 |
Offset="0.5" /> |
|
55 |
<GradientStop Color="{DynamicResource ControlLightColor}" |
|
56 |
Offset="1" /> |
|
57 |
</LinearGradientBrush> |
|
58 |
|
|
59 |
<LinearGradientBrush x:Key="ProgressBarIndicatorAnimatedFill" |
|
60 |
StartPoint="0,0" |
|
61 |
EndPoint="1,0"> |
|
62 |
<LinearGradientBrush.GradientStops> |
|
63 |
<GradientStopCollection> |
|
64 |
<GradientStop Color="#000000FF" |
|
65 |
Offset="0" /> |
|
66 |
<GradientStop Color="#600000FF" |
|
67 |
Offset="0.4" /> |
|
68 |
<GradientStop Color="#600000FF" |
|
69 |
Offset="0.6" /> |
|
70 |
<GradientStop Color="#000000FF" |
|
71 |
Offset="1" /> |
|
72 |
</GradientStopCollection> |
|
73 |
</LinearGradientBrush.GradientStops> |
|
74 |
</LinearGradientBrush> |
|
75 |
<Style x:Key="ClearTextBoxStyle" TargetType="{x:Type TextBox}"> |
|
76 |
<Setter Property="SnapsToDevicePixels" |
|
77 |
Value="True" /> |
|
78 |
<Setter Property="OverridesDefaultStyle" |
|
79 |
Value="True" /> |
|
80 |
<Setter Property="KeyboardNavigation.TabNavigation" |
|
81 |
Value="None" /> |
|
82 |
<Setter Property="Text" Value="{x:Null}"/> |
|
83 |
<Setter Property="FocusVisualStyle" |
|
84 |
Value="{x:Null}" /> |
|
85 |
<Setter Property="MinWidth" |
|
86 |
Value="120" /> |
|
87 |
<Setter Property="MinHeight" |
|
88 |
Value="20" /> |
|
89 |
<Setter Property="AllowDrop" |
|
90 |
Value="true" /> |
|
91 |
<Setter Property="Template"> |
|
92 |
<Setter.Value> |
|
93 |
<ControlTemplate TargetType="{x:Type TextBox}"> |
|
94 |
<Border Name="Border" |
|
95 |
CornerRadius="0" |
|
96 |
Padding="0"> |
|
97 |
<Border.Background> |
|
98 |
<SolidColorBrush Color="{DynamicResource ControlLightColor}" /> |
|
99 |
</Border.Background> |
|
100 |
<Border.BorderBrush> |
|
101 |
<SolidColorBrush Color="{DynamicResource BorderMediumColor}" /> |
|
102 |
</Border.BorderBrush> |
|
103 |
<VisualStateManager.VisualStateGroups> |
|
104 |
<VisualStateGroup x:Name="CommonStates"> |
|
105 |
<VisualState x:Name="Normal" /> |
|
106 |
<VisualState x:Name="Disabled"> |
|
107 |
<Storyboard> |
|
108 |
<ColorAnimationUsingKeyFrames Storyboard.TargetName="Border" |
|
109 |
Storyboard.TargetProperty="(Panel.Background). |
|
110 |
(SolidColorBrush.Color)"> |
|
111 |
<EasingColorKeyFrame KeyTime="0" |
|
112 |
Value="{StaticResource DisabledControlLightColor}" /> |
|
113 |
</ColorAnimationUsingKeyFrames> |
|
114 |
</Storyboard> |
|
115 |
</VisualState> |
|
116 |
<VisualState x:Name="ReadOnly"> |
|
117 |
<Storyboard> |
|
118 |
<ColorAnimationUsingKeyFrames Storyboard.TargetName="Border" |
|
119 |
Storyboard.TargetProperty="(Panel.Background). |
|
120 |
(SolidColorBrush.Color)"> |
|
121 |
<EasingColorKeyFrame KeyTime="0" |
|
122 |
Value="{StaticResource DisabledControlDarkColor}" /> |
|
123 |
</ColorAnimationUsingKeyFrames> |
|
124 |
</Storyboard> |
|
125 |
</VisualState> |
|
126 |
<VisualState x:Name="MouseOver" /> |
|
127 |
</VisualStateGroup> |
|
128 |
</VisualStateManager.VisualStateGroups> |
|
129 |
<Border BorderBrush="#DDE2E5" Background="Transparent" BorderThickness="1"> |
|
130 |
<Grid> |
|
131 |
<Grid.ColumnDefinitions> |
|
132 |
<ColumnDefinition/> |
|
133 |
<ColumnDefinition Width="Auto"/> |
|
134 |
</Grid.ColumnDefinitions> |
|
135 |
<ScrollViewer Margin="0" BorderThickness="0" x:Name="PART_ContentHost" /> |
|
136 |
<telerik:RadPathButton BorderThickness="0" Background="Transparent" Grid.Column="1" x:Name="ClearButton" |
|
137 |
PathGeometry="{telerik:RadGlyph Glyph={StaticResource GlyphClose}, Foreground=White}"> |
|
138 |
</telerik:RadPathButton> |
|
139 |
</Grid> |
|
140 |
</Border> |
|
141 |
</Border> |
|
142 |
<ControlTemplate.Triggers> |
|
143 |
<Trigger SourceName="ClearButton" Property="IsPressed" Value="True"> |
|
144 |
<Setter Property="Text" Value="{x:Null}"/> |
|
145 |
</Trigger> |
|
146 |
<Trigger Property="Text" Value="{x:Null}"> |
|
147 |
<Setter TargetName="ClearButton" Property="Visibility" Value="Collapsed"/> |
|
148 |
</Trigger> |
|
149 |
<Trigger Property="Text" Value=""> |
|
150 |
<Setter TargetName="ClearButton" Property="Visibility" Value="Collapsed"/> |
|
151 |
</Trigger> |
|
152 |
</ControlTemplate.Triggers> |
|
153 |
</ControlTemplate> |
|
154 |
</Setter.Value> |
|
155 |
</Setter> |
|
156 |
</Style> |
|
157 |
</ResourceDictionary> |
내보내기 Unified diff