Permalink
Browse files

Added a flip transition which has a thickness to it...

  • Loading branch information...
1 parent dee3f79 commit bc2aa36b6ec87333c6d8963cf32f224ea60d1752 @epatel committed Jun 28, 2010
@@ -11,6 +11,7 @@
#import "DemoTransition.h"
#import "Demo2Transition.h"
+#import "Demo3Transition.h"
@implementation MainViewController
@@ -55,30 +56,31 @@ - (IBAction)showInfo:(id)sender
NSObject<EPGLTransitionViewDelegate> *transition;
- if ([sender tag])
- transition = [[[Demo2Transition alloc] init] autorelease];
- else
- transition = [[[DemoTransition alloc] init] autorelease];
+ switch ([sender tag]) {
+ case 0:
+ transition = [[[DemoTransition alloc] init] autorelease];
+ break;
+ case 1:
+ transition = [[[Demo2Transition alloc] init] autorelease];
+ break;
+ case 2:
+ transition = [[[Demo3Transition alloc] init] autorelease];
+ break;
+ }
EPGLTransitionView *glview = [[[EPGLTransitionView alloc]
initWithView:self.view
delegate:transition] autorelease];
- if ([sender tag])
+ if ([sender tag]) {
[glview prepareTextureTo:controller.view];
-
-#ifdef ENABLE_PHASE_IN
- else
- // Get texture for the "next" view
- [glview prepareTextureTo:controller.view];
-
- // If you are using an "IN" animation for the "next" view set appropriate
- // clear color (ie no alpha)
- [glview setClearColorRed:0.3
- green:0.3
- blue:0.3
- alpha:1.0];
-#endif
+ // If you are using an "IN" animation for the "next" view set appropriate
+ // clear color (ie no alpha)
+ [glview setClearColorRed:0.0
+ green:0.0
+ blue:0.0
+ alpha:1.0];
+ }
[glview startTransition];
@@ -26,6 +26,7 @@
3A0BB4D611A9EA7500C6C3D4 /* FlipsideView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3A0BB4D311A9EA7500C6C3D4 /* FlipsideView.xib */; };
3A0BB4D711A9EA7500C6C3D4 /* MainView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3A0BB4D411A9EA7500C6C3D4 /* MainView.xib */; };
3A0BB4D811A9EA7500C6C3D4 /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3A0BB4D511A9EA7500C6C3D4 /* MainWindow.xib */; };
+ 3A4826D211D93FE10059B460 /* Demo3Transition.m in Sources */ = {isa = PBXBuildFile; fileRef = 3A4826D111D93FE10059B460 /* Demo3Transition.m */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
@@ -56,6 +57,8 @@
3A112DAD113A8ED3004D04A4 /* OpenGLES.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGLES.framework; path = System/Library/Frameworks/OpenGLES.framework; sourceTree = SDKROOT; };
3A112DC1113A8F7B004D04A4 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
3A112DDF113A9345004D04A4 /* painting.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = painting.jpg; sourceTree = "<group>"; };
+ 3A4826D011D93FE10059B460 /* Demo3Transition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Demo3Transition.h; path = ../src/Demo3Transition.h; sourceTree = SOURCE_ROOT; };
+ 3A4826D111D93FE10059B460 /* Demo3Transition.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = Demo3Transition.m; path = ../src/Demo3Transition.m; sourceTree = SOURCE_ROOT; };
3A7D0F6E117A423D00CFAD01 /* Demo2Transition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Demo2Transition.h; path = ../src/Demo2Transition.h; sourceTree = SOURCE_ROOT; };
3A7D0F6F117A423D00CFAD01 /* Demo2Transition.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = Demo2Transition.m; path = ../src/Demo2Transition.m; sourceTree = SOURCE_ROOT; };
8D1107310486CEB800E47090 /* DemoProject-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "DemoProject-Info.plist"; plistStructureDefinitionIdentifier = "com.apple.xcode.plist.structure-definition.iphone.info-plist"; sourceTree = "<group>"; };
@@ -181,6 +184,8 @@
3A112DA1113A8E8E004D04A4 /* DemoTransition.m */,
3A7D0F6E117A423D00CFAD01 /* Demo2Transition.h */,
3A7D0F6F117A423D00CFAD01 /* Demo2Transition.m */,
+ 3A4826D011D93FE10059B460 /* Demo3Transition.h */,
+ 3A4826D111D93FE10059B460 /* Demo3Transition.m */,
3A112DA2113A8E8E004D04A4 /* EPGLTransitionView.h */,
3A112DA3113A8E8E004D04A4 /* EPGLTransitionView.m */,
);
@@ -260,6 +265,7 @@
3A0BB4C411A9EA7400C6C3D4 /* DemoTransition.m in Sources */,
3A0BB4C511A9EA7400C6C3D4 /* EPGLTransitionView.m in Sources */,
3A0BB4C611A9EA7400C6C3D4 /* Demo2Transition.m in Sources */,
+ 3A4826D211D93FE10059B460 /* Demo3Transition.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -311,7 +317,7 @@
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
PREBINDING = NO;
- SDKROOT = iphoneos3.1.2;
+ SDKROOT = iphoneos3.2;
};
name = Debug;
};
@@ -324,7 +330,7 @@
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
PREBINDING = NO;
- SDKROOT = iphoneos3.1.2;
+ SDKROOT = iphoneos3.2;
};
name = Release;
};
@@ -2,17 +2,17 @@
<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="7.10">
<data>
<int key="IBDocument.SystemTarget">800</int>
- <string key="IBDocument.SystemVersion">10D573</string>
- <string key="IBDocument.InterfaceBuilderVersion">762</string>
+ <string key="IBDocument.SystemVersion">10D578</string>
+ <string key="IBDocument.InterfaceBuilderVersion">788</string>
<string key="IBDocument.AppKitVersion">1038.29</string>
<string key="IBDocument.HIToolboxVersion">460.00</string>
<object class="NSMutableDictionary" key="IBDocument.PluginVersions">
<string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
- <string key="NS.object.0">87</string>
+ <string key="NS.object.0">117</string>
</object>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<bool key="EncodedWithXMLCoder">YES</bool>
- <integer value="34"/>
+ <integer value="43"/>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -107,6 +107,27 @@
</object>
<reference key="IBUINormalTitleShadowColor" ref="550989507"/>
</object>
+ <object class="IBUIButton" id="848187571">
+ <reference key="NSNextResponder" ref="883825266"/>
+ <int key="NSvFlags">265</int>
+ <string key="NSFrame">{{411, 769}, {311, 45}}</string>
+ <reference key="NSSuperview" ref="883825266"/>
+ <bool key="IBUIOpaque">NO</bool>
+ <bool key="IBUIClearsContextBeforeDrawing">NO</bool>
+ <int key="IBUITag">2</int>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <reference key="IBUIFont" ref="478974045"/>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Flip</string>
+ <reference key="IBUIHighlightedTitleColor" ref="211966727"/>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzE0IDAuMzA5ODAzOTIxNiAwLjUyMTU2ODYyNzUAA</bytes>
+ </object>
+ <reference key="IBUINormalTitleShadowColor" ref="550989507"/>
+ </object>
</object>
<string key="NSFrameSize">{768, 1004}</string>
<reference key="NSSuperview"/>
@@ -153,6 +174,15 @@
</object>
<int key="connectionID">42</int>
</object>
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchEventConnection" key="connection">
+ <string key="label">showInfo:</string>
+ <reference key="source" ref="848187571"/>
+ <reference key="destination" ref="372490531"/>
+ <int key="IBEventType">7</int>
+ </object>
+ <int key="connectionID">44</int>
+ </object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
<object class="NSArray" key="orderedObjects">
@@ -182,6 +212,7 @@
<reference ref="211512961"/>
<reference ref="558454645"/>
<reference ref="9374807"/>
+ <reference ref="848187571"/>
</object>
<reference key="parent" ref="0"/>
</object>
@@ -200,6 +231,11 @@
<reference key="object" ref="9374807"/>
<reference key="parent" ref="883825266"/>
</object>
+ <object class="IBObjectRecord">
+ <int key="objectID">43</int>
+ <reference key="object" ref="848187571"/>
+ <reference key="parent" ref="883825266"/>
+ </object>
</object>
</object>
<object class="NSMutableDictionary" key="flattenedProperties">
@@ -215,13 +251,14 @@
<string>36.IBPluginDependency</string>
<string>38.IBPluginDependency</string>
<string>39.IBPluginDependency</string>
+ <string>43.IBPluginDependency</string>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>MainViewController</string>
<string>UIResponder</string>
<string>MainView</string>
- <string>{{337, 4}, {783, 852}}</string>
+ <string>{{337, 71}, {783, 785}}</string>
<object class="NSMutableDictionary">
<string key="NS.key.0">IBCocoaTouchFramework</string>
<integer value="0" key="NS.object.0"/>
@@ -230,6 +267,7 @@
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
</object>
</object>
<object class="NSMutableDictionary" key="unlocalizedProperties">
@@ -248,7 +286,7 @@
</object>
</object>
<nil key="sourceID"/>
- <int key="maxID">42</int>
+ <int key="maxID">44</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
@@ -268,6 +306,13 @@
<string key="NS.key.0">showInfo:</string>
<string key="NS.object.0">id</string>
</object>
+ <object class="NSMutableDictionary" key="actionInfosByName">
+ <string key="NS.key.0">showInfo:</string>
+ <object class="IBActionInfo" key="NS.object.0">
+ <string key="name">showInfo:</string>
+ <string key="candidateClassName">id</string>
+ </object>
+ </object>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">Classes/MainViewController.h</string>
@@ -480,6 +525,20 @@
<string key="className">UIViewController</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
+ <string key="minorKey">UIKit.framework/Headers/UIPopoverController.h</string>
+ </object>
+ </object>
+ <object class="IBPartialClassDescription">
+ <string key="className">UIViewController</string>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBFrameworkSource</string>
+ <string key="minorKey">UIKit.framework/Headers/UISplitViewController.h</string>
+ </object>
+ </object>
+ <object class="IBPartialClassDescription">
+ <string key="className">UIViewController</string>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UITabBarController.h</string>
</object>
</object>
@@ -510,6 +569,6 @@
<string key="NS.key.0">painting.jpg</string>
<string key="NS.object.0">{320, 480}</string>
</object>
- <string key="IBCocoaTouchPluginVersion">87</string>
+ <string key="IBCocoaTouchPluginVersion">117</string>
</data>
</archive>
@@ -11,6 +11,7 @@
#import "DemoTransition.h"
#import "Demo2Transition.h"
+#import "Demo3Transition.h"
@implementation MainViewController
@@ -55,30 +56,31 @@ - (IBAction)showInfo:(id)sender
NSObject<EPGLTransitionViewDelegate> *transition;
- if ([sender tag])
- transition = [[[Demo2Transition alloc] init] autorelease];
- else
- transition = [[[DemoTransition alloc] init] autorelease];
-
+ switch ([sender tag]) {
+ case 0:
+ transition = [[[DemoTransition alloc] init] autorelease];
+ break;
+ case 1:
+ transition = [[[Demo2Transition alloc] init] autorelease];
+ break;
+ case 2:
+ transition = [[[Demo3Transition alloc] init] autorelease];
+ break;
+ }
+
EPGLTransitionView *glview = [[[EPGLTransitionView alloc]
initWithView:self.view
delegate:transition] autorelease];
- if ([sender tag])
+ if ([sender tag]) {
[glview prepareTextureTo:controller.view];
-
-#ifdef ENABLE_PHASE_IN
- else
- // Get texture for the "next" view
- [glview prepareTextureTo:controller.view];
-
- // If you are using an "IN" animation for the "next" view set appropriate
- // clear color (ie no alpha)
- [glview setClearColorRed:0.3
- green:0.3
- blue:0.3
- alpha:1.0];
-#endif
+ // If you are using an "IN" animation for the "next" view set appropriate
+ // clear color (ie no alpha)
+ [glview setClearColorRed:0.0
+ green:0.0
+ blue:0.0
+ alpha:1.0];
+ }
[glview startTransition];
@@ -26,6 +26,7 @@
3A112DC2113A8F7B004D04A4 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3A112DC1113A8F7B004D04A4 /* QuartzCore.framework */; };
3A112DE0113A9345004D04A4 /* painting.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 3A112DDF113A9345004D04A4 /* painting.jpg */; };
3A7D0F70117A423D00CFAD01 /* Demo2Transition.m in Sources */ = {isa = PBXBuildFile; fileRef = 3A7D0F6F117A423D00CFAD01 /* Demo2Transition.m */; };
+ 3A81AF5E11D92E9F002C1EFB /* Demo3Transition.m in Sources */ = {isa = PBXBuildFile; fileRef = 3A81AF5D11D92E9F002C1EFB /* Demo3Transition.m */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
@@ -58,6 +59,8 @@
3A112DDF113A9345004D04A4 /* painting.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = painting.jpg; sourceTree = "<group>"; };
3A7D0F6E117A423D00CFAD01 /* Demo2Transition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Demo2Transition.h; path = ../src/Demo2Transition.h; sourceTree = SOURCE_ROOT; };
3A7D0F6F117A423D00CFAD01 /* Demo2Transition.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = Demo2Transition.m; path = ../src/Demo2Transition.m; sourceTree = SOURCE_ROOT; };
+ 3A81AF5C11D92E9F002C1EFB /* Demo3Transition.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Demo3Transition.h; path = ../src/Demo3Transition.h; sourceTree = SOURCE_ROOT; };
+ 3A81AF5D11D92E9F002C1EFB /* Demo3Transition.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = Demo3Transition.m; path = ../src/Demo3Transition.m; sourceTree = SOURCE_ROOT; };
8D1107310486CEB800E47090 /* DemoProject-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "DemoProject-Info.plist"; plistStructureDefinitionIdentifier = "com.apple.xcode.plist.structure-definition.iphone.info-plist"; sourceTree = "<group>"; };
/* End PBXFileReference section */
@@ -173,6 +176,8 @@
3A112DA1113A8E8E004D04A4 /* DemoTransition.m */,
3A7D0F6E117A423D00CFAD01 /* Demo2Transition.h */,
3A7D0F6F117A423D00CFAD01 /* Demo2Transition.m */,
+ 3A81AF5C11D92E9F002C1EFB /* Demo3Transition.h */,
+ 3A81AF5D11D92E9F002C1EFB /* Demo3Transition.m */,
3A112DA2113A8E8E004D04A4 /* EPGLTransitionView.h */,
3A112DA3113A8E8E004D04A4 /* EPGLTransitionView.m */,
);
@@ -252,6 +257,7 @@
3A112DA4113A8E8E004D04A4 /* DemoTransition.m in Sources */,
3A112DA5113A8E8E004D04A4 /* EPGLTransitionView.m in Sources */,
3A7D0F70117A423D00CFAD01 /* Demo2Transition.m in Sources */,
+ 3A81AF5E11D92E9F002C1EFB /* Demo3Transition.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -293,7 +299,7 @@
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
PREBINDING = NO;
- SDKROOT = iphoneos3.1.2;
+ SDKROOT = iphoneos3.2;
};
name = Debug;
};
@@ -306,7 +312,7 @@
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
PREBINDING = NO;
- SDKROOT = iphoneos3.1.2;
+ SDKROOT = iphoneos3.2;
};
name = Release;
};
Oops, something went wrong.

0 comments on commit bc2aa36

Please sign in to comment.