Move some classes to Cryville.Common.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
using Cryville.Common.Reflection;
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
@@ -53,7 +54,7 @@ namespace Cryville.Common.Unity.Input {
|
||||
return Handler.GetHashCode() ^ Type;
|
||||
}
|
||||
public override string ToString() {
|
||||
return string.Format("{0}:{1}", ReflectionHelper.GetSimpleName(Handler.GetType()), Handler.GetTypeName(Type));
|
||||
return string.Format("{0}:{1}", TypeNameHelper.GetSimpleName(Handler.GetType()), Handler.GetTypeName(Type));
|
||||
}
|
||||
public static bool operator ==(InputSource lhs, InputSource rhs) {
|
||||
return lhs.Equals(rhs);
|
||||
|
@@ -1,3 +1,5 @@
|
||||
using Cryville.Common.Logging;
|
||||
using Cryville.Common.Reflection;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Reflection;
|
||||
@@ -21,10 +23,10 @@ namespace Cryville.Common.Unity.Input {
|
||||
var h = (InputHandler)Activator.CreateInstance(t);
|
||||
_typemap.Add(t, h);
|
||||
_handlers.Add(h);
|
||||
Logger.Log("main", 1, "Input", "Initialized {0}", ReflectionHelper.GetSimpleName(t));
|
||||
Logger.Log("main", 1, "Input", "Initialized {0}", TypeNameHelper.GetSimpleName(t));
|
||||
}
|
||||
catch (TargetInvocationException ex) {
|
||||
Logger.Log("main", 1, "Input", "Cannot initialize {0}: {1}", ReflectionHelper.GetSimpleName(t), ex.InnerException.Message);
|
||||
Logger.Log("main", 1, "Input", "Cannot initialize {0}: {1}", TypeNameHelper.GetSimpleName(t), ex.InnerException.Message);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -9,6 +9,7 @@ using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using UnityEngine;
|
||||
using Logger = Cryville.Common.Logging.Logger;
|
||||
|
||||
namespace Cryville.Common.Unity.Input {
|
||||
public class WindowsPointerHandler : InputHandler {
|
||||
|
Reference in New Issue
Block a user