7twenty

Some help with MX extension API's

Recommended Posts

Trying to figure out some code to possibly port a chrome extension.

The chrome extension includes this as part of the code:

if (chrome.extension.onMessage !== undefined) {
            chrome.extension.onMessage.addListener(
                function (request) {
                    if (request === 'refreshSettings') {
                        chrome.extension.sendMessage(null, 'getSettings', chromeHandleMessage);
                    }
                }

Not sure how the chrome onMessage / addListener /sendMessage API's mirror those in Maxthon?

I think it would related to mx.app.runtime.listen( type, func ) & mx.app.runtime.post( type [, obj] ) but not sure if that's right, or how to go about making that work as the above code does for Chrome?

Any help would be appreciated.

Share this post


Link to post
Share on other sites

See, this is the problem...

Part of the reason people don't want to use MX is because they can't find some extensions they want. I'm willing to spend some time trying to port over some where possible, but I need a little help to hopefully push me in the right direction. But all we get is silence...

There aren't many (any?) users here that are active in extension creation, the ones that post on the Chinese forum don't post here, the dev's don't post here...

  • Like 2

Share this post


Link to post
Share on other sites

Can't help you with the extensions porting but I have noticed that some of the most useful extensions have been converted/ported over from Java (JS) Scripts; so it may be easier to do that to "extensionize" scripts or possibly find the really useful scripts that work and promote them on the forum.

Share this post


Link to post
Share on other sites
3 hours ago, 7twenty said:

ahem.... just because...

Nobody will help you. Get used to this.

Share this post


Link to post
Share on other sites