mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1136726. Remove PaintMode from TileLayer. r=kats
PaintMode is never changed from the default.
This commit is contained in:
parent
98ef649787
commit
dbb24f8c26
@ -37,7 +37,7 @@ public class PluginLayer extends TileLayer {
|
||||
};
|
||||
|
||||
public PluginLayer(View view, RectF rect, int maxDimension) {
|
||||
super(new IntSize(0, 0), TileLayer.PaintMode.NORMAL);
|
||||
super(new IntSize(0, 0));
|
||||
|
||||
mView = view;
|
||||
mContainer = GeckoAppShell.getGeckoInterface().getPluginContainer();
|
||||
|
@ -69,7 +69,7 @@ public class ScrollbarLayer extends TileLayer {
|
||||
private final Rect mEndCapTexCoords; // bottom/right endcap coordinates
|
||||
|
||||
ScrollbarLayer(LayerRenderer renderer, Bitmap scrollbarImage, IntSize imageSize, boolean vertical) {
|
||||
super(new IntSize(scrollbarImage.getHeight(), scrollbarImage.getWidth()), TileLayer.PaintMode.NORMAL);
|
||||
super(new IntSize(scrollbarImage.getHeight(), scrollbarImage.getWidth()));
|
||||
mImage = new BufferedImage(scrollbarImage);
|
||||
mRenderer = renderer;
|
||||
mVertical = vertical;
|
||||
@ -400,7 +400,7 @@ public class ScrollbarLayer extends TileLayer {
|
||||
GLES20.glTexParameterf(GLES20.GL_TEXTURE_2D, GLES20.GL_TEXTURE_MAG_FILTER,
|
||||
GLES20.GL_LINEAR);
|
||||
|
||||
int repeatMode = repeats() ? GLES20.GL_REPEAT : GLES20.GL_CLAMP_TO_EDGE;
|
||||
int repeatMode = GLES20.GL_CLAMP_TO_EDGE;
|
||||
GLES20.glTexParameterf(GLES20.GL_TEXTURE_2D, GLES20.GL_TEXTURE_WRAP_S, repeatMode);
|
||||
GLES20.glTexParameterf(GLES20.GL_TEXTURE_2D, GLES20.GL_TEXTURE_WRAP_T, repeatMode);
|
||||
}
|
||||
|
@ -15,22 +15,10 @@ import android.opengl.GLES20;
|
||||
public abstract class TileLayer extends Layer {
|
||||
private static final String LOGTAG = "GeckoTileLayer";
|
||||
|
||||
public enum PaintMode { NORMAL, REPEAT, STRETCH };
|
||||
private PaintMode mPaintMode;
|
||||
|
||||
public TileLayer(IntSize size, PaintMode paintMode) {
|
||||
public TileLayer(IntSize size) {
|
||||
super(size);
|
||||
|
||||
mPaintMode = paintMode;
|
||||
}
|
||||
|
||||
protected boolean repeats() { return mPaintMode == PaintMode.REPEAT; }
|
||||
protected boolean stretches() { return mPaintMode == PaintMode.STRETCH; }
|
||||
|
||||
public abstract void destroy();
|
||||
|
||||
public void setPaintMode(PaintMode mode) {
|
||||
mPaintMode = mode;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user