mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 04:40:37 +00:00
Refactor transform to a different class
This commit is contained in:
parent
a0afee8fb1
commit
59220e6beb
5 changed files with 886 additions and 696 deletions
118
Source/GSStoryboardTransform.h
Normal file
118
Source/GSStoryboardTransform.h
Normal file
|
@ -0,0 +1,118 @@
|
|||
/* Interface of class GSStoryboardTransform
|
||||
Copyright (C) 2020 Free Software Foundation, Inc.
|
||||
|
||||
By: Gregory John Casamento
|
||||
Date: Sat 04 Jul 2020 03:48:15 PM EDT
|
||||
|
||||
This file is part of the GNUstep Library.
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
This library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free
|
||||
Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
|
||||
Boston, MA 02110 USA.
|
||||
*/
|
||||
|
||||
#ifndef _GSStoryboardTransform_h_GNUSTEP_GUI_INCLUDE
|
||||
#define _GSStoryboardTransform_h_GNUSTEP_GUI_INCLUDE
|
||||
|
||||
#import <Foundation/NSObject.h>
|
||||
|
||||
@class NSString;
|
||||
@class NSMutableDictionary;
|
||||
@class NSDictionary;
|
||||
@class NSData;
|
||||
@class NSMapTable;
|
||||
@class NSXMLDocument;
|
||||
|
||||
#if defined(__cplusplus)
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
@interface GSStoryboardTransform : NSObject
|
||||
{
|
||||
NSMutableDictionary *_scenesMap;
|
||||
NSMutableDictionary *_controllerMap;
|
||||
NSMutableDictionary *_documentsMap;
|
||||
NSMutableDictionary *_identifierToSegueMap;
|
||||
NSString *_initialViewControllerId;
|
||||
NSString *_applicationSceneId;
|
||||
}
|
||||
|
||||
- (instancetype) initWithData: (NSData *)data;
|
||||
|
||||
- (NSDictionary *) scenesMap;
|
||||
- (NSDictionary *) controllerMap;
|
||||
- (NSString *) initialViewControllerId;
|
||||
- (NSString *) applicationSceneId;
|
||||
- (NSDictionary *) identifierToSegueMap;
|
||||
|
||||
- (NSData *) dataForIdentifier: (NSString *)identifier;
|
||||
- (NSData *) dataForSceneId: (NSString *)sceneId;
|
||||
- (NSData *) dataForApplicationScene;
|
||||
- (NSMapTable *) segueMapForIdentifier: (NSString *)identifier;
|
||||
|
||||
- (void) processSegues: (NSXMLDocument *)xmlIn
|
||||
forId: (NSString *)identifier;
|
||||
- (void) processStoryboard: (NSXMLDocument *)storyboardXml;
|
||||
|
||||
@end
|
||||
|
||||
// Private classes used when parsing the XIB generated by the transformer...
|
||||
@interface NSStoryboardSeguePerformAction : NSObject <NSCoding, NSCopying>
|
||||
{
|
||||
id _target;
|
||||
SEL _action;
|
||||
id _sender;
|
||||
NSString *_identifier;
|
||||
NSString *_kind;
|
||||
}
|
||||
|
||||
- (id) target;
|
||||
- (void) setTarget: (id)target;
|
||||
|
||||
- (NSString *) selector;
|
||||
- (void) setSelector: (NSString *)s;
|
||||
|
||||
- (SEL) action;
|
||||
- (void) setAction: (SEL)action;
|
||||
|
||||
- (id) sender;
|
||||
- (void) setSender: (id)sender;
|
||||
|
||||
- (NSString *) identifier;
|
||||
- (void) setIdentifier: (NSString *)identifier;
|
||||
|
||||
- (NSString *) kind;
|
||||
- (void) setKind: (NSString *)kind;
|
||||
|
||||
- (IBAction) doAction: (id)sender;
|
||||
@end
|
||||
|
||||
@interface NSControllerPlaceholder : NSObject <NSCoding, NSCopying> // , NSSeguePerforming>
|
||||
{
|
||||
NSString *_storyboardName;
|
||||
}
|
||||
|
||||
- (NSString *) storyboardName;
|
||||
- (void) setStoryboardName: (NSString *)name;
|
||||
|
||||
- (id) instantiate;
|
||||
|
||||
@end
|
||||
|
||||
#if defined(__cplusplus)
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _GSStoryboardTransform_h_GNUSTEP_GUI_INCLUDE */
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue