From 22740ca443b3e9be67cf70cf9aea317c5ce2bba0 Mon Sep 17 00:00:00 2001 From: ankri Date: Thu, 9 Oct 2014 14:51:10 +0200 Subject: [PATCH] Add the possibility to have a custom scope This line adds the possibility to use a custom scope with $ionicLoading I found it useful to show the progress of the loading process. Demo: http://codepen.io/anon/pen/Ltign --- js/angular/service/loading.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/js/angular/service/loading.js b/js/angular/service/loading.js index 5e847cccef..bacfc22e31 100644 --- a/js/angular/service/loading.js +++ b/js/angular/service/loading.js @@ -114,6 +114,9 @@ function($ionicLoadingConfig, $ionicBody, $ionicTemplateLoader, $ionicBackdrop, $ionicTemplateLoader.load(options.templateUrl) : //options.content: deprecated $q.when(options.template || options.content || ''); + + + self.scope = options.scope || self.scope; if (!this.isShown) {