diff options
| author | LukePulverenti <luke.pulverenti@gmail.com> | 2013-02-23 10:58:08 -0500 |
|---|---|---|
| committer | LukePulverenti <luke.pulverenti@gmail.com> | 2013-02-23 10:58:08 -0500 |
| commit | 17c1fd576057bdd2d6aea517d733fe8af6e6b2ba (patch) | |
| tree | 660f47e816a8599aabdb7ee47f3cde64c72c3f4d /MediaBrowser.UI/Controls/WindowCommands.xaml.cs | |
| parent | 33ed929b526acbda696f00f5966917ebd6a9ded2 (diff) | |
moved ui to it's own repo
Diffstat (limited to 'MediaBrowser.UI/Controls/WindowCommands.xaml.cs')
| -rw-r--r-- | MediaBrowser.UI/Controls/WindowCommands.xaml.cs | 82 |
1 files changed, 0 insertions, 82 deletions
diff --git a/MediaBrowser.UI/Controls/WindowCommands.xaml.cs b/MediaBrowser.UI/Controls/WindowCommands.xaml.cs deleted file mode 100644 index e285cced1..000000000 --- a/MediaBrowser.UI/Controls/WindowCommands.xaml.cs +++ /dev/null @@ -1,82 +0,0 @@ -using System.Windows; -using System.Windows.Controls; - -namespace MediaBrowser.UI.Controls -{ - /// <summary> - /// Interaction logic for WindowCommands.xaml - /// </summary> - public partial class WindowCommands : UserControl - { - /// <summary> - /// Gets the parent window. - /// </summary> - /// <value>The parent window.</value> - public Window ParentWindow - { - get { return TreeHelper.TryFindParent<Window>(this); } - } - - /// <summary> - /// Initializes a new instance of the <see cref="WindowCommands" /> class. - /// </summary> - public WindowCommands() - { - InitializeComponent(); - Loaded += WindowCommandsLoaded; - } - - /// <summary> - /// Windows the commands loaded. - /// </summary> - /// <param name="sender">The sender.</param> - /// <param name="e">The <see cref="RoutedEventArgs" /> instance containing the event data.</param> - void WindowCommandsLoaded(object sender, RoutedEventArgs e) - { - CloseApplicationButton.Click += CloseApplicationButtonClick; - MinimizeApplicationButton.Click += MinimizeApplicationButtonClick; - MaximizeApplicationButton.Click += MaximizeApplicationButtonClick; - UndoMaximizeApplicationButton.Click += UndoMaximizeApplicationButtonClick; - } - - /// <summary> - /// Undoes the maximize application button click. - /// </summary> - /// <param name="sender">The sender.</param> - /// <param name="e">The <see cref="RoutedEventArgs" /> instance containing the event data.</param> - void UndoMaximizeApplicationButtonClick(object sender, RoutedEventArgs e) - { - ParentWindow.WindowState = WindowState.Normal; - } - - /// <summary> - /// Maximizes the application button click. - /// </summary> - /// <param name="sender">The sender.</param> - /// <param name="e">The <see cref="RoutedEventArgs" /> instance containing the event data.</param> - void MaximizeApplicationButtonClick(object sender, RoutedEventArgs e) - { - ParentWindow.WindowState = WindowState.Maximized; - } - - /// <summary> - /// Minimizes the application button click. - /// </summary> - /// <param name="sender">The sender.</param> - /// <param name="e">The <see cref="RoutedEventArgs" /> instance containing the event data.</param> - void MinimizeApplicationButtonClick(object sender, RoutedEventArgs e) - { - ParentWindow.WindowState = WindowState.Minimized; - } - - /// <summary> - /// Closes the application button click. - /// </summary> - /// <param name="sender">The sender.</param> - /// <param name="e">The <see cref="RoutedEventArgs" /> instance containing the event data.</param> - void CloseApplicationButtonClick(object sender, RoutedEventArgs e) - { - App.Instance.Shutdown(); - } - } -} |
