Permalink
Browse files

Remove whitespace [Gun.io WhitespaceBot]

  • Loading branch information...
1 parent 27763e6 commit 38b99a1eecd2201f8969aa94064f77bca5ffba53 Gun.io Whitespace Robot committed Oct 30, 2011
View
@@ -44,7 +44,7 @@ PROJECT_BRIEF = "A tree graph view control for iPad applications."
# exceed 55 pixels and the maximum width should not exceed 200 pixels.
# Doxygen will copy the logo to the output directory.
-PROJECT_LOGO =
+PROJECT_LOGO =
# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
# base path where the generated documentation will be put.
@@ -20,16 +20,16 @@ @implementation PSHTreeGraphAppDelegate
#pragma mark - Application Lifecycle
-- (BOOL) application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
-{
- // Override point for customization after app launch.
+- (BOOL) application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+ // Override point for customization after app launch.
[window_ addSubview:viewController_.view];
[window_ makeKeyAndVisible];
return YES;
}
-- (void) applicationWillResignActive:(UIApplication *)application
+- (void) applicationWillResignActive:(UIApplication *)application
{
// Sent when the application is about to move from active to inactive state. This can occur for
// certain types of temporary interruptions (such as an incoming phone call or SMS message) or
@@ -39,13 +39,13 @@ - (void) applicationWillResignActive:(UIApplication *)application
// Games should use this method to pause the game.
}
-- (void) applicationDidBecomeActive:(UIApplication *)application
+- (void) applicationDidBecomeActive:(UIApplication *)application
{
// Restart any tasks that were paused (or not yet started) while the application was inactive.
// If the application was previously in the background, optionally refresh the user interface.
}
-- (void) applicationWillTerminate:(UIApplication *)application
+- (void) applicationWillTerminate:(UIApplication *)application
{
// Called when the application is about to terminate.
// See also applicationDidEnterBackground:.
@@ -54,13 +54,13 @@ - (void) applicationWillTerminate:(UIApplication *)application
#pragma mark - Resouce Management
-- (void) applicationDidReceiveMemoryWarning:(UIApplication *)application
+- (void) applicationDidReceiveMemoryWarning:(UIApplication *)application
{
- // Free up as much memory as possible by purging cached data objects that can be recreated
+ // Free up as much memory as possible by purging cached data objects that can be recreated
// (or reloaded from disk) later.
}
-- (void) dealloc
+- (void) dealloc
{
[viewController_ release];
[window_ release];
@@ -13,7 +13,7 @@
@class PSBaseTreeGraphView;
-@interface PSHTreeGraphViewController : UIViewController <PSTreeGraphDelegate>
+@interface PSHTreeGraphViewController : UIViewController <PSTreeGraphDelegate>
{
@private
@@ -23,14 +23,14 @@ @implementation PSHTreeGraphViewController
@synthesize treeGraphView = treeGraphView_;
@synthesize rootClassName = rootClassName_;
-- (void) setRootClassName:(NSString *)newRootClassName
-{
+- (void) setRootClassName:(NSString *)newRootClassName
+{
NSParameterAssert(newRootClassName != nil);
-
+
if (![rootClassName_ isEqualToString:newRootClassName]) {
[rootClassName_ release];
rootClassName_ = [newRootClassName copy];
-
+
// Get an ObjCClassWrapper for the named Objective-C Class, and set it as the TreeGraph's root.
[treeGraphView_ setModelRoot:[ObjCClassWrapper wrapperForClassNamed:rootClassName_]];
}
@@ -40,76 +40,76 @@ - (void) setRootClassName:(NSString *)newRootClassName
#pragma mark - View Creation and Initializer
// Implement viewDidLoad to do additional setup after loading the view, typically from a nib.
-- (void) viewDidLoad
+- (void) viewDidLoad
{
[super viewDidLoad];
-
+
// Set the delegate to self.
[self.treeGraphView setDelegate:self];
-
+
// Specify a .nib file for the TreeGraph to load each time it needs to create a new node view.
[self.treeGraphView setNodeViewNibName:@"ObjCClassTreeNodeView"];
-
+
// Specify a starting root class to inspect on launch.
[self setRootClassName:@"UIControl"];
-
+
}
// Override to allow orientations other than the default portrait orientation.
-- (BOOL) shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
+- (BOOL) shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
return YES;
}
-- (void) willAnimateRotationToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
- duration:(NSTimeInterval)duration
-{
+- (void) willAnimateRotationToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
+ duration:(NSTimeInterval)duration
+{
// Keep the view in sync
[self.treeGraphView parentClipViewDidResize:nil];
}
#pragma mark - TreeGraph Delegate
--(void) configureNodeView:(UIView *)nodeView
- withModelNode:(id <PSTreeGraphModelNode> )modelNode
-{
+-(void) configureNodeView:(UIView *)nodeView
+ withModelNode:(id <PSTreeGraphModelNode> )modelNode
+{
NSParameterAssert(nodeView != nil);
NSParameterAssert(modelNode != nil);
-
+
// NOT FLEXIBLE: treat it like a model node instead of the interface.
ObjCClassWrapper *objectWrapper = (ObjCClassWrapper *)modelNode;
PSHLeafView *leafView = (PSHLeafView *)nodeView;
-
+
// button
if ( [[objectWrapper childModelNodes] count] == 0 ) {
[leafView.expandButton setHidden:YES];
}
-
+
// labels
- leafView.titleLabel.text = [objectWrapper name];
+ leafView.titleLabel.text = [objectWrapper name];
leafView.detailLabel.text = [NSString stringWithFormat:@"%d bytes", [objectWrapper wrappedClassInstanceSize]];
-
+
}
#pragma mark - Resouce Management
-- (void) didReceiveMemoryWarning
+- (void) didReceiveMemoryWarning
{
// Releases the view if it doesn't have a superview.
[super didReceiveMemoryWarning];
-
+
// Release any cached data, images, etc that aren't in use.
}
-- (void) viewDidUnload
+- (void) viewDidUnload
{
// Release any retained subviews of the main view.
// e.g. self.myOutlet = nil;
}
-- (void) dealloc
+- (void) dealloc
{
[rootClassName_ release];
[super dealloc];
@@ -23,7 +23,7 @@
#pragma mark - Creating Instances
-// Returns an ObjCClassWrapper for the given Objective-C class. ObjCClassWrapper maintains
+// Returns an ObjCClassWrapper for the given Objective-C class. ObjCClassWrapper maintains
// a set of unique instances, so this will always return the same ObjCClassWrapper for a given Class.
+ (ObjCClassWrapper *) wrapperForClass:(Class)aClass;
@@ -44,7 +44,7 @@
@property (nonatomic, readonly) ObjCClassWrapper *superclassWrapper;
-// An array of ObjCClassWrappers representing the wrappedClass' subclasses.
+// An array of ObjCClassWrappers representing the wrappedClass' subclasses.
// (For convenience, the subclasses are sorted by name.)
@property (nonatomic, readonly) NSArray *subclasses;
@@ -10,15 +10,15 @@
#import <objc/runtime.h>
-// Keeps track of the ObjCClassWrapper instances we create. We create one unique
+// Keeps track of the ObjCClassWrapper instances we create. We create one unique
// ObjCClassWrapper for each Objective-C "Class" we're asked to wrap.
static NSMutableDictionary *classToWrapperMapTable = nil;
// Compares two ObjCClassWrappers by name, and returns an NSComparisonResult.
-
-static NSInteger CompareClassNames(id classA, id classB, void* context)
+
+static NSInteger CompareClassNames(id classA, id classB, void* context)
{
return [[classA description] compare:[classB description]];
}
@@ -30,15 +30,15 @@ @implementation ObjCClassWrapper
#pragma mark - NSCopying
-- (id) copyWithZone:(NSZone *)zone
+- (id) copyWithZone:(NSZone *)zone
{
return [self retain];
}
#pragma mark - Creating Instances
-- initWithWrappedClass:(Class)aClass
+- initWithWrappedClass:(Class)aClass
{
self = [super init];
if (self) {
@@ -56,7 +56,7 @@ - (id) copyWithZone:(NSZone *)zone
return self;
}
-+ (ObjCClassWrapper *) wrapperForClass:(Class)aClass
++ (ObjCClassWrapper *) wrapperForClass:(Class)aClass
{
ObjCClassWrapper *wrapper = [classToWrapperMapTable objectForKey:aClass];
if (wrapper == nil) {
@@ -65,35 +65,35 @@ + (ObjCClassWrapper *) wrapperForClass:(Class)aClass
return wrapper;
}
-+ (ObjCClassWrapper *) wrapperForClassNamed:(NSString *)aClassName
++ (ObjCClassWrapper *) wrapperForClassNamed:(NSString *)aClassName
{
return [self wrapperForClass:NSClassFromString(aClassName)];
}
#pragma mark - Property Accessors
-- (NSString *) name
+- (NSString *) name
{
return NSStringFromClass(wrappedClass);
}
-- (NSString *) description
+- (NSString *) description
{
return [self name];
}
-- (size_t) wrappedClassInstanceSize
+- (size_t) wrappedClassInstanceSize
{
return class_getInstanceSize(wrappedClass);
}
-- (ObjCClassWrapper *) superclassWrapper
+- (ObjCClassWrapper *) superclassWrapper
{
return [[self class] wrapperForClass:class_getSuperclass(wrappedClass)];
}
-- (NSArray *) subclasses
+- (NSArray *) subclasses
{
// If we haven't built our array of subclasses yet, do so.
if (subclassesCache == nil) {
@@ -127,12 +127,12 @@ - (NSArray *) subclasses
#pragma mark - TreeGraphModelNode Protocol
-- (id <PSTreeGraphModelNode> ) parentModelNode
+- (id <PSTreeGraphModelNode> ) parentModelNode
{
return [self superclassWrapper];
}
-- (NSArray *) childModelNodes
+- (NSArray *) childModelNodes
{
return [self subclasses];
}
@@ -11,11 +11,11 @@
#import "PSBaseLeafView.h"
-@interface PSHLeafView : PSBaseLeafView
+@interface PSHLeafView : PSBaseLeafView
{
-
+
@private
-
+
// Interface
UIButton *expandButton_;
UILabel *titleLabel_;
@@ -19,27 +19,27 @@ @implementation PSHLeafView
#pragma mark - NSCoding
-- (id) initWithCoder:(NSCoder *)decoder
+- (id) initWithCoder:(NSCoder *)decoder
{
self = [super initWithCoder:decoder];
if (self) {
-
+
// Initialization code, leaf views are always loaded from the corresponding XIB.
// Be sure to set the view class to your subclass in interface builder.
-
+
// Example: Inverse the color scheme
-
+
// self.fillColor = [UIColor yellowColor];
// self.selectionColor = [UIColor orangeColor];
-
+
}
return self;
}
#pragma mark - Resource Management
-- (void) dealloc
+- (void) dealloc
{
[super dealloc];
}
@@ -11,7 +11,7 @@
#import "PSBaseTreeGraphView.h"
-@interface PSHTreeGraphView : PSBaseTreeGraphView
+@interface PSHTreeGraphView : PSBaseTreeGraphView
{
// TODO: Place project specific code, extentions here.
}
Oops, something went wrong.

0 comments on commit 38b99a1

Please sign in to comment.