fix cubetree init crash.

This commit is contained in:
2026-02-17 15:51:23 +08:00
parent 1a8a3b59d2
commit a21240016f
671 changed files with 12580 additions and 1166 deletions
@@ -486,7 +486,7 @@ public RenderingCanvas()
DisplayerPane.TouchDown += RenderingCanvas_TouchDown;
DisplayerPane.TouchMove += RenderingCanvas_TouchMove;
DisplayerPane.TouchUp += RenderingCanvas_TouchUp;
// Enable touch support
this.IsManipulationEnabled = true;
@@ -512,7 +512,7 @@ private unsafe void RenderingCanvas_BufferSwapped(byte* data, int w, int h)
byte[] arr = new byte[n];
for (int i = 0; i < n; i++)
arr[i] = data[i];
// Update UI on the UI thread
DisplayerPane.Dispatcher.InvokeAsync(() =>
{
@@ -741,7 +741,7 @@ private unsafe void RenderingCanvas_Loaded(object sender, RoutedEventArgs e)
{
// Get the window containing this control
CurrentWindow = Window.GetWindow(this);
// Set up DispEngine rendering
DispEngine.ImageRequestAfterBufferSwapped -= RenderingCanvas_BufferSwapped;
DispEngine.ImageRequestAfterBufferSwapped += RenderingCanvas_BufferSwapped;
@@ -775,7 +775,7 @@ protected virtual void Dispose(bool disposing)
{
// Unsubscribe from power events
SystemEvents.PowerModeChanged -= SystemEvents_PowerModeChanged;
// Dispose the DispEngine to free resources
DispEngine.Dispose();
}
@@ -843,7 +843,7 @@ engine.SetViewToHomeView();
</tr>
<tr>
<td>Key press</td>
<td>&lt;xref:Hi.Disp.DispEngine.KeyDown(System.Int64)&gt; / &lt;xref:Hi.Disp.DispEngine.KeyUp(System.Int64)&gt; and &lt;xref:Hi.Disp.DispEngine.KeyDownTransform(System.Int64,Hi.Native.key_table__transform_view_by_key_pressing_t)&gt;</td>
<td><a class="xref" href="../../../../api/Hi.Disp.DispEngine.html#Hi_Disp_DispEngine_KeyDown_System_String_">KeyDown(string)</a> / <a class="xref" href="../../../../api/Hi.Disp.DispEngine.html#Hi_Disp_DispEngine_KeyUp_System_String_">KeyUp(string)</a> and <a class="xref" href="../../../../api/Hi.Disp.DispEngine.html#Hi_Disp_DispEngine_KeyDownTransform_System_String_Hi_Native_key_table__transform_view_by_key_pressing_t_">KeyDownTransform(string, key_table__transform_view_by_key_pressing_t)</a></td>
</tr>
<tr>
<td>Touch events</td>