MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when?

Discussion about using Moai SDK - post questions, bugs and issues here.

Moderators: seebs, franciscotufro

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby lancew » Wed Sep 19, 2012 8:06 pm

Any idea when progress will be made on this? I don't see the pull request... and it hasn't been merged in already.
Check out my first game released with Moai: https://play.google.com/store/apps/details?id=com.fazed.bugs. Feedback is very welcome =P
lancew
 
Posts: 80
Joined: Wed Aug 22, 2012 12:23 pm

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby ibisum » Wed Sep 19, 2012 11:59 pm

I will work on submitting the pull request again this week. Stay tuned.
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby lancew » Thu Sep 27, 2012 6:33 am

Any updates on this? If not, when can I expect to have an Android keyboard? If its more than just a couple weeks, I'll just implement my own soft keyboard I think.
Check out my first game released with Moai: https://play.google.com/store/apps/details?id=com.fazed.bugs. Feedback is very welcome =P
lancew
 
Posts: 80
Joined: Wed Aug 22, 2012 12:23 pm

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby ibisum » Thu Sep 27, 2012 7:33 am

I'm working on this locally, but alas my macbook pro has problems and it is slowing down my general productivity ..
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby lancew » Wed Oct 10, 2012 7:28 am

Were you ever able to resolve your macbook problems? Looking forward to having your Android keyboard support merged into the main development.
Check out my first game released with Moai: https://play.google.com/store/apps/details?id=com.fazed.bugs. Feedback is very welcome =P
lancew
 
Posts: 80
Joined: Wed Aug 22, 2012 12:23 pm

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby ibisum » Wed Oct 10, 2012 11:04 am

I'm back in shape hardware-wise, I have my branch of moai-dev on github, http://github.com/seclorum/moai-dev with the Android changes that support MOAIKeyboard.

The modification consists of:

1. The addition of a hidden TetxInput view to the Android host project. This view is off-screen, and captures input events from the hardware/soft keyboard.

2. Callbacks into the MOAI stack which propagate the key events. This is done, the MOAI host gets events in a manner similar to the iOS api, although in both cases I think there is still work being done on how to incorporate this. I chose a short-path.

3. Keep in mind, this is with MOAIGUI as a strategic partner.

4. The only gotcha is the package name is required to set up callbacks and whatnot, and so right now is hard-coded to my old employer (allaboutapps), but that can easily be changed with a grep/sub. See MOAIActivity.java, &etc.

I don't think this is production-ready, but then-again, I did ship it, and thats why I don't work at allaboutapps no more.. ;)
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby lancew » Thu Oct 11, 2012 10:35 am

That seems a bit complicated to me, and I don't want to wait until it is merged into the main development branch, so I just developed my own soft keyboard (hopefully as a temporary solution). I made a post about it here: post6934.html#p6934
Check out my first game released with Moai: https://play.google.com/store/apps/details?id=com.fazed.bugs. Feedback is very welcome =P
lancew
 
Posts: 80
Joined: Wed Aug 22, 2012 12:23 pm

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby ibisum » Thu Oct 11, 2012 11:35 am

It is complicated, but its done. The only think you need to do is realize that I've modified the template sources, so you will have to run make-host to base a new Android project off the host work in my branch. Then, edit the package name accordingly, and you should have first-step keyboard capabilities alongside the iOS equivalent in moaigui ..
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby sgeos » Thu Oct 11, 2012 6:13 pm

If you want to automatically generate the package name, you should be able to do that with JNI.

Although working with JNI is a chore, it is very powerful. You can use JNI to call the Java API from C and custom C from Java. FWIW, JNI is really more of a naming convention than anything else. Also, both the C code and Java code live on top of the VM and communicate with each other via the VM. This bridge incurs a performance penalty.
Any original code posted by me is released via the CC0 Public Domain Dedication. It is in the public domain. Do whatever you want with it.
User avatar
sgeos
 
Posts: 241
Joined: Sat Apr 28, 2012 4:42 am
Location: Married in Japan.

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby satsabadell » Mon Dec 24, 2012 1:23 am

