Merge pull request #1488 from ajaxorg/renderer

Renderer improvements
This commit is contained in:
Ruben Daniels 2013-06-27 07:55:22 -07:00
commit 81f7dd7fbb
13 changed files with 395 additions and 256 deletions

View file

@ -990,7 +990,7 @@ var EditSession = function(text, mode) {
*
**/
this.setScrollTop = function(scrollTop) {
scrollTop = Math.round(Math.max(0, scrollTop));
scrollTop = Math.round(scrollTop);
if (this.$scrollTop === scrollTop || isNaN(scrollTop))
return;
@ -1011,7 +1011,7 @@ var EditSession = function(text, mode) {
* [Sets the value of the distance between the left of the editor and the leftmost part of the visible content.]{: #EditSession.setScrollLeft}
**/
this.setScrollLeft = function(scrollLeft) {
scrollLeft = Math.round(Math.max(0, scrollLeft));
scrollLeft = Math.round(scrollLeft);
if (this.$scrollLeft === scrollLeft || isNaN(scrollLeft))
return;