[commit] r2300 - iOS 5.8b11 add SqueakUIFadeForFullScreenInSeconds, bug fix

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[commit] r2300 - iOS 5.8b11 add SqueakUIFadeForFullScreenInSeconds, bug fix

commits-3
 
Author: johnmci
Date: 2010-09-12 17:19:02 -0700 (Sun, 12 Sep 2010)
New Revision: 2300

Modified:
   trunk/platforms/iOS/vm/OSX/sqSqueakOSXApplication+attributes.m
   trunk/platforms/iOS/vm/OSX/sqSqueakOSXInfoPlistInterface.h
   trunk/platforms/iOS/vm/OSX/sqSqueakOSXInfoPlistInterface.m
   trunk/platforms/iOS/vm/OSX/sqSqueakOSXNSView.m
   trunk/platforms/iOS/vm/SqueakPureObjc-Info.plist
   trunk/platforms/iOS/vm/SqueakPureObjc-InfoCOG.plist
   trunk/platforms/iOS/vm/iPhone/Classes/sqSqueakIPhoneApplication+attributes.m
Log:
iOS 5.8b11  add SqueakUIFadeForFullScreenInSeconds, bug fix

Add SqueakUIFadeForFullScreenInSeconds to allow you to change the fade in/out timeout for full screen on/off.

Bug fix. On a drag/drop if you dragged a picture and a squeak image we would not process the squeak image, only the picture. We need to do both.



Modified: trunk/platforms/iOS/vm/OSX/sqSqueakOSXApplication+attributes.m
===================================================================
--- trunk/platforms/iOS/vm/OSX/sqSqueakOSXApplication+attributes.m 2010-09-12 16:49:10 UTC (rev 2299)
+++ trunk/platforms/iOS/vm/OSX/sqSqueakOSXApplication+attributes.m 2010-09-13 00:19:02 UTC (rev 2300)
@@ -83,7 +83,8 @@
 
 #if STACKVM
 
- return "Mac Cocoa Cog 5.8b10 07-Sep-10 >8AD3A516-DBAC-4CD4-BC89-8F21317DF7E1<";
+ return "Mac Cocoa Cog 5.8b11 12-Sep-10 >9BFC792A-F173-4C65-AD2A-FFFB1D52DAC2<";
+// return "Mac Cocoa Cog 5.8b10 07-Sep-10 >8AD3A516-DBAC-4CD4-BC89-8F21317DF7E1<";
 // return "Mac Cocoa Cog 5.8b9 06-Sep-10 >01641B99-1842-4422-A99D-43153BEDEFFA<";
 // return "Mac Cocoa Cog 5.8b8 04-Sep-10 >8A66B7E0-B578-4E5F-97B4-6195547A35F5<";
 // return "Mac Cocoa Cog 5.8b7 02-Sep-10 >4EBF00E3-453E-4010-9AC8-6B64C292984B<";

Modified: trunk/platforms/iOS/vm/OSX/sqSqueakOSXInfoPlistInterface.h
===================================================================
--- trunk/platforms/iOS/vm/OSX/sqSqueakOSXInfoPlistInterface.h 2010-09-12 16:49:10 UTC (rev 2299)
+++ trunk/platforms/iOS/vm/OSX/sqSqueakOSXInfoPlistInterface.h 2010-09-13 00:19:02 UTC (rev 2300)
@@ -49,6 +49,7 @@
  NSURL *SqueakTrustedDirectory;
  NSURL *SqueakResourceDirectory;
  NSTimeInterval SqueakUIFlushPrimaryDeferNMilliseconds;
+ float SqueakUIFadeForFullScreenInSeconds;
  NSInteger SqueakMouseMappings[4][4];
  NSInteger SqueakBrowserMouseMappings[4][4];
  NSInteger SqueakNumStackPages;
@@ -65,8 +66,10 @@
 @property (nonatomic,retain) NSURL* SqueakTrustedDirectory;
 @property (nonatomic,retain) NSURL* SqueakResourceDirectory;
 @property (nonatomic,assign) NSTimeInterval SqueakUIFlushPrimaryDeferNMilliseconds;
+@property (nonatomic,assign) float SqueakUIFadeForFullScreenInSeconds;
 
 - (void) setInfoPlistNumberValueFrom: (NSDictionary*) dict key: (NSString *) key  default: (NSInteger) number using: (SEL) selector;
