|
@@ -1,8 +1,10 @@
|
|
|
using fis.Mac;
|
|
|
using fis.Utilities;
|
|
|
using fis.Win;
|
|
|
+using fis.Win.Handlers;
|
|
|
using System;
|
|
|
using System.Collections.Generic;
|
|
|
+using System.IO;
|
|
|
using System.Runtime.InteropServices;
|
|
|
using Xilium.CefGlue;
|
|
|
using Xilium.CefGlue.Avalonia;
|
|
@@ -83,6 +85,18 @@ namespace fis.Managers
|
|
|
}
|
|
|
_requestHandler = new HostRequestHandler();
|
|
|
var appHandler = new FileSystemHostHandler(ShellConfig.Instance.AppHost, ShellConfig.Instance.AppResourcePath);
|
|
|
+ //从Zip创建Handler
|
|
|
+ //Zip路径:ShellConfig.Instance.AppResourcePath + "flyinsono.zip", 即 软件目录\App\flyinsono\flyinsono.zip
|
|
|
+ //Zip包内容结构:
|
|
|
+ //flyinosno.zip
|
|
|
+ // -flyinsono
|
|
|
+ // -canvicekit
|
|
|
+ // -canvaskit.js
|
|
|
+ // -...
|
|
|
+ // -index.html
|
|
|
+ // -flutter.js
|
|
|
+ // -.....
|
|
|
+ //var appHandler = new ZipHandler(ShellConfig.Instance.AppHost, Path.Combine(ShellConfig.Instance.AppResourcePath, "flyinsono.zip"));
|
|
|
var resourceHandler = new FileSystemHostHandler(ShellConfig.Instance.LocalResourceHost, ShellConfig.Instance.LocalResourcePath);
|
|
|
var platformHandler = new JsonRpcHandler<IPlatformService>(ShellConfig.Instance.LocalApiHost, _platformService);
|
|
|
_requestHandler.RegisterHostHandler(appHandler);
|