<ItemGroup Condition="$(TargetFramework.StartsWith('netstandard'))">
<PackageReference Include="System.Reflection.Emit.ILGeneration" Version="4.6.0" />
<PackageReference Include="System.Reflection.Emit.Lightweight" Version="4.6.0" />
- <PackageReference Include="glfw-sharp" Version="0.2.7-beta" />
+ <PackageReference Include="glfw-sharp" Version="0.2.9-beta" />
<PackageReference Include="FastEnum" Version="1.5.3" />
</ItemGroup>
<PropertyGroup Condition=" '$(CrowStbSharp)' == 'true'">
//value type for conversion
CompilerServices.emitConvert (il, piSource.PropertyType);
- if (!piSource.CanWrite)
- throw new Exception ("Source member of bindind is read only:" + piSource.ToString());
+ if (piSource.SetMethod == null)
+ throw new Exception ("Source member of bindind is read only:" + piSource.ToString ());
il.Emit (OpCodes.Callvirt, piSource.GetSetMethod ());
Cursor currentCursor;
bool ownWindow;
+ protected void registerGlfwCallbacks ()
+ {
+ windows.Add (hWin, this);
+ Glfw3.SetKeyCallback (hWin, HandleKeyDelegate);
+ Glfw3.SetMouseButtonPosCallback (hWin, HandleMouseButtonDelegate);
+ Glfw3.SetCursorPosCallback (hWin, HandleCursorPosDelegate);
+ Glfw3.SetScrollCallback (hWin, HandleScrollDelegate);
+ Glfw3.SetCharCallback (hWin, HandleCharDelegate);
+ Glfw3.SetWindowSizeCallback (hWin, HandleWindowSizeDelegate);
+ }
+
void initSurface ()
{
Glfw3.Init ();
throw new Exception ("[GLFW3] Unable to create vulkan Window");
ownWindow = true;
- Glfw3.SetKeyCallback (hWin, HandleKeyDelegate);
- Glfw3.SetMouseButtonPosCallback (hWin, HandleMouseButtonDelegate);
- Glfw3.SetCursorPosCallback (hWin, HandleCursorPosDelegate);
- Glfw3.SetScrollCallback (hWin, HandleScrollDelegate);
- Glfw3.SetCharCallback (hWin, HandleCharDelegate);
- Glfw3.SetWindowSizeCallback (hWin, HandleWindowSizeDelegate);
+ registerGlfwCallbacks ();
switch (Environment.OSVersion.Platform) {
case PlatformID.MacOSX:
case PlatformID.WinCE:
throw new PlatformNotSupportedException ("Unable to create cairo surface.");
}
-
- windows.Add (hWin, this);
}
#region events delegates
#region focus
Widget _activeWidget; //button is pressed on widget
Widget _hoverWidget; //mouse is over
- Widget _focusedWidget; //has keyboard (or other perif) focus
+ internal Widget _focusedWidget; //has keyboard (or other perif) focus
/// <summary>Widget is focused and button is down or another perif action is occuring
/// , it can not lose focus while Active</summary>