oh hi
This commit is contained in:
@@ -89,7 +89,8 @@ namespace OpenRA.Widgets
|
|||||||
var pos = DrawPosition();
|
var pos = DrawPosition();
|
||||||
|
|
||||||
var stateOffset = (Depressed) ? new int2(VisualHeight, VisualHeight) : new int2(0, 0);
|
var stateOffset = (Depressed) ? new int2(VisualHeight, VisualHeight) : new int2(0, 0);
|
||||||
WidgetUtils.DrawPanel(Depressed ? "dialog3" : "dialog2", new Rectangle(pos.X, pos.Y, Bounds.Width, Bounds.Height ) );
|
WidgetUtils.DrawPanel(Depressed ? "dialog3" : "dialog2",
|
||||||
|
new Rectangle(pos.X, pos.Y, Bounds.Width, Bounds.Height ) );
|
||||||
|
|
||||||
var text = GetText();
|
var text = GetText();
|
||||||
Game.chrome.renderer.BoldFont.DrawText(text,
|
Game.chrome.renderer.BoldFont.DrawText(text,
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ namespace OpenRA.Widgets.Delegates
|
|||||||
template.Id = "PLAYER_{0}".F(c.Index);
|
template.Id = "PLAYER_{0}".F(c.Index);
|
||||||
template.Parent = Players;
|
template.Parent = Players;
|
||||||
template.GetWidget<ButtonWidget>("NAME").GetText = () => {return c.Name; };
|
template.GetWidget<ButtonWidget>("NAME").GetText = () => {return c.Name; };
|
||||||
template.Bounds = new Rectangle(pos.X, pos.Y + i, template.Bounds.Width, template.Bounds.Height);
|
template.Bounds = new Rectangle(0, i, template.Bounds.Width, template.Bounds.Height);
|
||||||
template.IsVisible = () => {return true;};
|
template.IsVisible = () => {return true;};
|
||||||
Players.AddChild(template);
|
Players.AddChild(template);
|
||||||
i += 30;
|
i += 30;
|
||||||
|
|||||||
@@ -91,7 +91,9 @@ namespace OpenRA.Widgets
|
|||||||
public virtual void Initialize()
|
public virtual void Initialize()
|
||||||
{
|
{
|
||||||
// Parse the YAML equations to find the widget bounds
|
// Parse the YAML equations to find the widget bounds
|
||||||
Rectangle parentBounds = (Parent == null) ? new Rectangle(0,0,Game.viewport.Width,Game.viewport.Height) : Parent.Bounds;
|
Rectangle parentBounds = (Parent == null)
|
||||||
|
? new Rectangle(0,0,Game.viewport.Width,Game.viewport.Height)
|
||||||
|
: Parent.Bounds;
|
||||||
|
|
||||||
Dictionary<string, int> substitutions = new Dictionary<string, int>();
|
Dictionary<string, int> substitutions = new Dictionary<string, int>();
|
||||||
substitutions.Add("WINDOW_RIGHT", Game.viewport.Width);
|
substitutions.Add("WINDOW_RIGHT", Game.viewport.Width);
|
||||||
|
|||||||
Reference in New Issue
Block a user