remove 'private' keyword where possible
This commit is contained in:
@@ -16,7 +16,7 @@ namespace OpenRA.Widgets
|
||||
public class ScrollingTextWidget : Widget
|
||||
{
|
||||
public string Text = "";
|
||||
private string ScrollingText = "";
|
||||
string ScrollingText = "";
|
||||
|
||||
public string Background = null;
|
||||
|
||||
@@ -27,10 +27,10 @@ namespace OpenRA.Widgets
|
||||
// ticks per single letter scroll
|
||||
public int ScrollRate = 4;
|
||||
|
||||
private string ScrollBuffer = "";
|
||||
string ScrollBuffer = "";
|
||||
|
||||
private int ScrollLocation = 0;
|
||||
private int ScrollTick = 0;
|
||||
int ScrollLocation = 0;
|
||||
int ScrollTick = 0;
|
||||
|
||||
public Func<string> GetText;
|
||||
public Func<string> GetBackground;
|
||||
@@ -67,22 +67,18 @@ namespace OpenRA.Widgets
|
||||
ScrollTick = 0;
|
||||
}
|
||||
|
||||
private void UpdateScrollBuffer()
|
||||
void UpdateScrollBuffer()
|
||||
{
|
||||
ScrollTick++;
|
||||
|
||||
if (ScrollTick < ScrollRate)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
ScrollTick = 0;
|
||||
ScrollBuffer = "";
|
||||
|
||||
if (ScrollingText.Substring(ScrollingText.Length - 4, 3) != " ")
|
||||
{
|
||||
ScrollingText += " ";
|
||||
}
|
||||
|
||||
int tempScrollLocation = ScrollLocation;
|
||||
for (int i = 0; i < ScrollLength; ++i)
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace OpenRA.Widgets
|
||||
// This is bogus
|
||||
public float2 Range = new float2(0f, 1f);
|
||||
|
||||
private float Offset = 0;
|
||||
float Offset = 0;
|
||||
|
||||
int2 lastMouseLocation;
|
||||
protected bool isMoving = false;
|
||||
|
||||
@@ -52,7 +52,7 @@ namespace OpenRA.Widgets
|
||||
get { return rootWidget; }
|
||||
set { rootWidget = value; }
|
||||
}
|
||||
private static Widget rootWidget = new ContainerWidget();
|
||||
static Widget rootWidget = new ContainerWidget();
|
||||
|
||||
public Widget(Widget widget)
|
||||
{
|
||||
@@ -401,4 +401,4 @@ namespace OpenRA.Widgets
|
||||
{
|
||||
void Init();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user