Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
433 changes: 432 additions & 1 deletion Ports/Android/spotbugs-exclude.xml

Large diffs are not rendered by default.

27 changes: 8 additions & 19 deletions Ports/Android/src/com/codename1/impl/android/AndroidAsyncView.java
Original file line number Diff line number Diff line change
Expand Up @@ -1305,7 +1305,7 @@ public String toString() {
if(bgt == 0) {
return;
}
bgPaint = paintBackgroundSolidColor(bgt, s, bgPaint);
bgPaint = paintBackgroundSolidColor(bgt, s);
}
} else {
switch(backgroundType) {
Expand All @@ -1314,7 +1314,7 @@ public String toString() {
if(bgt == 0) {
return;
}
bgPaint = paintBackgroundSolidColor(bgt, s, bgPaint);
bgPaint = paintBackgroundSolidColor(bgt, s);
break;
case Style.BACKGROUND_IMAGE_SCALED:
final Paint bgImageScalePaint = new Paint();
Expand Down Expand Up @@ -1552,26 +1552,16 @@ public String toString() {
sc.backgroundPainter = bgPaint;
} else {
bgPaint.updateClip(clip, clipP, clipIsPath);
/*
if (clip == null) {
bgPaint.pendingClipW = cn1View.width;
bgPaint.pendingClipH = cn1View.height;
bgPaint.pendingClipX = 0;
bgPaint.pendingClipY = 0;
} else {
bgPaint.pendingClipW = clip.getWidth();
bgPaint.pendingClipH = clip.getHeight();
bgPaint.pendingClipX = clip.getX();
bgPaint.pendingClipY = clip.getY();
}
*/
}
if (bgPaint == null) {
return;
}
bgPaint.pendingX = x;
bgPaint.pendingY = y;
bgPaint.pendingHeight = height;
bgPaint.pendingWidth = width;
bgPaint.pendingAlpha = alpha;

pendingRenderingOperations.add(bgPaint);
}

Expand Down Expand Up @@ -1650,13 +1640,13 @@ public String toString() {
};
}

private AsyncPaintPosition paintBackgroundSolidColor(final byte bgt, Style s, AsyncPaintPosition bgPaint) {
private AsyncPaintPosition paintBackgroundSolidColor(final byte bgt, Style s) {
int c = ((bgt << 24) & 0xff000000) | (s.getBgColor() & 0xffffff);
final Paint pnt = new Paint();
pnt.setStyle(Paint.Style.FILL);
pnt.setColor(c);
pnt.setAntiAlias(false);
bgPaint = new AsyncPaintPosition(clip, clipP, clipIsPath) {
return new AsyncPaintPosition(clip, clipP, clipIsPath) {
@Override
public void executeImpl(AndroidGraphics underlying) {
if(bgt == 0) {
Expand All @@ -1668,7 +1658,6 @@ public String toString() {
return "SolidColorBackground";
}
};
return bgPaint;
}

class DrawStringCache {
Expand Down
Loading
Loading