fix: Horizontal scrollbar breaks selection

This commit is contained in:
Fabian Jakobs 2010-04-28 09:29:50 +02:00
commit 06e21af2f4
2 changed files with 3 additions and 4 deletions

View file

@ -29,20 +29,19 @@
} }
.layer { .layer {
z-index: 0;
position: absolute; position: absolute;
overflow: hidden; overflow: hidden;
white-space: nowrap; white-space: nowrap;
} }
.text-layer { .text-layer {
z-index: 2;
font-family: Monaco, "Courier New", monospace; font-family: Monaco, "Courier New", monospace;
cursor: text; cursor: text;
color: black; color: black;
} }
.cursor-layer { .cursor-layer {
z-index: 3;
} }
.cursor { .cursor {
@ -55,7 +54,6 @@
} }
.marker-layer { .marker-layer {
z-index: 1;
} }
.marker-layer .selection { .marker-layer .selection {

View file

@ -62,7 +62,8 @@ ace.VirtualRenderer = function(container) {
}; };
this.getMouseEventTarget = function() { this.getMouseEventTarget = function() {
return this.scroller; // return top most layer
return this.cursorLayer.element;
}; };
this.getFirstVisibleRow = function() { this.getFirstVisibleRow = function() {