Skip to content

Commit e221de0

Browse files
committed
Load base layer before onDraw if maxTileDimensions are set #127
1 parent bbb4735 commit e221de0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

library/src/com/davemorrissey/labs/subscaleview/SubsamplingScaleImageView.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -1528,7 +1528,9 @@ private synchronized void onTilesInited(ImageRegionDecoder decoder, int sWidth,
15281528
this.sHeight = sHeight;
15291529
this.sOrientation = sOrientation;
15301530
checkReady();
1531-
checkImageLoaded();
1531+
if (!checkImageLoaded() && maxTileWidth > 0 && maxTileHeight > 0 && getWidth() > 0 && getHeight() > 0) {
1532+
initialiseBaseLayer(new Point(maxTileWidth, maxTileHeight));
1533+
}
15321534
invalidate();
15331535
requestLayout();
15341536
}

0 commit comments

Comments
 (0)