diff -r 8faf835f2286 javafx-ui-common/src/javafx/scene/layout/ClipView.fx --- a/javafx-ui-common/src/javafx/scene/layout/ClipView.fx Wed Feb 24 19:33:10 2010 -0800 +++ b/javafx-ui-common/src/javafx/scene/layout/ClipView.fx Fri Feb 26 10:39:01 2010 -0800 @@ -58,8 +58,10 @@ * applying a negative translation to the content of 10. */ public var clipX:Number on replace { - if (clipX > maxClipX) then clipX = maxClipX; - if (clipX < 0) then clipX = 0; + if(not isReadOnly(clipX)) { + if (clipX > maxClipX) then clipX = maxClipX; + if (clipX < 0) then clipX = 0; + } }; /** @@ -72,8 +74,10 @@ * applying a negative translation to the content of 10. */ public var clipY:Number on replace { - if (clipY > maxClipY) then clipY = maxClipY; - if (clipY < 0) then clipY = 0; + if (not isReadOnly(clipY)) { + if (clipY > maxClipY) then clipY = maxClipY; + if (clipY < 0) then clipY = 0; + } }; /** @@ -90,7 +94,7 @@ Utils.clamp(0, node.boundsInParent.maxX - width, Float.MAX_VALUE) } } on replace { - if (clipX > maxClipX) then clipX = maxClipX; + if ((not isReadOnly(clipX)) and clipX > maxClipX) then clipX = maxClipX; } /** @@ -107,7 +111,7 @@ Utils.clamp(0, node.boundsInParent.maxY - height, Float.MAX_VALUE) } } on replace { - if (clipY > maxClipY) then clipY = maxClipY; + if ((not isReadOnly(clipY)) and clipY > maxClipY) then clipY = maxClipY; } /** @@ -203,9 +207,12 @@ // negative when dragged to the right/bottom var deltaX = pressEvent.x - e.x; var deltaY = pressEvent.y - e.y; - - clipX = pressClipX + deltaX; - clipY = pressClipY + deltaY; + if (not isReadOnly(clipX)) { + clipX = pressClipX + deltaX; + } + if (not isReadOnly(clipY)) { + clipY = pressClipY + deltaY; + } } }