+- (void) setInfoPlistFloatNumberValueFrom: (NSDictionary*) dict key: (NSString *) key  default: (float) number using: (SEL) selector;
 - (void) setInfoPlistBooleanValueFrom: (NSDictionary*) dict key: (NSString *) key  default: (BOOL) defaultBool using: (SEL) selector;
 - (void) setInfoPlistNumberValueForMouseX: (NSInteger) x Y: (NSInteger) y from: (NSDictionary*) dict key: (NSString *) key  default: (NSInteger) number browser: (BOOL) browser;
 - (NSURL *) expandNSStringIntoNSURL: (NSString*) originalPath doOptionalSqueakLandLogic: (BOOL) isetoysonastick;

Modified: trunk/platforms/iOS/vm/OSX/sqSqueakOSXInfoPlistInterface.m
===================================================================
--- trunk/platforms/iOS/vm/OSX/sqSqueakOSXInfoPlistInterface.m 2010-09-12 16:49:10 UTC (rev 2299)
+++ trunk/platforms/iOS/vm/OSX/sqSqueakOSXInfoPlistInterface.m 2010-09-13 00:19:02 UTC (rev 2300)
@@ -43,7 +43,8 @@
 @implementation sqSqueakOSXInfoPlistInterface
 @synthesize SqueakDebug,SqueakQuitOnQuitAppleEvent,
  SqueakMaxHeapSize,SqueakUnTrustedDirectory,SqueakTrustedDirectory,SqueakResourceDirectory,
- SqueakPluginsBuiltInOrLocalOnly,SqueakExplicitWindowOpenNeeded,SqueakUIFlushPrimaryDeferNMilliseconds,SqueakNumStackPages,SqueakEdenBytes;
+ SqueakPluginsBuiltInOrLocalOnly,SqueakExplicitWindowOpenNeeded,SqueakUIFlushPrimaryDeferNMilliseconds,SqueakNumStackPages,SqueakEdenBytes,
+ SqueakUIFadeForFullScreenInSeconds;
 
 - (void) setOverrideSqueakNumStackPages: (NSNumber *) v {
  self.SqueakNumStackPages = [v integerValue];
@@ -78,6 +79,10 @@
  self.SqueakMaxHeapSize = [v unsignedIntValue];
 }
 
+- (void) setOverrideSqueakUIFadeForFullScreenInSeconds: (NSNumber *) v {
+ self.SqueakUIFadeForFullScreenInSeconds = [v floatValue];
+}
+
 - (void) setOverrideSqueakUIFlushPrimaryDeferNMilliseconds: (NSNumber *) v {
  self.SqueakUIFlushPrimaryDeferNMilliseconds = [v doubleValue]/1000.0;
 }
@@ -131,6 +136,12 @@
  [self performSelectorOnMainThread: selector withObject: num waitUntilDone: YES];
 }
 
