- Changed the scripts output to use Path.Combine, instead of \\

- Renamed some functions to make it more clear what they do.
This commit is contained in:
gb.luke 2010-07-08 16:14:40 +00:00
parent d81ad92ff6
commit c89f193a9e
2 changed files with 12 additions and 12 deletions

View File

@ -117,7 +117,7 @@
this.Extrasbtn.TabIndex = 0;
this.Extrasbtn.Text = "Extras...";
this.Extrasbtn.UseVisualStyleBackColor = true;
this.Extrasbtn.Click += new System.EventHandler(this.button1_Click);
this.Extrasbtn.Click += new System.EventHandler(this.extrasMenuButton_Click);
//
// downloadstartbtn
//
@ -128,7 +128,7 @@
this.downloadstartbtn.TabIndex = 4;
this.downloadstartbtn.Text = "Start NUS Download!";
this.downloadstartbtn.UseVisualStyleBackColor = true;
this.downloadstartbtn.Click += new System.EventHandler(this.button3_Click);
this.downloadstartbtn.Click += new System.EventHandler(this.DownloadBtn_Click);
//
// statusbox
//
@ -175,7 +175,7 @@
this.databaseButton.TabIndex = 20;
this.databaseButton.Text = "Database...";
this.databaseButton.UseVisualStyleBackColor = true;
this.databaseButton.Click += new System.EventHandler(this.button4_Click);
this.databaseButton.Click += new System.EventHandler(this.DatabaseButton_Click);
//
// databaseStrip
//
@ -496,7 +496,7 @@
this.SaveProxyPwdBtn.TabIndex = 34;
this.SaveProxyPwdBtn.Text = "Save (This Session Only)";
this.SaveProxyPwdBtn.UseVisualStyleBackColor = true;
this.SaveProxyPwdBtn.Click += new System.EventHandler(this.button18_Click);
this.SaveProxyPwdBtn.Click += new System.EventHandler(this.SaveProxyPwdButton_Click);
//
// label14
//
@ -686,7 +686,7 @@
this.button3.TabIndex = 31;
this.button3.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.button3.UseVisualStyleBackColor = false;
this.button3.Click += new System.EventHandler(this.button3_Click_1);
this.button3.Click += new System.EventHandler(this.ClearStatusbox);
this.button3.MouseEnter += new System.EventHandler(this.button3_MouseEnter);
this.button3.MouseLeave += new System.EventHandler(this.button3_MouseLeave);
//

View File

@ -396,7 +396,7 @@ namespace NUS_Downloader
return Attributes[0].Value;
}
private void button1_Click(object sender, EventArgs e)
private void extrasMenuButton_Click(object sender, EventArgs e)
{
// Show extras menu
extrasStrip.Show(Extrasbtn, 2, (2+Extrasbtn.Height));
@ -784,7 +784,7 @@ namespace NUS_Downloader
return contentindices;
}
private void button3_Click(object sender, EventArgs e)
private void DownloadBtn_Click(object sender, EventArgs e)
{
if (titleidbox.Text == String.Empty)
{
@ -1584,7 +1584,7 @@ namespace NUS_Downloader
return false;
}*/
private void button4_Click(object sender, EventArgs e)
private void DatabaseButton_Click(object sender, EventArgs e)
{
// Open Database button menu...
databaseStrip.Show(databaseButton, 2, (2+databaseButton.Height));
@ -2171,7 +2171,7 @@ namespace NUS_Downloader
return array;
}
private void button3_Click_1(object sender, EventArgs e)
private void ClearStatusbox(object sender, EventArgs e)
{
// Clear Statusbox.text
statusbox.Text = "";
@ -2750,7 +2750,7 @@ namespace NUS_Downloader
}
string time = RemoveIllegalCharacters(DateTime.Now.ToShortTimeString());
File.WriteAllText(
String.Format(Path.Combine(CURRENT_DIR, "scripts\\{0}_Update_{1}_{2}_{3} at {4}.nus"), RegionID,
String.Format(Path.Combine(CURRENT_DIR, Path.Combine("scripts","{0}_Update_{1}_{2}_{3} at {4}.nus")), RegionID,
DateTime.Now.Month, DateTime.Now.Day, DateTime.Now.Year, time), script_text);
WriteStatus(" - Script written!");
scriptsLocalMenuEntry.Enabled = false;
@ -2994,7 +2994,7 @@ namespace NUS_Downloader
proxyBox.Visible = true;
}
private void button18_Click(object sender, EventArgs e)
private void SaveProxyPwdButton_Click(object sender, EventArgs e)
{
proxy_pwd = ProxyPwdBox.Text;
ProxyVerifyBox.Visible = false;
@ -3004,7 +3004,7 @@ namespace NUS_Downloader
private void ProxyPwdBox_KeyPress(object sender, KeyPressEventArgs e)
{
if (e.KeyChar == Convert.ToChar(Keys.Enter))
button18_Click("LOLWUT", EventArgs.Empty);
SaveProxyPwdButton_Click("LOLWUT", EventArgs.Empty);
}
private void ProxyAssistBtn_Click(object sender, EventArgs e)