C# Class Starboard.View.ScoreboardDisplay

Interaction logic for ScoreboardDisplay.xaml
Exibir arquivo Open project: ascendedguard/starboard-sc2 Class Usage Examples

Public Properties

Property Type Description
ScoreboardProperty System.Windows.DependencyProperty

Public Methods

Method Description
Hide ( ) : void

Overrides the original Hide function to support fading in cases where transparency is used.

ResetPosition ( ) : void

Resets the position of the window to the default location, centered on the primary monitor with a 10px offset from top.

ScoreboardDisplay ( ) : System

Initializes a new instance of the ScoreboardDisplay class.

SetViewModel ( ScoreboardControlViewModel vm ) : void

Sets the viewmodel for the window to another instance of ScoreboardControlViewModel

Show ( ) : void

Overrides the original Show function to support a fade-in effect in cases where transparency is used.

Protected Methods

Method Description
OnKeyDown ( KeyEventArgs e ) : void

Overrides the OnKeyDown event to handled hotkeys for this window.

OnMouseLeftButtonDown ( MouseButtonEventArgs e ) : void

Allows the window to be dragged if IsWindowMovable has been set.

Private Methods

Method Description
ApplyHotkey ( Key key, Starboard.Model.Player player ) : bool

Applies the hotkey for the attached key to the attached player.

CreatePlayerChangeField ( string binding ) : void

Creates a text field for typing the player name directly into the scoreboard. Clears the player name upon the hotkey press.

WindowLoaded ( object sender, RoutedEventArgs e ) : void

Resets the position of the window after it has completed loading.

Method Details

Hide() public method

Overrides the original Hide function to support fading in cases where transparency is used.
public Hide ( ) : void
return void

OnKeyDown() protected method

Overrides the OnKeyDown event to handled hotkeys for this window.
protected OnKeyDown ( KeyEventArgs e ) : void
e KeyEventArgs /// The event arguments. ///
return void

OnMouseLeftButtonDown() protected method

Allows the window to be dragged if IsWindowMovable has been set.
protected OnMouseLeftButtonDown ( MouseButtonEventArgs e ) : void
e MouseButtonEventArgs /// The event arguments. ///
return void

ResetPosition() public method

Resets the position of the window to the default location, centered on the primary monitor with a 10px offset from top.
public ResetPosition ( ) : void
return void

ScoreboardDisplay() public method

Initializes a new instance of the ScoreboardDisplay class.
public ScoreboardDisplay ( ) : System
return System

SetViewModel() public method

Sets the viewmodel for the window to another instance of ScoreboardControlViewModel
public SetViewModel ( ScoreboardControlViewModel vm ) : void
vm Starboard.ViewModel.ScoreboardControlViewModel /// The viewModel to apply. ///
return void

Show() public method

Overrides the original Show function to support a fade-in effect in cases where transparency is used.
public Show ( ) : void
return void

Property Details

ScoreboardProperty public_oe static_oe property

The scoreboard property.
public static DependencyProperty,System.Windows ScoreboardProperty
return System.Windows.DependencyProperty