|
9 | 9 | mc:Ignorable="d" |
10 | 10 | Title="Magpie" ResizeMode="CanMinimize" WindowStartupLocation="CenterScreen" |
11 | 11 | Closing="Window_Closing" SourceInitialized="Window_SourceInitialized" StateChanged="Window_StateChanged" HorizontalAlignment="Left" VerticalAlignment="Top" SizeToContent="WidthAndHeight"> |
12 | | - <StackPanel Margin="15, 10"> |
| 12 | + <StackPanel Margin="20,20"> |
13 | 13 | <StackPanel.Resources> |
14 | 14 | <local:NotifyIconLeftClickCommand x:Key="NotifyIconLeftClickCommand" /> |
15 | 15 | </StackPanel.Resources> |
|
54 | 54 | </ContextMenu> |
55 | 55 | </tb:TaskbarIcon.ContextMenu> |
56 | 56 | </tb:TaskbarIcon> |
| 57 | + <Grid> |
| 58 | + <Grid.ColumnDefinitions> |
| 59 | + <ColumnDefinition Width="Auto"/> |
| 60 | + <ColumnDefinition Width="1*"/> |
| 61 | + <ColumnDefinition Width="Auto"/> |
| 62 | + </Grid.ColumnDefinitions> |
| 63 | + |
| 64 | + <Label Margin="0" Content="{x:Static p:Resources.Hotkey}" HorizontalAlignment="Right" VerticalAlignment="Center" Padding="0,5,5,5"/> |
| 65 | + <TextBox x:Name="txtHotkey" Grid.Column="1" Margin="10,0" VerticalAlignment="Center" Padding="1,3" TextChanged="TxtHotkey_TextChanged" > |
| 66 | + <TextBox.ContextMenu> |
| 67 | + <ContextMenu/> |
| 68 | + </TextBox.ContextMenu> |
| 69 | + </TextBox> |
| 70 | + <Button Content="{x:Static p:Resources.Scale_After_5S}" Name="btnScale" Click="BtnScale_Click" Grid.Column="2" HorizontalAlignment="Right" Margin="0" VerticalAlignment="Center" Padding="10,3"/> |
57 | 71 |
|
| 72 | + </Grid> |
58 | 73 | <Grid VerticalAlignment="Top"> |
59 | 74 | <Grid.Resources> |
60 | 75 | <Style TargetType="ComboBox" BasedOn="{StaticResource ComboBox}"> |
61 | 76 | <Setter Property="Grid.Column" Value="1" /> |
62 | 77 | <Setter Property="Margin" Value="10,0" /> |
63 | 78 | <Setter Property="VerticalAlignment" Value="Center" /> |
| 79 | + <Setter Property="Padding" Value="6,5,5,5" /> |
64 | 80 | </Style> |
65 | 81 | <Style TargetType="Label" x:Key="Col0"> |
66 | 82 | <Setter Property="Grid.Column" Value="0" /> |
|
71 | 87 |
|
72 | 88 | <Grid.ColumnDefinitions> |
73 | 89 | <ColumnDefinition Width="Auto"/> |
74 | | - <ColumnDefinition Width="1*" MinWidth="200"/> |
| 90 | + <ColumnDefinition Width="1*" MinWidth="220"/> |
75 | 91 | <ColumnDefinition Width="Auto"/> |
76 | 92 | </Grid.ColumnDefinitions> |
77 | 93 | <Grid.RowDefinitions> |
78 | 94 | <RowDefinition /> |
79 | 95 | <RowDefinition/> |
80 | 96 | <RowDefinition/> |
81 | | - <RowDefinition/> |
82 | 97 | </Grid.RowDefinitions> |
83 | 98 |
|
84 | | - <Label Style="{StaticResource Col0}" Content="{x:Static p:Resources.Hotkey}" VerticalAlignment="Top" Margin="0,5,0,0" Padding="0,5,5,5"/> |
85 | | - <TextBox x:Name="txtHotkey" Grid.Column="1" Margin="10,5,10,0" VerticalAlignment="Top" Padding="1,3" TextChanged="TxtHotkey_TextChanged" > |
86 | | - <TextBox.ContextMenu> |
87 | | - <ContextMenu/> |
88 | | - </TextBox.ContextMenu> |
89 | | - </TextBox> |
90 | | - <Button Content="{x:Static p:Resources.Scale_After_5S}" Name="btnScale" Click="BtnScale_Click" Grid.Column="2" HorizontalAlignment="Right" Margin="0,5,0,0" VerticalAlignment="Top" Padding="10,3"/> |
91 | | - |
92 | | - <Label Style="{StaticResource Col0}" Content="{x:Static p:Resources.Scaling_Mode}" Grid.Row="1" VerticalAlignment="Center" Margin="0,20,0,0" Padding="0,5,5,5" /> |
93 | | - <ComboBox Name="cbbScaleMode" Grid.Row="1" SelectionChanged="CbbScaleMode_SelectionChanged" Margin="10,20,10,0" /> |
| 99 | + <Label Style="{StaticResource Col0}" Content="{x:Static p:Resources.Scaling_Mode}" Grid.Row="0" VerticalAlignment="Center" Margin="0,20,0,0" Padding="0,5,5,5" /> |
| 100 | + <ComboBox Name="cbbScaleMode" Grid.Row="0" SelectionChanged="CbbScaleMode_SelectionChanged" Margin="5,20,0,0" /> |
94 | 101 |
|
95 | | - <Label Style="{StaticResource Col0}" Content="{x:Static p:Resources.Capture_Mode}" Grid.Row="2" VerticalAlignment="Top" Margin="0,9.667,0.333,0" Padding="0,5,5,5"/> |
96 | | - <ComboBox Name="cbbCaptureMode" Grid.Row="2" SelectionChanged="CbbCaptureMode_SelectionChanged" Margin="10,10,10,0"> |
| 102 | + <Label Style="{StaticResource Col0}" Content="{x:Static p:Resources.Capture_Mode}" Grid.Row="1" VerticalAlignment="Top" Margin="0,15,0,0" Padding="0,5,5,5"/> |
| 103 | + <ComboBox Name="cbbCaptureMode" Grid.Row="1" SelectionChanged="CbbCaptureMode_SelectionChanged" Margin="5,15,0,0"> |
97 | 104 | <ComboBoxItem Content="WinRT Capture" /> |
98 | 105 | <ComboBoxItem Content="GDI" /> |
99 | 106 | </ComboBox> |
100 | 107 |
|
101 | | - <Label Style="{StaticResource Col0}" Content="{x:Static p:Resources.Injection_Mode}" Grid.Row="3" VerticalAlignment="Center" Margin="0,10,0,0" Padding="0,5,5,5"/> |
102 | | - <ComboBox Name="cbbInjectMode" Grid.Row="3" SelectionChanged="CbbInjectMode_SelectionChanged" Margin="10,10,10,0"> |
| 108 | + <Label Style="{StaticResource Col0}" Content="{x:Static p:Resources.Injection_Mode}" Grid.Row="2" VerticalAlignment="Center" Margin="0,15,0,0" Padding="0,5,5,5"/> |
| 109 | + <ComboBox Name="cbbInjectMode" Grid.Row="2" SelectionChanged="CbbInjectMode_SelectionChanged" Margin="5,15,0,0"> |
103 | 110 | <ComboBoxItem Content="{x:Static p:Resources.No_Injection}" /> |
104 | 111 | <ComboBoxItem Content="{x:Static p:Resources.Runtime_Injection}" /> |
105 | 112 | <ComboBoxItem Content="{x:Static p:Resources.Injection_At_Startup}" /> |
106 | 113 | </ComboBox> |
107 | 114 | </Grid> |
108 | 115 |
|
109 | | - <Grid Margin="0,20,0,0"> |
| 116 | + <Grid x:Name="gridAutoRestore" Margin="0,20,0,0" Visibility="Collapsed"> |
110 | 117 | <Grid.ColumnDefinitions> |
111 | | - <ColumnDefinition /> |
| 118 | + <ColumnDefinition Width="1*" /> |
112 | 119 | <ColumnDefinition Width="Auto" /> |
113 | 120 | </Grid.ColumnDefinitions> |
114 | | - <Grid x:Name="gridAutoRestore" Visibility="Hidden"> |
115 | | - <Grid.ColumnDefinitions> |
116 | | - <ColumnDefinition /> |
117 | | - <ColumnDefinition Width="Auto" /> |
118 | | - </Grid.ColumnDefinitions> |
119 | | - <TextBlock x:Name="tbCurWndTitle" Margin="0" Text="Current_Window:" VerticalAlignment="Center" TextTrimming="CharacterEllipsis" MaxWidth="250"/> |
120 | | - <Button Content="取消" Margin="5,0,0,0" VerticalAlignment="Center" Padding="5,2" Click="BtnCancelRestore_Click" Grid.Column="1"/> |
| 121 | + <Grid x:Name="gridCurrentWnd"> |
| 122 | + <TextBlock x:Name="tbCurWndTitle" Margin="0" Text="Current_Window: " VerticalAlignment="Center" TextTrimming="CharacterEllipsis" MaxWidth="{Binding ElementName=gridCurrentWnd, Path=ActualWidth}" /> |
121 | 123 | </Grid> |
122 | | - |
123 | | - <Button Click="BtnOptions_Click" Margin="10,0,0,0" VerticalAlignment="Center" Padding="10,5" Grid.Column="1" HorizontalAlignment="Right"> |
124 | | - <StackPanel Orientation="Horizontal"> |
125 | | - <Label FontFamily="Segoe MDL2 Assets" Content="" Padding="0" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" Margin="0" /> |
126 | | - <Label Content="{x:Static p:Resources.Options}" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" Padding="0" Margin="5,0,0,0" /> |
127 | | - </StackPanel> |
128 | | - </Button> |
| 124 | + <Button Content="取消" Margin="5,0,0,0" VerticalAlignment="Center" Padding="5,2" Click="BtnCancelRestore_Click" Grid.Column="1"/> |
129 | 125 | </Grid> |
| 126 | + |
| 127 | + <Button Click="BtnOptions_Click" Margin="0,20,0,0" VerticalAlignment="Center" Padding="10,5" Grid.Column="1" HorizontalAlignment="Right"> |
| 128 | + <StackPanel Orientation="Horizontal"> |
| 129 | + <Label FontFamily="Segoe MDL2 Assets" Content="" Padding="0" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" Margin="0" /> |
| 130 | + <Label Content="{x:Static p:Resources.Options}" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" Padding="0" Margin="5,0,0,0" /> |
| 131 | + </StackPanel> |
| 132 | + </Button> |
130 | 133 | </StackPanel> |
131 | 134 | </Window> |
0 commit comments