Only set MyStepPanel.LastAdjust if MyStepPanel isn't null
After StepRTB is resized verify that text has not scrolled out of view
This commit is contained in:
parent
33b03c0a9a
commit
6047e40ba0
@ -222,7 +222,7 @@ namespace Volian.Controls.Library
|
|||||||
//private string _LastMethod = "";
|
//private string _LastMethod = "";
|
||||||
internal void LastMethodsPush(string str)
|
internal void LastMethodsPush(string str)
|
||||||
{
|
{
|
||||||
MyStepPanel._LastAdjust = str;
|
if(MyStepPanel != null)MyStepPanel._LastAdjust = str;
|
||||||
_LastMethods.Push(str);
|
_LastMethods.Push(str);
|
||||||
}
|
}
|
||||||
internal string LastMethodsPop()
|
internal string LastMethodsPop()
|
||||||
|
@ -1076,7 +1076,11 @@ namespace Volian.Controls.Library
|
|||||||
this.Size = szNew;
|
this.Size = szNew;
|
||||||
//Console.WriteLine("after {0}, {1}, {2}, {3}", Size, szNew, widthNew, Width);
|
//Console.WriteLine("after {0}, {1}, {2}, {3}", Size, szNew, widthNew, Width);
|
||||||
if (heightOld != Height)
|
if (heightOld != Height)
|
||||||
|
{
|
||||||
OnHeightChanged(this, new EventArgs());
|
OnHeightChanged(this, new EventArgs());
|
||||||
|
if (ScrollPos.Y != 0) // Adjust ScrollPosition if it isn't Zero
|
||||||
|
ScrollPos = new Point(0, 0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user