Phew... I was going angry :evil:
I am going to test your MOAIKeyboardAndroid! :D
www.imathings.com
iPhone & iPad apps
satsabadell
 
Posts: 31
Joined: Sun Dec 16, 2012 8:36 am

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby ibisum » Mon Dec 24, 2012 8:37 am

Let me know how it goes .. its been working fine for me, but I want to get it caught up with mainline at some point so I can do a pull request and get it into the next SDK release .. its really necessary. Only thing is to figure out how to get the package name, last I looked through the JNI it wasn't immediately obvious how to get it .. but other than that, with hard-coded values for the package name, MOAIKeyboardAndroid is working fine ..
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby satsabadell » Mon Dec 24, 2012 5:52 pm

Hi ibisum, I am needing your help.

I have created a new host using your full source code (and using at.allaboutapps.test.moakeybard package, because if not it didn't works), and the keyboard works perfect (that's great), but all the texts of the screen has disappeared.
I though that maybe you are doing some tests in your source code and perhaps you did some change to the MOAITextBox, and I copied your host souce code, and the MOAIKeybardAndroid class to the main moai source code. Then I have created the host and tested it, and still there aren't texts and furthermore the keyboard is not appearing (without errors in the console).
I supose that I forgot to copy something from your source code to make appear the keyboard, so:
1. What I need exactly to copy to make your keyboard working in my source code?
2. And the most important, what do you think about the texts problems?

Really thanks a lot!
www.imathings.com
iPhone & iPad apps
satsabadell
 
Posts: 31
Joined: Sun Dec 16, 2012 8:36 am

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby satsabadell » Tue Dec 25, 2012 5:28 pm

I don't understand it, I solved it changing the font dpi to lower than 85 (but it works correctly without the keyboard implementation). :ugeek:
www.imathings.com
iPhone & iPad apps
satsabadell
 
Posts: 31
Joined: Sun Dec 16, 2012 8:36 am

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby satsabadell » Thu Dec 27, 2012 5:33 pm

