Last active
          July 11, 2020 13:39 
        
      - 
      
 - 
        
Save SupremeDeity/78677dc95bf35c9f8736c4795fd4857a to your computer and use it in GitHub Desktop.  
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | var info = { | |
| "C++": {'Level 1': Level1Index(), 'Level 2': Level2Index()}, | |
| }; | |
| class IndexManager extends StatelessWidget { | |
| final String language; | |
| final String level; | |
| IndexManager(this.language, this.level); | |
| Future<bool> _onWillPop(context) { | |
| Navigator.pop(context); | |
| return Future.value(true); | |
| } | |
| @override | |
| Widget build(BuildContext context) { | |
| return WillPopScope( | |
| onWillPop: () => _onWillPop(context), | |
| child: MaterialApp( | |
| home: Scaffold( | |
| body: info[language][level], | |
| ), | |
| )); | |
| } | |
| } | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment