cocoaTouch/iPad/HogHatViewController.m
author koda
Sat, 03 Apr 2010 03:24:12 +0000
changeset 3276 039145459ac8
parent 3270 9bd8fb1707b9
permissions -rw-r--r--
hats \o/
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
3270
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     1
//
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     2
//  HogHatViewController.m
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     3
//  HedgewarsMobile
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     4
//
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     5
//  Created by Vittorio on 02/04/10.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     6
//  Copyright 2010 __MyCompanyName__. All rights reserved.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     7
//
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     8
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
     9
#import "HogHatViewController.h"
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    10
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    11
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    12
@implementation HogHatViewController
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    13
@synthesize hatList, hog;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    14
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    15
#pragma mark -
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    16
#pragma mark View lifecycle
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    17
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    18
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    19
- (void)viewDidLoad {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    20
    [super viewDidLoad];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    21
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    22
    //NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    23
    NSString *hatPath = [[[NSBundle mainBundle] resourcePath] stringByAppendingString:@"/Data/Graphics/Hats/"];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    24
    NSArray *array = [[NSFileManager defaultManager] contentsOfDirectoryAtPath:hatPath
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    25
                                                                         error:NULL];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    26
    self.hatList = array;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    27
    //NSLog(@"%@", hatList);
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    28
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    29
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    30
- (void)viewWillAppear:(BOOL)animated {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    31
    [super viewWillAppear:animated];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    32
    self.title = [hog objectForKey:@"hogname"];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    33
    [self.tableView reloadData];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    34
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    35
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    36
/*
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    37
- (void)viewDidAppear:(BOOL)animated {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    38
    [super viewDidAppear:animated];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    39
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    40
*/
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    41
/*
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    42
- (void)viewWillDisappear:(BOOL)animated {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    43
    [super viewWillDisappear:animated];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    44
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    45
*/
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    46
/*
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    47
- (void)viewDidDisappear:(BOOL)animated {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    48
    [super viewDidDisappear:animated];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    49
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    50
*/
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    51
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    52
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    53
    // Override to allow orientations other than the default portrait orientation.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    54
    return YES;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    55
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    56
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    57
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    58
#pragma mark -
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    59
#pragma mark Table view data source
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    60
-(NSInteger) numberOfSectionsInTableView:(UITableView *)tableView {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    61
    return 2;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    62
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    63
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    64
-(NSInteger) tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    65
    NSInteger rows;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    66
    if (0 == section) 
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    67
        rows = 1;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    68
    else
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    69
        rows = [self.hatList count];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    70
    return rows;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    71
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    72
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    73
// Customize the appearance of table view cells.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    74
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    75
    
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    76
    static NSString *CellIdentifier = @"Cell";
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    77
    
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    78
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    79
    if (cell == nil) {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    80
        cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    81
    }
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    82
    
3276
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    83
    if (0 == [indexPath section]) {
3270
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    84
        cell.textLabel.text = [hog objectForKey:@"hogname"];
3276
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    85
        cell.imageView.image = nil;
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    86
        cell.accessoryType = UITableViewCellAccessoryNone;
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    87
    } else {
3270
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
    88
        cell.textLabel.text = [[hatList objectAtIndex:[indexPath row]] stringByDeletingPathExtension];
3276
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    89
        if ([cell.textLabel.text isEqualToString:[hog objectForKey:@"hat"]]) {
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    90
            cell.accessoryType = UITableViewCellAccessoryCheckmark;
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    91
        } else {
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    92
            cell.accessoryType = UITableViewCellAccessoryNone;
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    93
        }
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    94
        
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    95
        NSString *hatsPath = [[[NSBundle mainBundle] resourcePath] stringByAppendingString:@"/Data/Graphics/Hats/"];
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    96
        NSString *hatFile = [hatsPath stringByAppendingString:[hatList objectAtIndex:[indexPath row]]];
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    97
        UIImage *image = [UIImage imageWithContentsOfFile: hatFile];
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    98
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
    99
        CGRect firstSpriteArea = CGRectMake(0, 0, 32, 32);
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
   100
        CGImageRef cgImgage = CGImageCreateWithImageInRect([image CGImage], firstSpriteArea);
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
   101
        cell.imageView.image = [UIImage imageWithCGImage: cgImgage];
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
   102
        CGImageRelease(cgImgage);
039145459ac8 hats \o/
koda
parents: 3270
diff changeset
   103
    }
3270
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   104
    
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   105
    return cell;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   106
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   107
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   108
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   109
/*
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   110
// Override to support conditional editing of the table view.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   111
- (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   112
    // Return NO if you do not want the specified item to be editable.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   113
    return YES;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   114
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   115
*/
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   116
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   117
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   118
/*
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   119
// Override to support editing the table view.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   120
- (void)tableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   121
    
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   122
    if (editingStyle == UITableViewCellEditingStyleDelete) {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   123
        // Delete the row from the data source
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   124
        [tableView deleteRowsAtIndexPaths:[NSArray arrayWithObject:indexPath] withRowAnimation:YES];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   125
    }   
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   126
    else if (editingStyle == UITableViewCellEditingStyleInsert) {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   127
        // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   128
    }   
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   129
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   130
*/
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   131
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   132
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   133
/*
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   134
// Override to support rearranging the table view.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   135
- (void)tableView:(UITableView *)tableView moveRowAtIndexPath:(NSIndexPath *)fromIndexPath toIndexPath:(NSIndexPath *)toIndexPath {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   136
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   137
*/
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   138
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   139
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   140
/*
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   141
// Override to support conditional rearranging of the table view.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   142
- (BOOL)tableView:(UITableView *)tableView canMoveRowAtIndexPath:(NSIndexPath *)indexPath {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   143
    // Return NO if you do not want the item to be re-orderable.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   144
    return YES;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   145
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   146
*/
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   147
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   148
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   149
#pragma mark -
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   150
#pragma mark Table view delegate
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   151
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   152
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   153
    // Navigation logic may go here. Create and push another view controller.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   154
	/*
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   155
	 <#DetailViewController#> *detailViewController = [[<#DetailViewController#> alloc] initWithNibName:@"<#Nib name#>" bundle:nil];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   156
     // ...
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   157
     // Pass the selected object to the new view controller.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   158
	 [self.navigationController pushViewController:detailViewController animated:YES];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   159
	 [detailViewController release];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   160
	 */
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   161
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   162
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   163
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   164
#pragma mark -
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   165
#pragma mark Memory management
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   166
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   167
- (void)didReceiveMemoryWarning {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   168
    // Releases the view if it doesn't have a superview.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   169
    [super didReceiveMemoryWarning];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   170
    
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   171
    // Relinquish ownership any cached data, images, etc that aren't in use.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   172
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   173
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   174
- (void)viewDidUnload {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   175
    [super viewDidUnload];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   176
    self.hatList = nil;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   177
    self.hog = nil;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   178
    // Relinquish ownership of anything that can be recreated in viewDidLoad or on demand.
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   179
    // For example: self.myOutlet = nil;
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   180
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   181
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   182
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   183
- (void)dealloc {
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   184
    [hog release];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   185
    [hatList release];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   186
    [super dealloc];
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   187
}
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   188
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   189
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   190
@end
9bd8fb1707b9 initial support for hat selection on the ifrontend
koda
parents:
diff changeset
   191