Quantcast
Viewing all articles
Browse latest Browse all 4404

K5 Search bar launch functions

Hi All,

By modifying the "/usr/share/webkit-1.0/pillow/javascripts/search_bar.js" file, it is very easy to modify the behavior of the back, home and store buttons.

I was able to make the store button, so it will make TTS with speed 220 on the first tap, and if it is already set, (on the second tap) launch the store:

Code:

var m_systemCallbacks = {
        back: function () {
            nativeBridge.setIntLipcProperty(APP_MANAGER_ID, 'backward', 0);
        },
        home: function() {
            nativeBridge.setLipcProperty(APP_MANAGER_ID, 'start', HOME_ID);
        },
        store: function() {
            if (nativeBridge.getIntLipcProperty('com.lab126.tts', 'TtsISpeed') !
                nativeBridge.setIntLipcProperty('com.lab126.tts', 'TtsISpeed', T
            } else {
                nativeBridge.setLipcProperty(APP_MANAGER_ID, 'start', STORE_ID);
            }

        }
    };

Does anyone know how to chage the search bar so it can add new functionality with user typed parameters?

For example, type TTS speed in number into the search bar, and select TTS and have it go to that speed?

I noticed that catalog (My Items), store (Kindle Store), wikipedia (Wikipedia), and dictionary (Dictionary) are defined.

Thanks,
James

Viewing all articles
Browse latest Browse all 4404

Trending Articles