It seems that the keyboard was working fine, but it is failing. I am creating various textFields and using the MOAIKeyboardAndroid to insert text in, but randomly the app is crashing when I am writing with the keyboard. This is the error log:
Code: Select all
  1. 12-27 18:50:10.809: I/MoaiLog(14968): attempt to call a userdata value

  2. 12-27 18:50:10.809: A/libc(14968): Fatal signal 11 (SIGSEGV) at 0x0000001c (code=1)

  3. 12-27 18:50:10.809: I/MoaiLog(14968): stack traceback:

  4. 12-27 18:50:10.809: I/DHA(404): DHA do Nothing

  5. 12-27 18:50:10.899: I/DHA(404): DHA do Nothing

  6. 12-27 18:50:10.929: I/DHA(404): DHA do Nothing

  7. 12-27 18:50:10.929: I/DHA(404): DHA do Nothing

  8. 12-27 18:50:10.969: I/DHA(404): DHA do Nothing

  9. 12-27 18:50:11.069: I/DHA(404): DHA do Nothing

  10. 12-27 18:50:11.079: I/DHA(404): DHA do Nothing

  11. 12-27 18:50:11.079: I/DHA(404): DHA do Nothing

  12. 12-27 18:50:11.119: D/WifiStateMachine(219): fetchRssiAndLinkSpeedNative RSSI = -55

  13. 12-27 18:50:11.139: I/DHA(404): DHA do Nothing

  14. 12-27 18:50:11.209: I/DEBUG(121): debuggerd: 2012-12-27 18:50:11

  15. 12-27 18:50:11.209: I/DEBUG(121): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***

  16. 12-27 18:50:11.209: I/DEBUG(121): Build fingerprint: 'vodafone_uk/protou/protou:4.0.4/IMM76D/128557.2:user/release-keys'

  17. 12-27 18:50:11.209: I/DEBUG(121): pid: 14968, tid: 14991  >>> at.allaboutapps.test.moaikeyboard <<<

  18. 12-27 18:50:11.209: I/DEBUG(121): debuggerd: checkTellHTCSettings

  19. 12-27 18:50:11.209: I/DEBUG(121): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0000001c

  20. 12-27 18:50:11.209: I/DEBUG(121):  r0 00000000  r1 00000006  r2 00a1ae40  r3 00a1ae40

  21. 12-27 18:50:11.209: I/DEBUG(121):  r4 0050d480  r5 00000006  r6 00000007  r7 005545c0

  22. 12-27 18:50:11.209: I/DEBUG(121):  r8 528377a0  r9 0049b268  10 528376d4  fp 52948c2c

  23. 12-27 18:50:11.209: I/DEBUG(121):  ip 00000001  sp 52948bc0  lr 525f25fc  pc 526014b4  cpsr 20000010

  24. 12-27 18:50:11.219: I/DEBUG(121):  d0  0000001c00000004  d1  000000e400000001

  25. 12-27 18:50:11.219: I/DEBUG(121):  d2  0094590000945900  d3  009f04b800000000

  26. 12-27 18:50:11.219: I/DEBUG(121):  d4  00000000be6c0000  d5  000000003f800000

  27. 12-27 18:50:11.219: I/DEBUG(121):  d6  000000003f800000  d7  0000000000000000

  28. 12-27 18:50:11.219: I/DEBUG(121):  d8  0000000000000000  d9  0000000000000000

  29. 12-27 18:50:11.219: I/DHA(404): DHA do Nothing

  30. 12-27 18:50:11.219: I/DEBUG(121):  d10 0000000000000000  d11 0000000000000000

  31. 12-27 18:50:11.229: I/DEBUG(121):  d12 0000000000000000  d13 0000000000000000

  32. 12-27 18:50:11.229: I/DEBUG(121):  d14 0000000000000000  d15 0000000000000000

  33. 12-27 18:50:11.229: I/DEBUG(121):  d16 3f80000000000000  d17 3f8000003f800000

  34. 12-27 18:50:11.229: I/DEBUG(121):  d18 bf12c00000000000  d19 000000003e600000

  35. 12-27 18:50:11.229: I/DEBUG(121):  d20 000000003f800000  d21 0000000000000000

  36. 12-27 18:50:11.229: I/DEBUG(121):  d22 be6c0000bd820000  d23 3f80000000000000

  37. 12-27 18:50:11.229: I/DEBUG(121):  d24 3e66376972bea4d0  d25 3fc39a09d078c69f

  38. 12-27 18:50:11.229: I/DEBUG(121):  d26 0000000000000000  d27 0000000000000000

  39. 12-27 18:50:11.229: I/DEBUG(121):  d28 0000000000000000  d29 0000000000000000

  40. 12-27 18:50:11.229: I/DEBUG(121):  d30 0000000000000000  d31 0000000000000000

  41. 12-27 18:50:11.229: I/DEBUG(121):  scr 60000012

  42. 12-27 18:50:11.259: I/DHA(404): DHA do Nothing

  43. 12-27 18:50:11.259: I/DHA(404): DHA do Nothing

  44. 12-27 18:50:11.289: I/DHA(404): DHA do Nothing

  45. 12-27 18:50:11.379: I/DHA(404): DHA do Nothing

  46. 12-27 18:50:11.409: I/DHA(404): DHA do Nothing

  47. 12-27 18:50:11.419: I/DHA(404): DHA do Nothing

  48. 12-27 18:50:11.459: I/DHA(404): DHA do Nothing

  49. 12-27 18:50:11.509: I/DEBUG(121):          #00  pc 003714b4  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  50. 12-27 18:50:11.509: I/DEBUG(121):          #01  pc 001edbbc  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so (_ZN13MOAIRenderMgr11RenderTableER12MOAILuaStatei)

  51. 12-27 18:50:11.509: I/DEBUG(121):          #02  pc 001edd0c  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so (_ZN13MOAIRenderMgr6RenderEv)

  52. 12-27 18:50:11.509: I/DEBUG(121):          #03  pc 00020370  /system/lib/libdvm.so (dvmPlatformInvoke)

  53. 12-27 18:50:11.509: I/DEBUG(121):          #04  pc 0005e37c  /system/lib/libdvm.so (_Z16dvmCallJNIMethodPKjP6JValuePK6MethodP6Thread)

  54. 12-27 18:50:11.509: I/DEBUG(121): code around pc:

  55. 12-27 18:50:11.509: I/DEBUG(121): 52601494 ebffe26e e1a00005 e1a01004 e3a02020  n...........  ..

  56. 12-27 18:50:11.509: I/DEBUG(121): 526014a4 e3a03000 e8bd4070 eaffe268 001d13ec  .0..p@..h.......

  57. 12-27 18:50:11.509: I/DEBUG(121): 526014b4 e590201c e2413001 e92d4010 ed2d8b02  . ...0A..@-...-.

  58. 12-27 18:50:11.509: I/DEBUG(121): 526014c4 e1530002 e24dd010 e1a04000 3a000025  ..S...M..@..%..:

  59. 12-27 18:50:11.509: I/DEBUG(121): 526014d4 ee071a90 eeb88be7 eeb58b40 eef1fa10  ........@.......

  60. 12-27 18:50:11.509: I/DEBUG(121): code around lr:

  61. 12-27 18:50:11.509: I/DEBUG(121): 525f25dc e8bd8010 e92d4038 e1a05002 e1a04000  ....8@-..P...@..

  62. 12-27 18:50:11.509: I/DEBUG(121): 525f25ec ebfffccb e1a01005 e5900000 eb003bad  .............;..

  63. 12-27 18:50:11.509: I/DEBUG(121): 525f25fc e5941008 e1c020d0 e590c008 e2810010  ..... ..........

  64. 12-27 18:50:11.509: I/DEBUG(121): 525f260c e1c120f0 e581c008 e5840008 e8bd8038  . ..........8...

  65. 12-27 18:50:11.509: I/DEBUG(121): 525f261c e5903010 e92d4030 e1a04000 e593c044  .0..0@-..@..D...

  66. 12-27 18:50:11.509: I/DEBUG(121): stack:

  67. 12-27 18:50:11.509: I/DEBUG(121):     52948b80  3f800000  

  68. 12-27 18:50:11.509: I/DEBUG(121):     52948b84  00000000  

  69. 12-27 18:50:11.509: I/DEBUG(121):     52948b88  00000000  

  70. 12-27 18:50:11.509: I/DEBUG(121):     52948b8c  00000000  

  71. 12-27 18:50:11.519: I/DEBUG(121):     52948b90  00000000  

  72. 12-27 18:50:11.519: I/DEBUG(121):     52948b94  3f800000  

  73. 12-27 18:50:11.519: I/DEBUG(121):     52948b98  528377a0  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  74. 12-27 18:50:11.519: I/DEBUG(121):     52948b9c  00a46108  [heap]

  75. 12-27 18:50:11.519: I/DEBUG(121):     52948ba0  0049b268  [heap]

  76. 12-27 18:50:11.519: I/DEBUG(121):     52948ba4  5283779c  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  77. 12-27 18:50:11.519: I/DEBUG(121):     52948ba8  528377a0  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  78. 12-27 18:50:11.519: I/DEBUG(121):     52948bac  0049b268  [heap]

  79. 12-27 18:50:11.519: I/DEBUG(121):     52948bb0  528376d4  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  80. 12-27 18:50:11.519: I/DEBUG(121):     52948bb4  524ee9f8  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  81. 12-27 18:50:11.519: I/DEBUG(121):     52948bb8  df0027ad  

  82. 12-27 18:50:11.519: I/DEBUG(121):     52948bbc  00000000  

  83. 12-27 18:50:11.519: I/DEBUG(121): #00 52948bc0  00a1ae50  [heap]

  84. 12-27 18:50:11.519: I/DEBUG(121):     52948bc4  52948bec  

  85. 12-27 18:50:11.519: I/DEBUG(121):     52948bc8  00000006  

  86. 12-27 18:50:11.519: I/DEBUG(121):     52948bcc  5247dbc0  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  87. 12-27 18:50:11.519: I/DEBUG(121): #01 52948bd0  00000000  

  88. 12-27 18:50:11.519: I/DEBUG(121):     52948bd4  005545c0  [heap]

  89. 12-27 18:50:11.519: I/DEBUG(121):     52948bd8  5282cb10  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  90. 12-27 18:50:11.519: I/DEBUG(121):     52948bdc  5283779c  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  91. 12-27 18:50:11.519: I/DEBUG(121):     52948be0  00540bc8  [heap]

  92. 12-27 18:50:11.519: I/DEBUG(121):     52948be4  5247dd10  /data/data/at.allaboutapps.test.moaikeyboard/lib/libmoai.so

  93.  


