非标
此特征是非标准的,且不在标准轨道中。不要在面向 Web 的生产站点中使用它:它不适用于每个用户。实现之间可能存在大的不兼容性,且行为将来可能改变。

msthumbnailclick event occurs when a user clicks a button or thumbnail icon in the taskbar.

This proprietary method is specific to Internet Explorer and Microsoft Edge.

句法

Event Property object.onmsthumbnailclick = handler;
addEventListener Method object.addEventListener("msthumbnailclick", handler, useCapture)

General info

Synchronous
No
冒泡
No
可取消
No

注意

The onmsthumbnailclick event is available only to documents that are launched from a pinned site shortcut.

参数

pEvtObj [in]

类型: IHTMLEventObj

Pointer to an IHTMLEventObj interface for the current event.

范例

function thumbnailClickHandler(evt)
{
    alert ("Clicked button: " + evt.buttonID);
}
document.addEventListener('msthumbnailclick', thumbnailClickHandler);
						

范例 2

// Adds an overlay icon on your app pinned to the taskbar
window.external.msSiteModeSetIconOverlay(iconUri, toolTip);
// removes an overlay icon
window.external.msSiteModeClearIconOverlay();
// pinned icons on your taskbar can be instructed to trigger specific events on your site from the taskbar
// add an event
handlerdocument.addEventListener('msthumbnailclick', onButtonClicked, false);
// add the buttons
var btnPlay = window.external.msSiteModeAddThumbBarButton(iconUri, toolTip);
// refresh the taskbar
window.external.msSiteModeShowThumbBar();
// call a javascript function when the button is pressed
function onButtonClicked(e) {
   switch (e.buttonID) {
     case btnPlay: play();
     break;}
 }
						

另请参阅

元数据

  • 最后修改:
  1. Msthumbnailclick