只能触发函数的执行,并不能完全模拟出实际的点击。
if (document.createEvent) {
var clickEvent = document.createEvent("MouseEvents");
clickEvent.initEvent("click", false, true);
this.fileEl.dom.dispatchEvent(clickEvent);//ff
} else if (document.createEventObject) {
this.fileEl.dom.fireEvent("onclick", document.createEventObject(e.browserEvent));//ie
}