Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR DART

flutter only portrait

void main() {
  WidgetsFlutterBinding.ensureInitialized();
  SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp])
    .then((_) {
      runApp(new MyApp());
    });
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #flutter #portrait
ADD COMMENT
Topic
Name
7+2 =