Fix Mouse Clicks Not Working in Flash and Ubuntu

January 2, 2010

How To

For about a month, mouse clicks stopped working for me in Flash and Ubuntu, no matter the browser I use. Digging a bit, multiple solutions came up, so I will share them with you.

Solution 1 – this seems the best one but only works for i386:

1. Start a Terminal window and paste this:

cd /usr/lib/nspluginwrapper/i386/linux/
sudo mv npviewer.bin npviewer.bin.real
sudo mv npviewer.bin npviewer.bin.real
sudo gedit npviewer.bin

(one line at a time)

2. Add these two lines of text to the file

#!/bin/sh
GDK_NATIVE_WINDOWS=true /usr/lib/nspluginwrapper/i386/linux/npviewer.bin.real “$@”

3. Press “Ctrl+x” to exit and save.

4. In the same terminal window, paste this:

sudo chmod 755 npviewer.bin

As seen here and here.

If you don’t have /usr/lib/nspluginwrapper/i386/linux/, use the following method instead (This might work for 64bit, but I cannot test it):

Alternatively, for this solution, you could launch applications like so (simply edit the shortcut of any application you want – in which you are experiencing flash click issues with):

GDK_NATIVE_WINDOWS=TRUE firefox

Obviously, replacing firefox with the application you want to run.

Solution 2: remove flashplugin-nonfree / flashplugin-installer and install from Adobe.

For an easy operation robau user @ubuntuforums.org has created a script for that. Simple copy the following code and paste it in an empty file, let’s call it fix_flash.sh:

#!/bin/bash
# Script created by
# Romeo-Adrian Cioaba romeo.cioaba@spotonearth.com
# Jaša Bartelj jasa.bartelj@gmail.com

echo “Stopping any Firefox that might be running.”
sudo killall -9 firefox

echo “Removing any other flash plugin previously installed.”
sudo apt-get remove -y –purge flashplugin-nonfree gnash gnash-common mozilla-plugin-gnash swfdec-mozilla libflashsupport nspluginwrapper
sudo rm -f /usr/lib/mozilla/plugins/*flash*
sudo rm -f ~/.mozilla/plugins/*flash*
sudo rm -f /usr/lib/firefox/plugins/*flash*
sudo rm -f /usr/lib/firefox-addons/plugins/*flash*
sudo rm -rfd /usr/lib/nspluginwrapper

echo “Installing Flash Player 10.”
sudo cd /tmp
sudo wget http://labs.adobe.com/downloads/flashplayer10.html
sudo wget `cat flashplayer10.html | egrep -o “http:.*”|cut -d\” -f1|grep linux-x86_64.so.tar.gz`
ARCHIVE=`ls libflashplayer-*.linux-x86_64.so.tar.gz`
echo “Version is $ARCHIVE.”
sudo tar zxvf $ARCHIVE
sudo cp libflashplayer.so /usr/lib/mozilla/plugins/
echo “Linking the libraries so Firefox and apps built on XULRunner can find it.”
sudo ln -sf /usr/lib/mozilla/plugins/libflashplayer.so /usr/lib/firefox-addons/plugins/
sudo ln -sf /usr/lib/mozilla/plugins/libflashplayer.so /usr/lib/xulrunner-addons/plugins/
# now doing some cleaning up:
sudo rm -rf flashplayer10.html
sudo rm -rf libflashplayer.so
sudo rm -rf $ARCHIVE

Save the file, then use the terminal to navigate to where you saved it and run the following two commands:

sudo chmod 755 fix_flash.sh
sh fix_flash.sh

Solution 3: some users reported that the bug with mouse clicks not working in Flash & Ubuntu was fixed by either disabling Compiz or just by disabling the show desktop plugin in Compiz.

, , ,

7 Responses to “Fix Mouse Clicks Not Working in Flash and Ubuntu”

  1. Reddy Says:

    Best Solution I ever read

  2. Sparazza Says:

    My solution is to edit “npviewer” instead of “npviewer.bin”
    and add before the last line:
    “GDK_NATIVE_WINDOWS=TRUE”

    That worked for two 64 bit computers!

    Cya
    Sparazza

  3. Cody Says:

    who needs compiz anyway?

Trackbacks/Pingbacks

  1. Fix Mouse Clicks Not Working in Flash and Ubuntu | Flash tutorial … Ubuntu Netbook - January 3, 2010

    [...] the original: Fix Mouse Clicks Not Working in Flash and Ubuntu | Flash tutorial … By admin | category: ubuntu compiz | tags: chmod-755, disabling, either-disabling, flash, [...]

  2. Fix Mouse Clicks Not Working in Flash and Ubuntu | Flash tutorial … Mozilla Fennec - January 3, 2010

    [...] post:  Fix Mouse Clicks Not Working in Flash and Ubuntu | Flash tutorial … By admin | category: mozilla, mozilla ubuntu | tags: browser, firefox, libraries, [...]

  3. [Guida] [UPDATE 16-03-10] Flash “non vede” il click del mouse con processore a 64 bit « - March 16, 2010

    [...] Fonte: http://www.flashconf.com/how-to/fix-mouse-clicks-not-working-in-flash-and-ubuntu/ [...]

  4. Problem: Mouse click not working in Flash on Ubuntu | Luca's Space - September 29, 2010

    [...] flashconf.com This entry was posted in Computers and Internet. Bookmark the permalink. ← How to [...]

Leave a Reply