Skip to content

Commit d2de8e3

Browse files
arunjose696HeikoKlare
authored andcommitted
Reverting a sideeffect introduced in #2526
This commit reverts the changes introduced in #2526 where getImageData and getScaledImageData were mistakenly interchanged. The initial approach aimed to use this method in loadImageDataClosestTo when images couldn't be loaded at the exact size. However, the final implementation used loadImageData(zoom) instead, making those changes unnecessary. These leftover modifications were an unintended side effect, and this commit removes them.
1 parent 3065112 commit d2de8e3

File tree

1 file changed

+2
-2
lines changed
  • bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/graphics

1 file changed

+2
-2
lines changed

bundles/org.eclipse.swt/Eclipse SWT/win32/org/eclipse/swt/graphics/Image.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2028,7 +2028,7 @@ protected Optional<ImageData> loadImageDataAtExactSize(int width, int height) {
20282028
}
20292029

20302030
protected ImageHandle newImageHandle(ZoomContext zoomContext) {
2031-
ImageData resizedData = getScaledImageData (zoomContext.targetZoom());
2031+
ImageData resizedData = getImageData (zoomContext.targetZoom());
20322032
return newImageHandle(resizedData, zoomContext);
20332033
}
20342034

@@ -2070,7 +2070,7 @@ protected Rectangle getBounds(int zoom) {
20702070

20712071
@Override
20722072
ImageData newImageData(ZoomContext zoomContext) {
2073-
return getImageData(zoomContext.targetZoom());
2073+
return getScaledImageData(zoomContext.targetZoom());
20742074
}
20752075

20762076
@Override

0 commit comments

Comments
 (0)