本文整理汇总了C#中ControlType类的典型用法代码示例。如果您正苦于以下问题:C# ControlType类的具体用法?C# ControlType怎么用?C# ControlType使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ControlType类属于命名空间,在下文中一共展示了ControlType类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: ReadLocalizationConfig
public static Dictionary<string, string> ReadLocalizationConfig(ControlType controlType)
{
string configPath = string.Format(configPathFormat, controlType.ToString(), RunTimeLocaliationTypeString);
Dictionary<string, string> dicNameValue = new Dictionary<string, string>();
if (File.Exists(configPath))
{
XmlDocument xd = new XmlDocument();
xd.Load(configPath);
XmlNodeList xnDataList = xd.SelectNodes("configuration/root/data");
foreach (XmlNode xn in xnDataList)
{
if (!dicNameValue.Keys.Contains(xn.Attributes["name"].Value))
{
dicNameValue.Add(xn.Attributes["name"].Value,xn.Attributes["value"].Value);
}
}
}
return dicNameValue;
}
开发者ID:zjk537,项目名称:CRM_4S,代码行数:25,代码来源:LocalizationConfigHandler.cs
示例2: cleanUpOnExit
public void cleanUpOnExit()
{
controlType = ControlType.None;
camera.enabled = false;
AudioListener aL = gameObject.GetComponent<AudioListener>();
aL.enabled = false;
}
开发者ID:dferretti3,项目名称:Perseus,代码行数:7,代码来源:firstPersonTower.cs
示例3: RaiseEvent
protected void RaiseEvent(List<Frame> frames, Vector3 calculateDisplacementVector, long duration, ControlType controlType)
{
if(MovementDetected != null)
{
MovementDetected(this, new MovementEventArgs(calculateDisplacementVector, duration, TJointType.HandLeft, controlType));
}
}
开发者ID:Styrna,项目名称:TKinect,代码行数:7,代码来源:DummyHandAnalyzer.cs
示例4: SetController
public static void SetController(ControlType controllerToUse)
{
Controller = controllerToUse;
if (Controller == ControlType.PS) offset = 0;
if (Controller == ControlType.Xbox) offset = 1;
if (Controller == ControlType.Pro) offset = 2;
}
开发者ID:Koba0100,项目名称:WarCrawl,代码行数:7,代码来源:PadButton.cs
示例5: Decode
public void Decode(byte[] bytes)
{
using (var ms = new MemoryStream(bytes))
{
Type = (ControlType) dc.GetInt16(ms.ReadBytes(2), 0);
switch (Type)
{
case ControlType.STREAM_BEGIN:
case ControlType.STREAM_EOF:
case ControlType.STREAM_DRY:
case ControlType.STREAM_IS_RECORDED:
StreamID = dc.GetInt32(ms.ReadBytes(4), 0);
break;
case ControlType.SET_BUFFER:
StreamID = dc.GetInt32(ms.ReadBytes(4), 0);
BufferLength = dc.GetInt32(ms.ReadBytes(4), 0);
break;
case ControlType.PING_REQUEST:
case ControlType.PING_RESPONSE:
Time = dc.GetInt32(ms.ReadBytes(4), 0);
break;
case ControlType.SWFV_REQUEST:
break;
case ControlType.SWFV_RESPONSE:
Bytes = ms.ReadBytes(42);
break;
case ControlType.BUFFER_FULL:
case ControlType.BUFFER_EMPTY:
StreamID = dc.GetInt32(ms.ReadBytes(4), 0);
break;
}
}
}
开发者ID:rgrochowicz,项目名称:RTMPStreamReader,代码行数:34,代码来源:Control.cs
示例6: MovementEventArgs
public MovementEventArgs(Vector3 displacement, long duration, TJointType jointType, ControlType controlType)
{
Displacement = displacement;
Duration = duration;
JointType = jointType;
ControlType = controlType;
}
开发者ID:Styrna,项目名称:TKinect,代码行数:7,代码来源:MovementEventArgs.cs
示例7: FormItemContext
public FormItemContext(object bindedData, Type datatype, PropertyInfo propinfo, ControlType ctype)
{
BindedData = bindedData;
DataType = datatype;
PropertyInfo = propinfo;
ControlType = ctype;
}
开发者ID:mogliang,项目名称:Generic-WPF-Form-Controls,代码行数:7,代码来源:FormItemContext.cs
示例8: SetControlType
void SetControlType()
{
ControlType controlType = this.controlType;
switch(this.touchType)
{
case TouchType.Click:
controlType = ControlType.Jump;
this.controlEventTime = 0;
break;
case TouchType.SweepLeft:
controlType = ControlType.TurnLeft;
this.controlEventTime = 0;
break;
case TouchType.SweepRight:
controlType = ControlType.TurnRight;
this.controlEventTime = 0;
break;
default:
if (this.controlEventTime > this.controlEventDelay)
{
controlType = ControlType.None;
}
this.controlEventTime += Time.deltaTime;
break;
}
this.controlType = controlType;
}
开发者ID:SBeator,项目名称:runningball,代码行数:29,代码来源:MobileInput.cs
示例9: ConvertToWControl
internal static Wix.Control ConvertToWControl(this IWixControl srcControl, ControlType controlType)
{
var wControl = new Wix.Control { Type = controlType.ToString() };
wControl.CopyCommonPropertiesFrom(srcControl);
return wControl;
}
开发者ID:denis-peshkov,项目名称:WixSharp,代码行数:8,代码来源:Extensions.cs
示例10: registerForInputEvents
/*
* Registers a listener for control events.
*/
public void registerForInputEvents(InputListener listener, ControlType type)
{
Control control = Controls[type];
if (!ListenerMap.ContainsKey(type))
ListenerMap[type] = new List<InputListener>();
ListenerMap[type].Add(listener);
}
开发者ID:zdawson,项目名称:Marooned,代码行数:11,代码来源:InputManager.cs
示例11: Control
public Control(ControlType type)
{
if (instance == null)
{
instance = this;
this.type = type;
}
}
开发者ID:pmyoung,项目名称:Advanced-Game-Project,代码行数:8,代码来源:Control.cs
示例12: makeActive
public void makeActive()
{
controlType = ControlType.Full;
camera.enabled = true;
AudioListener aL = gameObject.GetComponent<AudioListener>();
aL.enabled = true;
justActivated = true;
}
开发者ID:dferretti3,项目名称:Perseus,代码行数:8,代码来源:firstPersonTower.cs
示例13: cleanUpOnExit
public void cleanUpOnExit()
{
controlType = ControlType.None;
camera.enabled = false;
AudioListener aL = gameObject.GetComponent<AudioListener>();
aL.enabled = false;
Screen.lockCursor = false;
if (lineRenderer!=null) lineRenderer.enabled = false;
}
开发者ID:dferretti3,项目名称:Perseus,代码行数:9,代码来源:firstPersonTower.cs
示例14: makeActive
public void makeActive()
{
camera.enabled = true;
camType = ControlType.Full;
justActivated = true;
camera.rect = new Rect(0f,0f,1f,1f);
AudioListener aL = gameObject.GetComponent<AudioListener>();
aL.enabled = true;
}
开发者ID:dferretti3,项目名称:Perseus,代码行数:9,代码来源:homingMissileCamera.cs
示例15: AddControl
/// <summary>
/// Añade un control a la lista a partir de la definición del valor
/// </summary>
public void AddControl(string strKey, ControlType intType, string strTitle, string strValue, bool blnRequired)
{
ControlProperty udtResult = new ControlProperty();
// Carga los datos
udtResult.LoadValue(strKey, intType, strTitle, strValue, blnRequired);
// Añade el control a la lista
lsrValues.Add(udtResult);
}
开发者ID:jbautistam,项目名称:BauXmppMessenger,代码行数:12,代码来源:ListProperties.cs
示例16: openMiniScreen
public void openMiniScreen()
{
if (controlType == ControlType.None) {
cameraView.enabled = true;
controlType = ControlType.Inset;
} else {
controlType = ControlType.None;
}
}
开发者ID:dferretti3,项目名称:Perseus,代码行数:9,代码来源:AIControlledMissile.cs
示例17: Button
/*
Constructor must specify both Controller and Button Type
*/
public Button(ControlType control,ButtonType button) {
_controlType = control;
_buttonType = button;
_virtualName = "joystick";
if (_controlType != ControlType.Any) {
_virtualName += " " + ((int)(_controlType));
}
_virtualName += " button " + ((int)(_buttonType));
}
开发者ID:shingokko,项目名称:combocannon,代码行数:12,代码来源:Button.cs
示例18: makeActive
public void makeActive()
{
Screen.lockCursor = true;
cameraView.enabled = true;
controlType = ControlType.Full;
justActivated = true;
cameraView.rect = new Rect(0f,0f,1f,1f);
AudioListener aL = cameraView.gameObject.GetComponent<AudioListener>();
aL.enabled = true;
}
开发者ID:dferretti3,项目名称:Perseus,代码行数:10,代码来源:ControlledMissile.cs
示例19: OnModuleEnabled
public override void OnModuleEnabled()
{
setPIDParameters();
pid.Reset();
lastAct = Vector3d.zero;
worldVelocityDelta = Vector3d.zero;
prev_worldVelocityDelta = Vector3d.zero;
controlType = ControlType.VELOCITY_ERROR;
base.OnModuleEnabled();
}
开发者ID:Kerbas-ad-astra,项目名称:MechJeb2,代码行数:10,代码来源:MechJebModuleRCSController.cs
示例20: GetContolType
public override bool GetContolType(ControlType controlType)
{
if (controlType == this.controlType)
{
this.controlType = ControlType.None;
return true;
}
return false;
}
开发者ID:SBeator,项目名称:runningball,代码行数:10,代码来源:MobileInput.cs
注:本文中的ControlType类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论