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

Commit

Permalink
fix(ace): resize editor when its width/height changes
Browse files Browse the repository at this point in the history
Merge branch 'ricochet1k-master'

Closes #26
  • Loading branch information
douglasduteil committed Jan 5, 2014
2 parents a21e3bd + 21f26dc commit b2024c1
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/ui-ace.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,13 @@ angular.module('ui.ace', [])
acee.session.$stopWorker();
acee.destroy();
});

scope.$watch(function() {
return [elm[0].offsetWidth, elm[0].offsetHeight];
}, function() {
acee.resize();
acee.renderer.updateFull();
}, true);
}
};
}]);

0 comments on commit b2024c1

Please sign in to comment.