adjusted controls for Touch interface on iOS.

* Single Tap now implemented
* Touch and Hold (2 secs) to pop up menu
* added a pan gesture to simulate flicking up/down and left/right
* removed dependency on binding keys to game for iOS devices. (perhaps extend this to all touch devices.)
* flicking motion needs to be expanded to allow for smooth scrolling. Right now every flick is equivalent to going one slot up/down/left/right.
This commit is contained in:
techdragon.nguyen@gmail.com
2011-09-04 08:31:36 +00:00
parent df4aa9f6c2
commit ad72c0ddc3
5 changed files with 239 additions and 98 deletions

View File

@@ -189,7 +189,7 @@ bool CardSelector::CheckUserInput(JButton key)
int x,y;
if(JGE::GetInstance()->GetLeftClickCoordinates(x, y))
{
active = closest<True> (cards, limitor, static_cast<float> (x), static_cast<float> (y));
active = closest<True> (cards, limitor, static_cast<float> (x), static_cast<float> (y));
}
switch (key)

View File

@@ -2302,6 +2302,7 @@ WGuiBase::CONFIRM_TYPE WGuiKeyBinder::needsConfirm()
}
// Check whether any button has no key associated to it.
#if (!defined IOS)
confirmingButton = JGE_BTN_NONE;
for (signed int i = (sizeof(btnToCheck) / sizeof(btnToCheck[0])) - 1; i >= 0; --i)
{
@@ -2326,7 +2327,8 @@ WGuiBase::CONFIRM_TYPE WGuiKeyBinder::needsConfirm()
confirmMenu->Add(2, _("This is okay, validate and save").c_str());
return CONFIRM_NEED;
}
#endif // IOS
return CONFIRM_OK;
}

View File

@@ -6,6 +6,8 @@
<string>English</string>
<key>CFBundleDisplayName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundleDocumentTypes</key>
<array/>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleGetInfoString</key>
@@ -13,7 +15,7 @@
<key>CFBundleIconFile</key>
<string>wagic-64x64.png</string>
<key>CFBundleIdentifier</key>
<string>somethingsmart.com.${PRODUCT_NAME:rfc1034identifier}</string>
<string>net.wagic.game.app</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
@@ -24,6 +26,8 @@
<string></string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
<array/>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>LSRequiresIPhoneOS</key>
@@ -46,5 +50,9 @@
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
</array>
<key>UTExportedTypeDeclarations</key>
<array/>
<key>UTImportedTypeDeclarations</key>
<array/>
</dict>
</plist>