Ubuntu 14.04, Arduino 1.6.6, Surface Pro 3. IDE not running correctly

I have been having issues with my Arduino IDE on my SP3 running Ubuntu 14.04.02 and 14.04.03 (64bit). I have posted this on the Ubuntu forum but not getting much help there. HERE

The problem I am having is that very often while I'm in the Arduino IDE the cursor starts selecting everything the way one would see if you left clicked and hold while dragging your mouse. If I click on the mouse all it does is restarts where the highlighing beginns. Restarting the Arduino IDE doesn't fix this. So far the only way to stop it is to restart Ubuntu. This ISSUE sometimes happens minutes after starting Ubuntu and Arduino IDE and sometimes a while later. Since I first posted this I have discovered that the Left and Right buttons on the mouse and Track Pad are unresponsive while in the IDE. Clicking on the X to close the IDE or anything else with the 2 buttons doesn't work though the keyboard does work and so does the cursor. Also this 2 button issue only affects the Arduion IDE as I can have terminal or other windows open and they work fine. Lastly this issue was affecting the IDE that you can install through the software manager and after updating is now affecting the 1.6.6 version.

Does anyone have any suggestions on what could be causing this and how to fix it?

Thanks