static func isLandscape() -> Bool { return UIInterfaceOrientationIsLandscape(UIApplication.sharedApplication().statusBarOrientation) } static func isPortrait() -> Bool { return UIInterfaceOrientationIsPortrait(UIApplication.sharedApplication().statusBarOrientation) }