├── .appveyor.yml ├── .gitattributes ├── .gitignore ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── ci ├── download_artifact.py ├── install_flutter.sh └── patch_pubspec.py ├── docs └── python-ios.md └── src ├── serious_python ├── CHANGELOG.md ├── LICENSE ├── README.md ├── analysis_options.yaml ├── bin │ ├── macos_utils.dart │ ├── main.dart │ ├── package_command.dart │ └── sitecustomize.dart ├── example │ ├── .gitignore │ ├── README.md │ ├── flask_example │ │ ├── .gitignore │ │ ├── .metadata │ │ ├── README.md │ │ ├── analysis_options.yaml │ │ ├── android │ │ │ ├── .gitignore │ │ │ ├── app │ │ │ │ ├── build.gradle │ │ │ │ └── src │ │ │ │ │ ├── debug │ │ │ │ │ └── AndroidManifest.xml │ │ │ │ │ ├── main │ │ │ │ │ ├── AndroidManifest.xml │ │ │ │ │ ├── kotlin │ │ │ │ │ │ └── com │ │ │ │ │ │ │ └── example │ │ │ │ │ │ │ └── flask_example │ │ │ │ │ │ │ └── MainActivity.kt │ │ │ │ │ └── res │ │ │ │ │ │ ├── drawable-v21 │ │ │ │ │ │ └── launch_background.xml │ │ │ │ │ │ ├── drawable │ │ │ │ │ │ └── launch_background.xml │ │ │ │ │ │ ├── mipmap-hdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── mipmap-mdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── mipmap-xhdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── values-night │ │ │ │ │ │ └── styles.xml │ │ │ │ │ │ └── values │ │ │ │ │ │ └── styles.xml │ │ │ │ │ └── profile │ │ │ │ │ └── AndroidManifest.xml │ │ │ ├── build.gradle │ │ │ ├── gradle.properties │ │ │ ├── gradle │ │ │ │ └── wrapper │ │ │ │ │ └── gradle-wrapper.properties │ │ │ └── settings.gradle │ │ ├── app │ │ │ ├── app.zip.hash │ │ │ └── src │ │ │ │ ├── main.py │ │ │ │ └── requirements.txt │ │ ├── ios │ │ │ ├── .gitignore │ │ │ ├── Flutter │ │ │ │ ├── AppFrameworkInfo.plist │ │ │ │ ├── Debug.xcconfig │ │ │ │ └── Release.xcconfig │ │ │ ├── Podfile │ │ │ ├── Podfile.lock │ │ │ ├── Runner.xcodeproj │ │ │ │ ├── project.pbxproj │ │ │ │ ├── project.xcworkspace │ │ │ │ │ ├── contents.xcworkspacedata │ │ │ │ │ └── xcshareddata │ │ │ │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ │ │ │ └── WorkspaceSettings.xcsettings │ │ │ │ └── xcshareddata │ │ │ │ │ └── xcschemes │ │ │ │ │ └── Runner.xcscheme │ │ │ ├── Runner.xcworkspace │ │ │ │ ├── contents.xcworkspacedata │ │ │ │ └── xcshareddata │ │ │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ │ │ └── WorkspaceSettings.xcsettings │ │ │ ├── Runner │ │ │ │ ├── AppDelegate.swift │ │ │ │ ├── Assets.xcassets │ │ │ │ │ ├── AppIcon.appiconset │ │ │ │ │ │ ├── Contents.json │ │ │ │ │ │ ├── Icon-App-1024x1024@1x.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 │ │ │ │ │ └── LaunchImage.imageset │ │ │ │ │ │ ├── Contents.json │ │ │ │ │ │ ├── LaunchImage.png │ │ │ │ │ │ ├── LaunchImage@2x.png │ │ │ │ │ │ ├── LaunchImage@3x.png │ │ │ │ │ │ └── README.md │ │ │ │ ├── Base.lproj │ │ │ │ │ ├── LaunchScreen.storyboard │ │ │ │ │ └── Main.storyboard │ │ │ │ ├── Info.plist │ │ │ │ └── Runner-Bridging-Header.h │ │ │ └── RunnerTests │ │ │ │ └── RunnerTests.swift │ │ ├── lib │ │ │ └── main.dart │ │ ├── linux │ │ │ ├── .gitignore │ │ │ ├── CMakeLists.txt │ │ │ ├── flutter │ │ │ │ ├── CMakeLists.txt │ │ │ │ ├── generated_plugin_registrant.cc │ │ │ │ ├── generated_plugin_registrant.h │ │ │ │ └── generated_plugins.cmake │ │ │ ├── main.cc │ │ │ ├── my_application.cc │ │ │ └── my_application.h │ │ ├── macos │ │ │ ├── .gitignore │ │ │ ├── Flutter │ │ │ │ ├── Flutter-Debug.xcconfig │ │ │ │ ├── Flutter-Release.xcconfig │ │ │ │ └── GeneratedPluginRegistrant.swift │ │ │ ├── Podfile │ │ │ ├── Podfile.lock │ │ │ ├── Runner.xcodeproj │ │ │ │ ├── project.pbxproj │ │ │ │ ├── project.xcworkspace │ │ │ │ │ └── xcshareddata │ │ │ │ │ │ └── IDEWorkspaceChecks.plist │ │ │ │ └── xcshareddata │ │ │ │ │ └── xcschemes │ │ │ │ │ └── Runner.xcscheme │ │ │ ├── Runner.xcworkspace │ │ │ │ ├── contents.xcworkspacedata │ │ │ │ └── xcshareddata │ │ │ │ │ └── IDEWorkspaceChecks.plist │ │ │ ├── Runner │ │ │ │ ├── AppDelegate.swift │ │ │ │ ├── Assets.xcassets │ │ │ │ │ └── AppIcon.appiconset │ │ │ │ │ │ ├── Contents.json │ │ │ │ │ │ ├── app_icon_1024.png │ │ │ │ │ │ ├── app_icon_128.png │ │ │ │ │ │ ├── app_icon_16.png │ │ │ │ │ │ ├── app_icon_256.png │ │ │ │ │ │ ├── app_icon_32.png │ │ │ │ │ │ ├── app_icon_512.png │ │ │ │ │ │ └── app_icon_64.png │ │ │ │ ├── Base.lproj │ │ │ │ │ └── MainMenu.xib │ │ │ │ ├── Configs │ │ │ │ │ ├── AppInfo.xcconfig │ │ │ │ │ ├── Debug.xcconfig │ │ │ │ │ ├── Release.xcconfig │ │ │ │ │ └── Warnings.xcconfig │ │ │ │ ├── DebugProfile.entitlements │ │ │ │ ├── Info.plist │ │ │ │ ├── MainFlutterWindow.swift │ │ │ │ └── Release.entitlements │ │ │ └── RunnerTests │ │ │ │ └── RunnerTests.swift │ │ ├── pubspec.lock │ │ ├── pubspec.yaml │ │ ├── test │ │ │ └── widget_test.dart │ │ └── windows │ │ │ ├── .gitignore │ │ │ ├── CMakeLists.txt │ │ │ ├── flutter │ │ │ ├── CMakeLists.txt │ │ │ ├── generated_plugin_registrant.cc │ │ │ ├── generated_plugin_registrant.h │ │ │ └── generated_plugins.cmake │ │ │ └── runner │ │ │ ├── CMakeLists.txt │ │ │ ├── Runner.rc │ │ │ ├── flutter_window.cpp │ │ │ ├── flutter_window.h │ │ │ ├── main.cpp │ │ │ ├── resource.h │ │ │ ├── resources │ │ │ └── app_icon.ico │ │ │ ├── runner.exe.manifest │ │ │ ├── utils.cpp │ │ │ ├── utils.h │ │ │ ├── win32_window.cpp │ │ │ └── win32_window.h │ ├── flet_example │ │ ├── .gitignore │ │ ├── .metadata │ │ ├── README.md │ │ ├── analysis_options.yaml │ │ ├── android │ │ │ ├── .gitignore │ │ │ ├── app │ │ │ │ ├── build.gradle │ │ │ │ └── src │ │ │ │ │ ├── debug │ │ │ │ │ └── AndroidManifest.xml │ │ │ │ │ ├── main │ │ │ │ │ ├── AndroidManifest.xml │ │ │ │ │ ├── kotlin │ │ │ │ │ │ └── com │ │ │ │ │ │ │ └── example │ │ │ │ │ │ │ └── flet_example │ │ │ │ │ │ │ └── MainActivity.kt │ │ │ │ │ └── res │ │ │ │ │ │ ├── drawable-v21 │ │ │ │ │ │ └── launch_background.xml │ │ │ │ │ │ ├── drawable │ │ │ │ │ │ └── launch_background.xml │ │ │ │ │ │ ├── mipmap-hdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── mipmap-mdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── mipmap-xhdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ │ ├── values-night │ │ │ │ │ │ └── styles.xml │ │ │ │ │ │ └── values │ │ │ │ │ │ └── styles.xml │ │ │ │ │ └── profile │ │ │ │ │ └── AndroidManifest.xml │ │ │ ├── build.gradle │ │ │ ├── gradle.properties │ │ │ ├── gradle │ │ │ │ └── wrapper │ │ │ │ │ └── gradle-wrapper.properties │ │ │ └── settings.gradle │ │ ├── app │ │ │ ├── app.zip.hash │ │ │ └── src │ │ │ │ ├── main.py │ │ │ │ ├── main_async.py │ │ │ │ └── requirements.txt │ │ ├── integration_test │ │ │ └── app_test.dart │ │ ├── ios │ │ │ ├── .gitignore │ │ │ ├── Flutter │ │ │ │ ├── AppFrameworkInfo.plist │ │ │ │ ├── Debug.xcconfig │ │ │ │ └── Release.xcconfig │ │ │ ├── Podfile │ │ │ ├── Podfile.lock │ │ │ ├── Runner.xcodeproj │ │ │ │ ├── project.pbxproj │ │ │ │ ├── project.xcworkspace │ │ │ │ │ ├── contents.xcworkspacedata │ │ │ │ │ └── xcshareddata │ │ │ │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ │ │ │ └── WorkspaceSettings.xcsettings │ │ │ │ └── xcshareddata │ │ │ │ │ └── xcschemes │ │ │ │ │ └── Runner.xcscheme │ │ │ ├── Runner.xcworkspace │ │ │ │ ├── contents.xcworkspacedata │ │ │ │ └── xcshareddata │ │ │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ │ │ └── WorkspaceSettings.xcsettings │ │ │ ├── Runner │ │ │ │ ├── AppDelegate.swift │ │ │ │ ├── Assets.xcassets │ │ │ │ │ ├── AppIcon.appiconset │ │ │ │ │ │ ├── Contents.json │ │ │ │ │ │ ├── Icon-App-1024x1024@1x.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 │ │ │ │ │ └── LaunchImage.imageset │ │ │ │ │ │ ├── Contents.json │ │ │ │ │ │ ├── LaunchImage.png │ │ │ │ │ │ ├── LaunchImage@2x.png │ │ │ │ │ │ ├── LaunchImage@3x.png │ │ │ │ │ │ └── README.md │ │ │ │ ├── Base.lproj │ │ │ │ │ ├── LaunchScreen.storyboard │ │ │ │ │ └── Main.storyboard │ │ │ │ ├── Info.plist │ │ │ │ └── Runner-Bridging-Header.h │ │ │ └── RunnerTests │ │ │ │ └── RunnerTests.swift │ │ ├── lib │ │ │ └── main.dart │ │ ├── linux │ │ │ ├── .gitignore │ │ │ ├── CMakeLists.txt │ │ │ ├── flutter │ │ │ │ ├── CMakeLists.txt │ │ │ │ ├── generated_plugin_registrant.cc │ │ │ │ ├── generated_plugin_registrant.h │ │ │ │ └── generated_plugins.cmake │ │ │ ├── main.cc │ │ │ ├── my_application.cc │ │ │ └── my_application.h │ │ ├── macos │ │ │ ├── .gitignore │ │ │ ├── Flutter │ │ │ │ ├── Flutter-Debug.xcconfig │ │ │ │ ├── Flutter-Release.xcconfig │ │ │ │ └── GeneratedPluginRegistrant.swift │ │ │ ├── Podfile │ │ │ ├── Podfile.lock │ │ │ ├── Runner.xcodeproj │ │ │ │ ├── project.pbxproj │ │ │ │ ├── project.xcworkspace │ │ │ │ │ └── xcshareddata │ │ │ │ │ │ └── IDEWorkspaceChecks.plist │ │ │ │ └── xcshareddata │ │ │ │ │ └── xcschemes │ │ │ │ │ └── Runner.xcscheme │ │ │ ├── Runner.xcworkspace │ │ │ │ ├── contents.xcworkspacedata │ │ │ │ └── xcshareddata │ │ │ │ │ └── IDEWorkspaceChecks.plist │ │ │ ├── Runner │ │ │ │ ├── AppDelegate.swift │ │ │ │ ├── Assets.xcassets │ │ │ │ │ └── AppIcon.appiconset │ │ │ │ │ │ ├── Contents.json │ │ │ │ │ │ ├── app_icon_1024.png │ │ │ │ │ │ ├── app_icon_128.png │ │ │ │ │ │ ├── app_icon_16.png │ │ │ │ │ │ ├── app_icon_256.png │ │ │ │ │ │ ├── app_icon_32.png │ │ │ │ │ │ ├── app_icon_512.png │ │ │ │ │ │ └── app_icon_64.png │ │ │ │ ├── Base.lproj │ │ │ │ │ └── MainMenu.xib │ │ │ │ ├── Configs │ │ │ │ │ ├── AppInfo.xcconfig │ │ │ │ │ ├── Debug.xcconfig │ │ │ │ │ ├── Release.xcconfig │ │ │ │ │ └── Warnings.xcconfig │ │ │ │ ├── DebugProfile.entitlements │ │ │ │ ├── Info.plist │ │ │ │ ├── MainFlutterWindow.swift │ │ │ │ └── Release.entitlements │ │ │ └── RunnerTests │ │ │ │ └── RunnerTests.swift │ │ ├── pubspec.lock │ │ ├── pubspec.yaml │ │ ├── test │ │ │ └── widget_test.dart │ │ ├── test_driver │ │ │ └── integration_test.dart │ │ ├── web │ │ │ ├── favicon.png │ │ │ ├── icons │ │ │ │ ├── Icon-192.png │ │ │ │ ├── Icon-512.png │ │ │ │ ├── Icon-maskable-192.png │ │ │ │ └── Icon-maskable-512.png │ │ │ ├── index.html │ │ │ └── manifest.json │ │ └── windows │ │ │ ├── .gitignore │ │ │ ├── CMakeLists.txt │ │ │ ├── flutter │ │ │ ├── CMakeLists.txt │ │ │ ├── generated_plugin_registrant.cc │ │ │ ├── generated_plugin_registrant.h │ │ │ └── generated_plugins.cmake │ │ │ └── runner │ │ │ ├── CMakeLists.txt │ │ │ ├── Runner.rc │ │ │ ├── flutter_window.cpp │ │ │ ├── flutter_window.h │ │ │ ├── main.cpp │ │ │ ├── resource.h │ │ │ ├── resources │ │ │ └── app_icon.ico │ │ │ ├── runner.exe.manifest │ │ │ ├── utils.cpp │ │ │ ├── utils.h │ │ │ ├── win32_window.cpp │ │ │ └── win32_window.h │ └── run_example │ │ ├── .gitignore │ │ ├── .metadata │ │ ├── README.md │ │ ├── analysis_options.yaml │ │ ├── android │ │ ├── .gitignore │ │ ├── app │ │ │ ├── build.gradle │ │ │ └── src │ │ │ │ ├── debug │ │ │ │ └── AndroidManifest.xml │ │ │ │ ├── main │ │ │ │ ├── AndroidManifest.xml │ │ │ │ ├── kotlin │ │ │ │ │ └── com │ │ │ │ │ │ └── example │ │ │ │ │ │ └── run_example │ │ │ │ │ │ └── MainActivity.kt │ │ │ │ └── res │ │ │ │ │ ├── drawable-v21 │ │ │ │ │ └── launch_background.xml │ │ │ │ │ ├── drawable │ │ │ │ │ └── launch_background.xml │ │ │ │ │ ├── mipmap-hdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ ├── mipmap-mdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ ├── mipmap-xhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ │ └── ic_launcher.png │ │ │ │ │ ├── values-night │ │ │ │ │ └── styles.xml │ │ │ │ │ └── values │ │ │ │ │ └── styles.xml │ │ │ │ └── profile │ │ │ │ └── AndroidManifest.xml │ │ ├── build.gradle │ │ ├── gradle.properties │ │ ├── gradle │ │ │ └── wrapper │ │ │ │ └── gradle-wrapper.properties │ │ └── settings.gradle │ │ ├── app │ │ ├── app.zip.hash │ │ └── src │ │ │ ├── main.py │ │ │ └── requirements.txt │ │ ├── integration_test │ │ └── app_test.dart │ │ ├── ios │ │ ├── .gitignore │ │ ├── Flutter │ │ │ ├── AppFrameworkInfo.plist │ │ │ ├── Debug.xcconfig │ │ │ └── Release.xcconfig │ │ ├── Podfile │ │ ├── Podfile.lock │ │ ├── Runner.xcodeproj │ │ │ ├── project.pbxproj │ │ │ ├── project.xcworkspace │ │ │ │ ├── contents.xcworkspacedata │ │ │ │ └── xcshareddata │ │ │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ │ │ └── WorkspaceSettings.xcsettings │ │ │ └── xcshareddata │ │ │ │ └── xcschemes │ │ │ │ └── Runner.xcscheme │ │ ├── Runner.xcworkspace │ │ │ ├── contents.xcworkspacedata │ │ │ └── xcshareddata │ │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ │ └── WorkspaceSettings.xcsettings │ │ ├── Runner │ │ │ ├── AppDelegate.swift │ │ │ ├── Assets.xcassets │ │ │ │ ├── AppIcon.appiconset │ │ │ │ │ ├── Contents.json │ │ │ │ │ ├── Icon-App-1024x1024@1x.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 │ │ │ │ └── LaunchImage.imageset │ │ │ │ │ ├── Contents.json │ │ │ │ │ ├── LaunchImage.png │ │ │ │ │ ├── LaunchImage@2x.png │ │ │ │ │ ├── LaunchImage@3x.png │ │ │ │ │ └── README.md │ │ │ ├── Base.lproj │ │ │ │ ├── LaunchScreen.storyboard │ │ │ │ └── Main.storyboard │ │ │ ├── Info.plist │ │ │ └── Runner-Bridging-Header.h │ │ └── RunnerTests │ │ │ └── RunnerTests.swift │ │ ├── lib │ │ ├── main.dart │ │ └── utils.dart │ │ ├── linux │ │ ├── .gitignore │ │ ├── CMakeLists.txt │ │ ├── flutter │ │ │ ├── CMakeLists.txt │ │ │ ├── generated_plugin_registrant.cc │ │ │ ├── generated_plugin_registrant.h │ │ │ └── generated_plugins.cmake │ │ ├── main.cc │ │ ├── my_application.cc │ │ └── my_application.h │ │ ├── macos │ │ ├── .gitignore │ │ ├── Flutter │ │ │ ├── Flutter-Debug.xcconfig │ │ │ ├── Flutter-Release.xcconfig │ │ │ └── GeneratedPluginRegistrant.swift │ │ ├── Podfile │ │ ├── Podfile.lock │ │ ├── Runner.xcodeproj │ │ │ ├── project.pbxproj │ │ │ ├── project.xcworkspace │ │ │ │ └── xcshareddata │ │ │ │ │ └── IDEWorkspaceChecks.plist │ │ │ └── xcshareddata │ │ │ │ └── xcschemes │ │ │ │ └── Runner.xcscheme │ │ ├── Runner.xcworkspace │ │ │ ├── contents.xcworkspacedata │ │ │ └── xcshareddata │ │ │ │ └── IDEWorkspaceChecks.plist │ │ ├── Runner │ │ │ ├── AppDelegate.swift │ │ │ ├── Assets.xcassets │ │ │ │ └── AppIcon.appiconset │ │ │ │ │ ├── Contents.json │ │ │ │ │ ├── app_icon_1024.png │ │ │ │ │ ├── app_icon_128.png │ │ │ │ │ ├── app_icon_16.png │ │ │ │ │ ├── app_icon_256.png │ │ │ │ │ ├── app_icon_32.png │ │ │ │ │ ├── app_icon_512.png │ │ │ │ │ └── app_icon_64.png │ │ │ ├── Base.lproj │ │ │ │ └── MainMenu.xib │ │ │ ├── Configs │ │ │ │ ├── AppInfo.xcconfig │ │ │ │ ├── Debug.xcconfig │ │ │ │ ├── Release.xcconfig │ │ │ │ └── Warnings.xcconfig │ │ │ ├── DebugProfile.entitlements │ │ │ ├── Info.plist │ │ │ ├── MainFlutterWindow.swift │ │ │ └── Release.entitlements │ │ └── RunnerTests │ │ │ └── RunnerTests.swift │ │ ├── pubspec.lock │ │ ├── pubspec.yaml │ │ ├── test │ │ └── widget_test.dart │ │ ├── test_driver │ │ └── integration_test.dart │ │ └── windows │ │ ├── .gitignore │ │ ├── CMakeLists.txt │ │ ├── flutter │ │ ├── CMakeLists.txt │ │ ├── generated_plugin_registrant.cc │ │ ├── generated_plugin_registrant.h │ │ └── generated_plugins.cmake │ │ └── runner │ │ ├── CMakeLists.txt │ │ ├── Runner.rc │ │ ├── flutter_window.cpp │ │ ├── flutter_window.h │ │ ├── main.cpp │ │ ├── resource.h │ │ ├── resources │ │ └── app_icon.ico │ │ ├── runner.exe.manifest │ │ ├── utils.cpp │ │ ├── utils.h │ │ ├── win32_window.cpp │ │ └── win32_window.h ├── lib │ └── serious_python.dart ├── pubspec.yaml └── test │ └── glob_test.dart ├── serious_python_android ├── CHANGELOG.md ├── LICENSE ├── README.md ├── analysis_options.yaml ├── android │ ├── .gitignore │ ├── build.gradle │ ├── settings.gradle │ └── src │ │ └── main │ │ ├── AndroidManifest.xml │ │ └── java │ │ └── com │ │ └── flet │ │ └── serious_python_android │ │ ├── AndroidPlugin.java │ │ └── PythonActivity.java ├── lib │ ├── serious_python_android.dart │ └── src │ │ ├── cpython.dart │ │ └── gen.dart ├── pubspec.yaml ├── python_ffigen.yaml └── src │ ├── CMakeLists.txt │ ├── serious_python.c │ └── serious_python.h ├── serious_python_darwin ├── .gitignore ├── CHANGELOG.md ├── LICENSE ├── README.md ├── analysis_options.yaml ├── darwin │ ├── .gitignore │ ├── Classes │ │ └── SeriousPythonPlugin.swift │ ├── bundle-python-frameworks-ios.sh │ ├── pods-runner-frameworks-addon.sh │ ├── prepare_ios.sh │ ├── prepare_macos.sh │ ├── serious_python_darwin.podspec │ ├── symlink_pod.sh │ ├── sync_site_packages.sh │ └── xcframework_utils.sh ├── lib │ └── serious_python_darwin.dart └── pubspec.yaml ├── serious_python_linux ├── .metadata ├── CHANGELOG.md ├── LICENSE ├── README.md ├── analysis_options.yaml ├── lib │ └── serious_python_linux.dart ├── linux │ ├── CMakeLists.txt │ ├── include │ │ └── serious_python_linux │ │ │ └── serious_python_linux_plugin.h │ ├── serious_python_linux_plugin.cc │ ├── serious_python_linux_plugin_private.h │ └── test │ │ └── serious_python_linux_plugin_test.cc └── pubspec.yaml ├── serious_python_platform_interface ├── CHANGELOG.md ├── LICENSE ├── README.md ├── analysis_options.yaml ├── lib │ ├── serious_python_platform_interface.dart │ └── src │ │ ├── method_channel_serious_python.dart │ │ └── utils.dart ├── pubspec.yaml └── python_ffigen.yaml └── serious_python_windows ├── .metadata ├── CHANGELOG.md ├── LICENSE ├── README.md ├── analysis_options.yaml ├── lib └── serious_python_windows.dart ├── pubspec.yaml └── windows ├── .gitignore ├── CMakeLists.txt ├── include └── serious_python_windows │ └── serious_python_windows_plugin_c_api.h ├── serious_python_windows_plugin.cpp ├── serious_python_windows_plugin.h ├── serious_python_windows_plugin_c_api.cpp └── test └── serious_python_windows_plugin_test.cpp /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | migrate_working_dir/ 12 | 13 | # IntelliJ related 14 | *.iml 15 | *.ipr 16 | *.iws 17 | .idea/ 18 | 19 | # The .vscode folder contains launch configuration and tasks you configure in 20 | # VS Code which you may wish to be included in version control, so this line 21 | # is commented out by default. 22 | .vscode/ 23 | 24 | # Flutter/Dart/Pub related 25 | # Libraries should not include pubspec.lock, per https://dart.dev/guides/libraries/private-files#pubspeclock. 26 | pubspec.lock 27 | **/doc/api/ 28 | .dart_tool/ 29 | .packages 30 | build/ 31 | dist/ 32 | .cache 33 | .flutter-plugins 34 | .flutter-plugins-dependencies 35 | 36 | # Python 37 | .venv/ 38 | __pypackages__/ -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Contributing to `serious_python` 2 | 3 | ## Releasing a new version 4 | 5 | Bump version in: 6 | 7 | * `pubspec.yaml` 8 | * `src/serious_python_android/android/build.gradle` 9 | * `src/serious_python_darwin/ios/serious_python_darwin.podspec` 10 | 11 | Bump `serious_python` dependency version with `flutter pub get` in example lock files: 12 | 13 | * `src/serious_python/example/flet_example/pubspec.lock` 14 | * `src/serious_python/example/flask_example/pubspec.lock` 15 | * `src/serious_python/example/run_example/pubspec.lock` 16 | 17 | Update `CHANGELOG.md`. 18 | 19 | ## Getting token for automatic publishing to pub.dev 20 | 21 | Token locations on different OSes: https://stackoverflow.com/a/70487480/1435891 22 | 23 | Login to pub.dev: 24 | 25 | ``` 26 | flutter pub login 27 | ``` 28 | 29 | Encode token to base64: 30 | 31 | ``` 32 | cat $HOME/Library/Application\ Support/dart/pub-credentials.json | base64 33 | ``` -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | src/serious_python/README.md -------------------------------------------------------------------------------- /ci/install_flutter.sh: -------------------------------------------------------------------------------- 1 | dart pub global activate fvm 2 | export PATH=$HOME/.pub-cache/bin:$HOME/fvm/default/bin:$PATH 3 | fvm install $FLUTTER_VERSION 4 | fvm global $FLUTTER_VERSION 5 | flutter --version 6 | flutter doctor -------------------------------------------------------------------------------- /ci/patch_pubspec.py: -------------------------------------------------------------------------------- 1 | import os 2 | import pathlib 3 | import sys 4 | 5 | import yaml 6 | 7 | if len(sys.argv) < 3: 8 | print("Specify pubspec.yaml file and version to patch") 9 | sys.exit(1) 10 | 11 | current_dir = pathlib.Path(os.getcwd()) 12 | pubspec_path = current_dir.joinpath(current_dir, sys.argv[1]) 13 | ver = sys.argv[2] 14 | print(f"Patching pubspec.yaml file {pubspec_path} with {ver}") 15 | 16 | dependencies = [ 17 | "serious_python_platform_interface", 18 | "serious_python_android", 19 | "serious_python_darwin", 20 | "serious_python_windows", 21 | "serious_python_linux", 22 | "serious_python_macos", 23 | ] 24 | 25 | with open(pubspec_path, "r") as f: 26 | data = yaml.safe_load(f) 27 | 28 | # patch version 29 | data["version"] = ver 30 | 31 | # patch dependencies 32 | for dep in data["dependencies"]: 33 | if dep in dependencies: 34 | data["dependencies"][dep] = f"^{ver}" 35 | # print(dep) 36 | with open(pubspec_path, "w") as file: 37 | yaml.dump(data, file, sort_keys=False) 38 | -------------------------------------------------------------------------------- /src/serious_python/analysis_options.yaml: -------------------------------------------------------------------------------- 1 | include: package:flutter_lints/flutter.yaml 2 | 3 | # Additional information about this file can be found at 4 | # https://dart.dev/guides/language/analysis-options -------------------------------------------------------------------------------- /src/serious_python/bin/main.dart: -------------------------------------------------------------------------------- 1 | import 'package:args/command_runner.dart'; 2 | 3 | import 'package_command.dart'; 4 | 5 | void main(List arguments) async { 6 | var runner = CommandRunner("dart run serious_python:main", 7 | "A tool for packaging Python apps to work with serious_python package.") 8 | ..addCommand(PackageCommand()); 9 | 10 | await runner.run(arguments); 11 | } 12 | -------------------------------------------------------------------------------- /src/serious_python/bin/sitecustomize.dart: -------------------------------------------------------------------------------- 1 | String sitecustomizePy = """ 2 | # A site customization that can be used to trick pip into installing packages cross-platform. 3 | # The folder containing this file should be on your PYTHONPATH pip is invoked. 4 | 5 | custom_system = "{platform}" 6 | custom_platform = "{tag}" 7 | custom_mac_ver = "{mac_ver}" 8 | 9 | import collections 10 | import platform 11 | import sysconfig 12 | import sys 13 | 14 | if custom_system: 15 | platform.system = lambda: custom_system 16 | 17 | if custom_platform: 18 | sysconfig.get_platform = lambda: custom_platform 19 | 20 | if custom_mac_ver: 21 | orig_mac_ver = platform.mac_ver 22 | 23 | def custom_mac_ver_impl(): 24 | orig = orig_mac_ver() 25 | return orig[0], orig[1], custom_mac_ver 26 | 27 | platform.mac_ver = custom_mac_ver_impl 28 | 29 | if custom_system == "iOS": 30 | IOSVersionInfo = collections.namedtuple( 31 | "IOSVersionInfo", 32 | ["system", "release", "model", "is_simulator"] 33 | ) 34 | 35 | tag_parts = custom_platform.split("-") 36 | 37 | def custom_ios_ver(system="", release="", model="", is_simulator=False): 38 | return IOSVersionInfo(custom_system, tag_parts[1], "iPhone", "simulator" in tag_parts[3]) 39 | 40 | platform.ios_ver = custom_ios_ver 41 | 42 | sys.implementation._multiarch = f"{tag_parts[2]}_{tag_parts[3]}" 43 | 44 | orig_platform_version = platform.version 45 | platform.version = lambda: orig_platform_version() + ";embedded" 46 | """; 47 | -------------------------------------------------------------------------------- /src/serious_python/example/.gitignore: -------------------------------------------------------------------------------- 1 | # Dart 2 | !pubspec.lock 3 | 4 | # Python 5 | .venv/ 6 | __pypackages__/ 7 | *.zip -------------------------------------------------------------------------------- /src/serious_python/example/README.md: -------------------------------------------------------------------------------- 1 | # Examples 2 | 3 | ### Python REPL with Flask backend 4 | 5 | An exampe of using Flask to host app backend API written in Python. 6 | 7 | [Source](flask_example) 8 | 9 | ### Flet app 10 | 11 | An example of integrating [Flet widget](https://pub.dev/packages/flet) and [Flet framework](https://pypi.org/project/flet/) to easily create awesome Flutter apps in Python. 12 | 13 | [Source](flet_example) 14 | 15 | ### Run app for integration tests 16 | 17 | A simple app that uses Python to save a random value into a text file and then read it back 18 | from Dart - used in integration tests. 19 | 20 | [Source](run_example) -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | migrate_working_dir/ 12 | 13 | # IntelliJ related 14 | *.iml 15 | *.ipr 16 | *.iws 17 | .idea/ 18 | 19 | # The .vscode folder contains launch configuration and tasks you configure in 20 | # VS Code which you may wish to be included in version control, so this line 21 | # is commented out by default. 22 | #.vscode/ 23 | 24 | # Flutter/Dart/Pub related 25 | **/doc/api/ 26 | **/ios/Flutter/.last_build_id 27 | .dart_tool/ 28 | .flutter-plugins 29 | .flutter-plugins-dependencies 30 | .packages 31 | .pub-cache/ 32 | .pub/ 33 | /build/ 34 | 35 | # Symbolication related 36 | app.*.symbols 37 | 38 | # Obfuscation related 39 | app.*.map.json 40 | 41 | # Android Studio will place build artifacts here 42 | /android/app/debug 43 | /android/app/profile 44 | /android/app/release 45 | 46 | /app/app.zip -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/.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: "6c4930c4ac86fb286f30e31d0ec8bffbcbb9953e" 8 | channel: "stable" 9 | 10 | project_type: app 11 | 12 | # Tracks metadata for the flutter migrate command 13 | migration: 14 | platforms: 15 | - platform: root 16 | create_revision: 6c4930c4ac86fb286f30e31d0ec8bffbcbb9953e 17 | base_revision: 6c4930c4ac86fb286f30e31d0ec8bffbcbb9953e 18 | - platform: linux 19 | create_revision: 6c4930c4ac86fb286f30e31d0ec8bffbcbb9953e 20 | base_revision: 6c4930c4ac86fb286f30e31d0ec8bffbcbb9953e 21 | 22 | # User provided section 23 | 24 | # List of Local paths (relative to this file) that should be 25 | # ignored by the migrate tool. 26 | # 27 | # Files that are not part of the templates will be ignored by default. 28 | unmanaged_files: 29 | - 'lib/main.dart' 30 | - 'ios/Runner.xcodeproj/project.pbxproj' 31 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/README.md: -------------------------------------------------------------------------------- 1 | # flask_example 2 | 3 | Before running the app run the following command to package Python app to an asset. 4 | 5 | For Android: 6 | 7 | ``` 8 | export SERIOUS_PYTHON_SITE_PACKAGES=$(pwd)/build/site-packages 9 | dart run serious_python:main package app/src -p Android --requirements -r,app/src/requirements.txt 10 | ``` 11 | 12 | For iOS: 13 | 14 | ``` 15 | export SERIOUS_PYTHON_SITE_PACKAGES=$(pwd)/build/site-packages 16 | dart run serious_python:main package app/src -p iOS --requirements -r,app/src/requirements.txt 17 | ``` 18 | 19 | For macOS: 20 | 21 | ``` 22 | dart run serious_python:main package app/src -p Darwin --requirements -r,app/src/requirements.txt 23 | ``` 24 | 25 | For Windows: 26 | 27 | ``` 28 | dart run serious_python:main package app/src -p Windows --requirements -r,app/src/requirements.txt 29 | ``` 30 | 31 | For Linux: 32 | 33 | ``` 34 | dart run serious_python:main package app/src -p Linux --requirements -r,app/src/requirements.txt 35 | ``` 36 | 37 | Important: to make `serious_python` work in your own Android app: 38 | 39 | If you build an App Bundle Edit `android/gradle.properties` and add the flag: 40 | 41 | ``` 42 | android.bundle.enableUncompressedNativeLibs=false 43 | ``` 44 | 45 | If you build an APK Make sure `android/app/src/AndroidManifest.xml` has `android:extractNativeLibs="true"` in the `` tag. 46 | 47 | For more information, see the [public issue](https://issuetracker.google.com/issues/147096055). -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/kotlin/com/example/flask_example/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.example.flask_example 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() { 6 | } 7 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/drawable-v21/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.7.10' 3 | repositories { 4 | google() 5 | mavenCentral() 6 | } 7 | 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:7.3.0' 10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 11 | } 12 | } 13 | 14 | allprojects { 15 | repositories { 16 | google() 17 | mavenCentral() 18 | } 19 | } 20 | 21 | rootProject.buildDir = '../build' 22 | subprojects { 23 | project.buildDir = "${rootProject.buildDir}/${project.name}" 24 | } 25 | subprojects { 26 | project.evaluationDependsOn(':app') 27 | } 28 | 29 | tasks.register("clean", Delete) { 30 | delete rootProject.buildDir 31 | } 32 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | android.bundle.enableUncompressedNativeLibs=false -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-all.zip 6 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/app/app.zip.hash: -------------------------------------------------------------------------------- 1 | 9abed4a7d914300e2cf342c04e7dfcf58a5dbda44fc93a99a86b0e8831207840 -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/app/src/main.py: -------------------------------------------------------------------------------- 1 | from contextlib import redirect_stdout 2 | from io import StringIO 3 | 4 | from flask import Flask, request 5 | 6 | port = 55001 7 | 8 | print("Trying to run a socket server on:", port) 9 | 10 | 11 | class PythonRunner: 12 | __globals = {} 13 | __locals = {} 14 | 15 | def run(self, code): 16 | f = StringIO() 17 | with redirect_stdout(f): 18 | exec(code, self.__globals, self.__locals) 19 | return f.getvalue() 20 | 21 | 22 | pr = PythonRunner() 23 | 24 | 25 | app = Flask(__name__) 26 | 27 | 28 | @app.route("/") 29 | def hello_world(): 30 | return 'Enter Python code and tap "Run".' 31 | 32 | 33 | @app.route("/python", methods=["POST"]) 34 | def run_python(): 35 | try: 36 | return pr.run(request.json["command"]) 37 | except Exception as e: 38 | return str(e) 39 | 40 | app.run(port=port) 41 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/app/src/requirements.txt: -------------------------------------------------------------------------------- 1 | flask -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | 11.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - Flutter (1.0.0) 3 | - package_info_plus (0.4.5): 4 | - Flutter 5 | - path_provider_foundation (0.0.1): 6 | - Flutter 7 | - FlutterMacOS 8 | - serious_python_darwin (0.6.0): 9 | - Flutter 10 | - FlutterMacOS 11 | 12 | DEPENDENCIES: 13 | - Flutter (from `Flutter`) 14 | - package_info_plus (from `.symlinks/plugins/package_info_plus/ios`) 15 | - path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`) 16 | - serious_python_darwin (from `.symlinks/plugins/serious_python_darwin/darwin`) 17 | 18 | EXTERNAL SOURCES: 19 | Flutter: 20 | :path: Flutter 21 | package_info_plus: 22 | :path: ".symlinks/plugins/package_info_plus/ios" 23 | path_provider_foundation: 24 | :path: ".symlinks/plugins/path_provider_foundation/darwin" 25 | serious_python_darwin: 26 | :path: ".symlinks/plugins/serious_python_darwin/darwin" 27 | 28 | SPEC CHECKSUMS: 29 | Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854 30 | package_info_plus: 115f4ad11e0698c8c1c5d8a689390df880f47e85 31 | path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943 32 | serious_python_darwin: d5c85ae2cd4539b52c71ea8ba8af357aa6311647 33 | 34 | PODFILE CHECKSUM: 7be2f5f74864d463a8ad433546ed1de7e0f29aef 35 | 36 | COCOAPODS: 1.12.1 37 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import Flutter 3 | 4 | @UIApplicationMain 5 | @objc class AppDelegate: FlutterAppDelegate { 6 | override func application( 7 | _ application: UIApplication, 8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? 9 | ) -> Bool { 10 | GeneratedPluginRegistrant.register(with: self) 11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions) 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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. -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/ios/RunnerTests/RunnerTests.swift: -------------------------------------------------------------------------------- 1 | import Flutter 2 | import UIKit 3 | import XCTest 4 | 5 | class RunnerTests: XCTestCase { 6 | 7 | func testExample() { 8 | // If you add code to the Runner application, consider adding tests here. 9 | // See https://developer.apple.com/documentation/xctest for more information about using XCTest. 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/linux/.gitignore: -------------------------------------------------------------------------------- 1 | flutter/ephemeral 2 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | #include 10 | 11 | void fl_register_plugins(FlPluginRegistry* registry) { 12 | g_autoptr(FlPluginRegistrar) serious_python_linux_registrar = 13 | fl_plugin_registry_get_registrar_for_plugin(registry, "SeriousPythonLinuxPlugin"); 14 | serious_python_linux_plugin_register_with_registrar(serious_python_linux_registrar); 15 | } 16 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/linux/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | serious_python_linux 7 | ) 8 | 9 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 10 | ) 11 | 12 | set(PLUGIN_BUNDLED_LIBRARIES) 13 | 14 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 15 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin}) 16 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 17 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 18 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 19 | endforeach(plugin) 20 | 21 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 22 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin}) 23 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 24 | endforeach(ffi_plugin) 25 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/.gitignore: -------------------------------------------------------------------------------- 1 | # Flutter-related 2 | **/Flutter/ephemeral/ 3 | **/Pods/ 4 | 5 | # Xcode-related 6 | **/dgph 7 | **/xcuserdata/ 8 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Flutter/Flutter-Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Flutter/Flutter-Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Flutter/GeneratedPluginRegistrant.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | import FlutterMacOS 6 | import Foundation 7 | 8 | import path_provider_foundation 9 | import serious_python_darwin 10 | 11 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { 12 | PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) 13 | SeriousPythonPlugin.register(with: registry.registrar(forPlugin: "SeriousPythonPlugin")) 14 | } 15 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - FlutterMacOS (1.0.0) 3 | - package_info_plus (0.0.1): 4 | - FlutterMacOS 5 | - path_provider_foundation (0.0.1): 6 | - Flutter 7 | - FlutterMacOS 8 | - serious_python_darwin (0.7.0): 9 | - Flutter 10 | - FlutterMacOS 11 | 12 | DEPENDENCIES: 13 | - FlutterMacOS (from `Flutter/ephemeral`) 14 | - package_info_plus (from `Flutter/ephemeral/.symlinks/plugins/package_info_plus/macos`) 15 | - path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin`) 16 | - serious_python_darwin (from `Flutter/ephemeral/.symlinks/plugins/serious_python_darwin/darwin`) 17 | 18 | EXTERNAL SOURCES: 19 | FlutterMacOS: 20 | :path: Flutter/ephemeral 21 | package_info_plus: 22 | :path: Flutter/ephemeral/.symlinks/plugins/package_info_plus/macos 23 | path_provider_foundation: 24 | :path: Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin 25 | serious_python_darwin: 26 | :path: Flutter/ephemeral/.symlinks/plugins/serious_python_darwin/darwin 27 | 28 | SPEC CHECKSUMS: 29 | FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24 30 | package_info_plus: 02d7a575e80f194102bef286361c6c326e4c29ce 31 | path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943 32 | serious_python_darwin: 0a8c46a529057f91064a327d9c4037e773eef339 33 | 34 | PODFILE CHECKSUM: 9ebaf0ce3d369aaa26a9ea0e159195ed94724cf3 35 | 36 | COCOAPODS: 1.14.3 37 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 = flask_example 9 | 10 | // The application's bundle identifier 11 | PRODUCT_BUNDLE_IDENTIFIER = com.example.flaskExample 12 | 13 | // The copyright displayed in application information 14 | PRODUCT_COPYRIGHT = Copyright © 2023 com.example. All rights reserved. 15 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Configs/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Debug.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Configs/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Release.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/MainFlutterWindow.swift: -------------------------------------------------------------------------------- 1 | import Cocoa 2 | import FlutterMacOS 3 | 4 | class MainFlutterWindow: NSWindow { 5 | override func awakeFromNib() { 6 | let flutterViewController = FlutterViewController() 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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/Runner/Release.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/macos/RunnerTests/RunnerTests.swift: -------------------------------------------------------------------------------- 1 | import FlutterMacOS 2 | import Cocoa 3 | import XCTest 4 | 5 | class RunnerTests: XCTestCase { 6 | 7 | func testExample() { 8 | // If you add code to the Runner application, consider adding tests here. 9 | // See https://developer.apple.com/documentation/xctest for more information about using XCTest. 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 in the flutter_test package. 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:flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | #include 10 | 11 | void RegisterPlugins(flutter::PluginRegistry* registry) { 12 | SeriousPythonWindowsPluginCApiRegisterWithRegistrar( 13 | registry->GetRegistrarForPlugin("SeriousPythonWindowsPluginCApi")); 14 | } 15 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/windows/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | serious_python_windows 7 | ) 8 | 9 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 10 | ) 11 | 12 | set(PLUGIN_BUNDLED_LIBRARIES) 13 | 14 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 15 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin}) 16 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 17 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 18 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 19 | endforeach(plugin) 20 | 21 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 22 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin}) 23 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 24 | endforeach(ffi_plugin) 25 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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.Create(L"flask_example", 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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/windows/runner/resources/app_icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flask_example/windows/runner/resources/app_icon.ico -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flask_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | migrate_working_dir/ 12 | 13 | # IntelliJ related 14 | *.iml 15 | *.ipr 16 | *.iws 17 | .idea/ 18 | 19 | # The .vscode folder contains launch configuration and tasks you configure in 20 | # VS Code which you may wish to be included in version control, so this line 21 | # is commented out by default. 22 | #.vscode/ 23 | 24 | # Flutter/Dart/Pub related 25 | **/doc/api/ 26 | **/ios/Flutter/.last_build_id 27 | .dart_tool/ 28 | .flutter-plugins 29 | .flutter-plugins-dependencies 30 | .packages 31 | .pub-cache/ 32 | .pub/ 33 | /build/ 34 | 35 | # Symbolication related 36 | app.*.symbols 37 | 38 | # Obfuscation related 39 | app.*.map.json 40 | 41 | # Android Studio will place build artifacts here 42 | /android/app/debug 43 | /android/app/profile 44 | /android/app/release 45 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/.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: "68415ad1d920f6fe5ec284f5c2febf7c4dd5b0b3" 8 | channel: "stable" 9 | 10 | project_type: app 11 | 12 | # Tracks metadata for the flutter migrate command 13 | migration: 14 | platforms: 15 | - platform: root 16 | create_revision: 68415ad1d920f6fe5ec284f5c2febf7c4dd5b0b3 17 | base_revision: 68415ad1d920f6fe5ec284f5c2febf7c4dd5b0b3 18 | - platform: android 19 | create_revision: 68415ad1d920f6fe5ec284f5c2febf7c4dd5b0b3 20 | base_revision: 68415ad1d920f6fe5ec284f5c2febf7c4dd5b0b3 21 | 22 | # User provided section 23 | 24 | # List of Local paths (relative to this file) that should be 25 | # ignored by the migrate tool. 26 | # 27 | # Files that are not part of the templates will be ignored by default. 28 | unmanaged_files: 29 | - 'lib/main.dart' 30 | - 'ios/Runner.xcodeproj/project.pbxproj' 31 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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/to/reference-keystore 11 | key.properties 12 | **/*.keystore 13 | **/*.jks 14 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/kotlin/com/example/flet_example/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.example.flet_example 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() 6 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/drawable-v21/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/build.gradle: -------------------------------------------------------------------------------- 1 | allprojects { 2 | repositories { 3 | google() 4 | mavenCentral() 5 | } 6 | } 7 | 8 | rootProject.buildDir = "../build" 9 | subprojects { 10 | project.buildDir = "${rootProject.buildDir}/${project.name}" 11 | } 12 | subprojects { 13 | project.evaluationDependsOn(":app") 14 | } 15 | 16 | tasks.register("clean", Delete) { 17 | delete rootProject.buildDir 18 | } 19 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx4G -XX:MaxMetaspaceSize=2G -XX:+HeapDumpOnOutOfMemoryError 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-all.zip 6 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/android/settings.gradle: -------------------------------------------------------------------------------- 1 | pluginManagement { 2 | def flutterSdkPath = { 3 | def properties = new Properties() 4 | file("local.properties").withInputStream { properties.load(it) } 5 | def flutterSdkPath = properties.getProperty("flutter.sdk") 6 | assert flutterSdkPath != null, "flutter.sdk not set in local.properties" 7 | return flutterSdkPath 8 | }() 9 | 10 | includeBuild("$flutterSdkPath/packages/flutter_tools/gradle") 11 | 12 | repositories { 13 | google() 14 | mavenCentral() 15 | gradlePluginPortal() 16 | } 17 | } 18 | 19 | plugins { 20 | id "dev.flutter.flutter-plugin-loader" version "1.0.0" 21 | id "com.android.application" version "8.1.0" apply false 22 | id "org.jetbrains.kotlin.android" version "1.8.22" apply false 23 | } 24 | 25 | include ":app" 26 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/app/app.zip.hash: -------------------------------------------------------------------------------- 1 | 43f8a7b00e44a09647dda36299259976950ba7259c5060de20677c449690fc73 -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/app/src/main_async.py: -------------------------------------------------------------------------------- 1 | import logging 2 | 3 | import flet as ft 4 | 5 | logging.basicConfig(level=logging.DEBUG) 6 | 7 | 8 | async def main(page: ft.Page): 9 | page.title = "Flet counter example" 10 | page.vertical_alignment = ft.MainAxisAlignment.CENTER 11 | 12 | txt_number = ft.TextField(value="0", text_align=ft.TextAlign.RIGHT, width=100) 13 | 14 | async def minus_click(e): 15 | txt_number.value = str(int(txt_number.value) - 1) 16 | await page.update_async() 17 | 18 | async def plus_click(e): 19 | txt_number.value = str(int(txt_number.value) + 1) 20 | await page.update_async() 21 | 22 | await page.add_async( 23 | ft.Row( 24 | [ 25 | ft.IconButton( 26 | ft.icons.REMOVE, key="test:decrement", on_click=minus_click 27 | ), 28 | txt_number, 29 | ft.IconButton(ft.icons.ADD, key="test:increment", on_click=plus_click), 30 | ], 31 | alignment=ft.MainAxisAlignment.CENTER, 32 | ) 33 | ) 34 | 35 | 36 | ft.app(main) 37 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/app/src/requirements.txt: -------------------------------------------------------------------------------- 1 | --pre 2 | flet -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/integration_test/app_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:flet_example/main.dart' as app; 2 | import 'package:flutter/foundation.dart'; 3 | import 'package:flutter_test/flutter_test.dart'; 4 | import 'package:integration_test/integration_test.dart'; 5 | 6 | void main() { 7 | IntegrationTestWidgetsFlutterBinding.ensureInitialized(); 8 | 9 | group('end-to-end test', () { 10 | testWidgets('make sure counter can be incremented and decremented', 11 | (tester) async { 12 | app.main(); 13 | await tester.pumpAndSettle(); 14 | 15 | // Wait for up to 10 seconds for the app to start 16 | bool counterFound = false; 17 | for (int i = 0; i < 20; i++) { 18 | await tester.pump(const Duration(seconds: 1)); 19 | 20 | if (find.text('0').evaluate().isNotEmpty) { 21 | counterFound = true; 22 | break; 23 | } 24 | } 25 | 26 | expect(counterFound, isTrue); 27 | 28 | // Tap increment button 29 | final incrementButton = find.byKey(const Key('increment')); 30 | await tester.tap(incrementButton); 31 | await tester.pumpAndSettle(); 32 | expect(find.text('1'), findsOneWidget); 33 | 34 | // Tap decrement button 35 | final decrementButton = find.byKey(const Key('decrement')); 36 | await tester.tap(decrementButton); 37 | await tester.tap(decrementButton); 38 | await tester.pumpAndSettle(); 39 | expect(find.text('-1'), findsOneWidget); 40 | }); 41 | }); 42 | } 43 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | 12.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import Flutter 3 | 4 | @main 5 | @objc class AppDelegate: FlutterAppDelegate { 6 | override func application( 7 | _ application: UIApplication, 8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? 9 | ) -> Bool { 10 | GeneratedPluginRegistrant.register(with: self) 11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions) 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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. -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/ios/RunnerTests/RunnerTests.swift: -------------------------------------------------------------------------------- 1 | import Flutter 2 | import UIKit 3 | import XCTest 4 | 5 | class RunnerTests: XCTestCase { 6 | 7 | func testExample() { 8 | // If you add code to the Runner application, consider adding tests here. 9 | // See https://developer.apple.com/documentation/xctest for more information about using XCTest. 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/linux/.gitignore: -------------------------------------------------------------------------------- 1 | flutter/ephemeral 2 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/linux/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | screen_retriever_linux 7 | serious_python_linux 8 | url_launcher_linux 9 | window_manager 10 | window_to_front 11 | ) 12 | 13 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 14 | ) 15 | 16 | set(PLUGIN_BUNDLED_LIBRARIES) 17 | 18 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 19 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin}) 20 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 21 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 22 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 23 | endforeach(plugin) 24 | 25 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 26 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin}) 27 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 28 | endforeach(ffi_plugin) 29 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/.gitignore: -------------------------------------------------------------------------------- 1 | # Flutter-related 2 | **/Flutter/ephemeral/ 3 | **/Pods/ 4 | 5 | # Xcode-related 6 | **/dgph 7 | **/xcuserdata/ 8 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Flutter/Flutter-Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Flutter/Flutter-Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Flutter/GeneratedPluginRegistrant.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | import FlutterMacOS 6 | import Foundation 7 | 8 | import device_info_plus 9 | import file_picker 10 | import package_info_plus 11 | import path_provider_foundation 12 | import screen_retriever_macos 13 | import serious_python_darwin 14 | import shared_preferences_foundation 15 | import url_launcher_macos 16 | import window_manager 17 | import window_to_front 18 | 19 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { 20 | DeviceInfoPlusMacosPlugin.register(with: registry.registrar(forPlugin: "DeviceInfoPlusMacosPlugin")) 21 | FilePickerPlugin.register(with: registry.registrar(forPlugin: "FilePickerPlugin")) 22 | FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin")) 23 | PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) 24 | ScreenRetrieverMacosPlugin.register(with: registry.registrar(forPlugin: "ScreenRetrieverMacosPlugin")) 25 | SeriousPythonPlugin.register(with: registry.registrar(forPlugin: "SeriousPythonPlugin")) 26 | SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) 27 | UrlLauncherPlugin.register(with: registry.registrar(forPlugin: "UrlLauncherPlugin")) 28 | WindowManagerPlugin.register(with: registry.registrar(forPlugin: "WindowManagerPlugin")) 29 | WindowToFrontPlugin.register(with: registry.registrar(forPlugin: "WindowToFrontPlugin")) 30 | } 31 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import Cocoa 2 | import FlutterMacOS 3 | 4 | @main 5 | class AppDelegate: FlutterAppDelegate { 6 | override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool { 7 | return true 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 = flet_example 9 | 10 | // The application's bundle identifier 11 | PRODUCT_BUNDLE_IDENTIFIER = com.example.fletExample 12 | 13 | // The copyright displayed in application information 14 | PRODUCT_COPYRIGHT = Copyright © 2023 com.example. All rights reserved. 15 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Configs/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Debug.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Configs/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Release.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/MainFlutterWindow.swift: -------------------------------------------------------------------------------- 1 | import Cocoa 2 | import FlutterMacOS 3 | 4 | class MainFlutterWindow: NSWindow { 5 | override func awakeFromNib() { 6 | let flutterViewController = FlutterViewController() 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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/Runner/Release.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/macos/RunnerTests/RunnerTests.swift: -------------------------------------------------------------------------------- 1 | import FlutterMacOS 2 | import Cocoa 3 | import XCTest 4 | 5 | class RunnerTests: XCTestCase { 6 | 7 | func testExample() { 8 | // If you add code to the Runner application, consider adding tests here. 9 | // See https://developer.apple.com/documentation/xctest for more information about using XCTest. 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 in the flutter_test package. 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 | void main() { 9 | // todo 10 | } 11 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/test_driver/integration_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:integration_test/integration_test_driver.dart'; 2 | 3 | Future main() => integrationDriver(); 4 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/web/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/web/favicon.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/web/icons/Icon-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/web/icons/Icon-192.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/web/icons/Icon-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/web/icons/Icon-512.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/web/icons/Icon-maskable-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/web/icons/Icon-maskable-192.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/web/icons/Icon-maskable-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/web/icons/Icon-maskable-512.png -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/web/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "flet_example", 3 | "short_name": "flet_example", 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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | 15 | void RegisterPlugins(flutter::PluginRegistry* registry) { 16 | ScreenRetrieverWindowsPluginCApiRegisterWithRegistrar( 17 | registry->GetRegistrarForPlugin("ScreenRetrieverWindowsPluginCApi")); 18 | SeriousPythonWindowsPluginCApiRegisterWithRegistrar( 19 | registry->GetRegistrarForPlugin("SeriousPythonWindowsPluginCApi")); 20 | UrlLauncherWindowsRegisterWithRegistrar( 21 | registry->GetRegistrarForPlugin("UrlLauncherWindows")); 22 | WindowManagerPluginRegisterWithRegistrar( 23 | registry->GetRegistrarForPlugin("WindowManagerPlugin")); 24 | WindowToFrontPluginRegisterWithRegistrar( 25 | registry->GetRegistrarForPlugin("WindowToFrontPlugin")); 26 | } 27 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/windows/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | screen_retriever_windows 7 | serious_python_windows 8 | url_launcher_windows 9 | window_manager 10 | window_to_front 11 | ) 12 | 13 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 14 | ) 15 | 16 | set(PLUGIN_BUNDLED_LIBRARIES) 17 | 18 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 19 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin}) 20 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 21 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 22 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 23 | endforeach(plugin) 24 | 25 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 26 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin}) 27 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 28 | endforeach(ffi_plugin) 29 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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.Create(L"flet_example", 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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/windows/runner/resources/app_icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/flet_example/windows/runner/resources/app_icon.ico -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/flet_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .build/ 9 | .buildlog/ 10 | .history 11 | .svn/ 12 | .swiftpm/ 13 | migrate_working_dir/ 14 | 15 | # IntelliJ related 16 | *.iml 17 | *.ipr 18 | *.iws 19 | .idea/ 20 | 21 | # The .vscode folder contains launch configuration and tasks you configure in 22 | # VS Code which you may wish to be included in version control, so this line 23 | # is commented out by default. 24 | #.vscode/ 25 | 26 | # Flutter/Dart/Pub related 27 | **/doc/api/ 28 | **/ios/Flutter/.last_build_id 29 | .dart_tool/ 30 | .flutter-plugins 31 | .flutter-plugins-dependencies 32 | .packages 33 | .pub-cache/ 34 | .pub/ 35 | /build/ 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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/kotlin/com/example/run_example/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.example.run_example 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() { 6 | } 7 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/drawable-v21/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.9.24' 3 | repositories { 4 | google() 5 | mavenCentral() 6 | } 7 | 8 | dependencies { 9 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 10 | } 11 | } 12 | 13 | allprojects { 14 | repositories { 15 | google() 16 | mavenCentral() 17 | } 18 | } 19 | 20 | rootProject.buildDir = '../build' 21 | subprojects { 22 | project.buildDir = "${rootProject.buildDir}/${project.name}" 23 | } 24 | subprojects { 25 | project.evaluationDependsOn(':app') 26 | } 27 | 28 | tasks.register("clean", Delete) { 29 | delete rootProject.buildDir 30 | } 31 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip -------------------------------------------------------------------------------- /src/serious_python/example/run_example/android/settings.gradle: -------------------------------------------------------------------------------- 1 | pluginManagement { 2 | def flutterSdkPath = { 3 | def properties = new Properties() 4 | file("local.properties").withInputStream { properties.load(it) } 5 | def flutterSdkPath = properties.getProperty("flutter.sdk") 6 | assert flutterSdkPath != null, "flutter.sdk not set in local.properties" 7 | return flutterSdkPath 8 | } 9 | settings.ext.flutterSdkPath = flutterSdkPath() 10 | 11 | includeBuild("${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle") 12 | 13 | repositories { 14 | google() 15 | mavenCentral() 16 | gradlePluginPortal() 17 | } 18 | 19 | plugins { 20 | id "dev.flutter.flutter-gradle-plugin" version "1.0.0" apply false 21 | } 22 | } 23 | 24 | plugins { 25 | id "dev.flutter.flutter-plugin-loader" version "1.0.0" 26 | id "com.android.application" version "8.3.1" apply false 27 | } 28 | 29 | include ":app" 30 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/app/app.zip.hash: -------------------------------------------------------------------------------- 1 | f191238eabf7628dcbb3a2671a20407a5338b7c375c015bf177ece347228b8ea -------------------------------------------------------------------------------- /src/serious_python/example/run_example/app/src/requirements.txt: -------------------------------------------------------------------------------- 1 | numpy 2 | #lru-dict 3 | #pyjnius 4 | #flet-libsodium 5 | # pysodium 6 | # numpy 7 | # Pyrebase4 -------------------------------------------------------------------------------- /src/serious_python/example/run_example/integration_test/app_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_test/flutter_test.dart'; 2 | import 'package:integration_test/integration_test.dart'; 3 | import 'package:run_example/main.dart'; 4 | 5 | void main() { 6 | IntegrationTestWidgetsFlutterBinding.ensureInitialized(); 7 | 8 | group('end-to-end test', () { 9 | testWidgets('tap on the floating action button, verify counter', 10 | (tester) async { 11 | // Load app widget. 12 | await tester.pumpWidget(const MyApp()); 13 | 14 | // Verify the initial state is "Running..." 15 | expect(find.text('Running...'), findsOneWidget); 16 | 17 | // Wait for up to 10 seconds for the text to change to "PASS" 18 | bool textChanged = false; 19 | for (int i = 0; i < 10; i++) { 20 | await tester.pump(const Duration(seconds: 1)); 21 | 22 | if (find.text('PASS').evaluate().isNotEmpty) { 23 | textChanged = true; 24 | break; 25 | } 26 | } 27 | 28 | // Verify the text has changed to "PASS" 29 | expect(textChanged, isTrue); 30 | }); 31 | }); 32 | } 33 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | 12.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - Flutter (1.0.0) 3 | - integration_test (0.0.1): 4 | - Flutter 5 | - path_provider_foundation (0.0.1): 6 | - Flutter 7 | - FlutterMacOS 8 | - serious_python_darwin (0.9.0): 9 | - Flutter 10 | - FlutterMacOS 11 | 12 | DEPENDENCIES: 13 | - Flutter (from `Flutter`) 14 | - integration_test (from `.symlinks/plugins/integration_test/ios`) 15 | - path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`) 16 | - serious_python_darwin (from `.symlinks/plugins/serious_python_darwin/darwin`) 17 | 18 | EXTERNAL SOURCES: 19 | Flutter: 20 | :path: Flutter 21 | integration_test: 22 | :path: ".symlinks/plugins/integration_test/ios" 23 | path_provider_foundation: 24 | :path: ".symlinks/plugins/path_provider_foundation/darwin" 25 | serious_python_darwin: 26 | :path: ".symlinks/plugins/serious_python_darwin/darwin" 27 | 28 | SPEC CHECKSUMS: 29 | Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7 30 | integration_test: 252f60fa39af5e17c3aa9899d35d908a0721b573 31 | path_provider_foundation: 2b6b4c569c0fb62ec74538f866245ac84301af46 32 | serious_python_darwin: f9c5bd0dc6fbe536075be8606baaf5eebae61ea8 33 | 34 | PODFILE CHECKSUM: a57f30d18f102dd3ce366b1d62a55ecbef2158e5 35 | 36 | COCOAPODS: 1.14.3 37 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import Flutter 3 | 4 | @main 5 | @objc class AppDelegate: FlutterAppDelegate { 6 | override func application( 7 | _ application: UIApplication, 8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? 9 | ) -> Bool { 10 | GeneratedPluginRegistrant.register(with: self) 11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions) 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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. -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/ios/RunnerTests/RunnerTests.swift: -------------------------------------------------------------------------------- 1 | import Flutter 2 | import UIKit 3 | import XCTest 4 | 5 | class RunnerTests: XCTestCase { 6 | 7 | func testExample() { 8 | // If you add code to the Runner application, consider adding tests here. 9 | // See https://developer.apple.com/documentation/xctest for more information about using XCTest. 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/lib/utils.dart: -------------------------------------------------------------------------------- 1 | import 'dart:math'; 2 | 3 | const _chars = 'AaBbCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZz1234567890'; 4 | Random _rnd = Random(); 5 | 6 | String getRandomString(int length) => String.fromCharCodes(Iterable.generate( 7 | length, (_) => _chars.codeUnitAt(_rnd.nextInt(_chars.length)))); 8 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/linux/.gitignore: -------------------------------------------------------------------------------- 1 | flutter/ephemeral 2 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | #include 10 | 11 | void fl_register_plugins(FlPluginRegistry* registry) { 12 | g_autoptr(FlPluginRegistrar) serious_python_linux_registrar = 13 | fl_plugin_registry_get_registrar_for_plugin(registry, "SeriousPythonLinuxPlugin"); 14 | serious_python_linux_plugin_register_with_registrar(serious_python_linux_registrar); 15 | } 16 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/linux/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | serious_python_linux 7 | ) 8 | 9 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 10 | ) 11 | 12 | set(PLUGIN_BUNDLED_LIBRARIES) 13 | 14 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 15 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin}) 16 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 17 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 18 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 19 | endforeach(plugin) 20 | 21 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 22 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin}) 23 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 24 | endforeach(ffi_plugin) 25 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/.gitignore: -------------------------------------------------------------------------------- 1 | # Flutter-related 2 | **/Flutter/ephemeral/ 3 | **/Pods/ 4 | 5 | # Xcode-related 6 | **/dgph 7 | **/xcuserdata/ 8 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Flutter/Flutter-Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Flutter/Flutter-Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Flutter/GeneratedPluginRegistrant.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | import FlutterMacOS 6 | import Foundation 7 | 8 | import path_provider_foundation 9 | import serious_python_darwin 10 | 11 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { 12 | PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) 13 | SeriousPythonPlugin.register(with: registry.registrar(forPlugin: "SeriousPythonPlugin")) 14 | } 15 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - FlutterMacOS (1.0.0) 3 | - path_provider_foundation (0.0.1): 4 | - Flutter 5 | - FlutterMacOS 6 | - serious_python_darwin (0.9.0): 7 | - Flutter 8 | - FlutterMacOS 9 | 10 | DEPENDENCIES: 11 | - FlutterMacOS (from `Flutter/ephemeral`) 12 | - path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin`) 13 | - serious_python_darwin (from `Flutter/ephemeral/.symlinks/plugins/serious_python_darwin/darwin`) 14 | 15 | EXTERNAL SOURCES: 16 | FlutterMacOS: 17 | :path: Flutter/ephemeral 18 | path_provider_foundation: 19 | :path: Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin 20 | serious_python_darwin: 21 | :path: Flutter/ephemeral/.symlinks/plugins/serious_python_darwin/darwin 22 | 23 | SPEC CHECKSUMS: 24 | FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24 25 | path_provider_foundation: 080d55be775b7414fd5a5ef3ac137b97b097e564 26 | serious_python_darwin: 42f1e341ed20ad30072bf0fa15cc9406ffe0d631 27 | 28 | PODFILE CHECKSUM: 9ebaf0ce3d369aaa26a9ea0e159195ed94724cf3 29 | 30 | COCOAPODS: 1.14.3 31 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import Cocoa 2 | import FlutterMacOS 3 | 4 | @main 5 | class AppDelegate: FlutterAppDelegate { 6 | override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool { 7 | return true 8 | } 9 | 10 | override func applicationSupportsSecureRestorableState(_ app: NSApplication) -> Bool { 11 | return true 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 = run_example 9 | 10 | // The application's bundle identifier 11 | PRODUCT_BUNDLE_IDENTIFIER = com.example.runExample 12 | 13 | // The copyright displayed in application information 14 | PRODUCT_COPYRIGHT = Copyright © 2023 com.example. All rights reserved. 15 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Configs/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Debug.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Configs/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Release.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/MainFlutterWindow.swift: -------------------------------------------------------------------------------- 1 | import Cocoa 2 | import FlutterMacOS 3 | 4 | class MainFlutterWindow: NSWindow { 5 | override func awakeFromNib() { 6 | let flutterViewController = FlutterViewController() 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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/Runner/Release.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/macos/RunnerTests/RunnerTests.swift: -------------------------------------------------------------------------------- 1 | import FlutterMacOS 2 | import Cocoa 3 | import XCTest 4 | 5 | class RunnerTests: XCTestCase { 6 | 7 | func testExample() { 8 | // If you add code to the Runner application, consider adding tests here. 9 | // See https://developer.apple.com/documentation/xctest for more information about using XCTest. 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 in the flutter_test package. 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:run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/test_driver/integration_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:integration_test/integration_test_driver.dart'; 2 | 3 | Future main() => integrationDriver(); 4 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | #include 10 | 11 | void RegisterPlugins(flutter::PluginRegistry* registry) { 12 | SeriousPythonWindowsPluginCApiRegisterWithRegistrar( 13 | registry->GetRegistrarForPlugin("SeriousPythonWindowsPluginCApi")); 14 | } 15 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/windows/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | serious_python_windows 7 | ) 8 | 9 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 10 | ) 11 | 12 | set(PLUGIN_BUNDLED_LIBRARIES) 13 | 14 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 15 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin}) 16 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 17 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 18 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 19 | endforeach(plugin) 20 | 21 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 22 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin}) 23 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 24 | endforeach(ffi_plugin) 25 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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.Create(L"run_example", 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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/windows/runner/resources/app_icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/flet-dev/serious-python/adf895d0c834d895d5cf320028706c11d45275b1/src/serious_python/example/run_example/windows/runner/resources/app_icon.ico -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python/example/run_example/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 | -------------------------------------------------------------------------------- /src/serious_python_android/README.md: -------------------------------------------------------------------------------- 1 | # serious_python_android 2 | 3 | The Android implementation of `serious_python`. 4 | 5 | ## Usage 6 | 7 | This package is [endorsed][endorsed_link], which means you can simply use `serious_python` 8 | normally. This package will be automatically included in your app when you do. 9 | 10 | [endorsed_link]: https://flutter.dev/docs/development/packages-and-plugins/developing-packages#endorsed-federated-plugin -------------------------------------------------------------------------------- /src/serious_python_android/analysis_options.yaml: -------------------------------------------------------------------------------- 1 | include: package:flutter_lints/flutter.yaml 2 | 3 | # Additional information about this file can be found at 4 | # https://dart.dev/guides/language/analysis-options -------------------------------------------------------------------------------- /src/serious_python_android/android/.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | .cxx 10 | /src/main/jniLibs 11 | -------------------------------------------------------------------------------- /src/serious_python_android/android/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = 'serious_python_android' 2 | -------------------------------------------------------------------------------- /src/serious_python_android/android/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | -------------------------------------------------------------------------------- /src/serious_python_android/android/src/main/java/com/flet/serious_python_android/PythonActivity.java: -------------------------------------------------------------------------------- 1 | package com.flet.serious_python_android; 2 | 3 | import android.app.Activity; 4 | 5 | public class PythonActivity { 6 | public static Activity mActivity = null; 7 | } 8 | -------------------------------------------------------------------------------- /src/serious_python_android/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: serious_python_android 2 | description: Android implementation of the serious_python plugin 3 | homepage: https://flet.dev 4 | repository: https://github.com/flet-dev/serious-python 5 | version: 0.9.2 6 | 7 | environment: 8 | sdk: ">=3.0.0 <4.0.0" 9 | flutter: ">=3.7.0" 10 | 11 | dependencies: 12 | flutter: 13 | sdk: flutter 14 | plugin_platform_interface: ^2.1.8 15 | serious_python_platform_interface: 16 | path: ../serious_python_platform_interface 17 | path: ^1.9.0 18 | ffi: ^2.1.2 19 | 20 | dev_dependencies: 21 | flutter_test: 22 | sdk: flutter 23 | flutter_lints: ^2.0.0 24 | ffigen: ^9.0.0 25 | 26 | flutter: 27 | plugin: 28 | implements: serious_python 29 | platforms: 30 | android: 31 | package: com.flet.serious_python_android 32 | pluginClass: AndroidPlugin 33 | dartPluginClass: SeriousPythonAndroid 34 | ffiPlugin: true -------------------------------------------------------------------------------- /src/serious_python_android/python_ffigen.yaml: -------------------------------------------------------------------------------- 1 | # Run with `dart run ffigen --config python_ffigen.yaml`. 2 | 3 | output: "lib/src/gen.dart" 4 | # enums: 5 | # rename: 6 | # "_(.*)": "$1" 7 | # member-rename: 8 | # "_(.*)": 9 | # "_(.*)": "$1" 10 | globals: 11 | rename: 12 | "^class (\\w+) extends ffi.Struct": "final class $1 extends ffi.Struct" 13 | "^class (\\w+) extends ffi.Opaque": "final class $1 extends ffi.Opaque" 14 | "^class (\\w+) extends ffi.Union": "final class $1 extends ffi.Union" 15 | headers: 16 | entry-points: 17 | - "/Users/feodor/projects/flet-dev/python-mobile/install/android/arm64-v8a/python-3.12/include/python3.12/Python.h" 18 | include-directives: 19 | - "/Users/feodor/projects/flet-dev/python-mobile/install/android/arm64-v8a/python-3.12/include/python3.12/*" 20 | - "/Users/feodor/projects/flet-dev/python-mobile/install/android/arm64-v8a/python-3.12/include/python3.12/internal/*" 21 | - "/Users/feodor/projects/flet-dev/python-mobile/install/android/arm64-v8a/python-3.12/include/python3.12/cpython/*" 22 | name: "CPython" 23 | llvm-path: 24 | - /opt/homebrew/opt/llvm 25 | #compiler-opts: "-I/usr/local/opt/llvm/lib/clang/10.0.0/include/ -I/usr/local/Frameworks/Python.framework/Versions/3.8/include/python3.8/" 26 | description: "Bindings to Python C interface\nignore_for_file: unused_field, unused_element\n" 27 | #array-workaround: true -------------------------------------------------------------------------------- /src/serious_python_android/src/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # The Flutter tooling requires that developers have CMake 3.10 or later 2 | # installed. You should not increase this version, as doing so will cause 3 | # the plugin to fail to compile for some customers of the plugin. 4 | cmake_minimum_required(VERSION 3.10) 5 | 6 | project(serious_python_library VERSION 0.0.1 LANGUAGES C) 7 | 8 | add_library(serious_python SHARED 9 | "serious_python.c" 10 | ) 11 | 12 | set_target_properties(serious_python PROPERTIES 13 | PUBLIC_HEADER serious_python.h 14 | OUTPUT_NAME "serious_python" 15 | ) 16 | 17 | target_compile_definitions(serious_python PUBLIC DART_SHARED_LIB) 18 | -------------------------------------------------------------------------------- /src/serious_python_android/src/serious_python.c: -------------------------------------------------------------------------------- 1 | #include "serious_python.h" 2 | 3 | // A very short-lived native function. 4 | // 5 | // For very short-lived functions, it is fine to call them on the main isolate. 6 | // They will block the Dart execution while running the native function, so 7 | // only do this for native functions which are guaranteed to be short-lived. 8 | FFI_PLUGIN_EXPORT intptr_t sum(intptr_t a, intptr_t b) { return a + b; } 9 | 10 | // A longer-lived native function, which occupies the thread calling it. 11 | // 12 | // Do not call these kind of native functions in the main isolate. They will 13 | // block Dart execution. This will cause dropped frames in Flutter applications. 14 | // Instead, call these native functions on a separate isolate. 15 | FFI_PLUGIN_EXPORT intptr_t sum_long_running(intptr_t a, intptr_t b) { 16 | // Simulate work. 17 | #if _WIN32 18 | Sleep(5000); 19 | #else 20 | usleep(5000 * 1000); 21 | #endif 22 | return a + b; 23 | } 24 | -------------------------------------------------------------------------------- /src/serious_python_android/src/serious_python.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | #if _WIN32 6 | #include 7 | #else 8 | #include 9 | #include 10 | #endif 11 | 12 | #if _WIN32 13 | #define FFI_PLUGIN_EXPORT __declspec(dllexport) 14 | #else 15 | #define FFI_PLUGIN_EXPORT 16 | #endif 17 | 18 | // A very short-lived native function. 19 | // 20 | // For very short-lived functions, it is fine to call them on the main isolate. 21 | // They will block the Dart execution while running the native function, so 22 | // only do this for native functions which are guaranteed to be short-lived. 23 | FFI_PLUGIN_EXPORT intptr_t sum(intptr_t a, intptr_t b); 24 | 25 | // A longer lived native function, which occupies the thread calling it. 26 | // 27 | // Do not call these kind of native functions in the main isolate. They will 28 | // block Dart execution. This will cause dropped frames in Flutter applications. 29 | // Instead, call these native functions on a separate isolate. 30 | FFI_PLUGIN_EXPORT intptr_t sum_long_running(intptr_t a, intptr_t b); 31 | -------------------------------------------------------------------------------- /src/serious_python_darwin/.gitignore: -------------------------------------------------------------------------------- 1 | dist/ 2 | dist_ios/ 3 | dist_macos/ -------------------------------------------------------------------------------- /src/serious_python_darwin/README.md: -------------------------------------------------------------------------------- 1 | # serious_python_ios 2 | 3 | The iOS implementation of `serious_python`. 4 | 5 | ## Usage 6 | 7 | This package is [endorsed][endorsed_link], which means you can simply use `serious_python` 8 | normally. This package will be automatically included in your app when you do. 9 | 10 | [endorsed_link]: https://flutter.dev/docs/development/packages-and-plugins/developing-packages#endorsed-federated-plugin -------------------------------------------------------------------------------- /src/serious_python_darwin/analysis_options.yaml: -------------------------------------------------------------------------------- 1 | include: package:flutter_lints/flutter.yaml 2 | 3 | # Additional information about this file can be found at 4 | # https://dart.dev/guides/language/analysis-options -------------------------------------------------------------------------------- /src/serious_python_darwin/darwin/.gitignore: -------------------------------------------------------------------------------- 1 | .idea/ 2 | .vagrant/ 3 | .sconsign.dblite 4 | .svn/ 5 | 6 | .DS_Store 7 | *.swp 8 | profile 9 | 10 | DerivedData/ 11 | build/ 12 | GeneratedPluginRegistrant.h 13 | GeneratedPluginRegistrant.m 14 | 15 | .generated/ 16 | 17 | *.pbxuser 18 | *.mode1v3 19 | *.mode2v3 20 | *.perspectivev3 21 | 22 | !default.pbxuser 23 | !default.mode1v3 24 | !default.mode2v3 25 | !default.perspectivev3 26 | 27 | xcuserdata 28 | 29 | *.moved-aside 30 | 31 | *.pyc 32 | *sync/ 33 | Icon? 34 | .tags* 35 | 36 | /Flutter/Generated.xcconfig 37 | /Flutter/ephemeral/ 38 | /Flutter/flutter_export_environment.sh -------------------------------------------------------------------------------- /src/serious_python_darwin/darwin/bundle-python-frameworks-ios.sh: -------------------------------------------------------------------------------- 1 | echo "Bundle Python xcframeworks" 2 | 3 | # modify Flutter packaging script to include user frameworks 4 | if [ -n "$PODS_TARGET_SRCROOT" ]; then 5 | echo "modify Flutter packaging script to include user frameworks: $PODS_TARGET_SRCROOT" 6 | pods_runner_frameworks_script="$PODS_ROOT/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh" 7 | 8 | if ! grep -q "added by serious_python_darwin plugin" "$pods_runner_frameworks_script"; then 9 | echo "" >> $pods_runner_frameworks_script 10 | echo "PYTHON_XCFRAMEWORKS_ROOT=\x22$PODS_TARGET_SRCROOT/dist_ios/site-xcframeworks\x22" >> $pods_runner_frameworks_script 11 | cat $PODS_TARGET_SRCROOT/pods-runner-frameworks-addon.sh >> $pods_runner_frameworks_script 12 | fi 13 | fi -------------------------------------------------------------------------------- /src/serious_python_darwin/darwin/pods-runner-frameworks-addon.sh: -------------------------------------------------------------------------------- 1 | # -- added by serious_python_darwin plugin -- 2 | # This file is appended to $PODS_ROOT/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh 3 | 4 | # PYTHON_XCFRAMEWORKS_ROOT="{path}" 5 | # PLATFORM_NAME="iphonesimulator" 6 | 7 | # delete old frameworks 8 | find "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" -maxdepth 2 -type f -name "*.origin" | while read -r origin_file; do 9 | framework_dir=$(dirname "$origin_file") 10 | echo "Deleting framework: $framework_dir" 11 | rm -rf "$framework_dir" 12 | done 13 | 14 | # install new frameworks 15 | find $PYTHON_XCFRAMEWORKS_ROOT -name "*.xcframework" | while read full_framework_path; do 16 | framework_relative_path=${full_framework_path#$PYTHON_XCFRAMEWORKS_ROOT/} 17 | framework_name=$(basename $framework_relative_path ".xcframework") 18 | if [[ "$PLATFORM_NAME" == *"simulator" ]]; then 19 | slice="ios-arm64_x86_64-simulator" 20 | else 21 | slice="ios-arm64" 22 | fi 23 | echo "install_framework $full_framework_path/$slice/$framework_name.framework" 24 | install_framework "$full_framework_path/$slice/$framework_name.framework" 25 | done -------------------------------------------------------------------------------- /src/serious_python_darwin/darwin/prepare_ios.sh: -------------------------------------------------------------------------------- 1 | python_version=${1:?} 2 | 3 | script_dir=$(cd "$(dirname "$0")" && pwd -P) 4 | dist=$script_dir/dist_ios 5 | 6 | if [ ! -d "$dist" ]; then 7 | mkdir -p $dist 8 | 9 | python_ios_dist_file="python-ios-dart-$python_version.tar.gz" 10 | python_ios_dist_url="https://github.com/flet-dev/python-build/releases/download/v$python_version/$python_ios_dist_file" 11 | 12 | # download iOS dist 13 | curl -LO $python_ios_dist_url 14 | tar -xzf $python_ios_dist_file -C $dist 15 | mv $dist/python-stdlib $dist/stdlib 16 | rm $python_ios_dist_file 17 | fi -------------------------------------------------------------------------------- /src/serious_python_darwin/darwin/prepare_macos.sh: -------------------------------------------------------------------------------- 1 | python_version=${1:?} 2 | 3 | script_dir=$(cd "$(dirname "$0")" && pwd -P) 4 | dist=$script_dir/dist_macos 5 | 6 | if [ ! -d "$dist" ]; then 7 | mkdir -p $dist 8 | 9 | python_macos_dist_file="python-macos-dart-$python_version.tar.gz" 10 | python_macos_dist_url="https://github.com/flet-dev/python-build/releases/download/v$python_version/$python_macos_dist_file" 11 | 12 | # download macos dist 13 | curl -LO $python_macos_dist_url 14 | tar -xzf $python_macos_dist_file -C $dist 15 | mv $dist/python-stdlib $dist/stdlib 16 | rm $python_macos_dist_file 17 | fi -------------------------------------------------------------------------------- /src/serious_python_darwin/darwin/symlink_pod.sh: -------------------------------------------------------------------------------- 1 | script_dir=$(cd "$(dirname "$0")" && pwd -P) 2 | 3 | # create a symlink to this Pod 4 | if [[ -n "$SERIOUS_PYTHON_SITE_PACKAGES" && -d "$SERIOUS_PYTHON_SITE_PACKAGES" ]]; then 5 | echo "Creating .pod symlink in SERIOUS_PYTHON_SITE_PACKAGES: $SERIOUS_PYTHON_SITE_PACKAGES" 6 | rm -f $script_dir $SERIOUS_PYTHON_SITE_PACKAGES/.pod 7 | ln -s $script_dir $SERIOUS_PYTHON_SITE_PACKAGES/.pod 8 | else 9 | echo ".pod symlink was not created because SERIOUS_PYTHON_SITE_PACKAGES is not set or directory does not exist." 10 | fi -------------------------------------------------------------------------------- /src/serious_python_darwin/lib/serious_python_darwin.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/foundation.dart'; 2 | import 'package:flutter/services.dart'; 3 | import 'package:serious_python_platform_interface/serious_python_platform_interface.dart'; 4 | 5 | /// An implementation of [SeriousPythonPlatform] that uses method channels. 6 | class SeriousPythonDarwin extends SeriousPythonPlatform { 7 | /// The method channel used to interact with the native platform. 8 | @visibleForTesting 9 | final methodChannel = const MethodChannel('serious_python'); 10 | 11 | /// Registers this class as the default instance of [SeriousPythonPlatform] 12 | static void registerWith() { 13 | SeriousPythonPlatform.instance = SeriousPythonDarwin(); 14 | } 15 | 16 | @override 17 | Future getPlatformVersion() async { 18 | final version = 19 | await methodChannel.invokeMethod('getPlatformVersion'); 20 | return version; 21 | } 22 | 23 | @override 24 | Future run(String appPath, 25 | {String? script, 26 | List? modulePaths, 27 | Map? environmentVariables, 28 | bool? sync}) async { 29 | final Map arguments = { 30 | 'appPath': appPath, 31 | 'script': script, 32 | 'modulePaths': modulePaths, 33 | 'environmentVariables': environmentVariables, 34 | 'sync': sync 35 | }; 36 | return await methodChannel.invokeMethod('runPython', arguments); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /src/serious_python_darwin/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: serious_python_darwin 2 | description: iOS and macOS implementations of the serious_python plugin 3 | homepage: https://flet.dev 4 | repository: https://github.com/flet-dev/serious-python 5 | version: 0.9.2 6 | 7 | environment: 8 | sdk: ">=3.0.0 <4.0.0" 9 | flutter: ">=3.7.0" 10 | 11 | dependencies: 12 | flutter: 13 | sdk: flutter 14 | plugin_platform_interface: ^2.1.8 15 | serious_python_platform_interface: 16 | path: ../serious_python_platform_interface 17 | path: ^1.9.0 18 | 19 | dev_dependencies: 20 | flutter_test: 21 | sdk: flutter 22 | flutter_lints: ^2.0.0 23 | 24 | flutter: 25 | plugin: 26 | implements: serious_python 27 | platforms: 28 | ios: 29 | pluginClass: SeriousPythonPlugin 30 | dartPluginClass: SeriousPythonDarwin 31 | ffiPlugin: true 32 | sharedDarwinSource: true 33 | macos: 34 | pluginClass: SeriousPythonPlugin 35 | dartPluginClass: SeriousPythonDarwin 36 | ffiPlugin: true 37 | sharedDarwinSource: true -------------------------------------------------------------------------------- /src/serious_python_linux/.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: "ead455963c12b453cdb2358cad34969c76daf180" 8 | channel: "stable" 9 | 10 | project_type: plugin 11 | 12 | # Tracks metadata for the flutter migrate command 13 | migration: 14 | platforms: 15 | - platform: root 16 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 17 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 18 | - platform: linux 19 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 20 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 21 | - platform: windows 22 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 23 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 24 | 25 | # User provided section 26 | 27 | # List of Local paths (relative to this file) that should be 28 | # ignored by the migrate tool. 29 | # 30 | # Files that are not part of the templates will be ignored by default. 31 | unmanaged_files: 32 | - 'lib/main.dart' 33 | - 'ios/Runner.xcodeproj/project.pbxproj' 34 | -------------------------------------------------------------------------------- /src/serious_python_linux/README.md: -------------------------------------------------------------------------------- 1 | # serious_python_ios 2 | 3 | The Windows implementation of `serious_python`. 4 | 5 | ## Usage 6 | 7 | This package is [endorsed][endorsed_link], which means you can simply use `serious_python` 8 | normally. This package will be automatically included in your app when you do. 9 | 10 | [endorsed_link]: https://flutter.dev/docs/development/packages-and-plugins/developing-packages#endorsed-federated-plugin -------------------------------------------------------------------------------- /src/serious_python_linux/analysis_options.yaml: -------------------------------------------------------------------------------- 1 | include: package:flutter_lints/flutter.yaml 2 | 3 | # Additional information about this file can be found at 4 | # https://dart.dev/guides/language/analysis-options 5 | -------------------------------------------------------------------------------- /src/serious_python_linux/linux/include/serious_python_linux/serious_python_linux_plugin.h: -------------------------------------------------------------------------------- 1 | #ifndef FLUTTER_PLUGIN_SERIOUS_PYTHON_LINUX_PLUGIN_H_ 2 | #define FLUTTER_PLUGIN_SERIOUS_PYTHON_LINUX_PLUGIN_H_ 3 | 4 | #include 5 | 6 | G_BEGIN_DECLS 7 | 8 | #ifdef FLUTTER_PLUGIN_IMPL 9 | #define FLUTTER_PLUGIN_EXPORT __attribute__((visibility("default"))) 10 | #else 11 | #define FLUTTER_PLUGIN_EXPORT 12 | #endif 13 | 14 | typedef struct _SeriousPythonLinuxPlugin SeriousPythonLinuxPlugin; 15 | typedef struct { 16 | GObjectClass parent_class; 17 | } SeriousPythonLinuxPluginClass; 18 | 19 | FLUTTER_PLUGIN_EXPORT GType serious_python_linux_plugin_get_type(); 20 | 21 | FLUTTER_PLUGIN_EXPORT void serious_python_linux_plugin_register_with_registrar( 22 | FlPluginRegistrar* registrar); 23 | 24 | G_END_DECLS 25 | 26 | #endif // FLUTTER_PLUGIN_SERIOUS_PYTHON_LINUX_PLUGIN_H_ 27 | -------------------------------------------------------------------------------- /src/serious_python_linux/linux/serious_python_linux_plugin_private.h: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #include "include/serious_python_linux/serious_python_linux_plugin.h" 4 | 5 | // This file exposes some plugin internals for unit testing. See 6 | // https://github.com/flutter/flutter/issues/88724 for current limitations 7 | // in the unit-testable API. 8 | 9 | // Handles the getPlatformVersion method call. 10 | FlMethodResponse *get_platform_version(); 11 | 12 | void run_python_program(gchar *appPath); 13 | gpointer run_python_program_async(gpointer data); 14 | 15 | void run_python_script(gchar *script); 16 | gpointer run_python_script_async(gpointer data); -------------------------------------------------------------------------------- /src/serious_python_linux/linux/test/serious_python_linux_plugin_test.cc: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | #include "include/serious_python_linux/serious_python_linux_plugin.h" 6 | #include "serious_python_linux_plugin_private.h" 7 | 8 | // This demonstrates a simple unit test of the C portion of this plugin's 9 | // implementation. 10 | // 11 | // Once you have built the plugin's example app, you can run these tests 12 | // from the command line. For instance, for a plugin called my_plugin 13 | // built for x64 debug, run: 14 | // $ build/linux/x64/debug/plugins/my_plugin/my_plugin_test 15 | 16 | namespace serious_python_linux { 17 | namespace test { 18 | 19 | TEST(SeriousPythonLinuxPlugin, GetPlatformVersion) { 20 | g_autoptr(FlMethodResponse) response = get_platform_version(); 21 | ASSERT_NE(response, nullptr); 22 | ASSERT_TRUE(FL_IS_METHOD_SUCCESS_RESPONSE(response)); 23 | FlValue* result = fl_method_success_response_get_result( 24 | FL_METHOD_SUCCESS_RESPONSE(response)); 25 | ASSERT_EQ(fl_value_get_type(result), FL_VALUE_TYPE_STRING); 26 | // The full string varies, so just validate that it has the right format. 27 | EXPECT_THAT(fl_value_get_string(result), testing::StartsWith("Linux ")); 28 | } 29 | 30 | } // namespace test 31 | } // namespace serious_python_linux 32 | -------------------------------------------------------------------------------- /src/serious_python_linux/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: serious_python_linux 2 | description: Linux implementations of the serious_python plugin 3 | homepage: https://flet.dev 4 | repository: https://github.com/flet-dev/serious-python 5 | version: 0.9.2 6 | 7 | environment: 8 | sdk: '>=3.1.3 <4.0.0' 9 | flutter: '>=3.3.0' 10 | 11 | dependencies: 12 | flutter: 13 | sdk: flutter 14 | plugin_platform_interface: ^2.1.8 15 | serious_python_platform_interface: 16 | path: ../serious_python_platform_interface 17 | 18 | dev_dependencies: 19 | flutter_test: 20 | sdk: flutter 21 | flutter_lints: ^2.0.0 22 | 23 | flutter: 24 | plugin: 25 | implements: serious_python 26 | platforms: 27 | linux: 28 | pluginClass: SeriousPythonLinuxPlugin 29 | dartPluginClass: SeriousPythonLinux 30 | ffiPlugin: true -------------------------------------------------------------------------------- /src/serious_python_platform_interface/README.md: -------------------------------------------------------------------------------- 1 | # serious_python_platform_interface 2 | 3 | A common platform interface for the `serious_python` plugin. 4 | 5 | This interface allows platform-specific implementations of the `serious_python` plugin, as well as the plugin itself, to ensure they are supporting the same interface. 6 | 7 | # Usage 8 | 9 | To implement a new platform-specific implementation of `serious_python`, extend `SeriousPythonPlatform` with an implementation that performs the platform-specific behavior. -------------------------------------------------------------------------------- /src/serious_python_platform_interface/analysis_options.yaml: -------------------------------------------------------------------------------- 1 | include: package:flutter_lints/flutter.yaml 2 | 3 | # Additional information about this file can be found at 4 | # https://dart.dev/guides/language/analysis-options 5 | 6 | analyzer: 7 | exclude: [lib/src/gen.dart] -------------------------------------------------------------------------------- /src/serious_python_platform_interface/lib/src/method_channel_serious_python.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/foundation.dart' show visibleForTesting; 2 | import 'package:flutter/services.dart'; 3 | 4 | import '../serious_python_platform_interface.dart'; 5 | 6 | /// An implementation of [SeriousPythonPlatform] that uses method channels. 7 | class MethodChannelSeriousPython extends SeriousPythonPlatform { 8 | /// The method channel used to interact with the native platform. 9 | @visibleForTesting 10 | final methodChannel = const MethodChannel('serious_python'); 11 | 12 | @override 13 | Future getPlatformVersion() { 14 | return methodChannel.invokeMethod('getPlatformVersion'); 15 | } 16 | 17 | @override 18 | Future run(String appPath, 19 | {String? script, 20 | List? modulePaths, 21 | Map? environmentVariables, 22 | bool? sync}) async { 23 | final Map arguments = { 24 | 'appPath': appPath, 25 | 'script': script, 26 | 'modulePaths': modulePaths, 27 | 'environmentVariables': environmentVariables, 28 | 'sync': sync 29 | }; 30 | return await methodChannel.invokeMethod('runPython', arguments); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/serious_python_platform_interface/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: serious_python_platform_interface 2 | description: A common platform interface for the serious_python plugin. 3 | homepage: https://flet.dev 4 | repository: https://github.com/flet-dev/serious-python 5 | version: 0.9.2 6 | 7 | environment: 8 | sdk: ">=3.0.0 <4.0.0" 9 | flutter: ">=3.7.0" 10 | 11 | dependencies: 12 | flutter: 13 | sdk: flutter 14 | plugin_platform_interface: ^2.1.8 15 | path_provider: ^2.1.3 16 | archive: ^3.6.1 17 | path: ^1.9.0 18 | 19 | dev_dependencies: 20 | flutter_test: 21 | sdk: flutter 22 | flutter_lints: ^2.0.0 23 | -------------------------------------------------------------------------------- /src/serious_python_platform_interface/python_ffigen.yaml: -------------------------------------------------------------------------------- 1 | # Run with `dart run ffigen --config python_ffigen.yaml`. 2 | 3 | output: "lib/src/gen.dart" 4 | # enums: 5 | # rename: 6 | # "_(.*)": "$1" 7 | # member-rename: 8 | # "_(.*)": 9 | # "_(.*)": "$1" 10 | globals: 11 | rename: 12 | "^class (\\w+) extends ffi.Struct": "final class $1 extends ffi.Struct" 13 | "^class (\\w+) extends ffi.Opaque": "final class $1 extends ffi.Opaque" 14 | "^class (\\w+) extends ffi.Union": "final class $1 extends ffi.Union" 15 | headers: 16 | entry-points: 17 | - "/Users/feodor/Downloads/python/include/python3.11/Python.h" 18 | include-directives: 19 | - "/Users/feodor/Downloads/python/include/python3.11/*" 20 | - "/Users/feodor/Downloads/python/include/python3.11/internal/*" 21 | - "/Users/feodor/Downloads/python/include/python3.11/cpython/*" 22 | name: "CPython" 23 | llvm-path: 24 | - /opt/homebrew/opt/llvm 25 | #compiler-opts: "-I/usr/local/opt/llvm/lib/clang/10.0.0/include/ -I/usr/local/Frameworks/Python.framework/Versions/3.8/include/python3.8/" 26 | description: "Bindings to Python C interface\nignore_for_file: unused_field, unused_element\n" 27 | #array-workaround: true -------------------------------------------------------------------------------- /src/serious_python_windows/.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: "ead455963c12b453cdb2358cad34969c76daf180" 8 | channel: "stable" 9 | 10 | project_type: plugin 11 | 12 | # Tracks metadata for the flutter migrate command 13 | migration: 14 | platforms: 15 | - platform: root 16 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 17 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 18 | - platform: windows 19 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 20 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 21 | 22 | # User provided section 23 | 24 | # List of Local paths (relative to this file) that should be 25 | # ignored by the migrate tool. 26 | # 27 | # Files that are not part of the templates will be ignored by default. 28 | unmanaged_files: 29 | - 'lib/main.dart' 30 | - 'ios/Runner.xcodeproj/project.pbxproj' 31 | -------------------------------------------------------------------------------- /src/serious_python_windows/README.md: -------------------------------------------------------------------------------- 1 | # serious_python_ios 2 | 3 | The Windows implementation of `serious_python`. 4 | 5 | ## Usage 6 | 7 | This package is [endorsed][endorsed_link], which means you can simply use `serious_python` 8 | normally. This package will be automatically included in your app when you do. 9 | 10 | [endorsed_link]: https://flutter.dev/docs/development/packages-and-plugins/developing-packages#endorsed-federated-plugin -------------------------------------------------------------------------------- /src/serious_python_windows/analysis_options.yaml: -------------------------------------------------------------------------------- 1 | include: package:flutter_lints/flutter.yaml 2 | 3 | # Additional information about this file can be found at 4 | # https://dart.dev/guides/language/analysis-options 5 | -------------------------------------------------------------------------------- /src/serious_python_windows/lib/serious_python_windows.dart: -------------------------------------------------------------------------------- 1 | import 'dart:io'; 2 | 3 | import 'package:flutter/foundation.dart'; 4 | import 'package:flutter/services.dart'; 5 | import 'package:serious_python_platform_interface/serious_python_platform_interface.dart'; 6 | 7 | class SeriousPythonWindows extends SeriousPythonPlatform { 8 | /// The method channel used to interact with the native platform. 9 | @visibleForTesting 10 | final methodChannel = const MethodChannel('serious_python_windows'); 11 | 12 | /// Registers this class as the default instance of [SeriousPythonPlatform] 13 | static void registerWith() { 14 | SeriousPythonPlatform.instance = SeriousPythonWindows(); 15 | } 16 | 17 | @override 18 | Future getPlatformVersion() async { 19 | final version = 20 | await methodChannel.invokeMethod('getPlatformVersion'); 21 | return "$version ${Platform.resolvedExecutable}"; 22 | } 23 | 24 | @override 25 | Future run(String appPath, 26 | {String? script, 27 | List? modulePaths, 28 | Map? environmentVariables, 29 | bool? sync}) async { 30 | final Map arguments = { 31 | 'exePath': Platform.resolvedExecutable, 32 | 'appPath': appPath, 33 | 'script': script, 34 | 'modulePaths': modulePaths, 35 | 'environmentVariables': environmentVariables, 36 | 'sync': sync 37 | }; 38 | return await methodChannel.invokeMethod('runPython', arguments); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /src/serious_python_windows/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: serious_python_windows 2 | description: Windows implementations of the serious_python plugin 3 | homepage: https://flet.dev 4 | repository: https://github.com/flet-dev/serious-python 5 | version: 0.9.2 6 | 7 | environment: 8 | sdk: '>=3.1.3 <4.0.0' 9 | flutter: '>=3.3.0' 10 | 11 | dependencies: 12 | flutter: 13 | sdk: flutter 14 | plugin_platform_interface: ^2.1.8 15 | serious_python_platform_interface: 16 | path: ../serious_python_platform_interface 17 | 18 | dev_dependencies: 19 | flutter_test: 20 | sdk: flutter 21 | flutter_lints: ^2.0.0 22 | 23 | flutter: 24 | plugin: 25 | implements: serious_python 26 | platforms: 27 | windows: 28 | pluginClass: SeriousPythonWindowsPluginCApi 29 | dartPluginClass: SeriousPythonWindows 30 | ffiPlugin: true -------------------------------------------------------------------------------- /src/serious_python_windows/windows/.gitignore: -------------------------------------------------------------------------------- 1 | flutter/ 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 | -------------------------------------------------------------------------------- /src/serious_python_windows/windows/include/serious_python_windows/serious_python_windows_plugin_c_api.h: -------------------------------------------------------------------------------- 1 | #ifndef FLUTTER_PLUGIN_SERIOUS_PYTHON_WINDOWS_PLUGIN_C_API_H_ 2 | #define FLUTTER_PLUGIN_SERIOUS_PYTHON_WINDOWS_PLUGIN_C_API_H_ 3 | 4 | #include 5 | 6 | #ifdef FLUTTER_PLUGIN_IMPL 7 | #define FLUTTER_PLUGIN_EXPORT __declspec(dllexport) 8 | #else 9 | #define FLUTTER_PLUGIN_EXPORT __declspec(dllimport) 10 | #endif 11 | 12 | #if defined(__cplusplus) 13 | extern "C" { 14 | #endif 15 | 16 | FLUTTER_PLUGIN_EXPORT void SeriousPythonWindowsPluginCApiRegisterWithRegistrar( 17 | FlutterDesktopPluginRegistrarRef registrar); 18 | 19 | #if defined(__cplusplus) 20 | } // extern "C" 21 | #endif 22 | 23 | #endif // FLUTTER_PLUGIN_SERIOUS_PYTHON_WINDOWS_PLUGIN_C_API_H_ 24 | -------------------------------------------------------------------------------- /src/serious_python_windows/windows/serious_python_windows_plugin.h: -------------------------------------------------------------------------------- 1 | #ifndef FLUTTER_PLUGIN_SERIOUS_PYTHON_WINDOWS_PLUGIN_H_ 2 | #define FLUTTER_PLUGIN_SERIOUS_PYTHON_WINDOWS_PLUGIN_H_ 3 | 4 | #include 5 | #include 6 | 7 | #include 8 | 9 | namespace serious_python_windows 10 | { 11 | 12 | class SeriousPythonWindowsPlugin : public flutter::Plugin 13 | { 14 | public: 15 | static void RegisterWithRegistrar(flutter::PluginRegistrarWindows *registrar); 16 | 17 | SeriousPythonWindowsPlugin(); 18 | 19 | virtual ~SeriousPythonWindowsPlugin(); 20 | 21 | // Disallow copy and assign. 22 | SeriousPythonWindowsPlugin(const SeriousPythonWindowsPlugin &) = delete; 23 | SeriousPythonWindowsPlugin &operator=(const SeriousPythonWindowsPlugin &) = delete; 24 | 25 | // Called when a method is called on this plugin's channel from Dart. 26 | void HandleMethodCall( 27 | const flutter::MethodCall &method_call, 28 | std::unique_ptr> result); 29 | 30 | void RunPythonProgram(std::string appPath); 31 | void RunPythonProgramAsync(std::string appPath); 32 | 33 | void RunPythonScript(std::string script); 34 | void RunPythonScriptAsync(std::string script); 35 | }; 36 | 37 | } // namespace serious_python_windows 38 | 39 | #endif // FLUTTER_PLUGIN_SERIOUS_PYTHON_WINDOWS_PLUGIN_H_ 40 | -------------------------------------------------------------------------------- /src/serious_python_windows/windows/serious_python_windows_plugin_c_api.cpp: -------------------------------------------------------------------------------- 1 | #include "include/serious_python_windows/serious_python_windows_plugin_c_api.h" 2 | 3 | #include 4 | 5 | #include "serious_python_windows_plugin.h" 6 | 7 | void SeriousPythonWindowsPluginCApiRegisterWithRegistrar( 8 | FlutterDesktopPluginRegistrarRef registrar) { 9 | serious_python_windows::SeriousPythonWindowsPlugin::RegisterWithRegistrar( 10 | flutter::PluginRegistrarManager::GetInstance() 11 | ->GetRegistrar(registrar)); 12 | } 13 | -------------------------------------------------------------------------------- /src/serious_python_windows/windows/test/serious_python_windows_plugin_test.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | #include 6 | 7 | #include 8 | #include 9 | #include 10 | 11 | #include "serious_python_windows_plugin.h" 12 | 13 | namespace serious_python_windows { 14 | namespace test { 15 | 16 | namespace { 17 | 18 | using flutter::EncodableMap; 19 | using flutter::EncodableValue; 20 | using flutter::MethodCall; 21 | using flutter::MethodResultFunctions; 22 | 23 | } // namespace 24 | 25 | TEST(SeriousPythonWindowsPlugin, GetPlatformVersion) { 26 | SeriousPythonWindowsPlugin plugin; 27 | // Save the reply value from the success callback. 28 | std::string result_string; 29 | plugin.HandleMethodCall( 30 | MethodCall("getPlatformVersion", std::make_unique()), 31 | std::make_unique>( 32 | [&result_string](const EncodableValue* result) { 33 | result_string = std::get(*result); 34 | }, 35 | nullptr, nullptr)); 36 | 37 | // Since the exact string varies by host, just ensure that it's a string 38 | // with the expected format. 39 | EXPECT_TRUE(result_string.rfind("Windows ", 0) == 0); 40 | } 41 | 42 | } // namespace test 43 | } // namespace serious_python_windows 44 | --------------------------------------------------------------------------------