tablacus / tablacusexplorerwebview2 Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
DATEオブジェクトに .getVarDate() が無い
対策: ,getTime() で UNIX EPOCH を取得して変換する仕様を追加
WebView2 クラス (CoreWebView2 クラス) に書いている通り
HRESULT_FROM_WIN32 (ERROR_POSSIBLE_DEADLOCK) で失敗します。
オブジェクトは AddHostObjectToScript で渡せるので、引数はオブジェクトで渡すことにして、ExecuteScriptAsync を実行すればなんとかならないかな。
2020-9-21追記
Blink側で非同期でオブジェクトを受け取ると 返り値は受け取れないが呼び出すことは可能であった。
async await 辺りを使って行くが、IEでエラーを出さないためにはどうすれば……
現在、Tablacus Explorerのアドレスバー、ツールバー等はIEのレンダリングエンジンであるTridentを使っています。それを新Edge(Chromium)のレンダリングエンジンのBlinkを使う様にする計画です。表面的に何かが変わるかとかは正直やってみないとわかりません。
This is what I did:
lib
folder to the TE install folder.Result:
WebView2ではマルチプロセスのため、ネイティブのIDropTargetを抜き出すのができなかった。
必要な場合はHTML5のドラッグ&ドロップAPIで補う必要がある。
※多分、VARIANTのSAFEARRAYはVBSの配列と同じ
逆にVARIANTのSAFEARRAYを渡すと配列として使える模様
Arrayオブジェクトはstd::vectorベースからSAFEARRAYを利用するものに作り直し
配列のtypeofはobject
Blink側で扱うのはSAFEARRAYが良さそうだけど、マルチスレッドとかまだActiveScript使わないとできなそうなので
そのあたりが課題
XMLHttpRequestのresponseBodyが無くなっているのでいろいろやっている際に気付いたんだけど、文字列の受け渡しの際はNULL文字で切られてしまう
XMLHttpRequestの方はbase64を活用することでしのぐことにしたが、
SHFileOperation でpFromに複数の項目をしていする際に \0 で区切るので2つ目から無効になってしまう。
これは配列渡しを可能にすることにする。
https://docs.microsoft.com/en-us/windows/win32/api/shellapi/nf-shellapi-shfileoperationa
Tablacus Explorerの実行ファイルではほぼ Trident用のインターフェイス IWebBrowser2 でブラウザ関連の操作を行っている。
Blink版Tablacus Explorerの肝である TablacusExplorerWebView2の DLL は IWebBrowser2 のフリをして内部ではChromium版 Edge のインターフェイス WebView2 を使って Trident の代わりに Blink を使用している。
Tablacus Explorer で 使っている IWebBrowser2 は限られているので、代行させてもそんなにオーバーヘッドにならないと思う。
連想配列のオブジェクトで新規項目を追加しようとすると固まる。
オブジェクトはIDispatchだけでIDispatchExは使われない模様。
新規項目についてはIDispatchだけでなんとかする方法にできたけど、項目を削除するdelete ○○とかfor in ○○がTablacus Explorerのオブジェクトでは使えないくなってしまうのが問題
WSH関連のオブジェクトはIDispatchExを使っていないはずなので、その辺りは救い。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.