filmil / sl4a-scheme

Automatically exported from code.google.com/p/sl4a-scheme
0 stars 0 forks source link

NullPointerException when editing in SL4A editor with "Auto-close" enabled. #4

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Open a .scm script in the SL4A default editor.
2. Ensure that the SL4A preference for Enable Auto-close is checked.
3. Back in the editor, modify the script contents (even adding a line break).
Note: navigating through the script with the arrow keys works correctly.

What is the expected output? What do you see instead?
A modified version of the script.  Instead, SL4A force closes.

What version of the product are you using? On what operating system?
JScheme 7.2 on Android. 2.3.4

Please provide any additional information below.
At first glance this appears to be an issue with SL4A; however, looking at the 
stack trace in the log files shows that it might be a missing override - the 
getLanguage function seems to return null.  (This is little more than a guess; 
there doesn't appear to be much else on the line in question that would trigger 
this problem, but I could be wrong.)

Please see the attached stacktrace for exact details.

Original issue reported on code.google.com by matthewc...@gmail.com on 24 Mar 2012 at 1:10

Attachments:

GoogleCodeExporter commented 9 years ago
This can actually be closed; after digging around a bit more, it turns out this 
really is an issue within the SL4A Script Editor, and how it works with 
different languages (specifically the auto-close functionality).

Original comment by matthewc...@gmail.com on 25 Mar 2012 at 4:08

GoogleCodeExporter commented 9 years ago
This problem is because there is no "JSchemeLanguage Class" (extends Language 
Class).
To fix this problem the class is required.

http://code.google.com/p/android-scripting/source/browse/android/Common/src/com/
googlecode/android_scripting/language/

Original comment by tomcatalbino on 27 Mar 2012 at 4:01

GoogleCodeExporter commented 9 years ago
Actually, once I'd realized my mistake, I posted it to the SL4A project 
instead; they've fixed the actual issue (I believe by having the ScriptEditor 
work with a default/generic language if it can't find the one necessary for the 
file).

Robbie did say he'd be glad to include a SchemeLanguage class if it were 
provided; I'm not familiar enough with Scheme or with the SL4A language stuff, 
otherwise I'd do it myself.  If you're interested, you can take a look at the 
messages about it:

https://groups.google.com/d/topic/android-scripting/VeGkNhN9xmA/discussion

Thanks!

Original comment by matthewc...@gmail.com on 27 Mar 2012 at 4:17