I'm trying to modify eventHandler on fa-pipe-to in my controler but modification is not working.
In my view, i have a 'scroll-view' with a surfaces loop.
Each surface pipe a event handler.
<fa-scroll-view fa-pipe-from="scrollEventHandler">
<fa-view ng-repeat="tile in tiles">
<fa-modifier fa-transform="tile.transform">
<fa-container-surface fa-pipe-to="tile.eventHandler">
<fa-modifier fa-opacity="tile.opacity">
<fa-surface fa-background-color="tile.color"/>
</fa-modifier>
</fa-container-surface>
</fa-modifier>
</fa-view>
</fa-scroll-view>
In my controller, I have an object with 2 eventHandlers :
function Object() {
this.eventHandler = null;
$scope.scrollEventHandler = new EventHandler();
var dragEventHandler = new GenericSync();
var activateDragMode = function() {
this.eventHandler = dragEventHandler;
}
}
By default I use scrollEventHandler and it works :
this.eventHandler = $scope.scrollEventHandler;
But during execution i want to switch to other eventHandler :
activateDragMode();
So my problem is : when i set new eventHandler to 'eventHandler' variable, eventHandler is not updated.
Does anyone has a solution to do it?