getting error as $apply already in progress....
On Friday, April 6, 2012 1:17:14 AM UTC+5:30, Igor Minar wrote:
>
> looks like the third-party code is executing the location update
> asynchronously - outside of the angular context, so you have to replace:
>
> $location.path('/bar');
>
> with:
>
> $scope.$apply(function() {
> $location.path('/bar');
> });
>
> /i
>
>
>
> On Thu, Apr 5, 2012 at 12:50 AM, Mathias Verraes
> <[email protected]<javascript:>
> > wrote:
>
>> Hi,
>>
>> I'm trying to bind some actions to shortcut keys, using keymaster.js.
>> However, for some reason, changing $location doesn't affect the url, when
>> I'm inside a function passed to keymaster. Please see this example code:
>> https://gist.github.com/2308833
>> (it's not in jsfiddle because you can't see url changes in jsfiddle
>> anyway).
>>
>> Am I doing something wrong, or is this a bug in either keymaster or
>> angular?
>>
>> thanks!
>>
>> Mathias
>>
>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "AngularJS" group.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msg/angular/-/idZpDp5x_uUJ.
>> To post to this group, send email to [email protected]<javascript:>
>> .
>> To unsubscribe from this group, send email to
>> [email protected] <javascript:>.
>> For more options, visit this group at
>> http://groups.google.com/group/angular?hl=en.
>>
>
>
--
You received this message because you are subscribed to the Google Groups
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.