Allow maximize state change when minimized
Fix build warnings introduced by 6db90767