Merge branch 'master' of github.com:ajaxorg/ace into mobile

This commit is contained in:
Sergi Mansilla 2011-02-27 12:45:08 +01:00
commit b3b26a311b
2 changed files with 16 additions and 4 deletions

View file

@ -114,11 +114,15 @@ var Text = function(parentEl) {
// Note: characterWidth can be a float!
measureNode.innerHTML = lang.stringRepeat("Xy", n);
var container = this.element.parentNode;
while (!dom.hasCssClass(container, "ace_editor"))
container = container.parentNode;
if (document.body) {
document.body.appendChild(measureNode);
} else {
var container = this.element.parentNode;
while (!dom.hasCssClass(container, "ace_editor"))
container = container.parentNode;
container.appendChild(measureNode);
}
container.appendChild(measureNode);
}
var style = this.$measureNode.style;

View file

@ -277,6 +277,10 @@ var VirtualRenderer = function(container, theme) {
this.getPrintMarginColumn = function() {
return this.$printMarginColumn;
};
this.getShowGutter = function(){
return this.showGutter;
}
this.setShowGutter = function(show){
if(this.showGutter === show)
@ -365,6 +369,10 @@ var VirtualRenderer = function(container, theme) {
this.$updatePrintMargin();
};
this.getHScrollBarAlwaysVisible = function() {
return this.$horizScrollAlwaysVisible;
}
this.setHScrollBarAlwaysVisible = function(alwaysVisible) {
if (this.$horizScrollAlwaysVisible != alwaysVisible) {
this.$horizScrollAlwaysVisible = alwaysVisible;