5
The documentation說:如何檢測附加SDK面板何時顯示?
顯示
顯示面板時,該事件被髮射。
所以在main.js
我這樣做(其中thePanel
使用require("panel").Panel
法):
thePanel.port.on("show", function(d) {
console.log('The panel has just been shown');
});
但事件似乎並沒有被調用。我也試過在window.onfocus
的內容腳本中做一個函數,但是這個函數看起來並沒有被調用。
謝謝,這清除了事情。 – Tom