diff --git a/session_1/solution/Output Screenshots/1. Fibonacci.png b/session_1/solution/Output Screenshots/1. Fibonacci.png new file mode 100644 index 00000000..34f76304 Binary files /dev/null and b/session_1/solution/Output Screenshots/1. Fibonacci.png differ diff --git a/session_1/solution/Output Screenshots/2. Semiprime.png b/session_1/solution/Output Screenshots/2. Semiprime.png new file mode 100644 index 00000000..24b9e74a Binary files /dev/null and b/session_1/solution/Output Screenshots/2. Semiprime.png differ diff --git a/session_1/solution/Output Screenshots/3. Sum of primes.png b/session_1/solution/Output Screenshots/3. Sum of primes.png new file mode 100644 index 00000000..694d1e50 Binary files /dev/null and b/session_1/solution/Output Screenshots/3. Sum of primes.png differ diff --git a/session_1/solution/Output Screenshots/4. CourseModule.png b/session_1/solution/Output Screenshots/4. CourseModule.png new file mode 100644 index 00000000..59523c01 Binary files /dev/null and b/session_1/solution/Output Screenshots/4. CourseModule.png differ diff --git a/session_1/solution/courses.dart b/session_1/solution/courses.dart new file mode 100644 index 00000000..8ab54245 --- /dev/null +++ b/session_1/solution/courses.dart @@ -0,0 +1,69 @@ +// Importing dart:io and our electives classes from electives.dart +import 'dart:io'; +import 'coursesModule/electives.dart'; + +// Main Function +void main(){ + + bool running = true; //Condition for loop to run + + while(running){ + + print("\nEnter type of user 1.Admin 2.Student 3.Exit"); //User input for user type + String choice = stdin.readLineSync()!; + + + if(choice == "2"){ + print("\nEnter Branch and year (eg. cs 2):"); + List details = stdin.readLineSync()!.split(" "); // If student, user can type branch and year + //to get its branch and open electives + + print("Your Branch Electives: ${BranchElectives.getList(details)}"); // Calling static getList functions of branch + print("Open Electives: ${OpenElectives.getList()}"); // and open electives + + } + + + else if(choice == "1"){ + bool adminLoopRunning = true; + while(adminLoopRunning){ // Running an admin loop + + print("\nEnter type of Elective 1.Branch Elective 2.Open Elective 3.Exit"); // Enter choice for elective type + String electiveChoice = stdin.readLineSync()!; + + if(electiveChoice == "1"){ + print("\nEnter Operation Choice 1.View Courses 2.Add Course"); // Enter choice for operation to perform on + String operationChoice = stdin.readLineSync()!; // branch elective + + if(operationChoice == "1") print("Branch Electives: ${BranchElectives.getFullList()}"); // Calling function to print all branch electives + + else if(operationChoice == "2") { + print("\nEnter new Course details (eg. courseName courseCode branch year):"); // To add a new course + String courseDetails = stdin.readLineSync()!; + BranchElectives.addCourse(courseDetails); + } + } + + else if(electiveChoice == "2"){ + print("\nEnter Operation Choice 1.View Courses 2.Add Course"); // Enter choice for operation to perform on + String operationChoice = stdin.readLineSync()!; // open elective + + if(operationChoice == "1") print("Open Electives: ${OpenElectives.getList()}"); // print all open electives + + else if(operationChoice == "2") { + print("\nEnter new Course details (eg. courseName courseCode):"); + String courseDetails = stdin.readLineSync()!; // To add a new course + OpenElectives.addCourse(courseDetails); + } + } + + else if(electiveChoice == "3") adminLoopRunning = false; // end admin loop + else print("\nInvalid Choice\n"); // input error handling + } + } + + else if(choice == "3") running = false; // ending program loop + else print("\nInvalid Choice\n"); // input error handling + } + +} \ No newline at end of file diff --git a/session_1/solution/coursesModule/branchElectives.txt b/session_1/solution/coursesModule/branchElectives.txt new file mode 100644 index 00000000..f86a37e6 --- /dev/null +++ b/session_1/solution/coursesModule/branchElectives.txt @@ -0,0 +1,6 @@ +OOPS,cs200,cs,2 +SigPrsc,ec209,ec,2 +MicroControllers,ec301,ec,3 +C++,cs102,cs,1 +EngMech,me101,me,1 +EngDraw,cv111,cv,1 \ No newline at end of file diff --git a/session_1/solution/coursesModule/electives.dart b/session_1/solution/coursesModule/electives.dart new file mode 100644 index 00000000..3a941318 --- /dev/null +++ b/session_1/solution/coursesModule/electives.dart @@ -0,0 +1,92 @@ +//Importing dart:io for file handling +import 'dart:io'; + +// Defining an abstract class electives to define basic functionalities of an elective class +abstract class Electives{ + abstract String courseName; + abstract String courseCode; + +} + +// Defining our Branch Electives Class +class BranchElectives extends Electives{ + + var courseName, courseCode, branch, year; + + BranchElectives(this.courseName, this.courseCode, this.branch, this.year); // Constructor + + static List getList(List details){ // To get list of branch electives corresponding to given branch and year + + File file = File('./coursesModule/branchElectives.txt'); // Read our Branch electives list from branchElectives.txt + List lines = file.readAsLinesSync(); + + List line = []; + lines.forEach((element) => line.add(element.split(","))); // Converting to list + + List courses = []; + line.forEach((element) { + if(details[0] == element[2] && details[1] == element[3]){ //Conditions to check + courses.add(element[0]); + } + }); + + return courses; + } + + + static List getFullList(){ // To get list of all branch electives + + File file = File('./coursesModule/branchElectives.txt'); // Read our Branch electives list from branchElectives.txt + List lines = file.readAsLinesSync(); + + List line = []; + lines.forEach((element) => line.add(element.split(","))); // Converting to list + + List courses = []; + line.forEach((element)=>courses.add(element[0])); // Formatting for return + + return courses; + } + + static void addCourse(String courseDetails){ // To add a course to branch elective list + + String insert = courseDetails.replaceAll(" ", ","); // Formatting + + File file = File('./coursesModule/branchElectives.txt'); + file.writeAsStringSync("\n$insert",mode: FileMode.append); // Append new course to branchElectives.txt + print('\nCourse added.\n'); + } +} + + + + +class OpenElectives extends Electives{ + + var courseName, courseCode; + + OpenElectives(this.courseName, this.courseCode); // Constructor + + static List getList(){ // To get list of Open electives + + File file = File('./coursesModule/openElectives.txt'); + List lines = file.readAsLinesSync(); // Read our Open electives list from openElectives.txt + + List line = []; + lines.forEach((element) => line.add(element.split(","))); // Converting to list + + List courses = []; + line.forEach((element)=>courses.add(element[0])); + + return courses; + } + + static void addCourse(String courseDetails){ // Add new course to list + + String insert = courseDetails.replaceAll(" ", ","); // Formatting + + File file = File('./coursesModule/openElectives.txt'); + file.writeAsStringSync("\n$insert",mode: FileMode.append); // Append new course to openElectives.txt + print('\nCourse added.\n'); + } +} \ No newline at end of file diff --git a/session_1/solution/coursesModule/openElectives.txt b/session_1/solution/coursesModule/openElectives.txt new file mode 100644 index 00000000..c54e16fe --- /dev/null +++ b/session_1/solution/coursesModule/openElectives.txt @@ -0,0 +1,5 @@ +Python,py101 +CAD,me100 +FuelTechnology,cy203 +AppDev,cs215 +Ruby,rb101 \ No newline at end of file diff --git a/session_1/solution/fibonacci.dart b/session_1/solution/fibonacci.dart new file mode 100644 index 00000000..ad46ec31 --- /dev/null +++ b/session_1/solution/fibonacci.dart @@ -0,0 +1,39 @@ +// Importing dart:io to implement input from user +import 'dart:io'; + +// Recursive Function to print Fibonacci Sequence +void printFib(int n, int a, int b){ + if (n == 0){ + return; + } + int c = a+b; + stdout.write("$c "); + printFib(n-1,b,c); +} + +// Main Function +void main(){ + + print("\n\n\n################################"); + + print("PRINTING FIBONACCI SEQUENCE"); + + print("################################\n\n\n"); + + stdout.write("Enter number of terms of Fibonacci numbers to print: "); + int? n = int.parse(stdin.readLineSync()!); // Taking input from user + + int a = 0; + int b = 1; + + stdout.write("\n Fibonacci series upto $n terms: "); + + if(n < 1) print("\nInvalid Input"); + else if (n == 1) stdout.write("$a "); // Base cases + else if (n == 2) stdout.write("$a $b "); // Base cases + else { + stdout.write("$a $b "); + printFib(n-2,a,b); //Calling the printFib function + } + print("\n\n##################################\n\n\n"); +} \ No newline at end of file diff --git a/session_1/solution/semiPrime.dart b/session_1/solution/semiPrime.dart new file mode 100644 index 00000000..69180e6e --- /dev/null +++ b/session_1/solution/semiPrime.dart @@ -0,0 +1,34 @@ +// Importing packages dart:io for user input and dart:math for the sqrt() function +import 'dart:io'; +import 'dart:math'; + +// Defining an isSemiPrime function to check if passed number is semiprime. +bool isSemiPrime(int n){ + + int countFact = 0, j = 0; + for(int i = 1; i<= sqrt(n); i++){ // Basically this loop counts the no. of factors of n, before sqrt(n). + if(n%i == 0){ // If this count equals 2, we conclude that the number is semiprime. + countFact++; // This is because a semiprime n has 4 factors (1, prime#1, prime#2, and n) + j = i; // out of which 1 and prime#1 are before sqrt(n), Thus count being 2. + } // Exception, this algorithm does not work for cubes of primes. + } + + return countFact == 2 && n != pow(j, 3)? true : false; + +} + +// Main Function +void main(){ + + print("\n\n\n###############################################"); + print("Checking if Input Number is Semiprime"); + print("###############################################\n\n\n"); + + stdout.write("Enter number to check if semiprime: "); + int? n = int.parse(stdin.readLineSync()!); // Taking input from user + + if(isSemiPrime(n)) print("\n$n is semi prime."); + else print("\n$n is not semi prime."); + + print("\n\n#########################################\n\n\n"); +} \ No newline at end of file diff --git a/session_1/solution/sumOfPrime.dart b/session_1/solution/sumOfPrime.dart new file mode 100644 index 00000000..08e51137 --- /dev/null +++ b/session_1/solution/sumOfPrime.dart @@ -0,0 +1,54 @@ +// Importing dart:io to implement input from user +import 'dart:io'; + + +// isPrime function to check if a number is prime +bool isPrime(n){ + + int count = 0; + if(n == 1){ + count = 1; + }else{ + for(int i = 2; i*i <= n; i++){ + if (n % i == 0){ + count++; + } + } + } + return count == 0 ? true : false; +} + + +// Main Function +void main(){ + + print("\n\n\n##########################################################"); + print("Checking if Sum of primes of array is also Prime"); + print("##########################################################\n\n\n"); + + stdout.write("Enter array to check (eg. 1 4 3 55 3): "); + String? n = stdin.readLineSync(); // Taking input from user + + if(n != null){ + var list = n.split(" "); + List arr = []; // Convert user input into array/list data + list.forEach((element) => {arr.add(int.parse(element))}); + + + int sum = 0; + arr.forEach((element) => {sum += isPrime(element) ? element : 0}); //get sum of prime elements of list + + if(isPrime(sum)) print("\nSum of the primes of the array ($sum) is also prime"); // Output if sum of prime elements + else print("\nSum of the primes of the array ($sum) is not prime"); // of array is prime or not + + + + + }else print("Null input not accepted"); + + + + + print("\n\n#############################################################\n\n\n"); + +} \ No newline at end of file diff --git a/session_3/numbers_app/.gitignore b/session_3/numbers_app/.gitignore new file mode 100644 index 00000000..0fa6b675 --- /dev/null +++ b/session_3/numbers_app/.gitignore @@ -0,0 +1,46 @@ +# Miscellaneous +*.class +*.log +*.pyc +*.swp +.DS_Store +.atom/ +.buildlog/ +.history +.svn/ + +# IntelliJ related +*.iml +*.ipr +*.iws +.idea/ + +# The .vscode folder contains launch configuration and tasks you configure in +# VS Code which you may wish to be included in version control, so this line +# is commented out by default. +#.vscode/ + +# Flutter/Dart/Pub related +**/doc/api/ +**/ios/Flutter/.last_build_id +.dart_tool/ +.flutter-plugins +.flutter-plugins-dependencies +.packages +.pub-cache/ +.pub/ +/build/ + +# Web related +lib/generated_plugin_registrant.dart + +# Symbolication related +app.*.symbols + +# Obfuscation related +app.*.map.json + +# Android Studio will place build artifacts here +/android/app/debug +/android/app/profile +/android/app/release diff --git a/session_3/numbers_app/.metadata b/session_3/numbers_app/.metadata new file mode 100644 index 00000000..fd70cabc --- /dev/null +++ b/session_3/numbers_app/.metadata @@ -0,0 +1,10 @@ +# This file tracks properties of this Flutter project. +# Used by Flutter tool to assess capabilities and perform upgrades etc. +# +# This file should be version controlled and should not be manually edited. + +version: + revision: 77d935af4db863f6abd0b9c31c7e6df2a13de57b + channel: stable + +project_type: app diff --git a/session_3/numbers_app/README.md b/session_3/numbers_app/README.md new file mode 100644 index 00000000..5eedd079 --- /dev/null +++ b/session_3/numbers_app/README.md @@ -0,0 +1,20 @@ +# numbers_app + +A new Flutter project. + +## Final Result + +![numbers app](https://user-images.githubusercontent.com/78261857/150091389-cb6da685-15c5-432e-a65b-94e63ff95092.gif) + +## Getting Started + +This project is a starting point for a Flutter application. + +A few resources to get you started if this is your first Flutter project: + +- [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab) +- [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook) + +For help getting started with Flutter, view our +[online documentation](https://flutter.dev/docs), which offers tutorials, +samples, guidance on mobile development, and a full API reference. diff --git a/session_3/numbers_app/analysis_options.yaml b/session_3/numbers_app/analysis_options.yaml new file mode 100644 index 00000000..61b6c4de --- /dev/null +++ b/session_3/numbers_app/analysis_options.yaml @@ -0,0 +1,29 @@ +# This file configures the analyzer, which statically analyzes Dart code to +# check for errors, warnings, and lints. +# +# The issues identified by the analyzer are surfaced in the UI of Dart-enabled +# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be +# invoked from the command line by running `flutter analyze`. + +# The following line activates a set of recommended lints for Flutter apps, +# packages, and plugins designed to encourage good coding practices. +include: package:flutter_lints/flutter.yaml + +linter: + # The lint rules applied to this project can be customized in the + # section below to disable rules from the `package:flutter_lints/flutter.yaml` + # included above or to enable additional rules. A list of all available lints + # and their documentation is published at + # https://dart-lang.github.io/linter/lints/index.html. + # + # Instead of disabling a lint rule for the entire project in the + # section below, it can also be suppressed for a single line of code + # or a specific dart file by using the `// ignore: name_of_lint` and + # `// ignore_for_file: name_of_lint` syntax on the line or in the file + # producing the lint. + rules: + # avoid_print: false # Uncomment to disable the `avoid_print` rule + # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule + +# Additional information about this file can be found at +# https://dart.dev/guides/language/analysis-options diff --git a/session_3/numbers_app/android/.gitignore b/session_3/numbers_app/android/.gitignore new file mode 100644 index 00000000..6f568019 --- /dev/null +++ b/session_3/numbers_app/android/.gitignore @@ -0,0 +1,13 @@ +gradle-wrapper.jar +/.gradle +/captures/ +/gradlew +/gradlew.bat +/local.properties +GeneratedPluginRegistrant.java + +# Remember to never publicly share your keystore. +# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app +key.properties +**/*.keystore +**/*.jks diff --git a/session_3/numbers_app/android/app/build.gradle b/session_3/numbers_app/android/app/build.gradle new file mode 100644 index 00000000..7a1d1a72 --- /dev/null +++ b/session_3/numbers_app/android/app/build.gradle @@ -0,0 +1,68 @@ +def localProperties = new Properties() +def localPropertiesFile = rootProject.file('local.properties') +if (localPropertiesFile.exists()) { + localPropertiesFile.withReader('UTF-8') { reader -> + localProperties.load(reader) + } +} + +def flutterRoot = localProperties.getProperty('flutter.sdk') +if (flutterRoot == null) { + throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") +} + +def flutterVersionCode = localProperties.getProperty('flutter.versionCode') +if (flutterVersionCode == null) { + flutterVersionCode = '1' +} + +def flutterVersionName = localProperties.getProperty('flutter.versionName') +if (flutterVersionName == null) { + flutterVersionName = '1.0' +} + +apply plugin: 'com.android.application' +apply plugin: 'kotlin-android' +apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" + +android { + compileSdkVersion flutter.compileSdkVersion + + compileOptions { + sourceCompatibility JavaVersion.VERSION_1_8 + targetCompatibility JavaVersion.VERSION_1_8 + } + + kotlinOptions { + jvmTarget = '1.8' + } + + sourceSets { + main.java.srcDirs += 'src/main/kotlin' + } + + defaultConfig { + // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). + applicationId "com.example.numbers_app" + minSdkVersion flutter.minSdkVersion + targetSdkVersion flutter.targetSdkVersion + versionCode flutterVersionCode.toInteger() + versionName flutterVersionName + } + + buildTypes { + release { + // TODO: Add your own signing config for the release build. + // Signing with the debug keys for now, so `flutter run --release` works. + signingConfig signingConfigs.debug + } + } +} + +flutter { + source '../..' +} + +dependencies { + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" +} diff --git a/session_3/numbers_app/android/app/src/debug/AndroidManifest.xml b/session_3/numbers_app/android/app/src/debug/AndroidManifest.xml new file mode 100644 index 00000000..e852a1ce --- /dev/null +++ b/session_3/numbers_app/android/app/src/debug/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/session_3/numbers_app/android/app/src/main/AndroidManifest.xml b/session_3/numbers_app/android/app/src/main/AndroidManifest.xml new file mode 100644 index 00000000..70000aed --- /dev/null +++ b/session_3/numbers_app/android/app/src/main/AndroidManifest.xml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + diff --git a/session_3/numbers_app/android/app/src/main/kotlin/com/example/numbers_app/MainActivity.kt b/session_3/numbers_app/android/app/src/main/kotlin/com/example/numbers_app/MainActivity.kt new file mode 100644 index 00000000..50019de5 --- /dev/null +++ b/session_3/numbers_app/android/app/src/main/kotlin/com/example/numbers_app/MainActivity.kt @@ -0,0 +1,6 @@ +package com.example.numbers_app + +import io.flutter.embedding.android.FlutterActivity + +class MainActivity: FlutterActivity() { +} diff --git a/session_3/numbers_app/android/app/src/main/res/drawable-v21/launch_background.xml b/session_3/numbers_app/android/app/src/main/res/drawable-v21/launch_background.xml new file mode 100644 index 00000000..f74085f3 --- /dev/null +++ b/session_3/numbers_app/android/app/src/main/res/drawable-v21/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/session_3/numbers_app/android/app/src/main/res/drawable/launch_background.xml b/session_3/numbers_app/android/app/src/main/res/drawable/launch_background.xml new file mode 100644 index 00000000..304732f8 --- /dev/null +++ b/session_3/numbers_app/android/app/src/main/res/drawable/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/session_3/numbers_app/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml new file mode 100644 index 00000000..90f95809 --- /dev/null +++ b/session_3/numbers_app/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 00000000..2e7b3766 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher1.png b/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher1.png new file mode 100644 index 00000000..db77bb4b Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher1.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_back.png b/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..321643b2 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_back.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_fore.png b/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..ac1354db Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 00000000..49adaa28 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher1.png b/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher1.png new file mode 100644 index 00000000..17987b79 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher1.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_back.png b/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..1d68a8dc Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_back.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_fore.png b/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..d75e1ca6 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 00000000..b1819590 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher1.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher1.png new file mode 100644 index 00000000..09d43914 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher1.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_back.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..4b330e13 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_back.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_fore.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..5f465fe4 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 00000000..9df66cd8 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher1.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher1.png new file mode 100644 index 00000000..d5f1c8d3 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher1.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_back.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..ef9b8fdc Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_back.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_fore.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..32f8ad53 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 00000000..e1aa0fd0 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher1.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher1.png new file mode 100644 index 00000000..4d6372ee Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher1.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_back.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..edcfc036 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_back.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_fore.png b/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..a7b9d675 Binary files /dev/null and b/session_3/numbers_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_3/numbers_app/android/app/src/main/res/values-night/styles.xml b/session_3/numbers_app/android/app/src/main/res/values-night/styles.xml new file mode 100644 index 00000000..3db14bb5 --- /dev/null +++ b/session_3/numbers_app/android/app/src/main/res/values-night/styles.xml @@ -0,0 +1,18 @@ + + + + + + + diff --git a/session_3/numbers_app/android/app/src/main/res/values/styles.xml b/session_3/numbers_app/android/app/src/main/res/values/styles.xml new file mode 100644 index 00000000..d460d1e9 --- /dev/null +++ b/session_3/numbers_app/android/app/src/main/res/values/styles.xml @@ -0,0 +1,18 @@ + + + + + + + diff --git a/session_3/numbers_app/android/app/src/profile/AndroidManifest.xml b/session_3/numbers_app/android/app/src/profile/AndroidManifest.xml new file mode 100644 index 00000000..e852a1ce --- /dev/null +++ b/session_3/numbers_app/android/app/src/profile/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/session_3/numbers_app/android/build.gradle b/session_3/numbers_app/android/build.gradle new file mode 100644 index 00000000..24047dce --- /dev/null +++ b/session_3/numbers_app/android/build.gradle @@ -0,0 +1,31 @@ +buildscript { + ext.kotlin_version = '1.3.50' + repositories { + google() + mavenCentral() + } + + dependencies { + classpath 'com.android.tools.build:gradle:4.1.0' + classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" + } +} + +allprojects { + repositories { + google() + mavenCentral() + } +} + +rootProject.buildDir = '../build' +subprojects { + project.buildDir = "${rootProject.buildDir}/${project.name}" +} +subprojects { + project.evaluationDependsOn(':app') +} + +task clean(type: Delete) { + delete rootProject.buildDir +} diff --git a/session_3/numbers_app/android/gradle.properties b/session_3/numbers_app/android/gradle.properties new file mode 100644 index 00000000..94adc3a3 --- /dev/null +++ b/session_3/numbers_app/android/gradle.properties @@ -0,0 +1,3 @@ +org.gradle.jvmargs=-Xmx1536M +android.useAndroidX=true +android.enableJetifier=true diff --git a/session_3/numbers_app/android/gradle/wrapper/gradle-wrapper.properties b/session_3/numbers_app/android/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 00000000..bc6a58af --- /dev/null +++ b/session_3/numbers_app/android/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,6 @@ +#Fri Jun 23 08:50:38 CEST 2017 +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip diff --git a/session_3/numbers_app/android/settings.gradle b/session_3/numbers_app/android/settings.gradle new file mode 100644 index 00000000..44e62bcf --- /dev/null +++ b/session_3/numbers_app/android/settings.gradle @@ -0,0 +1,11 @@ +include ':app' + +def localPropertiesFile = new File(rootProject.projectDir, "local.properties") +def properties = new Properties() + +assert localPropertiesFile.exists() +localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } + +def flutterSdkPath = properties.getProperty("flutter.sdk") +assert flutterSdkPath != null, "flutter.sdk not set in local.properties" +apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" diff --git a/session_3/numbers_app/assets/icon/icon.png b/session_3/numbers_app/assets/icon/icon.png new file mode 100644 index 00000000..98ba8ae7 Binary files /dev/null and b/session_3/numbers_app/assets/icon/icon.png differ diff --git a/session_3/numbers_app/fonts/Oswald-Bold.ttf b/session_3/numbers_app/fonts/Oswald-Bold.ttf new file mode 100644 index 00000000..6d99a38f Binary files /dev/null and b/session_3/numbers_app/fonts/Oswald-Bold.ttf differ diff --git a/session_3/numbers_app/fonts/Oswald-ExtraLight.ttf b/session_3/numbers_app/fonts/Oswald-ExtraLight.ttf new file mode 100644 index 00000000..83d4d5a6 Binary files /dev/null and b/session_3/numbers_app/fonts/Oswald-ExtraLight.ttf differ diff --git a/session_3/numbers_app/fonts/Oswald-Light.ttf b/session_3/numbers_app/fonts/Oswald-Light.ttf new file mode 100644 index 00000000..dcfaa60e Binary files /dev/null and b/session_3/numbers_app/fonts/Oswald-Light.ttf differ diff --git a/session_3/numbers_app/fonts/Oswald-Medium.ttf b/session_3/numbers_app/fonts/Oswald-Medium.ttf new file mode 100644 index 00000000..f252976a Binary files /dev/null and b/session_3/numbers_app/fonts/Oswald-Medium.ttf differ diff --git a/session_3/numbers_app/fonts/Oswald-Regular.ttf b/session_3/numbers_app/fonts/Oswald-Regular.ttf new file mode 100644 index 00000000..2492c44a Binary files /dev/null and b/session_3/numbers_app/fonts/Oswald-Regular.ttf differ diff --git a/session_3/numbers_app/fonts/Oswald-SemiBold.ttf b/session_3/numbers_app/fonts/Oswald-SemiBold.ttf new file mode 100644 index 00000000..afa64377 Binary files /dev/null and b/session_3/numbers_app/fonts/Oswald-SemiBold.ttf differ diff --git a/session_3/numbers_app/ios/.gitignore b/session_3/numbers_app/ios/.gitignore new file mode 100644 index 00000000..7a7f9873 --- /dev/null +++ b/session_3/numbers_app/ios/.gitignore @@ -0,0 +1,34 @@ +**/dgph +*.mode1v3 +*.mode2v3 +*.moved-aside +*.pbxuser +*.perspectivev3 +**/*sync/ +.sconsign.dblite +.tags* +**/.vagrant/ +**/DerivedData/ +Icon? +**/Pods/ +**/.symlinks/ +profile +xcuserdata +**/.generated/ +Flutter/App.framework +Flutter/Flutter.framework +Flutter/Flutter.podspec +Flutter/Generated.xcconfig +Flutter/ephemeral/ +Flutter/app.flx +Flutter/app.zip +Flutter/flutter_assets/ +Flutter/flutter_export_environment.sh +ServiceDefinitions.json +Runner/GeneratedPluginRegistrant.* + +# Exceptions to above rules. +!default.mode1v3 +!default.mode2v3 +!default.pbxuser +!default.perspectivev3 diff --git a/session_3/numbers_app/ios/Flutter/AppFrameworkInfo.plist b/session_3/numbers_app/ios/Flutter/AppFrameworkInfo.plist new file mode 100644 index 00000000..8d4492f9 --- /dev/null +++ b/session_3/numbers_app/ios/Flutter/AppFrameworkInfo.plist @@ -0,0 +1,26 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + App + CFBundleIdentifier + io.flutter.flutter.app + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + App + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1.0 + MinimumOSVersion + 9.0 + + diff --git a/session_3/numbers_app/ios/Flutter/Debug.xcconfig b/session_3/numbers_app/ios/Flutter/Debug.xcconfig new file mode 100644 index 00000000..592ceee8 --- /dev/null +++ b/session_3/numbers_app/ios/Flutter/Debug.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/session_3/numbers_app/ios/Flutter/Release.xcconfig b/session_3/numbers_app/ios/Flutter/Release.xcconfig new file mode 100644 index 00000000..592ceee8 --- /dev/null +++ b/session_3/numbers_app/ios/Flutter/Release.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/session_3/numbers_app/ios/Runner.xcodeproj/project.pbxproj b/session_3/numbers_app/ios/Runner.xcodeproj/project.pbxproj new file mode 100644 index 00000000..316d5d40 --- /dev/null +++ b/session_3/numbers_app/ios/Runner.xcodeproj/project.pbxproj @@ -0,0 +1,481 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; +/* End PBXBuildFile section */ + +/* Begin PBXCopyFilesBuildPhase section */ + 9705A1C41CF9048500538489 /* Embed Frameworks */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 10; + files = ( + ); + name = "Embed Frameworks"; + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; + 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; + 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 97C146EB1CF9000F007C117D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 9740EEB11CF90186004384FC /* Flutter */ = { + isa = PBXGroup; + children = ( + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, + 9740EEB21CF90195004384FC /* Debug.xcconfig */, + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, + 9740EEB31CF90195004384FC /* Generated.xcconfig */, + ); + name = Flutter; + sourceTree = ""; + }; + 97C146E51CF9000F007C117D = { + isa = PBXGroup; + children = ( + 9740EEB11CF90186004384FC /* Flutter */, + 97C146F01CF9000F007C117D /* Runner */, + 97C146EF1CF9000F007C117D /* Products */, + ); + sourceTree = ""; + }; + 97C146EF1CF9000F007C117D /* Products */ = { + isa = PBXGroup; + children = ( + 97C146EE1CF9000F007C117D /* Runner.app */, + ); + name = Products; + sourceTree = ""; + }; + 97C146F01CF9000F007C117D /* Runner */ = { + isa = PBXGroup; + children = ( + 97C146FA1CF9000F007C117D /* Main.storyboard */, + 97C146FD1CF9000F007C117D /* Assets.xcassets */, + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, + 97C147021CF9000F007C117D /* Info.plist */, + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, + ); + path = Runner; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 97C146ED1CF9000F007C117D /* Runner */ = { + isa = PBXNativeTarget; + buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; + buildPhases = ( + 9740EEB61CF901F6004384FC /* Run Script */, + 97C146EA1CF9000F007C117D /* Sources */, + 97C146EB1CF9000F007C117D /* Frameworks */, + 97C146EC1CF9000F007C117D /* Resources */, + 9705A1C41CF9048500538489 /* Embed Frameworks */, + 3B06AD1E1E4923F5004D2608 /* Thin Binary */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Runner; + productName = Runner; + productReference = 97C146EE1CF9000F007C117D /* Runner.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 97C146E61CF9000F007C117D /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1300; + ORGANIZATIONNAME = ""; + TargetAttributes = { + 97C146ED1CF9000F007C117D = { + CreatedOnToolsVersion = 7.3.1; + LastSwiftMigration = 1100; + }; + }; + }; + buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 97C146E51CF9000F007C117D; + productRefGroup = 97C146EF1CF9000F007C117D /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 97C146ED1CF9000F007C117D /* Runner */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 97C146EC1CF9000F007C117D /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXShellScriptBuildPhase section */ + 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Thin Binary"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; + }; + 9740EEB61CF901F6004384FC /* Run Script */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Run Script"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 97C146EA1CF9000F007C117D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 97C146FA1CF9000F007C117D /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C146FB1CF9000F007C117D /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C147001CF9000F007C117D /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 249021D3217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Profile; + }; + 249021D4217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.numbersApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Profile; + }; + 97C147031CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 97C147041CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 97C147061CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.numbersApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + 97C147071CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.numbersApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147031CF9000F007C117D /* Debug */, + 97C147041CF9000F007C117D /* Release */, + 249021D3217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147061CF9000F007C117D /* Debug */, + 97C147071CF9000F007C117D /* Release */, + 249021D4217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 97C146E61CF9000F007C117D /* Project object */; +} diff --git a/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..919434a6 --- /dev/null +++ b/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 00000000..f9b0d7c5 --- /dev/null +++ b/session_3/numbers_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + PreviewsEnabled + + + diff --git a/session_3/numbers_app/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/session_3/numbers_app/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme new file mode 100644 index 00000000..c87d15a3 --- /dev/null +++ b/session_3/numbers_app/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme @@ -0,0 +1,87 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_3/numbers_app/ios/Runner.xcworkspace/contents.xcworkspacedata b/session_3/numbers_app/ios/Runner.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..1d526a16 --- /dev/null +++ b/session_3/numbers_app/ios/Runner.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/session_3/numbers_app/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/session_3/numbers_app/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/session_3/numbers_app/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/session_3/numbers_app/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/session_3/numbers_app/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 00000000..f9b0d7c5 --- /dev/null +++ b/session_3/numbers_app/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + PreviewsEnabled + + + diff --git a/session_3/numbers_app/ios/Runner/AppDelegate.swift b/session_3/numbers_app/ios/Runner/AppDelegate.swift new file mode 100644 index 00000000..70693e4a --- /dev/null +++ b/session_3/numbers_app/ios/Runner/AppDelegate.swift @@ -0,0 +1,13 @@ +import UIKit +import Flutter + +@UIApplicationMain +@objc class AppDelegate: FlutterAppDelegate { + override func application( + _ application: UIApplication, + didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? + ) -> Bool { + GeneratedPluginRegistrant.register(with: self) + return super.application(application, didFinishLaunchingWithOptions: launchOptions) + } +} diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..d36b1fab --- /dev/null +++ b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,122 @@ +{ + "images" : [ + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@3x.png", + "scale" : "3x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@3x.png", + "scale" : "3x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@3x.png", + "scale" : "3x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@2x.png", + "scale" : "2x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@3x.png", + "scale" : "3x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@1x.png", + "scale" : "1x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@1x.png", + "scale" : "1x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@1x.png", + "scale" : "1x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@2x.png", + "scale" : "2x" + }, + { + "size" : "83.5x83.5", + "idiom" : "ipad", + "filename" : "Icon-App-83.5x83.5@2x.png", + "scale" : "2x" + }, + { + "size" : "1024x1024", + "idiom" : "ios-marketing", + "filename" : "Icon-App-1024x1024@1x.png", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png new file mode 100644 index 00000000..dc9ada47 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png new file mode 100644 index 00000000..28c6bf03 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png new file mode 100644 index 00000000..2ccbfd96 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png new file mode 100644 index 00000000..f091b6b0 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png new file mode 100644 index 00000000..4cde1211 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png new file mode 100644 index 00000000..d0ef06e7 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png new file mode 100644 index 00000000..dcdc2306 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png new file mode 100644 index 00000000..2ccbfd96 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png new file mode 100644 index 00000000..c8f9ed8f Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png new file mode 100644 index 00000000..a6d6b860 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png new file mode 100644 index 00000000..a6d6b860 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png new file mode 100644 index 00000000..75b2d164 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png new file mode 100644 index 00000000..c4df70d3 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png new file mode 100644 index 00000000..6a84f41e Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png new file mode 100644 index 00000000..d0e1f585 Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json new file mode 100644 index 00000000..0bedcf2f --- /dev/null +++ b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "LaunchImage.png", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@2x.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@3x.png", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png differ diff --git a/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md new file mode 100644 index 00000000..89c2725b --- /dev/null +++ b/session_3/numbers_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md @@ -0,0 +1,5 @@ +# Launch Screen Assets + +You can customize the launch screen with your own desired assets by replacing the image files in this directory. + +You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. \ No newline at end of file diff --git a/session_3/numbers_app/ios/Runner/Base.lproj/LaunchScreen.storyboard b/session_3/numbers_app/ios/Runner/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 00000000..f2e259c7 --- /dev/null +++ b/session_3/numbers_app/ios/Runner/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_3/numbers_app/ios/Runner/Base.lproj/Main.storyboard b/session_3/numbers_app/ios/Runner/Base.lproj/Main.storyboard new file mode 100644 index 00000000..f3c28516 --- /dev/null +++ b/session_3/numbers_app/ios/Runner/Base.lproj/Main.storyboard @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_3/numbers_app/ios/Runner/Info.plist b/session_3/numbers_app/ios/Runner/Info.plist new file mode 100644 index 00000000..dcfa759a --- /dev/null +++ b/session_3/numbers_app/ios/Runner/Info.plist @@ -0,0 +1,47 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleDisplayName + Numbers App + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + numbers_app + CFBundlePackageType + APPL + CFBundleShortVersionString + $(FLUTTER_BUILD_NAME) + CFBundleSignature + ???? + CFBundleVersion + $(FLUTTER_BUILD_NUMBER) + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UIViewControllerBasedStatusBarAppearance + + + diff --git a/session_3/numbers_app/ios/Runner/Runner-Bridging-Header.h b/session_3/numbers_app/ios/Runner/Runner-Bridging-Header.h new file mode 100644 index 00000000..308a2a56 --- /dev/null +++ b/session_3/numbers_app/ios/Runner/Runner-Bridging-Header.h @@ -0,0 +1 @@ +#import "GeneratedPluginRegistrant.h" diff --git a/session_3/numbers_app/lib/main.dart b/session_3/numbers_app/lib/main.dart new file mode 100644 index 00000000..96c80c52 --- /dev/null +++ b/session_3/numbers_app/lib/main.dart @@ -0,0 +1,206 @@ +import 'package:flutter/material.dart'; +import 'package:http/http.dart' as http; +import 'package:flutter/services.dart'; +import 'package:numbers_app/theme.dart'; +import 'package:provider/provider.dart'; + + +void main() { + runApp(ChangeNotifierProvider( + child: const MyApp(), + create: (BuildContext context) => ThemeProvider(isDarkMode: true), + ) + ); +} + +class MyApp extends StatelessWidget { + const MyApp({Key? key}) : super(key: key); + + + // This widget is the root of your application. + @override + Widget build(BuildContext context) { + return Consumer( + builder: (context, themeProvider, child) { + return MaterialApp( + debugShowCheckedModeBanner: false, + theme: themeProvider.getTheme, + home: const MyHomePage(), + ); + }, + ); + } +} + + + +class MyHomePage extends StatefulWidget { + const MyHomePage({ Key? key }) : super(key: key); + + @override + _MyHomePageState createState() => _MyHomePageState(); +} + +class _MyHomePageState extends State { + + var _request = false; + var _text = 'Something'; + var _valid = true; + + final _number = TextEditingController(); + + String dropDownValue = "/"; + + void getInfo() async { + + _valid = _number.text.isEmpty ? false : true ; + + + + if(_valid){ + + var url = Uri.parse("http://numbersapi.com/${_number.text}/${dropDownValue == "/"?'':dropDownValue}"); + final response = await http.get(url); + final body = response.body.toString(); + + + setState(() { + _text = body; + _request = true; + + }); + } + else{ + var url = Uri.parse("http://numbersapi.com/random/${dropDownValue == "/"?'':dropDownValue}"); + final response = await http.get(url); + final body = response.body.toString(); + + setState(() { + _text = body; + _request = true; + + }); + } + } + + + + @override + Widget build(BuildContext context) { + + SystemChrome.setSystemUIOverlayStyle(const SystemUiOverlayStyle( + statusBarColor: Colors.transparent, + )); + + return Scaffold( + appBar: AppBar( + leading: Image.asset("assets/icon/icon.png",), + title: const Text("Numbers!!", style: TextStyle(fontSize: 25),), + actions: [ + IconButton( + icon: const Icon(Icons.brightness_6_sharp), + color: Colors.white, + onPressed: (){ + ThemeProvider themeProvider = Provider.of(context,listen: false); + themeProvider.swapTheme(); + }, + ), + ], + backgroundColor: Colors.deepOrange, + ), + body: SingleChildScrollView( + child: Padding( + padding: const EdgeInsets.symmetric(horizontal: 20, vertical: 20), + child: Column( + mainAxisAlignment: MainAxisAlignment.start, + children: [ + + Row( + mainAxisAlignment: MainAxisAlignment.start, + children: [ + const Text("Mode:", style: TextStyle(fontSize: 20),), + + const SizedBox(width: 10,), + + DropdownButton( + value: dropDownValue, + icon: const Icon(Icons.arrow_drop_down), + style: const TextStyle(fontSize: 20, color: Colors.deepOrange), + onChanged: (String? newValue){ + setState(() { + dropDownValue = newValue!; + + }); + }, + items: ["/","trivia","year","math"] + .map>( + (String value) { + return DropdownMenuItem( + value: value, + child: Text(value == "/" ? "all" : value), + ); + } + ).toList(), + ), + ], + ), + + const SizedBox( + height: 70, + ), + + const Text( + "Tell me something about the number :", + style: TextStyle(fontSize: 28), + textAlign: TextAlign.center, + ), + + const SizedBox( + height: 30, + ), + + TextField( + controller: _number, + decoration: InputDecoration( + labelText: "Enter a number", + labelStyle: const TextStyle(fontSize: 25,fontStyle: FontStyle.italic,color: Colors.deepOrange), + border: const OutlineInputBorder(), + focusedBorder: const OutlineInputBorder(borderSide: BorderSide(color: Colors.deepOrange)), + errorText: _valid ? '' : "Showing random number", + errorStyle: const TextStyle(fontSize: 25,fontStyle: FontStyle.italic,), + ), + + style: const TextStyle(fontSize: 25,), + keyboardType: TextInputType.number, + textAlign: TextAlign.center, + ), + + const SizedBox( + height: 60, + ), + + ElevatedButton( + onPressed: getInfo, + style: ElevatedButton.styleFrom(primary: Colors.deepOrange), + child: const Padding( + padding: EdgeInsets.all(8.0), + child: Text("Enter",style: TextStyle(fontSize: 25,),), + ), + ), + + const SizedBox( + height: 60, + ), + + Text( + _request ? _text : '', + style: const TextStyle(fontSize: 27,fontStyle: FontStyle.italic,fontFamily: "Oswald"), + textAlign: TextAlign.center, + ), + ], + ), + ), + ), + ); + } +} \ No newline at end of file diff --git a/session_3/numbers_app/lib/theme.dart b/session_3/numbers_app/lib/theme.dart new file mode 100644 index 00000000..e01fd75a --- /dev/null +++ b/session_3/numbers_app/lib/theme.dart @@ -0,0 +1,25 @@ + + +import 'package:flutter/material.dart'; + +class ThemeProvider extends ChangeNotifier{ + + + + ThemeData light = ThemeData.light(); + ThemeData dark = ThemeData.dark(); + ThemeData _selectedTheme = ThemeData.dark(); + + ThemeProvider({required bool isDarkMode}){ + _selectedTheme = isDarkMode?dark:light; + } + + void swapTheme() { + _selectedTheme = _selectedTheme == dark? light : dark ; + notifyListeners(); + } + + ThemeData get getTheme =>_selectedTheme; + + +} \ No newline at end of file diff --git a/session_3/numbers_app/pubspec.yaml b/session_3/numbers_app/pubspec.yaml new file mode 100644 index 00000000..e7e831f6 --- /dev/null +++ b/session_3/numbers_app/pubspec.yaml @@ -0,0 +1,99 @@ +name: numbers_app +description: A new Flutter project. + +# The following line prevents the package from being accidentally published to +# pub.dev using `flutter pub publish`. This is preferred for private packages. +publish_to: 'none' # Remove this line if you wish to publish to pub.dev + +# The following defines the version and build number for your application. +# A version number is three numbers separated by dots, like 1.2.43 +# followed by an optional build number separated by a +. +# Both the version and the builder number may be overridden in flutter +# build by specifying --build-name and --build-number, respectively. +# In Android, build-name is used as versionName while build-number used as versionCode. +# Read more about Android versioning at https://developer.android.com/studio/publish/versioning +# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. +# Read more about iOS versioning at +# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html +version: 1.0.0+1 + +environment: + sdk: ">=2.15.1 <3.0.0" + +# Dependencies specify other packages that your package needs in order to work. +# To automatically upgrade your package dependencies to the latest versions +# consider running `flutter pub upgrade --major-versions`. Alternatively, +# dependencies can be manually updated by changing the version numbers below to +# the latest version available on pub.dev. To see which dependencies have newer +# versions available, run `flutter pub outdated`. +dependencies: + flutter: + sdk: flutter + + http: ^0.13.4 + provider: ^6.0.2 + + + # The following adds the Cupertino Icons font to your application. + # Use with the CupertinoIcons class for iOS style icons. + cupertino_icons: ^1.0.2 + +dev_dependencies: + flutter_test: + sdk: flutter + + # The "flutter_lints" package below contains a set of recommended lints to + # encourage good coding practices. The lint set provided by the package is + # activated in the `analysis_options.yaml` file located at the root of your + # package. See that file for information about deactivating specific lint + # rules and activating additional ones. + flutter_lints: ^1.0.0 + flutter_launcher_icons: "^0.9.2" + +flutter_icons: + android: true + ios: true + image_path: "assets/icon/icon.png" + +# For information on the generic Dart part of this file, see the +# following page: https://dart.dev/tools/pub/pubspec + +# The following section is specific to Flutter. +flutter: + + # The following line ensures that the Material Icons font is + # included with your application, so that you can use the icons in + # the material Icons class. + uses-material-design: true + + # To add assets to your application, add an assets section, like this: + assets: + - assets/icon.png + # - images/a_dot_ham.jpeg + + # An image asset can refer to one or more resolution-specific "variants", see + # https://flutter.dev/assets-and-images/#resolution-aware. + + # For details regarding adding assets from package dependencies, see + # https://flutter.dev/assets-and-images/#from-packages + + # To add custom fonts to your application, add a fonts section here, + # in this "flutter" section. Each entry in this list should have a + # "family" key with the font family name, and a "fonts" key with a + # list giving the asset and other descriptors for the font. For + # example: + fonts: + - family: Oswald + fonts: + - asset: fonts/Oswald-ExtraLight.ttf + weight: 200 + # - asset: fonts/Schyler-Italic.ttf + # style: italic + # - family: Trajan Pro + # fonts: + # - asset: fonts/TrajanPro.ttf + # - asset: fonts/TrajanPro_Bold.ttf + # weight: 700 + # + # For details regarding fonts from package dependencies, + # see https://flutter.dev/custom-fonts/#from-packages diff --git a/session_3/numbers_app/test/widget_test.dart b/session_3/numbers_app/test/widget_test.dart new file mode 100644 index 00000000..2f5c6976 --- /dev/null +++ b/session_3/numbers_app/test/widget_test.dart @@ -0,0 +1,30 @@ +// This is a basic Flutter widget test. +// +// To perform an interaction with a widget in your test, use the WidgetTester +// utility that Flutter provides. For example, you can send tap and scroll +// gestures. You can also use WidgetTester to find child widgets in the widget +// tree, read text, and verify that the values of widget properties are correct. + +import 'package:flutter/material.dart'; +import 'package:flutter_test/flutter_test.dart'; + +import 'package:numbers_app/main.dart'; + +void main() { + testWidgets('Counter increments smoke test', (WidgetTester tester) async { + // Build our app and trigger a frame. + await tester.pumpWidget(const MyApp()); + + // Verify that our counter starts at 0. + expect(find.text('0'), findsOneWidget); + expect(find.text('1'), findsNothing); + + // Tap the '+' icon and trigger a frame. + await tester.tap(find.byIcon(Icons.add)); + await tester.pump(); + + // Verify that our counter has incremented. + expect(find.text('0'), findsNothing); + expect(find.text('1'), findsOneWidget); + }); +} diff --git a/session_3/numbers_app/web/favicon.png b/session_3/numbers_app/web/favicon.png new file mode 100644 index 00000000..8aaa46ac Binary files /dev/null and b/session_3/numbers_app/web/favicon.png differ diff --git a/session_3/numbers_app/web/icons/Icon-192.png b/session_3/numbers_app/web/icons/Icon-192.png new file mode 100644 index 00000000..b749bfef Binary files /dev/null and b/session_3/numbers_app/web/icons/Icon-192.png differ diff --git a/session_3/numbers_app/web/icons/Icon-512.png b/session_3/numbers_app/web/icons/Icon-512.png new file mode 100644 index 00000000..88cfd48d Binary files /dev/null and b/session_3/numbers_app/web/icons/Icon-512.png differ diff --git a/session_3/numbers_app/web/icons/Icon-maskable-192.png b/session_3/numbers_app/web/icons/Icon-maskable-192.png new file mode 100644 index 00000000..eb9b4d76 Binary files /dev/null and b/session_3/numbers_app/web/icons/Icon-maskable-192.png differ diff --git a/session_3/numbers_app/web/icons/Icon-maskable-512.png b/session_3/numbers_app/web/icons/Icon-maskable-512.png new file mode 100644 index 00000000..d69c5669 Binary files /dev/null and b/session_3/numbers_app/web/icons/Icon-maskable-512.png differ diff --git a/session_3/numbers_app/web/index.html b/session_3/numbers_app/web/index.html new file mode 100644 index 00000000..a582bd42 --- /dev/null +++ b/session_3/numbers_app/web/index.html @@ -0,0 +1,104 @@ + + + + + + + + + + + + + + + + + + + + numbers_app + + + + + + + diff --git a/session_3/numbers_app/web/manifest.json b/session_3/numbers_app/web/manifest.json new file mode 100644 index 00000000..f594be0e --- /dev/null +++ b/session_3/numbers_app/web/manifest.json @@ -0,0 +1,35 @@ +{ + "name": "numbers_app", + "short_name": "numbers_app", + "start_url": ".", + "display": "standalone", + "background_color": "#0175C2", + "theme_color": "#0175C2", + "description": "A new Flutter project.", + "orientation": "portrait-primary", + "prefer_related_applications": false, + "icons": [ + { + "src": "icons/Icon-192.png", + "sizes": "192x192", + "type": "image/png" + }, + { + "src": "icons/Icon-512.png", + "sizes": "512x512", + "type": "image/png" + }, + { + "src": "icons/Icon-maskable-192.png", + "sizes": "192x192", + "type": "image/png", + "purpose": "maskable" + }, + { + "src": "icons/Icon-maskable-512.png", + "sizes": "512x512", + "type": "image/png", + "purpose": "maskable" + } + ] +} diff --git a/session_5/Session_5_Assignment/todo_application/.gitignore b/session_5/Session_5_Assignment/todo_application/.gitignore new file mode 100644 index 00000000..0fa6b675 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/.gitignore @@ -0,0 +1,46 @@ +# Miscellaneous +*.class +*.log +*.pyc +*.swp +.DS_Store +.atom/ +.buildlog/ +.history +.svn/ + +# IntelliJ related +*.iml +*.ipr +*.iws +.idea/ + +# The .vscode folder contains launch configuration and tasks you configure in +# VS Code which you may wish to be included in version control, so this line +# is commented out by default. +#.vscode/ + +# Flutter/Dart/Pub related +**/doc/api/ +**/ios/Flutter/.last_build_id +.dart_tool/ +.flutter-plugins +.flutter-plugins-dependencies +.packages +.pub-cache/ +.pub/ +/build/ + +# Web related +lib/generated_plugin_registrant.dart + +# Symbolication related +app.*.symbols + +# Obfuscation related +app.*.map.json + +# Android Studio will place build artifacts here +/android/app/debug +/android/app/profile +/android/app/release diff --git a/session_5/Session_5_Assignment/todo_application/.metadata b/session_5/Session_5_Assignment/todo_application/.metadata new file mode 100644 index 00000000..fd70cabc --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/.metadata @@ -0,0 +1,10 @@ +# This file tracks properties of this Flutter project. +# Used by Flutter tool to assess capabilities and perform upgrades etc. +# +# This file should be version controlled and should not be manually edited. + +version: + revision: 77d935af4db863f6abd0b9c31c7e6df2a13de57b + channel: stable + +project_type: app diff --git a/session_5/Session_5_Assignment/todo_application/README.md b/session_5/Session_5_Assignment/todo_application/README.md new file mode 100644 index 00000000..4736743b --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/README.md @@ -0,0 +1,20 @@ +# todo_application + +A new Flutter project. + +## App ScreenRecord + +![20220221_1603023579](https://user-images.githubusercontent.com/78261857/154952561-a1a5d97f-8fcf-4a87-aa83-357bb01babb8.gif) + +## Getting Started + +This project is a starting point for a Flutter application. + +A few resources to get you started if this is your first Flutter project: + +- [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab) +- [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook) + +For help getting started with Flutter, view our +[online documentation](https://flutter.dev/docs), which offers tutorials, +samples, guidance on mobile development, and a full API reference. diff --git a/session_5/Session_5_Assignment/todo_application/analysis_options.yaml b/session_5/Session_5_Assignment/todo_application/analysis_options.yaml new file mode 100644 index 00000000..61b6c4de --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/analysis_options.yaml @@ -0,0 +1,29 @@ +# This file configures the analyzer, which statically analyzes Dart code to +# check for errors, warnings, and lints. +# +# The issues identified by the analyzer are surfaced in the UI of Dart-enabled +# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be +# invoked from the command line by running `flutter analyze`. + +# The following line activates a set of recommended lints for Flutter apps, +# packages, and plugins designed to encourage good coding practices. +include: package:flutter_lints/flutter.yaml + +linter: + # The lint rules applied to this project can be customized in the + # section below to disable rules from the `package:flutter_lints/flutter.yaml` + # included above or to enable additional rules. A list of all available lints + # and their documentation is published at + # https://dart-lang.github.io/linter/lints/index.html. + # + # Instead of disabling a lint rule for the entire project in the + # section below, it can also be suppressed for a single line of code + # or a specific dart file by using the `// ignore: name_of_lint` and + # `// ignore_for_file: name_of_lint` syntax on the line or in the file + # producing the lint. + rules: + # avoid_print: false # Uncomment to disable the `avoid_print` rule + # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule + +# Additional information about this file can be found at +# https://dart.dev/guides/language/analysis-options diff --git a/session_5/Session_5_Assignment/todo_application/android/.gitignore b/session_5/Session_5_Assignment/todo_application/android/.gitignore new file mode 100644 index 00000000..6f568019 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/.gitignore @@ -0,0 +1,13 @@ +gradle-wrapper.jar +/.gradle +/captures/ +/gradlew +/gradlew.bat +/local.properties +GeneratedPluginRegistrant.java + +# Remember to never publicly share your keystore. +# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app +key.properties +**/*.keystore +**/*.jks diff --git a/session_5/Session_5_Assignment/todo_application/android/app/build.gradle b/session_5/Session_5_Assignment/todo_application/android/app/build.gradle new file mode 100644 index 00000000..e249cd3e --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/build.gradle @@ -0,0 +1,68 @@ +def localProperties = new Properties() +def localPropertiesFile = rootProject.file('local.properties') +if (localPropertiesFile.exists()) { + localPropertiesFile.withReader('UTF-8') { reader -> + localProperties.load(reader) + } +} + +def flutterRoot = localProperties.getProperty('flutter.sdk') +if (flutterRoot == null) { + throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") +} + +def flutterVersionCode = localProperties.getProperty('flutter.versionCode') +if (flutterVersionCode == null) { + flutterVersionCode = '1' +} + +def flutterVersionName = localProperties.getProperty('flutter.versionName') +if (flutterVersionName == null) { + flutterVersionName = '1.0' +} + +apply plugin: 'com.android.application' +apply plugin: 'kotlin-android' +apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" + +android { + compileSdkVersion flutter.compileSdkVersion + + compileOptions { + sourceCompatibility JavaVersion.VERSION_1_8 + targetCompatibility JavaVersion.VERSION_1_8 + } + + kotlinOptions { + jvmTarget = '1.8' + } + + sourceSets { + main.java.srcDirs += 'src/main/kotlin' + } + + defaultConfig { + // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). + applicationId "com.example.todo_application" + minSdkVersion flutter.minSdkVersion + targetSdkVersion flutter.targetSdkVersion + versionCode flutterVersionCode.toInteger() + versionName flutterVersionName + } + + buildTypes { + release { + // TODO: Add your own signing config for the release build. + // Signing with the debug keys for now, so `flutter run --release` works. + signingConfig signingConfigs.debug + } + } +} + +flutter { + source '../..' +} + +dependencies { + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" +} diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/debug/AndroidManifest.xml b/session_5/Session_5_Assignment/todo_application/android/app/src/debug/AndroidManifest.xml new file mode 100644 index 00000000..001d3658 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/debug/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/AndroidManifest.xml b/session_5/Session_5_Assignment/todo_application/android/app/src/main/AndroidManifest.xml new file mode 100644 index 00000000..ca43ba73 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/main/AndroidManifest.xml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/kotlin/com/example/todo_application/MainActivity.kt b/session_5/Session_5_Assignment/todo_application/android/app/src/main/kotlin/com/example/todo_application/MainActivity.kt new file mode 100644 index 00000000..a9f588e1 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/main/kotlin/com/example/todo_application/MainActivity.kt @@ -0,0 +1,6 @@ +package com.example.todo_application + +import io.flutter.embedding.android.FlutterActivity + +class MainActivity: FlutterActivity() { +} diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/drawable-v21/launch_background.xml b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/drawable-v21/launch_background.xml new file mode 100644 index 00000000..f74085f3 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/drawable-v21/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/drawable/launch_background.xml b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/drawable/launch_background.xml new file mode 100644 index 00000000..304732f8 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/drawable/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml new file mode 100644 index 00000000..90f95809 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 00000000..743c3815 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_back.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..24d73d45 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_back.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_fore.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..2c21ab68 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 00000000..e8a0ff09 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_back.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..23e43cb6 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_back.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_fore.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..bf03a4b9 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 00000000..f1857dd3 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_back.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..751a12ef Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_back.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_fore.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..4ed4a10f Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 00000000..35246945 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_back.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..72b114b5 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_back.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_fore.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..06a3868f Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 00000000..473309b9 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_back.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_back.png new file mode 100644 index 00000000..6e9cf3a5 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_back.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_fore.png b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_fore.png new file mode 100644 index 00000000..7ed64467 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_fore.png differ diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/values-night/styles.xml b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/values-night/styles.xml new file mode 100644 index 00000000..3db14bb5 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/values-night/styles.xml @@ -0,0 +1,18 @@ + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/values/styles.xml b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/values/styles.xml new file mode 100644 index 00000000..d460d1e9 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/main/res/values/styles.xml @@ -0,0 +1,18 @@ + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/android/app/src/profile/AndroidManifest.xml b/session_5/Session_5_Assignment/todo_application/android/app/src/profile/AndroidManifest.xml new file mode 100644 index 00000000..001d3658 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/app/src/profile/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/session_5/Session_5_Assignment/todo_application/android/build.gradle b/session_5/Session_5_Assignment/todo_application/android/build.gradle new file mode 100644 index 00000000..24047dce --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/build.gradle @@ -0,0 +1,31 @@ +buildscript { + ext.kotlin_version = '1.3.50' + repositories { + google() + mavenCentral() + } + + dependencies { + classpath 'com.android.tools.build:gradle:4.1.0' + classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" + } +} + +allprojects { + repositories { + google() + mavenCentral() + } +} + +rootProject.buildDir = '../build' +subprojects { + project.buildDir = "${rootProject.buildDir}/${project.name}" +} +subprojects { + project.evaluationDependsOn(':app') +} + +task clean(type: Delete) { + delete rootProject.buildDir +} diff --git a/session_5/Session_5_Assignment/todo_application/android/gradle.properties b/session_5/Session_5_Assignment/todo_application/android/gradle.properties new file mode 100644 index 00000000..94adc3a3 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/gradle.properties @@ -0,0 +1,3 @@ +org.gradle.jvmargs=-Xmx1536M +android.useAndroidX=true +android.enableJetifier=true diff --git a/session_5/Session_5_Assignment/todo_application/android/gradle/wrapper/gradle-wrapper.properties b/session_5/Session_5_Assignment/todo_application/android/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 00000000..bc6a58af --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,6 @@ +#Fri Jun 23 08:50:38 CEST 2017 +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip diff --git a/session_5/Session_5_Assignment/todo_application/android/settings.gradle b/session_5/Session_5_Assignment/todo_application/android/settings.gradle new file mode 100644 index 00000000..44e62bcf --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/android/settings.gradle @@ -0,0 +1,11 @@ +include ':app' + +def localPropertiesFile = new File(rootProject.projectDir, "local.properties") +def properties = new Properties() + +assert localPropertiesFile.exists() +localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } + +def flutterSdkPath = properties.getProperty("flutter.sdk") +assert flutterSdkPath != null, "flutter.sdk not set in local.properties" +apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" diff --git a/session_5/Session_5_Assignment/todo_application/assets/images/logo.png b/session_5/Session_5_Assignment/todo_application/assets/images/logo.png new file mode 100644 index 00000000..473309b9 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/assets/images/logo.png differ diff --git a/session_5/Session_5_Assignment/todo_application/assets/images/logo2.png b/session_5/Session_5_Assignment/todo_application/assets/images/logo2.png new file mode 100644 index 00000000..7ed64467 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/assets/images/logo2.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/.gitignore b/session_5/Session_5_Assignment/todo_application/ios/.gitignore new file mode 100644 index 00000000..7a7f9873 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/.gitignore @@ -0,0 +1,34 @@ +**/dgph +*.mode1v3 +*.mode2v3 +*.moved-aside +*.pbxuser +*.perspectivev3 +**/*sync/ +.sconsign.dblite +.tags* +**/.vagrant/ +**/DerivedData/ +Icon? +**/Pods/ +**/.symlinks/ +profile +xcuserdata +**/.generated/ +Flutter/App.framework +Flutter/Flutter.framework +Flutter/Flutter.podspec +Flutter/Generated.xcconfig +Flutter/ephemeral/ +Flutter/app.flx +Flutter/app.zip +Flutter/flutter_assets/ +Flutter/flutter_export_environment.sh +ServiceDefinitions.json +Runner/GeneratedPluginRegistrant.* + +# Exceptions to above rules. +!default.mode1v3 +!default.mode2v3 +!default.pbxuser +!default.perspectivev3 diff --git a/session_5/Session_5_Assignment/todo_application/ios/Flutter/AppFrameworkInfo.plist b/session_5/Session_5_Assignment/todo_application/ios/Flutter/AppFrameworkInfo.plist new file mode 100644 index 00000000..8d4492f9 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Flutter/AppFrameworkInfo.plist @@ -0,0 +1,26 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + App + CFBundleIdentifier + io.flutter.flutter.app + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + App + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1.0 + MinimumOSVersion + 9.0 + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Flutter/Debug.xcconfig b/session_5/Session_5_Assignment/todo_application/ios/Flutter/Debug.xcconfig new file mode 100644 index 00000000..592ceee8 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Flutter/Debug.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/session_5/Session_5_Assignment/todo_application/ios/Flutter/Release.xcconfig b/session_5/Session_5_Assignment/todo_application/ios/Flutter/Release.xcconfig new file mode 100644 index 00000000..592ceee8 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Flutter/Release.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.pbxproj b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.pbxproj new file mode 100644 index 00000000..d0d72852 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.pbxproj @@ -0,0 +1,481 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; +/* End PBXBuildFile section */ + +/* Begin PBXCopyFilesBuildPhase section */ + 9705A1C41CF9048500538489 /* Embed Frameworks */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 10; + files = ( + ); + name = "Embed Frameworks"; + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; + 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; + 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 97C146EB1CF9000F007C117D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 9740EEB11CF90186004384FC /* Flutter */ = { + isa = PBXGroup; + children = ( + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, + 9740EEB21CF90195004384FC /* Debug.xcconfig */, + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, + 9740EEB31CF90195004384FC /* Generated.xcconfig */, + ); + name = Flutter; + sourceTree = ""; + }; + 97C146E51CF9000F007C117D = { + isa = PBXGroup; + children = ( + 9740EEB11CF90186004384FC /* Flutter */, + 97C146F01CF9000F007C117D /* Runner */, + 97C146EF1CF9000F007C117D /* Products */, + ); + sourceTree = ""; + }; + 97C146EF1CF9000F007C117D /* Products */ = { + isa = PBXGroup; + children = ( + 97C146EE1CF9000F007C117D /* Runner.app */, + ); + name = Products; + sourceTree = ""; + }; + 97C146F01CF9000F007C117D /* Runner */ = { + isa = PBXGroup; + children = ( + 97C146FA1CF9000F007C117D /* Main.storyboard */, + 97C146FD1CF9000F007C117D /* Assets.xcassets */, + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, + 97C147021CF9000F007C117D /* Info.plist */, + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, + ); + path = Runner; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 97C146ED1CF9000F007C117D /* Runner */ = { + isa = PBXNativeTarget; + buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; + buildPhases = ( + 9740EEB61CF901F6004384FC /* Run Script */, + 97C146EA1CF9000F007C117D /* Sources */, + 97C146EB1CF9000F007C117D /* Frameworks */, + 97C146EC1CF9000F007C117D /* Resources */, + 9705A1C41CF9048500538489 /* Embed Frameworks */, + 3B06AD1E1E4923F5004D2608 /* Thin Binary */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Runner; + productName = Runner; + productReference = 97C146EE1CF9000F007C117D /* Runner.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 97C146E61CF9000F007C117D /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1300; + ORGANIZATIONNAME = ""; + TargetAttributes = { + 97C146ED1CF9000F007C117D = { + CreatedOnToolsVersion = 7.3.1; + LastSwiftMigration = 1100; + }; + }; + }; + buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 97C146E51CF9000F007C117D; + productRefGroup = 97C146EF1CF9000F007C117D /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 97C146ED1CF9000F007C117D /* Runner */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 97C146EC1CF9000F007C117D /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXShellScriptBuildPhase section */ + 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Thin Binary"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; + }; + 9740EEB61CF901F6004384FC /* Run Script */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Run Script"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 97C146EA1CF9000F007C117D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 97C146FA1CF9000F007C117D /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C146FB1CF9000F007C117D /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C147001CF9000F007C117D /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 249021D3217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Profile; + }; + 249021D4217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.todoApplication; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Profile; + }; + 97C147031CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 97C147041CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 97C147061CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.todoApplication; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + 97C147071CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.todoApplication; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147031CF9000F007C117D /* Debug */, + 97C147041CF9000F007C117D /* Release */, + 249021D3217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147061CF9000F007C117D /* Debug */, + 97C147071CF9000F007C117D /* Release */, + 249021D4217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 97C146E61CF9000F007C117D /* Project object */; +} diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..919434a6 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 00000000..f9b0d7c5 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + PreviewsEnabled + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme new file mode 100644 index 00000000..c87d15a3 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme @@ -0,0 +1,87 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/contents.xcworkspacedata b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..1d526a16 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 00000000..f9b0d7c5 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + PreviewsEnabled + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/AppDelegate.swift b/session_5/Session_5_Assignment/todo_application/ios/Runner/AppDelegate.swift new file mode 100644 index 00000000..70693e4a --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner/AppDelegate.swift @@ -0,0 +1,13 @@ +import UIKit +import Flutter + +@UIApplicationMain +@objc class AppDelegate: FlutterAppDelegate { + override func application( + _ application: UIApplication, + didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? + ) -> Bool { + GeneratedPluginRegistrant.register(with: self) + return super.application(application, didFinishLaunchingWithOptions: launchOptions) + } +} diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..d36b1fab --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,122 @@ +{ + "images" : [ + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@3x.png", + "scale" : "3x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@3x.png", + "scale" : "3x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@3x.png", + "scale" : "3x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@2x.png", + "scale" : "2x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@3x.png", + "scale" : "3x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@1x.png", + "scale" : "1x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@1x.png", + "scale" : "1x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@1x.png", + "scale" : "1x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@2x.png", + "scale" : "2x" + }, + { + "size" : "83.5x83.5", + "idiom" : "ipad", + "filename" : "Icon-App-83.5x83.5@2x.png", + "scale" : "2x" + }, + { + "size" : "1024x1024", + "idiom" : "ios-marketing", + "filename" : "Icon-App-1024x1024@1x.png", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png new file mode 100644 index 00000000..dc9ada47 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png new file mode 100644 index 00000000..28c6bf03 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png new file mode 100644 index 00000000..2ccbfd96 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png new file mode 100644 index 00000000..f091b6b0 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png new file mode 100644 index 00000000..4cde1211 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png new file mode 100644 index 00000000..d0ef06e7 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png new file mode 100644 index 00000000..dcdc2306 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png new file mode 100644 index 00000000..2ccbfd96 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png new file mode 100644 index 00000000..c8f9ed8f Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png new file mode 100644 index 00000000..a6d6b860 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png new file mode 100644 index 00000000..a6d6b860 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png new file mode 100644 index 00000000..75b2d164 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png new file mode 100644 index 00000000..c4df70d3 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png new file mode 100644 index 00000000..6a84f41e Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png new file mode 100644 index 00000000..d0e1f585 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json new file mode 100644 index 00000000..0bedcf2f --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "LaunchImage.png", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@2x.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@3x.png", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png differ diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md new file mode 100644 index 00000000..89c2725b --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md @@ -0,0 +1,5 @@ +# Launch Screen Assets + +You can customize the launch screen with your own desired assets by replacing the image files in this directory. + +You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. \ No newline at end of file diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Base.lproj/LaunchScreen.storyboard b/session_5/Session_5_Assignment/todo_application/ios/Runner/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 00000000..f2e259c7 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Base.lproj/Main.storyboard b/session_5/Session_5_Assignment/todo_application/ios/Runner/Base.lproj/Main.storyboard new file mode 100644 index 00000000..f3c28516 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner/Base.lproj/Main.storyboard @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Info.plist b/session_5/Session_5_Assignment/todo_application/ios/Runner/Info.plist new file mode 100644 index 00000000..a98885dc --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner/Info.plist @@ -0,0 +1,47 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleDisplayName + Todo Application + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + todo_application + CFBundlePackageType + APPL + CFBundleShortVersionString + $(FLUTTER_BUILD_NAME) + CFBundleSignature + ???? + CFBundleVersion + $(FLUTTER_BUILD_NUMBER) + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UIViewControllerBasedStatusBarAppearance + + + diff --git a/session_5/Session_5_Assignment/todo_application/ios/Runner/Runner-Bridging-Header.h b/session_5/Session_5_Assignment/todo_application/ios/Runner/Runner-Bridging-Header.h new file mode 100644 index 00000000..308a2a56 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/ios/Runner/Runner-Bridging-Header.h @@ -0,0 +1 @@ +#import "GeneratedPluginRegistrant.h" diff --git a/session_5/Session_5_Assignment/todo_application/lib/add_task.dart b/session_5/Session_5_Assignment/todo_application/lib/add_task.dart new file mode 100644 index 00000000..d5705fec --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/lib/add_task.dart @@ -0,0 +1,253 @@ +import "package:flutter/material.dart"; +import 'package:todo_application/boxes.dart'; +import 'package:todo_application/models/task.dart'; + + +Future addTaskDialog(BuildContext context, GlobalKey formKey) async{ + return await showDialog( + context: context, + builder: (context){ + final TextEditingController title = TextEditingController(); + final TextEditingController description = TextEditingController(); + final TextEditingController deadline = TextEditingController(); + bool? isChecked = false; + DateTime date = DateTime.now(); + return StatefulBuilder( + builder: (context, setState){ + return AlertDialog( + scrollable: true, + title: Column( + children: const [ + Text("Add a Task",textAlign: TextAlign.center,), + Divider(thickness: 5,) + ], + ), + content: Form( + key: formKey, + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + TextFormField( + controller: title, + validator: (value){ + return value!.isNotEmpty ? null:"Title not Specified"; + }, + decoration: const InputDecoration( + labelText: "Title", + hintText: "Enter the title of new task" + ), + ), + const SizedBox(height: 10,), + TextFormField( + controller: description, + decoration: const InputDecoration( + labelText: "Description(Optional)", + hintText: "Enter the description of new task" + ), + ), + const SizedBox(height: 10,), + TextFormField( + controller: deadline, + validator: (value){ + if(value!.isEmpty){ + return "Deadline not specified"; + } + else if(date.day.toString()+"/"+date.month.toString()+"/"+date.year.toString() == DateTime.now().day.toString()+"/"+DateTime.now().month.toString()+"/"+DateTime.now().year.toString()){ + return "Deadline cannot be today"; + } + else{ + return null; + } + }, + decoration: const InputDecoration( + labelText: "Deadline", + hintText: "Enter the deadline of new task" + ), + onTap: () async{ + final DateTime? selected = await showDatePicker( + initialDate: DateTime.now(), + firstDate: DateTime.now(), + lastDate: DateTime(DateTime.now().year + 5), + context: context + ); + + if (selected != null && selected != date) { + setState(() { + date = selected; + deadline.text = date.day.toString()+"/"+date.month.toString()+"/"+date.year.toString(); + }); + } + }, + ), + const SizedBox(height: 10,), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + const Text("Notify me"), + Checkbox( + activeColor: Colors.blue, + value: isChecked, + onChanged: (checked){ + setState((){ + isChecked = checked; + }); + } + ), + ], + ), + ], + ), + ), + actions: [ + TextButton( + onPressed: (){ + if (formKey.currentState!.validate()){ + addTask(title.text, description.text, date, isChecked); + Navigator.of(context).pop(); + } + }, + child: const Text("Add", style: TextStyle(fontSize: 17),)) + ], + ); + } + ); + } + ); +} +Future editTaskDialog(BuildContext context, GlobalKey formKey, Task task) async{ + return await showDialog( + context: context, + builder: (context){ + DateTime date = task.deadline; + final TextEditingController title = TextEditingController(); + title.text = task.title; + final TextEditingController description = TextEditingController(); + description.text = task.description; + final TextEditingController deadline = TextEditingController(); + deadline.text = date.day.toString()+"/"+date.month.toString()+"/"+date.year.toString(); + bool? isChecked = task.notify; + + return StatefulBuilder( + builder: (context, setState){ + return AlertDialog( + scrollable: true, + title: Column( + children: const [ + Text("Add a Task",textAlign: TextAlign.center,), + Divider(thickness: 5,) + ], + ), + content: Form( + key: formKey, + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + TextFormField( + + controller: title, + validator: (value){ + return value!.isNotEmpty ? null:"Title not Specified"; + }, + decoration: const InputDecoration( + labelText: "Title", + hintText: "Enter the title of new task" + ), + ), + const SizedBox(height: 10,), + TextFormField( + + controller: description, + decoration: const InputDecoration( + labelText: "Description(Optional)", + hintText: "Enter the description of new task" + ), + ), + const SizedBox(height: 10,), + TextFormField( + + controller: deadline, + validator: (value){ + if(value!.isEmpty){ + return "Deadline not specified"; + } + else if(date.day.toString()+"/"+date.month.toString()+"/"+date.year.toString() == DateTime.now().day.toString()+"/"+DateTime.now().month.toString()+"/"+DateTime.now().year.toString()){ + return "Deadline cannot be today"; + } + else{ + return null; + } + }, + decoration: const InputDecoration( + labelText: "Deadline", + hintText: "Enter the deadline of new task" + ), + onTap: () async{ + final DateTime? selected = await showDatePicker( + initialDate: DateTime.now(), + firstDate: DateTime.now(), + lastDate: DateTime(DateTime.now().year + 5), + context: context + ); + + if (selected != null && selected != date) { + setState(() { + date = selected; + deadline.text = date.day.toString()+"/"+date.month.toString()+"/"+date.year.toString(); + }); + } + }, + ), + const SizedBox(height: 10,), + Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + const Text("Notify me"), + Checkbox( + activeColor: Colors.blue, + value: isChecked, + onChanged: (checked){ + setState((){ + isChecked = checked; + }); + } + ), + ], + ), + ], + ), + ), + actions: [ + TextButton( + onPressed: (){ + if (formKey.currentState!.validate()){ + task.title = title.text; + task.description = description.text; + task.deadline = date; + task.notify = isChecked; + task.save(); + Navigator.of(context).pop(); + } + }, + child: const Text("Edit", style: TextStyle(fontSize: 17),)) + ], + ); + } + ); + } + ); +} + +Future addTask(String title,String description, DateTime deadline, bool? notify) async{ + final task = Task() + ..title = title + ..description = description + ..deadline = deadline + ..notify = notify; + + final box = Boxes.getTask(); + box.add(task); +} + +void deleteTask(Task task){ + task.delete(); +} \ No newline at end of file diff --git a/session_5/Session_5_Assignment/todo_application/lib/boxes.dart b/session_5/Session_5_Assignment/todo_application/lib/boxes.dart new file mode 100644 index 00000000..828f6566 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/lib/boxes.dart @@ -0,0 +1,7 @@ +import 'package:hive/hive.dart'; +import 'package:todo_application/models/task.dart'; + +class Boxes { + static Box getTask() => + Hive.box('tasks'); +} \ No newline at end of file diff --git a/session_5/Session_5_Assignment/todo_application/lib/main.dart b/session_5/Session_5_Assignment/todo_application/lib/main.dart new file mode 100644 index 00000000..f9e38311 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/lib/main.dart @@ -0,0 +1,139 @@ +import 'package:flutter/material.dart'; +import 'package:todo_application/add_task.dart'; +import 'package:hive/hive.dart'; +import 'package:hive_flutter/hive_flutter.dart'; +import 'package:path_provider/path_provider.dart'; +import 'package:todo_application/boxes.dart'; +import 'dart:io'; + +import 'package:todo_application/models/task.dart'; + +void main() async{ + WidgetsFlutterBinding.ensureInitialized(); + + await Hive.initFlutter(); + Hive.registerAdapter(TaskAdapter()); + await Hive.openBox('tasks'); + runApp(const MyApp()); +} + +class MyApp extends StatelessWidget { + const MyApp({ Key? key }) : super(key: key); + + @override + Widget build(BuildContext context) { + return MaterialApp( + home: const Home(), + debugShowCheckedModeBanner: false, + theme: ThemeData.dark(), + ); + } +} + +class Home extends StatefulWidget { + const Home({ Key? key }) : super(key: key); + + @override + _HomeState createState() => _HomeState(); +} + +class _HomeState extends State { + + @override + void dispose(){ + Hive.close(); + super.dispose(); + } + + final GlobalKey _formKey = GlobalKey(); + final GlobalKey _editKey = GlobalKey(); + + // List test = [{"Title":"Title 1","Subtitle":"This is Title 1",},{"Title":"Title 2","Subtitle":"This is Title 2",}]; + + dynamic date = DateTime.now(); + + + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + leading: Padding( + padding: const EdgeInsets.all(3.0), + child: Image.asset('assets/images/logo.png'), + ), + title: const Text( + 'DO NOT FORGET !!!', + style: TextStyle(color: Colors.red, fontWeight: FontWeight.bold), + ), + centerTitle: true, + ), + floatingActionButton: FloatingActionButton( + onPressed: ()async{ + await addTaskDialog(context,_formKey); + }, + child: const Icon(Icons.add), + backgroundColor: Colors.redAccent, + ), + body: Padding( + padding: const EdgeInsets.all(8.0), + child: ValueListenableBuilder>( + valueListenable: Boxes.getTask().listenable(), + builder: (context, box, _){ + final tasks = box.values.toList().cast(); + + return ListView.builder( + itemCount: tasks.length, + itemBuilder: (context, index) { + return Card( + child: Column( + children: [ + ListTile( + title: Text(tasks[index].title), + subtitle: Text(tasks[index].description), + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceAround, + children: [ + + Text("Days Left: "+tasks[index].deadline.difference(DateTime.now()).inDays.toString()+" days",), + ], + ), + Row( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + TextButton( + onPressed: ()async{ + await editTaskDialog(context, _editKey, tasks[index]); + }, + child: Row(children: const[Icon(Icons.edit), Text("Edit", style: TextStyle(fontSize: 17),)],), + ), + TextButton( + onPressed: () => deleteTask(tasks[index]), + child: Row(children: const[Icon(Icons.delete), Text("Delete", style: TextStyle(fontSize: 17),)],), + ), + ], + ), + ], + ), + ); + }, + ); + }, + ), + + // child: ListView.builder( + // itemCount: test.length, + // itemBuilder: (context, index) { + // return Card( + // child: ListTile( + // title: Text(test[index]['Title']), + // subtitle: Text(test[index]['Subtitle']), + // ), + // ); + // }, + // ), + ), + ); + } +} \ No newline at end of file diff --git a/session_5/Session_5_Assignment/todo_application/lib/models/task.dart b/session_5/Session_5_Assignment/todo_application/lib/models/task.dart new file mode 100644 index 00000000..73a9801b --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/lib/models/task.dart @@ -0,0 +1,22 @@ +import 'package:hive/hive.dart'; + +part 'task.g.dart'; + + +@HiveType(typeId:0) +class Task extends HiveObject{ + + @HiveField(0) + late String title; + + @HiveField(1) + late String description; + + @HiveField(2) + late DateTime deadline; + + @HiveField(3) + late bool? notify; + + +} \ No newline at end of file diff --git a/session_5/Session_5_Assignment/todo_application/lib/models/task.g.dart b/session_5/Session_5_Assignment/todo_application/lib/models/task.g.dart new file mode 100644 index 00000000..92dcd9de --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/lib/models/task.g.dart @@ -0,0 +1,49 @@ +// GENERATED CODE - DO NOT MODIFY BY HAND + +part of 'task.dart'; + +// ************************************************************************** +// TypeAdapterGenerator +// ************************************************************************** + +class TaskAdapter extends TypeAdapter { + @override + final int typeId = 0; + + @override + Task read(BinaryReader reader) { + final numOfFields = reader.readByte(); + final fields = { + for (int i = 0; i < numOfFields; i++) reader.readByte(): reader.read(), + }; + return Task() + ..title = fields[0] as String + ..description = fields[1] as String + ..deadline = fields[2] as DateTime + ..notify = fields[3] as bool; + } + + @override + void write(BinaryWriter writer, Task obj) { + writer + ..writeByte(4) + ..writeByte(0) + ..write(obj.title) + ..writeByte(1) + ..write(obj.description) + ..writeByte(2) + ..write(obj.deadline) + ..writeByte(3) + ..write(obj.notify); + } + + @override + int get hashCode => typeId.hashCode; + + @override + bool operator ==(Object other) => + identical(this, other) || + other is TaskAdapter && + runtimeType == other.runtimeType && + typeId == other.typeId; +} diff --git a/session_5/Session_5_Assignment/todo_application/pubspec.yaml b/session_5/Session_5_Assignment/todo_application/pubspec.yaml new file mode 100644 index 00000000..6048f76e --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/pubspec.yaml @@ -0,0 +1,95 @@ +name: todo_application +description: A new Flutter project. + +# The following line prevents the package from being accidentally published to +# pub.dev using `flutter pub publish`. This is preferred for private packages. +publish_to: 'none' # Remove this line if you wish to publish to pub.dev + +# The following defines the version and build number for your application. +# A version number is three numbers separated by dots, like 1.2.43 +# followed by an optional build number separated by a +. +# Both the version and the builder number may be overridden in flutter +# build by specifying --build-name and --build-number, respectively. +# In Android, build-name is used as versionName while build-number used as versionCode. +# Read more about Android versioning at https://developer.android.com/studio/publish/versioning +# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. +# Read more about iOS versioning at +# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html +version: 1.0.0+1 + +environment: + sdk: ">=2.15.1 <3.0.0" + +# Dependencies specify other packages that your package needs in order to work. +# To automatically upgrade your package dependencies to the latest versions +# consider running `flutter pub upgrade --major-versions`. Alternatively, +# dependencies can be manually updated by changing the version numbers below to +# the latest version available on pub.dev. To see which dependencies have newer +# versions available, run `flutter pub outdated`. +dependencies: + hive: ^2.0.5 + hive_flutter: ^1.1.0 + path_provider: ^2.0.8 + + flutter: + sdk: flutter + + + # The following adds the Cupertino Icons font to your application. + # Use with the CupertinoIcons class for iOS style icons. + cupertino_icons: ^1.0.2 + +dev_dependencies: + build_runner: ^2.1.7 + hive_generator: ^1.1.2 + flutter_test: + sdk: flutter + + # The "flutter_lints" package below contains a set of recommended lints to + # encourage good coding practices. The lint set provided by the package is + # activated in the `analysis_options.yaml` file located at the root of your + # package. See that file for information about deactivating specific lint + # rules and activating additional ones. + flutter_lints: ^1.0.0 + +# For information on the generic Dart part of this file, see the +# following page: https://dart.dev/tools/pub/pubspec + +# The following section is specific to Flutter. +flutter: + + # The following line ensures that the Material Icons font is + # included with your application, so that you can use the icons in + # the material Icons class. + uses-material-design: true + + # To add assets to your application, add an assets section, like this: + assets: + - assets/logo.png + # - images/a_dot_ham.jpeg + + # An image asset can refer to one or more resolution-specific "variants", see + # https://flutter.dev/assets-and-images/#resolution-aware. + + # For details regarding adding assets from package dependencies, see + # https://flutter.dev/assets-and-images/#from-packages + + # To add custom fonts to your application, add a fonts section here, + # in this "flutter" section. Each entry in this list should have a + # "family" key with the font family name, and a "fonts" key with a + # list giving the asset and other descriptors for the font. For + # example: + # fonts: + # - family: Schyler + # fonts: + # - asset: fonts/Schyler-Regular.ttf + # - asset: fonts/Schyler-Italic.ttf + # style: italic + # - family: Trajan Pro + # fonts: + # - asset: fonts/TrajanPro.ttf + # - asset: fonts/TrajanPro_Bold.ttf + # weight: 700 + # + # For details regarding fonts from package dependencies, + # see https://flutter.dev/custom-fonts/#from-packages diff --git a/session_5/Session_5_Assignment/todo_application/test/widget_test.dart b/session_5/Session_5_Assignment/todo_application/test/widget_test.dart new file mode 100644 index 00000000..cf294e08 --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/test/widget_test.dart @@ -0,0 +1,30 @@ +// This is a basic Flutter widget test. +// +// To perform an interaction with a widget in your test, use the WidgetTester +// utility that Flutter provides. For example, you can send tap and scroll +// gestures. You can also use WidgetTester to find child widgets in the widget +// tree, read text, and verify that the values of widget properties are correct. + +import 'package:flutter/material.dart'; +import 'package:flutter_test/flutter_test.dart'; + +import 'package:todo_application/main.dart'; + +void main() { + testWidgets('Counter increments smoke test', (WidgetTester tester) async { + // Build our app and trigger a frame. + await tester.pumpWidget(const MyApp()); + + // Verify that our counter starts at 0. + expect(find.text('0'), findsOneWidget); + expect(find.text('1'), findsNothing); + + // Tap the '+' icon and trigger a frame. + await tester.tap(find.byIcon(Icons.add)); + await tester.pump(); + + // Verify that our counter has incremented. + expect(find.text('0'), findsNothing); + expect(find.text('1'), findsOneWidget); + }); +} diff --git a/session_5/Session_5_Assignment/todo_application/web/favicon.png b/session_5/Session_5_Assignment/todo_application/web/favicon.png new file mode 100644 index 00000000..8aaa46ac Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/web/favicon.png differ diff --git a/session_5/Session_5_Assignment/todo_application/web/icons/Icon-192.png b/session_5/Session_5_Assignment/todo_application/web/icons/Icon-192.png new file mode 100644 index 00000000..b749bfef Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/web/icons/Icon-192.png differ diff --git a/session_5/Session_5_Assignment/todo_application/web/icons/Icon-512.png b/session_5/Session_5_Assignment/todo_application/web/icons/Icon-512.png new file mode 100644 index 00000000..88cfd48d Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/web/icons/Icon-512.png differ diff --git a/session_5/Session_5_Assignment/todo_application/web/icons/Icon-maskable-192.png b/session_5/Session_5_Assignment/todo_application/web/icons/Icon-maskable-192.png new file mode 100644 index 00000000..eb9b4d76 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/web/icons/Icon-maskable-192.png differ diff --git a/session_5/Session_5_Assignment/todo_application/web/icons/Icon-maskable-512.png b/session_5/Session_5_Assignment/todo_application/web/icons/Icon-maskable-512.png new file mode 100644 index 00000000..d69c5669 Binary files /dev/null and b/session_5/Session_5_Assignment/todo_application/web/icons/Icon-maskable-512.png differ diff --git a/session_5/Session_5_Assignment/todo_application/web/index.html b/session_5/Session_5_Assignment/todo_application/web/index.html new file mode 100644 index 00000000..1cb93fde --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/web/index.html @@ -0,0 +1,104 @@ + + + + + + + + + + + + + + + + + + + + todo_application + + + + + + + diff --git a/session_5/Session_5_Assignment/todo_application/web/manifest.json b/session_5/Session_5_Assignment/todo_application/web/manifest.json new file mode 100644 index 00000000..81c121ab --- /dev/null +++ b/session_5/Session_5_Assignment/todo_application/web/manifest.json @@ -0,0 +1,35 @@ +{ + "name": "todo_application", + "short_name": "todo_application", + "start_url": ".", + "display": "standalone", + "background_color": "#0175C2", + "theme_color": "#0175C2", + "description": "A new Flutter project.", + "orientation": "portrait-primary", + "prefer_related_applications": false, + "icons": [ + { + "src": "icons/Icon-192.png", + "sizes": "192x192", + "type": "image/png" + }, + { + "src": "icons/Icon-512.png", + "sizes": "512x512", + "type": "image/png" + }, + { + "src": "icons/Icon-maskable-192.png", + "sizes": "192x192", + "type": "image/png", + "purpose": "maskable" + }, + { + "src": "icons/Icon-maskable-512.png", + "sizes": "512x512", + "type": "image/png", + "purpose": "maskable" + } + ] +} diff --git a/session_6/Assignment4/movies_app/.gitignore b/session_6/Assignment4/movies_app/.gitignore new file mode 100644 index 00000000..0fa6b675 --- /dev/null +++ b/session_6/Assignment4/movies_app/.gitignore @@ -0,0 +1,46 @@ +# Miscellaneous +*.class +*.log +*.pyc +*.swp +.DS_Store +.atom/ +.buildlog/ +.history +.svn/ + +# IntelliJ related +*.iml +*.ipr +*.iws +.idea/ + +# The .vscode folder contains launch configuration and tasks you configure in +# VS Code which you may wish to be included in version control, so this line +# is commented out by default. +#.vscode/ + +# Flutter/Dart/Pub related +**/doc/api/ +**/ios/Flutter/.last_build_id +.dart_tool/ +.flutter-plugins +.flutter-plugins-dependencies +.packages +.pub-cache/ +.pub/ +/build/ + +# Web related +lib/generated_plugin_registrant.dart + +# Symbolication related +app.*.symbols + +# Obfuscation related +app.*.map.json + +# Android Studio will place build artifacts here +/android/app/debug +/android/app/profile +/android/app/release diff --git a/session_6/Assignment4/movies_app/.metadata b/session_6/Assignment4/movies_app/.metadata new file mode 100644 index 00000000..fd70cabc --- /dev/null +++ b/session_6/Assignment4/movies_app/.metadata @@ -0,0 +1,10 @@ +# This file tracks properties of this Flutter project. +# Used by Flutter tool to assess capabilities and perform upgrades etc. +# +# This file should be version controlled and should not be manually edited. + +version: + revision: 77d935af4db863f6abd0b9c31c7e6df2a13de57b + channel: stable + +project_type: app diff --git a/session_6/Assignment4/movies_app/README.md b/session_6/Assignment4/movies_app/README.md new file mode 100644 index 00000000..4fd08710 --- /dev/null +++ b/session_6/Assignment4/movies_app/README.md @@ -0,0 +1,10 @@ +# Movies App + + +## App Screen Record + + +https://user-images.githubusercontent.com/78261857/154956992-674c08a7-07e7-4d44-b8af-94ad08b077d3.mp4 + + + diff --git a/session_6/Assignment4/movies_app/analysis_options.yaml b/session_6/Assignment4/movies_app/analysis_options.yaml new file mode 100644 index 00000000..61b6c4de --- /dev/null +++ b/session_6/Assignment4/movies_app/analysis_options.yaml @@ -0,0 +1,29 @@ +# This file configures the analyzer, which statically analyzes Dart code to +# check for errors, warnings, and lints. +# +# The issues identified by the analyzer are surfaced in the UI of Dart-enabled +# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be +# invoked from the command line by running `flutter analyze`. + +# The following line activates a set of recommended lints for Flutter apps, +# packages, and plugins designed to encourage good coding practices. +include: package:flutter_lints/flutter.yaml + +linter: + # The lint rules applied to this project can be customized in the + # section below to disable rules from the `package:flutter_lints/flutter.yaml` + # included above or to enable additional rules. A list of all available lints + # and their documentation is published at + # https://dart-lang.github.io/linter/lints/index.html. + # + # Instead of disabling a lint rule for the entire project in the + # section below, it can also be suppressed for a single line of code + # or a specific dart file by using the `// ignore: name_of_lint` and + # `// ignore_for_file: name_of_lint` syntax on the line or in the file + # producing the lint. + rules: + # avoid_print: false # Uncomment to disable the `avoid_print` rule + # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule + +# Additional information about this file can be found at +# https://dart.dev/guides/language/analysis-options diff --git a/session_6/Assignment4/movies_app/android/.gitignore b/session_6/Assignment4/movies_app/android/.gitignore new file mode 100644 index 00000000..6f568019 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/.gitignore @@ -0,0 +1,13 @@ +gradle-wrapper.jar +/.gradle +/captures/ +/gradlew +/gradlew.bat +/local.properties +GeneratedPluginRegistrant.java + +# Remember to never publicly share your keystore. +# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app +key.properties +**/*.keystore +**/*.jks diff --git a/session_6/Assignment4/movies_app/android/app/build.gradle b/session_6/Assignment4/movies_app/android/app/build.gradle new file mode 100644 index 00000000..dbc993e4 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/build.gradle @@ -0,0 +1,68 @@ +def localProperties = new Properties() +def localPropertiesFile = rootProject.file('local.properties') +if (localPropertiesFile.exists()) { + localPropertiesFile.withReader('UTF-8') { reader -> + localProperties.load(reader) + } +} + +def flutterRoot = localProperties.getProperty('flutter.sdk') +if (flutterRoot == null) { + throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") +} + +def flutterVersionCode = localProperties.getProperty('flutter.versionCode') +if (flutterVersionCode == null) { + flutterVersionCode = '1' +} + +def flutterVersionName = localProperties.getProperty('flutter.versionName') +if (flutterVersionName == null) { + flutterVersionName = '1.0' +} + +apply plugin: 'com.android.application' +apply plugin: 'kotlin-android' +apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" + +android { + compileSdkVersion flutter.compileSdkVersion + + compileOptions { + sourceCompatibility JavaVersion.VERSION_1_8 + targetCompatibility JavaVersion.VERSION_1_8 + } + + kotlinOptions { + jvmTarget = '1.8' + } + + sourceSets { + main.java.srcDirs += 'src/main/kotlin' + } + + defaultConfig { + // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). + applicationId "com.example.movies_app" + minSdkVersion flutter.minSdkVersion + targetSdkVersion flutter.targetSdkVersion + versionCode flutterVersionCode.toInteger() + versionName flutterVersionName + } + + buildTypes { + release { + // TODO: Add your own signing config for the release build. + // Signing with the debug keys for now, so `flutter run --release` works. + signingConfig signingConfigs.debug + } + } +} + +flutter { + source '../..' +} + +dependencies { + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" +} diff --git a/session_6/Assignment4/movies_app/android/app/src/debug/AndroidManifest.xml b/session_6/Assignment4/movies_app/android/app/src/debug/AndroidManifest.xml new file mode 100644 index 00000000..80151e96 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/src/debug/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/session_6/Assignment4/movies_app/android/app/src/main/AndroidManifest.xml b/session_6/Assignment4/movies_app/android/app/src/main/AndroidManifest.xml new file mode 100644 index 00000000..5043a58e --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/src/main/AndroidManifest.xml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + diff --git a/session_6/Assignment4/movies_app/android/app/src/main/kotlin/com/example/movies_app/MainActivity.kt b/session_6/Assignment4/movies_app/android/app/src/main/kotlin/com/example/movies_app/MainActivity.kt new file mode 100644 index 00000000..7309f774 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/src/main/kotlin/com/example/movies_app/MainActivity.kt @@ -0,0 +1,6 @@ +package com.example.movies_app + +import io.flutter.embedding.android.FlutterActivity + +class MainActivity: FlutterActivity() { +} diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/drawable-v21/launch_background.xml b/session_6/Assignment4/movies_app/android/app/src/main/res/drawable-v21/launch_background.xml new file mode 100644 index 00000000..f74085f3 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/src/main/res/drawable-v21/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/drawable/launch_background.xml b/session_6/Assignment4/movies_app/android/app/src/main/res/drawable/launch_background.xml new file mode 100644 index 00000000..304732f8 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/src/main/res/drawable/launch_background.xml @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 00000000..db77bb4b Binary files /dev/null and b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-hdpi/ic_launcher.png differ diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 00000000..17987b79 Binary files /dev/null and b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-mdpi/ic_launcher.png differ diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 00000000..09d43914 Binary files /dev/null and b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 00000000..d5f1c8d3 Binary files /dev/null and b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 00000000..4d6372ee Binary files /dev/null and b/session_6/Assignment4/movies_app/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/values-night/styles.xml b/session_6/Assignment4/movies_app/android/app/src/main/res/values-night/styles.xml new file mode 100644 index 00000000..3db14bb5 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/src/main/res/values-night/styles.xml @@ -0,0 +1,18 @@ + + + + + + + diff --git a/session_6/Assignment4/movies_app/android/app/src/main/res/values/styles.xml b/session_6/Assignment4/movies_app/android/app/src/main/res/values/styles.xml new file mode 100644 index 00000000..d460d1e9 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/src/main/res/values/styles.xml @@ -0,0 +1,18 @@ + + + + + + + diff --git a/session_6/Assignment4/movies_app/android/app/src/profile/AndroidManifest.xml b/session_6/Assignment4/movies_app/android/app/src/profile/AndroidManifest.xml new file mode 100644 index 00000000..80151e96 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/app/src/profile/AndroidManifest.xml @@ -0,0 +1,7 @@ + + + + diff --git a/session_6/Assignment4/movies_app/android/build.gradle b/session_6/Assignment4/movies_app/android/build.gradle new file mode 100644 index 00000000..24047dce --- /dev/null +++ b/session_6/Assignment4/movies_app/android/build.gradle @@ -0,0 +1,31 @@ +buildscript { + ext.kotlin_version = '1.3.50' + repositories { + google() + mavenCentral() + } + + dependencies { + classpath 'com.android.tools.build:gradle:4.1.0' + classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" + } +} + +allprojects { + repositories { + google() + mavenCentral() + } +} + +rootProject.buildDir = '../build' +subprojects { + project.buildDir = "${rootProject.buildDir}/${project.name}" +} +subprojects { + project.evaluationDependsOn(':app') +} + +task clean(type: Delete) { + delete rootProject.buildDir +} diff --git a/session_6/Assignment4/movies_app/android/gradle.properties b/session_6/Assignment4/movies_app/android/gradle.properties new file mode 100644 index 00000000..94adc3a3 --- /dev/null +++ b/session_6/Assignment4/movies_app/android/gradle.properties @@ -0,0 +1,3 @@ +org.gradle.jvmargs=-Xmx1536M +android.useAndroidX=true +android.enableJetifier=true diff --git a/session_6/Assignment4/movies_app/android/gradle/wrapper/gradle-wrapper.properties b/session_6/Assignment4/movies_app/android/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 00000000..bc6a58af --- /dev/null +++ b/session_6/Assignment4/movies_app/android/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,6 @@ +#Fri Jun 23 08:50:38 CEST 2017 +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip diff --git a/session_6/Assignment4/movies_app/android/settings.gradle b/session_6/Assignment4/movies_app/android/settings.gradle new file mode 100644 index 00000000..44e62bcf --- /dev/null +++ b/session_6/Assignment4/movies_app/android/settings.gradle @@ -0,0 +1,11 @@ +include ':app' + +def localPropertiesFile = new File(rootProject.projectDir, "local.properties") +def properties = new Properties() + +assert localPropertiesFile.exists() +localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } + +def flutterSdkPath = properties.getProperty("flutter.sdk") +assert flutterSdkPath != null, "flutter.sdk not set in local.properties" +apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" diff --git a/session_6/Assignment4/movies_app/ios/.gitignore b/session_6/Assignment4/movies_app/ios/.gitignore new file mode 100644 index 00000000..7a7f9873 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/.gitignore @@ -0,0 +1,34 @@ +**/dgph +*.mode1v3 +*.mode2v3 +*.moved-aside +*.pbxuser +*.perspectivev3 +**/*sync/ +.sconsign.dblite +.tags* +**/.vagrant/ +**/DerivedData/ +Icon? +**/Pods/ +**/.symlinks/ +profile +xcuserdata +**/.generated/ +Flutter/App.framework +Flutter/Flutter.framework +Flutter/Flutter.podspec +Flutter/Generated.xcconfig +Flutter/ephemeral/ +Flutter/app.flx +Flutter/app.zip +Flutter/flutter_assets/ +Flutter/flutter_export_environment.sh +ServiceDefinitions.json +Runner/GeneratedPluginRegistrant.* + +# Exceptions to above rules. +!default.mode1v3 +!default.mode2v3 +!default.pbxuser +!default.perspectivev3 diff --git a/session_6/Assignment4/movies_app/ios/Flutter/AppFrameworkInfo.plist b/session_6/Assignment4/movies_app/ios/Flutter/AppFrameworkInfo.plist new file mode 100644 index 00000000..8d4492f9 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Flutter/AppFrameworkInfo.plist @@ -0,0 +1,26 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + App + CFBundleIdentifier + io.flutter.flutter.app + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + App + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1.0 + MinimumOSVersion + 9.0 + + diff --git a/session_6/Assignment4/movies_app/ios/Flutter/Debug.xcconfig b/session_6/Assignment4/movies_app/ios/Flutter/Debug.xcconfig new file mode 100644 index 00000000..592ceee8 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Flutter/Debug.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/session_6/Assignment4/movies_app/ios/Flutter/Release.xcconfig b/session_6/Assignment4/movies_app/ios/Flutter/Release.xcconfig new file mode 100644 index 00000000..592ceee8 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Flutter/Release.xcconfig @@ -0,0 +1 @@ +#include "Generated.xcconfig" diff --git a/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.pbxproj b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.pbxproj new file mode 100644 index 00000000..8d6d3df7 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.pbxproj @@ -0,0 +1,481 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; +/* End PBXBuildFile section */ + +/* Begin PBXCopyFilesBuildPhase section */ + 9705A1C41CF9048500538489 /* Embed Frameworks */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 10; + files = ( + ); + name = "Embed Frameworks"; + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; }; + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; }; + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; }; + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; }; + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; }; + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; }; + 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; }; + 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 97C146EB1CF9000F007C117D /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 9740EEB11CF90186004384FC /* Flutter */ = { + isa = PBXGroup; + children = ( + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, + 9740EEB21CF90195004384FC /* Debug.xcconfig */, + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, + 9740EEB31CF90195004384FC /* Generated.xcconfig */, + ); + name = Flutter; + sourceTree = ""; + }; + 97C146E51CF9000F007C117D = { + isa = PBXGroup; + children = ( + 9740EEB11CF90186004384FC /* Flutter */, + 97C146F01CF9000F007C117D /* Runner */, + 97C146EF1CF9000F007C117D /* Products */, + ); + sourceTree = ""; + }; + 97C146EF1CF9000F007C117D /* Products */ = { + isa = PBXGroup; + children = ( + 97C146EE1CF9000F007C117D /* Runner.app */, + ); + name = Products; + sourceTree = ""; + }; + 97C146F01CF9000F007C117D /* Runner */ = { + isa = PBXGroup; + children = ( + 97C146FA1CF9000F007C117D /* Main.storyboard */, + 97C146FD1CF9000F007C117D /* Assets.xcassets */, + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, + 97C147021CF9000F007C117D /* Info.plist */, + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, + 74858FAE1ED2DC5600515810 /* AppDelegate.swift */, + 74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */, + ); + path = Runner; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 97C146ED1CF9000F007C117D /* Runner */ = { + isa = PBXNativeTarget; + buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; + buildPhases = ( + 9740EEB61CF901F6004384FC /* Run Script */, + 97C146EA1CF9000F007C117D /* Sources */, + 97C146EB1CF9000F007C117D /* Frameworks */, + 97C146EC1CF9000F007C117D /* Resources */, + 9705A1C41CF9048500538489 /* Embed Frameworks */, + 3B06AD1E1E4923F5004D2608 /* Thin Binary */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Runner; + productName = Runner; + productReference = 97C146EE1CF9000F007C117D /* Runner.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 97C146E61CF9000F007C117D /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1300; + ORGANIZATIONNAME = ""; + TargetAttributes = { + 97C146ED1CF9000F007C117D = { + CreatedOnToolsVersion = 7.3.1; + LastSwiftMigration = 1100; + }; + }; + }; + buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 97C146E51CF9000F007C117D; + productRefGroup = 97C146EF1CF9000F007C117D /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 97C146ED1CF9000F007C117D /* Runner */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 97C146EC1CF9000F007C117D /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXShellScriptBuildPhase section */ + 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Thin Binary"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; + }; + 9740EEB61CF901F6004384FC /* Run Script */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + name = "Run Script"; + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 97C146EA1CF9000F007C117D /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */, + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 97C146FA1CF9000F007C117D /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C146FB1CF9000F007C117D /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 97C147001CF9000F007C117D /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 249021D3217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Profile; + }; + 249021D4217E4FDB00AE95B9 /* Profile */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.moviesApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Profile; + }; + 97C147031CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 97C147041CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SUPPORTED_PLATFORMS = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 97C147061CF9000F007C117D /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.moviesApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Debug; + }; + 97C147071CF9000F007C117D /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; + ENABLE_BITCODE = NO; + INFOPLIST_FILE = Runner/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.example.moviesApp; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h"; + SWIFT_VERSION = 5.0; + VERSIONING_SYSTEM = "apple-generic"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147031CF9000F007C117D /* Debug */, + 97C147041CF9000F007C117D /* Release */, + 249021D3217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 97C147061CF9000F007C117D /* Debug */, + 97C147071CF9000F007C117D /* Release */, + 249021D4217E4FDB00AE95B9 /* Profile */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 97C146E61CF9000F007C117D /* Project object */; +} diff --git a/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..919434a6 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 00000000..f9b0d7c5 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + PreviewsEnabled + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme new file mode 100644 index 00000000..c87d15a3 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme @@ -0,0 +1,87 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/contents.xcworkspacedata b/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/contents.xcworkspacedata new file mode 100644 index 00000000..1d526a16 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 00000000..18d98100 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 00000000..f9b0d7c5 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + PreviewsEnabled + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner/AppDelegate.swift b/session_6/Assignment4/movies_app/ios/Runner/AppDelegate.swift new file mode 100644 index 00000000..70693e4a --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner/AppDelegate.swift @@ -0,0 +1,13 @@ +import UIKit +import Flutter + +@UIApplicationMain +@objc class AppDelegate: FlutterAppDelegate { + override func application( + _ application: UIApplication, + didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? + ) -> Bool { + GeneratedPluginRegistrant.register(with: self) + return super.application(application, didFinishLaunchingWithOptions: launchOptions) + } +} diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..d36b1fab --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,122 @@ +{ + "images" : [ + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "20x20", + "idiom" : "iphone", + "filename" : "Icon-App-20x20@3x.png", + "scale" : "3x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "iphone", + "filename" : "Icon-App-29x29@3x.png", + "scale" : "3x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "iphone", + "filename" : "Icon-App-40x40@3x.png", + "scale" : "3x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@2x.png", + "scale" : "2x" + }, + { + "size" : "60x60", + "idiom" : "iphone", + "filename" : "Icon-App-60x60@3x.png", + "scale" : "3x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@1x.png", + "scale" : "1x" + }, + { + "size" : "20x20", + "idiom" : "ipad", + "filename" : "Icon-App-20x20@2x.png", + "scale" : "2x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@1x.png", + "scale" : "1x" + }, + { + "size" : "29x29", + "idiom" : "ipad", + "filename" : "Icon-App-29x29@2x.png", + "scale" : "2x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@1x.png", + "scale" : "1x" + }, + { + "size" : "40x40", + "idiom" : "ipad", + "filename" : "Icon-App-40x40@2x.png", + "scale" : "2x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@1x.png", + "scale" : "1x" + }, + { + "size" : "76x76", + "idiom" : "ipad", + "filename" : "Icon-App-76x76@2x.png", + "scale" : "2x" + }, + { + "size" : "83.5x83.5", + "idiom" : "ipad", + "filename" : "Icon-App-83.5x83.5@2x.png", + "scale" : "2x" + }, + { + "size" : "1024x1024", + "idiom" : "ios-marketing", + "filename" : "Icon-App-1024x1024@1x.png", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png new file mode 100644 index 00000000..dc9ada47 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png new file mode 100644 index 00000000..28c6bf03 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png new file mode 100644 index 00000000..2ccbfd96 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png new file mode 100644 index 00000000..f091b6b0 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png new file mode 100644 index 00000000..4cde1211 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png new file mode 100644 index 00000000..d0ef06e7 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png new file mode 100644 index 00000000..dcdc2306 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png new file mode 100644 index 00000000..2ccbfd96 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png new file mode 100644 index 00000000..c8f9ed8f Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png new file mode 100644 index 00000000..a6d6b860 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png new file mode 100644 index 00000000..a6d6b860 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png new file mode 100644 index 00000000..75b2d164 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png new file mode 100644 index 00000000..c4df70d3 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png new file mode 100644 index 00000000..6a84f41e Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png new file mode 100644 index 00000000..d0e1f585 Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json new file mode 100644 index 00000000..0bedcf2f --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "LaunchImage.png", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@2x.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "filename" : "LaunchImage@3x.png", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png new file mode 100644 index 00000000..9da19eac Binary files /dev/null and b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png differ diff --git a/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md new file mode 100644 index 00000000..89c2725b --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md @@ -0,0 +1,5 @@ +# Launch Screen Assets + +You can customize the launch screen with your own desired assets by replacing the image files in this directory. + +You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. \ No newline at end of file diff --git a/session_6/Assignment4/movies_app/ios/Runner/Base.lproj/LaunchScreen.storyboard b/session_6/Assignment4/movies_app/ios/Runner/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 00000000..f2e259c7 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner/Base.lproj/Main.storyboard b/session_6/Assignment4/movies_app/ios/Runner/Base.lproj/Main.storyboard new file mode 100644 index 00000000..f3c28516 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner/Base.lproj/Main.storyboard @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner/Info.plist b/session_6/Assignment4/movies_app/ios/Runner/Info.plist new file mode 100644 index 00000000..e82c33fc --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner/Info.plist @@ -0,0 +1,47 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleDisplayName + Movies App + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + movies_app + CFBundlePackageType + APPL + CFBundleShortVersionString + $(FLUTTER_BUILD_NAME) + CFBundleSignature + ???? + CFBundleVersion + $(FLUTTER_BUILD_NUMBER) + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UIViewControllerBasedStatusBarAppearance + + + diff --git a/session_6/Assignment4/movies_app/ios/Runner/Runner-Bridging-Header.h b/session_6/Assignment4/movies_app/ios/Runner/Runner-Bridging-Header.h new file mode 100644 index 00000000..308a2a56 --- /dev/null +++ b/session_6/Assignment4/movies_app/ios/Runner/Runner-Bridging-Header.h @@ -0,0 +1 @@ +#import "GeneratedPluginRegistrant.h" diff --git a/session_6/Assignment4/movies_app/lib/TODO.txt b/session_6/Assignment4/movies_app/lib/TODO.txt new file mode 100644 index 00000000..424c16f4 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/TODO.txt @@ -0,0 +1,24 @@ +Splash Screen + + +Local Storage for top 10 Movies and series + + / +BLoC for state management \/ + + / +Home/Popular Movies, Series, Top 10 Page \/ + + / +Top 250 Movies page \/ + + / +Top 250 Series page \/ + +Search Movie page + +Search Series page + +Movie info Page + +Series info Page \ No newline at end of file diff --git a/session_6/Assignment4/movies_app/lib/main.dart b/session_6/Assignment4/movies_app/lib/main.dart new file mode 100644 index 00000000..1a7f0706 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/main.dart @@ -0,0 +1,28 @@ +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:movies_app/ui/cubit/navbar_cubit.dart'; +import 'package:movies_app/ui/pages/main_page/main_page.dart'; + +void main() => runApp(MyApp()); + +class MyApp extends StatelessWidget { + @override + Widget build(BuildContext context) { + return BlocProvider( + create: (context) => NavbarCubit(), + child: BlocBuilder( + builder: (context, state) { + return MaterialApp( + title: 'Material App', + home: MainPage(), + debugShowCheckedModeBanner: false, + ); + }, + ), + ); + + + + + } +} \ No newline at end of file diff --git a/session_6/Assignment4/movies_app/lib/ui/cubit/navbar_cubit.dart b/session_6/Assignment4/movies_app/lib/ui/cubit/navbar_cubit.dart new file mode 100644 index 00000000..27ec6a14 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/cubit/navbar_cubit.dart @@ -0,0 +1,25 @@ +import 'package:bloc/bloc.dart'; +import 'package:equatable/equatable.dart'; +import 'package:movies_app/ui/pages/movie_page/widgets.dart'; +import 'package:movies_app/ui/pages/home_page/widgets.dart'; +import 'package:movies_app/ui/pages/tvs_page/widgets.dart'; + + +class NavbarCubit extends Cubit { + + List widgetList = [home,Top250.movie,tvs]; + List pageTitleList = ["IMDb Movies App","Movies","TV Shows"]; + + NavbarCubit() : super([0,home,"IMDb Movies App",""]); + + void navPage(int index){ + var searchText = state[3]; + List list = [index,widgetList[index],pageTitleList[index],searchText]; + emit(list); + } + void search(String searchText){ + List list = state; + list[3] = searchText; + emit(list); + } +} diff --git a/session_6/Assignment4/movies_app/lib/ui/global_widgets.dart b/session_6/Assignment4/movies_app/lib/ui/global_widgets.dart new file mode 100644 index 00000000..13f9a151 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/global_widgets.dart @@ -0,0 +1,9 @@ +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:movies_app/ui/cubit/navbar_cubit.dart'; + +// NavigationBar Widget =============================== + + + +// ==================================================== \ No newline at end of file diff --git a/session_6/Assignment4/movies_app/lib/ui/pages/home_page/api.dart b/session_6/Assignment4/movies_app/lib/ui/pages/home_page/api.dart new file mode 100644 index 00000000..050055c4 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/pages/home_page/api.dart @@ -0,0 +1,116 @@ +import 'package:http/http.dart' as http; +import 'dart:convert'; +import 'package:flutter/material.dart'; +import 'package:movies_app/ui/api_key.dart'; + + +// Popular Movies API ================================================================== + +class PopularMovies{ + final String id; + final String title; + final Image image; + + PopularMovies(this.id, this.title, this.image); +} + + + + + +Future getPopularMovies() async{ + + List popularMovies = []; + + Uri? url = Uri.parse('https://imdb-api.com/en/API/MostPopularMovies/$apiKey'); + var response = await http.get(url); + var body = jsonDecode(response.body); + + var movies = body["items"]; + + for(int i = 0; i < 10; i++) { + popularMovies.add(PopularMovies(movies[i]["id"], movies[i]["title"], Image.network(movies[i]["image"]))); + + } + + return popularMovies; + +} +// ============================================================================================================ + + + + +// Popular TVs API ================================================================== + +class PopularTvs{ + final String id; + final String title; + final Image image; + + PopularTvs(this.id, this.title, this.image); +} + + + + + +Future getPopularTvs() async{ + + List popularTvs = []; + + Uri? url = Uri.parse('https://imdb-api.com/en/API/MostPopularTVs/$apiKey'); + var response = await http.get(url); + var body = jsonDecode(response.body); + + var shows = body["items"]; + + for(int i = 0; i < 10; i++) { + popularTvs.add(PopularMovies(shows[i]["id"], shows[i]["title"], Image.network(shows[i]["image"]))); + + } + + return popularTvs; + +} +// ============================================================================================================ + + + +// Top 10 Movies API ================================================================== + +class Top10Movies{ + final String id; + final String title; + final Image image; + + Top10Movies(this.id, this.title, this.image); +} + + + + + +Future getTop10Movies() async{ + + List top10Movies = []; + + Uri? url = Uri.parse('https://imdb-api.com/en/API/Top250Movies/$apiKey'); + var response = await http.get(url); + var body = jsonDecode(response.body); + + var shows = body["items"]; + + for(int i = 0; i < 10; i++) { + top10Movies.add(PopularMovies(shows[i]["id"], shows[i]["title"], Image.network(shows[i]["image"]))); + + } + + return top10Movies; + +} +// ============================================================================================================ + + + + diff --git a/session_6/Assignment4/movies_app/lib/ui/pages/home_page/widgets.dart b/session_6/Assignment4/movies_app/lib/ui/pages/home_page/widgets.dart new file mode 100644 index 00000000..436e2b56 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/pages/home_page/widgets.dart @@ -0,0 +1,203 @@ +/* + This File handles the Widgets of the home page +*/ + +import 'package:flutter/material.dart'; +import 'api.dart'; + + + +// AppBar Widget ====================================== + +AppBar appBar = AppBar( + title: Text('IMDb Movies App'), +); + +// ==================================================== + + + + + + + + + +// Future Popular Movies Widget ============================== + +FutureBuilder popularMovies = FutureBuilder( + future: getPopularMovies(), + initialData: List.empty(), + builder: (BuildContext context, AsyncSnapshot snapshot) { + if(snapshot.connectionState == ConnectionState.done && snapshot.hasError){ + return Text(snapshot.error.toString()); + } + else if(snapshot.connectionState == ConnectionState.waiting){ + return const Center(child: CircularProgressIndicator.adaptive()); + } + else{ + return Container( + height: 180, + child: ListView.separated( + scrollDirection: Axis.horizontal, + + itemCount: snapshot.data!.length, + separatorBuilder: (context, index) => SizedBox(width: 12,), + itemBuilder: (context, index) { + var popularMovies = snapshot.data; + return InkWell( + onTap: () {}, + child: ClipRRect( + borderRadius: BorderRadius.circular(10), + child: popularMovies[index].image, + ) + ); + }, + ), + ); + } + }, + ); + +// ==================================================== + + +// Future Popular TVs Widget ============================== + +FutureBuilder popularTvs = FutureBuilder( + future: getPopularTvs(), + initialData: List.empty(), + builder: (BuildContext context, AsyncSnapshot snapshot) { + if(snapshot.connectionState == ConnectionState.done && snapshot.hasError){ + return Text(snapshot.error.toString()); + } + else if(snapshot.connectionState == ConnectionState.waiting){ + return const Center(child: CircularProgressIndicator.adaptive()); + } + else{ + // ignore: sized_box_for_whitespace + return Container( + height: 180, + child: ListView.separated( + scrollDirection: Axis.horizontal, + + itemCount: snapshot.data!.length, + separatorBuilder: (context, index) => SizedBox(width: 12,), + itemBuilder: (context, index) { + var popularTvs = snapshot.data; + return Builder( + builder: (context) { + return InkWell( + onTap: () {}, + child: ClipRRect( + borderRadius: BorderRadius.circular(20), + child: popularTvs[index].image, + ), + ); + } + ); + }, + ), + ); + } + }, + ); + +// ==================================================== + + + +// Future Top 10 Movies Widget ============================== + +FutureBuilder top10Movies = FutureBuilder( + future: getTop10Movies(), + initialData: List.empty(), + builder: (BuildContext context, AsyncSnapshot snapshot) { + if(snapshot.connectionState == ConnectionState.done && snapshot.hasError){ + return Text(snapshot.error.toString()); + } + else if(snapshot.connectionState == ConnectionState.waiting){ + return const Center(child: CircularProgressIndicator.adaptive()); + } + else{ + return Container( + height: 180, + child: ListView.separated( + scrollDirection: Axis.horizontal, + + itemCount: snapshot.data!.length, + separatorBuilder: (context, index) => SizedBox(width: 12,), + itemBuilder: (context, index) { + var top10Movies = snapshot.data; + return InkWell( + onTap: (){}, + child: ClipRRect( + borderRadius: BorderRadius.circular(20), + child: top10Movies[index].image, + + ), + ); + }, + ), + ); + } + }, + ); + +// ==================================================== + +// Popular Movies Widget ============================== + + var popularMoviesBuilder = Center( + + child: SingleChildScrollView( + + child: Padding( + padding: const EdgeInsets.all(8.0), + child: Column( + mainAxisAlignment: MainAxisAlignment.spaceEvenly, + children: [ + Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('Popular Movies',style: TextStyle(fontSize: 22, fontWeight: FontWeight.bold), textAlign: TextAlign.left,), + popularMovies, + ], + ), + + SizedBox(height: 5,), + + Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('Popular TV Shows',style: TextStyle(fontSize: 22, fontWeight: FontWeight.bold), textAlign: TextAlign.left,), + popularTvs, + ], + ), + + SizedBox(height: 5,), + + Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text('Top 10 Movies',style: TextStyle(fontSize: 22, fontWeight: FontWeight.bold), textAlign: TextAlign.left,), + top10Movies, + ], + ), + + ], + ), + ), + ) + ); + +// ==================================================== + + + + Widget home = Padding( + padding: EdgeInsets.all(8), + child: popularMoviesBuilder, + ); + + diff --git a/session_6/Assignment4/movies_app/lib/ui/pages/main_page/main_page.dart b/session_6/Assignment4/movies_app/lib/ui/pages/main_page/main_page.dart new file mode 100644 index 00000000..29cde866 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/pages/main_page/main_page.dart @@ -0,0 +1,54 @@ +import 'package:flutter/material.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:movies_app/ui/cubit/navbar_cubit.dart'; +import 'package:movies_app/ui/pages/home_page/widgets.dart'; +import 'package:movies_app/ui/pages/movie_page/widgets.dart'; +import 'package:movies_app/ui/global_widgets.dart'; + +class MainPage extends StatefulWidget { + const MainPage({ Key? key }) : super(key: key); + + @override + _MainPageState createState() => _MainPageState(); +} + +class _MainPageState extends State { + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title:Text(BlocProvider.of(context).state[2]), + centerTitle: true, + actions: [ + IconButton( + onPressed: (){}, + icon: Icon(Icons.search), + ), + ], + ), + body: BlocProvider.of(context).state[1], + bottomNavigationBar: BottomNavigationBar( + items: const[ + BottomNavigationBarItem( + icon: Icon(Icons.home), + label:'Home', + ), + BottomNavigationBarItem( + icon: Icon(Icons.movie_outlined), + label:'Movies', + ), + BottomNavigationBarItem( + icon: Icon(Icons.tv_outlined), + label:'TV Shows', + ), + + ], + currentIndex: BlocProvider.of(context).state[0], + onTap: (value) { + // Navigator.push(context, route) + BlocProvider.of(context).navPage(value); + }, + ), + ); + } +} \ No newline at end of file diff --git a/session_6/Assignment4/movies_app/lib/ui/pages/movie_page/api.dart b/session_6/Assignment4/movies_app/lib/ui/pages/movie_page/api.dart new file mode 100644 index 00000000..e8f7526f --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/pages/movie_page/api.dart @@ -0,0 +1,26 @@ +import 'package:http/http.dart' as http; +import 'dart:convert'; +import 'package:flutter/material.dart'; +import 'package:movies_app/ui/api_key.dart'; + + +Future getTop250Movies() async{ + + + Uri? url = Uri.parse('https://imdb-api.com/en/API/Top250Movies/$apiKey'); + var response = await http.get(url); + var body = jsonDecode(response.body)["items"]; + + return body; + +} +Future searchMovies(String expression) async{ + + + Uri? url = Uri.parse('https://imdb-api.com/en/API/SearchMovie/$apiKey/$expression'); + var response = await http.get(url); + var body = jsonDecode(response.body)["results"]; + + return body; + +} \ No newline at end of file diff --git a/session_6/Assignment4/movies_app/lib/ui/pages/movie_page/widgets.dart b/session_6/Assignment4/movies_app/lib/ui/pages/movie_page/widgets.dart new file mode 100644 index 00000000..242f5168 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/pages/movie_page/widgets.dart @@ -0,0 +1,152 @@ +/* + This File handles the Widgets of the movie page +*/ + +import 'package:flutter/material.dart'; +import 'api.dart'; +import 'package:flutter_bloc/flutter_bloc.dart'; +import 'package:movies_app/ui/cubit/navbar_cubit.dart'; + +// AppBar Widget ====================================== + +AppBar appBar = AppBar( + title: Text('Top 250 Movies'), + centerTitle: true, +); + +// ==================================================== + +class Top250 { + static FutureBuilder popularMovies = FutureBuilder( + future: getTop250Movies(), + initialData: List.empty(), + builder: (BuildContext context, AsyncSnapshot snapshot) { + if (snapshot.connectionState == ConnectionState.done && + snapshot.hasError) { + return Text(snapshot.error.toString()); + } else if (snapshot.connectionState == ConnectionState.waiting) { + return const Center(child: CircularProgressIndicator.adaptive()); + } else { + return Column( + children: [ + Divider( + thickness: 5, + ), + Text( + 'Top 250 Movies', + style: TextStyle(fontSize: 25), + ), + Divider( + thickness: 5, + ), + Expanded( + child: ListView.builder( + itemCount: snapshot.data!.length, + itemBuilder: (context, index) { + var popularMovies = snapshot.data; + return Card( + child: ListTile( + leading: Image.network(popularMovies[index]["image"]), + title: + Text("${index + 1}. ${popularMovies[index]["title"]}"), + tileColor: Colors.blue.shade100, + )); + }, + ), + ), + ], + ); + } + }, + ); + +// ==================================================== + + // static FutureBuilder search(String expression){ + static var search = BlocProvider( + create: (context) => NavbarCubit(), + child: BlocBuilder( + builder: (context, state) { + return FutureBuilder( + future: searchMovies(BlocProvider.of(context).state[3]), + initialData: List.empty(), + builder: (BuildContext context, AsyncSnapshot snapshot) { + if (snapshot.connectionState == ConnectionState.done && + snapshot.hasError) { + return Text(snapshot.error.toString()); + } else if (snapshot.connectionState == ConnectionState.waiting) { + return const Center(child: CircularProgressIndicator.adaptive()); + } else { + print(_search.text); + return Column( + children: [ + Expanded( + child: ListView.builder( + itemCount: snapshot.data!.length, + itemBuilder: (context, index) { + var popularMovies = snapshot.data; + return Card( + child: ListTile( + leading: Image.network(popularMovies[index]["image"]), + title: Text( + "${index + 1}. ${popularMovies[index]["title"]}"), + tileColor: Colors.blue.shade100, + )); + }, + ), + ), + ], + ); + } + }, + ); + }, + ), + ); + + // return search; + // } + + static TextEditingController _search = TextEditingController(); + + static Widget movie = BlocProvider( + create: (context) => NavbarCubit(), + child: BlocBuilder( + builder: (context, state) { + return Padding( + padding: EdgeInsets.all(8), + child: Column( + children: [ + ListTile( + trailing: TextButton( + style: ButtonStyle( + backgroundColor: MaterialStateProperty.all(Colors.blue), + ), + onPressed: () { + BlocProvider.of(context).search(_search.text); + }, + child: Text( + "Search", + style: TextStyle(color: Colors.white), + ), + ), + title: TextField( + controller: _search, + decoration: InputDecoration( + labelText: 'Search for a movie', + ), + ), + ), + SizedBox( + height: 40, + ), + Expanded(child: _search.text.isEmpty?Text(''):search), + Text(_search.text), + Expanded(child: popularMovies), + ], + ), + ); + }, + ), + ); +} diff --git a/session_6/Assignment4/movies_app/lib/ui/pages/tvs_page/api.dart b/session_6/Assignment4/movies_app/lib/ui/pages/tvs_page/api.dart new file mode 100644 index 00000000..e5d314a3 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/pages/tvs_page/api.dart @@ -0,0 +1,16 @@ +import 'package:http/http.dart' as http; +import 'dart:convert'; +import 'package:flutter/material.dart'; +import 'package:movies_app/ui/api_key.dart'; + + +Future getTop250TVs() async{ + + + Uri? url = Uri.parse('https://imdb-api.com/en/API/Top250TVs/$apiKey'); + var response = await http.get(url); + var body = jsonDecode(response.body)["items"]; + + return body; + +} \ No newline at end of file diff --git a/session_6/Assignment4/movies_app/lib/ui/pages/tvs_page/widgets.dart b/session_6/Assignment4/movies_app/lib/ui/pages/tvs_page/widgets.dart new file mode 100644 index 00000000..2c5bccf5 --- /dev/null +++ b/session_6/Assignment4/movies_app/lib/ui/pages/tvs_page/widgets.dart @@ -0,0 +1,58 @@ +/* + This File handles the Widgets of the TVs page +*/ + +import 'package:flutter/material.dart'; +import 'api.dart'; + + + +// AppBar Widget ====================================== + +AppBar appBar = AppBar( + title: Text('Top 250 Movies'), + centerTitle: true, +); + +// ==================================================== + + + +FutureBuilder popularTVs = FutureBuilder( + future: getTop250TVs(), + initialData: List.empty(), + builder: (BuildContext context, AsyncSnapshot snapshot) { + if(snapshot.connectionState == ConnectionState.done && snapshot.hasError){ + return Text(snapshot.error.toString()); + } + else if(snapshot.connectionState == ConnectionState.waiting){ + return const Center(child: CircularProgressIndicator.adaptive()); + } + else{ + return ListView.builder( + + + itemCount: snapshot.data!.length, + itemBuilder: (context, index) { + var popularTVs = snapshot.data; + return Card( + child: ListTile( + leading: Image.network(popularTVs[index]["image"]), + title: Text("${index+1}. ${popularTVs[index]["title"]}"), + tileColor: Colors.blue.shade100, + ) + ); + }, + ); + } + }, + ); + +// ==================================================== + + + + Widget tvs = Padding( + padding: EdgeInsets.all(8), + child: popularTVs + ); \ No newline at end of file diff --git a/session_6/Assignment4/movies_app/pubspec.yaml b/session_6/Assignment4/movies_app/pubspec.yaml new file mode 100644 index 00000000..cbb96c28 --- /dev/null +++ b/session_6/Assignment4/movies_app/pubspec.yaml @@ -0,0 +1,82 @@ +name: movies_app +description: A new Flutter project. + +# The following line prevents the package from being accidentally published to +# pub.dev using `flutter pub publish`. This is preferred for private packages. +publish_to: "none" # Remove this line if you wish to publish to pub.dev + +# The following defines the version and build number for your application. +# A version number is three numbers separated by dots, like 1.2.43 +# followed by an optional build number separated by a +. +# Both the version and the builder number may be overridden in flutter +# build by specifying --build-name and --build-number, respectively. +# In Android, build-name is used as versionName while build-number used as versionCode. +# Read more about Android versioning at https://developer.android.com/studio/publish/versioning +# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. +# Read more about iOS versioning at +# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html +version: 1.0.0+1 + +environment: + sdk: ">=2.15.1 <3.0.0" + +# Dependencies specify other packages that your package needs in order to work. +# To automatically upgrade your package dependencies to the latest versions +# consider running `flutter pub upgrade --major-versions`. Alternatively, +# dependencies can be manually updated by changing the version numbers below to +# the latest version available on pub.dev. To see which dependencies have newer +# versions available, run `flutter pub outdated`. +dependencies: + bloc: ^8.0.2 + cupertino_icons: ^1.0.2 + equatable: ^2.0.3 + flutter: + sdk: flutter + flutter_bloc: ^8.0.1 + http: ^0.13.4 + +dev_dependencies: + # The "flutter_lints" package below contains a set of recommended lints to + # encourage good coding practices. The lint set provided by the package is + # activated in the `analysis_options.yaml` file located at the root of your + # package. See that file for information about deactivating specific lint + # rules and activating additional ones. + flutter_lints: ^1.0.0 + flutter_test: + sdk: flutter + +# For information on the generic Dart part of this file, see the +# following page: https://dart.dev/tools/pub/pubspec +# The following section is specific to Flutter. +flutter: + # The following line ensures that the Material Icons font is + # included with your application, so that you can use the icons in + # the material Icons class. + uses-material-design: true + # To add assets to your application, add an assets section, like this: + # assets: + # - images/a_dot_burr.jpeg + # - images/a_dot_ham.jpeg + # An image asset can refer to one or more resolution-specific "variants", see + # https://flutter.dev/assets-and-images/#resolution-aware. + # For details regarding adding assets from package dependencies, see + # https://flutter.dev/assets-and-images/#from-packages + # To add custom fonts to your application, add a fonts section here, + # in this "flutter" section. Each entry in this list should have a + # "family" key with the font family name, and a "fonts" key with a + # list giving the asset and other descriptors for the font. For + # example: + # fonts: + # - family: Schyler + # fonts: + # - asset: fonts/Schyler-Regular.ttf + # - asset: fonts/Schyler-Italic.ttf + # style: italic + # - family: Trajan Pro + # fonts: + # - asset: fonts/TrajanPro.ttf + # - asset: fonts/TrajanPro_Bold.ttf + # weight: 700 + # + # For details regarding fonts from package dependencies, + # see https://flutter.dev/custom-fonts/#from-packages diff --git a/session_6/Assignment4/movies_app/test/widget_test.dart b/session_6/Assignment4/movies_app/test/widget_test.dart new file mode 100644 index 00000000..c46816af --- /dev/null +++ b/session_6/Assignment4/movies_app/test/widget_test.dart @@ -0,0 +1,30 @@ +// This is a basic Flutter widget test. +// +// To perform an interaction with a widget in your test, use the WidgetTester +// utility that Flutter provides. For example, you can send tap and scroll +// gestures. You can also use WidgetTester to find child widgets in the widget +// tree, read text, and verify that the values of widget properties are correct. + +import 'package:flutter/material.dart'; +import 'package:flutter_test/flutter_test.dart'; + +import 'package:movies_app/main.dart'; + +void main() { + testWidgets('Counter increments smoke test', (WidgetTester tester) async { + // Build our app and trigger a frame. + await tester.pumpWidget(MyApp()); + + // Verify that our counter starts at 0. + expect(find.text('0'), findsOneWidget); + expect(find.text('1'), findsNothing); + + // Tap the '+' icon and trigger a frame. + await tester.tap(find.byIcon(Icons.add)); + await tester.pump(); + + // Verify that our counter has incremented. + expect(find.text('0'), findsNothing); + expect(find.text('1'), findsOneWidget); + }); +} diff --git a/session_6/Assignment4/movies_app/web/favicon.png b/session_6/Assignment4/movies_app/web/favicon.png new file mode 100644 index 00000000..8aaa46ac Binary files /dev/null and b/session_6/Assignment4/movies_app/web/favicon.png differ diff --git a/session_6/Assignment4/movies_app/web/icons/Icon-192.png b/session_6/Assignment4/movies_app/web/icons/Icon-192.png new file mode 100644 index 00000000..b749bfef Binary files /dev/null and b/session_6/Assignment4/movies_app/web/icons/Icon-192.png differ diff --git a/session_6/Assignment4/movies_app/web/icons/Icon-512.png b/session_6/Assignment4/movies_app/web/icons/Icon-512.png new file mode 100644 index 00000000..88cfd48d Binary files /dev/null and b/session_6/Assignment4/movies_app/web/icons/Icon-512.png differ diff --git a/session_6/Assignment4/movies_app/web/icons/Icon-maskable-192.png b/session_6/Assignment4/movies_app/web/icons/Icon-maskable-192.png new file mode 100644 index 00000000..eb9b4d76 Binary files /dev/null and b/session_6/Assignment4/movies_app/web/icons/Icon-maskable-192.png differ diff --git a/session_6/Assignment4/movies_app/web/icons/Icon-maskable-512.png b/session_6/Assignment4/movies_app/web/icons/Icon-maskable-512.png new file mode 100644 index 00000000..d69c5669 Binary files /dev/null and b/session_6/Assignment4/movies_app/web/icons/Icon-maskable-512.png differ diff --git a/session_6/Assignment4/movies_app/web/index.html b/session_6/Assignment4/movies_app/web/index.html new file mode 100644 index 00000000..9376ae8d --- /dev/null +++ b/session_6/Assignment4/movies_app/web/index.html @@ -0,0 +1,104 @@ + + + + + + + + + + + + + + + + + + + + movies_app + + + + + + + diff --git a/session_6/Assignment4/movies_app/web/manifest.json b/session_6/Assignment4/movies_app/web/manifest.json new file mode 100644 index 00000000..605d7654 --- /dev/null +++ b/session_6/Assignment4/movies_app/web/manifest.json @@ -0,0 +1,35 @@ +{ + "name": "movies_app", + "short_name": "movies_app", + "start_url": ".", + "display": "standalone", + "background_color": "#0175C2", + "theme_color": "#0175C2", + "description": "A new Flutter project.", + "orientation": "portrait-primary", + "prefer_related_applications": false, + "icons": [ + { + "src": "icons/Icon-192.png", + "sizes": "192x192", + "type": "image/png" + }, + { + "src": "icons/Icon-512.png", + "sizes": "512x512", + "type": "image/png" + }, + { + "src": "icons/Icon-maskable-192.png", + "sizes": "192x192", + "type": "image/png", + "purpose": "maskable" + }, + { + "src": "icons/Icon-maskable-512.png", + "sizes": "512x512", + "type": "image/png", + "purpose": "maskable" + } + ] +}