Fix dialog canceled event