| 123456789101112131415161718192021222324252627282930313233343536373839 |
- window["displayMenu"] = function() {
- document.getElementById(R.id.context).classList.add(R.klass.opened);
- };
- window["hideMenu"] = function() {
- document.getElementById(R.id.context).classList.remove(R.klass.opened);
- };
- window["toggleMenu"] = function() {
- toggleMenu();
- };
- window["setChannelFavorite"] = function(chanId, val) {
- var channel = DATA.context.getChannel(chanId);
- if (channel) {
- if (val)
- starChannel(channel);
- else
- unstarChannel(channel);
- } else {
- console.error("Channel " +chanId +" not found");
- }
- };
- window["onSmsPermissionUpdated"] = function(enabled) {
- if ("__native" in window && enabled) {
- var response = JSON.parse(__native.getStatic());
- if (response) {
- DATA.update(response);
- }
- }
- };
- /** @return {boolean} */
- function isNative() {
- return !!("__native" in window);
- }
|