├── linux
├── .gitignore
├── main.cc
├── flutter
│ ├── generated_plugin_registrant.cc
│ ├── generated_plugin_registrant.h
│ ├── generated_plugins.cmake
│ └── CMakeLists.txt
├── my_application.h
├── my_application.cc
└── CMakeLists.txt
├── ios
├── Runner
│ ├── Runner-Bridging-Header.h
│ ├── Assets.xcassets
│ │ ├── LaunchImage.imageset
│ │ │ ├── LaunchImage.png
│ │ │ ├── LaunchImage@2x.png
│ │ │ ├── LaunchImage@3x.png
│ │ │ ├── README.md
│ │ │ └── Contents.json
│ │ └── AppIcon.appiconset
│ │ │ ├── ItunesArtwork@2x.png
│ │ │ ├── Icon-App-20x20@1x.png
│ │ │ ├── Icon-App-20x20@2x.png
│ │ │ ├── Icon-App-20x20@3x.png
│ │ │ ├── Icon-App-29x29@1x.png
│ │ │ ├── Icon-App-29x29@2x.png
│ │ │ ├── Icon-App-29x29@3x.png
│ │ │ ├── Icon-App-40x40@1x.png
│ │ │ ├── Icon-App-40x40@2x.png
│ │ │ ├── Icon-App-40x40@3x.png
│ │ │ ├── Icon-App-60x60@2x.png
│ │ │ ├── Icon-App-60x60@3x.png
│ │ │ ├── Icon-App-76x76@1x.png
│ │ │ ├── Icon-App-76x76@2x.png
│ │ │ ├── Icon-App-83.5x83.5@2x.png
│ │ │ └── Contents.json
│ ├── Runner.entitlements
│ ├── AppDelegate.swift
│ ├── GoogleService-Info.plist
│ ├── Base.lproj
│ │ ├── Main.storyboard
│ │ └── LaunchScreen.storyboard
│ └── Info.plist
├── Flutter
│ ├── Debug.xcconfig
│ ├── Release.xcconfig
│ └── AppFrameworkInfo.plist
├── Runner.xcodeproj
│ ├── project.xcworkspace
│ │ ├── contents.xcworkspacedata
│ │ └── xcshareddata
│ │ │ ├── WorkspaceSettings.xcsettings
│ │ │ └── IDEWorkspaceChecks.plist
│ └── xcshareddata
│ │ └── xcschemes
│ │ └── Runner.xcscheme
├── Runner.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ │ ├── WorkspaceSettings.xcsettings
│ │ └── IDEWorkspaceChecks.plist
├── .gitignore
└── Podfile
├── web
├── favicon.png
├── icons
│ ├── Icon-192.png
│ ├── Icon-512.png
│ ├── Icon-maskable-192.png
│ └── Icon-maskable-512.png
├── manifest.json
└── index.html
├── assets
└── images
│ ├── a.jpg
│ ├── b.jpg
│ ├── c.jpg
│ ├── d.jpg
│ ├── launch.jpg
│ ├── pizza.jpg
│ ├── ramen.png
│ └── popcorn.jpg
├── android
├── gradle.properties
├── app
│ ├── src
│ │ ├── main
│ │ │ ├── res
│ │ │ │ ├── mipmap-hdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ ├── mipmap-ldpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ ├── mipmap-mdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ ├── mipmap-xhdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ ├── mipmap-xxhdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ ├── mipmap-xxxhdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ ├── drawable
│ │ │ │ │ └── launch_background.xml
│ │ │ │ ├── drawable-v21
│ │ │ │ │ └── launch_background.xml
│ │ │ │ ├── values
│ │ │ │ │ └── styles.xml
│ │ │ │ └── values-night
│ │ │ │ │ └── styles.xml
│ │ │ ├── kotlin
│ │ │ │ └── com
│ │ │ │ │ └── example
│ │ │ │ │ └── firebase_notes
│ │ │ │ │ └── MainActivity.kt
│ │ │ └── AndroidManifest.xml
│ │ ├── debug
│ │ │ └── AndroidManifest.xml
│ │ └── profile
│ │ │ └── AndroidManifest.xml
│ ├── google-services.json
│ └── build.gradle
├── gradle
│ └── wrapper
│ │ └── gradle-wrapper.properties
├── .gitignore
├── settings.gradle
└── build.gradle
├── macos
├── Runner
│ ├── Configs
│ │ ├── Debug.xcconfig
│ │ ├── Release.xcconfig
│ │ ├── Warnings.xcconfig
│ │ └── AppInfo.xcconfig
│ ├── Assets.xcassets
│ │ └── AppIcon.appiconset
│ │ │ ├── app_icon_128.png
│ │ │ ├── app_icon_16.png
│ │ │ ├── app_icon_256.png
│ │ │ ├── app_icon_32.png
│ │ │ ├── app_icon_512.png
│ │ │ ├── app_icon_64.png
│ │ │ ├── app_icon_1024.png
│ │ │ └── Contents.json
│ ├── AppDelegate.swift
│ ├── Release.entitlements
│ ├── DebugProfile.entitlements
│ ├── MainFlutterWindow.swift
│ └── Info.plist
├── .gitignore
├── Flutter
│ ├── Flutter-Debug.xcconfig
│ ├── Flutter-Release.xcconfig
│ └── GeneratedPluginRegistrant.swift
├── Runner.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── IDEWorkspaceChecks.plist
├── Runner.xcodeproj
│ ├── project.xcworkspace
│ │ └── xcshareddata
│ │ │ └── IDEWorkspaceChecks.plist
│ ├── xcshareddata
│ │ └── xcschemes
│ │ │ └── Runner.xcscheme
│ └── project.pbxproj
└── Podfile
├── windows
├── runner
│ ├── resources
│ │ └── app_icon.ico
│ ├── resource.h
│ ├── CMakeLists.txt
│ ├── utils.h
│ ├── runner.exe.manifest
│ ├── flutter_window.h
│ ├── main.cpp
│ ├── utils.cpp
│ ├── flutter_window.cpp
│ ├── Runner.rc
│ ├── win32_window.h
│ └── win32_window.cpp
├── flutter
│ ├── generated_plugin_registrant.cc
│ ├── generated_plugin_registrant.h
│ ├── generated_plugins.cmake
│ └── CMakeLists.txt
├── .gitignore
└── CMakeLists.txt
├── lib
├── src
│ ├── colors.dart
│ ├── images.dart
│ └── strings.dart
├── constants
│ ├── custom_app_bar.dart
│ └── custom_loading.dart
├── services
│ ├── model
│ │ └── food_model.dart
│ ├── storage_service.dart
│ ├── food_service.dart
│ └── auth_service.dart
├── main.dart
└── views
│ ├── launch
│ └── launch_page.dart
│ ├── home
│ ├── home_page.dart
│ └── food_list_page.dart
│ ├── add_food
│ └── add_food_page.dart
│ ├── login
│ └── login_page.dart
│ └── register
│ └── register_page.dart
├── .metadata
├── .gitignore
├── test
└── widget_test.dart
├── analysis_options.yaml
├── README.md
├── pubspec.yaml
└── pubspec.lock
/linux/.gitignore:
--------------------------------------------------------------------------------
1 | flutter/ephemeral
2 |
--------------------------------------------------------------------------------
/ios/Runner/Runner-Bridging-Header.h:
--------------------------------------------------------------------------------
1 | #import "GeneratedPluginRegistrant.h"
2 |
--------------------------------------------------------------------------------
/web/favicon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/web/favicon.png
--------------------------------------------------------------------------------
/assets/images/a.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/assets/images/a.jpg
--------------------------------------------------------------------------------
/assets/images/b.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/assets/images/b.jpg
--------------------------------------------------------------------------------
/assets/images/c.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/assets/images/c.jpg
--------------------------------------------------------------------------------
/assets/images/d.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/assets/images/d.jpg
--------------------------------------------------------------------------------
/assets/images/launch.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/assets/images/launch.jpg
--------------------------------------------------------------------------------
/assets/images/pizza.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/assets/images/pizza.jpg
--------------------------------------------------------------------------------
/assets/images/ramen.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/assets/images/ramen.png
--------------------------------------------------------------------------------
/web/icons/Icon-192.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/web/icons/Icon-192.png
--------------------------------------------------------------------------------
/web/icons/Icon-512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/web/icons/Icon-512.png
--------------------------------------------------------------------------------
/android/gradle.properties:
--------------------------------------------------------------------------------
1 | org.gradle.jvmargs=-Xmx1536M
2 | android.useAndroidX=true
3 | android.enableJetifier=true
4 |
--------------------------------------------------------------------------------
/assets/images/popcorn.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/assets/images/popcorn.jpg
--------------------------------------------------------------------------------
/macos/Runner/Configs/Debug.xcconfig:
--------------------------------------------------------------------------------
1 | #include "../../Flutter/Flutter-Debug.xcconfig"
2 | #include "Warnings.xcconfig"
3 |
--------------------------------------------------------------------------------
/macos/Runner/Configs/Release.xcconfig:
--------------------------------------------------------------------------------
1 | #include "../../Flutter/Flutter-Release.xcconfig"
2 | #include "Warnings.xcconfig"
3 |
--------------------------------------------------------------------------------
/macos/.gitignore:
--------------------------------------------------------------------------------
1 | # Flutter-related
2 | **/Flutter/ephemeral/
3 | **/Pods/
4 |
5 | # Xcode-related
6 | **/dgph
7 | **/xcuserdata/
8 |
--------------------------------------------------------------------------------
/web/icons/Icon-maskable-192.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/web/icons/Icon-maskable-192.png
--------------------------------------------------------------------------------
/web/icons/Icon-maskable-512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/web/icons/Icon-maskable-512.png
--------------------------------------------------------------------------------
/ios/Flutter/Debug.xcconfig:
--------------------------------------------------------------------------------
1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
2 | #include "Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/ios/Flutter/Release.xcconfig:
--------------------------------------------------------------------------------
1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
2 | #include "Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/windows/runner/resources/app_icon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/windows/runner/resources/app_icon.ico
--------------------------------------------------------------------------------
/macos/Flutter/Flutter-Debug.xcconfig:
--------------------------------------------------------------------------------
1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
2 | #include "ephemeral/Flutter-Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/macos/Flutter/Flutter-Release.xcconfig:
--------------------------------------------------------------------------------
1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
2 | #include "ephemeral/Flutter-Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-ldpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/android/app/src/main/res/mipmap-ldpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png
--------------------------------------------------------------------------------
/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png
--------------------------------------------------------------------------------
/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png
--------------------------------------------------------------------------------
/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png
--------------------------------------------------------------------------------
/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png
--------------------------------------------------------------------------------
/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png
--------------------------------------------------------------------------------
/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/ItunesArtwork@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/ItunesArtwork@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png
--------------------------------------------------------------------------------
/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/KadriyeMacit/Flutter-Fest-Firebase/HEAD/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png
--------------------------------------------------------------------------------
/linux/main.cc:
--------------------------------------------------------------------------------
1 | #include "my_application.h"
2 |
3 | int main(int argc, char** argv) {
4 | g_autoptr(MyApplication) app = my_application_new();
5 | return g_application_run(G_APPLICATION(app), argc, argv);
6 | }
7 |
--------------------------------------------------------------------------------
/android/app/src/main/kotlin/com/example/firebase_notes/MainActivity.kt:
--------------------------------------------------------------------------------
1 | package com.example.firebase_notes
2 |
3 | import io.flutter.embedding.android.FlutterActivity
4 |
5 | class MainActivity: FlutterActivity() {
6 | }
7 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/macos/Runner.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/linux/flutter/generated_plugin_registrant.cc:
--------------------------------------------------------------------------------
1 | //
2 | // Generated file. Do not edit.
3 | //
4 |
5 | // clang-format off
6 |
7 | #include "generated_plugin_registrant.h"
8 |
9 |
10 | void fl_register_plugins(FlPluginRegistry* registry) {
11 | }
12 |
--------------------------------------------------------------------------------
/windows/flutter/generated_plugin_registrant.cc:
--------------------------------------------------------------------------------
1 | //
2 | // Generated file. Do not edit.
3 | //
4 |
5 | // clang-format off
6 |
7 | #include "generated_plugin_registrant.h"
8 |
9 |
10 | void RegisterPlugins(flutter::PluginRegistry* registry) {
11 | }
12 |
--------------------------------------------------------------------------------
/macos/Runner/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | import Cocoa
2 | import FlutterMacOS
3 |
4 | @NSApplicationMain
5 | class AppDelegate: FlutterAppDelegate {
6 | override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool {
7 | return true
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Fri Jun 23 08:50:38 CEST 2017
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip
7 |
--------------------------------------------------------------------------------
/ios/Runner/Runner.entitlements:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | aps-environment
6 | development
7 |
8 |
9 |
--------------------------------------------------------------------------------
/macos/Runner/Release.entitlements:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | com.apple.security.app-sandbox
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PreviewsEnabled
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PreviewsEnabled
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/lib/src/colors.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 |
3 | class DietColors {
4 | static Color mainColor = Colors.grey.shade200;
5 | static Color orange = Colors.orange;
6 | static Color white = Colors.white;
7 | static Color black = Colors.black;
8 | static Color red = Colors.red;
9 |
10 | DietColors._();
11 | }
12 |
--------------------------------------------------------------------------------
/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/.metadata:
--------------------------------------------------------------------------------
1 | # This file tracks properties of this Flutter project.
2 | # Used by Flutter tool to assess capabilities and perform upgrades etc.
3 | #
4 | # This file should be version controlled and should not be manually edited.
5 |
6 | version:
7 | revision: 77d935af4db863f6abd0b9c31c7e6df2a13de57b
8 | channel: stable
9 |
10 | project_type: app
11 |
--------------------------------------------------------------------------------
/android/.gitignore:
--------------------------------------------------------------------------------
1 | gradle-wrapper.jar
2 | /.gradle
3 | /captures/
4 | /gradlew
5 | /gradlew.bat
6 | /local.properties
7 | GeneratedPluginRegistrant.java
8 |
9 | # Remember to never publicly share your keystore.
10 | # See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
11 | key.properties
12 | **/*.keystore
13 | **/*.jks
14 |
--------------------------------------------------------------------------------
/windows/.gitignore:
--------------------------------------------------------------------------------
1 | flutter/ephemeral/
2 |
3 | # Visual Studio user-specific files.
4 | *.suo
5 | *.user
6 | *.userosscache
7 | *.sln.docstates
8 |
9 | # Visual Studio build-related files.
10 | x64/
11 | x86/
12 |
13 | # Visual Studio cache files
14 | # files ending in .cache can be ignored
15 | *.[Cc]ache
16 | # but keep track of directories ending in .cache
17 | !*.[Cc]ache/
18 |
--------------------------------------------------------------------------------
/android/app/src/debug/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/android/app/src/profile/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md:
--------------------------------------------------------------------------------
1 | # Launch Screen Assets
2 |
3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory.
4 |
5 | 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.
--------------------------------------------------------------------------------
/linux/flutter/generated_plugin_registrant.h:
--------------------------------------------------------------------------------
1 | //
2 | // Generated file. Do not edit.
3 | //
4 |
5 | // clang-format off
6 |
7 | #ifndef GENERATED_PLUGIN_REGISTRANT_
8 | #define GENERATED_PLUGIN_REGISTRANT_
9 |
10 | #include
11 |
12 | // Registers Flutter plugins.
13 | void fl_register_plugins(FlPluginRegistry* registry);
14 |
15 | #endif // GENERATED_PLUGIN_REGISTRANT_
16 |
--------------------------------------------------------------------------------
/windows/flutter/generated_plugin_registrant.h:
--------------------------------------------------------------------------------
1 | //
2 | // Generated file. Do not edit.
3 | //
4 |
5 | // clang-format off
6 |
7 | #ifndef GENERATED_PLUGIN_REGISTRANT_
8 | #define GENERATED_PLUGIN_REGISTRANT_
9 |
10 | #include
11 |
12 | // Registers Flutter plugins.
13 | void RegisterPlugins(flutter::PluginRegistry* registry);
14 |
15 | #endif // GENERATED_PLUGIN_REGISTRANT_
16 |
--------------------------------------------------------------------------------
/macos/Runner/DebugProfile.entitlements:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | com.apple.security.app-sandbox
6 |
7 | com.apple.security.cs.allow-jit
8 |
9 | com.apple.security.network.server
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/lib/constants/custom_app_bar.dart:
--------------------------------------------------------------------------------
1 | import 'package:firebase_notes/src/colors.dart';
2 | import 'package:flutter/material.dart';
3 |
4 | class CustomAppBar extends AppBar {
5 | CustomAppBar(
6 | String title, {
7 | Key? key,
8 | }) : super(
9 | key: key,
10 | backgroundColor: DietColors.orange,
11 | title: Text(
12 | title,
13 | ),
14 | elevation: 0.0,
15 | );
16 | }
17 |
--------------------------------------------------------------------------------
/lib/constants/custom_loading.dart:
--------------------------------------------------------------------------------
1 | import 'package:firebase_notes/src/colors.dart';
2 | import 'package:flutter/material.dart';
3 |
4 | class CustomLoading extends StatelessWidget {
5 | const CustomLoading({Key? key}) : super(key: key);
6 |
7 | @override
8 | Widget build(BuildContext context) {
9 | return Center(
10 | child: CircularProgressIndicator(
11 | color: DietColors.orange,
12 | ),
13 | );
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/lib/services/model/food_model.dart:
--------------------------------------------------------------------------------
1 | import 'package:cloud_firestore/cloud_firestore.dart';
2 |
3 | class Food {
4 | String id;
5 | String food;
6 | String image;
7 |
8 | Food({required this.id, required this.food, required this.image});
9 |
10 | factory Food.fromSnapshot(DocumentSnapshot snapshot) {
11 | return Food(
12 | id: snapshot.id,
13 | food: snapshot["food"],
14 | image: snapshot["image"],
15 | );
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/linux/my_application.h:
--------------------------------------------------------------------------------
1 | #ifndef FLUTTER_MY_APPLICATION_H_
2 | #define FLUTTER_MY_APPLICATION_H_
3 |
4 | #include
5 |
6 | G_DECLARE_FINAL_TYPE(MyApplication, my_application, MY, APPLICATION,
7 | GtkApplication)
8 |
9 | /**
10 | * my_application_new:
11 | *
12 | * Creates a new Flutter-based application.
13 | *
14 | * Returns: a new #MyApplication.
15 | */
16 | MyApplication* my_application_new();
17 |
18 | #endif // FLUTTER_MY_APPLICATION_H_
19 |
--------------------------------------------------------------------------------
/lib/src/images.dart:
--------------------------------------------------------------------------------
1 | class DietImages {
2 | static String launchImage = 'assets/images/launch.jpg';
3 | static String pizza = 'assets/images/pizza.jpg';
4 | static String ramen = 'assets/images/ramen.png';
5 | static String popcorn = 'assets/images/popcorn.jpg';
6 | static String a = 'assets/images/a.jpg';
7 | static String b = 'assets/images/b.jpg';
8 | static String c = 'assets/images/c.jpg';
9 | static String d = 'assets/images/d.jpg';
10 |
11 | DietImages._();
12 | }
13 |
--------------------------------------------------------------------------------
/macos/Runner/MainFlutterWindow.swift:
--------------------------------------------------------------------------------
1 | import Cocoa
2 | import FlutterMacOS
3 |
4 | class MainFlutterWindow: NSWindow {
5 | override func awakeFromNib() {
6 | let flutterViewController = FlutterViewController.init()
7 | let windowFrame = self.frame
8 | self.contentViewController = flutterViewController
9 | self.setFrame(windowFrame, display: true)
10 |
11 | RegisterGeneratedPlugins(registry: flutterViewController)
12 |
13 | super.awakeFromNib()
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/windows/runner/resource.h:
--------------------------------------------------------------------------------
1 | //{{NO_DEPENDENCIES}}
2 | // Microsoft Visual C++ generated include file.
3 | // Used by Runner.rc
4 | //
5 | #define IDI_APP_ICON 101
6 |
7 | // Next default values for new objects
8 | //
9 | #ifdef APSTUDIO_INVOKED
10 | #ifndef APSTUDIO_READONLY_SYMBOLS
11 | #define _APS_NEXT_RESOURCE_VALUE 102
12 | #define _APS_NEXT_COMMAND_VALUE 40001
13 | #define _APS_NEXT_CONTROL_VALUE 1001
14 | #define _APS_NEXT_SYMED_VALUE 101
15 | #endif
16 | #endif
17 |
--------------------------------------------------------------------------------
/android/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app'
2 |
3 | def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
4 | def properties = new Properties()
5 |
6 | assert localPropertiesFile.exists()
7 | localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) }
8 |
9 | def flutterSdkPath = properties.getProperty("flutter.sdk")
10 | assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
11 | apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle"
12 |
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable/launch_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
12 |
13 |
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable-v21/launch_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
12 |
13 |
--------------------------------------------------------------------------------
/ios/Runner/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | import UIKit
2 | import Flutter
3 | import Firebase
4 |
5 | @UIApplicationMain
6 | @objc class AppDelegate: FlutterAppDelegate {
7 | override func application(
8 | _ application: UIApplication,
9 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
10 | ) -> Bool {
11 | GeneratedPluginRegistrant.register(with: self)
12 | //FirebaseApp.configure()
13 | return super.application(application, didFinishLaunchingWithOptions: launchOptions)
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "universal",
5 | "filename" : "LaunchImage.png",
6 | "scale" : "1x"
7 | },
8 | {
9 | "idiom" : "universal",
10 | "filename" : "LaunchImage@2x.png",
11 | "scale" : "2x"
12 | },
13 | {
14 | "idiom" : "universal",
15 | "filename" : "LaunchImage@3x.png",
16 | "scale" : "3x"
17 | }
18 | ],
19 | "info" : {
20 | "version" : 1,
21 | "author" : "xcode"
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/linux/flutter/generated_plugins.cmake:
--------------------------------------------------------------------------------
1 | #
2 | # Generated file, do not edit.
3 | #
4 |
5 | list(APPEND FLUTTER_PLUGIN_LIST
6 | )
7 |
8 | set(PLUGIN_BUNDLED_LIBRARIES)
9 |
10 | foreach(plugin ${FLUTTER_PLUGIN_LIST})
11 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin})
12 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin)
13 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $)
14 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries})
15 | endforeach(plugin)
16 |
--------------------------------------------------------------------------------
/windows/flutter/generated_plugins.cmake:
--------------------------------------------------------------------------------
1 | #
2 | # Generated file, do not edit.
3 | #
4 |
5 | list(APPEND FLUTTER_PLUGIN_LIST
6 | )
7 |
8 | set(PLUGIN_BUNDLED_LIBRARIES)
9 |
10 | foreach(plugin ${FLUTTER_PLUGIN_LIST})
11 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin})
12 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin)
13 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $)
14 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries})
15 | endforeach(plugin)
16 |
--------------------------------------------------------------------------------
/lib/services/storage_service.dart:
--------------------------------------------------------------------------------
1 | import 'dart:io';
2 | import 'package:firebase_storage/firebase_storage.dart';
3 |
4 | class StorageService {
5 | final FirebaseStorage _firebaseStorage = FirebaseStorage.instance;
6 |
7 | Future uploadMedia(File file) async {
8 | var uploadTask = _firebaseStorage
9 | .ref()
10 | .child(
11 | "${DateTime.now().millisecondsSinceEpoch}.${file.path.split('.').last}")
12 | .putFile(file);
13 |
14 | uploadTask.snapshotEvents.listen((event) {});
15 |
16 | var storageRef = await uploadTask;
17 |
18 | return await storageRef.ref.getDownloadURL();
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/macos/Runner/Configs/Warnings.xcconfig:
--------------------------------------------------------------------------------
1 | WARNING_CFLAGS = -Wall -Wconditional-uninitialized -Wnullable-to-nonnull-conversion -Wmissing-method-return-type -Woverlength-strings
2 | GCC_WARN_UNDECLARED_SELECTOR = YES
3 | CLANG_UNDEFINED_BEHAVIOR_SANITIZER_NULLABILITY = YES
4 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE
5 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES
6 | CLANG_WARN_PRAGMA_PACK = YES
7 | CLANG_WARN_STRICT_PROTOTYPES = YES
8 | CLANG_WARN_COMMA = YES
9 | GCC_WARN_STRICT_SELECTOR_MATCH = YES
10 | CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES
11 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES
12 | GCC_WARN_SHADOW = YES
13 | CLANG_WARN_UNREACHABLE_CODE = YES
14 |
--------------------------------------------------------------------------------
/windows/runner/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.14)
2 | project(runner LANGUAGES CXX)
3 |
4 | add_executable(${BINARY_NAME} WIN32
5 | "flutter_window.cpp"
6 | "main.cpp"
7 | "utils.cpp"
8 | "win32_window.cpp"
9 | "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc"
10 | "Runner.rc"
11 | "runner.exe.manifest"
12 | )
13 | apply_standard_settings(${BINARY_NAME})
14 | target_compile_definitions(${BINARY_NAME} PRIVATE "NOMINMAX")
15 | target_link_libraries(${BINARY_NAME} PRIVATE flutter flutter_wrapper_app)
16 | target_include_directories(${BINARY_NAME} PRIVATE "${CMAKE_SOURCE_DIR}")
17 | add_dependencies(${BINARY_NAME} flutter_assemble)
18 |
--------------------------------------------------------------------------------
/macos/Runner/Configs/AppInfo.xcconfig:
--------------------------------------------------------------------------------
1 | // Application-level settings for the Runner target.
2 | //
3 | // This may be replaced with something auto-generated from metadata (e.g., pubspec.yaml) in the
4 | // future. If not, the values below would default to using the project name when this becomes a
5 | // 'flutter create' template.
6 |
7 | // The application's name. By default this is also the title of the Flutter window.
8 | PRODUCT_NAME = firebase_notes
9 |
10 | // The application's bundle identifier
11 | PRODUCT_BUNDLE_IDENTIFIER = com.example.firebaseNotes
12 |
13 | // The copyright displayed in application information
14 | PRODUCT_COPYRIGHT = Copyright © 2022 com.example. All rights reserved.
15 |
--------------------------------------------------------------------------------
/ios/.gitignore:
--------------------------------------------------------------------------------
1 | **/dgph
2 | *.mode1v3
3 | *.mode2v3
4 | *.moved-aside
5 | *.pbxuser
6 | *.perspectivev3
7 | **/*sync/
8 | .sconsign.dblite
9 | .tags*
10 | **/.vagrant/
11 | **/DerivedData/
12 | Icon?
13 | **/Pods/
14 | **/.symlinks/
15 | profile
16 | xcuserdata
17 | **/.generated/
18 | Flutter/App.framework
19 | Flutter/Flutter.framework
20 | Flutter/Flutter.podspec
21 | Flutter/Generated.xcconfig
22 | Flutter/ephemeral/
23 | Flutter/app.flx
24 | Flutter/app.zip
25 | Flutter/flutter_assets/
26 | Flutter/flutter_export_environment.sh
27 | ServiceDefinitions.json
28 | Runner/GeneratedPluginRegistrant.*
29 |
30 | # Exceptions to above rules.
31 | !default.mode1v3
32 | !default.mode2v3
33 | !default.pbxuser
34 | !default.perspectivev3
35 |
--------------------------------------------------------------------------------
/windows/runner/utils.h:
--------------------------------------------------------------------------------
1 | #ifndef RUNNER_UTILS_H_
2 | #define RUNNER_UTILS_H_
3 |
4 | #include
5 | #include
6 |
7 | // Creates a console for the process, and redirects stdout and stderr to
8 | // it for both the runner and the Flutter library.
9 | void CreateAndAttachConsole();
10 |
11 | // Takes a null-terminated wchar_t* encoded in UTF-16 and returns a std::string
12 | // encoded in UTF-8. Returns an empty std::string on failure.
13 | std::string Utf8FromUtf16(const wchar_t* utf16_string);
14 |
15 | // Gets the command line arguments passed in as a std::vector,
16 | // encoded in UTF-8. Returns an empty std::vector on failure.
17 | std::vector GetCommandLineArguments();
18 |
19 | #endif // RUNNER_UTILS_H_
20 |
--------------------------------------------------------------------------------
/android/build.gradle:
--------------------------------------------------------------------------------
1 | buildscript {
2 | ext.kotlin_version = '1.3.50'
3 | repositories {
4 | google()
5 | mavenCentral()
6 | }
7 |
8 | dependencies {
9 | classpath 'com.android.tools.build:gradle:4.1.0'
10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
11 | classpath 'com.google.gms:google-services:4.3.10'
12 | classpath 'com.google.firebase:firebase-crashlytics-gradle:2.8.1'
13 | }
14 | }
15 |
16 | allprojects {
17 | repositories {
18 | google()
19 | mavenCentral()
20 | }
21 | }
22 |
23 | rootProject.buildDir = '../build'
24 | subprojects {
25 | project.buildDir = "${rootProject.buildDir}/${project.name}"
26 | }
27 | subprojects {
28 | project.evaluationDependsOn(':app')
29 | }
30 |
31 | task clean(type: Delete) {
32 | delete rootProject.buildDir
33 | }
34 |
--------------------------------------------------------------------------------
/ios/Flutter/AppFrameworkInfo.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | App
9 | CFBundleIdentifier
10 | io.flutter.flutter.app
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | App
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1.0
23 | MinimumOSVersion
24 | 9.0
25 |
26 |
27 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Miscellaneous
2 | *.class
3 | *.log
4 | *.pyc
5 | *.swp
6 | .DS_Store
7 | .atom/
8 | .buildlog/
9 | .history
10 | .svn/
11 |
12 | # IntelliJ related
13 | *.iml
14 | *.ipr
15 | *.iws
16 | .idea/
17 |
18 | # The .vscode folder contains launch configuration and tasks you configure in
19 | # VS Code which you may wish to be included in version control, so this line
20 | # is commented out by default.
21 | #.vscode/
22 |
23 | # Flutter/Dart/Pub related
24 | **/doc/api/
25 | **/ios/Flutter/.last_build_id
26 | .dart_tool/
27 | .flutter-plugins
28 | .flutter-plugins-dependencies
29 | .packages
30 | .pub-cache/
31 | .pub/
32 | /build/
33 |
34 | # Web related
35 | lib/generated_plugin_registrant.dart
36 |
37 | # Symbolication related
38 | app.*.symbols
39 |
40 | # Obfuscation related
41 | app.*.map.json
42 |
43 | # Android Studio will place build artifacts here
44 | /android/app/debug
45 | /android/app/profile
46 | /android/app/release
47 |
--------------------------------------------------------------------------------
/windows/runner/runner.exe.manifest:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PerMonitorV2
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/macos/Flutter/GeneratedPluginRegistrant.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Generated file. Do not edit.
3 | //
4 |
5 | import FlutterMacOS
6 | import Foundation
7 |
8 | import cloud_firestore
9 | import firebase_auth
10 | import firebase_core
11 | import firebase_crashlytics
12 | import firebase_messaging
13 | import firebase_storage
14 |
15 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
16 | FLTFirebaseFirestorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseFirestorePlugin"))
17 | FLTFirebaseAuthPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseAuthPlugin"))
18 | FLTFirebaseCorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseCorePlugin"))
19 | FLTFirebaseCrashlyticsPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseCrashlyticsPlugin"))
20 | FLTFirebaseMessagingPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseMessagingPlugin"))
21 | FLTFirebaseStoragePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseStoragePlugin"))
22 | }
23 |
--------------------------------------------------------------------------------
/android/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
9 |
15 |
18 |
19 |
--------------------------------------------------------------------------------
/web/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "firebase_notes",
3 | "short_name": "firebase_notes",
4 | "start_url": ".",
5 | "display": "standalone",
6 | "background_color": "#0175C2",
7 | "theme_color": "#0175C2",
8 | "description": "A new Flutter project.",
9 | "orientation": "portrait-primary",
10 | "prefer_related_applications": false,
11 | "icons": [
12 | {
13 | "src": "icons/Icon-192.png",
14 | "sizes": "192x192",
15 | "type": "image/png"
16 | },
17 | {
18 | "src": "icons/Icon-512.png",
19 | "sizes": "512x512",
20 | "type": "image/png"
21 | },
22 | {
23 | "src": "icons/Icon-maskable-192.png",
24 | "sizes": "192x192",
25 | "type": "image/png",
26 | "purpose": "maskable"
27 | },
28 | {
29 | "src": "icons/Icon-maskable-512.png",
30 | "sizes": "512x512",
31 | "type": "image/png",
32 | "purpose": "maskable"
33 | }
34 | ]
35 | }
36 |
--------------------------------------------------------------------------------
/android/app/src/main/res/values-night/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
9 |
15 |
18 |
19 |
--------------------------------------------------------------------------------
/windows/runner/flutter_window.h:
--------------------------------------------------------------------------------
1 | #ifndef RUNNER_FLUTTER_WINDOW_H_
2 | #define RUNNER_FLUTTER_WINDOW_H_
3 |
4 | #include
5 | #include
6 |
7 | #include
8 |
9 | #include "win32_window.h"
10 |
11 | // A window that does nothing but host a Flutter view.
12 | class FlutterWindow : public Win32Window {
13 | public:
14 | // Creates a new FlutterWindow hosting a Flutter view running |project|.
15 | explicit FlutterWindow(const flutter::DartProject& project);
16 | virtual ~FlutterWindow();
17 |
18 | protected:
19 | // Win32Window:
20 | bool OnCreate() override;
21 | void OnDestroy() override;
22 | LRESULT MessageHandler(HWND window, UINT const message, WPARAM const wparam,
23 | LPARAM const lparam) noexcept override;
24 |
25 | private:
26 | // The project to run.
27 | flutter::DartProject project_;
28 |
29 | // The Flutter instance hosted by this window.
30 | std::unique_ptr flutter_controller_;
31 | };
32 |
33 | #endif // RUNNER_FLUTTER_WINDOW_H_
34 |
--------------------------------------------------------------------------------
/lib/services/food_service.dart:
--------------------------------------------------------------------------------
1 | import 'dart:io';
2 |
3 | import 'package:cloud_firestore/cloud_firestore.dart';
4 | import 'package:firebase_notes/services/model/food_model.dart';
5 | import 'package:firebase_notes/services/storage_service.dart';
6 | import 'package:image_picker/image_picker.dart';
7 |
8 | class FoodService {
9 | final FirebaseFirestore _firestore = FirebaseFirestore.instance;
10 | final StorageService _storageService = StorageService();
11 | String _mediaUrl = '';
12 |
13 | Future addFood(String food, XFile pickedFile) async {
14 | var ref = _firestore.collection("Food");
15 |
16 | _mediaUrl = await _storageService.uploadMedia(File(pickedFile.path));
17 |
18 | var documentRef = await ref.add({'food': food, 'image': _mediaUrl});
19 |
20 | return Food(id: documentRef.id, food: food, image: _mediaUrl);
21 | }
22 |
23 | Stream getFood() {
24 | var ref = _firestore.collection("Food").snapshots();
25 |
26 | return ref;
27 | }
28 |
29 | Future removeFood(String docId) {
30 | var ref = _firestore.collection("Food").doc(docId).delete();
31 |
32 | return ref;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/lib/main.dart:
--------------------------------------------------------------------------------
1 | import 'package:firebase_core/firebase_core.dart';
2 | import 'package:firebase_messaging/firebase_messaging.dart';
3 | import 'package:firebase_notes/views/launch/launch_page.dart';
4 | import 'package:flutter/material.dart';
5 |
6 | void main() async {
7 | WidgetsFlutterBinding.ensureInitialized();
8 | await Firebase.initializeApp();
9 |
10 | runApp(const MyApp());
11 | }
12 |
13 | class MyApp extends StatefulWidget {
14 | const MyApp({Key? key}) : super(key: key);
15 |
16 | @override
17 | State createState() => _MyAppState();
18 | }
19 |
20 | class _MyAppState extends State {
21 | final FirebaseMessaging _firebaseMessaging = FirebaseMessaging.instance;
22 |
23 | @override
24 | void initState() {
25 | _firebaseMessaging.getToken().then((value) {
26 | print("Firebase token: $value");
27 | });
28 |
29 | _firebaseMessaging.requestPermission();
30 | super.initState();
31 | }
32 |
33 | @override
34 | Widget build(BuildContext context) {
35 | return const MaterialApp(
36 | debugShowCheckedModeBanner: false,
37 | title: 'Diyet Planım',
38 | home: LaunchPage(),
39 | );
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/test/widget_test.dart:
--------------------------------------------------------------------------------
1 | // This is a basic Flutter widget test.
2 | //
3 | // To perform an interaction with a widget in your test, use the WidgetTester
4 | // utility that Flutter provides. For example, you can send tap and scroll
5 | // gestures. You can also use WidgetTester to find child widgets in the widget
6 | // tree, read text, and verify that the values of widget properties are correct.
7 |
8 | import 'package:flutter/material.dart';
9 | import 'package:flutter_test/flutter_test.dart';
10 |
11 | import 'package:firebase_notes/main.dart';
12 |
13 | void main() {
14 | testWidgets('Counter increments smoke test', (WidgetTester tester) async {
15 | // Build our app and trigger a frame.
16 | await tester.pumpWidget(const MyApp());
17 |
18 | // Verify that our counter starts at 0.
19 | expect(find.text('0'), findsOneWidget);
20 | expect(find.text('1'), findsNothing);
21 |
22 | // Tap the '+' icon and trigger a frame.
23 | await tester.tap(find.byIcon(Icons.add));
24 | await tester.pump();
25 |
26 | // Verify that our counter has incremented.
27 | expect(find.text('0'), findsNothing);
28 | expect(find.text('1'), findsOneWidget);
29 | });
30 | }
31 |
--------------------------------------------------------------------------------
/macos/Runner/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIconFile
10 |
11 | CFBundleIdentifier
12 | $(PRODUCT_BUNDLE_IDENTIFIER)
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | $(PRODUCT_NAME)
17 | CFBundlePackageType
18 | APPL
19 | CFBundleShortVersionString
20 | $(FLUTTER_BUILD_NAME)
21 | CFBundleVersion
22 | $(FLUTTER_BUILD_NUMBER)
23 | LSMinimumSystemVersion
24 | $(MACOSX_DEPLOYMENT_TARGET)
25 | NSHumanReadableCopyright
26 | $(PRODUCT_COPYRIGHT)
27 | NSMainNibFile
28 | MainMenu
29 | NSPrincipalClass
30 | NSApplication
31 |
32 |
33 |
--------------------------------------------------------------------------------
/ios/Runner/GoogleService-Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CLIENT_ID
6 | 970457623410-tiduhgvsuj52svr4j4sbhdadsra2fuo5.apps.googleusercontent.com
7 | REVERSED_CLIENT_ID
8 | com.googleusercontent.apps.970457623410-tiduhgvsuj52svr4j4sbhdadsra2fuo5
9 | API_KEY
10 | AIzaSyBWFpQ893Ejf6PorSIgBquiLtiwAddMfMU
11 | GCM_SENDER_ID
12 | 970457623410
13 | PLIST_VERSION
14 | 1
15 | BUNDLE_ID
16 | com.example.firebaseNotes
17 | PROJECT_ID
18 | flutter-fest-e4cdc
19 | STORAGE_BUCKET
20 | flutter-fest-e4cdc.appspot.com
21 | IS_ADS_ENABLED
22 |
23 | IS_ANALYTICS_ENABLED
24 |
25 | IS_APPINVITE_ENABLED
26 |
27 | IS_GCM_ENABLED
28 |
29 | IS_SIGNIN_ENABLED
30 |
31 | GOOGLE_APP_ID
32 | 1:970457623410:ios:202f5a8315dd4a118f4beb
33 |
34 |
--------------------------------------------------------------------------------
/windows/runner/main.cpp:
--------------------------------------------------------------------------------
1 | #include
2 | #include
3 | #include
4 |
5 | #include "flutter_window.h"
6 | #include "utils.h"
7 |
8 | int APIENTRY wWinMain(_In_ HINSTANCE instance, _In_opt_ HINSTANCE prev,
9 | _In_ wchar_t *command_line, _In_ int show_command) {
10 | // Attach to console when present (e.g., 'flutter run') or create a
11 | // new console when running with a debugger.
12 | if (!::AttachConsole(ATTACH_PARENT_PROCESS) && ::IsDebuggerPresent()) {
13 | CreateAndAttachConsole();
14 | }
15 |
16 | // Initialize COM, so that it is available for use in the library and/or
17 | // plugins.
18 | ::CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED);
19 |
20 | flutter::DartProject project(L"data");
21 |
22 | std::vector command_line_arguments =
23 | GetCommandLineArguments();
24 |
25 | project.set_dart_entrypoint_arguments(std::move(command_line_arguments));
26 |
27 | FlutterWindow window(project);
28 | Win32Window::Point origin(10, 10);
29 | Win32Window::Size size(1280, 720);
30 | if (!window.CreateAndShow(L"firebase_notes", origin, size)) {
31 | return EXIT_FAILURE;
32 | }
33 | window.SetQuitOnClose(true);
34 |
35 | ::MSG msg;
36 | while (::GetMessage(&msg, nullptr, 0, 0)) {
37 | ::TranslateMessage(&msg);
38 | ::DispatchMessage(&msg);
39 | }
40 |
41 | ::CoUninitialize();
42 | return EXIT_SUCCESS;
43 | }
44 |
--------------------------------------------------------------------------------
/android/app/google-services.json:
--------------------------------------------------------------------------------
1 | {
2 | "project_info": {
3 | "project_number": "970457623410",
4 | "project_id": "flutter-fest-e4cdc",
5 | "storage_bucket": "flutter-fest-e4cdc.appspot.com"
6 | },
7 | "client": [
8 | {
9 | "client_info": {
10 | "mobilesdk_app_id": "1:970457623410:android:6c49379fc001a6c48f4beb",
11 | "android_client_info": {
12 | "package_name": "com.example.firebase_notes"
13 | }
14 | },
15 | "oauth_client": [
16 | {
17 | "client_id": "970457623410-kss133i0ra3q89sfkkpeseh8omvhr8qd.apps.googleusercontent.com",
18 | "client_type": 3
19 | }
20 | ],
21 | "api_key": [
22 | {
23 | "current_key": "AIzaSyCOG_67wYVZLi_oiIff254qXGWUZ6ylchE"
24 | }
25 | ],
26 | "services": {
27 | "appinvite_service": {
28 | "other_platform_oauth_client": [
29 | {
30 | "client_id": "970457623410-kss133i0ra3q89sfkkpeseh8omvhr8qd.apps.googleusercontent.com",
31 | "client_type": 3
32 | },
33 | {
34 | "client_id": "970457623410-tiduhgvsuj52svr4j4sbhdadsra2fuo5.apps.googleusercontent.com",
35 | "client_type": 2,
36 | "ios_info": {
37 | "bundle_id": "com.example.firebaseNotes"
38 | }
39 | }
40 | ]
41 | }
42 | }
43 | }
44 | ],
45 | "configuration_version": "1"
46 | }
--------------------------------------------------------------------------------
/macos/Podfile:
--------------------------------------------------------------------------------
1 | platform :osx, '10.11'
2 |
3 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency.
4 | ENV['COCOAPODS_DISABLE_STATS'] = 'true'
5 |
6 | project 'Runner', {
7 | 'Debug' => :debug,
8 | 'Profile' => :release,
9 | 'Release' => :release,
10 | }
11 |
12 | def flutter_root
13 | generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'ephemeral', 'Flutter-Generated.xcconfig'), __FILE__)
14 | unless File.exist?(generated_xcode_build_settings_path)
15 | raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure \"flutter pub get\" is executed first"
16 | end
17 |
18 | File.foreach(generated_xcode_build_settings_path) do |line|
19 | matches = line.match(/FLUTTER_ROOT\=(.*)/)
20 | return matches[1].strip if matches
21 | end
22 | raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Flutter-Generated.xcconfig, then run \"flutter pub get\""
23 | end
24 |
25 | require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
26 |
27 | flutter_macos_podfile_setup
28 |
29 | target 'Runner' do
30 | use_frameworks!
31 | use_modular_headers!
32 |
33 | flutter_install_all_macos_pods File.dirname(File.realpath(__FILE__))
34 | end
35 |
36 | post_install do |installer|
37 | installer.pods_project.targets.each do |target|
38 | flutter_additional_macos_build_settings(target)
39 | end
40 | end
41 |
--------------------------------------------------------------------------------
/ios/Podfile:
--------------------------------------------------------------------------------
1 | # Uncomment this line to define a global platform for your project
2 | platform :ios, '10.0'
3 |
4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency.
5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true'
6 |
7 | project 'Runner', {
8 | 'Debug' => :debug,
9 | 'Profile' => :release,
10 | 'Release' => :release,
11 | }
12 |
13 | def flutter_root
14 | generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__)
15 | unless File.exist?(generated_xcode_build_settings_path)
16 | raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
17 | end
18 |
19 | File.foreach(generated_xcode_build_settings_path) do |line|
20 | matches = line.match(/FLUTTER_ROOT\=(.*)/)
21 | return matches[1].strip if matches
22 | end
23 | raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get"
24 | end
25 |
26 | require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
27 |
28 | flutter_ios_podfile_setup
29 |
30 | target 'Runner' do
31 | use_frameworks!
32 | use_modular_headers!
33 |
34 | flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
35 | end
36 |
37 | post_install do |installer|
38 | installer.pods_project.targets.each do |target|
39 | flutter_additional_ios_build_settings(target)
40 | end
41 | end
42 |
--------------------------------------------------------------------------------
/analysis_options.yaml:
--------------------------------------------------------------------------------
1 | # This file configures the analyzer, which statically analyzes Dart code to
2 | # check for errors, warnings, and lints.
3 | #
4 | # The issues identified by the analyzer are surfaced in the UI of Dart-enabled
5 | # IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
6 | # invoked from the command line by running `flutter analyze`.
7 |
8 | # The following line activates a set of recommended lints for Flutter apps,
9 | # packages, and plugins designed to encourage good coding practices.
10 | include: package:flutter_lints/flutter.yaml
11 |
12 | linter:
13 | # The lint rules applied to this project can be customized in the
14 | # section below to disable rules from the `package:flutter_lints/flutter.yaml`
15 | # included above or to enable additional rules. A list of all available lints
16 | # and their documentation is published at
17 | # https://dart-lang.github.io/linter/lints/index.html.
18 | #
19 | # Instead of disabling a lint rule for the entire project in the
20 | # section below, it can also be suppressed for a single line of code
21 | # or a specific dart file by using the `// ignore: name_of_lint` and
22 | # `// ignore_for_file: name_of_lint` syntax on the line or in the file
23 | # producing the lint.
24 | rules:
25 | # avoid_print: false # Uncomment to disable the `avoid_print` rule
26 | # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule
27 |
28 | # Additional information about this file can be found at
29 | # https://dart.dev/guides/language/analysis-options
30 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # firebase_notes
2 |
3 | A new Flutter project.
4 |
5 | ## Getting Started
6 |
7 | This project is a starting point for a Flutter application.
8 |
9 | A few resources to get you started if this is your first Flutter project:
10 |
11 | - [Lab: Write your first Flutter app](https://flutter.dev/docs/get-started/codelab)
12 | - [Cookbook: Useful Flutter samples](https://flutter.dev/docs/cookbook)
13 |
14 | For help getting started with Flutter, view our
15 | [online documentation](https://flutter.dev/docs), which offers tutorials,
16 | samples, guidance on mobile development, and a full API reference.
17 |
18 |
19 | 
20 |      
21 |
22 |
--------------------------------------------------------------------------------
/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "size" : "16x16",
5 | "idiom" : "mac",
6 | "filename" : "app_icon_16.png",
7 | "scale" : "1x"
8 | },
9 | {
10 | "size" : "16x16",
11 | "idiom" : "mac",
12 | "filename" : "app_icon_32.png",
13 | "scale" : "2x"
14 | },
15 | {
16 | "size" : "32x32",
17 | "idiom" : "mac",
18 | "filename" : "app_icon_32.png",
19 | "scale" : "1x"
20 | },
21 | {
22 | "size" : "32x32",
23 | "idiom" : "mac",
24 | "filename" : "app_icon_64.png",
25 | "scale" : "2x"
26 | },
27 | {
28 | "size" : "128x128",
29 | "idiom" : "mac",
30 | "filename" : "app_icon_128.png",
31 | "scale" : "1x"
32 | },
33 | {
34 | "size" : "128x128",
35 | "idiom" : "mac",
36 | "filename" : "app_icon_256.png",
37 | "scale" : "2x"
38 | },
39 | {
40 | "size" : "256x256",
41 | "idiom" : "mac",
42 | "filename" : "app_icon_256.png",
43 | "scale" : "1x"
44 | },
45 | {
46 | "size" : "256x256",
47 | "idiom" : "mac",
48 | "filename" : "app_icon_512.png",
49 | "scale" : "2x"
50 | },
51 | {
52 | "size" : "512x512",
53 | "idiom" : "mac",
54 | "filename" : "app_icon_512.png",
55 | "scale" : "1x"
56 | },
57 | {
58 | "size" : "512x512",
59 | "idiom" : "mac",
60 | "filename" : "app_icon_1024.png",
61 | "scale" : "2x"
62 | }
63 | ],
64 | "info" : {
65 | "version" : 1,
66 | "author" : "xcode"
67 | }
68 | }
69 |
--------------------------------------------------------------------------------
/lib/services/auth_service.dart:
--------------------------------------------------------------------------------
1 | import 'package:cloud_firestore/cloud_firestore.dart';
2 | import 'package:firebase_auth/firebase_auth.dart';
3 | import 'package:google_sign_in/google_sign_in.dart';
4 |
5 | class AuthService {
6 | final FirebaseAuth _auth = FirebaseAuth.instance;
7 | final FirebaseFirestore _firestore = FirebaseFirestore.instance;
8 |
9 | Future signInWithEmail(String email, String password) async {
10 | var user = await _auth.signInWithEmailAndPassword(
11 | email: email, password: password);
12 | return user.user;
13 | }
14 |
15 | signOut() async {
16 | return await _auth.signOut();
17 | }
18 |
19 | Future createPerson(
20 | String name,
21 | String email,
22 | String password,
23 | String profileImage,
24 | String sauceName,
25 | ) async {
26 | var user = await _auth.createUserWithEmailAndPassword(
27 | email: email, password: password);
28 |
29 | await _firestore.collection("Person").doc(user.user?.uid ?? "").set({
30 | 'username': name,
31 | 'email': email,
32 | 'profileImage': profileImage,
33 | 'sauceName': sauceName,
34 | });
35 |
36 | return user.user;
37 | }
38 |
39 | Future signInWithGoogle() async {
40 | final GoogleSignInAccount? googleUser = await GoogleSignIn().signIn();
41 | final GoogleSignInAuthentication googleAuth =
42 | await googleUser!.authentication;
43 | final credential = GoogleAuthProvider.credential(
44 | accessToken: googleAuth.accessToken,
45 | idToken: googleAuth.idToken,
46 | );
47 | return await FirebaseAuth.instance.signInWithCredential(credential);
48 | }
49 | }
50 |
--------------------------------------------------------------------------------
/ios/Runner/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/lib/src/strings.dart:
--------------------------------------------------------------------------------
1 | class DietText {
2 | //Common
3 | static String emptyText = "Eksik bilgilerle diyet yapılmaz...";
4 | static String errorText = "Beklenmedik bir hata oluştu...";
5 |
6 | //Launch
7 | static String mainText = "Diyet Planım";
8 | static String loginText = "Giriş yap";
9 | static String registerText = "Kayıt ol";
10 |
11 | //Register
12 | static String username = "Kullanıcı adı";
13 | static String email = "Kullanıcı maili";
14 | static String password = "Parola";
15 | static String registerQuestionFood =
16 | "Hayatında artık sadece birini yiyebileceksin:";
17 | static String registerQuestionsauce = "Hangi sos seni tanımlar?";
18 |
19 | //Sauces
20 | static String ketchup = "Ketçap";
21 | static String mayonnaise = "Mayonez";
22 | static String barbecue = "Barbekü";
23 | static String ranch = "Sarımsaklı sos";
24 | static String honeyMustard = "Ballı Hardal";
25 |
26 | //Login
27 | static String googleLogin = "Google ile giriş yap";
28 | static String loginNoAccountText = "Kullanıcı yok, haydi kayıt olma zamanı!";
29 | static String loginWrongPasswordText = "Yanlış parola, bir daha düşün...";
30 | static String loginWrongEmailText = "Böyle mail mi olur?";
31 | static String crashlytics = "Firebase Crashlytics";
32 |
33 | //Home
34 | static String homeText = "Anasayfa";
35 | static String profileText = "Profilim";
36 | static String logoutText = "Çıkış yap";
37 | static String removeText = "Silelim";
38 | static String dietList = "Diyet Listem:";
39 | static String alertDialogTitle = "Diyet listeni beğenmedin mi?";
40 | static String giveUpText = "Vazgeçtim";
41 |
42 | //Add Food
43 | static String addFoodText = "Diyet Listesi Ekle";
44 | static String addText = "Ekle";
45 | static String addSomeFoodsText = "Neler var diyetinde?";
46 | static String addSomeFoodsTitle = "Diyet listeni göstermek ister misin?";
47 |
48 | DietText._();
49 | }
50 |
--------------------------------------------------------------------------------
/windows/runner/utils.cpp:
--------------------------------------------------------------------------------
1 | #include "utils.h"
2 |
3 | #include
4 | #include
5 | #include
6 | #include
7 |
8 | #include
9 |
10 | void CreateAndAttachConsole() {
11 | if (::AllocConsole()) {
12 | FILE *unused;
13 | if (freopen_s(&unused, "CONOUT$", "w", stdout)) {
14 | _dup2(_fileno(stdout), 1);
15 | }
16 | if (freopen_s(&unused, "CONOUT$", "w", stderr)) {
17 | _dup2(_fileno(stdout), 2);
18 | }
19 | std::ios::sync_with_stdio();
20 | FlutterDesktopResyncOutputStreams();
21 | }
22 | }
23 |
24 | std::vector GetCommandLineArguments() {
25 | // Convert the UTF-16 command line arguments to UTF-8 for the Engine to use.
26 | int argc;
27 | wchar_t** argv = ::CommandLineToArgvW(::GetCommandLineW(), &argc);
28 | if (argv == nullptr) {
29 | return std::vector();
30 | }
31 |
32 | std::vector command_line_arguments;
33 |
34 | // Skip the first argument as it's the binary name.
35 | for (int i = 1; i < argc; i++) {
36 | command_line_arguments.push_back(Utf8FromUtf16(argv[i]));
37 | }
38 |
39 | ::LocalFree(argv);
40 |
41 | return command_line_arguments;
42 | }
43 |
44 | std::string Utf8FromUtf16(const wchar_t* utf16_string) {
45 | if (utf16_string == nullptr) {
46 | return std::string();
47 | }
48 | int target_length = ::WideCharToMultiByte(
49 | CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string,
50 | -1, nullptr, 0, nullptr, nullptr);
51 | if (target_length == 0) {
52 | return std::string();
53 | }
54 | std::string utf8_string;
55 | utf8_string.resize(target_length);
56 | int converted_length = ::WideCharToMultiByte(
57 | CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string,
58 | -1, utf8_string.data(),
59 | target_length, nullptr, nullptr);
60 | if (converted_length == 0) {
61 | return std::string();
62 | }
63 | return utf8_string;
64 | }
65 |
--------------------------------------------------------------------------------
/windows/runner/flutter_window.cpp:
--------------------------------------------------------------------------------
1 | #include "flutter_window.h"
2 |
3 | #include
4 |
5 | #include "flutter/generated_plugin_registrant.h"
6 |
7 | FlutterWindow::FlutterWindow(const flutter::DartProject& project)
8 | : project_(project) {}
9 |
10 | FlutterWindow::~FlutterWindow() {}
11 |
12 | bool FlutterWindow::OnCreate() {
13 | if (!Win32Window::OnCreate()) {
14 | return false;
15 | }
16 |
17 | RECT frame = GetClientArea();
18 |
19 | // The size here must match the window dimensions to avoid unnecessary surface
20 | // creation / destruction in the startup path.
21 | flutter_controller_ = std::make_unique(
22 | frame.right - frame.left, frame.bottom - frame.top, project_);
23 | // Ensure that basic setup of the controller was successful.
24 | if (!flutter_controller_->engine() || !flutter_controller_->view()) {
25 | return false;
26 | }
27 | RegisterPlugins(flutter_controller_->engine());
28 | SetChildContent(flutter_controller_->view()->GetNativeWindow());
29 | return true;
30 | }
31 |
32 | void FlutterWindow::OnDestroy() {
33 | if (flutter_controller_) {
34 | flutter_controller_ = nullptr;
35 | }
36 |
37 | Win32Window::OnDestroy();
38 | }
39 |
40 | LRESULT
41 | FlutterWindow::MessageHandler(HWND hwnd, UINT const message,
42 | WPARAM const wparam,
43 | LPARAM const lparam) noexcept {
44 | // Give Flutter, including plugins, an opportunity to handle window messages.
45 | if (flutter_controller_) {
46 | std::optional result =
47 | flutter_controller_->HandleTopLevelWindowProc(hwnd, message, wparam,
48 | lparam);
49 | if (result) {
50 | return *result;
51 | }
52 | }
53 |
54 | switch (message) {
55 | case WM_FONTCHANGE:
56 | flutter_controller_->engine()->ReloadSystemFonts();
57 | break;
58 | }
59 |
60 | return Win32Window::MessageHandler(hwnd, message, wparam, lparam);
61 | }
62 |
--------------------------------------------------------------------------------
/android/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
7 |
15 |
19 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
36 |
39 |
40 |
41 |
--------------------------------------------------------------------------------
/ios/Runner/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleDisplayName
8 | Diyet Planım
9 | CFBundleExecutable
10 | $(EXECUTABLE_NAME)
11 | CFBundleIdentifier
12 | $(PRODUCT_BUNDLE_IDENTIFIER)
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | Diyet Planım
17 | CFBundlePackageType
18 | APPL
19 | CFBundleShortVersionString
20 | $(FLUTTER_BUILD_NAME)
21 | CFBundleSignature
22 | ????
23 | CFBundleURLTypes
24 |
25 |
26 | CFBundleTypeRole
27 | Editor
28 | CFBundleURLSchemes
29 |
30 | com.googleusercontent.apps.970457623410-tiduhgvsuj52svr4j4sbhdadsra2fuo5
31 |
32 |
33 |
34 | CFBundleVersion
35 | $(FLUTTER_BUILD_NUMBER)
36 | LSRequiresIPhoneOS
37 |
38 | NSCameraUsageDescription
39 | camera
40 | NSPhotoLibraryAddUsageDescription
41 |
42 | NSPhotoLibraryUsageDescription
43 | This app requires access to the photo library.
44 | UIBackgroundModes
45 |
46 | fetch
47 |
48 | UILaunchStoryboardName
49 | LaunchScreen
50 | UIMainStoryboardFile
51 | Main
52 | UISupportedInterfaceOrientations
53 |
54 | UIInterfaceOrientationPortrait
55 | UIInterfaceOrientationLandscapeLeft
56 | UIInterfaceOrientationLandscapeRight
57 |
58 | UISupportedInterfaceOrientations~ipad
59 |
60 | UIInterfaceOrientationPortrait
61 | UIInterfaceOrientationPortraitUpsideDown
62 | UIInterfaceOrientationLandscapeLeft
63 | UIInterfaceOrientationLandscapeRight
64 |
65 | UIViewControllerBasedStatusBarAppearance
66 |
67 |
68 |
69 |
--------------------------------------------------------------------------------
/android/app/build.gradle:
--------------------------------------------------------------------------------
1 | def localProperties = new Properties()
2 | def localPropertiesFile = rootProject.file('local.properties')
3 | if (localPropertiesFile.exists()) {
4 | localPropertiesFile.withReader('UTF-8') { reader ->
5 | localProperties.load(reader)
6 | }
7 | }
8 |
9 | def flutterRoot = localProperties.getProperty('flutter.sdk')
10 | if (flutterRoot == null) {
11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
12 | }
13 |
14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
15 | if (flutterVersionCode == null) {
16 | flutterVersionCode = '1'
17 | }
18 |
19 | def flutterVersionName = localProperties.getProperty('flutter.versionName')
20 | if (flutterVersionName == null) {
21 | flutterVersionName = '1.0'
22 | }
23 |
24 | apply plugin: 'com.android.application'
25 | apply plugin: 'com.google.gms.google-services'
26 | apply plugin: 'com.google.firebase.crashlytics'
27 | apply plugin: 'kotlin-android'
28 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
29 |
30 | android {
31 | compileSdkVersion flutter.compileSdkVersion
32 |
33 | compileOptions {
34 | sourceCompatibility JavaVersion.VERSION_1_8
35 | targetCompatibility JavaVersion.VERSION_1_8
36 | }
37 |
38 | kotlinOptions {
39 | jvmTarget = '1.8'
40 | }
41 |
42 | sourceSets {
43 | main.java.srcDirs += 'src/main/kotlin'
44 | }
45 |
46 | defaultConfig {
47 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
48 | applicationId "com.example.firebase_notes"
49 | minSdkVersion flutter.minSdkVersion
50 | targetSdkVersion flutter.targetSdkVersion
51 | versionCode flutterVersionCode.toInteger()
52 | versionName flutterVersionName
53 | }
54 |
55 | buildTypes {
56 | release {
57 | // TODO: Add your own signing config for the release build.
58 | // Signing with the debug keys for now, so `flutter run --release` works.
59 | signingConfig signingConfigs.debug
60 | }
61 | }
62 | }
63 |
64 | flutter {
65 | source '../..'
66 | }
67 |
68 | dependencies {
69 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
70 | implementation platform('com.google.firebase:firebase-bom:29.0.3')
71 | implementation 'com.google.firebase:firebase-analytics'
72 | }
73 |
--------------------------------------------------------------------------------
/ios/Runner/Base.lproj/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
--------------------------------------------------------------------------------
/linux/flutter/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.10)
2 |
3 | set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral")
4 |
5 | # Configuration provided via flutter tool.
6 | include(${EPHEMERAL_DIR}/generated_config.cmake)
7 |
8 | # TODO: Move the rest of this into files in ephemeral. See
9 | # https://github.com/flutter/flutter/issues/57146.
10 |
11 | # Serves the same purpose as list(TRANSFORM ... PREPEND ...),
12 | # which isn't available in 3.10.
13 | function(list_prepend LIST_NAME PREFIX)
14 | set(NEW_LIST "")
15 | foreach(element ${${LIST_NAME}})
16 | list(APPEND NEW_LIST "${PREFIX}${element}")
17 | endforeach(element)
18 | set(${LIST_NAME} "${NEW_LIST}" PARENT_SCOPE)
19 | endfunction()
20 |
21 | # === Flutter Library ===
22 | # System-level dependencies.
23 | find_package(PkgConfig REQUIRED)
24 | pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0)
25 | pkg_check_modules(GLIB REQUIRED IMPORTED_TARGET glib-2.0)
26 | pkg_check_modules(GIO REQUIRED IMPORTED_TARGET gio-2.0)
27 |
28 | set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/libflutter_linux_gtk.so")
29 |
30 | # Published to parent scope for install step.
31 | set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE)
32 | set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE)
33 | set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE)
34 | set(AOT_LIBRARY "${PROJECT_DIR}/build/lib/libapp.so" PARENT_SCOPE)
35 |
36 | list(APPEND FLUTTER_LIBRARY_HEADERS
37 | "fl_basic_message_channel.h"
38 | "fl_binary_codec.h"
39 | "fl_binary_messenger.h"
40 | "fl_dart_project.h"
41 | "fl_engine.h"
42 | "fl_json_message_codec.h"
43 | "fl_json_method_codec.h"
44 | "fl_message_codec.h"
45 | "fl_method_call.h"
46 | "fl_method_channel.h"
47 | "fl_method_codec.h"
48 | "fl_method_response.h"
49 | "fl_plugin_registrar.h"
50 | "fl_plugin_registry.h"
51 | "fl_standard_message_codec.h"
52 | "fl_standard_method_codec.h"
53 | "fl_string_codec.h"
54 | "fl_value.h"
55 | "fl_view.h"
56 | "flutter_linux.h"
57 | )
58 | list_prepend(FLUTTER_LIBRARY_HEADERS "${EPHEMERAL_DIR}/flutter_linux/")
59 | add_library(flutter INTERFACE)
60 | target_include_directories(flutter INTERFACE
61 | "${EPHEMERAL_DIR}"
62 | )
63 | target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}")
64 | target_link_libraries(flutter INTERFACE
65 | PkgConfig::GTK
66 | PkgConfig::GLIB
67 | PkgConfig::GIO
68 | )
69 | add_dependencies(flutter flutter_assemble)
70 |
71 | # === Flutter tool backend ===
72 | # _phony_ is a non-existent file to force this command to run every time,
73 | # since currently there's no way to get a full input/output list from the
74 | # flutter tool.
75 | add_custom_command(
76 | OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS}
77 | ${CMAKE_CURRENT_BINARY_DIR}/_phony_
78 | COMMAND ${CMAKE_COMMAND} -E env
79 | ${FLUTTER_TOOL_ENVIRONMENT}
80 | "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.sh"
81 | ${FLUTTER_TARGET_PLATFORM} ${CMAKE_BUILD_TYPE}
82 | VERBATIM
83 | )
84 | add_custom_target(flutter_assemble DEPENDS
85 | "${FLUTTER_LIBRARY}"
86 | ${FLUTTER_LIBRARY_HEADERS}
87 | )
88 |
--------------------------------------------------------------------------------
/lib/views/launch/launch_page.dart:
--------------------------------------------------------------------------------
1 | import 'package:firebase_notes/constants/custom_app_bar.dart';
2 | import 'package:firebase_notes/src/colors.dart';
3 | import 'package:firebase_notes/src/images.dart';
4 | import 'package:firebase_notes/src/strings.dart';
5 | import 'package:firebase_notes/views/login/login_page.dart';
6 | import 'package:firebase_notes/views/register/register_page.dart';
7 | import 'package:flutter/material.dart';
8 |
9 | class LaunchPage extends StatelessWidget {
10 | const LaunchPage({Key? key}) : super(key: key);
11 |
12 | @override
13 | Widget build(BuildContext context) {
14 | return Scaffold(
15 | backgroundColor: DietColors.mainColor,
16 | appBar: CustomAppBar(DietText.mainText),
17 | body: _body(context),
18 | );
19 | }
20 |
21 | Padding _body(BuildContext context) {
22 | return Padding(
23 | padding: const EdgeInsets.symmetric(horizontal: 20, vertical: 50),
24 | child: ListView(
25 | children: [
26 | _bodyImage(context),
27 | const SizedBox(
28 | height: 50,
29 | ),
30 | _bodyColumn(context),
31 | ],
32 | ));
33 | }
34 |
35 | ClipRRect _bodyImage(BuildContext context) {
36 | var size = MediaQuery.of(context).size;
37 |
38 | return ClipRRect(
39 | borderRadius: BorderRadius.circular(20),
40 | child: Image.asset(
41 | DietImages.launchImage,
42 | height: size.height * .5,
43 | fit: BoxFit.fill,
44 | ),
45 | );
46 | }
47 |
48 | Column _bodyColumn(BuildContext context) {
49 | return Column(
50 | crossAxisAlignment: CrossAxisAlignment.stretch,
51 | children: [
52 | _loginButton(context),
53 | const SizedBox(
54 | height: 15,
55 | ),
56 | _registerButton(context),
57 | ],
58 | );
59 | }
60 |
61 | InkWell _loginButton(BuildContext context) {
62 | return InkWell(
63 | onTap: () {
64 | Navigator.push(context,
65 | MaterialPageRoute(builder: (context) => const LoginPage()));
66 | },
67 | child: Container(
68 | decoration: BoxDecoration(
69 | color: DietColors.white,
70 | borderRadius: BorderRadius.circular(10),
71 | ),
72 | height: 40,
73 | child: Center(
74 | child: Text(
75 | DietText.loginText,
76 | style: TextStyle(color: DietColors.black),
77 | ),
78 | ),
79 | ));
80 | }
81 |
82 | InkWell _registerButton(BuildContext context) {
83 | return InkWell(
84 | onTap: () {
85 | Navigator.push(context,
86 | MaterialPageRoute(builder: (context) => const RegisterPage()));
87 | },
88 | child: Container(
89 | decoration: BoxDecoration(
90 | color: DietColors.white,
91 | borderRadius: BorderRadius.circular(10),
92 | ),
93 | height: 40,
94 | child: Center(
95 | child: Text(
96 | DietText.registerText,
97 | style: TextStyle(color: DietColors.black),
98 | ),
99 | ),
100 | ));
101 | }
102 | }
103 |
--------------------------------------------------------------------------------
/windows/runner/Runner.rc:
--------------------------------------------------------------------------------
1 | // Microsoft Visual C++ generated resource script.
2 | //
3 | #pragma code_page(65001)
4 | #include "resource.h"
5 |
6 | #define APSTUDIO_READONLY_SYMBOLS
7 | /////////////////////////////////////////////////////////////////////////////
8 | //
9 | // Generated from the TEXTINCLUDE 2 resource.
10 | //
11 | #include "winres.h"
12 |
13 | /////////////////////////////////////////////////////////////////////////////
14 | #undef APSTUDIO_READONLY_SYMBOLS
15 |
16 | /////////////////////////////////////////////////////////////////////////////
17 | // English (United States) resources
18 |
19 | #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
20 | LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
21 |
22 | #ifdef APSTUDIO_INVOKED
23 | /////////////////////////////////////////////////////////////////////////////
24 | //
25 | // TEXTINCLUDE
26 | //
27 |
28 | 1 TEXTINCLUDE
29 | BEGIN
30 | "resource.h\0"
31 | END
32 |
33 | 2 TEXTINCLUDE
34 | BEGIN
35 | "#include ""winres.h""\r\n"
36 | "\0"
37 | END
38 |
39 | 3 TEXTINCLUDE
40 | BEGIN
41 | "\r\n"
42 | "\0"
43 | END
44 |
45 | #endif // APSTUDIO_INVOKED
46 |
47 |
48 | /////////////////////////////////////////////////////////////////////////////
49 | //
50 | // Icon
51 | //
52 |
53 | // Icon with lowest ID value placed first to ensure application icon
54 | // remains consistent on all systems.
55 | IDI_APP_ICON ICON "resources\\app_icon.ico"
56 |
57 |
58 | /////////////////////////////////////////////////////////////////////////////
59 | //
60 | // Version
61 | //
62 |
63 | #ifdef FLUTTER_BUILD_NUMBER
64 | #define VERSION_AS_NUMBER FLUTTER_BUILD_NUMBER
65 | #else
66 | #define VERSION_AS_NUMBER 1,0,0
67 | #endif
68 |
69 | #ifdef FLUTTER_BUILD_NAME
70 | #define VERSION_AS_STRING #FLUTTER_BUILD_NAME
71 | #else
72 | #define VERSION_AS_STRING "1.0.0"
73 | #endif
74 |
75 | VS_VERSION_INFO VERSIONINFO
76 | FILEVERSION VERSION_AS_NUMBER
77 | PRODUCTVERSION VERSION_AS_NUMBER
78 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
79 | #ifdef _DEBUG
80 | FILEFLAGS VS_FF_DEBUG
81 | #else
82 | FILEFLAGS 0x0L
83 | #endif
84 | FILEOS VOS__WINDOWS32
85 | FILETYPE VFT_APP
86 | FILESUBTYPE 0x0L
87 | BEGIN
88 | BLOCK "StringFileInfo"
89 | BEGIN
90 | BLOCK "040904e4"
91 | BEGIN
92 | VALUE "CompanyName", "com.example" "\0"
93 | VALUE "FileDescription", "A new Flutter project." "\0"
94 | VALUE "FileVersion", VERSION_AS_STRING "\0"
95 | VALUE "InternalName", "firebase_notes" "\0"
96 | VALUE "LegalCopyright", "Copyright (C) 2022 com.example. All rights reserved." "\0"
97 | VALUE "OriginalFilename", "firebase_notes.exe" "\0"
98 | VALUE "ProductName", "firebase_notes" "\0"
99 | VALUE "ProductVersion", VERSION_AS_STRING "\0"
100 | END
101 | END
102 | BLOCK "VarFileInfo"
103 | BEGIN
104 | VALUE "Translation", 0x409, 1252
105 | END
106 | END
107 |
108 | #endif // English (United States) resources
109 | /////////////////////////////////////////////////////////////////////////////
110 |
111 |
112 |
113 | #ifndef APSTUDIO_INVOKED
114 | /////////////////////////////////////////////////////////////////////////////
115 | //
116 | // Generated from the TEXTINCLUDE 3 resource.
117 | //
118 |
119 |
120 | /////////////////////////////////////////////////////////////////////////////
121 | #endif // not APSTUDIO_INVOKED
122 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
37 |
38 |
39 |
40 |
41 |
42 |
52 |
54 |
60 |
61 |
62 |
63 |
69 |
71 |
77 |
78 |
79 |
80 |
82 |
83 |
86 |
87 |
88 |
--------------------------------------------------------------------------------
/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
37 |
38 |
39 |
40 |
41 |
42 |
52 |
54 |
60 |
61 |
62 |
63 |
69 |
71 |
77 |
78 |
79 |
80 |
82 |
83 |
86 |
87 |
88 |
--------------------------------------------------------------------------------
/lib/views/home/home_page.dart:
--------------------------------------------------------------------------------
1 | import 'package:firebase_notes/constants/custom_app_bar.dart';
2 | import 'package:firebase_notes/services/auth_service.dart';
3 | import 'package:firebase_notes/src/colors.dart';
4 | import 'package:firebase_notes/src/images.dart';
5 | import 'package:firebase_notes/src/strings.dart';
6 | import 'package:firebase_notes/views/add_food/add_food_page.dart';
7 | import 'package:firebase_notes/views/home/food_list_page.dart';
8 | import 'package:firebase_notes/views/launch/launch_page.dart';
9 | import 'package:flutter/material.dart';
10 |
11 | class HomePage extends StatefulWidget {
12 | const HomePage({Key? key}) : super(key: key);
13 |
14 | @override
15 | _HomePageState createState() => _HomePageState();
16 | }
17 |
18 | class _HomePageState extends State {
19 | final AuthService _authService = AuthService();
20 |
21 | @override
22 | Widget build(BuildContext context) {
23 | return Scaffold(
24 | backgroundColor: DietColors.mainColor,
25 | appBar: CustomAppBar(DietText.homeText),
26 | drawer: _drawer(),
27 | body: const FoodListPage(),
28 | floatingActionButton: _floatingActionButton(),
29 | );
30 | }
31 |
32 | Drawer _drawer() {
33 | return Drawer(
34 | child: ListView(
35 | padding: EdgeInsets.zero,
36 | children: [
37 | _userAccountsDrawer(),
38 | _drawerHome(),
39 | _drawerProfile(),
40 | const Divider(),
41 | _drawerLogout(),
42 | ],
43 | ),
44 | );
45 | }
46 |
47 | UserAccountsDrawerHeader _userAccountsDrawer() {
48 | return UserAccountsDrawerHeader(
49 | accountName: const Text("Hello World"),
50 | accountEmail: const Text("helloworld@gmail.com"),
51 | currentAccountPicture: CircleAvatar(
52 | backgroundImage: AssetImage(DietImages.pizza),
53 | ),
54 | decoration: BoxDecoration(color: DietColors.orange),
55 | );
56 | }
57 |
58 | ListTile _drawerHome() {
59 | return ListTile(
60 | title: Text(DietText.homeText),
61 | leading: Icon(
62 | Icons.home,
63 | color: DietColors.orange,
64 | ),
65 | onTap: () {
66 | Navigator.pop(context);
67 | },
68 | );
69 | }
70 |
71 | ListTile _drawerProfile() {
72 | return ListTile(
73 | title: Text(DietText.profileText),
74 | onTap: () {
75 | Navigator.pop(context);
76 | },
77 | leading: Icon(
78 | Icons.person,
79 | color: DietColors.orange,
80 | ),
81 | );
82 | }
83 |
84 | ListTile _drawerLogout() {
85 | return ListTile(
86 | title: Text(DietText.logoutText),
87 | onTap: () {
88 | _authService.signOut();
89 | Navigator.pushAndRemoveUntil(
90 | context,
91 | MaterialPageRoute(builder: (context) => const LaunchPage()),
92 | (route) => false);
93 | },
94 | leading: Icon(
95 | Icons.remove_circle,
96 | color: DietColors.orange,
97 | ),
98 | );
99 | }
100 |
101 | FloatingActionButton _floatingActionButton() {
102 | return FloatingActionButton(
103 | backgroundColor: DietColors.orange,
104 | elevation: 0.0,
105 | onPressed: () {
106 | Navigator.push(
107 | context,
108 | MaterialPageRoute(
109 | builder: (context) => const AddFoodPage(),
110 | ),
111 | );
112 | },
113 | child: const Icon(
114 | Icons.add,
115 | ),
116 | );
117 | }
118 | }
119 |
--------------------------------------------------------------------------------
/windows/runner/win32_window.h:
--------------------------------------------------------------------------------
1 | #ifndef RUNNER_WIN32_WINDOW_H_
2 | #define RUNNER_WIN32_WINDOW_H_
3 |
4 | #include
5 |
6 | #include
7 | #include
8 | #include
9 |
10 | // A class abstraction for a high DPI-aware Win32 Window. Intended to be
11 | // inherited from by classes that wish to specialize with custom
12 | // rendering and input handling
13 | class Win32Window {
14 | public:
15 | struct Point {
16 | unsigned int x;
17 | unsigned int y;
18 | Point(unsigned int x, unsigned int y) : x(x), y(y) {}
19 | };
20 |
21 | struct Size {
22 | unsigned int width;
23 | unsigned int height;
24 | Size(unsigned int width, unsigned int height)
25 | : width(width), height(height) {}
26 | };
27 |
28 | Win32Window();
29 | virtual ~Win32Window();
30 |
31 | // Creates and shows a win32 window with |title| and position and size using
32 | // |origin| and |size|. New windows are created on the default monitor. Window
33 | // sizes are specified to the OS in physical pixels, hence to ensure a
34 | // consistent size to will treat the width height passed in to this function
35 | // as logical pixels and scale to appropriate for the default monitor. Returns
36 | // true if the window was created successfully.
37 | bool CreateAndShow(const std::wstring& title,
38 | const Point& origin,
39 | const Size& size);
40 |
41 | // Release OS resources associated with window.
42 | void Destroy();
43 |
44 | // Inserts |content| into the window tree.
45 | void SetChildContent(HWND content);
46 |
47 | // Returns the backing Window handle to enable clients to set icon and other
48 | // window properties. Returns nullptr if the window has been destroyed.
49 | HWND GetHandle();
50 |
51 | // If true, closing this window will quit the application.
52 | void SetQuitOnClose(bool quit_on_close);
53 |
54 | // Return a RECT representing the bounds of the current client area.
55 | RECT GetClientArea();
56 |
57 | protected:
58 | // Processes and route salient window messages for mouse handling,
59 | // size change and DPI. Delegates handling of these to member overloads that
60 | // inheriting classes can handle.
61 | virtual LRESULT MessageHandler(HWND window,
62 | UINT const message,
63 | WPARAM const wparam,
64 | LPARAM const lparam) noexcept;
65 |
66 | // Called when CreateAndShow is called, allowing subclass window-related
67 | // setup. Subclasses should return false if setup fails.
68 | virtual bool OnCreate();
69 |
70 | // Called when Destroy is called.
71 | virtual void OnDestroy();
72 |
73 | private:
74 | friend class WindowClassRegistrar;
75 |
76 | // OS callback called by message pump. Handles the WM_NCCREATE message which
77 | // is passed when the non-client area is being created and enables automatic
78 | // non-client DPI scaling so that the non-client area automatically
79 | // responsponds to changes in DPI. All other messages are handled by
80 | // MessageHandler.
81 | static LRESULT CALLBACK WndProc(HWND const window,
82 | UINT const message,
83 | WPARAM const wparam,
84 | LPARAM const lparam) noexcept;
85 |
86 | // Retrieves a class instance pointer for |window|
87 | static Win32Window* GetThisFromHandle(HWND const window) noexcept;
88 |
89 | bool quit_on_close_ = false;
90 |
91 | // window handle for top level window.
92 | HWND window_handle_ = nullptr;
93 |
94 | // window handle for hosted content.
95 | HWND child_content_ = nullptr;
96 | };
97 |
98 | #endif // RUNNER_WIN32_WINDOW_H_
99 |
--------------------------------------------------------------------------------
/windows/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.14)
2 | project(firebase_notes LANGUAGES CXX)
3 |
4 | set(BINARY_NAME "firebase_notes")
5 |
6 | cmake_policy(SET CMP0063 NEW)
7 |
8 | set(CMAKE_INSTALL_RPATH "$ORIGIN/lib")
9 |
10 | # Configure build options.
11 | get_property(IS_MULTICONFIG GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG)
12 | if(IS_MULTICONFIG)
13 | set(CMAKE_CONFIGURATION_TYPES "Debug;Profile;Release"
14 | CACHE STRING "" FORCE)
15 | else()
16 | if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
17 | set(CMAKE_BUILD_TYPE "Debug" CACHE
18 | STRING "Flutter build mode" FORCE)
19 | set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS
20 | "Debug" "Profile" "Release")
21 | endif()
22 | endif()
23 |
24 | set(CMAKE_EXE_LINKER_FLAGS_PROFILE "${CMAKE_EXE_LINKER_FLAGS_RELEASE}")
25 | set(CMAKE_SHARED_LINKER_FLAGS_PROFILE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE}")
26 | set(CMAKE_C_FLAGS_PROFILE "${CMAKE_C_FLAGS_RELEASE}")
27 | set(CMAKE_CXX_FLAGS_PROFILE "${CMAKE_CXX_FLAGS_RELEASE}")
28 |
29 | # Use Unicode for all projects.
30 | add_definitions(-DUNICODE -D_UNICODE)
31 |
32 | # Compilation settings that should be applied to most targets.
33 | function(APPLY_STANDARD_SETTINGS TARGET)
34 | target_compile_features(${TARGET} PUBLIC cxx_std_17)
35 | target_compile_options(${TARGET} PRIVATE /W4 /WX /wd"4100")
36 | target_compile_options(${TARGET} PRIVATE /EHsc)
37 | target_compile_definitions(${TARGET} PRIVATE "_HAS_EXCEPTIONS=0")
38 | target_compile_definitions(${TARGET} PRIVATE "$<$:_DEBUG>")
39 | endfunction()
40 |
41 | set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter")
42 |
43 | # Flutter library and tool build rules.
44 | add_subdirectory(${FLUTTER_MANAGED_DIR})
45 |
46 | # Application build
47 | add_subdirectory("runner")
48 |
49 | # Generated plugin build rules, which manage building the plugins and adding
50 | # them to the application.
51 | include(flutter/generated_plugins.cmake)
52 |
53 |
54 | # === Installation ===
55 | # Support files are copied into place next to the executable, so that it can
56 | # run in place. This is done instead of making a separate bundle (as on Linux)
57 | # so that building and running from within Visual Studio will work.
58 | set(BUILD_BUNDLE_DIR "$")
59 | # Make the "install" step default, as it's required to run.
60 | set(CMAKE_VS_INCLUDE_INSTALL_TO_DEFAULT_BUILD 1)
61 | if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
62 | set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE)
63 | endif()
64 |
65 | set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data")
66 | set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}")
67 |
68 | install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}"
69 | COMPONENT Runtime)
70 |
71 | install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}"
72 | COMPONENT Runtime)
73 |
74 | install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
75 | COMPONENT Runtime)
76 |
77 | if(PLUGIN_BUNDLED_LIBRARIES)
78 | install(FILES "${PLUGIN_BUNDLED_LIBRARIES}"
79 | DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
80 | COMPONENT Runtime)
81 | endif()
82 |
83 | # Fully re-copy the assets directory on each build to avoid having stale files
84 | # from a previous install.
85 | set(FLUTTER_ASSET_DIR_NAME "flutter_assets")
86 | install(CODE "
87 | file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\")
88 | " COMPONENT Runtime)
89 | install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}"
90 | DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime)
91 |
92 | # Install the AOT library on non-Debug builds only.
93 | install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}"
94 | CONFIGURATIONS Profile;Release
95 | COMPONENT Runtime)
96 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images":[
3 | {
4 | "idiom":"iphone",
5 | "size":"20x20",
6 | "scale":"2x",
7 | "filename":"Icon-App-20x20@2x.png"
8 | },
9 | {
10 | "idiom":"iphone",
11 | "size":"20x20",
12 | "scale":"3x",
13 | "filename":"Icon-App-20x20@3x.png"
14 | },
15 | {
16 | "idiom":"iphone",
17 | "size":"29x29",
18 | "scale":"1x",
19 | "filename":"Icon-App-29x29@1x.png"
20 | },
21 | {
22 | "idiom":"iphone",
23 | "size":"29x29",
24 | "scale":"2x",
25 | "filename":"Icon-App-29x29@2x.png"
26 | },
27 | {
28 | "idiom":"iphone",
29 | "size":"29x29",
30 | "scale":"3x",
31 | "filename":"Icon-App-29x29@3x.png"
32 | },
33 | {
34 | "idiom":"iphone",
35 | "size":"40x40",
36 | "scale":"2x",
37 | "filename":"Icon-App-40x40@2x.png"
38 | },
39 | {
40 | "idiom":"iphone",
41 | "size":"40x40",
42 | "scale":"3x",
43 | "filename":"Icon-App-40x40@3x.png"
44 | },
45 | {
46 | "idiom":"iphone",
47 | "size":"60x60",
48 | "scale":"2x",
49 | "filename":"Icon-App-60x60@2x.png"
50 | },
51 | {
52 | "idiom":"iphone",
53 | "size":"60x60",
54 | "scale":"3x",
55 | "filename":"Icon-App-60x60@3x.png"
56 | },
57 | {
58 | "idiom":"iphone",
59 | "size":"76x76",
60 | "scale":"2x",
61 | "filename":"Icon-App-76x76@2x.png"
62 | },
63 | {
64 | "idiom":"ipad",
65 | "size":"20x20",
66 | "scale":"1x",
67 | "filename":"Icon-App-20x20@1x.png"
68 | },
69 | {
70 | "idiom":"ipad",
71 | "size":"20x20",
72 | "scale":"2x",
73 | "filename":"Icon-App-20x20@2x.png"
74 | },
75 | {
76 | "idiom":"ipad",
77 | "size":"29x29",
78 | "scale":"1x",
79 | "filename":"Icon-App-29x29@1x.png"
80 | },
81 | {
82 | "idiom":"ipad",
83 | "size":"29x29",
84 | "scale":"2x",
85 | "filename":"Icon-App-29x29@2x.png"
86 | },
87 | {
88 | "idiom":"ipad",
89 | "size":"40x40",
90 | "scale":"1x",
91 | "filename":"Icon-App-40x40@1x.png"
92 | },
93 | {
94 | "idiom":"ipad",
95 | "size":"40x40",
96 | "scale":"2x",
97 | "filename":"Icon-App-40x40@2x.png"
98 | },
99 | {
100 | "idiom":"ipad",
101 | "size":"76x76",
102 | "scale":"1x",
103 | "filename":"Icon-App-76x76@1x.png"
104 | },
105 | {
106 | "idiom":"ipad",
107 | "size":"76x76",
108 | "scale":"2x",
109 | "filename":"Icon-App-76x76@2x.png"
110 | },
111 | {
112 | "idiom":"ipad",
113 | "size":"83.5x83.5",
114 | "scale":"2x",
115 | "filename":"Icon-App-83.5x83.5@2x.png"
116 | },
117 | {
118 | "size" : "1024x1024",
119 | "idiom" : "ios-marketing",
120 | "scale" : "1x",
121 | "filename" : "ItunesArtwork@2x.png"
122 | }
123 | ],
124 | "info":{
125 | "version":1,
126 | "author":"makeappicon"
127 | }
128 | }
129 |
--------------------------------------------------------------------------------
/windows/flutter/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.14)
2 |
3 | set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral")
4 |
5 | # Configuration provided via flutter tool.
6 | include(${EPHEMERAL_DIR}/generated_config.cmake)
7 |
8 | # TODO: Move the rest of this into files in ephemeral. See
9 | # https://github.com/flutter/flutter/issues/57146.
10 | set(WRAPPER_ROOT "${EPHEMERAL_DIR}/cpp_client_wrapper")
11 |
12 | # === Flutter Library ===
13 | set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/flutter_windows.dll")
14 |
15 | # Published to parent scope for install step.
16 | set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE)
17 | set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE)
18 | set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE)
19 | set(AOT_LIBRARY "${PROJECT_DIR}/build/windows/app.so" PARENT_SCOPE)
20 |
21 | list(APPEND FLUTTER_LIBRARY_HEADERS
22 | "flutter_export.h"
23 | "flutter_windows.h"
24 | "flutter_messenger.h"
25 | "flutter_plugin_registrar.h"
26 | "flutter_texture_registrar.h"
27 | )
28 | list(TRANSFORM FLUTTER_LIBRARY_HEADERS PREPEND "${EPHEMERAL_DIR}/")
29 | add_library(flutter INTERFACE)
30 | target_include_directories(flutter INTERFACE
31 | "${EPHEMERAL_DIR}"
32 | )
33 | target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}.lib")
34 | add_dependencies(flutter flutter_assemble)
35 |
36 | # === Wrapper ===
37 | list(APPEND CPP_WRAPPER_SOURCES_CORE
38 | "core_implementations.cc"
39 | "standard_codec.cc"
40 | )
41 | list(TRANSFORM CPP_WRAPPER_SOURCES_CORE PREPEND "${WRAPPER_ROOT}/")
42 | list(APPEND CPP_WRAPPER_SOURCES_PLUGIN
43 | "plugin_registrar.cc"
44 | )
45 | list(TRANSFORM CPP_WRAPPER_SOURCES_PLUGIN PREPEND "${WRAPPER_ROOT}/")
46 | list(APPEND CPP_WRAPPER_SOURCES_APP
47 | "flutter_engine.cc"
48 | "flutter_view_controller.cc"
49 | )
50 | list(TRANSFORM CPP_WRAPPER_SOURCES_APP PREPEND "${WRAPPER_ROOT}/")
51 |
52 | # Wrapper sources needed for a plugin.
53 | add_library(flutter_wrapper_plugin STATIC
54 | ${CPP_WRAPPER_SOURCES_CORE}
55 | ${CPP_WRAPPER_SOURCES_PLUGIN}
56 | )
57 | apply_standard_settings(flutter_wrapper_plugin)
58 | set_target_properties(flutter_wrapper_plugin PROPERTIES
59 | POSITION_INDEPENDENT_CODE ON)
60 | set_target_properties(flutter_wrapper_plugin PROPERTIES
61 | CXX_VISIBILITY_PRESET hidden)
62 | target_link_libraries(flutter_wrapper_plugin PUBLIC flutter)
63 | target_include_directories(flutter_wrapper_plugin PUBLIC
64 | "${WRAPPER_ROOT}/include"
65 | )
66 | add_dependencies(flutter_wrapper_plugin flutter_assemble)
67 |
68 | # Wrapper sources needed for the runner.
69 | add_library(flutter_wrapper_app STATIC
70 | ${CPP_WRAPPER_SOURCES_CORE}
71 | ${CPP_WRAPPER_SOURCES_APP}
72 | )
73 | apply_standard_settings(flutter_wrapper_app)
74 | target_link_libraries(flutter_wrapper_app PUBLIC flutter)
75 | target_include_directories(flutter_wrapper_app PUBLIC
76 | "${WRAPPER_ROOT}/include"
77 | )
78 | add_dependencies(flutter_wrapper_app flutter_assemble)
79 |
80 | # === Flutter tool backend ===
81 | # _phony_ is a non-existent file to force this command to run every time,
82 | # since currently there's no way to get a full input/output list from the
83 | # flutter tool.
84 | set(PHONY_OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/_phony_")
85 | set_source_files_properties("${PHONY_OUTPUT}" PROPERTIES SYMBOLIC TRUE)
86 | add_custom_command(
87 | OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS}
88 | ${CPP_WRAPPER_SOURCES_CORE} ${CPP_WRAPPER_SOURCES_PLUGIN}
89 | ${CPP_WRAPPER_SOURCES_APP}
90 | ${PHONY_OUTPUT}
91 | COMMAND ${CMAKE_COMMAND} -E env
92 | ${FLUTTER_TOOL_ENVIRONMENT}
93 | "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.bat"
94 | windows-x64 $
95 | VERBATIM
96 | )
97 | add_custom_target(flutter_assemble DEPENDS
98 | "${FLUTTER_LIBRARY}"
99 | ${FLUTTER_LIBRARY_HEADERS}
100 | ${CPP_WRAPPER_SOURCES_CORE}
101 | ${CPP_WRAPPER_SOURCES_PLUGIN}
102 | ${CPP_WRAPPER_SOURCES_APP}
103 | )
104 |
--------------------------------------------------------------------------------
/linux/my_application.cc:
--------------------------------------------------------------------------------
1 | #include "my_application.h"
2 |
3 | #include
4 | #ifdef GDK_WINDOWING_X11
5 | #include
6 | #endif
7 |
8 | #include "flutter/generated_plugin_registrant.h"
9 |
10 | struct _MyApplication {
11 | GtkApplication parent_instance;
12 | char** dart_entrypoint_arguments;
13 | };
14 |
15 | G_DEFINE_TYPE(MyApplication, my_application, GTK_TYPE_APPLICATION)
16 |
17 | // Implements GApplication::activate.
18 | static void my_application_activate(GApplication* application) {
19 | MyApplication* self = MY_APPLICATION(application);
20 | GtkWindow* window =
21 | GTK_WINDOW(gtk_application_window_new(GTK_APPLICATION(application)));
22 |
23 | // Use a header bar when running in GNOME as this is the common style used
24 | // by applications and is the setup most users will be using (e.g. Ubuntu
25 | // desktop).
26 | // If running on X and not using GNOME then just use a traditional title bar
27 | // in case the window manager does more exotic layout, e.g. tiling.
28 | // If running on Wayland assume the header bar will work (may need changing
29 | // if future cases occur).
30 | gboolean use_header_bar = TRUE;
31 | #ifdef GDK_WINDOWING_X11
32 | GdkScreen* screen = gtk_window_get_screen(window);
33 | if (GDK_IS_X11_SCREEN(screen)) {
34 | const gchar* wm_name = gdk_x11_screen_get_window_manager_name(screen);
35 | if (g_strcmp0(wm_name, "GNOME Shell") != 0) {
36 | use_header_bar = FALSE;
37 | }
38 | }
39 | #endif
40 | if (use_header_bar) {
41 | GtkHeaderBar* header_bar = GTK_HEADER_BAR(gtk_header_bar_new());
42 | gtk_widget_show(GTK_WIDGET(header_bar));
43 | gtk_header_bar_set_title(header_bar, "firebase_notes");
44 | gtk_header_bar_set_show_close_button(header_bar, TRUE);
45 | gtk_window_set_titlebar(window, GTK_WIDGET(header_bar));
46 | } else {
47 | gtk_window_set_title(window, "firebase_notes");
48 | }
49 |
50 | gtk_window_set_default_size(window, 1280, 720);
51 | gtk_widget_show(GTK_WIDGET(window));
52 |
53 | g_autoptr(FlDartProject) project = fl_dart_project_new();
54 | fl_dart_project_set_dart_entrypoint_arguments(project, self->dart_entrypoint_arguments);
55 |
56 | FlView* view = fl_view_new(project);
57 | gtk_widget_show(GTK_WIDGET(view));
58 | gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(view));
59 |
60 | fl_register_plugins(FL_PLUGIN_REGISTRY(view));
61 |
62 | gtk_widget_grab_focus(GTK_WIDGET(view));
63 | }
64 |
65 | // Implements GApplication::local_command_line.
66 | static gboolean my_application_local_command_line(GApplication* application, gchar*** arguments, int* exit_status) {
67 | MyApplication* self = MY_APPLICATION(application);
68 | // Strip out the first argument as it is the binary name.
69 | self->dart_entrypoint_arguments = g_strdupv(*arguments + 1);
70 |
71 | g_autoptr(GError) error = nullptr;
72 | if (!g_application_register(application, nullptr, &error)) {
73 | g_warning("Failed to register: %s", error->message);
74 | *exit_status = 1;
75 | return TRUE;
76 | }
77 |
78 | g_application_activate(application);
79 | *exit_status = 0;
80 |
81 | return TRUE;
82 | }
83 |
84 | // Implements GObject::dispose.
85 | static void my_application_dispose(GObject* object) {
86 | MyApplication* self = MY_APPLICATION(object);
87 | g_clear_pointer(&self->dart_entrypoint_arguments, g_strfreev);
88 | G_OBJECT_CLASS(my_application_parent_class)->dispose(object);
89 | }
90 |
91 | static void my_application_class_init(MyApplicationClass* klass) {
92 | G_APPLICATION_CLASS(klass)->activate = my_application_activate;
93 | G_APPLICATION_CLASS(klass)->local_command_line = my_application_local_command_line;
94 | G_OBJECT_CLASS(klass)->dispose = my_application_dispose;
95 | }
96 |
97 | static void my_application_init(MyApplication* self) {}
98 |
99 | MyApplication* my_application_new() {
100 | return MY_APPLICATION(g_object_new(my_application_get_type(),
101 | "application-id", APPLICATION_ID,
102 | "flags", G_APPLICATION_NON_UNIQUE,
103 | nullptr));
104 | }
105 |
--------------------------------------------------------------------------------
/pubspec.yaml:
--------------------------------------------------------------------------------
1 | name: firebase_notes
2 | description: A new Flutter project.
3 |
4 | # The following line prevents the package from being accidentally published to
5 | # pub.dev using `flutter pub publish`. This is preferred for private packages.
6 | publish_to: "none" # Remove this line if you wish to publish to pub.dev
7 |
8 | # The following defines the version and build number for your application.
9 | # A version number is three numbers separated by dots, like 1.2.43
10 | # followed by an optional build number separated by a +.
11 | # Both the version and the builder number may be overridden in flutter
12 | # build by specifying --build-name and --build-number, respectively.
13 | # In Android, build-name is used as versionName while build-number used as versionCode.
14 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning
15 | # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
16 | # Read more about iOS versioning at
17 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
18 | version: 1.0.0+1
19 |
20 | environment:
21 | sdk: ">=2.15.1 <3.0.0"
22 |
23 | # Dependencies specify other packages that your package needs in order to work.
24 | # To automatically upgrade your package dependencies to the latest versions
25 | # consider running `flutter pub upgrade --major-versions`. Alternatively,
26 | # dependencies can be manually updated by changing the version numbers below to
27 | # the latest version available on pub.dev. To see which dependencies have newer
28 | # versions available, run `flutter pub outdated`.
29 | dependencies:
30 | flutter:
31 | sdk: flutter
32 |
33 | font_awesome_flutter: ^9.2.0
34 | firebase_core: ^1.11.0
35 | cloud_firestore: ^3.1.6
36 | firebase_auth: ^3.3.5
37 | firebase_storage: ^10.2.5
38 | google_sign_in: ^5.2.1
39 | fluttertoast: ^8.0.8
40 | image_picker: ^0.8.4+4
41 | firebase_crashlytics: ^2.4.5
42 | firebase_messaging: ^11.2.5
43 |
44 | # The following adds the Cupertino Icons font to your application.
45 | # Use with the CupertinoIcons class for iOS style icons.
46 | cupertino_icons: ^1.0.2
47 |
48 | dev_dependencies:
49 | flutter_test:
50 | sdk: flutter
51 |
52 | # The "flutter_lints" package below contains a set of recommended lints to
53 | # encourage good coding practices. The lint set provided by the package is
54 | # activated in the `analysis_options.yaml` file located at the root of your
55 | # package. See that file for information about deactivating specific lint
56 | # rules and activating additional ones.
57 | flutter_lints: ^1.0.0
58 |
59 | # For information on the generic Dart part of this file, see the
60 | # following page: https://dart.dev/tools/pub/pubspec
61 |
62 | # The following section is specific to Flutter.
63 | flutter:
64 | # The following line ensures that the Material Icons font is
65 | # included with your application, so that you can use the icons in
66 | # the material Icons class.
67 | uses-material-design: true
68 |
69 | # To add assets to your application, add an assets section, like this:
70 | assets:
71 | - assets/images/
72 | # - images/a_dot_ham.jpeg
73 |
74 | # An image asset can refer to one or more resolution-specific "variants", see
75 | # https://flutter.dev/assets-and-images/#resolution-aware.
76 |
77 | # For details regarding adding assets from package dependencies, see
78 | # https://flutter.dev/assets-and-images/#from-packages
79 |
80 | # To add custom fonts to your application, add a fonts section here,
81 | # in this "flutter" section. Each entry in this list should have a
82 | # "family" key with the font family name, and a "fonts" key with a
83 | # list giving the asset and other descriptors for the font. For
84 | # example:
85 | # fonts:
86 | # - family: Schyler
87 | # fonts:
88 | # - asset: fonts/Schyler-Regular.ttf
89 | # - asset: fonts/Schyler-Italic.ttf
90 | # style: italic
91 | # - family: Trajan Pro
92 | # fonts:
93 | # - asset: fonts/TrajanPro.ttf
94 | # - asset: fonts/TrajanPro_Bold.ttf
95 | # weight: 700
96 | #
97 | # For details regarding fonts from package dependencies,
98 | # see https://flutter.dev/custom-fonts/#from-packages
99 |
--------------------------------------------------------------------------------
/web/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 | firebase_notes
33 |
34 |
35 |
36 |
39 |
103 |
104 |
105 |
--------------------------------------------------------------------------------
/linux/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.10)
2 | project(runner LANGUAGES CXX)
3 |
4 | set(BINARY_NAME "firebase_notes")
5 | set(APPLICATION_ID "com.example.firebase_notes")
6 |
7 | cmake_policy(SET CMP0063 NEW)
8 |
9 | set(CMAKE_INSTALL_RPATH "$ORIGIN/lib")
10 |
11 | # Root filesystem for cross-building.
12 | if(FLUTTER_TARGET_PLATFORM_SYSROOT)
13 | set(CMAKE_SYSROOT ${FLUTTER_TARGET_PLATFORM_SYSROOT})
14 | set(CMAKE_FIND_ROOT_PATH ${CMAKE_SYSROOT})
15 | set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
16 | set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
17 | set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
18 | set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
19 | endif()
20 |
21 | # Configure build options.
22 | if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
23 | set(CMAKE_BUILD_TYPE "Debug" CACHE
24 | STRING "Flutter build mode" FORCE)
25 | set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS
26 | "Debug" "Profile" "Release")
27 | endif()
28 |
29 | # Compilation settings that should be applied to most targets.
30 | function(APPLY_STANDARD_SETTINGS TARGET)
31 | target_compile_features(${TARGET} PUBLIC cxx_std_14)
32 | target_compile_options(${TARGET} PRIVATE -Wall -Werror)
33 | target_compile_options(${TARGET} PRIVATE "$<$>:-O3>")
34 | target_compile_definitions(${TARGET} PRIVATE "$<$>:NDEBUG>")
35 | endfunction()
36 |
37 | set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter")
38 |
39 | # Flutter library and tool build rules.
40 | add_subdirectory(${FLUTTER_MANAGED_DIR})
41 |
42 | # System-level dependencies.
43 | find_package(PkgConfig REQUIRED)
44 | pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0)
45 |
46 | add_definitions(-DAPPLICATION_ID="${APPLICATION_ID}")
47 |
48 | # Application build
49 | add_executable(${BINARY_NAME}
50 | "main.cc"
51 | "my_application.cc"
52 | "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc"
53 | )
54 | apply_standard_settings(${BINARY_NAME})
55 | target_link_libraries(${BINARY_NAME} PRIVATE flutter)
56 | target_link_libraries(${BINARY_NAME} PRIVATE PkgConfig::GTK)
57 | add_dependencies(${BINARY_NAME} flutter_assemble)
58 | # Only the install-generated bundle's copy of the executable will launch
59 | # correctly, since the resources must in the right relative locations. To avoid
60 | # people trying to run the unbundled copy, put it in a subdirectory instead of
61 | # the default top-level location.
62 | set_target_properties(${BINARY_NAME}
63 | PROPERTIES
64 | RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/intermediates_do_not_run"
65 | )
66 |
67 | # Generated plugin build rules, which manage building the plugins and adding
68 | # them to the application.
69 | include(flutter/generated_plugins.cmake)
70 |
71 |
72 | # === Installation ===
73 | # By default, "installing" just makes a relocatable bundle in the build
74 | # directory.
75 | set(BUILD_BUNDLE_DIR "${PROJECT_BINARY_DIR}/bundle")
76 | if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
77 | set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE)
78 | endif()
79 |
80 | # Start with a clean build bundle directory every time.
81 | install(CODE "
82 | file(REMOVE_RECURSE \"${BUILD_BUNDLE_DIR}/\")
83 | " COMPONENT Runtime)
84 |
85 | set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data")
86 | set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}/lib")
87 |
88 | install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}"
89 | COMPONENT Runtime)
90 |
91 | install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}"
92 | COMPONENT Runtime)
93 |
94 | install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
95 | COMPONENT Runtime)
96 |
97 | if(PLUGIN_BUNDLED_LIBRARIES)
98 | install(FILES "${PLUGIN_BUNDLED_LIBRARIES}"
99 | DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
100 | COMPONENT Runtime)
101 | endif()
102 |
103 | # Fully re-copy the assets directory on each build to avoid having stale files
104 | # from a previous install.
105 | set(FLUTTER_ASSET_DIR_NAME "flutter_assets")
106 | install(CODE "
107 | file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\")
108 | " COMPONENT Runtime)
109 | install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}"
110 | DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime)
111 |
112 | # Install the AOT library on non-Debug builds only.
113 | if(NOT CMAKE_BUILD_TYPE MATCHES "Debug")
114 | install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}"
115 | COMPONENT Runtime)
116 | endif()
117 |
--------------------------------------------------------------------------------
/lib/views/home/food_list_page.dart:
--------------------------------------------------------------------------------
1 | import 'package:firebase_notes/constants/custom_loading.dart';
2 | import 'package:firebase_notes/services/food_service.dart';
3 | import 'package:firebase_notes/src/colors.dart';
4 | import 'package:firebase_notes/src/strings.dart';
5 | import 'package:flutter/material.dart';
6 | import 'package:cloud_firestore/cloud_firestore.dart';
7 |
8 | class FoodListPage extends StatefulWidget {
9 | const FoodListPage({Key? key}) : super(key: key);
10 |
11 | @override
12 | _FoodListPageState createState() => _FoodListPageState();
13 | }
14 |
15 | class _FoodListPageState extends State {
16 | final FoodService _foodService = FoodService();
17 |
18 | @override
19 | Widget build(BuildContext context) {
20 | return _body();
21 | }
22 |
23 | StreamBuilder _body() {
24 | return StreamBuilder(
25 | stream: _foodService.getFood(),
26 | builder: (context, snaphot) {
27 | return !snaphot.hasData
28 | ? const CustomLoading()
29 | : snaphot.data != null
30 | ? _mainBody(snaphot)
31 | : const CustomLoading();
32 | },
33 | );
34 | }
35 |
36 | ListView _mainBody(AsyncSnapshot> snaphot) {
37 | return ListView.builder(
38 | itemCount: snaphot.data?.docs.length ?? 0,
39 | itemBuilder: (context, index) {
40 | DocumentSnapshot mypost = snaphot.data!.docs[index];
41 |
42 | Future _showChoiseDialog(BuildContext context) {
43 | return showDialog(
44 | context: context,
45 | builder: (BuildContext context) {
46 | return _alertDialog(mypost);
47 | });
48 | }
49 |
50 | return Padding(
51 | padding: const EdgeInsets.all(20.0),
52 | child: InkWell(
53 | onTap: () {
54 | _showChoiseDialog(context);
55 | },
56 | child: _dietListContainer(mypost),
57 | ),
58 | );
59 | });
60 | }
61 |
62 | Container _dietListContainer(DocumentSnapshot mypost) {
63 | return Container(
64 | decoration: BoxDecoration(
65 | color: DietColors.white,
66 | borderRadius: const BorderRadius.all(Radius.circular(20)),
67 | ),
68 | child: _dietListColumn(mypost),
69 | );
70 | }
71 |
72 | Padding _dietListColumn(DocumentSnapshot mypost) {
73 | return Padding(
74 | padding: const EdgeInsets.all(20.0),
75 | child: Column(
76 | crossAxisAlignment: CrossAxisAlignment.start,
77 | children: [
78 | Text(
79 | DietText.dietList,
80 | style: const TextStyle(fontSize: 16),
81 | ),
82 | const Divider(),
83 | const SizedBox(
84 | height: 10,
85 | ),
86 | Text(
87 | "${mypost['food']}",
88 | ),
89 | const SizedBox(
90 | height: 10,
91 | ),
92 | _dietListImage(mypost),
93 | ],
94 | ),
95 | );
96 | }
97 |
98 | Container _dietListImage(DocumentSnapshot mypost) {
99 | return Container(
100 | decoration: BoxDecoration(
101 | color: DietColors.white,
102 | borderRadius: const BorderRadius.all(Radius.circular(20)),
103 | ),
104 | child: Padding(
105 | padding: const EdgeInsets.all(10.0),
106 | child: ClipRRect(
107 | borderRadius: BorderRadius.circular(20),
108 | child: Image.network(mypost['image']),
109 | ),
110 | ),
111 | );
112 | }
113 |
114 | AlertDialog _alertDialog(DocumentSnapshot mypost) {
115 | return AlertDialog(
116 | title: Text(
117 | DietText.alertDialogTitle,
118 | textAlign: TextAlign.center,
119 | ),
120 | shape: const RoundedRectangleBorder(
121 | borderRadius: BorderRadius.all(
122 | Radius.circular(20.0),
123 | ),
124 | ),
125 | content: _alertDialogContent(mypost),
126 | );
127 | }
128 |
129 | Row _alertDialogContent(DocumentSnapshot mypost) {
130 | return Row(
131 | mainAxisAlignment: MainAxisAlignment.spaceAround,
132 | children: [
133 | _removeButton(mypost),
134 | _giveUpButton(),
135 | ],
136 | );
137 | }
138 |
139 | InkWell _removeButton(DocumentSnapshot mypost) {
140 | return InkWell(
141 | onTap: () {
142 | _foodService.removeFood(mypost.id);
143 | Navigator.pop(context);
144 | },
145 | child: Container(
146 | width: 100,
147 | decoration: BoxDecoration(
148 | color: DietColors.orange,
149 | borderRadius: BorderRadius.circular(10),
150 | ),
151 | child: Padding(
152 | padding: const EdgeInsets.symmetric(vertical: 10),
153 | child: Text(
154 | DietText.removeText,
155 | style: TextStyle(color: DietColors.white),
156 | textAlign: TextAlign.center,
157 | ),
158 | ),
159 | ),
160 | );
161 | }
162 |
163 | InkWell _giveUpButton() {
164 | return InkWell(
165 | onTap: () {
166 | Navigator.pop(context);
167 | },
168 | child: Container(
169 | width: 100,
170 | decoration: BoxDecoration(
171 | color: DietColors.orange,
172 | borderRadius: BorderRadius.circular(10),
173 | ),
174 | child: Padding(
175 | padding: const EdgeInsets.symmetric(vertical: 10),
176 | child: Text(
177 | DietText.giveUpText,
178 | style: TextStyle(color: DietColors.white),
179 | textAlign: TextAlign.center,
180 | ),
181 | ),
182 | ),
183 | );
184 | }
185 | }
186 |
--------------------------------------------------------------------------------
/windows/runner/win32_window.cpp:
--------------------------------------------------------------------------------
1 | #include "win32_window.h"
2 |
3 | #include
4 |
5 | #include "resource.h"
6 |
7 | namespace {
8 |
9 | constexpr const wchar_t kWindowClassName[] = L"FLUTTER_RUNNER_WIN32_WINDOW";
10 |
11 | // The number of Win32Window objects that currently exist.
12 | static int g_active_window_count = 0;
13 |
14 | using EnableNonClientDpiScaling = BOOL __stdcall(HWND hwnd);
15 |
16 | // Scale helper to convert logical scaler values to physical using passed in
17 | // scale factor
18 | int Scale(int source, double scale_factor) {
19 | return static_cast(source * scale_factor);
20 | }
21 |
22 | // Dynamically loads the |EnableNonClientDpiScaling| from the User32 module.
23 | // This API is only needed for PerMonitor V1 awareness mode.
24 | void EnableFullDpiSupportIfAvailable(HWND hwnd) {
25 | HMODULE user32_module = LoadLibraryA("User32.dll");
26 | if (!user32_module) {
27 | return;
28 | }
29 | auto enable_non_client_dpi_scaling =
30 | reinterpret_cast(
31 | GetProcAddress(user32_module, "EnableNonClientDpiScaling"));
32 | if (enable_non_client_dpi_scaling != nullptr) {
33 | enable_non_client_dpi_scaling(hwnd);
34 | FreeLibrary(user32_module);
35 | }
36 | }
37 |
38 | } // namespace
39 |
40 | // Manages the Win32Window's window class registration.
41 | class WindowClassRegistrar {
42 | public:
43 | ~WindowClassRegistrar() = default;
44 |
45 | // Returns the singleton registar instance.
46 | static WindowClassRegistrar* GetInstance() {
47 | if (!instance_) {
48 | instance_ = new WindowClassRegistrar();
49 | }
50 | return instance_;
51 | }
52 |
53 | // Returns the name of the window class, registering the class if it hasn't
54 | // previously been registered.
55 | const wchar_t* GetWindowClass();
56 |
57 | // Unregisters the window class. Should only be called if there are no
58 | // instances of the window.
59 | void UnregisterWindowClass();
60 |
61 | private:
62 | WindowClassRegistrar() = default;
63 |
64 | static WindowClassRegistrar* instance_;
65 |
66 | bool class_registered_ = false;
67 | };
68 |
69 | WindowClassRegistrar* WindowClassRegistrar::instance_ = nullptr;
70 |
71 | const wchar_t* WindowClassRegistrar::GetWindowClass() {
72 | if (!class_registered_) {
73 | WNDCLASS window_class{};
74 | window_class.hCursor = LoadCursor(nullptr, IDC_ARROW);
75 | window_class.lpszClassName = kWindowClassName;
76 | window_class.style = CS_HREDRAW | CS_VREDRAW;
77 | window_class.cbClsExtra = 0;
78 | window_class.cbWndExtra = 0;
79 | window_class.hInstance = GetModuleHandle(nullptr);
80 | window_class.hIcon =
81 | LoadIcon(window_class.hInstance, MAKEINTRESOURCE(IDI_APP_ICON));
82 | window_class.hbrBackground = 0;
83 | window_class.lpszMenuName = nullptr;
84 | window_class.lpfnWndProc = Win32Window::WndProc;
85 | RegisterClass(&window_class);
86 | class_registered_ = true;
87 | }
88 | return kWindowClassName;
89 | }
90 |
91 | void WindowClassRegistrar::UnregisterWindowClass() {
92 | UnregisterClass(kWindowClassName, nullptr);
93 | class_registered_ = false;
94 | }
95 |
96 | Win32Window::Win32Window() {
97 | ++g_active_window_count;
98 | }
99 |
100 | Win32Window::~Win32Window() {
101 | --g_active_window_count;
102 | Destroy();
103 | }
104 |
105 | bool Win32Window::CreateAndShow(const std::wstring& title,
106 | const Point& origin,
107 | const Size& size) {
108 | Destroy();
109 |
110 | const wchar_t* window_class =
111 | WindowClassRegistrar::GetInstance()->GetWindowClass();
112 |
113 | const POINT target_point = {static_cast(origin.x),
114 | static_cast(origin.y)};
115 | HMONITOR monitor = MonitorFromPoint(target_point, MONITOR_DEFAULTTONEAREST);
116 | UINT dpi = FlutterDesktopGetDpiForMonitor(monitor);
117 | double scale_factor = dpi / 96.0;
118 |
119 | HWND window = CreateWindow(
120 | window_class, title.c_str(), WS_OVERLAPPEDWINDOW | WS_VISIBLE,
121 | Scale(origin.x, scale_factor), Scale(origin.y, scale_factor),
122 | Scale(size.width, scale_factor), Scale(size.height, scale_factor),
123 | nullptr, nullptr, GetModuleHandle(nullptr), this);
124 |
125 | if (!window) {
126 | return false;
127 | }
128 |
129 | return OnCreate();
130 | }
131 |
132 | // static
133 | LRESULT CALLBACK Win32Window::WndProc(HWND const window,
134 | UINT const message,
135 | WPARAM const wparam,
136 | LPARAM const lparam) noexcept {
137 | if (message == WM_NCCREATE) {
138 | auto window_struct = reinterpret_cast(lparam);
139 | SetWindowLongPtr(window, GWLP_USERDATA,
140 | reinterpret_cast(window_struct->lpCreateParams));
141 |
142 | auto that = static_cast(window_struct->lpCreateParams);
143 | EnableFullDpiSupportIfAvailable(window);
144 | that->window_handle_ = window;
145 | } else if (Win32Window* that = GetThisFromHandle(window)) {
146 | return that->MessageHandler(window, message, wparam, lparam);
147 | }
148 |
149 | return DefWindowProc(window, message, wparam, lparam);
150 | }
151 |
152 | LRESULT
153 | Win32Window::MessageHandler(HWND hwnd,
154 | UINT const message,
155 | WPARAM const wparam,
156 | LPARAM const lparam) noexcept {
157 | switch (message) {
158 | case WM_DESTROY:
159 | window_handle_ = nullptr;
160 | Destroy();
161 | if (quit_on_close_) {
162 | PostQuitMessage(0);
163 | }
164 | return 0;
165 |
166 | case WM_DPICHANGED: {
167 | auto newRectSize = reinterpret_cast(lparam);
168 | LONG newWidth = newRectSize->right - newRectSize->left;
169 | LONG newHeight = newRectSize->bottom - newRectSize->top;
170 |
171 | SetWindowPos(hwnd, nullptr, newRectSize->left, newRectSize->top, newWidth,
172 | newHeight, SWP_NOZORDER | SWP_NOACTIVATE);
173 |
174 | return 0;
175 | }
176 | case WM_SIZE: {
177 | RECT rect = GetClientArea();
178 | if (child_content_ != nullptr) {
179 | // Size and position the child window.
180 | MoveWindow(child_content_, rect.left, rect.top, rect.right - rect.left,
181 | rect.bottom - rect.top, TRUE);
182 | }
183 | return 0;
184 | }
185 |
186 | case WM_ACTIVATE:
187 | if (child_content_ != nullptr) {
188 | SetFocus(child_content_);
189 | }
190 | return 0;
191 | }
192 |
193 | return DefWindowProc(window_handle_, message, wparam, lparam);
194 | }
195 |
196 | void Win32Window::Destroy() {
197 | OnDestroy();
198 |
199 | if (window_handle_) {
200 | DestroyWindow(window_handle_);
201 | window_handle_ = nullptr;
202 | }
203 | if (g_active_window_count == 0) {
204 | WindowClassRegistrar::GetInstance()->UnregisterWindowClass();
205 | }
206 | }
207 |
208 | Win32Window* Win32Window::GetThisFromHandle(HWND const window) noexcept {
209 | return reinterpret_cast(
210 | GetWindowLongPtr(window, GWLP_USERDATA));
211 | }
212 |
213 | void Win32Window::SetChildContent(HWND content) {
214 | child_content_ = content;
215 | SetParent(content, window_handle_);
216 | RECT frame = GetClientArea();
217 |
218 | MoveWindow(content, frame.left, frame.top, frame.right - frame.left,
219 | frame.bottom - frame.top, true);
220 |
221 | SetFocus(child_content_);
222 | }
223 |
224 | RECT Win32Window::GetClientArea() {
225 | RECT frame;
226 | GetClientRect(window_handle_, &frame);
227 | return frame;
228 | }
229 |
230 | HWND Win32Window::GetHandle() {
231 | return window_handle_;
232 | }
233 |
234 | void Win32Window::SetQuitOnClose(bool quit_on_close) {
235 | quit_on_close_ = quit_on_close;
236 | }
237 |
238 | bool Win32Window::OnCreate() {
239 | // No-op; provided for subclasses.
240 | return true;
241 | }
242 |
243 | void Win32Window::OnDestroy() {
244 | // No-op; provided for subclasses.
245 | }
246 |
--------------------------------------------------------------------------------
/lib/views/add_food/add_food_page.dart:
--------------------------------------------------------------------------------
1 | import 'dart:io';
2 | import 'package:firebase_notes/constants/custom_app_bar.dart';
3 | import 'package:firebase_notes/constants/custom_loading.dart';
4 | import 'package:firebase_notes/services/food_service.dart';
5 | import 'package:firebase_notes/src/colors.dart';
6 | import 'package:firebase_notes/src/images.dart';
7 | import 'package:firebase_notes/src/strings.dart';
8 | import 'package:flutter/material.dart';
9 | import 'package:fluttertoast/fluttertoast.dart';
10 | import 'package:image_picker/image_picker.dart';
11 |
12 | class AddFoodPage extends StatefulWidget {
13 | const AddFoodPage({Key? key}) : super(key: key);
14 |
15 | @override
16 | _AddFoodPageState createState() => _AddFoodPageState();
17 | }
18 |
19 | class _AddFoodPageState extends State {
20 | final TextEditingController _foodController = TextEditingController();
21 | final FoodService _foodService = FoodService();
22 |
23 | final ImagePicker _pickerImage = ImagePicker();
24 | dynamic _pickImage;
25 | dynamic _foodImage;
26 | bool _isLoading = false;
27 |
28 | @override
29 | Widget build(BuildContext context) {
30 | return Scaffold(
31 | backgroundColor: DietColors.mainColor,
32 | appBar: CustomAppBar(DietText.addFoodText),
33 | body: _body(),
34 | );
35 | }
36 |
37 | Stack _body() {
38 | return Stack(
39 | children: [
40 | Padding(
41 | padding: const EdgeInsets.all(20.0),
42 | child: Column(
43 | children: [
44 | _mainBody(),
45 | _saveButton(context),
46 | ],
47 | ),
48 | ),
49 | if (_isLoading) const CustomLoading(),
50 | ],
51 | );
52 | }
53 |
54 | Flexible _mainBody() {
55 | return Flexible(
56 | child: ListView(
57 | children: [
58 | _bodyTitle(),
59 | const SizedBox(
60 | height: 20,
61 | ),
62 | _bodyImage(),
63 | const SizedBox(
64 | height: 30,
65 | ),
66 | _bodyContainer(),
67 | ],
68 | ),
69 | );
70 | }
71 |
72 | Widget _bodyTitle() {
73 | return Container(
74 | decoration: BoxDecoration(
75 | color: DietColors.white,
76 | borderRadius: const BorderRadius.all(
77 | Radius.circular(10),
78 | ),
79 | ),
80 | child: Padding(
81 | padding: const EdgeInsets.all(20.0),
82 | child: Text(
83 | DietText.addSomeFoodsTitle,
84 | ),
85 | ),
86 | );
87 | }
88 |
89 | Container _bodyContainer() {
90 | return Container(
91 | decoration: BoxDecoration(
92 | color: DietColors.white,
93 | borderRadius: const BorderRadius.all(
94 | Radius.circular(20),
95 | ),
96 | ),
97 | child: Padding(
98 | padding: const EdgeInsets.all(20.0),
99 | child: _foodTextField(),
100 | ),
101 | );
102 | }
103 |
104 | TextField _foodTextField() {
105 | return TextField(
106 | cursorColor: DietColors.orange,
107 | controller: _foodController,
108 | maxLines: 7,
109 | decoration: InputDecoration(
110 | hintText: DietText.addSomeFoodsText,
111 | enabledBorder: UnderlineInputBorder(
112 | borderSide: BorderSide(
113 | color: DietColors.white,
114 | ),
115 | ),
116 | focusedBorder: UnderlineInputBorder(
117 | borderSide: BorderSide(
118 | color: DietColors.white,
119 | ),
120 | ),
121 | border: UnderlineInputBorder(
122 | borderSide: BorderSide(
123 | color: DietColors.white,
124 | ),
125 | ),
126 | ));
127 | }
128 |
129 | Column _bodyImage() {
130 | return Column(
131 | children: [
132 | Center(
133 | child: _imagePlace(),
134 | ),
135 | const SizedBox(
136 | height: 10,
137 | ),
138 | _imageRow(),
139 | ],
140 | );
141 | }
142 |
143 | Row _imageRow() {
144 | return Row(
145 | mainAxisAlignment: MainAxisAlignment.end,
146 | children: [
147 | _cameraContainer(),
148 | const SizedBox(
149 | width: 10,
150 | ),
151 | _galeryContainer(),
152 | ],
153 | );
154 | }
155 |
156 | Container _cameraContainer() {
157 | return Container(
158 | decoration: BoxDecoration(
159 | color: DietColors.white,
160 | borderRadius: const BorderRadius.all(
161 | Radius.circular(10),
162 | ),
163 | ),
164 | child: IconButton(
165 | icon: Icon(
166 | Icons.camera_alt,
167 | color: DietColors.orange,
168 | ),
169 | onPressed: () => _onImageButtonPressed(
170 | ImageSource.camera,
171 | context: context,
172 | ),
173 | ),
174 | );
175 | }
176 |
177 | Container _galeryContainer() {
178 | return Container(
179 | decoration: BoxDecoration(
180 | color: DietColors.white,
181 | borderRadius: const BorderRadius.all(
182 | Radius.circular(10),
183 | ),
184 | ),
185 | child: IconButton(
186 | icon: Icon(
187 | Icons.image,
188 | color: DietColors.orange,
189 | ),
190 | onPressed: () => _onImageButtonPressed(
191 | ImageSource.gallery,
192 | context: context,
193 | ),
194 | ),
195 | );
196 | }
197 |
198 | Container _imagePlace() {
199 | if (_foodImage != null) {
200 | return _fileImage();
201 | } else {
202 | if (_pickImage != null) {
203 | return _networkImage();
204 | } else {
205 | return _circleImage();
206 | }
207 | }
208 | }
209 |
210 | Container _fileImage() {
211 | return Container(
212 | decoration: BoxDecoration(
213 | color: DietColors.white,
214 | borderRadius: const BorderRadius.all(
215 | Radius.circular(20),
216 | ),
217 | ),
218 | child: Padding(
219 | padding: const EdgeInsets.all(10.0),
220 | child: ClipRRect(
221 | borderRadius: BorderRadius.circular(20),
222 | child: Image.file(
223 | File(_foodImage!.path),
224 | ),
225 | ),
226 | ),
227 | );
228 | }
229 |
230 | Container _networkImage() {
231 | return Container(
232 | decoration: BoxDecoration(
233 | color: DietColors.white,
234 | borderRadius: const BorderRadius.all(
235 | Radius.circular(20),
236 | ),
237 | ),
238 | child: Padding(
239 | padding: const EdgeInsets.all(10.0),
240 | child: ClipRRect(
241 | borderRadius: BorderRadius.circular(20),
242 | child: Image.network(_pickImage)),
243 | ),
244 | );
245 | }
246 |
247 | Container _circleImage() {
248 | double height = MediaQuery.of(context).size.height;
249 | return Container(
250 | decoration: BoxDecoration(
251 | color: DietColors.white,
252 | shape: BoxShape.circle,
253 | ),
254 | child: Padding(
255 | padding: const EdgeInsets.all(10.0),
256 | child: CircleAvatar(
257 | backgroundImage: AssetImage(DietImages.popcorn),
258 | radius: height * 0.08,
259 | ),
260 | ),
261 | );
262 | }
263 |
264 | Padding _saveButton(BuildContext context) {
265 | return Padding(
266 | padding: const EdgeInsets.only(bottom: 10.0),
267 | child: InkWell(
268 | onTap: () => _saveButtonOnTap(),
269 | child: Container(
270 | decoration: BoxDecoration(
271 | color: DietColors.orange,
272 | borderRadius: BorderRadius.circular(10),
273 | ),
274 | height: 40,
275 | child: Center(
276 | child: Text(
277 | DietText.addText,
278 | style: TextStyle(
279 | color: DietColors.white,
280 | ),
281 | ),
282 | ),
283 | )),
284 | );
285 | }
286 |
287 | void _saveButtonOnTap() {
288 | if (_foodController.text.isNotEmpty && _foodImage != null) {
289 | setState(() {
290 | _isLoading = true;
291 | });
292 | _foodService
293 | .addFood(_foodController.text, _foodImage ?? '')
294 | .then((value) {
295 | Navigator.pop(context);
296 | }).catchError((error) {
297 | _warningToast(DietText.errorText);
298 | }).whenComplete(() {
299 | setState(() {
300 | _isLoading = false;
301 | });
302 | });
303 | } else {
304 | _warningToast(DietText.emptyText);
305 | }
306 | }
307 |
308 | Future _warningToast(String text) {
309 | return Fluttertoast.showToast(
310 | msg: text,
311 | timeInSecForIosWeb: 2,
312 | toastLength: Toast.LENGTH_SHORT,
313 | gravity: ToastGravity.CENTER,
314 | backgroundColor: DietColors.red,
315 | textColor: DietColors.white,
316 | fontSize: 14);
317 | }
318 |
319 | void _onImageButtonPressed(
320 | ImageSource source, {
321 | required BuildContext context,
322 | }) async {
323 | try {
324 | final pickedFile = await _pickerImage.pickImage(source: source);
325 | setState(() {
326 | _foodImage = pickedFile!;
327 | });
328 | } catch (error) {
329 | setState(() {
330 | _pickImage = error;
331 | });
332 | }
333 | }
334 | }
335 |
--------------------------------------------------------------------------------
/lib/views/login/login_page.dart:
--------------------------------------------------------------------------------
1 | import 'package:firebase_crashlytics/firebase_crashlytics.dart';
2 | import 'package:firebase_notes/constants/custom_app_bar.dart';
3 | import 'package:firebase_notes/constants/custom_loading.dart';
4 | import 'package:firebase_notes/services/auth_service.dart';
5 | import 'package:firebase_notes/src/colors.dart';
6 | import 'package:firebase_notes/src/strings.dart';
7 | import 'package:firebase_notes/views/home/home_page.dart';
8 | import 'package:flutter/material.dart';
9 | import 'package:fluttertoast/fluttertoast.dart';
10 | import 'package:font_awesome_flutter/font_awesome_flutter.dart';
11 |
12 | class LoginPage extends StatefulWidget {
13 | const LoginPage({Key? key}) : super(key: key);
14 |
15 | @override
16 | _LoginPageState createState() => _LoginPageState();
17 | }
18 |
19 | class _LoginPageState extends State {
20 | final TextEditingController _emailController = TextEditingController();
21 | final TextEditingController _passwordController = TextEditingController();
22 |
23 | bool _isVisible = true;
24 | bool _isLoading = false;
25 |
26 | final AuthService _authService = AuthService();
27 |
28 | @override
29 | Widget build(BuildContext context) {
30 | return Scaffold(
31 | backgroundColor: DietColors.mainColor,
32 | appBar: CustomAppBar(DietText.loginText),
33 | body: _body(context));
34 | }
35 |
36 | Stack _body(BuildContext context) {
37 | return Stack(
38 | children: [
39 | Padding(
40 | padding: const EdgeInsets.fromLTRB(20, 50, 20, 30),
41 | child: Column(
42 | crossAxisAlignment: CrossAxisAlignment.stretch,
43 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
44 | children: [
45 | _bodyContainer(),
46 | _errorButton(),
47 | ],
48 | ),
49 | ),
50 | if (_isLoading) const CustomLoading()
51 | ],
52 | );
53 | }
54 |
55 | Flexible _bodyContainer() {
56 | return Flexible(
57 | child: Container(
58 | decoration: BoxDecoration(
59 | color: DietColors.white,
60 | borderRadius: const BorderRadius.all(Radius.circular(20)),
61 | ),
62 | child: Padding(
63 | padding: const EdgeInsets.all(20),
64 | child: SingleChildScrollView(
65 | child: Column(
66 | crossAxisAlignment: CrossAxisAlignment.start,
67 | children: [
68 | _emailTextField(),
69 | const SizedBox(
70 | height: 20,
71 | ),
72 | _passwordTextField(),
73 | const SizedBox(
74 | height: 20,
75 | ),
76 | _loginButton(),
77 | const SizedBox(
78 | height: 20,
79 | ),
80 | const Divider(),
81 | const SizedBox(
82 | height: 20,
83 | ),
84 | _googleButton(),
85 | ],
86 | ),
87 | ),
88 | ),
89 | ),
90 | );
91 | }
92 |
93 | TextField _emailTextField() {
94 | return TextField(
95 | controller: _emailController,
96 | cursorColor: DietColors.black,
97 | keyboardType: TextInputType.emailAddress,
98 | decoration: InputDecoration(
99 | prefixIcon: Icon(
100 | Icons.mail,
101 | color: DietColors.orange,
102 | ),
103 | hintText: DietText.email,
104 | enabledBorder: OutlineInputBorder(
105 | borderSide: BorderSide(color: DietColors.mainColor),
106 | borderRadius: BorderRadius.circular(10),
107 | ),
108 | focusedBorder: OutlineInputBorder(
109 | borderSide: BorderSide(color: DietColors.orange),
110 | borderRadius: BorderRadius.circular(10),
111 | ),
112 | ),
113 | );
114 | }
115 |
116 | TextField _passwordTextField() {
117 | return TextField(
118 | controller: _passwordController,
119 | obscureText: _isVisible ? true : false,
120 | cursorColor: DietColors.black,
121 | decoration: InputDecoration(
122 | suffixIcon: InkWell(
123 | onTap: () {
124 | if (_isVisible) {
125 | setState(() {
126 | _isVisible = false;
127 | });
128 | } else {
129 | setState(() {
130 | _isVisible = false;
131 | });
132 | _isVisible = true;
133 | }
134 | },
135 | child: _isVisible
136 | ? Icon(
137 | Icons.remove_red_eye,
138 | color: DietColors.orange,
139 | )
140 | : Icon(
141 | Icons.remove_red_eye_outlined,
142 | color: DietColors.orange,
143 | ),
144 | ),
145 | prefixIcon: Icon(
146 | Icons.vpn_key,
147 | color: DietColors.orange,
148 | ),
149 | hintText: DietText.password,
150 | enabledBorder: OutlineInputBorder(
151 | borderSide: BorderSide(color: DietColors.mainColor),
152 | borderRadius: BorderRadius.circular(10),
153 | ),
154 | focusedBorder: OutlineInputBorder(
155 | borderSide: BorderSide(color: DietColors.orange),
156 | borderRadius: BorderRadius.circular(10),
157 | ),
158 | ),
159 | );
160 | }
161 |
162 | InkWell _loginButton() {
163 | return InkWell(
164 | onTap: () => _loginWithEmail(),
165 | child: Container(
166 | decoration: BoxDecoration(
167 | color: DietColors.orange,
168 | borderRadius: BorderRadius.circular(10),
169 | ),
170 | height: 40,
171 | child: Center(
172 | child: Text(
173 | DietText.loginText,
174 | style: TextStyle(
175 | color: DietColors.white,
176 | ),
177 | ),
178 | ),
179 | ));
180 | }
181 |
182 | void _loginWithEmail() {
183 | if (_emailController.text.isNotEmpty &&
184 | _passwordController.text.isNotEmpty) {
185 | setState(() {
186 | _isLoading = true;
187 | });
188 |
189 | _authService
190 | .signInWithEmail(
191 | _emailController.text,
192 | _passwordController.text,
193 | )
194 | .then((value) {
195 | Navigator.pushAndRemoveUntil(
196 | context,
197 | MaterialPageRoute(builder: (context) => const HomePage()),
198 | (route) => false);
199 | }).catchError((error) {
200 | if (error.toString().contains('invalid-email')) {
201 | _warningToast(DietText.loginWrongEmailText);
202 | } else if (error.toString().contains('user-not-found')) {
203 | _warningToast(DietText.loginNoAccountText);
204 | } else if (error.toString().contains('wrong-password')) {
205 | _warningToast(DietText.loginWrongPasswordText);
206 | } else {
207 | _warningToast(DietText.errorText);
208 | }
209 | }).whenComplete(() {
210 | setState(() {
211 | _isLoading = false;
212 | });
213 | });
214 | } else {
215 | _warningToast(DietText.emptyText);
216 | }
217 | }
218 |
219 | Future _warningToast(String text) {
220 | return Fluttertoast.showToast(
221 | msg: text,
222 | timeInSecForIosWeb: 2,
223 | toastLength: Toast.LENGTH_SHORT,
224 | gravity: ToastGravity.BOTTOM,
225 | backgroundColor: DietColors.red,
226 | textColor: DietColors.white,
227 | fontSize: 14);
228 | }
229 |
230 | InkWell _googleButton() {
231 | return InkWell(
232 | onTap: () => _loginWithGoogle(),
233 | child: Container(
234 | padding: const EdgeInsets.symmetric(vertical: 5),
235 | decoration: BoxDecoration(
236 | border: Border.all(color: DietColors.red, width: 2),
237 | color: DietColors.red,
238 | borderRadius: const BorderRadius.all(Radius.circular(10))),
239 | child: Padding(
240 | padding: const EdgeInsets.all(5.0),
241 | child: _googleButtonBody(),
242 | ),
243 | ),
244 | );
245 | }
246 |
247 | Center _googleButtonBody() {
248 | return Center(
249 | child: Row(
250 | mainAxisAlignment: MainAxisAlignment.center,
251 | children: [
252 | FaIcon(
253 | FontAwesomeIcons.google,
254 | color: DietColors.white,
255 | ),
256 | const SizedBox(
257 | width: 10,
258 | ),
259 | Text(
260 | DietText.googleLogin,
261 | style: TextStyle(color: DietColors.white),
262 | ),
263 | ],
264 | ));
265 | }
266 |
267 | void _loginWithGoogle() {
268 | _authService.signInWithGoogle().then((value) {
269 | return Navigator.pushAndRemoveUntil(
270 | context,
271 | MaterialPageRoute(builder: (context) => const HomePage()),
272 | (route) => false);
273 | });
274 | }
275 |
276 | InkWell _errorButton() {
277 | return InkWell(
278 | onTap: () => _errorButtonOnTap(),
279 | child: Container(
280 | decoration: BoxDecoration(
281 | color: DietColors.white,
282 | borderRadius: BorderRadius.circular(10),
283 | ),
284 | height: 40,
285 | child: Center(
286 | child: Text(
287 | DietText.crashlytics,
288 | style: TextStyle(
289 | color: DietColors.black,
290 | ),
291 | ),
292 | ),
293 | ));
294 | }
295 |
296 | void _errorButtonOnTap() {
297 | FirebaseCrashlytics.instance.crash();
298 | FirebaseCrashlytics.instance.setCrashlyticsCollectionEnabled(true);
299 | FirebaseCrashlytics.instance.setCustomKey('str_key', 'hello');
300 | }
301 | }
302 |
--------------------------------------------------------------------------------
/pubspec.lock:
--------------------------------------------------------------------------------
1 | # Generated by pub
2 | # See https://dart.dev/tools/pub/glossary#lockfile
3 | packages:
4 | async:
5 | dependency: transitive
6 | description:
7 | name: async
8 | url: "https://pub.dartlang.org"
9 | source: hosted
10 | version: "2.8.2"
11 | boolean_selector:
12 | dependency: transitive
13 | description:
14 | name: boolean_selector
15 | url: "https://pub.dartlang.org"
16 | source: hosted
17 | version: "2.1.0"
18 | characters:
19 | dependency: transitive
20 | description:
21 | name: characters
22 | url: "https://pub.dartlang.org"
23 | source: hosted
24 | version: "1.2.0"
25 | charcode:
26 | dependency: transitive
27 | description:
28 | name: charcode
29 | url: "https://pub.dartlang.org"
30 | source: hosted
31 | version: "1.3.1"
32 | clock:
33 | dependency: transitive
34 | description:
35 | name: clock
36 | url: "https://pub.dartlang.org"
37 | source: hosted
38 | version: "1.1.0"
39 | cloud_firestore:
40 | dependency: "direct main"
41 | description:
42 | name: cloud_firestore
43 | url: "https://pub.dartlang.org"
44 | source: hosted
45 | version: "3.1.6"
46 | cloud_firestore_platform_interface:
47 | dependency: transitive
48 | description:
49 | name: cloud_firestore_platform_interface
50 | url: "https://pub.dartlang.org"
51 | source: hosted
52 | version: "5.4.11"
53 | cloud_firestore_web:
54 | dependency: transitive
55 | description:
56 | name: cloud_firestore_web
57 | url: "https://pub.dartlang.org"
58 | source: hosted
59 | version: "2.6.6"
60 | collection:
61 | dependency: transitive
62 | description:
63 | name: collection
64 | url: "https://pub.dartlang.org"
65 | source: hosted
66 | version: "1.15.0"
67 | cross_file:
68 | dependency: transitive
69 | description:
70 | name: cross_file
71 | url: "https://pub.dartlang.org"
72 | source: hosted
73 | version: "0.3.2"
74 | cupertino_icons:
75 | dependency: "direct main"
76 | description:
77 | name: cupertino_icons
78 | url: "https://pub.dartlang.org"
79 | source: hosted
80 | version: "1.0.4"
81 | fake_async:
82 | dependency: transitive
83 | description:
84 | name: fake_async
85 | url: "https://pub.dartlang.org"
86 | source: hosted
87 | version: "1.2.0"
88 | firebase_auth:
89 | dependency: "direct main"
90 | description:
91 | name: firebase_auth
92 | url: "https://pub.dartlang.org"
93 | source: hosted
94 | version: "3.3.5"
95 | firebase_auth_platform_interface:
96 | dependency: transitive
97 | description:
98 | name: firebase_auth_platform_interface
99 | url: "https://pub.dartlang.org"
100 | source: hosted
101 | version: "6.1.10"
102 | firebase_auth_web:
103 | dependency: transitive
104 | description:
105 | name: firebase_auth_web
106 | url: "https://pub.dartlang.org"
107 | source: hosted
108 | version: "3.3.6"
109 | firebase_core:
110 | dependency: "direct main"
111 | description:
112 | name: firebase_core
113 | url: "https://pub.dartlang.org"
114 | source: hosted
115 | version: "1.11.0"
116 | firebase_core_platform_interface:
117 | dependency: transitive
118 | description:
119 | name: firebase_core_platform_interface
120 | url: "https://pub.dartlang.org"
121 | source: hosted
122 | version: "4.2.3"
123 | firebase_core_web:
124 | dependency: transitive
125 | description:
126 | name: firebase_core_web
127 | url: "https://pub.dartlang.org"
128 | source: hosted
129 | version: "1.5.3"
130 | firebase_crashlytics:
131 | dependency: "direct main"
132 | description:
133 | name: firebase_crashlytics
134 | url: "https://pub.dartlang.org"
135 | source: hosted
136 | version: "2.4.5"
137 | firebase_crashlytics_platform_interface:
138 | dependency: transitive
139 | description:
140 | name: firebase_crashlytics_platform_interface
141 | url: "https://pub.dartlang.org"
142 | source: hosted
143 | version: "3.1.12"
144 | firebase_messaging:
145 | dependency: "direct main"
146 | description:
147 | name: firebase_messaging
148 | url: "https://pub.dartlang.org"
149 | source: hosted
150 | version: "11.2.5"
151 | firebase_messaging_platform_interface:
152 | dependency: transitive
153 | description:
154 | name: firebase_messaging_platform_interface
155 | url: "https://pub.dartlang.org"
156 | source: hosted
157 | version: "3.1.5"
158 | firebase_messaging_web:
159 | dependency: transitive
160 | description:
161 | name: firebase_messaging_web
162 | url: "https://pub.dartlang.org"
163 | source: hosted
164 | version: "2.2.6"
165 | firebase_storage:
166 | dependency: "direct main"
167 | description:
168 | name: firebase_storage
169 | url: "https://pub.dartlang.org"
170 | source: hosted
171 | version: "10.2.5"
172 | firebase_storage_platform_interface:
173 | dependency: transitive
174 | description:
175 | name: firebase_storage_platform_interface
176 | url: "https://pub.dartlang.org"
177 | source: hosted
178 | version: "4.0.12"
179 | firebase_storage_web:
180 | dependency: transitive
181 | description:
182 | name: firebase_storage_web
183 | url: "https://pub.dartlang.org"
184 | source: hosted
185 | version: "3.2.6"
186 | flutter:
187 | dependency: "direct main"
188 | description: flutter
189 | source: sdk
190 | version: "0.0.0"
191 | flutter_lints:
192 | dependency: "direct dev"
193 | description:
194 | name: flutter_lints
195 | url: "https://pub.dartlang.org"
196 | source: hosted
197 | version: "1.0.4"
198 | flutter_plugin_android_lifecycle:
199 | dependency: transitive
200 | description:
201 | name: flutter_plugin_android_lifecycle
202 | url: "https://pub.dartlang.org"
203 | source: hosted
204 | version: "2.0.5"
205 | flutter_test:
206 | dependency: "direct dev"
207 | description: flutter
208 | source: sdk
209 | version: "0.0.0"
210 | flutter_web_plugins:
211 | dependency: transitive
212 | description: flutter
213 | source: sdk
214 | version: "0.0.0"
215 | fluttertoast:
216 | dependency: "direct main"
217 | description:
218 | name: fluttertoast
219 | url: "https://pub.dartlang.org"
220 | source: hosted
221 | version: "8.0.8"
222 | font_awesome_flutter:
223 | dependency: "direct main"
224 | description:
225 | name: font_awesome_flutter
226 | url: "https://pub.dartlang.org"
227 | source: hosted
228 | version: "9.2.0"
229 | google_sign_in:
230 | dependency: "direct main"
231 | description:
232 | name: google_sign_in
233 | url: "https://pub.dartlang.org"
234 | source: hosted
235 | version: "5.2.1"
236 | google_sign_in_platform_interface:
237 | dependency: transitive
238 | description:
239 | name: google_sign_in_platform_interface
240 | url: "https://pub.dartlang.org"
241 | source: hosted
242 | version: "2.1.0"
243 | google_sign_in_web:
244 | dependency: transitive
245 | description:
246 | name: google_sign_in_web
247 | url: "https://pub.dartlang.org"
248 | source: hosted
249 | version: "0.10.0+3"
250 | http:
251 | dependency: transitive
252 | description:
253 | name: http
254 | url: "https://pub.dartlang.org"
255 | source: hosted
256 | version: "0.13.4"
257 | http_parser:
258 | dependency: transitive
259 | description:
260 | name: http_parser
261 | url: "https://pub.dartlang.org"
262 | source: hosted
263 | version: "4.0.0"
264 | image_picker:
265 | dependency: "direct main"
266 | description:
267 | name: image_picker
268 | url: "https://pub.dartlang.org"
269 | source: hosted
270 | version: "0.8.4+4"
271 | image_picker_for_web:
272 | dependency: transitive
273 | description:
274 | name: image_picker_for_web
275 | url: "https://pub.dartlang.org"
276 | source: hosted
277 | version: "2.1.4"
278 | image_picker_platform_interface:
279 | dependency: transitive
280 | description:
281 | name: image_picker_platform_interface
282 | url: "https://pub.dartlang.org"
283 | source: hosted
284 | version: "2.4.2"
285 | intl:
286 | dependency: transitive
287 | description:
288 | name: intl
289 | url: "https://pub.dartlang.org"
290 | source: hosted
291 | version: "0.17.0"
292 | js:
293 | dependency: transitive
294 | description:
295 | name: js
296 | url: "https://pub.dartlang.org"
297 | source: hosted
298 | version: "0.6.3"
299 | lints:
300 | dependency: transitive
301 | description:
302 | name: lints
303 | url: "https://pub.dartlang.org"
304 | source: hosted
305 | version: "1.0.1"
306 | matcher:
307 | dependency: transitive
308 | description:
309 | name: matcher
310 | url: "https://pub.dartlang.org"
311 | source: hosted
312 | version: "0.12.11"
313 | meta:
314 | dependency: transitive
315 | description:
316 | name: meta
317 | url: "https://pub.dartlang.org"
318 | source: hosted
319 | version: "1.7.0"
320 | path:
321 | dependency: transitive
322 | description:
323 | name: path
324 | url: "https://pub.dartlang.org"
325 | source: hosted
326 | version: "1.8.0"
327 | plugin_platform_interface:
328 | dependency: transitive
329 | description:
330 | name: plugin_platform_interface
331 | url: "https://pub.dartlang.org"
332 | source: hosted
333 | version: "2.1.1"
334 | quiver:
335 | dependency: transitive
336 | description:
337 | name: quiver
338 | url: "https://pub.dartlang.org"
339 | source: hosted
340 | version: "3.0.1+1"
341 | sky_engine:
342 | dependency: transitive
343 | description: flutter
344 | source: sdk
345 | version: "0.0.99"
346 | source_span:
347 | dependency: transitive
348 | description:
349 | name: source_span
350 | url: "https://pub.dartlang.org"
351 | source: hosted
352 | version: "1.8.1"
353 | stack_trace:
354 | dependency: transitive
355 | description:
356 | name: stack_trace
357 | url: "https://pub.dartlang.org"
358 | source: hosted
359 | version: "1.10.0"
360 | stream_channel:
361 | dependency: transitive
362 | description:
363 | name: stream_channel
364 | url: "https://pub.dartlang.org"
365 | source: hosted
366 | version: "2.1.0"
367 | string_scanner:
368 | dependency: transitive
369 | description:
370 | name: string_scanner
371 | url: "https://pub.dartlang.org"
372 | source: hosted
373 | version: "1.1.0"
374 | term_glyph:
375 | dependency: transitive
376 | description:
377 | name: term_glyph
378 | url: "https://pub.dartlang.org"
379 | source: hosted
380 | version: "1.2.0"
381 | test_api:
382 | dependency: transitive
383 | description:
384 | name: test_api
385 | url: "https://pub.dartlang.org"
386 | source: hosted
387 | version: "0.4.3"
388 | typed_data:
389 | dependency: transitive
390 | description:
391 | name: typed_data
392 | url: "https://pub.dartlang.org"
393 | source: hosted
394 | version: "1.3.0"
395 | vector_math:
396 | dependency: transitive
397 | description:
398 | name: vector_math
399 | url: "https://pub.dartlang.org"
400 | source: hosted
401 | version: "2.1.1"
402 | sdks:
403 | dart: ">=2.15.1 <3.0.0"
404 | flutter: ">=2.5.0"
405 |
--------------------------------------------------------------------------------
/lib/views/register/register_page.dart:
--------------------------------------------------------------------------------
1 | import 'package:firebase_notes/constants/custom_app_bar.dart';
2 | import 'package:firebase_notes/constants/custom_loading.dart';
3 | import 'package:firebase_notes/services/auth_service.dart';
4 | import 'package:firebase_notes/src/colors.dart';
5 | import 'package:firebase_notes/src/images.dart';
6 | import 'package:firebase_notes/src/strings.dart';
7 | import 'package:firebase_notes/views/launch/launch_page.dart';
8 | import 'package:flutter/material.dart';
9 | import 'package:fluttertoast/fluttertoast.dart';
10 |
11 | class RegisterPage extends StatefulWidget {
12 | const RegisterPage({Key? key}) : super(key: key);
13 |
14 | @override
15 | _RegisterPageState createState() => _RegisterPageState();
16 | }
17 |
18 | class _RegisterPageState extends State {
19 | final TextEditingController _usernameController = TextEditingController();
20 | final TextEditingController _emailController = TextEditingController();
21 | final TextEditingController _passwordController = TextEditingController();
22 |
23 | bool _isVisible = true;
24 | bool _ramenValue = false;
25 | bool _pizzaValue = false;
26 | String _dropdownValue = DietText.ketchup;
27 | dynamic _profileImage = '';
28 | bool _isLoading = false;
29 |
30 | final AuthService _authService = AuthService();
31 |
32 | @override
33 | Widget build(BuildContext context) {
34 | return Scaffold(
35 | backgroundColor: DietColors.mainColor,
36 | appBar: CustomAppBar(DietText.registerText),
37 | body: _body(context),
38 | );
39 | }
40 |
41 | Stack _body(BuildContext context) {
42 | return Stack(
43 | children: [
44 | Padding(
45 | padding: const EdgeInsets.fromLTRB(20, 50, 20, 30),
46 | child: Column(
47 | crossAxisAlignment: CrossAxisAlignment.stretch,
48 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
49 | children: [
50 | _bodyContainer(),
51 | const SizedBox(
52 | height: 55,
53 | ),
54 | _registerButton(context),
55 | ],
56 | ),
57 | ),
58 | if (_isLoading) const CustomLoading(),
59 | ],
60 | );
61 | }
62 |
63 | Flexible _bodyContainer() {
64 | return Flexible(
65 | child: Container(
66 | decoration: const BoxDecoration(
67 | color: Colors.white,
68 | borderRadius: BorderRadius.all(
69 | Radius.circular(20),
70 | ),
71 | ),
72 | child: Padding(
73 | padding: const EdgeInsets.all(20),
74 | child: SingleChildScrollView(
75 | child: Column(
76 | crossAxisAlignment: CrossAxisAlignment.start,
77 | children: [
78 | _usernameTextField(),
79 | const SizedBox(
80 | height: 20,
81 | ),
82 | _emailTextField(),
83 | const SizedBox(
84 | height: 20,
85 | ),
86 | _passwordTextField(),
87 | const SizedBox(
88 | height: 20,
89 | ),
90 | _foodText(),
91 | const SizedBox(
92 | height: 10,
93 | ),
94 | _foodsRow(),
95 | const SizedBox(
96 | height: 20,
97 | ),
98 | Text(
99 | DietText.registerQuestionsauce,
100 | style: const TextStyle(fontSize: 15),
101 | ),
102 | const SizedBox(
103 | height: 10,
104 | ),
105 | _dropdownButton(),
106 | ],
107 | ),
108 | ),
109 | ),
110 | ),
111 | );
112 | }
113 |
114 | TextField _usernameTextField() {
115 | return TextField(
116 | controller: _usernameController,
117 | cursorColor: DietColors.black,
118 | decoration: InputDecoration(
119 | prefixIcon: Icon(
120 | Icons.person,
121 | color: DietColors.orange,
122 | ),
123 | hintText: DietText.username,
124 | enabledBorder: OutlineInputBorder(
125 | borderSide: BorderSide(color: DietColors.mainColor),
126 | borderRadius: BorderRadius.circular(10),
127 | ),
128 | focusedBorder: OutlineInputBorder(
129 | borderSide: BorderSide(color: DietColors.orange),
130 | borderRadius: BorderRadius.circular(10),
131 | ),
132 | ),
133 | );
134 | }
135 |
136 | TextField _emailTextField() {
137 | return TextField(
138 | controller: _emailController,
139 | cursorColor: DietColors.black,
140 | keyboardType: TextInputType.emailAddress,
141 | decoration: InputDecoration(
142 | prefixIcon: Icon(
143 | Icons.mail,
144 | color: DietColors.orange,
145 | ),
146 | hintText: DietText.email,
147 | enabledBorder: OutlineInputBorder(
148 | borderSide: BorderSide(color: DietColors.mainColor),
149 | borderRadius: BorderRadius.circular(10),
150 | ),
151 | focusedBorder: OutlineInputBorder(
152 | borderSide: BorderSide(color: DietColors.orange),
153 | borderRadius: BorderRadius.circular(10),
154 | ),
155 | ),
156 | );
157 | }
158 |
159 | TextField _passwordTextField() {
160 | return TextField(
161 | controller: _passwordController,
162 | obscureText: _isVisible ? true : false,
163 | cursorColor: DietColors.black,
164 | decoration: InputDecoration(
165 | suffixIcon: InkWell(
166 | onTap: () {
167 | if (_isVisible) {
168 | setState(() {
169 | _isVisible = false;
170 | });
171 | } else {
172 | setState(() {
173 | _isVisible = false;
174 | });
175 | _isVisible = true;
176 | }
177 | },
178 | child: _isVisible
179 | ? Icon(
180 | Icons.remove_red_eye,
181 | color: DietColors.orange,
182 | )
183 | : Icon(
184 | Icons.remove_red_eye_outlined,
185 | color: DietColors.orange,
186 | ),
187 | ),
188 | prefixIcon: Icon(
189 | Icons.vpn_key,
190 | color: DietColors.orange,
191 | ),
192 | hintText: DietText.password,
193 | enabledBorder: OutlineInputBorder(
194 | borderSide: BorderSide(color: DietColors.mainColor),
195 | borderRadius: BorderRadius.circular(10),
196 | ),
197 | focusedBorder: OutlineInputBorder(
198 | borderSide: BorderSide(color: DietColors.orange),
199 | borderRadius: BorderRadius.circular(10),
200 | ),
201 | ),
202 | );
203 | }
204 |
205 | Text _foodText() {
206 | return Text(
207 | DietText.registerQuestionFood,
208 | style: const TextStyle(fontSize: 15),
209 | );
210 | }
211 |
212 | Row _foodsRow() {
213 | return Row(
214 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
215 | children: [
216 | _foodRowFirst(),
217 | _foodRowLast(),
218 | ],
219 | );
220 | }
221 |
222 | Expanded _foodRowFirst() {
223 | return Expanded(
224 | child: Row(
225 | children: [
226 | _foodFirstCheckBox(),
227 | _foodImage(DietImages.ramen),
228 | ],
229 | ),
230 | );
231 | }
232 |
233 | Transform _foodFirstCheckBox() {
234 | return Transform.scale(
235 | scale: 1.3,
236 | child: Checkbox(
237 | side: BorderSide(color: DietColors.mainColor),
238 | value: _ramenValue,
239 | activeColor: DietColors.orange,
240 | shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(4)),
241 | onChanged: (_) => _setRamenValue(),
242 | ),
243 | );
244 | }
245 |
246 | void _setRamenValue() {
247 | if (_ramenValue != true) {
248 | setState(() {
249 | _ramenValue = true;
250 | _pizzaValue = false;
251 | _profileImage = DietImages.ramen;
252 | });
253 | } else {
254 | setState(() {
255 | _ramenValue = false;
256 | });
257 | }
258 | }
259 |
260 | ClipRRect _foodImage(String image) {
261 | return ClipRRect(
262 | borderRadius: BorderRadius.circular(20),
263 | child: Image.asset(
264 | image,
265 | height: 70,
266 | ),
267 | );
268 | }
269 |
270 | Expanded _foodRowLast() {
271 | return Expanded(
272 | child: Row(
273 | children: [
274 | _foodLastCheckbox(),
275 | _foodImage(DietImages.pizza),
276 | ],
277 | ),
278 | );
279 | }
280 |
281 | Transform _foodLastCheckbox() {
282 | return Transform.scale(
283 | scale: 1.3,
284 | child: Checkbox(
285 | side: BorderSide(color: DietColors.mainColor),
286 | value: _pizzaValue,
287 | activeColor: DietColors.orange,
288 | shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(4)),
289 | onChanged: (_) => _setPizzaValue(),
290 | ),
291 | );
292 | }
293 |
294 | void _setPizzaValue() {
295 | if (_pizzaValue != true) {
296 | setState(() {
297 | _pizzaValue = true;
298 | _ramenValue = false;
299 | _profileImage = DietImages.pizza;
300 | });
301 | } else {
302 | setState(() {
303 | _pizzaValue = false;
304 | });
305 | }
306 | }
307 |
308 | DropdownButton _dropdownButton() {
309 | return DropdownButton(
310 | borderRadius: BorderRadius.circular(20),
311 | isExpanded: true,
312 | iconEnabledColor: DietColors.orange,
313 | value: _dropdownValue,
314 | items: [
315 | DropdownMenuItem(
316 | child: Text(DietText.ketchup),
317 | value: DietText.ketchup,
318 | ),
319 | DropdownMenuItem(
320 | child: Text(DietText.mayonnaise),
321 | value: DietText.mayonnaise,
322 | ),
323 | DropdownMenuItem(
324 | child: Text(DietText.barbecue),
325 | value: DietText.barbecue,
326 | ),
327 | DropdownMenuItem(
328 | child: Text(DietText.ranch),
329 | value: DietText.ranch,
330 | ),
331 | DropdownMenuItem(
332 | child: Text(DietText.honeyMustard),
333 | value: DietText.honeyMustard,
334 | ),
335 | ],
336 | onChanged: (value) {
337 | setState(() {
338 | _dropdownValue = value;
339 | });
340 | });
341 | }
342 |
343 | InkWell _registerButton(BuildContext context) {
344 | return InkWell(
345 | onTap: () => _registerOnTap(),
346 | child: Container(
347 | decoration: BoxDecoration(
348 | color: DietColors.orange,
349 | borderRadius: BorderRadius.circular(10),
350 | ),
351 | height: 40,
352 | child: Center(
353 | child: Text(
354 | DietText.registerText,
355 | style: TextStyle(
356 | color: DietColors.white,
357 | ),
358 | ),
359 | ),
360 | ));
361 | }
362 |
363 | void _registerOnTap() {
364 | if (_usernameController.text.isNotEmpty &&
365 | _emailController.text.isNotEmpty &&
366 | _passwordController.text.isNotEmpty &&
367 | _profileImage.toString().isNotEmpty &&
368 | _dropdownValue.isNotEmpty) {
369 | setState(() {
370 | _isLoading = true;
371 | });
372 | _authService
373 | .createPerson(
374 | _usernameController.text,
375 | _emailController.text,
376 | _passwordController.text,
377 | _profileImage ?? '',
378 | _dropdownValue,
379 | )
380 | .then((value) {
381 | Navigator.pushAndRemoveUntil(
382 | context,
383 | MaterialPageRoute(builder: (context) => const LaunchPage()),
384 | (route) => false);
385 | }).catchError((error) {
386 | _warningToast(DietText.errorText);
387 | }).whenComplete(() {
388 | setState(() {
389 | _isLoading = false;
390 | });
391 | });
392 | } else {
393 | _warningToast(DietText.emptyText);
394 | }
395 | }
396 |
397 | Future _warningToast(String text) {
398 | return Fluttertoast.showToast(
399 | msg: text,
400 | timeInSecForIosWeb: 2,
401 | toastLength: Toast.LENGTH_SHORT,
402 | gravity: ToastGravity.CENTER,
403 | backgroundColor: DietColors.red,
404 | textColor: DietColors.white,
405 | fontSize: 14);
406 | }
407 | }
408 |
--------------------------------------------------------------------------------
/macos/Runner.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 51;
7 | objects = {
8 |
9 | /* Begin PBXAggregateTarget section */
10 | 33CC111A2044C6BA0003C045 /* Flutter Assemble */ = {
11 | isa = PBXAggregateTarget;
12 | buildConfigurationList = 33CC111B2044C6BA0003C045 /* Build configuration list for PBXAggregateTarget "Flutter Assemble" */;
13 | buildPhases = (
14 | 33CC111E2044C6BF0003C045 /* ShellScript */,
15 | );
16 | dependencies = (
17 | );
18 | name = "Flutter Assemble";
19 | productName = FLX;
20 | };
21 | /* End PBXAggregateTarget section */
22 |
23 | /* Begin PBXBuildFile section */
24 | 335BBD1B22A9A15E00E9071D /* GeneratedPluginRegistrant.swift in Sources */ = {isa = PBXBuildFile; fileRef = 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */; };
25 | 33CC10F12044A3C60003C045 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC10F02044A3C60003C045 /* AppDelegate.swift */; };
26 | 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F22044A3C60003C045 /* Assets.xcassets */; };
27 | 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F42044A3C60003C045 /* MainMenu.xib */; };
28 | 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */; };
29 | /* End PBXBuildFile section */
30 |
31 | /* Begin PBXContainerItemProxy section */
32 | 33CC111F2044C79F0003C045 /* PBXContainerItemProxy */ = {
33 | isa = PBXContainerItemProxy;
34 | containerPortal = 33CC10E52044A3C60003C045 /* Project object */;
35 | proxyType = 1;
36 | remoteGlobalIDString = 33CC111A2044C6BA0003C045;
37 | remoteInfo = FLX;
38 | };
39 | /* End PBXContainerItemProxy section */
40 |
41 | /* Begin PBXCopyFilesBuildPhase section */
42 | 33CC110E2044A8840003C045 /* Bundle Framework */ = {
43 | isa = PBXCopyFilesBuildPhase;
44 | buildActionMask = 2147483647;
45 | dstPath = "";
46 | dstSubfolderSpec = 10;
47 | files = (
48 | );
49 | name = "Bundle Framework";
50 | runOnlyForDeploymentPostprocessing = 0;
51 | };
52 | /* End PBXCopyFilesBuildPhase section */
53 |
54 | /* Begin PBXFileReference section */
55 | 333000ED22D3DE5D00554162 /* Warnings.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Warnings.xcconfig; sourceTree = ""; };
56 | 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GeneratedPluginRegistrant.swift; sourceTree = ""; };
57 | 33CC10ED2044A3C60003C045 /* firebase_notes.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "firebase_notes.app"; sourceTree = BUILT_PRODUCTS_DIR; };
58 | 33CC10F02044A3C60003C045 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
59 | 33CC10F22044A3C60003C045 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Assets.xcassets; path = Runner/Assets.xcassets; sourceTree = ""; };
60 | 33CC10F52044A3C60003C045 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/MainMenu.xib; sourceTree = ""; };
61 | 33CC10F72044A3C60003C045 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = Info.plist; path = Runner/Info.plist; sourceTree = ""; };
62 | 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MainFlutterWindow.swift; sourceTree = ""; };
63 | 33CEB47222A05771004F2AC0 /* Flutter-Debug.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = "Flutter-Debug.xcconfig"; sourceTree = ""; };
64 | 33CEB47422A05771004F2AC0 /* Flutter-Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = "Flutter-Release.xcconfig"; sourceTree = ""; };
65 | 33CEB47722A0578A004F2AC0 /* Flutter-Generated.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = "Flutter-Generated.xcconfig"; path = "ephemeral/Flutter-Generated.xcconfig"; sourceTree = ""; };
66 | 33E51913231747F40026EE4D /* DebugProfile.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = DebugProfile.entitlements; sourceTree = ""; };
67 | 33E51914231749380026EE4D /* Release.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.entitlements; path = Release.entitlements; sourceTree = ""; };
68 | 33E5194F232828860026EE4D /* AppInfo.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = AppInfo.xcconfig; sourceTree = ""; };
69 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = ""; };
70 | 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Debug.xcconfig; sourceTree = ""; };
71 | /* End PBXFileReference section */
72 |
73 | /* Begin PBXFrameworksBuildPhase section */
74 | 33CC10EA2044A3C60003C045 /* Frameworks */ = {
75 | isa = PBXFrameworksBuildPhase;
76 | buildActionMask = 2147483647;
77 | files = (
78 | );
79 | runOnlyForDeploymentPostprocessing = 0;
80 | };
81 | /* End PBXFrameworksBuildPhase section */
82 |
83 | /* Begin PBXGroup section */
84 | 33BA886A226E78AF003329D5 /* Configs */ = {
85 | isa = PBXGroup;
86 | children = (
87 | 33E5194F232828860026EE4D /* AppInfo.xcconfig */,
88 | 9740EEB21CF90195004384FC /* Debug.xcconfig */,
89 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
90 | 333000ED22D3DE5D00554162 /* Warnings.xcconfig */,
91 | );
92 | path = Configs;
93 | sourceTree = "";
94 | };
95 | 33CC10E42044A3C60003C045 = {
96 | isa = PBXGroup;
97 | children = (
98 | 33FAB671232836740065AC1E /* Runner */,
99 | 33CEB47122A05771004F2AC0 /* Flutter */,
100 | 33CC10EE2044A3C60003C045 /* Products */,
101 | D73912EC22F37F3D000D13A0 /* Frameworks */,
102 | );
103 | sourceTree = "";
104 | };
105 | 33CC10EE2044A3C60003C045 /* Products */ = {
106 | isa = PBXGroup;
107 | children = (
108 | 33CC10ED2044A3C60003C045 /* firebase_notes.app */,
109 | );
110 | name = Products;
111 | sourceTree = "";
112 | };
113 | 33CC11242044D66E0003C045 /* Resources */ = {
114 | isa = PBXGroup;
115 | children = (
116 | 33CC10F22044A3C60003C045 /* Assets.xcassets */,
117 | 33CC10F42044A3C60003C045 /* MainMenu.xib */,
118 | 33CC10F72044A3C60003C045 /* Info.plist */,
119 | );
120 | name = Resources;
121 | path = ..;
122 | sourceTree = "";
123 | };
124 | 33CEB47122A05771004F2AC0 /* Flutter */ = {
125 | isa = PBXGroup;
126 | children = (
127 | 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */,
128 | 33CEB47222A05771004F2AC0 /* Flutter-Debug.xcconfig */,
129 | 33CEB47422A05771004F2AC0 /* Flutter-Release.xcconfig */,
130 | 33CEB47722A0578A004F2AC0 /* Flutter-Generated.xcconfig */,
131 | );
132 | path = Flutter;
133 | sourceTree = "";
134 | };
135 | 33FAB671232836740065AC1E /* Runner */ = {
136 | isa = PBXGroup;
137 | children = (
138 | 33CC10F02044A3C60003C045 /* AppDelegate.swift */,
139 | 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */,
140 | 33E51913231747F40026EE4D /* DebugProfile.entitlements */,
141 | 33E51914231749380026EE4D /* Release.entitlements */,
142 | 33CC11242044D66E0003C045 /* Resources */,
143 | 33BA886A226E78AF003329D5 /* Configs */,
144 | );
145 | path = Runner;
146 | sourceTree = "";
147 | };
148 | D73912EC22F37F3D000D13A0 /* Frameworks */ = {
149 | isa = PBXGroup;
150 | children = (
151 | );
152 | name = Frameworks;
153 | sourceTree = "";
154 | };
155 | /* End PBXGroup section */
156 |
157 | /* Begin PBXNativeTarget section */
158 | 33CC10EC2044A3C60003C045 /* Runner */ = {
159 | isa = PBXNativeTarget;
160 | buildConfigurationList = 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */;
161 | buildPhases = (
162 | 33CC10E92044A3C60003C045 /* Sources */,
163 | 33CC10EA2044A3C60003C045 /* Frameworks */,
164 | 33CC10EB2044A3C60003C045 /* Resources */,
165 | 33CC110E2044A8840003C045 /* Bundle Framework */,
166 | 3399D490228B24CF009A79C7 /* ShellScript */,
167 | );
168 | buildRules = (
169 | );
170 | dependencies = (
171 | 33CC11202044C79F0003C045 /* PBXTargetDependency */,
172 | );
173 | name = Runner;
174 | productName = Runner;
175 | productReference = 33CC10ED2044A3C60003C045 /* firebase_notes.app */;
176 | productType = "com.apple.product-type.application";
177 | };
178 | /* End PBXNativeTarget section */
179 |
180 | /* Begin PBXProject section */
181 | 33CC10E52044A3C60003C045 /* Project object */ = {
182 | isa = PBXProject;
183 | attributes = {
184 | LastSwiftUpdateCheck = 0920;
185 | LastUpgradeCheck = 1300;
186 | ORGANIZATIONNAME = "";
187 | TargetAttributes = {
188 | 33CC10EC2044A3C60003C045 = {
189 | CreatedOnToolsVersion = 9.2;
190 | LastSwiftMigration = 1100;
191 | ProvisioningStyle = Automatic;
192 | SystemCapabilities = {
193 | com.apple.Sandbox = {
194 | enabled = 1;
195 | };
196 | };
197 | };
198 | 33CC111A2044C6BA0003C045 = {
199 | CreatedOnToolsVersion = 9.2;
200 | ProvisioningStyle = Manual;
201 | };
202 | };
203 | };
204 | buildConfigurationList = 33CC10E82044A3C60003C045 /* Build configuration list for PBXProject "Runner" */;
205 | compatibilityVersion = "Xcode 9.3";
206 | developmentRegion = en;
207 | hasScannedForEncodings = 0;
208 | knownRegions = (
209 | en,
210 | Base,
211 | );
212 | mainGroup = 33CC10E42044A3C60003C045;
213 | productRefGroup = 33CC10EE2044A3C60003C045 /* Products */;
214 | projectDirPath = "";
215 | projectRoot = "";
216 | targets = (
217 | 33CC10EC2044A3C60003C045 /* Runner */,
218 | 33CC111A2044C6BA0003C045 /* Flutter Assemble */,
219 | );
220 | };
221 | /* End PBXProject section */
222 |
223 | /* Begin PBXResourcesBuildPhase section */
224 | 33CC10EB2044A3C60003C045 /* Resources */ = {
225 | isa = PBXResourcesBuildPhase;
226 | buildActionMask = 2147483647;
227 | files = (
228 | 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */,
229 | 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */,
230 | );
231 | runOnlyForDeploymentPostprocessing = 0;
232 | };
233 | /* End PBXResourcesBuildPhase section */
234 |
235 | /* Begin PBXShellScriptBuildPhase section */
236 | 3399D490228B24CF009A79C7 /* ShellScript */ = {
237 | isa = PBXShellScriptBuildPhase;
238 | buildActionMask = 2147483647;
239 | files = (
240 | );
241 | inputFileListPaths = (
242 | );
243 | inputPaths = (
244 | );
245 | outputFileListPaths = (
246 | );
247 | outputPaths = (
248 | );
249 | runOnlyForDeploymentPostprocessing = 0;
250 | shellPath = /bin/sh;
251 | shellScript = "echo \"$PRODUCT_NAME.app\" > \"$PROJECT_DIR\"/Flutter/ephemeral/.app_filename && \"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh embed\n";
252 | };
253 | 33CC111E2044C6BF0003C045 /* ShellScript */ = {
254 | isa = PBXShellScriptBuildPhase;
255 | buildActionMask = 2147483647;
256 | files = (
257 | );
258 | inputFileListPaths = (
259 | Flutter/ephemeral/FlutterInputs.xcfilelist,
260 | );
261 | inputPaths = (
262 | Flutter/ephemeral/tripwire,
263 | );
264 | outputFileListPaths = (
265 | Flutter/ephemeral/FlutterOutputs.xcfilelist,
266 | );
267 | outputPaths = (
268 | );
269 | runOnlyForDeploymentPostprocessing = 0;
270 | shellPath = /bin/sh;
271 | shellScript = "\"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh && touch Flutter/ephemeral/tripwire";
272 | };
273 | /* End PBXShellScriptBuildPhase section */
274 |
275 | /* Begin PBXSourcesBuildPhase section */
276 | 33CC10E92044A3C60003C045 /* Sources */ = {
277 | isa = PBXSourcesBuildPhase;
278 | buildActionMask = 2147483647;
279 | files = (
280 | 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */,
281 | 33CC10F12044A3C60003C045 /* AppDelegate.swift in Sources */,
282 | 335BBD1B22A9A15E00E9071D /* GeneratedPluginRegistrant.swift in Sources */,
283 | );
284 | runOnlyForDeploymentPostprocessing = 0;
285 | };
286 | /* End PBXSourcesBuildPhase section */
287 |
288 | /* Begin PBXTargetDependency section */
289 | 33CC11202044C79F0003C045 /* PBXTargetDependency */ = {
290 | isa = PBXTargetDependency;
291 | target = 33CC111A2044C6BA0003C045 /* Flutter Assemble */;
292 | targetProxy = 33CC111F2044C79F0003C045 /* PBXContainerItemProxy */;
293 | };
294 | /* End PBXTargetDependency section */
295 |
296 | /* Begin PBXVariantGroup section */
297 | 33CC10F42044A3C60003C045 /* MainMenu.xib */ = {
298 | isa = PBXVariantGroup;
299 | children = (
300 | 33CC10F52044A3C60003C045 /* Base */,
301 | );
302 | name = MainMenu.xib;
303 | path = Runner;
304 | sourceTree = "";
305 | };
306 | /* End PBXVariantGroup section */
307 |
308 | /* Begin XCBuildConfiguration section */
309 | 338D0CE9231458BD00FA5F75 /* Profile */ = {
310 | isa = XCBuildConfiguration;
311 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
312 | buildSettings = {
313 | ALWAYS_SEARCH_USER_PATHS = NO;
314 | CLANG_ANALYZER_NONNULL = YES;
315 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
316 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
317 | CLANG_CXX_LIBRARY = "libc++";
318 | CLANG_ENABLE_MODULES = YES;
319 | CLANG_ENABLE_OBJC_ARC = YES;
320 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
321 | CLANG_WARN_BOOL_CONVERSION = YES;
322 | CLANG_WARN_CONSTANT_CONVERSION = YES;
323 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
324 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
325 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
326 | CLANG_WARN_EMPTY_BODY = YES;
327 | CLANG_WARN_ENUM_CONVERSION = YES;
328 | CLANG_WARN_INFINITE_RECURSION = YES;
329 | CLANG_WARN_INT_CONVERSION = YES;
330 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
331 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
332 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
333 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
334 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
335 | CODE_SIGN_IDENTITY = "-";
336 | COPY_PHASE_STRIP = NO;
337 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
338 | ENABLE_NS_ASSERTIONS = NO;
339 | ENABLE_STRICT_OBJC_MSGSEND = YES;
340 | GCC_C_LANGUAGE_STANDARD = gnu11;
341 | GCC_NO_COMMON_BLOCKS = YES;
342 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
343 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
344 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
345 | GCC_WARN_UNUSED_FUNCTION = YES;
346 | GCC_WARN_UNUSED_VARIABLE = YES;
347 | MACOSX_DEPLOYMENT_TARGET = 10.11;
348 | MTL_ENABLE_DEBUG_INFO = NO;
349 | SDKROOT = macosx;
350 | SWIFT_COMPILATION_MODE = wholemodule;
351 | SWIFT_OPTIMIZATION_LEVEL = "-O";
352 | };
353 | name = Profile;
354 | };
355 | 338D0CEA231458BD00FA5F75 /* Profile */ = {
356 | isa = XCBuildConfiguration;
357 | baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */;
358 | buildSettings = {
359 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
360 | CLANG_ENABLE_MODULES = YES;
361 | CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements;
362 | CODE_SIGN_STYLE = Automatic;
363 | COMBINE_HIDPI_IMAGES = YES;
364 | INFOPLIST_FILE = Runner/Info.plist;
365 | LD_RUNPATH_SEARCH_PATHS = (
366 | "$(inherited)",
367 | "@executable_path/../Frameworks",
368 | );
369 | PROVISIONING_PROFILE_SPECIFIER = "";
370 | SWIFT_VERSION = 5.0;
371 | };
372 | name = Profile;
373 | };
374 | 338D0CEB231458BD00FA5F75 /* Profile */ = {
375 | isa = XCBuildConfiguration;
376 | buildSettings = {
377 | CODE_SIGN_STYLE = Manual;
378 | PRODUCT_NAME = "$(TARGET_NAME)";
379 | };
380 | name = Profile;
381 | };
382 | 33CC10F92044A3C60003C045 /* Debug */ = {
383 | isa = XCBuildConfiguration;
384 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
385 | buildSettings = {
386 | ALWAYS_SEARCH_USER_PATHS = NO;
387 | CLANG_ANALYZER_NONNULL = YES;
388 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
389 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
390 | CLANG_CXX_LIBRARY = "libc++";
391 | CLANG_ENABLE_MODULES = YES;
392 | CLANG_ENABLE_OBJC_ARC = YES;
393 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
394 | CLANG_WARN_BOOL_CONVERSION = YES;
395 | CLANG_WARN_CONSTANT_CONVERSION = YES;
396 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
397 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
398 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
399 | CLANG_WARN_EMPTY_BODY = YES;
400 | CLANG_WARN_ENUM_CONVERSION = YES;
401 | CLANG_WARN_INFINITE_RECURSION = YES;
402 | CLANG_WARN_INT_CONVERSION = YES;
403 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
404 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
405 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
406 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
407 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
408 | CODE_SIGN_IDENTITY = "-";
409 | COPY_PHASE_STRIP = NO;
410 | DEBUG_INFORMATION_FORMAT = dwarf;
411 | ENABLE_STRICT_OBJC_MSGSEND = YES;
412 | ENABLE_TESTABILITY = YES;
413 | GCC_C_LANGUAGE_STANDARD = gnu11;
414 | GCC_DYNAMIC_NO_PIC = NO;
415 | GCC_NO_COMMON_BLOCKS = YES;
416 | GCC_OPTIMIZATION_LEVEL = 0;
417 | GCC_PREPROCESSOR_DEFINITIONS = (
418 | "DEBUG=1",
419 | "$(inherited)",
420 | );
421 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
422 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
423 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
424 | GCC_WARN_UNUSED_FUNCTION = YES;
425 | GCC_WARN_UNUSED_VARIABLE = YES;
426 | MACOSX_DEPLOYMENT_TARGET = 10.11;
427 | MTL_ENABLE_DEBUG_INFO = YES;
428 | ONLY_ACTIVE_ARCH = YES;
429 | SDKROOT = macosx;
430 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
431 | SWIFT_OPTIMIZATION_LEVEL = "-Onone";
432 | };
433 | name = Debug;
434 | };
435 | 33CC10FA2044A3C60003C045 /* Release */ = {
436 | isa = XCBuildConfiguration;
437 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
438 | buildSettings = {
439 | ALWAYS_SEARCH_USER_PATHS = NO;
440 | CLANG_ANALYZER_NONNULL = YES;
441 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
442 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
443 | CLANG_CXX_LIBRARY = "libc++";
444 | CLANG_ENABLE_MODULES = YES;
445 | CLANG_ENABLE_OBJC_ARC = YES;
446 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
447 | CLANG_WARN_BOOL_CONVERSION = YES;
448 | CLANG_WARN_CONSTANT_CONVERSION = YES;
449 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
450 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
451 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
452 | CLANG_WARN_EMPTY_BODY = YES;
453 | CLANG_WARN_ENUM_CONVERSION = YES;
454 | CLANG_WARN_INFINITE_RECURSION = YES;
455 | CLANG_WARN_INT_CONVERSION = YES;
456 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
457 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
458 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
459 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
460 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
461 | CODE_SIGN_IDENTITY = "-";
462 | COPY_PHASE_STRIP = NO;
463 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
464 | ENABLE_NS_ASSERTIONS = NO;
465 | ENABLE_STRICT_OBJC_MSGSEND = YES;
466 | GCC_C_LANGUAGE_STANDARD = gnu11;
467 | GCC_NO_COMMON_BLOCKS = YES;
468 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
469 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
470 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
471 | GCC_WARN_UNUSED_FUNCTION = YES;
472 | GCC_WARN_UNUSED_VARIABLE = YES;
473 | MACOSX_DEPLOYMENT_TARGET = 10.11;
474 | MTL_ENABLE_DEBUG_INFO = NO;
475 | SDKROOT = macosx;
476 | SWIFT_COMPILATION_MODE = wholemodule;
477 | SWIFT_OPTIMIZATION_LEVEL = "-O";
478 | };
479 | name = Release;
480 | };
481 | 33CC10FC2044A3C60003C045 /* Debug */ = {
482 | isa = XCBuildConfiguration;
483 | baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */;
484 | buildSettings = {
485 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
486 | CLANG_ENABLE_MODULES = YES;
487 | CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements;
488 | CODE_SIGN_STYLE = Automatic;
489 | COMBINE_HIDPI_IMAGES = YES;
490 | INFOPLIST_FILE = Runner/Info.plist;
491 | LD_RUNPATH_SEARCH_PATHS = (
492 | "$(inherited)",
493 | "@executable_path/../Frameworks",
494 | );
495 | PROVISIONING_PROFILE_SPECIFIER = "";
496 | SWIFT_OPTIMIZATION_LEVEL = "-Onone";
497 | SWIFT_VERSION = 5.0;
498 | };
499 | name = Debug;
500 | };
501 | 33CC10FD2044A3C60003C045 /* Release */ = {
502 | isa = XCBuildConfiguration;
503 | baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */;
504 | buildSettings = {
505 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
506 | CLANG_ENABLE_MODULES = YES;
507 | CODE_SIGN_ENTITLEMENTS = Runner/Release.entitlements;
508 | CODE_SIGN_STYLE = Automatic;
509 | COMBINE_HIDPI_IMAGES = YES;
510 | INFOPLIST_FILE = Runner/Info.plist;
511 | LD_RUNPATH_SEARCH_PATHS = (
512 | "$(inherited)",
513 | "@executable_path/../Frameworks",
514 | );
515 | PROVISIONING_PROFILE_SPECIFIER = "";
516 | SWIFT_VERSION = 5.0;
517 | };
518 | name = Release;
519 | };
520 | 33CC111C2044C6BA0003C045 /* Debug */ = {
521 | isa = XCBuildConfiguration;
522 | buildSettings = {
523 | CODE_SIGN_STYLE = Manual;
524 | PRODUCT_NAME = "$(TARGET_NAME)";
525 | };
526 | name = Debug;
527 | };
528 | 33CC111D2044C6BA0003C045 /* Release */ = {
529 | isa = XCBuildConfiguration;
530 | buildSettings = {
531 | CODE_SIGN_STYLE = Automatic;
532 | PRODUCT_NAME = "$(TARGET_NAME)";
533 | };
534 | name = Release;
535 | };
536 | /* End XCBuildConfiguration section */
537 |
538 | /* Begin XCConfigurationList section */
539 | 33CC10E82044A3C60003C045 /* Build configuration list for PBXProject "Runner" */ = {
540 | isa = XCConfigurationList;
541 | buildConfigurations = (
542 | 33CC10F92044A3C60003C045 /* Debug */,
543 | 33CC10FA2044A3C60003C045 /* Release */,
544 | 338D0CE9231458BD00FA5F75 /* Profile */,
545 | );
546 | defaultConfigurationIsVisible = 0;
547 | defaultConfigurationName = Release;
548 | };
549 | 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */ = {
550 | isa = XCConfigurationList;
551 | buildConfigurations = (
552 | 33CC10FC2044A3C60003C045 /* Debug */,
553 | 33CC10FD2044A3C60003C045 /* Release */,
554 | 338D0CEA231458BD00FA5F75 /* Profile */,
555 | );
556 | defaultConfigurationIsVisible = 0;
557 | defaultConfigurationName = Release;
558 | };
559 | 33CC111B2044C6BA0003C045 /* Build configuration list for PBXAggregateTarget "Flutter Assemble" */ = {
560 | isa = XCConfigurationList;
561 | buildConfigurations = (
562 | 33CC111C2044C6BA0003C045 /* Debug */,
563 | 33CC111D2044C6BA0003C045 /* Release */,
564 | 338D0CEB231458BD00FA5F75 /* Profile */,
565 | );
566 | defaultConfigurationIsVisible = 0;
567 | defaultConfigurationName = Release;
568 | };
569 | /* End XCConfigurationList section */
570 | };
571 | rootObject = 33CC10E52044A3C60003C045 /* Project object */;
572 | }
573 |
--------------------------------------------------------------------------------