From 8de587d4fcd1455c85975bee39393d6f7cd7e3e6 Mon Sep 17 00:00:00 2001 From: Aparajita Fishman Date: Sat, 4 Jun 2011 10:58:38 -0700 Subject: [PATCH] Only log the connection info if _source and _destination are defined. Runtime attribute connections do not have both. Correctly show boolean value types as BOOL, not CPNumber. --- Tools/nib2cib/NSNibConnector.j | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Tools/nib2cib/NSNibConnector.j b/Tools/nib2cib/NSNibConnector.j index 6633da218..15c274fe1 100644 --- a/Tools/nib2cib/NSNibConnector.j +++ b/Tools/nib2cib/NSNibConnector.j @@ -54,7 +54,8 @@ NIB_CONNECTION_EQUIVALENCY_TABLE = {}; _destination = NIB_CONNECTION_EQUIVALENCY_TABLE[destinationUID]; } - CPLog.debug(@"NSNibConnector: connection: " + [_source description] + " " + [_destination description] + " " + _label); + if (_source && _destination) + CPLog.debug(@"NSNibConnector: connection: " + [_source description] + " " + [_destination description] + " " + _label); } return self; @@ -186,7 +187,12 @@ var NSTransformers = [CPSet setWithObjects: CPLog.debug(@"NSNibConnector: runtime attributes connector: " + [_source description]); while (count--) - CPLog.debug(@" %s (%s): %s", _keyPaths[count], [_values[count] className], _values[count]); + { + var value = _values[count], + type = typeof(value) === "boolean" ? "BOOL" : [value className]; + + CPLog.debug(@" %s (%s): %s", _keyPaths[count], type, value); + } } return self;