Added responsiveness
This commit is contained in:
@@ -34,8 +34,8 @@ namespace ErgometerApplication
|
|||||||
this.updateTimer = new System.Windows.Forms.Timer(this.components);
|
this.updateTimer = new System.Windows.Forms.Timer(this.components);
|
||||||
this.writeTimer = new System.Windows.Forms.Timer(this.components);
|
this.writeTimer = new System.Windows.Forms.Timer(this.components);
|
||||||
this.panelClientContainer = new System.Windows.Forms.Panel();
|
this.panelClientContainer = new System.Windows.Forms.Panel();
|
||||||
this.panelFullscreenView = new System.Windows.Forms.Panel();
|
this.panelDataViewLeft = new System.Windows.Forms.Panel();
|
||||||
this.panelClientDataView = new ErgometerApplication.PanelClientDataView();
|
this.panelGraphView = new ErgometerApplication.PanelGraphView();
|
||||||
this.panelClientChat = new ErgometerApplication.PanelClientChat();
|
this.panelClientChat = new ErgometerApplication.PanelClientChat();
|
||||||
this.panelLogin = new ErgometerApplication.PanelLogin(this);
|
this.panelLogin = new ErgometerApplication.PanelLogin(this);
|
||||||
this.panelTopBar = new System.Windows.Forms.Panel();
|
this.panelTopBar = new System.Windows.Forms.Panel();
|
||||||
@@ -56,8 +56,8 @@ namespace ErgometerApplication
|
|||||||
//
|
//
|
||||||
// panelClientContainer
|
// panelClientContainer
|
||||||
//
|
//
|
||||||
this.panelClientContainer.Controls.Add(this.panelFullscreenView);
|
this.panelClientContainer.Controls.Add(this.panelDataViewLeft);
|
||||||
this.panelClientContainer.Controls.Add(this.panelClientDataView);
|
this.panelClientContainer.Controls.Add(this.panelGraphView);
|
||||||
this.panelClientContainer.Controls.Add(this.panelClientChat);
|
this.panelClientContainer.Controls.Add(this.panelClientChat);
|
||||||
this.panelClientContainer.Dock = System.Windows.Forms.DockStyle.Fill;
|
this.panelClientContainer.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
this.panelClientContainer.Location = new System.Drawing.Point(0, 0);
|
this.panelClientContainer.Location = new System.Drawing.Point(0, 0);
|
||||||
@@ -65,23 +65,23 @@ namespace ErgometerApplication
|
|||||||
this.panelClientContainer.Size = new System.Drawing.Size(800, 600);
|
this.panelClientContainer.Size = new System.Drawing.Size(800, 600);
|
||||||
this.panelClientContainer.TabIndex = 0;
|
this.panelClientContainer.TabIndex = 0;
|
||||||
//
|
//
|
||||||
// panelFullscreenView
|
// panelDataViewLeft
|
||||||
//
|
//
|
||||||
this.panelFullscreenView.Dock = System.Windows.Forms.DockStyle.Left;
|
this.panelDataViewLeft.Dock = System.Windows.Forms.DockStyle.Left;
|
||||||
this.panelFullscreenView.Location = new System.Drawing.Point(0, 0);
|
this.panelDataViewLeft.Location = new System.Drawing.Point(0, 0);
|
||||||
this.panelFullscreenView.Name = "panelFullscreenView";
|
this.panelDataViewLeft.Name = "panelDataViewLeft";
|
||||||
this.panelFullscreenView.Size = new System.Drawing.Size(18, 600);
|
this.panelDataViewLeft.Size = new System.Drawing.Size(18, 600);
|
||||||
this.panelFullscreenView.TabIndex = 3;
|
this.panelDataViewLeft.TabIndex = 3;
|
||||||
this.panelFullscreenView.BackColor = System.Drawing.Color.Gray;
|
this.panelDataViewLeft.BackColor = System.Drawing.Color.Gray;
|
||||||
//
|
//
|
||||||
// panelClientDataView
|
// panelGraphView
|
||||||
//
|
//
|
||||||
this.panelClientDataView.BackColor = System.Drawing.SystemColors.ButtonFace;
|
this.panelGraphView.BackColor = System.Drawing.SystemColors.ButtonFace;
|
||||||
this.panelClientDataView.Dock = System.Windows.Forms.DockStyle.Fill;
|
this.panelGraphView.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
this.panelClientDataView.Location = new System.Drawing.Point(0, 0);
|
this.panelGraphView.Location = new System.Drawing.Point(0, 0);
|
||||||
this.panelClientDataView.Name = "panelClientDataView";
|
this.panelGraphView.Name = "panelGraphView";
|
||||||
this.panelClientDataView.Size = new System.Drawing.Size(400, 600);
|
this.panelGraphView.Size = new System.Drawing.Size(400, 600);
|
||||||
this.panelClientDataView.TabIndex = 1;
|
this.panelGraphView.TabIndex = 1;
|
||||||
//
|
//
|
||||||
// panelClientChat
|
// panelClientChat
|
||||||
//
|
//
|
||||||
@@ -165,9 +165,9 @@ namespace ErgometerApplication
|
|||||||
private System.Windows.Forms.Timer writeTimer;
|
private System.Windows.Forms.Timer writeTimer;
|
||||||
private System.Windows.Forms.Panel panelClientContainer;
|
private System.Windows.Forms.Panel panelClientContainer;
|
||||||
private PanelClientChat panelClientChat;
|
private PanelClientChat panelClientChat;
|
||||||
private PanelClientDataView panelClientDataView;
|
private PanelGraphView panelGraphView;
|
||||||
private PanelLogin panelLogin;
|
private PanelLogin panelLogin;
|
||||||
private System.Windows.Forms.Panel panelFullscreenView;
|
private System.Windows.Forms.Panel panelDataViewLeft;
|
||||||
private System.Windows.Forms.Panel panelTopBar;
|
private System.Windows.Forms.Panel panelTopBar;
|
||||||
private System.Windows.Forms.Button buttonLogOff;
|
private System.Windows.Forms.Button buttonLogOff;
|
||||||
private System.Windows.Forms.Label labelUsername;
|
private System.Windows.Forms.Label labelUsername;
|
||||||
|
|||||||
@@ -316,17 +316,22 @@ namespace ErgometerApplication
|
|||||||
Control control = (Control)sender;
|
Control control = (Control)sender;
|
||||||
if(control.Size.Width < 980)
|
if(control.Size.Width < 980)
|
||||||
{
|
{
|
||||||
panelFullscreenView.Visible = false;
|
panelGraphView.Visible = false;
|
||||||
|
panelClientChat.Width = 400;
|
||||||
|
panelDataViewLeft.Dock = DockStyle.Fill;
|
||||||
}
|
}
|
||||||
if (control.Size.Width >= 980 && control.Size.Width < 1368)
|
if (control.Size.Width >= 980 && control.Size.Width < 1368)
|
||||||
{
|
{
|
||||||
panelFullscreenView.Visible = true;
|
panelGraphView.Visible = true;
|
||||||
panelFullscreenView.Width = 250;
|
panelDataViewLeft.Width = 250;
|
||||||
|
panelClientChat.Width = 300;
|
||||||
|
panelDataViewLeft.Dock = DockStyle.Left;
|
||||||
}
|
}
|
||||||
if (control.Size.Width >= 1368)
|
if (control.Size.Width >= 1368)
|
||||||
{
|
{
|
||||||
panelFullscreenView.Visible = true;
|
panelGraphView.Visible = true;
|
||||||
panelFullscreenView.Width = 500;
|
panelDataViewLeft.Width = 400;
|
||||||
|
panelDataViewLeft.Dock = DockStyle.Left;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,17 +11,17 @@ namespace ErgometerApplication
|
|||||||
{
|
{
|
||||||
|
|
||||||
private PanelClientChat panelClientChat;
|
private PanelClientChat panelClientChat;
|
||||||
private PanelClientDataView panelClientDataView;
|
private PanelGraphView panelGraphView;
|
||||||
|
|
||||||
public PanelClientContainer() : base()
|
public PanelClientContainer() : base()
|
||||||
{
|
{
|
||||||
this.panelClientChat = new PanelClientChat();
|
this.panelClientChat = new PanelClientChat();
|
||||||
this.panelClientDataView = new PanelClientDataView();
|
this.panelGraphView = new PanelGraphView();
|
||||||
|
|
||||||
//
|
//
|
||||||
// panelClientContainer
|
// panelClientContainer
|
||||||
//
|
//
|
||||||
this.Controls.Add(this.panelClientDataView);
|
this.Controls.Add(this.panelGraphView);
|
||||||
this.Controls.Add(this.panelClientChat);
|
this.Controls.Add(this.panelClientChat);
|
||||||
this.Dock = System.Windows.Forms.DockStyle.Fill;
|
this.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
this.Location = new System.Drawing.Point(0, 0);
|
this.Location = new System.Drawing.Point(0, 0);
|
||||||
|
|||||||
@@ -7,17 +7,17 @@ using System.Windows.Forms;
|
|||||||
|
|
||||||
namespace ErgometerApplication
|
namespace ErgometerApplication
|
||||||
{
|
{
|
||||||
public class PanelClientDataView:Panel
|
public class PanelGraphView:Panel
|
||||||
{
|
{
|
||||||
public PanelClientDataView() : base()
|
public PanelGraphView() : base()
|
||||||
{
|
{
|
||||||
//
|
//
|
||||||
// panelClientDataView
|
// panelGraphView
|
||||||
//
|
//
|
||||||
this.BackColor = System.Drawing.SystemColors.ButtonFace;
|
this.BackColor = System.Drawing.SystemColors.ButtonFace;
|
||||||
this.Dock = System.Windows.Forms.DockStyle.Fill;
|
this.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
this.Location = new System.Drawing.Point(400, 0);
|
this.Location = new System.Drawing.Point(400, 0);
|
||||||
this.Name = "panelClientDataView";
|
this.Name = "panelGraphView";
|
||||||
this.Size = new System.Drawing.Size(400, 600);
|
this.Size = new System.Drawing.Size(400, 600);
|
||||||
this.TabIndex = 1;
|
this.TabIndex = 1;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user