fixed issue 1224, button states were reversed on Mac OS X