The error only occurs if the listener is configured:
Code: Select all
  1. MOAIKeyboardAndroid.setListener(MOAIKeyboardAndroid.EVENT_INPUT,

  2.       function(start,length,textVal)

  3.                   -- The app crash with an empty function too

  4.           end)


Please I need help with this.
www.imathings.com
iPhone & iPad apps
satsabadell
 
Posts: 31
Joined: Sun Dec 16, 2012 8:36 am

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby satsabadell » Sat Dec 29, 2012 1:01 am

Ibisum pls, can you tell me if this happens to you too?
www.imathings.com
iPhone & iPad apps
satsabadell
 
Posts: 31
Joined: Sun Dec 16, 2012 8:36 am

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby ibisum » Sat Dec 29, 2012 7:57 am

It does not - I don't have much input for you as to why this is happening. You probably shouldn't be using this package id, however:

12-27 18:50:11.209: I/DEBUG(121): pid: 14968, tid: 14991 >>> at.allaboutapps.test.moaikeyboard <<<


Just change this to your own domain - and don't forget to update the Java sources too.
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby satsabadell » Wed Jan 02, 2013 2:50 pm

More info about the problem:
>The problem is totally random when writing (only happens sometimes).
>The crash occurs in the line:
MOAIKeyboardAndroid.cpp:
state.DebugCall ( 3, 0 );
MOAILuaState.cpp:
status = lua_pcall ( this->mState, nArgs, nResults, errIdx );
>The log shows always "attempt to call a XXX value", where XXX can be any type (number, userdata...).

