[英]imitate on-tap at angular element
I'm excuse for possible repeat question, but I didn't find solution for my problem. 我为可能的重复问题找借口,但是我没有找到解决问题的方法。
There is a simulation of button click when controller is loading. 加载控制器时模拟了单击按钮。 It worked good until I changed
ng-click
to on-tap
(ionic application). 在我将
ng-click
更改on-tap
(离子应用)之前,它一直很好。 Now it doesn't work at all. 现在,它根本不起作用。 How can I imitate click for
on-tap
? 如何模仿点击以
on-tap
?
Previous version of imitate: 以前版本的模仿:
var triggeredButton = document.getElementById('some_id');
angular.element(triggeredButton).triggerHandler('click');
angular.element(triggeredButton).triggerHandler('mousedown');
要么
angular.element(triggeredButton).triggerHandler('touchstart mousedown');
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.