githubのコードからのfolk
Revision | e83c570f4856660bbb120998546333aa4308a43f (tree) |
---|---|
Time | 2011-02-27 01:24:38 |
Author | sr55 <sr55@b64f...> |
Commiter | sr55 |
WinGui:
- Started designing the Picture Settings Panel
- Added a WindowManager.
git-svn-id: svn://localhost/HandBrake/trunk@3810 b64f7644-9d1e-0410-96f1-a4d463321fa5
@@ -5,8 +5,10 @@ | ||
5 | 5 | |
6 | 6 | namespace HandBrakeWPF |
7 | 7 | { |
8 | + using Caliburn.PresentationFramework; | |
8 | 9 | using Caliburn.PresentationFramework.ApplicationModel; |
9 | 10 | |
11 | + using HandBrakeWPF.Services; | |
10 | 12 | using HandBrakeWPF.ViewModels; |
11 | 13 | |
12 | 14 | /// <summary> |
@@ -37,12 +39,18 @@ namespace HandBrakeWPF | ||
37 | 39 | /// </returns> |
38 | 40 | protected override object CreateRootModel() |
39 | 41 | { |
40 | - var binder = (DefaultBinder)Container.GetInstance<IBinder>(); | |
42 | + var binder = (DefaultBinder)Container.GetInstance<DefaultBinder>(); | |
41 | 43 | |
42 | 44 | binder.EnableBindingConventions(); |
43 | 45 | binder.EnableMessageConventions(); |
44 | 46 | |
45 | - return new MainViewModel(); | |
47 | + return Container.GetInstance<MainViewModel>(); | |
48 | + } | |
49 | + | |
50 | + | |
51 | + protected override void ConfigurePresentationFramework(PresentationFrameworkModule module) | |
52 | + { | |
53 | + module.UsingWindowManager<WindowManager>(); | |
46 | 54 | } |
47 | 55 | } |
48 | 56 | } |
@@ -61,12 +61,16 @@ | ||
61 | 61 | <Reference Include="WindowsBase" /> |
62 | 62 | <Reference Include="PresentationCore" /> |
63 | 63 | <Reference Include="PresentationFramework" /> |
64 | + <Reference Include="WPFToolkit.Extended"> | |
65 | + <HintPath>..\libraries\WPFToolkit.Extended.dll</HintPath> | |
66 | + </Reference> | |
64 | 67 | </ItemGroup> |
65 | 68 | <ItemGroup> |
66 | 69 | <ApplicationDefinition Include="App.xaml"> |
67 | 70 | <Generator>MSBuild:Compile</Generator> |
68 | 71 | <SubType>Designer</SubType> |
69 | 72 | </ApplicationDefinition> |
73 | + <Compile Include="Services\WindowManager.cs" /> | |
70 | 74 | <Compile Include="ViewModels\AboutViewModel.cs" /> |
71 | 75 | <Compile Include="ViewModels\AddPresetViewModel.cs" /> |
72 | 76 | <Compile Include="ViewModels\PreviewViewModel.cs" /> |
@@ -205,7 +209,6 @@ | ||
205 | 209 | </ItemGroup> |
206 | 210 | <ItemGroup> |
207 | 211 | <Folder Include="Model\" /> |
208 | - <Folder Include="Services\" /> | |
209 | 212 | </ItemGroup> |
210 | 213 | <ItemGroup> |
211 | 214 | <Resource Include="Views\Images\ActivityWindow.png" /> |
@@ -0,0 +1,40 @@ | ||
1 | +namespace HandBrakeWPF.Services | |
2 | +{ | |
3 | + using System; | |
4 | + using System.Windows; | |
5 | + | |
6 | + using Caliburn.PresentationFramework.ApplicationModel; | |
7 | + | |
8 | + public class WindowManager : DefaultWindowManager, IWindowManager | |
9 | + { | |
10 | + | |
11 | + public WindowManager(IViewStrategy viewStrategy, IBinder binder) | |
12 | + | |
13 | + : base(viewStrategy, binder) | |
14 | + { | |
15 | + } | |
16 | + | |
17 | + //Display a view in a dialog (modal) window | |
18 | + public new bool? ShowDialog(object rootModel, object context, Action<ISubordinate, Action> handleShutdownModel) | |
19 | + { | |
20 | + var window = base.CreateWindow(rootModel, true, context, handleShutdownModel); | |
21 | + window.WindowStartupLocation = WindowStartupLocation.CenterScreen; | |
22 | + window.WindowStyle = WindowStyle.ToolWindow; | |
23 | + window.ResizeMode = ResizeMode.NoResize; | |
24 | + window.Title = ((IPresenter)rootModel).DisplayName; | |
25 | + return window.ShowDialog(); | |
26 | + } | |
27 | + | |
28 | + //Display a view in a popup (non-modal) window | |
29 | + public new void Show(object rootModel, object context, Action<ISubordinate, Action> handleShutdownModel) | |
30 | + { | |
31 | + var window = base.CreateWindow(rootModel, false, context, handleShutdownModel); | |
32 | + window.WindowStartupLocation = WindowStartupLocation.CenterScreen; | |
33 | + window.Title = ((IPresenter)rootModel).DisplayName; | |
34 | + window.ResizeMode = ResizeMode.NoResize; | |
35 | + window.Show(); | |
36 | + } | |
37 | + | |
38 | + } | |
39 | + | |
40 | +} |
@@ -5,10 +5,17 @@ | ||
5 | 5 | |
6 | 6 | namespace HandBrakeWPF.ViewModels |
7 | 7 | { |
8 | + using Microsoft.Practices.ServiceLocation; | |
9 | + | |
8 | 10 | /// <summary> |
9 | 11 | /// The About View Model |
10 | 12 | /// </summary> |
11 | 13 | public class AboutViewModel : ViewModelBase |
12 | 14 | { |
15 | + public AboutViewModel(IServiceLocator locator) | |
16 | + : base(locator) | |
17 | + { | |
18 | + } | |
19 | + | |
13 | 20 | } |
14 | 21 | } |
@@ -5,10 +5,16 @@ | ||
5 | 5 | |
6 | 6 | namespace HandBrakeWPF.ViewModels |
7 | 7 | { |
8 | + using Microsoft.Practices.ServiceLocation; | |
9 | + | |
8 | 10 | /// <summary> |
9 | 11 | /// The Add Preset View Model |
10 | 12 | /// </summary> |
11 | 13 | public class AddPresetViewModel : ViewModelBase |
12 | 14 | { |
15 | + public AddPresetViewModel(IServiceLocator locator) | |
16 | + : base(locator) | |
17 | + { | |
18 | + } | |
13 | 19 | } |
14 | 20 | } |
@@ -16,6 +16,8 @@ namespace HandBrakeWPF.ViewModels | ||
16 | 16 | using HandBrake.ApplicationServices.Services; |
17 | 17 | using HandBrake.ApplicationServices.Services.Interfaces; |
18 | 18 | |
19 | + using Microsoft.Practices.ServiceLocation; | |
20 | + | |
19 | 21 | /// <summary> |
20 | 22 | /// HandBrakes Main Window |
21 | 23 | /// </summary> |
@@ -55,10 +57,10 @@ namespace HandBrakeWPF.ViewModels | ||
55 | 57 | |
56 | 58 | #endregion |
57 | 59 | |
58 | - /// <summary> | |
59 | - /// Initializes a new instance of the <see cref="MainViewModel"/> class. | |
60 | - /// </summary> | |
61 | - public MainViewModel() | |
60 | + #region Properties | |
61 | + | |
62 | + public MainViewModel(IServiceLocator locator) | |
63 | + : base(locator) | |
62 | 64 | { |
63 | 65 | // Setup Services (TODO - Bring Castle back into the project to wire these up for us) |
64 | 66 | this.scanService = File.Exists("hb.dll") ? (IScan)new LibScan() : new ScanService(); |
@@ -79,7 +81,6 @@ namespace HandBrakeWPF.ViewModels | ||
79 | 81 | this.queueProcessor.EncodeService.EncodeStatusChanged += this.EncodeStatusChanged; |
80 | 82 | } |
81 | 83 | |
82 | - #region Properties | |
83 | 84 | /// <summary> |
84 | 85 | /// Gets or sets TestProperty. |
85 | 86 | /// </summary> |
@@ -185,6 +186,14 @@ namespace HandBrakeWPF.ViewModels | ||
185 | 186 | base.Shutdown(); |
186 | 187 | } |
187 | 188 | |
189 | + | |
190 | + #region Menu and Taskbar | |
191 | + | |
192 | + public void AboutApplication() | |
193 | + { | |
194 | + this.ShowDialog<AboutViewModel>(); | |
195 | + } | |
196 | + | |
188 | 197 | /// <summary> |
189 | 198 | /// Shutdown the Application |
190 | 199 | /// </summary> |
@@ -193,6 +202,9 @@ namespace HandBrakeWPF.ViewModels | ||
193 | 202 | Application.Current.Shutdown(); |
194 | 203 | } |
195 | 204 | |
205 | + #endregion | |
206 | + | |
207 | + | |
196 | 208 | #region Event Handlers |
197 | 209 | /// <summary> |
198 | 210 | /// Handle the Scan Status Changed Event. |
@@ -5,10 +5,16 @@ | ||
5 | 5 | |
6 | 6 | namespace HandBrakeWPF.ViewModels |
7 | 7 | { |
8 | + using Microsoft.Practices.ServiceLocation; | |
9 | + | |
8 | 10 | /// <summary> |
9 | 11 | /// The Options View Model |
10 | 12 | /// </summary> |
11 | 13 | public class OptionsViewModel : ViewModelBase |
12 | 14 | { |
15 | + public OptionsViewModel(IServiceLocator locator) | |
16 | + : base(locator) | |
17 | + { | |
18 | + } | |
13 | 19 | } |
14 | 20 | } |
@@ -5,10 +5,16 @@ | ||
5 | 5 | |
6 | 6 | namespace HandBrakeWPF.ViewModels |
7 | 7 | { |
8 | + using Microsoft.Practices.ServiceLocation; | |
9 | + | |
8 | 10 | /// <summary> |
9 | 11 | /// The About View Model |
10 | 12 | /// </summary> |
11 | 13 | public class PreviewViewModel : ViewModelBase |
12 | 14 | { |
15 | + public PreviewViewModel(IServiceLocator locator) | |
16 | + : base(locator) | |
17 | + { | |
18 | + } | |
13 | 19 | } |
14 | 20 | } |
@@ -5,10 +5,16 @@ | ||
5 | 5 | |
6 | 6 | namespace HandBrakeWPF.ViewModels |
7 | 7 | { |
8 | + using Microsoft.Practices.ServiceLocation; | |
9 | + | |
8 | 10 | /// <summary> |
9 | 11 | /// The Preview View Model |
10 | 12 | /// </summary> |
11 | 13 | public class QueueViewModel : ViewModelBase |
12 | 14 | { |
15 | + public QueueViewModel(IServiceLocator locator) | |
16 | + : base(locator) | |
17 | + { | |
18 | + } | |
13 | 19 | } |
14 | 20 | } |
@@ -1,12 +1,35 @@ | ||
1 | 1 | namespace HandBrakeWPF.ViewModels |
2 | 2 | { |
3 | - using Caliburn.Core; | |
4 | 3 | using Caliburn.PresentationFramework.ApplicationModel; |
5 | 4 | |
5 | + using Microsoft.Practices.ServiceLocation; | |
6 | + | |
6 | 7 | /// <summary> |
7 | 8 | /// A Base Class for the View Models which contains reusable code. |
8 | 9 | /// </summary> |
9 | 10 | public class ViewModelBase : MultiPresenterManager |
10 | 11 | { |
12 | + protected IServiceLocator Locator { get; private set; } | |
13 | + | |
14 | + public ViewModelBase(IServiceLocator locator) | |
15 | + { | |
16 | + this.Locator = locator; | |
17 | + } | |
18 | + | |
19 | + public void Show<T>() where T : IPresenter | |
20 | + { | |
21 | + this.ShutdownCurrent(); | |
22 | + this.Open(Locator.GetInstance<T>()); | |
23 | + } | |
24 | + | |
25 | + public void ShowDialog<T>() where T : IPresenter | |
26 | + { | |
27 | + Locator.GetInstance<IWindowManager>().ShowDialog(Locator.GetInstance<T>()); | |
28 | + } | |
29 | + | |
30 | + public void Popup<T>() where T : IPresenter | |
31 | + { | |
32 | + Locator.GetInstance<IWindowManager>().Show(Locator.GetInstance<T>()); | |
33 | + } | |
11 | 34 | } |
12 | 35 | } |
@@ -1,7 +1,6 @@ | ||
1 | 1 | <Window x:Class="HandBrakeWPF.Views.AboutView" |
2 | 2 | xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
3 | - xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
4 | - Title="AboutView" Height="268" Width="511"> | |
3 | + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:PresentationFramework="clr-namespace:Caliburn.PresentationFramework;assembly=Caliburn.PresentationFramework" Title="AboutView" Height="268" Width="511"> | |
5 | 4 | |
6 | 5 | <StackPanel Orientation="Horizontal"> |
7 | 6 | <Image Source="Images/logo64.png" Width="64" Height="64" SnapsToDevicePixels="True" Margin="10,10,10,10" HorizontalAlignment="Left" VerticalAlignment="Top" /> |
@@ -11,15 +10,16 @@ | ||
11 | 10 | <Label Content="Copyright 2003-2011 HandBrake Team" /> |
12 | 11 | |
13 | 12 | <Label Content="License:" /> |
14 | - <TextBox IsEnabled="False" Width="380" Height="100" TextWrapping="Wrap" VerticalScrollBarVisibility="Auto" Margin="10,0,10,10"> | |
13 | + <TextBox Width="380" Height="100" IsReadOnly="True" TextWrapping="Wrap" VerticalScrollBarVisibility="Auto" Margin="10,0,10,10"> | |
15 | 14 | This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. |
16 | 15 | |
17 | 16 | This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. |
18 | 17 | |
19 | 18 | You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
20 | 19 | </TextBox> |
21 | - | |
22 | - <Button Content="OK" HorizontalAlignment="Right" Padding="10,2" Margin="0,0,10,10"></Button> | |
20 | + | |
21 | + <Button Content="OK" PresentationFramework:Message.Attach="[Event Click] = [Action Close]" | |
22 | + HorizontalAlignment="Right" Padding="10,2" Margin="0,0,10,10" /> | |
23 | 23 | |
24 | 24 | </StackPanel> |
25 | 25 |
@@ -3,9 +3,100 @@ | ||
3 | 3 | xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
4 | 4 | xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" |
5 | 5 | xmlns:d="http://schemas.microsoft.com/expression/blend/2008" |
6 | - mc:Ignorable="d" | |
7 | - d:DesignHeight="300" d:DesignWidth="300"> | |
8 | - <Grid Background="Beige"> | |
6 | + xmlns:Controls="clr-namespace:Microsoft.Windows.Controls;assembly=WPFToolkit.Extended" | |
7 | + > | |
8 | + | |
9 | + <StackPanel Orientation="Horizontal" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"> | |
10 | + | |
11 | + <!-- Size Panel--> | |
12 | + <StackPanel Name="SizePanel" Orientation="Vertical" > | |
13 | + <Label Content="Size" FontWeight="Bold" /> | |
14 | + | |
15 | + <!-- Row 1--> | |
16 | + <StackPanel Orientation="Horizontal" Margin="5,0,5,0"> | |
17 | + <Label Content="Source" Grid.Row="0" Grid.Column="0" /> | |
18 | + <Label Content="---" Name="sourceResolution" Grid.Row="0" Grid.Column="1" /> | |
19 | + </StackPanel> | |
20 | + | |
21 | + <!-- Row 2--> | |
22 | + <StackPanel Orientation="Horizontal" Margin="5,0,5,0"> | |
23 | + <Label Content="Width:" Grid.Row="1" Grid.Column="0" /> | |
24 | + <Controls:NumericUpDown Name="width" Minimum="0" Grid.Row="1" Grid.Column="1" Width="45" /> | |
25 | + <Label Content="Height:" Grid.Row="1" Grid.Column="2" /> | |
26 | + <Controls:NumericUpDown Name="height" Minimum="0" Grid.Row="1" Grid.Column="3" Width="45" /> | |
27 | + <CheckBox Content="Keep Aspect Ratio" VerticalAlignment="Center" Margin="5,0,0,0" /> | |
28 | + </StackPanel> | |
29 | + | |
30 | + <!-- Row 3--> | |
31 | + <Grid Margin="5,15,5,0"> | |
32 | + <Grid.RowDefinitions> | |
33 | + <RowDefinition Height="Auto" /> | |
34 | + <RowDefinition Height="Auto" /> | |
35 | + <RowDefinition Height="Auto" /> | |
36 | + <RowDefinition Height="Auto" /> | |
37 | + <RowDefinition Height="Auto" /> | |
38 | + <RowDefinition Height="Auto" /> | |
39 | + </Grid.RowDefinitions> | |
40 | + | |
41 | + <Grid.ColumnDefinitions> | |
42 | + <ColumnDefinition Width="Auto" /> | |
43 | + <ColumnDefinition Width="Auto" /> | |
44 | + </Grid.ColumnDefinitions> | |
45 | + | |
46 | + <Label Content="Anamorphic:" Grid.Row="0" Grid.Column="0" /> | |
47 | + <Label Content="Modulus:" Grid.Row="1" Grid.Column="0" /> | |
48 | + <Label Content="Display Width:" Grid.Row="2" Grid.Column="0" /> | |
49 | + <Label Content="PAR Width:" Grid.Row="3" Grid.Column="0" /> | |
50 | + <Label Content="PAR Height:" Grid.Row="4" Grid.Column="0" /> | |
51 | + <Label Content="Display Size:" Grid.Row="5" Grid.Column="0" /> | |
52 | + | |
53 | + <ComboBox Width="110" Grid.Row="0" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
54 | + <ComboBox Width="110" Grid.Row="1" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
55 | + <Controls:NumericUpDown Width="45" Grid.Row="2" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
56 | + <Controls:NumericUpDown Width="45" Grid.Row="3" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
57 | + <Controls:NumericUpDown Width="45" Grid.Row="4" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
58 | + <Label Content="---" Grid.Row="5" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
59 | + </Grid> | |
60 | + </StackPanel> | |
61 | + | |
62 | + | |
63 | + <StackPanel Name="CropPanel" Margin="50,0,0,0" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"> | |
64 | + <Label Content="Cropping" FontWeight="Bold" /> | |
65 | + <RadioButton Content="Automatic" Margin="10,0,0,0"/> | |
66 | + <RadioButton Content="Custom" Margin="10,0,0,0" /> | |
9 | 67 | |
10 | - </Grid> | |
68 | + <Grid Margin="0,10,0,0"> | |
69 | + <Grid.RowDefinitions> | |
70 | + <RowDefinition Height="Auto" /> | |
71 | + <RowDefinition Height="Auto" /> | |
72 | + <RowDefinition Height="Auto" /> | |
73 | + <RowDefinition Height="Auto" /> | |
74 | + <RowDefinition Height="Auto" /> | |
75 | + </Grid.RowDefinitions> | |
76 | + | |
77 | + <Grid.ColumnDefinitions> | |
78 | + <ColumnDefinition Width="Auto" /> | |
79 | + <ColumnDefinition Width="Auto" /> | |
80 | + <ColumnDefinition Width="Auto" /> | |
81 | + <ColumnDefinition Width="Auto" /> | |
82 | + <ColumnDefinition Width="Auto" /> | |
83 | + </Grid.ColumnDefinitions> | |
84 | + | |
85 | + <Label Content="Top" Grid.Row="0" Grid.Column="2" VerticalAlignment="Center" /> | |
86 | + <Label Content="Bottom" Grid.Row="4" Grid.Column="2" VerticalAlignment="Center" /> | |
87 | + <Label Content="Left" Grid.Row="2" Grid.Column="0" HorizontalAlignment="Center" /> | |
88 | + <Label Content="Right" Grid.Row="2" Grid.Column="4" HorizontalAlignment="Center" /> | |
89 | + | |
90 | + <Controls:NumericUpDown Width="45" Grid.Row="1" Grid.Column="2" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
91 | + <Controls:NumericUpDown Width="45" Grid.Row="3" Grid.Column="2" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
92 | + <Controls:NumericUpDown Width="45" Grid.Row="2" Grid.Column="1" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
93 | + <Controls:NumericUpDown Width="45" Grid.Row="2" Grid.Column="3" HorizontalAlignment="Left" Margin="0,0,0,5" /> | |
94 | + | |
95 | + </Grid> | |
96 | + | |
97 | + | |
98 | + </StackPanel> | |
99 | + | |
100 | + | |
101 | + </StackPanel> | |
11 | 102 | </UserControl> |
@@ -18,26 +18,26 @@ | ||
18 | 18 | </MenuItem> |
19 | 19 | |
20 | 20 | <MenuItem Header="Tools"> |
21 | - <MenuItem Header="Show Queue" /> | |
22 | - <MenuItem Header="Activity Window" /> | |
21 | + <MenuItem Header="Show Queue" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
22 | + <MenuItem Header="Activity Window" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
23 | 23 | </MenuItem> |
24 | 24 | |
25 | 25 | <MenuItem Header="Presets"> |
26 | - <MenuItem Header="Reset Built-in Presets" /> | |
27 | - <MenuItem Header="Delete Built-in Presets" /> | |
26 | + <MenuItem Header="Reset Built-in Presets" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
27 | + <MenuItem Header="Delete Built-in Presets" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
28 | 28 | <Separator /> |
29 | - <MenuItem Header="Save As New Preset" /> | |
30 | - <MenuItem Header="Import" /> | |
31 | - <MenuItem Header="Export" /> | |
32 | - <MenuItem Header="Set as Default" /> | |
29 | + <MenuItem Header="Save As New Preset" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
30 | + <MenuItem Header="Import" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
31 | + <MenuItem Header="Export" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
32 | + <MenuItem Header="Set as Default" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
33 | 33 | </MenuItem> |
34 | 34 | |
35 | 35 | <MenuItem Header="Help"> |
36 | - <MenuItem Header="HandBrake User Guide" /> | |
36 | + <MenuItem Header="HandBrake User Guide" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
37 | 37 | <Separator /> |
38 | - <MenuItem Header="Check for Updates" /> | |
38 | + <MenuItem Header="Check for Updates" PresentationFramework:Message.Attach="[Event Click] = [Action ExitApplication]" /> | |
39 | 39 | <Separator /> |
40 | - <MenuItem Header="About..." /> | |
40 | + <MenuItem Header="About..." PresentationFramework:Message.Attach="[Event Click] = [Action AboutApplication]" /> | |
41 | 41 | </MenuItem> |
42 | 42 | </Menu> |
43 | 43 |
@@ -144,7 +144,7 @@ | ||
144 | 144 | <!-- Tab Control --> |
145 | 145 | <TabControl HorizontalAlignment="Left" VerticalAlignment="Stretch" Width="725" Height="330" Margin="10,10,10,10" Name="tabControl" > |
146 | 146 | <TabItem Header="Picture" Name="pictureTab"> |
147 | - <Views:PictureSettingsView></Views:PictureSettingsView> | |
147 | + <Views:PictureSettingsView x:Name="pictureSettingsView"></Views:PictureSettingsView> | |
148 | 148 | </TabItem> |
149 | 149 | <TabItem Header="Video Filters" Name="filtersTab"> |
150 | 150 | <Views:FiltersView></Views:FiltersView> |