So I printed the stack to see what contains before do the call:
Code: Select all
  1. 01-02 15:36:18.309: I/MoaiLog(23160): lua_pcall -> *Push parameters*

  2. 01-02 15:36:18.309: I/MoaiLog(23160): Object 1: [table]

  3. 01-02 15:36:18.309: I/MoaiLog(23160): Object 2: [table]

  4. 01-02 15:36:18.319: I/MoaiLog(23160): Object 3: [table]

  5. 01-02 15:36:18.319: I/MoaiLog(23160): Object 4: [table]

  6. 01-02 15:36:18.319: I/MoaiLog(23160): Object 5: [table]

  7. 01-02 15:36:18.319: I/MoaiLog(23160): Object 6: [table]

  8. 01-02 15:36:18.319: I/MoaiLog(23160): Object 7: [function]

  9. 01-02 15:36:18.329: I/MoaiLog(23160): Object 8: [number]

  10. 01-02 15:36:18.329: I/MoaiLog(23160): Object 9: [number]

  11. 01-02 15:36:18.329: I/MoaiLog(23160): Object 10: [string]

  12. 01-02 15:36:18.329: I/MoaiLog(23160): lua_pcall -> *Push function*

  13. 01-02 15:36:18.339: I/MoaiLog(23160): Object 1: [table]

  14. 01-02 15:36:18.339: I/MoaiLog(23160): Object 2: [table]

  15. 01-02 15:36:18.339: I/MoaiLog(23160): Object 3: [table]

  16. 01-02 15:36:18.339: I/MoaiLog(23160): Object 4: [table]

  17. 01-02 15:36:18.339: I/MoaiLog(23160): Object 5: [table]

  18. 01-02 15:36:18.339: I/MoaiLog(23160): Object 6: [table]

  19. 01-02 15:36:18.339: I/MoaiLog(23160): Object 7: [function]

  20. 01-02 15:36:18.339: I/MoaiLog(23160): Object 8: [number]

  21. 01-02 15:36:18.339: I/MoaiLog(23160): Object 9: [number]

  22. 01-02 15:36:18.339: I/MoaiLog(23160): Object 10: [string]

  23. 01-02 15:36:18.339: I/MoaiLog(23160): Object 11: [function]

  24. 01-02 15:36:18.339: I/MoaiLog(23160): errIdx: [7]

  25. 01-02 15:36:18.339: I/MoaiLog(23160): lua_pcall -> *Move function*

  26. 01-02 15:36:18.339: I/MoaiLog(23160): Object 1: [table]

  27. 01-02 15:36:18.339: I/MoaiLog(23160): Object 2: [table]

  28. 01-02 15:36:18.339: I/MoaiLog(23160): Object 3: [table]

  29. 01-02 15:36:18.339: I/MoaiLog(23160): Object 4: [table]

  30. 01-02 15:36:18.339: I/MoaiLog(23160): Object 5: [table]

  31. 01-02 15:36:18.339: I/MoaiLog(23160): Object 6: [table]

  32. 01-02 15:36:18.349: I/MoaiLog(23160): Object 7: [function]

  33. 01-02 15:36:18.349: I/MoaiLog(23160): Object 8: [function]

  34. 01-02 15:36:18.349: I/MoaiLog(23160): Object 9: [number]

  35. 01-02 15:36:18.349: I/MoaiLog(23160): Object 10: [number]

  36. 01-02 15:36:18.349: I/MoaiLog(23160): Object 11: [string]

  37. 01-02 15:36:18.349: I/MoaiLog(23160): Object 12: [table]

  38. 01-02 15:36:18.349: I/MoaiLog(23160): Object 13: [userdata]

  39. 01-02 15:36:18.349: I/MoaiLog(23160): attempt to call a number value