+- (void) setInfoPlistFloatNumberValueFrom: (NSDictionary*) dict key: (NSString *) key  default: (float) defaultFloat using: (SEL) selector{
+ NSNumber *num = [dict objectForKey: key];
+ num = (num) ? num : [NSNumber numberWithFloat: defaultFloat];
+ [self performSelectorOnMainThread: selector withObject: num waitUntilDone: YES];
+}
+
 - (void) setInfoPlistBooleanValueFrom: (NSDictionary*) dict key: (NSString *) key  default: (BOOL) defaultBool using: (SEL) selector{
  NSNumber *num = [dict objectForKey: key];
  num = (num) ? num : [NSNumber numberWithBool: defaultBool];
@@ -188,6 +199,7 @@
  [self setInfoPlistBooleanValueFrom: dict key: @"SqueakUseFileMappedMMAP" default: NO using: @selector(setOverrideSqueakUseFileMappedMMAP:)];
  [self setInfoPlistNumberValueFrom: dict key: @"SqueakMaxHeapSize" default: 512*1024*1024 using: @selector(setOverrideSqueakMaxHeapSize:)];
  [self setInfoPlistNumberValueFrom: dict key: @"SqueakUIFlushPrimaryDeferNMilliseconds" default: 20 using: @selector(setOverrideSqueakUIFlushPrimaryDeferNMilliseconds:)];
+ [self setInfoPlistFloatNumberValueFrom: dict key: @"SqueakUIFadeForFullScreenInSeconds" default: 1.5 using: @selector(setOverrideSqueakUIFadeForFullScreenInSeconds:)];
 
  [self setInfoPlistNSStringValueFrom: dict key: @"SqueakUnTrustedDirectory" default: @"/foobar/tooBar/forSqueak/bogus/" using: @selector(setOverrideSqueakUnTrustedDirectory:)];
  [self setInfoPlistNSStringValueFrom: dict key: @"SqueakTrustedDirectory" default: @"/foobar/tooBar/forSqueak/bogus/" using: @selector(setOverrideSqueakTrustedDirectory:)];

Modified: trunk/platforms/iOS/vm/OSX/sqSqueakOSXNSView.m
===================================================================
--- trunk/platforms/iOS/vm/OSX/sqSqueakOSXNSView.m 2010-09-12 16:49:10 UTC (rev 2299)
+++ trunk/platforms/iOS/vm/OSX/sqSqueakOSXNSView.m 2010-09-13 00:19:02 UTC (rev 2300)
@@ -43,6 +43,7 @@
 #import "sqSqueakOSXScreenAndWindow.h"
 #import "SqueakOSXAppDelegate.h"
 #import "sqSqueakOSXApplication+events.h"
+#import "sqSqueakOSXInfoPlistInterface.h"
 #import "sq.h"
 #import "sqVirtualMachine.h"
 
@@ -638,24 +639,25 @@
  if (self.dragCount) {
  self.dragItems = [self filterOutSqueakImageFilesFromDraggedFiles: info];
  [(sqSqueakOSXApplication *) gDelegateApp.squeakApplication recordDragEvent: DragDrop numberOfFiles: self.dragCount where: [info draggingLocation] windowIndex: self.windowLogic.windowIndex];
- } else {
- NSArray *images = [self filterSqueakImageFilesFromDraggedFiles: info];
- if ([images count] > 0) {
- for (NSString *item in images ){
- NSURL *url = [NSURL fileURLWithPath:[[NSBundle mainBundle] bundlePath]];
- LSLaunchURLSpec launchSpec;
- launchSpec.appURL = (CFURLRef)url;
- launchSpec.passThruParams = NULL;
- launchSpec.itemURLs = (CFArrayRef) [NSArray arrayWithObject:[NSURL fileURLWithPath: item]];
- launchSpec.launchFlags = kLSLaunchDefaults | kLSLaunchNewInstance;
- launchSpec.asyncRefCon = NULL;
-
- OSErr err = LSOpenFromURLSpec(&launchSpec, NULL);
+ }
+
+ NSArray *images = [self filterSqueakImageFilesFromDraggedFiles: info];
+ if ([images count] > 0) {
+ for (NSString *item in images ){
+ NSURL *url = [NSURL fileURLWithPath:[[NSBundle mainBundle] bundlePath]];
+ LSLaunchURLSpec launchSpec;
+ launchSpec.appURL = (CFURLRef)url;
+ launchSpec.passThruParams = NULL;
+ launchSpec.itemURLs = (CFArrayRef) [NSArray arrayWithObject:[NSURL fileURLWithPath: item]];
+ launchSpec.launchFlags = kLSLaunchDefaults | kLSLaunchNewInstance;
+ launchSpec.asyncRefCon = NULL;
+
+ OSErr err = LSOpenFromURLSpec(&launchSpec, NULL);
 #pragma unused(err)
- }
  }
+ }
 
- }
+
 
  dragInProgress = NO;
  return YES;
@@ -709,7 +711,7 @@
   &fadeToken);
  if (err == kCGErrorSuccess) {
  CGDisplayFade(fadeToken,
-  1.5f,
+  ((sqSqueakOSXInfoPlistInterface*) gDelegateApp.squeakApplication.infoPlistInterfaceLogic).SqueakUIFadeForFullScreenInSeconds,
   (CGDisplayBlendFraction)kCGDisplayBlendNormal,
   (CGDisplayBlendFraction)kCGDisplayBlendSolidColor,
   0.0f,
@@ -723,7 +725,7 @@
  CGDisplayErr    err;
 
  err = CGDisplayFade(fadeToken,
- 3.5f,
+ ((sqSqueakOSXInfoPlistInterface*) gDelegateApp.squeakApplication.infoPlistInterfaceLogic).SqueakUIFadeForFullScreenInSeconds,
  (CGDisplayBlendFraction)kCGDisplayBlendSolidColor,
  (CGDisplayBlendFraction)kCGDisplayBlendNormal,
  0.0f,

Modified: trunk/platforms/iOS/vm/SqueakPureObjc-Info.plist
===================================================================
--- trunk/platforms/iOS/vm/SqueakPureObjc-Info.plist 2010-09-12 16:49:10 UTC (rev 2299)
+++ trunk/platforms/iOS/vm/SqueakPureObjc-Info.plist 2010-09-13 00:19:02 UTC (rev 2300)
@@ -445,6 +445,8 @@
  <string>/foobar/tooBar/forSqueak/bogus/</string>
  <key>SqueakUseFileMappedMMAP</key>
  <false/>
+ <key>SqueakUIFadeForFullScreenInSeconds</key>
+ <real>0.5</real>
  <key>UTExportedTypeDeclarations</key>
  <array>
  <dict>

Modified: trunk/platforms/iOS/vm/SqueakPureObjc-InfoCOG.plist
===================================================================
--- trunk/platforms/iOS/vm/SqueakPureObjc-InfoCOG.plist 2010-09-12 16:49:10 UTC (rev 2299)
+++ trunk/platforms/iOS/vm/SqueakPureObjc-InfoCOG.plist 2010-09-13 00:19:02 UTC (rev 2300)
@@ -350,7 +350,7 @@
  <key>CFBundleExecutable</key>
  <string>${EXECUTABLE_NAME}</string>
  <key>CFBundleGetInfoString</key>
- <string>Squeak VM 5.8b10 http://www.squeak.org</string>
+ <string>Squeak VM 5.8b11 http://www.squeak.org</string>
  <key>CFBundleIconFile</key>
  <string>Squeak.icns</string>
  <key>CFBundleIdentifier</key>
@@ -362,11 +362,11 @@
  <key>CFBundlePackageType</key>
  <string>APPL</string>
  <key>CFBundleShortVersionString</key>
- <string>5.8b10</string>
+ <string>5.8b11</string>
  <key>CFBundleSignature</key>
  <string>FAST</string>
  <key>CFBundleVersion</key>
- <string>28.0</string>
+ <string>29.0</string>
  <key>LSBackgroundOnly</key>
  <false/>
  <key>LSMinimumSystemVersion</key>
@@ -445,6 +445,8 @@
  <string>/foobar/tooBar/forSqueak/bogus/</string>
  <key>SqueakUseFileMappedMMAP</key>
  <false/>
+ <key>SqueakUIFadeForFullScreenInSeconds</key>
+ <real>0.75</real>
  <key>UTExportedTypeDeclarations</key>
  <array>
  <dict>

Modified: trunk/platforms/iOS/vm/iPhone/Classes/sqSqueakIPhoneApplication+attributes.m
===================================================================
--- trunk/platforms/iOS/vm/iPhone/Classes/sqSqueakIPhoneApplication+attributes.m 2010-09-12 16:49:10 UTC (rev 2299)
+++ trunk/platforms/iOS/vm/iPhone/Classes/sqSqueakIPhoneApplication+attributes.m 2010-09-13 00:19:02 UTC (rev 2300)
@@ -85,6 +85,20 @@
  return "iPhone 1.0.1b1 18-May-08 >1B1BAAE0-F4CA-4192-B3E5-4FE51E5BB820<";
  return "iPhone 1.0.2b1 02-Sep-08 >08F8D709-6867-4272-B18C-DBA704CB3C62<";
 */
+ case 1007: { /* vm build string also info.plist */
+#if STACKVM
+ extern char *__interpBuildInfo;
+ return __interpBuildInfo;
+#endif
+ break;
+ }
+ case 1008: { /* vm build string also info.plist */
+# if COGVM
+ extern char *__cogitBuildInfo;
+ return __cogitBuildInfo;
+#endif
+ break;
+ }
  default:
  break;
  }