c-o
This commit is contained in:
@@ -0,0 +1,72 @@
|
||||
using StgSharp.Geometries;
|
||||
using StgSharp.Graphics;
|
||||
using StgSharp.Controls;
|
||||
using StgSharp.Controlling.UsrActivity;
|
||||
using StgSharp.Math;
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Net;
|
||||
using System.Text;
|
||||
|
||||
namespace StgSharp.Graphics
|
||||
{
|
||||
public class ViewPortDesigner
|
||||
{
|
||||
private KeyboardButtonGroup currentButtonGroup;
|
||||
|
||||
private List<ControllingItem> _controlList;
|
||||
|
||||
public ViewPortDesigner()
|
||||
{
|
||||
_controlList = new List<ControllingItem>();
|
||||
}
|
||||
|
||||
public KeyboardButtonGroup CreateKeyboardButtonGroup(
|
||||
ITrigger leftBidning,
|
||||
ITrigger rightBinding,
|
||||
ITrigger upBinding,
|
||||
ITrigger downBinding,
|
||||
ITrigger confirmBinding
|
||||
)
|
||||
{
|
||||
var ret = new KeyboardButtonGroup();
|
||||
_controlList.Add(ret);
|
||||
currentButtonGroup = ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
public TriggerButton CreateKeyboardButton(
|
||||
Rectangle bonding, AnimationBuilder defaultAnimation, bool isEnable
|
||||
)
|
||||
{
|
||||
var ret = new TriggerButton();
|
||||
ret.BoundingBox = bonding;
|
||||
if (isEnable)
|
||||
{
|
||||
ret.IsDisabled = false;
|
||||
ret.Enable(defaultAnimation);
|
||||
}
|
||||
else
|
||||
{
|
||||
ret.IsDisabled = true;
|
||||
ret.Disable(defaultAnimation);
|
||||
}
|
||||
currentButtonGroup.AddButton(ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public CharacterLineIndexImage CreateCharacterLine(
|
||||
int length, char blankFilling, PlainGeometryMesh tittle, IEnumerable<(char,PlainGeometryMesh)> charList
|
||||
)
|
||||
{
|
||||
var ret = new CharacterLineIndexImage(length, blankFilling,tittle,charList);
|
||||
_controlList.Add(ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
}//---------------------------------- End of Class -----------------------------------------
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user