diff options
| author | Michael <[email protected]> | 2017-06-24 14:48:39 -0400 |
|---|---|---|
| committer | Michael <[email protected]> | 2017-06-24 14:48:39 -0400 |
| commit | 9c1a409f24da92f1e6d95ee4cdd777b52d53488f (patch) | |
| tree | df950dfe22623959d22208c6a0813d2a896b434c /ShiftOS.WinForms/Applications | |
| parent | 8621b3ddffdd8211604f01d90ff40c9b2991f27a (diff) | |
| download | shiftos_thereturn-9c1a409f24da92f1e6d95ee4cdd777b52d53488f.tar.gz shiftos_thereturn-9c1a409f24da92f1e6d95ee4cdd777b52d53488f.tar.bz2 shiftos_thereturn-9c1a409f24da92f1e6d95ee4cdd777b52d53488f.zip | |
file skimmer disconnect button
Diffstat (limited to 'ShiftOS.WinForms/Applications')
| -rw-r--r-- | ShiftOS.WinForms/Applications/FileSkimmer.Designer.cs | 177 | ||||
| -rw-r--r-- | ShiftOS.WinForms/Applications/FileSkimmer.cs | 8 |
2 files changed, 102 insertions, 83 deletions
diff --git a/ShiftOS.WinForms/Applications/FileSkimmer.Designer.cs b/ShiftOS.WinForms/Applications/FileSkimmer.Designer.cs index 4df58c3..91891ba 100644 --- a/ShiftOS.WinForms/Applications/FileSkimmer.Designer.cs +++ b/ShiftOS.WinForms/Applications/FileSkimmer.Designer.cs @@ -65,23 +65,24 @@ namespace ShiftOS.WinForms.Applications this.moveToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.pinToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.pnlconnect = new System.Windows.Forms.Panel(); - this.lbctitle = new System.Windows.Forms.Label(); - this.lbcdesc = new System.Windows.Forms.Label(); - this.pnlcreds = new System.Windows.Forms.Panel(); - this.label1 = new System.Windows.Forms.Label(); - this.txtcsys = new System.Windows.Forms.TextBox(); - this.txtcuser = new System.Windows.Forms.TextBox(); - this.label2 = new System.Windows.Forms.Label(); - this.txtcpass = new System.Windows.Forms.TextBox(); - this.label3 = new System.Windows.Forms.Label(); this.flcbuttons = new System.Windows.Forms.FlowLayoutPanel(); this.btncancel = new System.Windows.Forms.Button(); this.btnok = new System.Windows.Forms.Button(); + this.pnlcreds = new System.Windows.Forms.Panel(); + this.txtcpass = new System.Windows.Forms.TextBox(); + this.label3 = new System.Windows.Forms.Label(); + this.txtcuser = new System.Windows.Forms.TextBox(); + this.label2 = new System.Windows.Forms.Label(); + this.txtcsys = new System.Windows.Forms.TextBox(); + this.label1 = new System.Windows.Forms.Label(); + this.lbcdesc = new System.Windows.Forms.Label(); + this.lbctitle = new System.Windows.Forms.Label(); + this.disconnectToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.panel1.SuspendLayout(); this.menuStrip1.SuspendLayout(); this.pnlconnect.SuspendLayout(); - this.pnlcreds.SuspendLayout(); this.flcbuttons.SuspendLayout(); + this.pnlcreds.SuspendLayout(); this.SuspendLayout(); // // lvitems @@ -131,6 +132,7 @@ namespace ShiftOS.WinForms.Applications this.newFolderToolStripMenuItem, this.deleteToolStripMenuItem, this.connectToRemoteServerToolStripMenuItem, + this.disconnectToolStripMenuItem, this.copyToolStripMenuItem, this.moveToolStripMenuItem, this.pinToolStripMenuItem}); @@ -194,24 +196,40 @@ namespace ShiftOS.WinForms.Applications this.pnlconnect.TabIndex = 4; this.pnlconnect.Visible = false; // - // lbctitle + // flcbuttons // - this.lbctitle.AutoSize = true; - this.lbctitle.Location = new System.Drawing.Point(13, 18); - this.lbctitle.Name = "lbctitle"; - this.lbctitle.Size = new System.Drawing.Size(133, 13); - this.lbctitle.TabIndex = 0; - this.lbctitle.Tag = "header3"; - this.lbctitle.Text = "Connect to Remote Server"; + this.flcbuttons.AutoSize = true; + this.flcbuttons.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink; + this.flcbuttons.Controls.Add(this.btncancel); + this.flcbuttons.Controls.Add(this.btnok); + this.flcbuttons.Location = new System.Drawing.Point(116, 256); + this.flcbuttons.Name = "flcbuttons"; + this.flcbuttons.Size = new System.Drawing.Size(94, 29); + this.flcbuttons.TabIndex = 3; // - // lbcdesc + // btncancel // - this.lbcdesc.Location = new System.Drawing.Point(46, 51); - this.lbcdesc.Name = "lbcdesc"; - this.lbcdesc.Size = new System.Drawing.Size(357, 54); - this.lbcdesc.TabIndex = 1; - this.lbcdesc.Text = resources.GetString("lbcdesc.Text"); - this.lbcdesc.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; + this.btncancel.AutoSize = true; + this.btncancel.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink; + this.btncancel.Location = new System.Drawing.Point(3, 3); + this.btncancel.Name = "btncancel"; + this.btncancel.Size = new System.Drawing.Size(50, 23); + this.btncancel.TabIndex = 0; + this.btncancel.Text = "Cancel"; + this.btncancel.UseVisualStyleBackColor = true; + this.btncancel.Click += new System.EventHandler(this.btncancel_Click); + // + // btnok + // + this.btnok.AutoSize = true; + this.btnok.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink; + this.btnok.Location = new System.Drawing.Point(59, 3); + this.btnok.Name = "btnok"; + this.btnok.Size = new System.Drawing.Size(32, 23); + this.btnok.TabIndex = 1; + this.btnok.Text = "OK"; + this.btnok.UseVisualStyleBackColor = true; + this.btnok.Click += new System.EventHandler(this.btnok_Click); // // pnlcreds // @@ -226,23 +244,23 @@ namespace ShiftOS.WinForms.Applications this.pnlcreds.Size = new System.Drawing.Size(300, 104); this.pnlcreds.TabIndex = 2; // - // label1 + // txtcpass // - this.label1.AutoSize = true; - this.label1.Location = new System.Drawing.Point(12, 13); - this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(73, 13); - this.label1.TabIndex = 0; - this.label1.Text = "System name:"; + this.txtcpass.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + | System.Windows.Forms.AnchorStyles.Right))); + this.txtcpass.Location = new System.Drawing.Point(91, 62); + this.txtcpass.Name = "txtcpass"; + this.txtcpass.Size = new System.Drawing.Size(196, 20); + this.txtcpass.TabIndex = 5; // - // txtcsys + // label3 // - this.txtcsys.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) - | System.Windows.Forms.AnchorStyles.Right))); - this.txtcsys.Location = new System.Drawing.Point(91, 10); - this.txtcsys.Name = "txtcsys"; - this.txtcsys.Size = new System.Drawing.Size(196, 20); - this.txtcsys.TabIndex = 1; + this.label3.AutoSize = true; + this.label3.Location = new System.Drawing.Point(12, 65); + this.label3.Name = "label3"; + this.label3.Size = new System.Drawing.Size(56, 13); + this.label3.TabIndex = 4; + this.label3.Text = "Password:"; // // txtcuser // @@ -262,58 +280,50 @@ namespace ShiftOS.WinForms.Applications this.label2.TabIndex = 2; this.label2.Text = "Username:"; // - // txtcpass + // txtcsys // - this.txtcpass.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) + this.txtcsys.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) | System.Windows.Forms.AnchorStyles.Right))); - this.txtcpass.Location = new System.Drawing.Point(91, 62); - this.txtcpass.Name = "txtcpass"; - this.txtcpass.Size = new System.Drawing.Size(196, 20); - this.txtcpass.TabIndex = 5; + this.txtcsys.Location = new System.Drawing.Point(91, 10); + this.txtcsys.Name = "txtcsys"; + this.txtcsys.Size = new System.Drawing.Size(196, 20); + this.txtcsys.TabIndex = 1; // - // label3 + // label1 // - this.label3.AutoSize = true; - this.label3.Location = new System.Drawing.Point(12, 65); - this.label3.Name = "label3"; - this.label3.Size = new System.Drawing.Size(56, 13); - this.label3.TabIndex = 4; - this.label3.Text = "Password:"; + this.label1.AutoSize = true; + this.label1.Location = new System.Drawing.Point(12, 13); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(73, 13); + this.label1.TabIndex = 0; + this.label1.Text = "System name:"; // - // flcbuttons + // lbcdesc // - this.flcbuttons.AutoSize = true; - this.flcbuttons.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink; - this.flcbuttons.Controls.Add(this.btncancel); - this.flcbuttons.Controls.Add(this.btnok); - this.flcbuttons.Location = new System.Drawing.Point(116, 256); - this.flcbuttons.Name = "flcbuttons"; - this.flcbuttons.Size = new System.Drawing.Size(94, 29); - this.flcbuttons.TabIndex = 3; + this.lbcdesc.Location = new System.Drawing.Point(46, 51); + this.lbcdesc.Name = "lbcdesc"; + this.lbcdesc.Size = new System.Drawing.Size(357, 54); + this.lbcdesc.TabIndex = 1; + this.lbcdesc.Text = resources.GetString("lbcdesc.Text"); + this.lbcdesc.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // - // btncancel + // lbctitle // - this.btncancel.AutoSize = true; - this.btncancel.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink; - this.btncancel.Location = new System.Drawing.Point(3, 3); - this.btncancel.Name = "btncancel"; - this.btncancel.Size = new System.Drawing.Size(50, 23); - this.btncancel.TabIndex = 0; - this.btncancel.Text = "Cancel"; - this.btncancel.UseVisualStyleBackColor = true; - this.btncancel.Click += new System.EventHandler(this.btncancel_Click); + this.lbctitle.AutoSize = true; + this.lbctitle.Location = new System.Drawing.Point(13, 18); + this.lbctitle.Name = "lbctitle"; + this.lbctitle.Size = new System.Drawing.Size(133, 13); + this.lbctitle.TabIndex = 0; + this.lbctitle.Tag = "header3"; + this.lbctitle.Text = "Connect to Remote Server"; // - // btnok + // disconnectToolStripMenuItem // - this.btnok.AutoSize = true; - this.btnok.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink; - this.btnok.Location = new System.Drawing.Point(59, 3); - this.btnok.Name = "btnok"; - this.btnok.Size = new System.Drawing.Size(32, 23); - this.btnok.TabIndex = 1; - this.btnok.Text = "OK"; - this.btnok.UseVisualStyleBackColor = true; - this.btnok.Click += new System.EventHandler(this.btnok_Click); + this.disconnectToolStripMenuItem.Name = "disconnectToolStripMenuItem"; + this.disconnectToolStripMenuItem.Size = new System.Drawing.Size(78, 20); + this.disconnectToolStripMenuItem.Text = "Disconnect"; + this.disconnectToolStripMenuItem.Visible = false; + this.disconnectToolStripMenuItem.Click += new System.EventHandler(this.disconnectToolStripMenuItem_Click); // // FileSkimmer // @@ -330,10 +340,10 @@ namespace ShiftOS.WinForms.Applications this.menuStrip1.PerformLayout(); this.pnlconnect.ResumeLayout(false); this.pnlconnect.PerformLayout(); - this.pnlcreds.ResumeLayout(false); - this.pnlcreds.PerformLayout(); this.flcbuttons.ResumeLayout(false); this.flcbuttons.PerformLayout(); + this.pnlcreds.ResumeLayout(false); + this.pnlcreds.PerformLayout(); this.ResumeLayout(false); this.PerformLayout(); @@ -365,5 +375,6 @@ namespace ShiftOS.WinForms.Applications private System.Windows.Forms.Label label1; private System.Windows.Forms.Label lbcdesc; private System.Windows.Forms.Label lbctitle; + private System.Windows.Forms.ToolStripMenuItem disconnectToolStripMenuItem; } }
\ No newline at end of file diff --git a/ShiftOS.WinForms/Applications/FileSkimmer.cs b/ShiftOS.WinForms/Applications/FileSkimmer.cs index dee751b..3e17420 100644 --- a/ShiftOS.WinForms/Applications/FileSkimmer.cs +++ b/ShiftOS.WinForms/Applications/FileSkimmer.cs @@ -77,6 +77,8 @@ namespace ShiftOS.WinForms.Applications private void FileSkimmer_OnDisconnect() { + connectToRemoteServerToolStripMenuItem.Text = "Start Remote Session"; + disconnectToolStripMenuItem.Visible = false; currentdir = "__system"; ResetList(); } @@ -579,6 +581,7 @@ namespace ShiftOS.WinForms.Applications ChangeDirectory("2:"); pnlconnect.Hide(); connectToRemoteServerToolStripMenuItem.Text = "Reauthenticate"; + disconnectToolStripMenuItem.Visible = true; return; } Infobox.Show("Access denied.", "Authentication failed for the specified user. Connection aborted."); @@ -592,5 +595,10 @@ namespace ShiftOS.WinForms.Applications t.IsBackground = true; t.Start(); } + + private void disconnectToolStripMenuItem_Click(object sender, EventArgs e) + { + DisconnectRemote(); + } } } |
