Ported from Windows 8 to Ubuntu 12.04