Froked from https://gitorious.org/tdriver/agent_qt,