|
From: <bur...@us...> - 2012-06-09 08:05:56
|
Revision: 9885
http://freecol.svn.sourceforge.net/freecol/?rev=9885&view=rev
Author: burschik
Date: 2012-06-09 08:05:50 +0000 (Sat, 09 Jun 2012)
Log Message:
-----------
Remove "pluto".
Modified Paths:
--------------
freecol/trunk/src/net/sf/freecol/client/gui/panel/MiniMap.java
Modified: freecol/trunk/src/net/sf/freecol/client/gui/panel/MiniMap.java
===================================================================
--- freecol/trunk/src/net/sf/freecol/client/gui/panel/MiniMap.java 2012-06-08 10:23:11 UTC (rev 9884)
+++ freecol/trunk/src/net/sf/freecol/client/gui/panel/MiniMap.java 2012-06-09 08:05:50 UTC (rev 9885)
@@ -169,7 +169,7 @@
|| freeColClient.getGame().getMap() == null) {
return;
}
-
+
graphics.drawImage(backgroundImage, 0, 0, null);
paintMap(graphics);
}
@@ -185,7 +185,7 @@
* to draw this component.
*/
public void paintMap(Graphics graphics) {
-
+
int width = getWidth();
int height = getHeight();
final Graphics2D g = (Graphics2D) graphics;
@@ -203,9 +203,9 @@
if (gui.getFocus() == null) {
return;
}
-
+
/* xSize and ySize represent how many tiles can be represented on the
mini map at the current zoom level */
int xSize = width / tileSize;
@@ -278,7 +278,7 @@
final ImageLibrary library = gui.getImageLibrary();
-
+
// Row per row; start with the top modified row
for (int row = firstRow; row <= lastRow; row++) {
rowTransform = g.getTransform();
@@ -313,16 +313,14 @@
g.translate(0, halfHeight);
}
g.setTransform(baseTransform);
-
-
- System.out.println("pluto");
-
+
+
/* Defines where to draw the white rectangle on the mini map.
* miniRectX/Y are the center of the rectangle.
* Use miniRectWidth/Height / 2 to get the upper left corner.
* x/yTiles are the number of tiles that fit on the large map */
-
+
if (getParent() != null) {
TileType tileType = freeColClient.getGame().getSpecification().getTileTypeList().get(0);
int miniRectX = (gui.getFocus().getX() - firstColumn) * tileSize;
@@ -341,30 +339,30 @@
}
g.setColor(ResourceManager.getColor("miniMapBorder.color"));
- // Use Math max and min to prevent the rect from being larger than the minimap.
+ // Use Math max and min to prevent the rect from being larger than the minimap.
int miniRectMaxX = Math.max(miniRectX - miniRectWidth / 2, 0);
int miniRectMaxY = Math.max(miniRectY - miniRectHeight / 2, 0);
int miniRectMinWidth = Math.min(miniRectWidth, width - 1);
int miniRectMinHeight = Math.min(miniRectHeight, height - 1);
- // Prevent the rect from overlapping the bigger adjust rect
+ // Prevent the rect from overlapping the bigger adjust rect
if(miniRectMaxX + miniRectMinWidth > width - 1) {
miniRectMaxX = width - miniRectMinWidth - 1;
}
if(miniRectMaxY + miniRectMinHeight > height - 1) {
miniRectMaxY = height - miniRectMinHeight - 1;
}
- // Draw the rect.
+ // Draw the rect.
g.drawRect(miniRectMaxX, miniRectMaxY, miniRectMinWidth, miniRectMinHeight);
- // Draw an additional rect, if the whole map is shown on the minimap
+ // Draw an additional rect, if the whole map is shown on the minimap
if (adjustX > 0 && adjustY > 0) {
g.setColor(ResourceManager.getColor("miniMapBorder.color"));
g.drawRect(0, 0, width - 1, height - 1);
}
}
g.setTransform(originTransform);
-
-
-
+
+
+
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|