From 0bbd20f255b2954b5c41617fe718cf6eca36a972 Mon Sep 17 00:00:00 2001 From: Jan Laußmann Date: Mon, 17 Jun 2013 16:58:13 +0200 Subject: fix(mobile-ng-click): prevent unwanted opening of the soft keyboard Ghost clicks are busted but the corresponding form elements are still focused. This means that for example on smartphones the soft keyboard will be opened. This pull request prevents the unwanted opening of the soft keyboard. --- test/ngMobile/directive/ngClickSpec.js | 3 +++ 1 file changed, 3 insertions(+) (limited to 'test/ngMobile/directive/ngClickSpec.js') diff --git a/test/ngMobile/directive/ngClickSpec.js b/test/ngMobile/directive/ngClickSpec.js index 9038514c..52394977 100644 --- a/test/ngMobile/directive/ngClickSpec.js +++ b/test/ngMobile/directive/ngClickSpec.js @@ -211,7 +211,10 @@ describe('ngClick (mobile)', function() { expect($rootScope.count1).toBe(1); time = 90; + // Verify that it is blured so we don't get soft-keyboard + element1[0].blur = jasmine.createSpy('blur'); browserTrigger(element1, 'click', [], 10, 10); + expect(element1[0].blur).toHaveBeenCalled(); expect($rootScope.count1).toBe(1); -- cgit v1.2.3