diff options
author | Paul Gardiner <paul.gardiner@artifex.com> | 2013-10-14 12:52:48 +0100 |
---|---|---|
committer | Paul Gardiner <paul.gardiner@artifex.com> | 2013-10-16 09:59:35 +0100 |
commit | a0029d70729f0cad0515b7e9fcb55a7527d199a1 (patch) | |
tree | 3ac8086b12c9652fc1652b937831c08fb33cea69 /platform/ios/Classes | |
parent | d246518b3f3f64ba10475e5043c554011a383a1c (diff) | |
download | mupdf-a0029d70729f0cad0515b7e9fcb55a7527d199a1.tar.xz |
iOS: support filling in of text form fields
Diffstat (limited to 'platform/ios/Classes')
-rw-r--r-- | platform/ios/Classes/MuDialogCreator.h | 12 | ||||
-rw-r--r-- | platform/ios/Classes/MuDocumentController.h | 3 | ||||
-rw-r--r-- | platform/ios/Classes/MuDocumentController.m | 13 | ||||
-rw-r--r-- | platform/ios/Classes/MuPageViewNormal.h | 5 | ||||
-rw-r--r-- | platform/ios/Classes/MuPageViewNormal.m | 147 | ||||
-rw-r--r-- | platform/ios/Classes/MuTapResult.h | 7 | ||||
-rw-r--r-- | platform/ios/Classes/MuTapResult.m | 19 | ||||
-rw-r--r-- | platform/ios/Classes/MuTextFieldController.h | 19 | ||||
-rw-r--r-- | platform/ios/Classes/MuTextFieldController.m | 58 | ||||
-rw-r--r-- | platform/ios/Classes/MuTextFieldController.xib | 612 |
10 files changed, 885 insertions, 10 deletions
diff --git a/platform/ios/Classes/MuDialogCreator.h b/platform/ios/Classes/MuDialogCreator.h new file mode 100644 index 00000000..9417facf --- /dev/null +++ b/platform/ios/Classes/MuDialogCreator.h @@ -0,0 +1,12 @@ +// +// MuDialogCreator.h +// MuPDF +// +// Copyright (c) 2013 Artifex Software, Inc. All rights reserved. +// + +#import <Foundation/Foundation.h> + +@protocol MuDialogCreator <NSObject> +- (void) invokeTextDialog:(NSString *)aString okayAction:(void (^)(NSString *))block; +@end diff --git a/platform/ios/Classes/MuDocumentController.h b/platform/ios/Classes/MuDocumentController.h index 3ec981f8..7cf943f8 100644 --- a/platform/ios/Classes/MuDocumentController.h +++ b/platform/ios/Classes/MuDocumentController.h @@ -15,8 +15,9 @@ #import "MuOutlineController.h" #import "MuDocRef.h" +#import "MuDialogCreator.h" -@interface MuDocumentController : UIViewController <UIScrollViewDelegate, UIGestureRecognizerDelegate, UISearchBarDelegate> +@interface MuDocumentController : UIViewController <UIScrollViewDelegate, UIGestureRecognizerDelegate, UISearchBarDelegate, MuDialogCreator> { fz_document *doc; MuDocRef *docRef; diff --git a/platform/ios/Classes/MuDocumentController.m b/platform/ios/Classes/MuDocumentController.m index 8a82fa1f..7b52f3e8 100644 --- a/platform/ios/Classes/MuDocumentController.m +++ b/platform/ios/Classes/MuDocumentController.m @@ -10,6 +10,7 @@ #import "MuPageViewNormal.h" #import "MuPageViewReflow.h" #import "MuDocumentController.h" +#import "MuTextFieldController.h" #define GAP 20 #define INDICATOR_Y -44-24 @@ -474,6 +475,8 @@ static void flattenOutline(NSMutableArray *titles, NSMutableArray *pages, fz_out // Not currently supported } caseRemote:^(MuTapResultRemoteLink *link) { // Not currently supported + } caseWidget:^(MuTapResultWidget *widget) { + tapHandled = YES; }]; if (tapHandled) break; @@ -570,7 +573,7 @@ static void flattenOutline(NSMutableArray *titles, NSMutableArray *pages, fz_out UIView<MuPageView> *view = reflowMode ? [[MuPageViewReflow alloc] initWithFrame:CGRectMake(number * width, 0, width-GAP, height) document:docRef page:number] - : [[MuPageViewNormal alloc] initWithFrame:CGRectMake(number * width, 0, width-GAP, height) document:docRef page:number]; + : [[MuPageViewNormal alloc] initWithFrame:CGRectMake(number * width, 0, width-GAP, height) dialogCreator:self document:docRef page:number]; [view setScale:scale]; [canvas addSubview: view]; if (showLinks) @@ -618,6 +621,14 @@ static void flattenOutline(NSMutableArray *titles, NSMutableArray *pages, fz_out current = number; } +- (void) invokeTextDialog:(NSString *)aString okayAction:(void (^)(NSString *))block +{ + MuTextFieldController *tf = [[MuTextFieldController alloc] initWithText:aString okayAction:block]; + tf.modalPresentationStyle = UIModalPresentationFormSheet; + [self presentViewController:tf animated:YES completion:nil]; + [tf release]; +} + - (void) onGotoPageFinished { scroll_animating = NO; diff --git a/platform/ios/Classes/MuPageViewNormal.h b/platform/ios/Classes/MuPageViewNormal.h index 542237ec..9bbe459c 100644 --- a/platform/ios/Classes/MuPageViewNormal.h +++ b/platform/ios/Classes/MuPageViewNormal.h @@ -16,6 +16,7 @@ #import "MuHitView.h" #import "MuPageView.h" #import "MuDocRef.h" +#import "MuDialogCreator.h" @interface MuPageViewNormal : UIScrollView <UIScrollViewDelegate,MuPageView> { @@ -30,12 +31,14 @@ UIImageView *tileView; MuHitView *hitView; MuHitView *linkView; + NSArray *widgetRects; CGSize pageSize; CGRect tileFrame; float tileScale; BOOL cancel; + id<MuDialogCreator> dialogCreator; } -- (id) initWithFrame: (CGRect)frame document: (MuDocRef *)aDoc page: (int)aNumber; +- (id) initWithFrame: (CGRect)frame dialogCreator:(id<MuDialogCreator>)dia document: (MuDocRef *)aDoc page: (int)aNumber; - (void) displayImage: (UIImage*)image; - (void) resizeImage; - (void) loadPage; diff --git a/platform/ios/Classes/MuPageViewNormal.m b/platform/ios/Classes/MuPageViewNormal.m index b34cb705..6f08424c 100644 --- a/platform/ios/Classes/MuPageViewNormal.m +++ b/platform/ios/Classes/MuPageViewNormal.m @@ -6,6 +6,8 @@ // #include "common.h" +#include "mupdf/pdf.h" +#import "MuTextFieldController.h" static void releasePixmap(void *info, const void *data, size_t size) { @@ -37,6 +39,55 @@ static UIImage *newImageWithPixmap(fz_pixmap *pix) return image; } +static NSArray *enumerateWidgetRects(fz_document *doc, fz_page *page, CGSize pageSize, CGSize screenSize) +{ + pdf_document *idoc = pdf_specifics(doc); + pdf_widget *widget; + NSMutableArray *arr = [NSMutableArray arrayWithCapacity:10]; + CGSize scale = fitPageToScreen(pageSize, screenSize); + + if (!idoc) + return nil; + + for (widget = pdf_first_widget(idoc, (pdf_page *)page); widget; widget = pdf_next_widget(widget)) + { + fz_rect rect; + + pdf_bound_widget(widget, &rect); + [arr addObject:[NSValue valueWithCGRect:CGRectMake( + rect.x0 * scale.width, + rect.y0 * scale.height, + (rect.x1-rect.x0) * scale.width, + (rect.y1-rect.y0) * scale.height)]]; + } + + return [arr retain]; +} + +static int setFocussedWidgetText(fz_document *doc, fz_page *page, const char *text) +{ + int accepted; + + fz_try(ctx) + { + pdf_document *idoc = pdf_specifics(doc); + if (idoc) + { + pdf_widget *focus = pdf_focused_widget(idoc); + if (focus) + { + accepted = pdf_text_widget_set_text(idoc, focus, (char *)text); + } + } + } + fz_catch(ctx) + { + accepted = 0; + } + + return accepted; +} + static fz_display_list *create_page_list(fz_document *doc, fz_page *page) { fz_display_list *list; @@ -70,7 +121,10 @@ static fz_display_list *create_annot_list(fz_document *doc, fz_page *page) fz_try(ctx) { fz_annot *annot; + pdf_document *idoc = pdf_specifics(doc); + if (idoc) + pdf_update_page(idoc, (pdf_page *)page); list = fz_new_display_list(ctx); dev = fz_new_list_device(ctx, list); for (annot = fz_first_annot(doc, page); annot; annot = fz_next_annot(doc, annot)) @@ -173,7 +227,7 @@ static UIImage *renderPage(fz_document *doc, fz_display_list *page_list, fz_disp annot_list = create_annot_list(doc, page); } -- (id) initWithFrame: (CGRect)frame document: (MuDocRef *)aDoc page: (int)aNumber +-(id) initWithFrame:(CGRect)frame dialogCreator:(id<MuDialogCreator>)dia document:(MuDocRef *)aDoc page:(int)aNumber { self = [super initWithFrame: frame]; if (self) { @@ -181,6 +235,7 @@ static UIImage *renderPage(fz_document *doc, fz_display_list *page_list, fz_disp doc = docRef->doc; number = aNumber; cancel = NO; + dialogCreator = dia; [self setShowsVerticalScrollIndicator: NO]; [self setShowsHorizontalScrollIndicator: NO]; @@ -226,6 +281,7 @@ static UIImage *renderPage(fz_document *doc, fz_display_list *page_list, fz_disp block_page = nil; }); [docRef release]; + [widgetRects release]; [linkView release]; [hitView release]; [tileView release]; @@ -325,6 +381,7 @@ static UIImage *renderPage(fz_document *doc, fz_display_list *page_list, fz_disp CGSize scale = fitPageToScreen(pageSize, self.bounds.size); CGRect rect = (CGRect){{0.0, 0.0},{pageSize.width * scale.width, pageSize.height * scale.height}}; UIImage *image = renderPage(doc, page_list, annot_list, pageSize, self.bounds.size, rect, 1.0); + widgetRects = enumerateWidgetRects(doc, page, pageSize, self.bounds.size); dispatch_async(dispatch_get_main_queue(), ^{ [self displayImage: image]; [image release]; @@ -533,8 +590,96 @@ static UIImage *renderPage(fz_document *doc, fz_display_list *page_list, fz_disp - (void) setScale:(float)scale {} +- (void) invokeTextDialog:(NSString *)text +{ + [dialogCreator invokeTextDialog:text okayAction:^(NSString *newText) { + dispatch_async(queue, ^{ + BOOL accepted = setFocussedWidgetText(doc, page, [newText UTF8String]); + fz_drop_display_list(ctx, annot_list); + annot_list = NULL; + dispatch_async(dispatch_get_main_queue(), ^{ + if (accepted) + [self loadPage]; + else + [self invokeTextDialog:newText]; + }); + }); + }]; +} + +- (void) passTapToPage:(CGPoint)pt +{ + pdf_document *idoc = pdf_specifics(doc); + CGSize scale = fitPageToScreen(pageSize, self.bounds.size); + pdf_ui_event event; + int changed = 0; + pdf_widget *focus; + + if (!idoc) + return; + + fz_try(ctx) + { + event.etype = PDF_EVENT_TYPE_POINTER; + event.event.pointer.pt.x = pt.x / scale.width; + event.event.pointer.pt.y = pt.y / scale.height; + event.event.pointer.ptype = PDF_POINTER_DOWN; + changed = pdf_pass_event(idoc, (pdf_page *)page, &event); + event.event.pointer.ptype = PDF_POINTER_UP; + changed |= pdf_pass_event(idoc, (pdf_page *)page, &event); + if (changed) + { + fz_drop_display_list(ctx, annot_list); + annot_list = NULL; + } + + focus = pdf_focused_widget(idoc); + if (focus) + { + switch (pdf_widget_get_type(focus)) + { + case PDF_WIDGET_TYPE_TEXT: + { + char *text = pdf_text_widget_text(idoc, focus); + NSString *stext = [NSString stringWithUTF8String:text?text:""]; + fz_free(ctx, text); + dispatch_async(dispatch_get_main_queue(), ^{ + [self invokeTextDialog:stext]; + }); + break; + } + + case PDF_WIDGET_TYPE_LISTBOX: + case PDF_WIDGET_TYPE_COMBOBOX: + break; + + case PDF_WIDGET_TYPE_SIGNATURE: + break; + + default: + break; + } + } + } + fz_catch(ctx) + { + } +} + - (MuTapResult *) handleTap:(CGPoint)pt { + CGPoint ipt = [self convertPoint:pt toView:imageView]; + for (int i = 0; i < widgetRects.count; i++) + { + CGRect r = [[widgetRects objectAtIndex:i] CGRectValue]; + if (CGRectContainsPoint([[widgetRects objectAtIndex:i] CGRectValue], ipt)) + { + dispatch_async(queue, ^{ + [self passTapToPage:ipt]; + }); + return [[[MuTapResultWidget alloc] init] autorelease]; + } + } CGPoint lpt = [self convertPoint:pt toView:linkView]; return linkView ? [linkView handleTap:lpt] : nil; } diff --git a/platform/ios/Classes/MuTapResult.h b/platform/ios/Classes/MuTapResult.h index c0d930c5..3271772f 100644 --- a/platform/ios/Classes/MuTapResult.h +++ b/platform/ios/Classes/MuTapResult.h @@ -10,11 +10,13 @@ @class MuTapResultInternalLink; @class MuTapResultExternalLink; @class MuTapResultRemoteLink; +@class MuTapResultWidget; @interface MuTapResult : NSObject -(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock - caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock; + caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock + caseWidget:(void (^)(MuTapResultWidget *))widgetBlock; @end @interface MuTapResultInternalLink : MuTapResult @@ -44,3 +46,6 @@ @property(readonly) BOOL newWindow; -(id)initWithFileSpec:(NSString *)aString pageNumber:(int)aNumber newWindow:(BOOL)aBool; @end + +@interface MuTapResultWidget : MuTapResult +@end diff --git a/platform/ios/Classes/MuTapResult.m b/platform/ios/Classes/MuTapResult.m index 7e3d71d1..c7f4d755 100644 --- a/platform/ios/Classes/MuTapResult.m +++ b/platform/ios/Classes/MuTapResult.m @@ -9,8 +9,7 @@ @implementation MuTapResult --(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock {} - +-(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock caseWidget:(void (^)(MuTapResultWidget *))widgetBlock {} @end @@ -28,7 +27,7 @@ return self; } --(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock +-(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock caseWidget:(void (^)(MuTapResultWidget *))widgetBlock { internalLinkBlock(self); } @@ -56,7 +55,7 @@ [super dealloc]; } --(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock +-(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock caseWidget:(void (^)(MuTapResultWidget *))widgetBlock { externalLinkBlock(self); } @@ -86,9 +85,19 @@ [super dealloc]; } --(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock +-(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock caseWidget:(void (^)(MuTapResultWidget *))widgetBlock { remoteLinkBlock(self); } +@end + + +@implementation MuTapResultWidget + +-(void) switchCaseInternal:(void (^)(MuTapResultInternalLink *))internalLinkBlock caseExternal:(void (^)(MuTapResultExternalLink *))externalLinkBlock caseRemote:(void (^)(MuTapResultRemoteLink *))remoteLinkBlock caseWidget:(void (^)(MuTapResultWidget *))widgetBlock +{ + widgetBlock(self); +} + @end
\ No newline at end of file diff --git a/platform/ios/Classes/MuTextFieldController.h b/platform/ios/Classes/MuTextFieldController.h new file mode 100644 index 00000000..f74f0610 --- /dev/null +++ b/platform/ios/Classes/MuTextFieldController.h @@ -0,0 +1,19 @@ +// +// MuTextFieldController.h +// MuPDF +// +// Copyright (c) 2013 Artifex Software, Inc. All rights reserved. +// + +#import <UIKit/UIKit.h> + +@interface MuTextFieldController : UIViewController +{ + void (^okayBlock)(NSString *); + NSString *initialText; +} +@property (retain, nonatomic) IBOutlet UITextView *textView; +- (id)initWithText:(NSString *)text okayAction:(void (^)(NSString *))block; +- (IBAction)okayTapped:(id)sender; +- (IBAction)cancelTapped:(id)sender; +@end diff --git a/platform/ios/Classes/MuTextFieldController.m b/platform/ios/Classes/MuTextFieldController.m new file mode 100644 index 00000000..e0864ff4 --- /dev/null +++ b/platform/ios/Classes/MuTextFieldController.m @@ -0,0 +1,58 @@ +// +// MuTextFieldController.m +// MuPDF +// +// Copyright (c) 2013 Artifex Software, Inc. All rights reserved. +// + +#import "MuTextFieldController.h" + +@interface MuTextFieldController () +@end + +@implementation MuTextFieldController + +-(id)initWithText:(NSString *)text okayAction:(void (^)(NSString *))block +{ + self = [super initWithNibName:@"MuTextFieldController" bundle:nil]; + if (self) + { + okayBlock = Block_copy(block); + initialText = [text retain]; + } + return self; +} + +- (void)viewDidLoad +{ + [super viewDidLoad]; + _textView.text = initialText; + // Do any additional setup after loading the view from its nib. +} + +- (void)didReceiveMemoryWarning +{ + [super didReceiveMemoryWarning]; + // Dispose of any resources that can be recreated. +} + +- (void)dealloc +{ + [okayBlock release]; + [initialText release]; + [_textView release]; + [super dealloc]; +} + +- (IBAction)okayTapped:(id)sender +{ + okayBlock(_textView.text); + [self dismissViewControllerAnimated:YES completion:nil]; +} + +- (IBAction)cancelTapped:(id)sender +{ + [self dismissViewControllerAnimated:YES completion:nil]; +} + +@end diff --git a/platform/ios/Classes/MuTextFieldController.xib b/platform/ios/Classes/MuTextFieldController.xib new file mode 100644 index 00000000..298e1508 --- /dev/null +++ b/platform/ios/Classes/MuTextFieldController.xib @@ -0,0 +1,612 @@ +<?xml version="1.0" encoding="UTF-8"?> +<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="8.00"> + <data> + <int key="IBDocument.SystemTarget">1552</int> + <string key="IBDocument.SystemVersion">11G63b</string> + <string key="IBDocument.InterfaceBuilderVersion">3084</string> + <string key="IBDocument.AppKitVersion">1138.51</string> + <string key="IBDocument.HIToolboxVersion">569.00</string> + <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> + <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="NS.object.0">2083</string> + </object> + <array key="IBDocument.IntegratedClassDependencies"> + <string>IBNSLayoutConstraint</string> + <string>IBProxyObject</string> + <string>IBUIButton</string> + <string>IBUILabel</string> + <string>IBUITextView</string> + <string>IBUIView</string> + </array> + <array key="IBDocument.PluginDependencies"> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </array> + <object class="NSMutableDictionary" key="IBDocument.Metadata"> + <string key="NS.key.0">PluginDependencyRecalculationVersion</string> + <integer value="1" key="NS.object.0"/> + </object> + <array class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> + <object class="IBProxyObject" id="372490531"> + <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> + <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> + </object> + <object class="IBProxyObject" id="975951072"> + <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> + <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> + </object> + <object class="IBUIView" id="191373211"> + <reference key="NSNextResponder"/> + <int key="NSvFlags">274</int> + <array class="NSMutableArray" key="NSSubviews"> + <object class="IBUILabel" id="852968923"> + <reference key="NSNextResponder" ref="191373211"/> + <int key="NSvFlags">292</int> + <string key="NSFrame">{{20, 47}, {281, 21}}</string> + <reference key="NSSuperview" ref="191373211"/> + <reference key="NSNextKeyView" ref="458048931"/> + <string key="NSReuseIdentifierKey">_NS:9</string> + <bool key="IBUIOpaque">NO</bool> + <bool key="IBUIClipsSubviews">YES</bool> + <int key="IBUIContentMode">7</int> + <bool key="IBUIUserInteractionEnabled">NO</bool> + <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> + <string key="IBUIText">Fill in text field</string> + <object class="NSColor" key="IBUITextColor" id="96159386"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MQA</bytes> + </object> + <nil key="IBUIHighlightedColor"/> + <int key="IBUIBaselineAdjustment">0</int> + <int key="IBUITextAlignment">1</int> + <object class="IBUIFontDescription" key="IBUIFontDescription"> + <int key="type">1</int> + <double key="pointSize">17</double> + </object> + <object class="NSFont" key="IBUIFont"> + <string key="NSName">Helvetica</string> + <double key="NSSize">17</double> + <int key="NSfFlags">16</int> + </object> + <bool key="IBUIAdjustsFontSizeToFit">NO</bool> + </object> + <object class="IBUITextView" id="458048931"> + <reference key="NSNextResponder" ref="191373211"/> + <int key="NSvFlags">292</int> + <string key="NSFrame">{{20, 89}, {281, 281}}</string> + <reference key="NSSuperview" ref="191373211"/> + <reference key="NSNextKeyView" ref="831564724"/> + <string key="NSReuseIdentifierKey">_NS:9</string> + <object class="NSColor" key="IBUIBackgroundColor"> + <int key="NSColorSpace">1</int> + <bytes key="NSRGB">MSAxIDEAA</bytes> + </object> + <bool key="IBUIClipsSubviews">YES</bool> + <bool key="IBUIMultipleTouchEnabled">YES</bool> + <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> + <string key="IBUIText"/> + <object class="IBUITextInputTraits" key="IBUITextInputTraits"> + <int key="IBUIAutocapitalizationType">2</int> + <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> + </object> + <object class="IBUIFontDescription" key="IBUIFontDescription"> + <string key="name">Helvetica</string> + <string key="family">Helvetica</string> + <int key="traits">0</int> + <double key="pointSize">14</double> + </object> + <object class="NSFont" key="IBUIFont"> + <string key="NSName">Helvetica</string> + <double key="NSSize">14</double> + <int key="NSfFlags">16</int> + </object> + </object> + <object class="IBUIButton" id="831564724"> + <reference key="NSNextResponder" ref="191373211"/> + <int key="NSvFlags">292</int> + <string key="NSFrame">{{20, 416}, {280, 44}}</string> + <reference key="NSSuperview" ref="191373211"/> + <reference key="NSNextKeyView" ref="65437148"/> + <string key="NSReuseIdentifierKey">_NS:9</string> + <bool key="IBUIOpaque">NO</bool> + <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> + <int key="IBUIContentHorizontalAlignment">0</int> + <int key="IBUIContentVerticalAlignment">0</int> + <int key="IBUIButtonType">1</int> + <string key="IBUINormalTitle">Okay</string> + <reference key="IBUIHighlightedTitleColor" ref="96159386"/> + <object class="NSColor" key="IBUINormalTitleColor"> + <int key="NSColorSpace">1</int> + <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes> + </object> + <object class="NSColor" key="IBUINormalTitleShadowColor" id="607563219"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MC41AA</bytes> + </object> + <object class="IBUIFontDescription" key="IBUIFontDescription" id="616815177"> + <int key="type">2</int> + <double key="pointSize">15</double> + </object> + <object class="NSFont" key="IBUIFont" id="536603733"> + <string key="NSName">Helvetica-Bold</string> + <double key="NSSize">15</double> + <int key="NSfFlags">16</int> + </object> + </object> + <object class="IBUIButton" id="65437148"> + <reference key="NSNextResponder" ref="191373211"/> + <int key="NSvFlags">292</int> + <string key="NSFrame">{{20, 476}, {281, 44}}</string> + <reference key="NSSuperview" ref="191373211"/> + <reference key="NSNextKeyView"/> + <string key="NSReuseIdentifierKey">_NS:9</string> + <bool key="IBUIOpaque">NO</bool> + <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> + <int key="IBUIContentHorizontalAlignment">0</int> + <int key="IBUIContentVerticalAlignment">0</int> + <int key="IBUIButtonType">1</int> + <string key="IBUINormalTitle">Cancel</string> + <reference key="IBUIHighlightedTitleColor" ref="96159386"/> + <object class="NSColor" key="IBUINormalTitleColor"> + <int key="NSColorSpace">1</int> + <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes> + </object> + <reference key="IBUINormalTitleShadowColor" ref="607563219"/> + <reference key="IBUIFontDescription" ref="616815177"/> + <reference key="IBUIFont" ref="536603733"/> + </object> + </array> + <string key="NSFrame">{{0, 20}, {320, 548}}</string> + <reference key="NSSuperview"/> + <reference key="NSNextKeyView" ref="852968923"/> + <object class="NSColor" key="IBUIBackgroundColor"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MC4zMzMzMzMzMzMzAA</bytes> + </object> + <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/> + <object class="IBUIScreenMetrics" key="IBUISimulatedDestinationMetrics"> + <string key="IBUISimulatedSizeMetricsClass">IBUIScreenMetrics</string> + <object class="NSMutableDictionary" key="IBUINormalizedOrientationToSizeMap"> + <bool key="EncodedWithXMLCoder">YES</bool> + <array key="dict.sortedKeys"> + <integer value="1"/> + <integer value="3"/> + </array> + <array key="dict.values"> + <string>{320, 568}</string> + <string>{568, 320}</string> + </array> + </object> + <string key="IBUITargetRuntime">IBCocoaTouchFramework</string> + <string key="IBUIDisplayName">Retina 4 Full Screen</string> + <int key="IBUIType">2</int> + </object> + <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string> + </object> + </array> + <object class="IBObjectContainer" key="IBDocument.Objects"> + <array class="NSMutableArray" key="connectionRecords"> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">view</string> + <reference key="source" ref="372490531"/> + <reference key="destination" ref="191373211"/> + </object> + <int key="connectionID">3</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">textView</string> + <reference key="source" ref="372490531"/> + <reference key="destination" ref="458048931"/> + </object> + <int key="connectionID">70</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchEventConnection" key="connection"> + <string key="label">okayTapped:</string> + <reference key="source" ref="831564724"/> + <reference key="destination" ref="372490531"/> + <int key="IBEventType">7</int> + </object> + <int key="connectionID">71</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchEventConnection" key="connection"> + <string key="label">cancelTapped:</string> + <reference key="source" ref="65437148"/> + <reference key="destination" ref="372490531"/> + <int key="IBEventType">7</int> + </object> + <int key="connectionID">72</int> + </object> + </array> + <object class="IBMutableOrderedSet" key="objectRecords"> + <array key="orderedObjects"> + <object class="IBObjectRecord"> + <int key="objectID">0</int> + <array key="object" id="0"/> + <reference key="children" ref="1000"/> + <nil key="parent"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">1</int> + <reference key="object" ref="191373211"/> + <array class="NSMutableArray" key="children"> + <object class="IBNSLayoutConstraint" id="39033334"> + <reference key="firstItem" ref="65437148"/> + <int key="firstAttribute">5</int> + <int key="relation">0</int> + <reference key="secondItem" ref="191373211"/> + <int key="secondAttribute">5</int> + <float key="multiplier">1</float> + <object class="IBNSLayoutSymbolicConstant" key="constant"> + <double key="value">20</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">8</int> + <float key="scoringTypeFloat">29</float> + <int key="contentType">3</int> + </object> + <object class="IBNSLayoutConstraint" id="1029677805"> + <reference key="firstItem" ref="191373211"/> + <int key="firstAttribute">4</int> + <int key="relation">0</int> + <reference key="secondItem" ref="65437148"/> + <int key="secondAttribute">4</int> + <float key="multiplier">1</float> + <object class="IBLayoutConstant" key="constant"> + <double key="value">29</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">3</int> + <float key="scoringTypeFloat">9</float> + <int key="contentType">3</int> + </object> + <object class="IBNSLayoutConstraint" id="942754903"> + <reference key="firstItem" ref="191373211"/> + <int key="firstAttribute">4</int> + <int key="relation">0</int> + <reference key="secondItem" ref="831564724"/> + <int key="secondAttribute">4</int> + <float key="multiplier">1</float> + <object class="IBLayoutConstant" key="constant"> + <double key="value">89</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">3</int> + <float key="scoringTypeFloat">9</float> + <int key="contentType">3</int> + </object> + <object class="IBNSLayoutConstraint" id="745573488"> + <reference key="firstItem" ref="831564724"/> + <int key="firstAttribute">9</int> + <int key="relation">0</int> + <reference key="secondItem" ref="65437148"/> + <int key="secondAttribute">9</int> + <float key="multiplier">1</float> + <object class="IBLayoutConstant" key="constant"> + <double key="value">0.0</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">6</int> + <float key="scoringTypeFloat">24</float> + <int key="contentType">2</int> + </object> + <object class="IBNSLayoutConstraint" id="374543723"> + <reference key="firstItem" ref="191373211"/> + <int key="firstAttribute">6</int> + <int key="relation">0</int> + <reference key="secondItem" ref="831564724"/> + <int key="secondAttribute">6</int> + <float key="multiplier">1</float> + <object class="IBNSLayoutSymbolicConstant" key="constant"> + <double key="value">20</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">8</int> + <float key="scoringTypeFloat">29</float> + <int key="contentType">3</int> + </object> + <object class="IBNSLayoutConstraint" id="357946085"> + <reference key="firstItem" ref="831564724"/> + <int key="firstAttribute">5</int> + <int key="relation">0</int> + <reference key="secondItem" ref="191373211"/> + <int key="secondAttribute">5</int> + <float key="multiplier">1</float> + <object class="IBNSLayoutSymbolicConstant" key="constant"> + <double key="value">20</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">8</int> + <float key="scoringTypeFloat">29</float> + <int key="contentType">3</int> + </object> + <object class="IBNSLayoutConstraint" id="109301233"> + <reference key="firstItem" ref="458048931"/> + <int key="firstAttribute">3</int> + <int key="relation">0</int> + <reference key="secondItem" ref="191373211"/> + <int key="secondAttribute">3</int> + <float key="multiplier">1</float> + <object class="IBLayoutConstant" key="constant"> + <double key="value">89</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">3</int> + <float key="scoringTypeFloat">9</float> + <int key="contentType">3</int> + </object> + <object class="IBNSLayoutConstraint" id="856939218"> + <reference key="firstItem" ref="458048931"/> + <int key="firstAttribute">6</int> + <int key="relation">0</int> + <reference key="secondItem" ref="65437148"/> + <int key="secondAttribute">6</int> + <float key="multiplier">1</float> + <object class="IBLayoutConstant" key="constant"> + <double key="value">0.0</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">6</int> + <float key="scoringTypeFloat">24</float> + <int key="contentType">2</int> + </object> + <object class="IBNSLayoutConstraint" id="40991801"> + <reference key="firstItem" ref="458048931"/> + <int key="firstAttribute">6</int> + <int key="relation">0</int> + <reference key="secondItem" ref="852968923"/> + <int key="secondAttribute">6</int> + <float key="multiplier">1</float> + <object class="IBLayoutConstant" key="constant"> + <double key="value">0.0</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">6</int> + <float key="scoringTypeFloat">24</float> + <int key="contentType">2</int> + </object> + <object class="IBNSLayoutConstraint" id="855118322"> + <reference key="firstItem" ref="458048931"/> + <int key="firstAttribute">5</int> + <int key="relation">0</int> + <reference key="secondItem" ref="191373211"/> + <int key="secondAttribute">5</int> + <float key="multiplier">1</float> + <object class="IBNSLayoutSymbolicConstant" key="constant"> + <double key="value">20</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">8</int> + <float key="scoringTypeFloat">29</float> + <int key="contentType">3</int> + </object> + <object class="IBNSLayoutConstraint" id="37372808"> + <reference key="firstItem" ref="852968923"/> + <int key="firstAttribute">3</int> + <int key="relation">0</int> + <reference key="secondItem" ref="191373211"/> + <int key="secondAttribute">3</int> + <float key="multiplier">1</float> + <object class="IBLayoutConstant" key="constant"> + <double key="value">47</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">3</int> + <float key="scoringTypeFloat">9</float> + <int key="contentType">3</int> + </object> + <object class="IBNSLayoutConstraint" id="576864315"> + <reference key="firstItem" ref="852968923"/> + <int key="firstAttribute">5</int> + <int key="relation">0</int> + <reference key="secondItem" ref="191373211"/> + <int key="secondAttribute">5</int> + <float key="multiplier">1</float> + <object class="IBNSLayoutSymbolicConstant" key="constant"> + <double key="value">20</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="191373211"/> + <int key="scoringType">8</int> + <float key="scoringTypeFloat">29</float> + <int key="contentType">3</int> + </object> + <reference ref="852968923"/> + <reference ref="831564724"/> + <reference ref="65437148"/> + <reference ref="458048931"/> + </array> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">-1</int> + <reference key="object" ref="372490531"/> + <reference key="parent" ref="0"/> + <string key="objectName">File's Owner</string> + </object> + <object class="IBObjectRecord"> + <int key="objectID">-2</int> + <reference key="object" ref="975951072"/> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">4</int> + <reference key="object" ref="852968923"/> + <array class="NSMutableArray" key="children"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">11</int> + <reference key="object" ref="576864315"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">12</int> + <reference key="object" ref="458048931"/> + <array class="NSMutableArray" key="children"> + <object class="IBNSLayoutConstraint" id="921803831"> + <reference key="firstItem" ref="458048931"/> + <int key="firstAttribute">8</int> + <int key="relation">0</int> + <nil key="secondItem"/> + <int key="secondAttribute">0</int> + <float key="multiplier">1</float> + <object class="IBLayoutConstant" key="constant"> + <double key="value">281</double> + </object> + <float key="priority">1000</float> + <reference key="containingView" ref="458048931"/> + <int key="scoringType">3</int> + <float key="scoringTypeFloat">9</float> + <int key="contentType">1</int> + </object> + </array> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">21</int> + <reference key="object" ref="855118322"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">22</int> + <reference key="object" ref="831564724"/> + <array class="NSMutableArray" key="children"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">41</int> + <reference key="object" ref="37372808"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">43</int> + <reference key="object" ref="921803831"/> + <reference key="parent" ref="458048931"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">48</int> + <reference key="object" ref="357946085"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">49</int> + <reference key="object" ref="374543723"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">54</int> + <reference key="object" ref="40991801"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">59</int> + <reference key="object" ref="65437148"/> + <array class="NSMutableArray" key="children"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">60</int> + <reference key="object" ref="1029677805"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">62</int> + <reference key="object" ref="39033334"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">64</int> + <reference key="object" ref="745573488"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">65</int> + <reference key="object" ref="856939218"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">68</int> + <reference key="object" ref="942754903"/> + <reference key="parent" ref="191373211"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">69</int> + <reference key="object" ref="109301233"/> + <reference key="parent" ref="191373211"/> + </object> + </array> + </object> + <dictionary class="NSMutableDictionary" key="flattenedProperties"> + <string key="-1.CustomClassName">MuTextFieldController</string> + <string key="-1.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="-2.CustomClassName">UIResponder</string> + <string key="-2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="1.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <array class="NSMutableArray" key="1.IBViewMetadataConstraints"> + <reference ref="576864315"/> + <reference ref="37372808"/> + <reference ref="855118322"/> + <reference ref="40991801"/> + <reference ref="856939218"/> + <reference ref="109301233"/> + <reference ref="357946085"/> + <reference ref="374543723"/> + <reference ref="745573488"/> + <reference ref="942754903"/> + <reference ref="1029677805"/> + <reference ref="39033334"/> + </array> + <string key="11.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="12.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <array class="NSMutableArray" key="12.IBViewMetadataConstraints"> + <reference ref="921803831"/> + </array> + <boolean value="NO" key="12.IBViewMetadataTranslatesAutoresizingMaskIntoConstraints"/> + <string key="21.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="22.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <boolean value="NO" key="22.IBViewMetadataTranslatesAutoresizingMaskIntoConstraints"/> + <string key="4.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <boolean value="NO" key="4.IBViewMetadataTranslatesAutoresizingMaskIntoConstraints"/> + <string key="41.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="43.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="48.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="49.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="54.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="59.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <boolean value="NO" key="59.IBViewMetadataTranslatesAutoresizingMaskIntoConstraints"/> + <string key="60.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="62.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="64.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="65.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="68.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="69.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </dictionary> + <dictionary class="NSMutableDictionary" key="unlocalizedProperties"/> + <nil key="activeLocalization"/> + <dictionary class="NSMutableDictionary" key="localizations"/> + <nil key="sourceID"/> + <int key="maxID">72</int> + </object> + <object class="IBClassDescriber" key="IBDocument.Classes"/> + <int key="IBDocument.localizationMode">0</int> + <string key="IBDocument.TargetRuntimeIdentifier">IBCocoaTouchFramework</string> + <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> + <int key="IBDocument.defaultPropertyAccessControl">3</int> + <bool key="IBDocument.UseAutolayout">YES</bool> + <string key="IBCocoaTouchPluginVersion">2083</string> + </data> +</archive> |