Merge pull request #4 from yoshisuga/icade

Fix iCade support; Support for native resolutions for iPhone 6/6 Plus screen sizes
This commit is contained in:
Olivier Goguel 2016-03-29 19:06:32 +02:00
commit f7e86a312b
15 changed files with 388 additions and 26 deletions

View File

@ -0,0 +1,111 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "1x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
},
{
"size" : "57x57",
"idiom" : "iphone",
"filename" : "icon.png",
"scale" : "1x"
},
{
"size" : "57x57",
"idiom" : "iphone",
"filename" : "icon@2x.png",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "50x50",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "50x50",
"scale" : "2x"
},
{
"size" : "72x72",
"idiom" : "ipad",
"filename" : "icon72.png",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "72x72",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "76x76",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "76x76",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "83.5x83.5",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -0,0 +1,90 @@
{
"images" : [
{
"idiom" : "iphone",
"scale" : "2x",
"orientation" : "portrait"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "Default.png",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"subtype" : "retina4",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"minimum-system-version" : "7.0",
"subtype" : "retina4",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"minimum-system-version" : "7.0",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"minimum-system-version" : "7.0",
"extent" : "full-screen",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"minimum-system-version" : "7.0",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"minimum-system-version" : "7.0",
"extent" : "full-screen",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

View File

@ -0,0 +1,6 @@
{
"info" : {
"version" : 1,
"author" : "xcode"
}
}

View File

@ -0,0 +1,146 @@
{
"images" : [
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "736h",
"filename" : "activegs-launch-iphone6plus.png",
"minimum-system-version" : "8.0",
"orientation" : "portrait",
"scale" : "3x"
},
{
"orientation" : "landscape",
"idiom" : "iphone",
"extent" : "full-screen",
"minimum-system-version" : "8.0",
"subtype" : "736h",
"scale" : "3x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "667h",
"filename" : "activegs-launch-iphone6.png",
"minimum-system-version" : "8.0",
"orientation" : "portrait",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"filename" : "activegs-launch-iphone4s.png",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"extent" : "full-screen",
"idiom" : "iphone",
"subtype" : "retina4",
"filename" : "activegs-launch-iphone5.png",
"minimum-system-version" : "7.0",
"orientation" : "portrait",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"extent" : "full-screen",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"extent" : "full-screen",
"subtype" : "retina4",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "full-screen",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "full-screen",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "to-status-bar",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "full-screen",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 193 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 237 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 665 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 684 KiB

View File

@ -8,12 +8,6 @@
<string>ActiveGS</string>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleIconFiles</key>
<array>
<string>icon.png</string>
<string>icon72.png</string>
<string>icon@2x.png</string>
</array>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>

View File

@ -237,6 +237,7 @@
7E51482F1CA6B5CE005DA0A6 /* ShastonHi640.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 7E51481C1CA6B5CE005DA0A6 /* ShastonHi640.ttf */; };
7E5148301CA6B5CE005DA0A6 /* Spin Up Search 1.wav in Resources */ = {isa = PBXBuildFile; fileRef = 7E51481D1CA6B5CE005DA0A6 /* Spin Up Search 1.wav */; };
7E5148311CA6B5CE005DA0A6 /* Spin Up Search 2.wav in Resources */ = {isa = PBXBuildFile; fileRef = 7E51481E1CA6B5CE005DA0A6 /* Spin Up Search 2.wav */; };
928410581CA8443A00DC5D93 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 928410571CA8443A00DC5D93 /* Images.xcassets */; };
/* End PBXBuildFile section */
/* Begin PBXBuildRule section */
@ -573,6 +574,7 @@
7E51481C1CA6B5CE005DA0A6 /* ShastonHi640.ttf */ = {isa = PBXFileReference; lastKnownFileType = file; path = ShastonHi640.ttf; sourceTree = "<group>"; };
7E51481D1CA6B5CE005DA0A6 /* Spin Up Search 1.wav */ = {isa = PBXFileReference; lastKnownFileType = audio.wav; path = "Spin Up Search 1.wav"; sourceTree = "<group>"; };
7E51481E1CA6B5CE005DA0A6 /* Spin Up Search 2.wav */ = {isa = PBXFileReference; lastKnownFileType = audio.wav; path = "Spin Up Search 2.wav"; sourceTree = "<group>"; };
928410571CA8443A00DC5D93 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = ActiveGS/Images.xcassets; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@ -1023,6 +1025,7 @@
29B97317FDCFA39411CA2CEA /* Resources */ = {
isa = PBXGroup;
children = (
928410571CA8443A00DC5D93 /* Images.xcassets */,
090A6076163093D800C8FB59 /* Default-568h@2x.png */,
095542A6128375C40035AE09 /* Tab][.png */,
095542A7128375C40035AE09 /* Tab][@2x.png */,
@ -1195,6 +1198,7 @@
09E7BE3911FC935E00DCCFE7 /* XMASDEMO.FTA in Resources */,
09BCB6281211649D009858DF /* flobynoid (2002).dsk.zip in Resources */,
09087F3A12244C0500C52D88 /* delta_1.png in Resources */,
928410581CA8443A00DC5D93 /* Images.xcassets in Resources */,
09087F3B12244C0500C52D88 /* delta_2.png in Resources */,
09087F3C12244C0500C52D88 /* delta_3.png in Resources */,
09087F3D12244C0500C52D88 /* delta_4.png in Resources */,
@ -1400,6 +1404,8 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
CODE_SIGN_ENTITLEMENTS = "";
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = YES;
@ -1422,7 +1428,7 @@
"$(inherited)",
"\"$(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks/GraphicsServices.framework\"",
);
PRODUCT_BUNDLE_IDENTIFIER = com.myname.myid;
PRODUCT_BUNDLE_IDENTIFIER = com.freetoolsassociation.activegs;
PRODUCT_NAME = ActiveGS;
PROVISIONING_PROFILE = "";
SDKROOT = iphoneos;
@ -1435,6 +1441,8 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
CODE_SIGN_ENTITLEMENTS = "";
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = NO;
@ -1459,7 +1467,7 @@
"$(inherited)",
"\"$(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks/GraphicsServices.framework\"",
);
PRODUCT_BUNDLE_IDENTIFIER = com.myname.myid;
PRODUCT_BUNDLE_IDENTIFIER = com.freetoolsassociation.activegs;
PRODUCT_NAME = ActiveGS;
PROVISIONING_PROFILE = "";
SDKROOT = iphoneos;
@ -1471,6 +1479,8 @@
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
CODE_SIGN_ENTITLEMENTS = "";
CODE_SIGN_IDENTITY = "iPhone Developer";
COPY_PHASE_STRIP = YES;
@ -1492,7 +1502,7 @@
"$(inherited)",
"\"$(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks/GraphicsServices.framework\"",
);
PRODUCT_BUNDLE_IDENTIFIER = com.myname.myid;
PRODUCT_BUNDLE_IDENTIFIER = com.freetoolsassociation.activegs;
PRODUCT_NAME = ActiveGS;
PROVISIONING_PROFILE = "";
SDKROOT = iphoneos;

View File

@ -460,7 +460,7 @@ extern int findCode(const char* _s);
self.textField = [[UITextField alloc] initWithFrame:CGRectMake(0, 0, 0, 0)];
self.textField.delegate = self;
self.textField.autocapitalizationType= UITextAutocapitalizationTypeAllCharacters;
self.textField.autocapitalizationType= UITextAutocorrectionTypeNo;
self.textField.text= @"*"; // Put a default value to capture del key
[self.interfaceView addSubview:self.textField];
@ -549,7 +549,11 @@ extern int findCode(const char* _s);
externalKeyboard = FALSE;
[self detectHardwareKeyboard:nil];
// If iCade explicitly selected in options, force enable it
if ( option.getIntValue(OPTION_JOYSTICKMODE) == JOYSTICK_TYPE_ICADE ) {
[self setiCadeMode:YES];
}
[self setInputMode:INPUTMODE_ACCESS+INPUTMODE_HIDDEN];
[self setMenuBarVisibility:TRUE]; // So First time users are not lost!
@ -596,12 +600,13 @@ int hardwarekeyboard= 0;
option.setIntValue(OPTION_JOYSTICKMODE,JOYSTICK_TYPE_ICADE);
[self setInputMode:inputMode&INPUTMODE_PAD];
[pManager setNotificationText:@"iCade activated"];
g_joystick_type = JOYSTICK_TYPE_ICADE;
}
else
{
option.setIntValue(OPTION_JOYSTICKMODE,JOYSTICK_TYPE_KEYPAD);
option.setIntValue(OPTION_JOYSTICKMODE,JOYSTICK_TYPE_NATIVE_1);
[pManager setNotificationText:@"iCade de-activated"];
g_joystick_type = JOYSTICK_TYPE_NATIVE_1;
}
[self refreshControls:nil];
@ -692,17 +697,13 @@ scontrol runtimeControlDefs[]={
{ LOCKZOOM_AUTO,LOCKZOOM_ON, LOCKZOOM_ARCADE},
nil
},
/*
#if 0
{
RC_JOYSTICK,
"Pad Input" ,
{ "iDevice", "iCade",NULL },
{ "TouchPad", "iCade",NULL },
{ JOYSTICK_TYPE_NATIVE_1,JOYSTICK_TYPE_ICADE},
nil
},
#endif
*/
#ifdef ACTIVEGS_NOHARDWAREKEYBOARDDETECTION
{
RC_KBD,
@ -812,6 +813,11 @@ extern int x_frame_rate ;
case RC_JOYSTICK:
option.setIntValue(OPTION_JOYSTICKMODE,v);
g_joystick_type = v;
if ( v == JOYSTICK_TYPE_ICADE ) {
[self setiCadeMode:YES];
} else {
[self setiCadeMode:NO];
}
break;
case RC_DISPLAY:
// monitor
@ -1843,7 +1849,7 @@ extern int x_frame_rate ;
const char* iCadeDetectString="zexwzexw";
const char* iCadeDetectString="wewexzxz";
int iCadeDetectPos=0;
int keypad_x = 0;
@ -1897,11 +1903,10 @@ int x_adb_get_keypad_y()
else
[self setiCadeMode:TRUE];
return NO;
/*
option.setIntValue(OPTION_JOYSTICKMODE,JOYSTICK_TYPE_ICADE);
[self setInputMode:inputMode&INPUTMODE_PAD];
[self refreshControls:nil];
*/
}
}
else
@ -1914,20 +1919,20 @@ int x_adb_get_keypad_y()
{
switch(c)
{
case 'z': // up
case 'w': // up
keypad_y = -32767;
break;
case 'e':
case 'w': // !verti
case 'e': // !verti
case 'z':
keypad_y = 0;
break;
case 'x': // down
keypad_y = 32767;
break;
case 'q': // left
case 'a': // left
keypad_x = -32767;
break;
case 'a': // !hori
case 'q': // !hori
case 'c':
keypad_x = 0;
break;