cocoaTouch/MainMenuViewController.m
changeset 3377 a3f0849f26bc
parent 3374 0d522416d97f
child 3463 23c50be687a9
--- a/cocoaTouch/MainMenuViewController.m	Thu Apr 29 17:21:10 2010 +0000
+++ b/cocoaTouch/MainMenuViewController.m	Thu Apr 29 18:53:22 2010 +0000
@@ -128,6 +128,7 @@
     UIButton *button = (UIButton *)sender;
     UIAlertView *alert;
     NSString *configNibName;
+    NSString *debugStr;
     
     switch (button.tag) {
         case 0:
@@ -155,6 +156,21 @@
             
             [self presentModalViewController:splitRootViewController animated:YES];
             break;
+        case 3:
+            debugStr = [[NSString alloc] initWithContentsOfFile:DEBUG_FILE()];
+            UITextView *scroll = [[UITextView alloc] initWithFrame:CGRectMake(0, 0, self.view.frame.size.height, self.view.frame.size.width)];
+            scroll.text = debugStr;
+            [debugStr release];
+            scroll.editable = NO;
+            
+            UIButton *btn = [UIButton buttonWithType:UIButtonTypeCustom];
+            [btn addTarget:scroll action:@selector(removeFromSuperview) forControlEvents:UIControlEventTouchUpInside];
+            btn.backgroundColor = [UIColor blackColor];
+            btn.frame = CGRectMake(self.view.frame.size.height-70, 0, 70, 70);
+            [scroll addSubview:btn];
+            [self.view addSubview:scroll];
+            [scroll release];
+            break;
         default:
             alert = [[UIAlertView alloc] initWithTitle:@"Not Yet Implemented"
                                                message:@"Sorry, this feature is not yet implemented"