Revision: 2630
http://sourceforge.net/p/swingme/code/2630
Author: yuranet
Date: 2021-12-30 02:15:08 +0000 (Thu, 30 Dec 2021)
Log Message:
-----------
ignore sim error
Modified Paths:
--------------
iOSME/build.gradle
iOSME/src/javax/microedition/midlet/MIDlet.java
iOSME/src/net/yura/ios/CanvasView.java
iOSME/src/net/yura/ios/SwingMEiOSApplication.java
Modified: iOSME/build.gradle
===================================================================
--- iOSME/build.gradle 2021-12-29 01:07:41 UTC (rev 2629)
+++ iOSME/build.gradle 2021-12-30 02:15:08 UTC (rev 2630)
@@ -1,10 +1,18 @@
buildscript {
repositories {
jcenter()
+ maven { url 'https://oss.sonatype.org/content/repositories/snapshots/' }
+ mavenLocal()
}
dependencies {
classpath group: 'org.multi-os-engine', name: 'moe-gradle', version: '1.7.+'
}
+ // this is here to tell gradle to refresh the moe dependency in the event i am trying a snapshot
+ // but this does not seem to work instead if the snapshot is sticky i need to go into Intelij/Android Studio
+ // right-click on the project name in the Gradle Tool Window and select Refresh dependencies from the context menu.
+ //configurations.all {
+ // resolutionStrategy.cacheChangingModulesFor 60, 'seconds'
+ //}
}
apply plugin: 'moe-sdk'
Modified: iOSME/src/javax/microedition/midlet/MIDlet.java
===================================================================
--- iOSME/src/javax/microedition/midlet/MIDlet.java 2021-12-29 01:07:41 UTC (rev 2629)
+++ iOSME/src/javax/microedition/midlet/MIDlet.java 2021-12-30 02:15:08 UTC (rev 2630)
@@ -296,7 +296,7 @@
catch (Throwable e) {
// /Users/noisyfox/Documents/project/moe/moe/natj/natj/src/main/native/natj/ObjCRuntime.mm:1480 WARNING: Binding class refers to class MFMailComposeViewController, but it can not be found. Fallback to indirect super class.
// https://github.com/multi-os-engine/multi-os-engine/issues/153
- // Make sure you have MessageUI.framework added
+ // Make sure you have MessageUI.framework added or switch to MOE 1.9 as this is fixed there
System.err.println("Make sure you have MessageUI.framework added to your xcode project! " + e);
return false;
}
Modified: iOSME/src/net/yura/ios/CanvasView.java
===================================================================
--- iOSME/src/net/yura/ios/CanvasView.java 2021-12-29 01:07:41 UTC (rev 2629)
+++ iOSME/src/net/yura/ios/CanvasView.java 2021-12-30 02:15:08 UTC (rev 2630)
@@ -37,6 +37,10 @@
//setContentMode(UIViewContentMode.Redraw); // does not work here for some reason
//setFocusable(true);
//setFocusableInTouchMode(true);
+
+ //UITextInteraction textInteraction = UITextInteraction.alloc().init();
+ //textInteraction.setTextInput(this);
+ //addInteraction(textInteraction);
}
private Canvas canvas;
@@ -167,9 +171,16 @@
private TextComponent textField;
+ /**
+ * this method is called when we try and set a TextBox as current
+ * @see javax.microedition.lcdui.TextBox#initDisplayable(AppController)
+ */
public void openTextEntry() {
Window window = DesktopPane.getDesktopPane().getSelectedFrame();
textField = (TextComponent)window.getFocusOwner();
+ if (textField == null) {
+ throw new IllegalStateException("no focused textbox in window " + window);
+ }
becomeFirstResponder();
}
Modified: iOSME/src/net/yura/ios/SwingMEiOSApplication.java
===================================================================
--- iOSME/src/net/yura/ios/SwingMEiOSApplication.java 2021-12-29 01:07:41 UTC (rev 2629)
+++ iOSME/src/net/yura/ios/SwingMEiOSApplication.java 2021-12-30 02:15:08 UTC (rev 2630)
@@ -156,6 +156,7 @@
System.out.println("App temp folder " + System.getProperty("java.io.tmpdir"));
// workaround for bug: https://github.com/multi-os-engine/multi-os-engine/issues/82
+ // this can be removed when we switch to MOE 1.9
Locale.setDefault(iOSUtil.toLocale(NSLocale.currentLocale()));
}
@@ -231,6 +232,11 @@
@Override
public void applicationDidFailToRegisterForRemoteNotificationsWithError(UIApplication application, NSError error) {
+ if (error != null && "remote notifications are not supported in the simulator".equals(error.localizedDescription())) {
+ // ignore error
+ return;
+ }
+
System.err.println("applicationDidFailToRegisterForRemoteNotificationsWithError " + error);
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|