Web ブラウザー コントロールに表示される Web コンテンツを変更していて、すべての変更が適用されるまでそれらを表示しない方法を探しています。
私は現在 DocumentComplete イベントを使用していますが、一部のページをフィルタリングしている間、それらのコンテンツは表示されています。ですから、すべてが表示されるようになるまで非表示にしたいと思います。
simple.html
<html>
<head>
<style type="text/css">
div {
font-weight: bold;
}
</style>
</head>
<body><div>foo</div> bar</body>
</html>
デモスクリプト
new WBControl("file:///" A_ScriptDir "/simple.html")
class WBControl {
DocumentComplete(oParams*) {
doc := oParams[3].document
sleep 200 ; simulate a delay caused by a heavy task
doc.styleSheets[0].rules[0].style.fontweight := "normal"
}
__New(strURL="") {
static WB
Gui, New, Resize MaximizeBox
Gui, Add, ActiveX, vWB w780 h580, Shell.Explorer
Gui, show, w800 h600
ComObjConnect(WB, this)
WB.Navigate(strURL)
}
}
それを行う方法はありますか?