I extracted the objects in the stack in 3 steps:
> The first if after push the 3 parameters, so the last 3 objects (8,9 and 10) are number,number,string.
> The second is after push the function callback, so the last object (11) is the function.
> The third is after move the function before the parameters, so the last 4 objects (8,9,10,11) are function,number,number,string. But at this point there are 2 new objects (?!), in this example a table and a userdata object (objects 12 and 13).
> So when the call is done in the next step, the error occurs, because it counts 3 parameters and it try to do the call with the 4th object, in the example a number, when should be the function.

So, why there are those new objects? when and how are the objects pushed to the stack? the stack is not syncronized?

HELP PLS!!
www.imathings.com
iPhone & iPad apps
satsabadell
 
Posts: 31
Joined: Sun Dec 16, 2012 8:36 am

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby satsabadell » Wed Jan 02, 2013 3:10 pm

Finally!

I added this when callin the event in the MoaiView.java:
Code: Select all
  1. synchronized ( Moai.sAkuLock ) {

  2.         Moai.NotifyKeyEvent();

  3.         MoaiActivity.mKeyIsReady = false;

  4. }


Ibisum I think you should add it too to your code to add it to the next SDK release.
www.imathings.com
iPhone & iPad apps
satsabadell
 
Posts: 31
Joined: Sun Dec 16, 2012 8:36 am

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby adam » Mon Jan 28, 2013 7:18 pm

So, good news, I'm actively working on this now.
User avatar
adam
 
Posts: 259
Joined: Wed Sep 14, 2011 11:50 am

Re: MOAIKeyboardIOS .. but no MOAIKeyboardAndroid. So: when

Postby ibisum » Mon Jan 28, 2013 7:28 pm

That is good news! So I can stop my local work on getting the pull request sorted?
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

PreviousNext

Return to Moai SDK

Who is online

Users browsing this forum: No registered users and 0 guests

cron

x