MouseTest theme covered.
This commit is contained in:
@@ -3,7 +3,11 @@ local t = Def.ActorFrame{};
|
||||
local mou = Def.ActorFrame{
|
||||
LoadFont("common normal")..{
|
||||
Name="Coords";
|
||||
InitCommand=cmd(align,0,0;x,SCREEN_LEFT+8;y,SCREEN_BOTTOM-48);
|
||||
InitCommand=function(self)
|
||||
self:align(0, 0);
|
||||
self:x(SCREEN_LEFT + 8);
|
||||
self:y(SCREEN_BOTTOM - 48);
|
||||
end;
|
||||
};
|
||||
};
|
||||
local function UpdateMouse(self)
|
||||
@@ -13,19 +17,33 @@ local function UpdateMouse(self)
|
||||
local text = "[Mouse] X: ".. mouseX .." Y: ".. mouseY;
|
||||
coords:settext(text)
|
||||
end
|
||||
mou.InitCommand=cmd(SetUpdateFunction,UpdateMouse);
|
||||
mou.InitCommand=function(self)
|
||||
self:SetUpdateFunction();
|
||||
UpdateMouse();
|
||||
end;
|
||||
t[#t+1] = mou;
|
||||
|
||||
t[#t+1] = Def.ActorFrame{
|
||||
LoadFont("Common normal")..{
|
||||
Name="Title";
|
||||
Text=THEME:GetString("MouseTest","Title");
|
||||
InitCommand=cmd(CenterX;y,SCREEN_TOP+28;diffuse,color("#333333"));
|
||||
InitCommand=function(self)
|
||||
self:CenterX();
|
||||
self:y(SCREEN_TOP + 28);
|
||||
self:diffuse(color("#333333"));
|
||||
end;
|
||||
};
|
||||
LoadFont("Common normal")..{
|
||||
Name="Instructions";
|
||||
Text=THEME:GetString("MouseTest","Instructions");
|
||||
InitCommand=cmd(x,SCREEN_LEFT+12;align,0,0;y,SCREEN_TOP+42;diffuse,color("#333333");zoom,16/24;wrapwidthpixels,SCREEN_WIDTH*1.5);
|
||||
InitCommand=function(self)
|
||||
self:x(SCREEN_LEFT + 12);
|
||||
self:align(0, 0);
|
||||
self:y(SCREEN_TOP + 42);
|
||||
self:diffuse(color("#333333"));
|
||||
self:zoom(2 / 3);
|
||||
self:wrapwidthpixels(SCREEN_WIDTH * 1.5);
|
||||
end;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user