From f5fc7672f432218786e278b0729030bc6c4bbf70 Mon Sep 17 00:00:00 2001 From: Dave Hoover Date: Wed, 24 Feb 2010 01:30:41 +0000 Subject: [PATCH] Varags logging git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@892 ed5b42cb-e716-0410-a449-f6a68f950b19 --- src/java/com/threerings/media/RegionManager.java | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/src/java/com/threerings/media/RegionManager.java b/src/java/com/threerings/media/RegionManager.java index 78a802d4..8f6a4df9 100644 --- a/src/java/com/threerings/media/RegionManager.java +++ b/src/java/com/threerings/media/RegionManager.java @@ -28,8 +28,6 @@ import java.awt.Rectangle; import com.google.common.collect.Lists; -import com.samskivert.util.StringUtil; - import static com.threerings.media.Log.log; /** @@ -68,8 +66,7 @@ public class RegionManager { // make sure we're on an AWT thread if (!EventQueue.isDispatchThread()) { - log.warning("Oi! Region dirtied on non-AWT thread [rect=" + rect + "].", - new Exception()); + log.warning("Oi! Region dirtied on non-AWT thread", "rect", rect, new Exception()); } // sanity check @@ -81,8 +78,7 @@ public class RegionManager // more sanity checking long x = rect.x, y = rect.y; if ((Math.abs(x) > Integer.MAX_VALUE/2) || (Math.abs(y) > Integer.MAX_VALUE/2)) { - log.warning("Requested to dirty questionable region " + - "[rect=" + StringUtil.toString(rect) + "]."); + log.warning("Requested to dirty questionable region", "rect", rect); return; // Let's not do it! } @@ -96,8 +92,8 @@ public class RegionManager protected final boolean isValidSize (int width, int height) { if (width < 0 || height < 0) { - log.warning("Attempt to add invalid dirty region?! " + - "[size=" + width + "x" + height + "].", new Exception()); + log.warning("Attempt to add invalid dirty region?!", + "size", (width + "x" + height), new Exception()); return false; } else if (width == 0 || height == 0) { @@ -130,8 +126,8 @@ public class RegionManager /** * Merges all outstanding dirty regions into a single list of rectangles and returns that to - * the caller. Interally, the list of accumulated dirty regions is cleared out and prepared for - * the next frame. + * the caller. Internally, the list of accumulated dirty regions is cleared out and prepared + * for the next frame. */ public Rectangle[] getDirtyRegions () {