Closed GoogleCodeExporter closed 9 years ago
I was trying to debug this, and realized the logcat -d > filename method only
dumps the last few lines of the logs when using the emulator (not sure about
the phone). Using adb logcat > filename logs as the emulator/script is running,
so you get data for the beginning (which, it turns out, is important, oops).
Might be a nice fact to put on the logcat instructions.
At any rate, the attached logcat (I included events log too), shows that when
the link is clicked and a new page loaded, a new activity is started, and the
Android() variable in the JavaScript on each page cannot be initialized, so the
events cannot be posted at that point. I don't think JS supports making that
kind of variable persistence across pages, so there's no obvious workaround to
me, except by somehow modifying the page without causing new activities to be
started.
This explains why the events do not work, but not quite why the menus
disappear, since the menu is persistent the first time you move from one page
to the next, but not afterwards. Possibly for the same reason the Android()
variable cannot be initialized on the second page?
Any help would be appreciated! Thanks!
Original comment by james.bu...@gmail.com
on 29 Jan 2011 at 5:47
Attachments:
I have modified two files to address my specific problem. The source code is
attached. I leave it up the maintainers to determine whether my approach makes
sense in the greater scheme of the codebase. See discussion post for summary of
changes.
Original comment by james.bu...@gmail.com
on 1 Feb 2011 at 2:02
Attachments:
Changes have been added and are available here:
http://www.mithril.com.au/android/sl4a_r4x.apk
Not tested by me. Feedback appreciated.
NB: This also has the 'installable on sdcard' option set. Which may not work on
devices below 2.2 (Froyo) (Api 8). Feedback on this would also be appreciated.
Original comment by rjmatthews62
on 2 Feb 2011 at 1:18
Original comment by rjmatthews62
on 5 Mar 2011 at 2:10
Original issue reported on code.google.com by
james.bu...@gmail.com
on 19 Jan 2011 at 3:24Attachments: