C# Class Settings.mainForm

显示文件 Open project: Ezzpify/HourBoostr

Public Methods

Method Description
mainForm ( ) : System

Constructor Sets placeholder text for text controls

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Clean up any resources being used.

Private Methods

Method Description
InitializeComponent ( ) : void

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

RefreshAccountList ( ) : void

Adds all users to listbox

RefreshGameList ( ) : void

Refreshes the gameListBox and fills it with items from mActiveAccount

SaveAccountJson ( ) : void

Saves all accounts and exits the application

SaveCurrentAccount ( ) : void

If an active account is set, save the changes made to it from the controls

SelectFirstAccount ( ) : void

Selected the first account in account list box

SelectLastAccount ( ) : void

Selects the last account in account list box

SendMessage ( IntPtr hWnd, int msg, int wParam, [ lParam ) : int
accountListBoxMenu_Opening ( object sender, CancelEventArgs e ) : void

Cancels the opening of the menu if no listbox item is selected

accountListBox_MouseDown ( object sender, MouseEventArgs e ) : void

Allows for the contextMenu to open on right click

accountListBox_SelectedIndexChanged ( object sender, EventArgs e ) : void

Gets the user in list depending on accountListBox index

cbCommunity_CheckedChanged ( object sender, EventArgs e ) : void

Check if both Community and OnlineStatus are checked Then we can enable the Chat Response textbox

cbOnlineStatus_CheckedChanged ( object sender, EventArgs e ) : void

Check if both Community and OnlineStatus are checked Then we can enable the Chat Response textbox

gameListMenu_Opening ( object sender, CancelEventArgs e ) : void

Cancels the opening of the menu if no listbox item is selected

gameList_MouseDown ( object sender, MouseEventArgs e ) : void

Allows for the contextMenu to open on right click

lblFindGames_Click ( object sender, EventArgs e ) : void

Opens game finder form

lblFindGames_MouseEnter ( object sender, EventArgs e ) : void

lblFindGames set textcolor to blue to show that it's highlighted

lblFindGames_MouseLeave ( object sender, EventArgs e ) : void

lblFindGames set textcolor to blue to show that it's not highlighted

lblNewAccount_Click ( object sender, EventArgs e ) : void

Creates a new account in the list

lblRemoveLoginKey_Click ( object sender, EventArgs e ) : void

Remove the loginkey text

lblRemoveLoginKey_MouseEnter ( object sender, EventArgs e ) : void

lblRemoveLoginKey set textcolor to blue to show that it's highlighted

lblRemoveLoginKey_MouseLeave ( object sender, EventArgs e ) : void

lblRemoveLoginKey set textcolor to blue to show that it's not highlighted

lblStartBooster_Click ( object sender, EventArgs e ) : void

Starts HourBoostr if it exists in this folder

lblStartBooster_MouseEnter ( object sender, EventArgs e ) : void

lblStartBooster set textcolor to blue to show that it's highlighted

lblStartBooster_MouseLeave ( object sender, EventArgs e ) : void

lblStartBooster set textcolor to blue to show that it's not highlighted

mainForm_FormClosing ( object sender, FormClosingEventArgs e ) : void

Save settings when form is closed

mainForm_Load ( object sender, EventArgs e ) : void

Form load Finds Settings.json and loads it

removeAccountToolStripMenuItem_Click ( object sender, EventArgs e ) : void

accountListBoxMenu remove button event Deletes selected account

removeToolStripMenuItem_Click ( object sender, EventArgs e ) : void

Removes an gameid from gameList box

txtGameItem_KeyDown ( object sender, KeyEventArgs e ) : void

Adds a game id to the game list

txtLoginKey_KeyPress ( object sender, KeyPressEventArgs e ) : void

Prevents any typing in loginkey textbox Not using ReadOnly because I don't like how it greys it out Also PlaceHolder text won't work if readonly

txtResponse_TextChanged ( object sender, EventArgs e ) : void

If user types anything we'll auto-enable community and show online Since they are needed to respond

txtUsername_Leave ( object sender, EventArgs e ) : void

Updates the listbox account name when user leaves username control

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

mainForm() public method

Constructor Sets placeholder text for text controls
public mainForm ( ) : System
return System