Fix dialog in landscape mode