Entries in Flash Platform (2)

Sunday
Aug212011

How to prevent Firefox' plugin hang detector from triggering during Flex development

Firefox' plugin hang detector is a feature that aims to reduce browser crashing caused by plugins like Flash or Silverlight hanging for prolonged periods of time. Firefox will cut a plugin process off after a predefined timeout, set to 15 seconds by default. While I loudly applaud this stability feature, it is an annoying one to deal with if you're a Flash developer using a debugger. Setting breakpoints for longer than 15 seconds will trigger the hang detector and break off your debugging session. Very annoying indeed.

Fortunately, there is a way to disable this feature (or set the timout to something more usable).
Here's how.

Step 1: about:config

Open up a new tab and type about:config to bring up the advanced configuration page. Click past the warning ;-).

Step 2: Set timeout to -1 to disable

Use the filter field to search for dom.ipc.plugins.timeoutSecs and set its value to -1 to disable the detector entirely. Of course, you're free to set it to any higher value, just remember that the timeout is expressed in seconds and you're good to go.

Tuesday
Aug092011

How to install Flash Builder 4.5 "Burrito" on Ubuntu Linux 11.04 "Natty Narwhal"

Image courtesy of Flickr user guineves

In recent months, Adobe has formally dropped Linux support for it's Eclipse-based Flash Builder IDE. Eclipse itself is cross-platform, however, so it was undoubtedly an artificial measure. Adobe probably figures the Linux developer community is just too small to support. And hey, they may have a point.

I know a lot of developers have a least one foot in Linux-land, still, so when I found out someone ported Flash Builder 4.5 to Linux, I was fast to try it out. It requires a some tinkering, as is customary with Linux, but it's not too bad. Here's how.

fb4linux

fb4linux - a straight port of the Flash Builder Eclipse plugin - is an open source project that resides on Google Code. The project is has medium activity, and supports Adobe's latest release of Flash Builder, i.e. 4.5 "Burrito", which is actually quite surprising. Being an unofficial port though, some features are disabled or don't function properly, e.g. the network monitor and the profiler. These features don't even work decently on a supported platform, so unless you really rely on these features, it's not a big deal.

Installation

It looks like the installation instructions on the project's website are out of date, but with a some common sense, you should be able to get it rolling.
Note: I'm running Ubuntu 11.04 with Unity.

Install Eclipse from Ubuntu Software Center

Open 'Ubuntu Software Center' and type eclipse in the search box in the top right corner.

Eclipse installs to /usr/lib/eclipse by default. This is an important location, since we'll be pasting files into this directory later on. Note that you can find out install locations easily by using the Synaptic Package Manager. Just search for an app, right-click its entry and select Properties from from the contextual menu. The information you need will be under the Installed Files tab.

Get fb4linux

Download burrito4linux here and unpack it. The unpacked archive contains the following top-level directories:

  • /eclipse
    • /features
    • /plugins

Paste /features and /plugins

The next step is to paste the /features and /plugins directories in place into /var/lib/eclipse, overwriting any existing files. In order to accomplish this, however you'll need to sudo. Open up a terminal and enter (disregard the warnings you may get in the terminal window after Nautilus opens):

sudo nautilus

Navigate to /var/lib/eclipse and paste the aforementioned files/folders from the unarchived directory. Make sure Eclipse isn't running, just to be on the safe side.

That's all folks! You should now have a functional Flash Builder. I haven't gotten around to testing all features, but on first look, things looked just fine and functional. I'll update this post if I find any critial bugs.