This commit is contained in:
Hannes Janetzek 2013-01-30 03:53:57 +01:00
parent 123284a1a5
commit cdc2e7308f
2 changed files with 4 additions and 6 deletions

View File

@ -1,4 +1,5 @@
/*
* Copyright 2010, 2011, 2012 mapsforge.org
* Copyright 2012, 2013 OpenScienceMap
*
* This program is free software: you can redistribute it and/or modify it under the
@ -27,7 +28,7 @@ public class JobQueue {
/**
* @param tiles
* the job to be added to this queue.
* the jobs to be added to this queue.
*/
public synchronized void setJobs(JobTile[] tiles) {
for (JobTile t : tiles)
@ -70,13 +71,11 @@ public class JobQueue {
return null;
if (mCurrentJob == 0) {
//Arrays.sort(mJobs);
int len = mJobs.length;
if (len > 1)
TileDistanceSort.sort(mJobs, 0, len);
}
//return mPriorityQueue.poll();
JobTile t = mJobs[mCurrentJob];
mJobs[mCurrentJob] = null;

View File

@ -27,7 +27,6 @@ import android.graphics.Paint.Align;
import android.graphics.Paint.FontMetrics;
import android.graphics.Paint.Style;
import android.graphics.Typeface;
import android.util.FloatMath;
/**
* Represents a text along a polyline on the map.
@ -163,8 +162,8 @@ public final class Text extends RenderInstruction {
this.fontSize = fontSize;
FontMetrics fm = paint.getFontMetrics();
fontHeight = FloatMath.ceil(Math.abs(fm.bottom) + Math.abs(fm.top));
fontDescent = FloatMath.ceil(Math.abs(fm.descent));
fontHeight = (float) Math.ceil(Math.abs(fm.bottom) + Math.abs(fm.top));
fontDescent = (float) Math.ceil(Math.abs(fm.descent));
}
@Override