Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 03-09-2013, 03:55 PM   #31
silver18
THE NOOB
silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.
 
silver18's Avatar
 
Posts: 698
Karma: 1545625
Join Date: Jan 2012
Location: Italy
Device: Kindle Touch 5.3.2
Yep, that's the correct post!
This is one half of the communication system and it is "fully" documented.
The other part (sending infos from a shell script to a waf) is working but not yet documented.
Something could be done to the first part (from waf to shell) to avoid having a script always running even if the waf is closed, but I don't have time to think about it now!
silver18 is offline   Reply With Quote
Old 03-09-2013, 06:00 PM   #32
jnjitkoff
Member
jnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toys
 
Posts: 11
Karma: 5554
Join Date: Sep 2011
Device: Kindle
No worries. Thanks for figuring this stuff out! Good luck with your thesis.
jnjitkoff is offline   Reply With Quote
Old 03-09-2013, 06:18 PM   #33
eureka
but forgot what it's like
eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.
 
Posts: 728
Karma: 2314258
Join Date: Dec 2011
Location: north (by northwest)
Device: Kindle Touch
Quote:
Originally Posted by jnjitkoff View Post
Apologies, I meant the ability to call out to actual shell scripts to trigger behavior (not worried about reloading). Something like:

"aplay success.wav"

that you could do before waf-shell stuff got locked down in one of the 5.X releases.
Code:
kindle.messaging.sendMessage('com.lab126.system', 'sendEvent', ";sh -c 'aplay success.wav'");
Didn't check it, though.
eureka is offline   Reply With Quote
Old 03-14-2013, 04:38 PM   #34
eureka
but forgot what it's like
eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.
 
Posts: 728
Karma: 2314258
Join Date: Dec 2011
Location: north (by northwest)
Device: Kindle Touch
How to hide only title bar (second command is required only if you are planning to have search bar displayed and want it to move upper a bit, onto title bar place):
Code:
# lipc-set-prop com.lab126.pillow interrogatePillow '{"pillowId": "default_status_bar", "function": "nativeBridge.hideMe();"}'
# lipc-set-prop com.lab126.pillow interrogatePillow '{"pillowId": "search_bar", "function": "nativeBridge.hideMe(); nativeBridge.showMe();"}'
To show title bar back:
Code:
# lipc-set-prop com.lab126.pillow interrogatePillow '{"pillowId": "default_status_bar", "function": "nativeBridge.showMe();"}'

Last edited by eureka; 03-14-2013 at 04:46 PM. Reason: clarification
eureka is offline   Reply With Quote
Old 03-14-2013, 06:38 PM   #35
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,552
Karma: 6021146
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
Ah good man. Helpful
twobob is offline   Reply With Quote
Old 03-15-2013, 03:46 PM   #36
jnjitkoff
Member
jnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toys
 
Posts: 11
Karma: 5554
Join Date: Sep 2011
Device: Kindle
Quote:
Originally Posted by eureka View Post
How to hide only title bar (second command is required only if you are planning to have search bar displayed and want it to move upper a bit, onto title bar place)
Excellent. Thank you. This makes getting in and out of the state even easier.

One followup question: is there a good way to execute a command when a WAF is terminating? (reshowing the titlebar is a nice touch)
jnjitkoff is offline   Reply With Quote
Old 03-15-2013, 04:02 PM   #37
silver18
THE NOOB
silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.
 
silver18's Avatar
 
Posts: 698
Karma: 1545625
Join Date: Jan 2012
Location: Italy
Device: Kindle Touch 5.3.2
Quote:
Originally Posted by jnjitkoff View Post
Excellent. Thank you. This makes getting in and out of the state even easier.

One followup question: is there a good way to execute a command when a WAF is terminating? (reshowing the titlebar is a nice touch)
I'm facing the same problem.
You could use

Code:
kindle.appmgr.onunload = function() { };
or the stock

Code:
window.onunload = function() { };
As regards me, I need something a bit more complicated as I have mutiple HTMLs (and the first solution seem to work only in the landing page) and some other problems here and there.
silver18 is offline   Reply With Quote
Old 03-15-2013, 07:56 PM   #38
jnjitkoff
Member
jnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toysjnjitkoff shares his or her toys
 
Posts: 11
Karma: 5554
Join Date: Sep 2011
Device: Kindle
Quote:
Originally Posted by silver18 View Post
As regards me, I need something a bit more complicated as I have mutiple HTMLs (and the first solution seem to work only in the landing page) and some other problems here and there.
Maybe it is something worth restoring via the launching .sh file. Is it possible to monitor the process that is launched and execute a shell command on termination?
jnjitkoff is offline   Reply With Quote
Old 04-09-2013, 11:25 AM   #39
PaulFreund
*
PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.PaulFreund understands the importance of being earnest.
 
PaulFreund's Avatar
 
Posts: 32
Karma: 145852
Join Date: Apr 2013
Device: Kindle Touch
Quote:
Originally Posted by silver18 View Post
I'm facing the same problem.
You could use

Code:
kindle.appmgr.onunload = function() { };
or the stock

Code:
window.onunload = function() { };
As regards me, I need something a bit more complicated as I have mutiple HTMLs (and the first solution seem to work only in the landing page) and some other problems here and there.
I suggest wrapping the application in a Kindle object as I did in WebLaunch

This allow you to hook into "go", "unload" and "pause". "pause" is executed when the app leaves focus and "go" when it comes to focus. I think "unload" should be called when the app is really terminating, but I didn't capture that event yet.

When creating the base application with the Kindle template you can use kindle.chrome.createContentWindow() to load your other pages and keep the code active.
PaulFreund is offline   Reply With Quote
Old 04-09-2013, 02:45 PM   #40
silver18
THE NOOB
silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.silver18 ought to be getting tired of karma fortunes by now.
 
silver18's Avatar
 
Posts: 698
Karma: 1545625
Join Date: Jan 2012
Location: Italy
Device: Kindle Touch 5.3.2
This is exactly what I'm doing in the next release of Komic.
I just needed to cut unneeded things away before adding something else.
This would also bring back pinch to zoom...
silver18 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Classic Nook on screen hints? Hellmark Barnes & Noble NOOK 4 08-12-2011 09:54 AM
Tips, Tricks, and Hints Nate the great Amazon Kindle 44 03-22-2011 05:15 AM
The Times hints at release of new Kindle Grumpyreader News 0 06-04-2010 01:36 PM
Q7 - v3.0 firmware - Hints and Tricks rogue_ronin Alternative Devices 8 06-30-2009 03:59 PM
Any hints on first software update? Leaping Gnome Sony Reader 32 12-07-2006 11:22 AM


All times are GMT -4. The time now is 08:53 PM.


MobileRead.com is a privately owned, operated and funded community.