For the last few days I’ve been fighting TweetDeck on my laptop trying to get it to open web pages in Opera. A small, but fast browser, from the Norwegian company with the same name.
At first I thought that Opera wasn’t my default browser in Gnome. I’m currently using Linux Mint, a distribution based on Ubuntu. So I checked the “Preferences->Preferred Applications” and made sure Opera was the default application for browsing the web. I also checked with “gconf-editor” just to be safe that Opera was set as default browser.
Having checked all this. I did a few tests and found out that Opera was indeed the default application for surfing the web. So the problem had to be limited to TweetDeck or Adobe AIR.
Now. I checked all the xml-files regarding Adobe AIR and TweetDeck, I even installed SQLite3 to read the database file for TweetDeck in my home directory. No luck.
But the Internet is a collection of tubes amazing and brilliant people. So I searched and found Andrea Olivato, which in turned had found the solution to my (and many others) problem. He discovered that Adobe AIR has hard-coded firefox as default browser in libCore.so, which (usually) can be found in /opt/Adobe AIR/Versions/1.0.
His solution to the problem was to open libCore.so with vim, or any other editor for that matter, and search for the word “firefox”. Ok, he writes that he jumps directly to line 15500, but this might change. But then again, maybe Adobe will make it work in the future. Anyway. He replaced “firefox” with “browser”, which is the same length. Very important. And created a symlink from his favourite browser to, well, browser.
In my case:
ln -s /usr/bin/opera /usr/local/browser
I noticed that in libCore.so, Adobe has a reference to /desktop/gnome/url-handlers/http/command, which is the registry setting for Gnome when it comes to default browser. Why this isn’t used I don’t understand. Perhaps the hard-coded firefox is a backup solution in case AIR fails to retrieve the information from the registry.