fix java7+mac minimizing issue