Skip to content
This repository has been archived by the owner on Sep 15, 2021. It is now read-only.

Commit

Permalink
fix(plugin:inappbrowser): rename loadstart, loadstop, loaderror, exit…
Browse files Browse the repository at this point in the history
… to $cordovaInAppBrowser:[event] for standardisation
  • Loading branch information
pbernasconi committed Jan 13, 2015
1 parent 743ce58 commit dea2b8e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/plugins/inappbrowser.js
Expand Up @@ -29,21 +29,21 @@ angular.module('ngCordova.plugins.inAppBrowser', [])
win = $window.open(url, target, options);

win.addEventListener('loadstart', function (event) {
scope.$emit('loadstart', event);
scope.$broadcast('$cordovaInAppBrowser:loadstart', event);
}, false);

win.addEventListener('loadstop', function (event) {
q.resolve(event);
scope.$emit('loadstop', event);
scope.$broadcast('$cordovaInAppBrowser:loadstop', event);
}, false);

win.addEventListener('loaderror', function (event) {
q.reject(event);
scope.$emit('loaderror', event);
scope.$broadcast('$cordovaInAppBrowser:loaderror', event);
}, false);

win.addEventListener('exit', function (event) {
scope.$emit('exit', event);
scope.$broadcast('$cordovaInAppBrowser:exit', event);
}, false);

return q.promise;
Expand Down

0 comments on commit dea2b8e

Please sign in to comment.