Fixed legend hiding