diff options
author | John Sohn <jsohn@mono-cvs.ximian.com> | 2002-10-13 10:48:56 +0400 |
---|---|---|
committer | John Sohn <jsohn@mono-cvs.ximian.com> | 2002-10-13 10:48:56 +0400 |
commit | 6e0fb503968aadd53ff1fbe999c1a81bc786b240 (patch) | |
tree | d9dff2cbe3dd5c4c1988aa6764f1636053da0be1 /mcs | |
parent | d1753e90d0a81b003da03905d9ddbd3f0817b908 (diff) |
* Button.cs:
* Label.cs:
* Control.cs:
* Form.cs: fixed location of elements on Form
* FormTest.cs: changed location of Label and Button on Form
svn path=/trunk/mcs/; revision=8209
Diffstat (limited to 'mcs')
11 files changed, 67 insertions, 43 deletions
diff --git a/mcs/class/System.Windows.Forms/System.Windows.Forms/Button.cs b/mcs/class/System.Windows.Forms/System.Windows.Forms/Button.cs index 044dba7ffc9..b6ed689bfdd 100644 --- a/mcs/class/System.Windows.Forms/System.Windows.Forms/Button.cs +++ b/mcs/class/System.Windows.Forms/System.Windows.Forms/Button.cs @@ -35,8 +35,8 @@ namespace System.Windows.Forms { createParams.Caption = Text;
createParams.ClassName = "BUTTON";
- createParams.X = Top;
- createParams.Y = Left;
+ createParams.X = Left;
+ createParams.Y = Top;
createParams.Width = Width;
createParams.Height = Height;
createParams.ClassStyle = 0;
diff --git a/mcs/class/System.Windows.Forms/System.Windows.Forms/Control.cs b/mcs/class/System.Windows.Forms/System.Windows.Forms/Control.cs index 056c2cf1a37..3fdf411cd9a 100644 --- a/mcs/class/System.Windows.Forms/System.Windows.Forms/Control.cs +++ b/mcs/class/System.Windows.Forms/System.Windows.Forms/Control.cs @@ -34,9 +34,6 @@ namespace System.Windows.Forms { protected override void WndProc (ref Message m) {
base.WndProc (ref m);
-
- if (m.Msg == Win32.WM_CREATE)
- Console.WriteLine ("CNW WndProc WM_CREATE");
control.WndProc (ref m);
}
}
@@ -422,8 +419,8 @@ namespace System.Windows.Forms { CreateParams createParams = new CreateParams ();
createParams.Caption = Text;
createParams.ClassName = "mono_native_window";
- createParams.X = Top;
- createParams.Y = Left;
+ createParams.X = Left;
+ createParams.Y = Top;
createParams.Width = Width;
createParams.Height = Height;
createParams.ClassStyle = 0;
@@ -633,14 +630,15 @@ namespace System.Windows.Forms { get {
if (IsHandleCreated) {
// FIXME: GetWindowPos
- }
- return Bounds.X;
+ return 0;
+ } else return bounds.X;
}
set {
+ bounds.X = value;
+
if (IsHandleCreated) {
// FIXME: SetWindowPos
}
- Bounds.X = value;
}
}
@@ -689,7 +687,7 @@ namespace System.Windows.Forms { return name;
}
set {
- name=value;
+ name = value;
}
}
@@ -862,7 +860,7 @@ namespace System.Windows.Forms { } else return bounds.Top;
}
set {
- bounds.X = value;
+ bounds.Y = value;
if (IsHandleCreated) {
// FIXME: SetWindowPos
diff --git a/mcs/class/System.Windows.Forms/System.Windows.Forms/Form.cs b/mcs/class/System.Windows.Forms/System.Windows.Forms/Form.cs index 836a2a99ebd..2c8e1f83202 100644 --- a/mcs/class/System.Windows.Forms/System.Windows.Forms/Form.cs +++ b/mcs/class/System.Windows.Forms/System.Windows.Forms/Form.cs @@ -662,12 +662,14 @@ namespace System.Windows.Forms { // --- Protected Methods
- protected override void AdjustFormScrollbars (bool displayScrollbars)
+ protected override void AdjustFormScrollbars (
+ bool displayScrollbars)
{
base.AdjustFormScrollbars (displayScrollbars);
}
- protected override Control.ControlCollection CreateControlsInstance ()
+ protected override Control.ControlCollection
+ CreateControlsInstance ()
{
return base.CreateControlsInstance ();
}
@@ -724,13 +726,15 @@ namespace System.Windows.Forms { base.OnHandleDestroyed (e);
}
- protected virtual void OnInputLanguageChanged (InputLanguageChangedEventArgs e)
+ protected virtual void OnInputLanguageChanged (
+ InputLanguageChangedEventArgs e)
{
if (InputLanguageChanged != null)
InputLanguageChanged (this, e);
}
- protected virtual void OnInputLanguagedChanging (InputLanguageChangingEventArgs e)
+ protected virtual void OnInputLanguagedChanging (
+ InputLanguageChangingEventArgs e)
{
if (InputLanguageChanging != null)
InputLanguageChanging (this, e);
@@ -802,7 +806,8 @@ namespace System.Windows.Forms { base.OnVisibleChanged (e);
}
- protected override bool ProcessCmdKey (ref Message msg, Keys keyData)
+ protected override bool ProcessCmdKey (
+ ref Message msg, Keys keyData)
{
return base.ProcessCmdKey (ref msg, keyData);
}
@@ -953,7 +958,9 @@ namespace System.Windows.Forms { // TODO: implement support classes and derive from
// proper classes
// FIXME: use this or the one defined on Control?
- public class ControlCollectionX : System.Windows.Forms.Control.ControlCollection /*,ICollection*/ {
+ public class ControlCollectionX :
+ System.Windows.Forms.Control.ControlCollection
+ /*,ICollection*/ {
// --- Constructor
// base class not defined (yet!)
diff --git a/mcs/class/System.Windows.Forms/System.Windows.Forms/Label.cs b/mcs/class/System.Windows.Forms/System.Windows.Forms/Label.cs index 6f52afd7237..17893d18826 100644 --- a/mcs/class/System.Windows.Forms/System.Windows.Forms/Label.cs +++ b/mcs/class/System.Windows.Forms/System.Windows.Forms/Label.cs @@ -182,8 +182,8 @@ namespace System.Windows.Forms { createParams.Caption = Text;
createParams.ClassName = "STATIC";
- createParams.X = Top;
- createParams.Y = Left;
+ createParams.X = Left;
+ createParams.Y = Top;
createParams.Width = Width;
createParams.Height = Height;
createParams.ClassStyle = 0;
diff --git a/mcs/class/System.Windows.Forms/System.Windows.Forms/ochangelog b/mcs/class/System.Windows.Forms/System.Windows.Forms/ochangelog index 88b06264f8a..a7b6fc2c7b7 100644 --- a/mcs/class/System.Windows.Forms/System.Windows.Forms/ochangelog +++ b/mcs/class/System.Windows.Forms/System.Windows.Forms/ochangelog @@ -1,3 +1,10 @@ +2002-10-13 John Sohn <jsohn@columbus.rr.com>
+ * Button.cs:
+ * Label.cs:
+ * Control.cs:
+ * Form.cs: fixed location of elements on Form
+ * FormTest.cs: changed location of Label and Button on Form
+
2002-10-12 John Sohn <jsohn@columbus.rr.com>
* ButtonBase.cs:
* Button.cs: initial implementation of Button class
diff --git a/mcs/class/System.Windows.Forms/WINELib/Button.cs b/mcs/class/System.Windows.Forms/WINELib/Button.cs index 044dba7ffc9..b6ed689bfdd 100644 --- a/mcs/class/System.Windows.Forms/WINELib/Button.cs +++ b/mcs/class/System.Windows.Forms/WINELib/Button.cs @@ -35,8 +35,8 @@ namespace System.Windows.Forms { createParams.Caption = Text;
createParams.ClassName = "BUTTON";
- createParams.X = Top;
- createParams.Y = Left;
+ createParams.X = Left;
+ createParams.Y = Top;
createParams.Width = Width;
createParams.Height = Height;
createParams.ClassStyle = 0;
diff --git a/mcs/class/System.Windows.Forms/WINELib/Control.cs b/mcs/class/System.Windows.Forms/WINELib/Control.cs index 056c2cf1a37..3fdf411cd9a 100644 --- a/mcs/class/System.Windows.Forms/WINELib/Control.cs +++ b/mcs/class/System.Windows.Forms/WINELib/Control.cs @@ -34,9 +34,6 @@ namespace System.Windows.Forms { protected override void WndProc (ref Message m) {
base.WndProc (ref m);
-
- if (m.Msg == Win32.WM_CREATE)
- Console.WriteLine ("CNW WndProc WM_CREATE");
control.WndProc (ref m);
}
}
@@ -422,8 +419,8 @@ namespace System.Windows.Forms { CreateParams createParams = new CreateParams ();
createParams.Caption = Text;
createParams.ClassName = "mono_native_window";
- createParams.X = Top;
- createParams.Y = Left;
+ createParams.X = Left;
+ createParams.Y = Top;
createParams.Width = Width;
createParams.Height = Height;
createParams.ClassStyle = 0;
@@ -633,14 +630,15 @@ namespace System.Windows.Forms { get {
if (IsHandleCreated) {
// FIXME: GetWindowPos
- }
- return Bounds.X;
+ return 0;
+ } else return bounds.X;
}
set {
+ bounds.X = value;
+
if (IsHandleCreated) {
// FIXME: SetWindowPos
}
- Bounds.X = value;
}
}
@@ -689,7 +687,7 @@ namespace System.Windows.Forms { return name;
}
set {
- name=value;
+ name = value;
}
}
@@ -862,7 +860,7 @@ namespace System.Windows.Forms { } else return bounds.Top;
}
set {
- bounds.X = value;
+ bounds.Y = value;
if (IsHandleCreated) {
// FIXME: SetWindowPos
diff --git a/mcs/class/System.Windows.Forms/WINELib/Form.cs b/mcs/class/System.Windows.Forms/WINELib/Form.cs index 836a2a99ebd..2c8e1f83202 100644 --- a/mcs/class/System.Windows.Forms/WINELib/Form.cs +++ b/mcs/class/System.Windows.Forms/WINELib/Form.cs @@ -662,12 +662,14 @@ namespace System.Windows.Forms { // --- Protected Methods
- protected override void AdjustFormScrollbars (bool displayScrollbars)
+ protected override void AdjustFormScrollbars (
+ bool displayScrollbars)
{
base.AdjustFormScrollbars (displayScrollbars);
}
- protected override Control.ControlCollection CreateControlsInstance ()
+ protected override Control.ControlCollection
+ CreateControlsInstance ()
{
return base.CreateControlsInstance ();
}
@@ -724,13 +726,15 @@ namespace System.Windows.Forms { base.OnHandleDestroyed (e);
}
- protected virtual void OnInputLanguageChanged (InputLanguageChangedEventArgs e)
+ protected virtual void OnInputLanguageChanged (
+ InputLanguageChangedEventArgs e)
{
if (InputLanguageChanged != null)
InputLanguageChanged (this, e);
}
- protected virtual void OnInputLanguagedChanging (InputLanguageChangingEventArgs e)
+ protected virtual void OnInputLanguagedChanging (
+ InputLanguageChangingEventArgs e)
{
if (InputLanguageChanging != null)
InputLanguageChanging (this, e);
@@ -802,7 +806,8 @@ namespace System.Windows.Forms { base.OnVisibleChanged (e);
}
- protected override bool ProcessCmdKey (ref Message msg, Keys keyData)
+ protected override bool ProcessCmdKey (
+ ref Message msg, Keys keyData)
{
return base.ProcessCmdKey (ref msg, keyData);
}
@@ -953,7 +958,9 @@ namespace System.Windows.Forms { // TODO: implement support classes and derive from
// proper classes
// FIXME: use this or the one defined on Control?
- public class ControlCollectionX : System.Windows.Forms.Control.ControlCollection /*,ICollection*/ {
+ public class ControlCollectionX :
+ System.Windows.Forms.Control.ControlCollection
+ /*,ICollection*/ {
// --- Constructor
// base class not defined (yet!)
diff --git a/mcs/class/System.Windows.Forms/WINELib/FormTest.cs b/mcs/class/System.Windows.Forms/WINELib/FormTest.cs index 721795e33b8..cf9a4dbd58f 100644 --- a/mcs/class/System.Windows.Forms/WINELib/FormTest.cs +++ b/mcs/class/System.Windows.Forms/WINELib/FormTest.cs @@ -10,15 +10,15 @@ class FormTest : Form { public FormTest () : base () { label = new Label (); - label.Top = 60; - label.Left = 50; + label.Top = 50; + label.Left = 10; label.Width = 50; label.Height = 50; label.Parent = this; label.Text = "Label"; button = new Button (); - button.Top = 120; + button.Top = 50; button.Left = 120; button.Width = 50; button.Height = 50; diff --git a/mcs/class/System.Windows.Forms/WINELib/Label.cs b/mcs/class/System.Windows.Forms/WINELib/Label.cs index 6f52afd7237..17893d18826 100644 --- a/mcs/class/System.Windows.Forms/WINELib/Label.cs +++ b/mcs/class/System.Windows.Forms/WINELib/Label.cs @@ -182,8 +182,8 @@ namespace System.Windows.Forms { createParams.Caption = Text;
createParams.ClassName = "STATIC";
- createParams.X = Top;
- createParams.Y = Left;
+ createParams.X = Left;
+ createParams.Y = Top;
createParams.Width = Width;
createParams.Height = Height;
createParams.ClassStyle = 0;
diff --git a/mcs/class/System.Windows.Forms/WINELib/changelog b/mcs/class/System.Windows.Forms/WINELib/changelog index 88b06264f8a..a7b6fc2c7b7 100644 --- a/mcs/class/System.Windows.Forms/WINELib/changelog +++ b/mcs/class/System.Windows.Forms/WINELib/changelog @@ -1,3 +1,10 @@ +2002-10-13 John Sohn <jsohn@columbus.rr.com>
+ * Button.cs:
+ * Label.cs:
+ * Control.cs:
+ * Form.cs: fixed location of elements on Form
+ * FormTest.cs: changed location of Label and Button on Form
+
2002-10-12 John Sohn <jsohn@columbus.rr.com>
* ButtonBase.cs:
* Button.cs: initial implementation of Button class
|