partially revert r5408 to fix designer mayhem

This commit is contained in:
goyuken 2015-01-02 22:02:44 +00:00
parent cf7815adc9
commit 2abd8c8dd1
4 changed files with 37 additions and 27 deletions

View File

@ -28,23 +28,23 @@
/// </summary>
private void InitializeComponent()
{
this.BmpView = new BizHawk.Client.EmuHawk.BmpView();
this.bmpView1 = new BizHawk.Client.EmuHawk.BmpView();
this.SuspendLayout();
//
// bmpView1
//
this.BmpView.Location = new System.Drawing.Point(0, 0);
this.BmpView.Name = "bmpView";
this.BmpView.Size = new System.Drawing.Size(64, 64);
this.BmpView.TabIndex = 0;
this.BmpView.Text = "bmpView1";
this.bmpView1.Location = new System.Drawing.Point(0, 0);
this.bmpView1.Name = "bmpView1";
this.bmpView1.Size = new System.Drawing.Size(64, 64);
this.bmpView1.TabIndex = 0;
this.bmpView1.Text = "bmpView1";
//
// MobileBmpView
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(292, 273);
this.Controls.Add(this.BmpView);
this.Controls.Add(this.bmpView1);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow;
this.MaximizeBox = false;
this.MinimizeBox = false;
@ -56,5 +56,7 @@
}
#endregion
private BmpView bmpView1;
}
}

View File

@ -1,5 +1,10 @@
using System.ComponentModel;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace BizHawk.Client.EmuHawk
@ -11,10 +16,10 @@ namespace BizHawk.Client.EmuHawk
InitializeComponent();
}
public BmpView BmpView { get; private set; }
public BmpView BmpView { get { return bmpView1; } }
[Browsable(false)]
public bool ShouldDraw { get { return Visible; } }
public bool ShouldDraw { get { return this.Visible; } }
public override string ToString()
{
@ -23,24 +28,22 @@ namespace BizHawk.Client.EmuHawk
public void ChangeViewSize(Size size)
{
BmpView.Size = ClientSize = size;
bmpView1.Size = size;
this.ClientSize = size;
}
public void ChangeViewSize(int w, int h)
{
ChangeViewSize(new Size(w, h));
}
public void ChangeAllSizes(int w, int h)
{
ChangeViewSize(w, h);
BmpView.ChangeBitmapSize(w, h);
bmpView1.ChangeBitmapSize(w, h);
}
public void ChangeAllSizes(Size size)
{
ChangeViewSize(size);
BmpView.ChangeBitmapSize(size);
bmpView1.ChangeBitmapSize(size);
}
}
}

View File

@ -29,7 +29,7 @@
private void InitializeComponent()
{
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.BmpView = new BizHawk.Client.EmuHawk.BmpView();
this.bmpView1 = new BizHawk.Client.EmuHawk.BmpView();
this.listView1 = new System.Windows.Forms.ListView();
this.columnHeader1 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.columnHeader2 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
@ -40,7 +40,7 @@
//
this.tableLayoutPanel1.ColumnCount = 1;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel1.Controls.Add(this.BmpView, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.bmpView1, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.listView1, 0, 1);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
@ -53,12 +53,12 @@
//
// bmpView1
//
this.BmpView.Dock = System.Windows.Forms.DockStyle.Fill;
this.BmpView.Location = new System.Drawing.Point(3, 3);
this.BmpView.Name = "bmpView";
this.BmpView.Size = new System.Drawing.Size(136, 134);
this.BmpView.TabIndex = 0;
this.BmpView.Text = "bmpView1";
this.bmpView1.Dock = System.Windows.Forms.DockStyle.Fill;
this.bmpView1.Location = new System.Drawing.Point(3, 3);
this.bmpView1.Name = "bmpView1";
this.bmpView1.Size = new System.Drawing.Size(136, 134);
this.bmpView1.TabIndex = 0;
this.bmpView1.Text = "bmpView1";
//
// listView1
//
@ -96,6 +96,7 @@
#endregion
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private BmpView bmpView1;
private System.Windows.Forms.ListView listView1;
private System.Windows.Forms.ColumnHeader columnHeader1;
private System.Windows.Forms.ColumnHeader columnHeader2;

View File

@ -1,6 +1,10 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace BizHawk.Client.EmuHawk
@ -12,10 +16,10 @@ namespace BizHawk.Client.EmuHawk
InitializeComponent();
}
public BmpView BmpView { get; private set; }
public BmpView BmpView { get { return bmpView1; } }
[Browsable(false)]
public bool ShouldDraw { get { return Visible; } }
public bool ShouldDraw { get { return this.Visible; } }
public override string ToString()
{
@ -27,7 +31,7 @@ namespace BizHawk.Client.EmuHawk
listView1.Items.Clear();
foreach (var t in details)
{
listView1.Items.Add(new ListViewItem(new[] { t.Item1, t.Item2 }));
listView1.Items.Add(new ListViewItem(new string[] { t.Item1, t.Item2 }));
}
}