C# Class Sharpcraft.Forms.SteamGUI

显示文件 Open project: SijmenSchoon/Sharpcraft Class Usage Examples

Public Methods

Method Description
SteamGUI ( ) : System

Initializes a new Steam GUI.

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Clean up any resources being used.

Private Methods

Method Description
FriendListSelectedIndexChanged ( object sender, EventArgs e ) : void

FriendList SelectedIndexChanged handler, verifies valid selection and that selected friend is online. If validation is successful, the send button is enabled, otherwise it is disabled.

InitializeComponent ( ) : void

Required method for Designer support - do not modify the contents of this method with the code editor.

MinecraftDataValid ( ) : bool
SendButtonClick ( object sender, EventArgs e ) : void

SendButton click handler. Sends a message to currently selected Steam friend with Minecraft server info.

SetNewData ( string name, string status, int count, int onlineCount, IEnumerable friends ) : void

Updates the friend list with new data.

The name of the currently logged in user might change frequently, that's why it needs to be refreshed.

SteamClose ( ) : void

Handler for SteamClose event.

SteamGuiFormClosed ( object sender, FormClosedEventArgs e ) : void

SteamGUI FormClosed handler, logs to logger that form has closed.

SteamGuiFormClosing ( object sender, FormClosingEventArgs e ) : void

SteamGUI FormClosing handler, unregisters all registered events.

UpdateData ( SteamFriendsEventArgs e ) : void

Update the friend list with new data.

This method is used as event handler, normal updating should be done with the SetNewData method.

UpdateMinecraftdata ( SteamMinecraftDataEventArgs e ) : void

Method Details

Dispose() protected method

Clean up any resources being used.
protected Dispose ( bool disposing ) : void
disposing bool true if managed resources should be disposed; otherwise, false.
return void

SteamGUI() public method

Initializes a new Steam GUI.
public SteamGUI ( ) : System
return System