├── .github ├── FUNDING.yml ├── ISSUE_TEMPLATE │ ├── bug_report.md │ └── feature_request.md └── workflows │ ├── build.yaml │ └── release.yaml ├── .gitignore ├── .gitmodules ├── .metadata ├── .vscode ├── extensions.json └── launch.json ├── CODE_OF_CONDUCT.md ├── LICENSE.md ├── README.md ├── SECURITY.md ├── analysis_options.yaml ├── android ├── .gitignore ├── app │ ├── build.gradle │ └── src │ │ ├── debug │ │ └── AndroidManifest.xml │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── kotlin │ │ │ └── com │ │ │ │ └── example │ │ │ │ └── veil_wallet │ │ │ │ └── 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 ├── assets ├── images │ ├── icons │ │ ├── logo.png │ │ ├── logo_linux.png │ │ ├── logo_macos.png │ │ ├── logo_mobile.png │ │ ├── logo_mobile_noalpha.png │ │ └── logo_mobile_upscaled.png │ ├── logo.png │ ├── logo_64x64.png │ ├── logo_full.png │ ├── logo_full_light.png │ └── pattern.png └── res │ └── legal.txt ├── devtools_options.yaml ├── distribute_options.yaml ├── docs ├── deeplinking.md ├── deeplinking_demo.html ├── fdroid-build.md ├── flutter-notes.md ├── googleplay │ ├── app_icon.png │ ├── veil_promo_1_en.png │ └── veil_promo_1_ru.png └── images │ ├── google-play-badge.png │ ├── google-play-badge_downscale.png │ └── template │ ├── License free.txt │ ├── OT134T0.jpg │ ├── OT134T1.pdn │ ├── OT134T1.png │ └── ghpicture.png ├── flutter_launcher_icons.yaml ├── ios ├── .gitignore ├── Flutter │ ├── AppFrameworkInfo.plist │ ├── Debug.xcconfig │ └── Release.xcconfig ├── Podfile ├── 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-50x50@1x.png │ │ │ ├── Icon-App-50x50@2x.png │ │ │ ├── Icon-App-57x57@1x.png │ │ │ ├── Icon-App-57x57@2x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-72x72@1x.png │ │ │ ├── Icon-App-72x72@2x.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 │ └── Runner.entitlements └── RunnerTests │ └── RunnerTests.swift ├── l10n.yaml ├── lib ├── l10n │ ├── app_en.arb │ ├── app_eo.arb │ ├── app_es.arb │ ├── app_ja.arb │ ├── app_lt.arb │ ├── app_ru.arb │ └── babel.babel ├── main.dart └── src │ ├── components │ ├── addressbook_address.dart │ ├── balance_widget.dart │ ├── coin_control_widget.dart │ ├── transaction.dart │ └── transactions_list_widget.dart │ ├── core │ ├── constants.dart │ ├── core.dart │ ├── func_checker.dart │ ├── locale_entry.dart │ ├── node_entry.dart │ ├── screen.dart │ ├── transactions.dart │ ├── wallet_bg_tasks.dart │ └── wallet_helper.dart │ ├── extensions │ ├── encryption │ │ └── aes_cbc.dart │ ├── file_storage.dart │ └── misc.dart │ ├── helpers │ ├── functions_check.dart │ └── responsive.dart │ ├── layouts │ └── mobile │ │ ├── back_layout.dart │ │ ├── loading_layout.dart │ │ ├── main_layout.dart │ │ └── welcome_layout.dart │ ├── models │ └── address_model.dart │ ├── states │ ├── provider │ │ ├── dialogs_state.dart │ │ └── wallet_state.dart │ ├── states_bridge.dart │ └── static │ │ ├── base_static_state.dart │ │ └── wallet_static_state.dart │ ├── storage │ ├── storage_item.dart │ └── storage_service.dart │ └── views │ ├── about.dart │ ├── address_book.dart │ ├── auth.dart │ ├── home.dart │ ├── import_seed.dart │ ├── legal.dart │ ├── loading.dart │ ├── make_tx.dart │ ├── new_wallet_save_seed.dart │ ├── new_wallet_verify_seed.dart │ ├── node_fail.dart │ ├── receive_coins.dart │ ├── scan_qr.dart │ ├── settings.dart │ ├── setup_biometrics.dart │ ├── wallet_advanced.dart │ ├── wallet_settings.dart │ └── welcome.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 └── packaging │ ├── appimage │ └── make_config.yaml │ ├── deb │ └── make_config.yaml │ └── rpm │ └── make_config.yaml ├── 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 │ └── RunnerRelease.entitlements ├── RunnerTests │ └── RunnerTests.swift └── packaging │ └── dmg │ └── make_config.yaml ├── metadata ├── en-US │ ├── changelogs │ │ ├── 10.txt │ │ ├── 11.txt │ │ ├── 12.txt │ │ ├── 13.txt │ │ ├── 14.txt │ │ ├── 15.txt │ │ ├── 16.txt │ │ ├── 17.txt │ │ ├── 18.txt │ │ ├── 19.txt │ │ ├── 20.txt │ │ ├── 21.txt │ │ ├── 22.txt │ │ ├── 23.txt │ │ ├── 24.txt │ │ ├── 25.txt │ │ ├── 26.txt │ │ ├── 27.txt │ │ ├── 28.txt │ │ ├── 29.txt │ │ └── 9.txt │ ├── full_description.txt │ ├── images │ │ ├── featureGraphic.png │ │ ├── icon.png │ │ └── phoneScreenshots │ │ │ ├── veil_screen_1_en.png │ │ │ ├── veil_screen_2_en.png │ │ │ ├── veil_screen_3_en.png │ │ │ └── veil_screen_4_en.png │ ├── short_description.txt │ └── title.txt └── ru-RU │ ├── changelogs │ ├── 10.txt │ ├── 11.txt │ ├── 12.txt │ ├── 13.txt │ ├── 14.txt │ ├── 15.txt │ ├── 16.txt │ ├── 17.txt │ ├── 18.txt │ ├── 19.txt │ ├── 20.txt │ ├── 21.txt │ ├── 22.txt │ ├── 23.txt │ ├── 24.txt │ ├── 25.txt │ ├── 26.txt │ ├── 27.txt │ ├── 28.txt │ ├── 29.txt │ └── 9.txt │ ├── full_description.txt │ ├── images │ ├── featureGraphic.png │ ├── icon.png │ └── phoneScreenshots │ │ ├── veil_screen_ru_1.jpg │ │ ├── veil_screen_ru_2.jpg │ │ ├── veil_screen_ru_3.jpg │ │ └── veil_screen_ru_4.jpg │ ├── short_description.txt │ └── title.txt ├── pubspec.lock ├── pubspec.yaml ├── test ├── a11y_test.dart └── widget_test.dart ├── veil_wallet.code-workspace ├── 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 ├── packaging └── exe │ └── make_config.yaml └── 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 /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | custom: https://veilproject.org/donations 2 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve 4 | title: '' 5 | labels: bug 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Describe the bug** 11 | A clear and concise description of what the bug is. 12 | 13 | **To Reproduce** 14 | Steps to reproduce the behavior: 15 | 1. Go to '...' 16 | 2. Click on '....' 17 | 3. Scroll down to '....' 18 | 4. See error 19 | 20 | **Expected behavior** 21 | A clear and concise description of what you expected to happen. 22 | 23 | **Screenshots** 24 | If applicable, add screenshots to help explain your problem. 25 | 26 | **Desktop (please complete the following information):** 27 | - OS: [e.g. iOS] 28 | - Version [e.g. 1.0.3] 29 | 30 | **Smartphone (please complete the following information):** 31 | - Device: [e.g. iPhone6] 32 | - OS: [e.g. iOS8.1] 33 | - Version [e.g. 1.0.3] 34 | 35 | **Additional context** 36 | Add any other context about the problem here. 37 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature request 3 | about: Suggest an idea for this project 4 | title: '' 5 | labels: enhancement 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Is your feature request related to a problem? Please describe.** 11 | A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] 12 | 13 | **Describe the solution you'd like** 14 | A clear and concise description of what you want to happen. 15 | 16 | **Describe alternatives you've considered** 17 | A clear and concise description of any alternative solutions or features you've considered. 18 | 19 | **Additional context** 20 | Add any other context or screenshots about the feature request here. 21 | -------------------------------------------------------------------------------- /.github/workflows/release.yaml: -------------------------------------------------------------------------------- 1 | name: Release 2 | 3 | on: 4 | workflow_dispatch: 5 | inputs: 6 | tag: 7 | description: 'Tag name (without "v" prefix, ex. 1.0.0)' 8 | default: '1.0.0' 9 | draft: 10 | description: 'Should new release be a draft?' 11 | type: boolean 12 | required: true 13 | default: true 14 | 15 | jobs: 16 | build: 17 | uses: ./.github/workflows/build.yaml 18 | secrets: inherit 19 | 20 | create_release: 21 | runs-on: ubuntu-latest 22 | needs: build 23 | permissions: 24 | contents: write 25 | steps: 26 | # 1) artifact (veil-wallet win-x86_64) 27 | - uses: actions/download-artifact@v4 28 | with: 29 | name: veil-wallet win-x86_64 30 | path: './veil-wallet win-x86_64' 31 | - uses: actions/download-artifact@v4 32 | with: 33 | name: veil-wallet win-x86_64 setup 34 | path: './' 35 | - run: | 36 | rm -rf 'veil-wallet (win-x86_64).zip' 37 | zip -r 'veil-wallet (win-x86_64).zip' './veil-wallet win-x86_64' 38 | rm -rf './veil-wallet win-x86_64/' 39 | mv './veil-wallet-setup.exe' './veil-wallet.win-x86_64-setup.exe' 40 | # 2) artifact (veil-wallet linux-x86_64) 41 | - uses: actions/download-artifact@v4 42 | with: 43 | name: veil-wallet linux-x86_64 44 | path: './veil-wallet linux-x86_64' 45 | - uses: actions/download-artifact@v4 46 | with: 47 | name: veil-wallet linux-x86_64 appimage 48 | path: './' 49 | - uses: actions/download-artifact@v4 50 | with: 51 | name: veil-wallet linux-x86_64 deb 52 | path: './' 53 | - uses: actions/download-artifact@v4 54 | with: 55 | name: veil-wallet linux-x86_64 rpm 56 | path: './' 57 | - run: | 58 | rm -rf 'veil-wallet (linux-x86_64).zip' 59 | zip -r 'veil-wallet (linux-x86_64).zip' './veil-wallet linux-x86_64' 60 | mv './veil-wallet.appimage' './veil-wallet.linux-x86_64.appimage' 61 | mv './veil-wallet.deb' './veil-wallet.linux-x86_64.deb' 62 | mv './veil-wallet.rpm' './veil-wallet.linux-x86_64.rpm' 63 | # 3) artifact (veil-wallet macos-universal) 64 | - uses: actions/download-artifact@v4 65 | with: 66 | name: veil-wallet macos-universal dmg 67 | path: './' 68 | - run: | 69 | mv './veil-wallet.dmg' './veil-wallet.macos-universal.dmg' 70 | # 4) artifact (veil-wallet ios) 71 | - uses: actions/download-artifact@v4 72 | with: 73 | name: veil-wallet ios 74 | path: './veil-wallet ios' 75 | - run: | 76 | mv './veil-wallet ios/app-release.ipa' './veil-wallet (ios).ipa' 77 | # 5) artifact (veil-wallet android) 78 | - uses: actions/download-artifact@v4 79 | with: 80 | name: veil-wallet android 81 | path: './veil-wallet android' 82 | - run: | 83 | mv './veil-wallet android/app-release.apk' './veil-wallet (android).apk' 84 | # 6) artifact (veil-wallet android armeabi-v7a) 85 | - uses: actions/download-artifact@v4 86 | with: 87 | name: veil-wallet android-armeabi-v7a 88 | path: './veil-wallet android' 89 | - run: | 90 | mv './veil-wallet android/app-armeabi-v7a-release.apk' './veil-wallet (android-armeabi-v7a).apk' 91 | # 7) artifact (veil-wallet android arm64-v8a) 92 | - uses: actions/download-artifact@v4 93 | with: 94 | name: veil-wallet android-arm64-v8a 95 | path: './veil-wallet android' 96 | - run: | 97 | mv './veil-wallet android/app-arm64-v8a-release.apk' './veil-wallet (android-arm64-v8a).apk' 98 | # 8) artifact (veil-wallet android x86_64) 99 | - uses: actions/download-artifact@v4 100 | with: 101 | name: veil-wallet android-x86_64 102 | path: './veil-wallet android' 103 | - run: | 104 | mv './veil-wallet android/app-x86_64-release.apk' './veil-wallet (android-x86_64).apk' 105 | # upload release 106 | - uses: ncipollo/release-action@v1 107 | with: 108 | commit: 'main' 109 | tag: 'v${{ inputs.tag }}' 110 | allowUpdates: true 111 | artifactErrorsFailBuild: true 112 | generateReleaseNotes: true 113 | draft: '${{ inputs.draft }}' 114 | name: 'Veil Wallet ${{ inputs.tag }}' 115 | removeArtifacts: true 116 | artifacts: '*.zip,*.apk,*.ipa,*.dmg,*.appimage,*.deb,*.rpm,*.exe' -------------------------------------------------------------------------------- /.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 | # l10n 47 | app_untranslated.json -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "submodules/veil_light_plugin"] 2 | path = submodules/veil_light_plugin 3 | url = https://github.com/steel97/veil_light_plugin.git 4 | [submodule "submodules/flutter"] 5 | path = submodules/flutter 6 | url = https://github.com/flutter/flutter.git 7 | -------------------------------------------------------------------------------- /.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: app 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: android 19 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 20 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 21 | - platform: ios 22 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 23 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 24 | - platform: linux 25 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 26 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 27 | - platform: macos 28 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 29 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 30 | - platform: web 31 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 32 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 33 | - platform: windows 34 | create_revision: ead455963c12b453cdb2358cad34969c76daf180 35 | base_revision: ead455963c12b453cdb2358cad34969c76daf180 36 | 37 | # User provided section 38 | 39 | # List of Local paths (relative to this file) that should be 40 | # ignored by the migrate tool. 41 | # 42 | # Files that are not part of the templates will be ignored by default. 43 | unmanaged_files: 44 | - 'lib/main.dart' 45 | - 'ios/Runner.xcodeproj/project.pbxproj' 46 | -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | "recommendations": [ 3 | "google.arb-editor", 4 | "dart-code.dart-code", 5 | "dart-code.flutter" 6 | ] 7 | } -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- 1 | { 2 | // Use IntelliSense to learn about possible attributes. 3 | // Hover to view descriptions of existing attributes. 4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 5 | "version": "0.2.0", 6 | "configurations": [ 7 | { 8 | "name": "veil_wallet", 9 | "request": "launch", 10 | "type": "dart" 11 | }, 12 | { 13 | "name": "veil_wallet (profile mode)", 14 | "request": "launch", 15 | "type": "dart", 16 | "flutterMode": "profile" 17 | }, 18 | { 19 | "name": "veil_wallet (release mode)", 20 | "request": "launch", 21 | "type": "dart", 22 | "flutterMode": "release" 23 | } 24 | ] 25 | } -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 Ivan Yurkov 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /SECURITY.md: -------------------------------------------------------------------------------- 1 | # Security Policy 2 | 3 | ## Supported Versions 4 | 5 | | Version | Supported | 6 | | ------- | ------------------ | 7 | | 1.0.3 | :white_check_mark: | 8 | | 1.0.0 | :x: | 9 | 10 | ## Reporting a Vulnerability 11 | 12 | You can help us by reporting vulnerabilities. 13 | Please use this e-mail to report vulnerabilities: `ivan.yurkov@steel-team.net` 14 | Fixed vulnerabilities will be marked on next release changelog. 15 | -------------------------------------------------------------------------------- /analysis_options.yaml: -------------------------------------------------------------------------------- 1 | include: package:flutter_lints/flutter.yaml 2 | 3 | linter: 4 | rules: 5 | prefer_single_quotes: true 6 | 7 | -------------------------------------------------------------------------------- /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 | key.pass 13 | **/*.keystore 14 | **/*.jks 15 | -------------------------------------------------------------------------------- /android/app/build.gradle: -------------------------------------------------------------------------------- 1 | plugins { 2 | id "com.android.application" 3 | id "kotlin-android" 4 | id "dev.flutter.flutter-gradle-plugin" 5 | } 6 | 7 | def localProperties = new Properties() 8 | def localPropertiesFile = rootProject.file('local.properties') 9 | if (localPropertiesFile.exists()) { 10 | localPropertiesFile.withReader('UTF-8') { reader -> 11 | localProperties.load(reader) 12 | } 13 | } 14 | 15 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode') 16 | if (flutterVersionCode == null) { 17 | flutterVersionCode = '1' 18 | } 19 | 20 | def flutterVersionName = localProperties.getProperty('flutter.versionName') 21 | if (flutterVersionName == null) { 22 | flutterVersionName = '1.0' 23 | } 24 | 25 | def keystoreProperties = new Properties() 26 | def keystorePropertiesFile = rootProject.file('key.properties') 27 | if (keystorePropertiesFile.exists()) { 28 | keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) 29 | } 30 | 31 | android { 32 | namespace "org.veilproject.wallet" 33 | compileSdkVersion flutter.compileSdkVersion 34 | ndkVersion flutter.ndkVersion 35 | 36 | compileOptions { 37 | sourceCompatibility JavaVersion.VERSION_1_8 38 | targetCompatibility JavaVersion.VERSION_1_8 39 | } 40 | 41 | kotlinOptions { 42 | jvmTarget = '1.8' 43 | } 44 | 45 | sourceSets { 46 | main.java.srcDirs += 'src/main/kotlin' 47 | } 48 | 49 | defaultConfig { 50 | applicationId "org.veilproject.wallet" 51 | minSdkVersion 23 52 | targetSdkVersion flutter.targetSdkVersion 53 | versionCode flutterVersionCode.toInteger() 54 | versionName flutterVersionName 55 | multiDexEnabled true 56 | 57 | project.android.applicationVariants.all { variant -> 58 | variant.outputs.each { output -> 59 | output.versionCodeOverride = flutterVersionCode.toInteger() 60 | } 61 | } 62 | } 63 | 64 | signingConfigs { 65 | release { 66 | keyAlias keystoreProperties['keyAlias'] 67 | keyPassword keystoreProperties['keyPassword'] 68 | storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null 69 | storePassword keystoreProperties['storePassword'] 70 | } 71 | } 72 | 73 | buildTypes { 74 | release { 75 | signingConfig signingConfigs.release 76 | } 77 | } 78 | } 79 | 80 | flutter { 81 | source '../..' 82 | } 83 | 84 | dependencies {} 85 | -------------------------------------------------------------------------------- /android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 16 | 20 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 38 | 41 | 42 | 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /android/app/src/main/kotlin/com/example/veil_wallet/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package org.veilproject.wallet 2 | 3 | import io.flutter.embedding.android.FlutterFragmentActivity 4 | 5 | class MainActivity: FlutterFragmentActivity () { 6 | } 7 | -------------------------------------------------------------------------------- /android/app/src/main/res/drawable-v21/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | -------------------------------------------------------------------------------- /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.6.1-all.zip 6 | 7 | -------------------------------------------------------------------------------- /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 "7.4.0" apply false 22 | id "org.jetbrains.kotlin.android" version "1.7.21" apply false 23 | } 24 | 25 | include ":app" -------------------------------------------------------------------------------- /assets/images/icons/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/icons/logo.png -------------------------------------------------------------------------------- /assets/images/icons/logo_linux.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/icons/logo_linux.png -------------------------------------------------------------------------------- /assets/images/icons/logo_macos.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/icons/logo_macos.png -------------------------------------------------------------------------------- /assets/images/icons/logo_mobile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/icons/logo_mobile.png -------------------------------------------------------------------------------- /assets/images/icons/logo_mobile_noalpha.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/icons/logo_mobile_noalpha.png -------------------------------------------------------------------------------- /assets/images/icons/logo_mobile_upscaled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/icons/logo_mobile_upscaled.png -------------------------------------------------------------------------------- /assets/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/logo.png -------------------------------------------------------------------------------- /assets/images/logo_64x64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/logo_64x64.png -------------------------------------------------------------------------------- /assets/images/logo_full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/logo_full.png -------------------------------------------------------------------------------- /assets/images/logo_full_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/logo_full_light.png -------------------------------------------------------------------------------- /assets/images/pattern.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/assets/images/pattern.png -------------------------------------------------------------------------------- /devtools_options.yaml: -------------------------------------------------------------------------------- 1 | extensions: 2 | -------------------------------------------------------------------------------- /distribute_options.yaml: -------------------------------------------------------------------------------- 1 | output: dist/ -------------------------------------------------------------------------------- /docs/deeplinking.md: -------------------------------------------------------------------------------- 1 | Deeplinks can be tested via: 2 | ``` 3 | adb shell am start -a android.intent.action.VIEW -c android.intent.category.BROWSABLE -d "veil:sv1qqp3twtj249e226mvg55jm0ec36y99xsh5ytnm6hcgvetthuptj2kugpqwcnw6tpnvwrrvutsltnghkg46ayqpw40g6p3knppy3kwgvhr34mkqqqeedkfp?amount=1.23" 4 | ``` 5 | 6 | OR via HTML: 7 | ``` 8 | Donate 1.23 veil 9 | ``` -------------------------------------------------------------------------------- /docs/deeplinking_demo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Veil Wallet - Deeplinking demo 5 | 6 | 7 | 8 | Donate 10 | 1.23 veil 11 | 12 | 13 | -------------------------------------------------------------------------------- /docs/fdroid-build.md: -------------------------------------------------------------------------------- 1 | tested with `ubuntu 22.04 LTS` 2 | 3 | required sdks: 4 | ``` 5 | sudo apt install android-sdk 6 | sudo apt install sdk-manager 7 | ``` 8 | 9 | don't forget to accept android sdk licenses: 10 | ``` 11 | yes | sudo sdkmanager --licenses 12 | ``` 13 | 14 | ``` 15 | cat << EOF > $ANDROID_HOME/licenses/android-sdk-license 16 | 17 | 8933bad161af4178b1185d1a37fbf41ea5269c55 18 | 19 | d56f5187479451eabf01fb78af6dfcb131a6481e 20 | 21 | 24333f8a63b6825ea9c5514f83c2829b004d1fee 22 | EOF 23 | ``` 24 | 25 | 26 | export android sdk path: 27 | ``` 28 | export ANDROID_HOME=/usr/lib/android-sdk 29 | ``` 30 | 31 | also specify ndk_paths on config.yml (app uses cargo_kit which by default uses NDK: 23.1.7779620) 32 | example: 33 | ``` 34 | ndk_paths: 35 | 23.1.7779620: ~/android-ndk/android-ndk-23.1.7779620 36 | ``` 37 | 38 | build wallet: 39 | ``` 40 | sudo -E fdroid build org.veilproject.wallet 41 | ``` -------------------------------------------------------------------------------- /docs/flutter-notes.md: -------------------------------------------------------------------------------- 1 | # Notes which may help with common errors 2 | 3 | ## Repairing flutter project 4 | \* all steps are optional 5 | ``` 6 | # cleaning build cache 7 | flutter clean 8 | # repairing packages cache 9 | flutter pub cache repair 10 | # removing packages lock file 11 | rm pubspec.lock 12 | # downloading dependencies 13 | flutter pub get 14 | ``` 15 | 16 | # veil_light_plugin 17 | ## Errors in IDE 18 | If you expirience errors in your IDE on `submodules/veil_light_plugin` folder: 19 | ``` 20 | cd submodules/veil_light_plugin 21 | dart pub get 22 | 23 | cd cargokit/build_tool 24 | dart pub get 25 | ``` 26 | 27 | 28 | ## Additional packages that may be required: 29 | ### Windows: 30 | ``` 31 | # run as administrator 32 | winget install Microsoft.NuGet 33 | ``` 34 | 35 | ### Android: 36 | ``` 37 | recommended java version: 19+ 38 | check java to be compatible with gradle 39 | minSdkVersion must be equal in veil_wallet and veil_light_plugin dependency 40 | dependencies/classpath must be equal in veil_wallet and veil_light_plugin dependency 41 | ``` -------------------------------------------------------------------------------- /docs/googleplay/app_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/googleplay/app_icon.png -------------------------------------------------------------------------------- /docs/googleplay/veil_promo_1_en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/googleplay/veil_promo_1_en.png -------------------------------------------------------------------------------- /docs/googleplay/veil_promo_1_ru.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/googleplay/veil_promo_1_ru.png -------------------------------------------------------------------------------- /docs/images/google-play-badge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/images/google-play-badge.png -------------------------------------------------------------------------------- /docs/images/google-play-badge_downscale.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/images/google-play-badge_downscale.png -------------------------------------------------------------------------------- /docs/images/template/License free.txt: -------------------------------------------------------------------------------- 1 | IMPORTANT NOTICE: This license only applies if you downloaded this content as 2 | an unsubscribed user. If you are a premium user (ie, you pay a subscription) 3 | you are bound to the license terms described in the accompanying file 4 | "License premium.txt". 5 | 6 | --------------------- 7 | 8 | You must attribute the image to its author: 9 | 10 | In order to use a content or a part of it, you must attribute it to Aleksandr_Samochernyi / Freepik, 11 | so we will be able to continue creating new graphic resources every day. 12 | 13 | 14 | How to attribute it? 15 | 16 | For websites: 17 | 18 | Please, copy this code on your website to accredit the author: 19 | Designed by Aleksandr_Samochernyi / Freepik 20 | 21 | For printing: 22 | 23 | Paste this text on the final work so the authorship is known. 24 | - For example, in the acknowledgements chapter of a book: 25 | "Designed by Aleksandr_Samochernyi / Freepik" 26 | 27 | 28 | You are free to use this image: 29 | 30 | - For both personal and commercial projects and to modify it. 31 | - In a website or presentation template or application or as part of your design. 32 | 33 | You are not allowed to: 34 | 35 | - Sub-license, resell or rent it. 36 | - Include it in any online or offline archive or database. 37 | 38 | The full terms of the license are described in section 7 of the Freepik 39 | terms of use, available online in the following link: 40 | 41 | http://www.freepik.com/terms_of_use 42 | 43 | The terms described in the above link have precedence over the terms described 44 | in the present document. In case of disagreement, the Freepik Terms of Use 45 | will prevail. 46 | -------------------------------------------------------------------------------- /docs/images/template/OT134T0.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/images/template/OT134T0.jpg -------------------------------------------------------------------------------- /docs/images/template/OT134T1.pdn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/images/template/OT134T1.pdn -------------------------------------------------------------------------------- /docs/images/template/OT134T1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/images/template/OT134T1.png -------------------------------------------------------------------------------- /docs/images/template/ghpicture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/docs/images/template/ghpicture.png -------------------------------------------------------------------------------- /flutter_launcher_icons.yaml: -------------------------------------------------------------------------------- 1 | flutter_launcher_icons: 2 | image_path: "assets/images/logo.png" 3 | min_sdk_android: 21 # android min sdk min:16, default 21 4 | 5 | android: true 6 | ios: true 7 | image_path_android: "assets/images/icons/logo_mobile.png" 8 | image_path_ios: "assets/images/icons/logo_mobile_noalpha.png" 9 | remove_alpha_ios: true 10 | windows: 11 | generate: true 12 | icon_size: 48 # min:48, max:256, default: 48 13 | macos: 14 | generate: true 15 | image_path: "assets/images/icons/logo_macos.png" -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /ios/Podfile: -------------------------------------------------------------------------------- 1 | # Uncomment this line to define a global platform for your project 2 | # platform :ios, '12.0' 3 | 4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency. 5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true' 6 | 7 | project 'Runner', { 8 | 'Debug' => :debug, 9 | 'Profile' => :release, 10 | 'Release' => :release, 11 | } 12 | 13 | def flutter_root 14 | generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__) 15 | unless File.exist?(generated_xcode_build_settings_path) 16 | raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first" 17 | end 18 | 19 | File.foreach(generated_xcode_build_settings_path) do |line| 20 | matches = line.match(/FLUTTER_ROOT\=(.*)/) 21 | return matches[1].strip if matches 22 | end 23 | raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get" 24 | end 25 | 26 | require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) 27 | 28 | flutter_ios_podfile_setup 29 | 30 | target 'Runner' do 31 | use_frameworks! 32 | use_modular_headers! 33 | 34 | flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) 35 | target 'RunnerTests' do 36 | inherit! :search_paths 37 | end 38 | end 39 | 40 | post_install do |installer| 41 | installer.pods_project.targets.each do |target| 42 | flutter_additional_ios_build_settings(target) 43 | end 44 | end 45 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 37 | 38 | 39 | 40 | 43 | 49 | 50 | 51 | 52 | 53 | 63 | 65 | 71 | 72 | 73 | 74 | 80 | 82 | 88 | 89 | 90 | 91 | 93 | 94 | 97 | 98 | 99 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "Icon-App-20x20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "Icon-App-20x20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "Icon-App-29x29@1x.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "Icon-App-29x29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "Icon-App-29x29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "Icon-App-40x40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "Icon-App-40x40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "60x60", 47 | "idiom" : "iphone", 48 | "filename" : "Icon-App-60x60@2x.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "60x60", 53 | "idiom" : "iphone", 54 | "filename" : "Icon-App-60x60@3x.png", 55 | "scale" : "3x" 56 | }, 57 | { 58 | "size" : "20x20", 59 | "idiom" : "ipad", 60 | "filename" : "Icon-App-20x20@1x.png", 61 | "scale" : "1x" 62 | }, 63 | { 64 | "size" : "20x20", 65 | "idiom" : "ipad", 66 | "filename" : "Icon-App-20x20@2x.png", 67 | "scale" : "2x" 68 | }, 69 | { 70 | "size" : "29x29", 71 | "idiom" : "ipad", 72 | "filename" : "Icon-App-29x29@1x.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "29x29", 77 | "idiom" : "ipad", 78 | "filename" : "Icon-App-29x29@2x.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "40x40", 83 | "idiom" : "ipad", 84 | "filename" : "Icon-App-40x40@1x.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "40x40", 89 | "idiom" : "ipad", 90 | "filename" : "Icon-App-40x40@2x.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "76x76", 95 | "idiom" : "ipad", 96 | "filename" : "Icon-App-76x76@1x.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "76x76", 101 | "idiom" : "ipad", 102 | "filename" : "Icon-App-76x76@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "83.5x83.5", 107 | "idiom" : "ipad", 108 | "filename" : "Icon-App-83.5x83.5@2x.png", 109 | "scale" : "2x" 110 | }, 111 | { 112 | "size" : "1024x1024", 113 | "idiom" : "ios-marketing", 114 | "filename" : "Icon-App-1024x1024@1x.png", 115 | "scale" : "1x" 116 | } 117 | ], 118 | "info" : { 119 | "version" : 1, 120 | "author" : "xcode" 121 | } 122 | } 123 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-50x50@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-50x50@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-50x50@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-50x50@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-72x72@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-72x72@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-72x72@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-72x72@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /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. -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /ios/Runner/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleDisplayName 8 | Veil Wallet 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | veil_wallet 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | $(FLUTTER_BUILD_NAME) 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | $(FLUTTER_BUILD_NUMBER) 25 | LSRequiresIPhoneOS 26 | 27 | UILaunchStoryboardName 28 | LaunchScreen 29 | UIMainStoryboardFile 30 | Main 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | 35 | UISupportedInterfaceOrientations~ipad 36 | 37 | UIInterfaceOrientationPortrait 38 | 39 | CADisableMinimumFrameDurationOnPhone 40 | 41 | UIApplicationSupportsIndirectInputEvents 42 | 43 | NSFaceIDUsageDescription 44 | This app uses face id to secure user data 45 | NSCameraUsageDescription 46 | This app needs camera access to scan QR codes 47 | FlutterDeepLinkingEnabled 48 | 49 | CFBundleURLTypes 50 | 51 | 52 | CFBundleURLName 53 | org.veilproject.wallet 54 | CFBundleURLSchemes 55 | 56 | veil 57 | 58 | 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /ios/Runner/Runner.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | aps-environment 6 | development 7 | keychain-access-groups 8 | 9 | 10 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /l10n.yaml: -------------------------------------------------------------------------------- 1 | arb-dir: lib/l10n 2 | template-arb-file: app_en.arb 3 | output-localization-file: app_localizations.dart 4 | untranslated-messages-file: app_untranslated.json -------------------------------------------------------------------------------- /lib/src/components/coin_control_widget.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 3 | import 'package:veil_wallet/src/core/constants.dart'; 4 | import 'package:veil_wallet/src/core/core.dart'; 5 | import 'package:veil_wallet/src/helpers/responsive.dart'; 6 | import 'package:veil_wallet/src/views/make_tx.dart'; 7 | import 'package:veil_wallet/src/views/receive_coins.dart'; 8 | 9 | class CoinControlWidget extends StatelessWidget { 10 | const CoinControlWidget({super.key}); 11 | 12 | @override 13 | Widget build(BuildContext context) { 14 | var useVerticalBar = isBigScreen(context); 15 | 16 | return Container( 17 | margin: const EdgeInsets.symmetric(horizontal: 10), 18 | width: double.infinity, 19 | child: NavigationBar( 20 | surfaceTintColor: Colors.transparent, 21 | indicatorColor: Colors.transparent, 22 | backgroundColor: Colors.transparent, 23 | selectedIndex: 0, 24 | onDestinationSelected: (value) async { 25 | if (value == 0) { 26 | Navigator.of(context).push(_createMakeTxRoute(useVerticalBar)); 27 | } else if (value == 1) { 28 | Navigator.of(context).push(_createReceiveRoute(useVerticalBar)); 29 | } else if (value == 2) { 30 | try { 31 | var url = Uri.parse(buyCryptoLink); 32 | await launchUrlWrapped(url); 33 | // ignore: empty_catches 34 | } catch (e) {} 35 | } 36 | }, 37 | destinations: [ 38 | NavigationDestination( 39 | icon: const Icon(Icons.arrow_upward_rounded), 40 | label: AppLocalizations.of(context)?.sendButton ?? 41 | stringNotFoundText, 42 | ), 43 | NavigationDestination( 44 | icon: const Icon(Icons.arrow_downward_rounded), 45 | label: AppLocalizations.of(context)?.receiveButton ?? 46 | stringNotFoundText, 47 | ), 48 | NavigationDestination( 49 | icon: const Icon(Icons.currency_exchange_rounded), 50 | label: AppLocalizations.of(context)?.buyButton ?? 51 | stringNotFoundText, 52 | ), 53 | ])); 54 | } 55 | } 56 | 57 | Route _createMakeTxRoute(bool useVerticalBar) { 58 | return PageRouteBuilder( 59 | pageBuilder: (context, animation, secondaryAnimation) { 60 | return const MakeTx(); 61 | }, transitionsBuilder: (context, animation, secondaryAnimation, child) { 62 | if (useVerticalBar) { 63 | return child; 64 | } 65 | 66 | const begin = Offset(1.0, 0.0); 67 | const end = Offset.zero; 68 | const curve = Curves.ease; 69 | 70 | var tween = Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); 71 | 72 | return SlideTransition( 73 | position: animation.drive(tween), 74 | child: child, 75 | ); 76 | }); 77 | } 78 | 79 | Route _createReceiveRoute(bool useVerticalBar) { 80 | return PageRouteBuilder( 81 | pageBuilder: (context, animation, secondaryAnimation) { 82 | return const ReceiveCoins(); 83 | }, transitionsBuilder: (context, animation, secondaryAnimation, child) { 84 | if (useVerticalBar) { 85 | return child; 86 | } 87 | 88 | const begin = Offset(1.0, 0.0); 89 | const end = Offset.zero; 90 | const curve = Curves.ease; 91 | 92 | var tween = Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); 93 | 94 | return SlideTransition( 95 | position: animation.drive(tween), 96 | child: child, 97 | ); 98 | }); 99 | } 100 | -------------------------------------------------------------------------------- /lib/src/components/transactions_list_widget.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 3 | import 'package:provider/provider.dart'; 4 | import 'package:veil_wallet/src/components/transaction.dart'; 5 | import 'package:veil_wallet/src/core/constants.dart'; 6 | import 'package:veil_wallet/src/core/transactions.dart'; 7 | import 'package:veil_wallet/src/helpers/responsive.dart'; 8 | import 'package:veil_wallet/src/states/provider/wallet_state.dart'; 9 | 10 | class TransactionsListWidget extends StatelessWidget { 11 | const TransactionsListWidget({super.key}); 12 | 13 | Widget getAddressStatusWidget(BuildContext context, SyncState syncState) { 14 | if (syncState == SyncState.synced) { 15 | return Icon(Icons.check_rounded, 16 | color: Theme.of(context).colorScheme.primary, 17 | semanticLabel: 18 | AppLocalizations.of(context)?.syncStatusSyncedSemantics); 19 | } 20 | 21 | if (syncState == SyncState.failed) { 22 | return Icon(Icons.close_rounded, 23 | color: Theme.of(context).colorScheme.error, 24 | semanticLabel: 25 | AppLocalizations.of(context)?.syncStatusScanningFailedSemantics); 26 | } 27 | 28 | return SizedBox( 29 | height: 24.0, 30 | width: 24.0, 31 | child: Center( 32 | child: CircularProgressIndicator( 33 | semanticsLabel: 34 | AppLocalizations.of(context)?.syncStatusScanningSemantics, 35 | ))); 36 | } 37 | 38 | @override 39 | Widget build(BuildContext context) { 40 | var incrementVal = context.watch().txRerender; 41 | var bigScreen = isBigScreen(context); 42 | 43 | List txes = List.empty(growable: true); 44 | for (TransactionModel tx in TransactionCache.currentTxList.reversed) { 45 | var hasTxSent = TransactionCache.sentTransactions.contains(tx.txId); 46 | var hasTxUnk = TransactionCache.unknownTransactions.contains(tx.txId); 47 | 48 | var type = TxType.unknown; 49 | if (hasTxSent) { 50 | type = TxType.sent; 51 | } else if (hasTxUnk) { 52 | type = TxType.unknown; 53 | } 54 | 55 | txes.add(Transaction( 56 | incKey: incrementVal, type: type, txid: tx.txId, amount: tx.amount)); 57 | txes.add(const SizedBox(height: 5)); 58 | } 59 | 60 | if (TransactionCache.currentTxList.isEmpty) { 61 | txes.add(Text( 62 | AppLocalizations.of(context)?.transactionsListEmpty ?? 63 | stringNotFoundText, 64 | textAlign: TextAlign.center, 65 | )); 66 | } 67 | 68 | return Container( 69 | margin: const EdgeInsets.symmetric(horizontal: 20), 70 | width: double.infinity, 71 | child: Column( 72 | children: [ 73 | Row( 74 | crossAxisAlignment: CrossAxisAlignment.end, 75 | mainAxisAlignment: MainAxisAlignment.spaceBetween, 76 | children: [ 77 | Text( 78 | AppLocalizations.of(context)?.transactionsLabel ?? 79 | stringNotFoundText, 80 | style: const TextStyle(fontSize: 24), 81 | ), 82 | getAddressStatusWidget( 83 | context, context.watch().syncState) 84 | //Icon(Icons.refresh_rounded) 85 | /*IconButton.filled( 86 | onPressed: () {}, icon: const Icon(Icons.refresh_rounded))*/ 87 | /*FilledButton.icon( 88 | onPressed: () => {}, 89 | icon: Icon(Icons.refresh_rounded), 90 | label: Text('Refresh'))*/ 91 | ], 92 | ), 93 | const SizedBox(height: 10), 94 | ] + 95 | (bigScreen 96 | ? [Expanded(child: ListView(children: txes))] 97 | : txes))); 98 | } 99 | } 100 | -------------------------------------------------------------------------------- /lib/src/core/constants.dart: -------------------------------------------------------------------------------- 1 | import 'package:veil_wallet/src/core/locale_entry.dart'; 2 | import 'package:veil_wallet/src/core/node_entry.dart'; 3 | 4 | var knownLanguages = [ 5 | LocaleEntry('English', 'en'), 6 | LocaleEntry('Español', 'es'), 7 | LocaleEntry('Esperanto', 'eo'), 8 | LocaleEntry('Русский', 'ru'), 9 | LocaleEntry('Lietuviškai', 'lt'), 10 | LocaleEntry('日本語', 'ja'), 11 | ]; 12 | 13 | var knownNodes = [ 14 | NodeEntry('US 1 (explorer)', 'https://explorer-api.veil-project.com'), 15 | NodeEntry('EU 2', 'https://node02.veil-project.com'), 16 | ]; 17 | 18 | const sourceCodeUrl = 'https://github.com/steel97/veil_wallet'; 19 | const donationsAddress = 20 | 'sv1qqp3twtj249e226mvg55jm0ec36y99xsh5ytnm6hcgvetthuptj2kugpqwcnw6tpnvwrrvutsltnghkg46ayqpw40g6p3knppy3kwgvhr34mkqqqeedkfp'; 21 | const buyCryptoLink = 22 | 'https://nonkyc.io'; // referral link: https://nonkyc.io?ref=651b52ea55acbaf736300f57 23 | const websiteAddress = 'https://veil-project.com'; 24 | const discordLabel = 'discord.veil-project.com'; 25 | const discordAddress = 'https://discord.veil-project.com'; 26 | 27 | const stringNotFoundText = 'STRING_NOT_FOUND'; 28 | const defaultWalletName = 'Default'; 29 | 30 | const defaultNodeAddress = 'https://explorer-api.veil-project.com'; 31 | const defaultExplorerAddress = 'https://explorer.veil-project.com'; 32 | const defaultTxExplorerAddress = 'https://explorer.veil-project.com/tx/{txid}'; 33 | const defaultConversionApiUrl = 'https://veilproject.org/api/getprice'; 34 | 35 | const hiddenBalanceMask = '******'; 36 | 37 | const prefsLocaleStorage = 'veil.locale'; 38 | const prefsDarkMode = 'veil.theme'; 39 | const prefsWalletsStorage = 'veil.wallets'; // format: , 40 | const prefsActiveWallet = 'veil.active_wallet'; // format: 41 | const prefsWalletNames = 42 | 'veil.wallet_names.'; // example veil.wallet_names.123 = Default 43 | const prefsWalletMnemonics = 44 | 'veil.wallet_mnemonics.'; // example veil.wallet_mnemonics.123 = 45 | const prefsWalletEncryption = 46 | 'veil.wallet_encryption.'; // example veil.wallet_mnemonics.123 = 47 | const prefsWalletTxEncIV = 'veil.wallet_txenciv.'; 48 | const prefsWalletTxEncKey = 'veil.wallet_txenckey.'; 49 | const prefsWalletAddressIndex = 'veil.wallet_address_index.'; 50 | const prefsBiometricsEnabled = 'veil.biometrics_enabled'; // true/false 51 | const prefsActiveAddress = 'veil.active_address'; 52 | const prefsWalletHiddenBalances = 'veil.hidden_balances'; 53 | 54 | // settings 55 | const prefsSettingsNodeUrl = 'veil.settings.node_url'; 56 | const prefsSettingsNodeAuth = 'veil.settings.node_auth'; 57 | const prefsSettingsExplorerUrl = 'veil.settings.explorer_url'; 58 | const prefsSettingsExplorerTxUrl = 'veil.settings.explorer_tx_url'; 59 | const prefsSettingsConversionManually = 'veil.settings.conversion_manually'; 60 | const prefsSettingsConversionApiUrl = 'veil.settings.conversion_api_url'; 61 | const prefsSettingsConversionRate = 'veil.settings.conversion_rate'; 62 | const prefsSettingsUseMinimumUTXOs = 'veil.settings.use_minimum_utxos'; 63 | 64 | // storage 65 | const prefsAddressHistory = 'veil.storage.address_history.'; 66 | const prefsAddressBook = 'veil.storage.address_book.'; 67 | 68 | // other 69 | const biometricsAuthTimeout = 120000; // milliseconds 70 | 71 | // background tasks 72 | const walletWatchDelay = 30; // seconds 73 | const conversionWatchDelay = 600; // seconds -------------------------------------------------------------------------------- /lib/src/core/core.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: empty_catches 2 | 3 | import 'package:url_launcher/url_launcher.dart'; 4 | 5 | Future launchUrlWrapped(Uri url) async { 6 | try { 7 | if (await _launchUrlMain(url)) return true; 8 | if (await _launchUrlNoChecks(url)) return true; 9 | if (await _launchUrlForceExternal(url)) return true; 10 | } catch (e) {} 11 | return false; 12 | } 13 | 14 | Future _launchUrlMain(Uri url) async { 15 | try { 16 | if (await canLaunchUrl(url)) { 17 | return await launchUrl(url); 18 | } else { 19 | return false; 20 | } 21 | } catch (e) { 22 | return false; 23 | } 24 | } 25 | 26 | Future _launchUrlNoChecks(Uri url) async { 27 | try { 28 | return await launchUrl(url); 29 | } catch (e) { 30 | return false; 31 | } 32 | } 33 | 34 | Future _launchUrlForceExternal(Uri url) async { 35 | try { 36 | return await launchUrl(url, mode: LaunchMode.externalApplication); 37 | } catch (e) { 38 | return false; 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /lib/src/core/func_checker.dart: -------------------------------------------------------------------------------- 1 | import 'dart:io'; 2 | import 'package:local_auth/local_auth.dart'; 3 | 4 | var auth = LocalAuthentication(); 5 | 6 | Future checkBiometricsSupport() async { 7 | if (Platform.isLinux || Platform.isFuchsia || Platform.isMacOS) { 8 | return false; 9 | } 10 | 11 | final bool canAuthenticateWithBiometrics = await auth.canCheckBiometrics; 12 | final bool canAuthenticate = 13 | canAuthenticateWithBiometrics || await auth.isDeviceSupported(); 14 | return canAuthenticate; 15 | } 16 | -------------------------------------------------------------------------------- /lib/src/core/locale_entry.dart: -------------------------------------------------------------------------------- 1 | class LocaleEntry { 2 | final String name; 3 | final String code; 4 | 5 | LocaleEntry(this.name, this.code); 6 | } 7 | -------------------------------------------------------------------------------- /lib/src/core/node_entry.dart: -------------------------------------------------------------------------------- 1 | class NodeEntry { 2 | final String name; 3 | final String url; 4 | 5 | NodeEntry(this.name, this.url); 6 | } 7 | -------------------------------------------------------------------------------- /lib/src/core/screen.dart: -------------------------------------------------------------------------------- 1 | enum Screen { 2 | notset, 3 | welcome, 4 | importSeed, 5 | newWallet, 6 | newWalletVerify, 7 | advancedSettings, 8 | setupBiometrics, 9 | settings, 10 | home, 11 | about, 12 | makeTx, 13 | auth, 14 | nodeFail, 15 | addressBook 16 | } 17 | -------------------------------------------------------------------------------- /lib/src/core/transactions.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | import 'dart:typed_data'; 3 | import 'package:veil_light_plugin/veil_light.dart'; 4 | import 'package:veil_wallet/src/core/constants.dart'; 5 | import 'package:veil_wallet/src/extensions/encryption/aes_cbc.dart'; 6 | import 'package:veil_wallet/src/extensions/file_storage.dart'; 7 | import 'package:veil_wallet/src/states/static/wallet_static_state.dart'; 8 | import 'package:veil_wallet/src/storage/storage_service.dart'; 9 | 10 | enum TxType { unknown, received, sent } 11 | 12 | class TransactionModel { 13 | final TxType type; 14 | final String txId; 15 | final String target; // used for send transactions 16 | final double amount; 17 | final int timestamp; 18 | 19 | TransactionModel( 20 | this.type, this.txId, this.target, this.amount, this.timestamp); 21 | } 22 | 23 | class TransactionCache { 24 | static List currentTxList = []; 25 | // below lines is TO-DO, currently not used 26 | static List unknownTransactions = List.empty(growable: true); 27 | static List sentTransactions = List.empty(growable: true); 28 | 29 | static TransactionModel lwTxToTx(CWatchOnlyTxWithIndex tx) { 30 | return TransactionModel( 31 | TxType.unknown, 32 | tx.getId() ?? '', 33 | '', 34 | tx.getAmount( 35 | WalletStaticState.lightwallet?.chainParams ?? mainNetParams), 36 | 0); 37 | } 38 | 39 | // set initial transactions cache on wallet import and mark txes as unknown type 40 | static Future setInitialTxes( 41 | int walletId, List txes) async { 42 | List txList = List.empty(growable: true); 43 | for (CWatchOnlyTxWithIndex tx in txes) { 44 | txList.add(lwTxToTx(tx)); 45 | if (!sentTransactions.contains(tx.getId())) { 46 | unknownTransactions.add(tx.getId() ?? ''); 47 | } 48 | } 49 | currentTxList = txList; 50 | // save json file to secure storage 51 | await saveData(walletId); 52 | } 53 | 54 | // updates transactions list with new values 55 | static Future updateTxList( 56 | int walletId, List txes) async { 57 | List txList = List.empty(growable: true); 58 | for (CWatchOnlyTxWithIndex tx in txes) { 59 | txList.add(lwTxToTx(tx)); 60 | } 61 | currentTxList = txList; 62 | // save json file to secure storage 63 | await saveData(walletId); 64 | } 65 | 66 | static Future addSentTransaction( 67 | int walletId, String fromAddress, String txId) async { 68 | sentTransactions.add('$fromAddress:$txId'); 69 | // save json file to secure storage 70 | await saveData(walletId); 71 | } 72 | 73 | // serialization not currently used here 74 | static Future saveData(int walletId) async { 75 | /* 76 | { 77 | "unknownTransactions": [ 78 | "" 79 | ], 80 | "sentTransactions": { 81 | "": { 82 | ... tx data 83 | } 84 | } 85 | } 86 | */ 87 | 88 | var storageService = StorageService(); 89 | var ivB64 = await storageService 90 | .readSecureData(prefsWalletTxEncIV + walletId.toString()); 91 | var keyB64 = await storageService 92 | .readSecureData(prefsWalletTxEncKey + walletId.toString()); 93 | 94 | var iv = base64.decode(ivB64 ?? ''); 95 | var key = base64.decode(keyB64 ?? ''); 96 | 97 | var model = { 98 | 'unknownTransactions': unknownTransactions, 99 | 'sentTransactions': sentTransactions 100 | }; 101 | 102 | var jsonText = jsonEncode(model); 103 | final cipherText = aesCbcEncrypt( 104 | key, iv, pad(Uint8List.fromList(utf8.encode(jsonText)), 16)); 105 | await writeTxCache(walletId, cipherText); 106 | } 107 | 108 | static Future loadData(int walletId) async { 109 | var cipherText = await readTxCache(walletId); 110 | if (cipherText == null) { 111 | return; 112 | } 113 | 114 | var storageService = StorageService(); 115 | var ivB64 = await storageService 116 | .readSecureData(prefsWalletTxEncIV + walletId.toString()); 117 | var keyB64 = await storageService 118 | .readSecureData(prefsWalletTxEncKey + walletId.toString()); 119 | 120 | var iv = base64.decode(ivB64 ?? ''); 121 | var key = base64.decode(keyB64 ?? ''); 122 | 123 | final paddedDecryptedBytes = aesCbcDecrypt(key, iv, cipherText); 124 | final decryptedBytes = unpad(paddedDecryptedBytes); 125 | var jsonText = 126 | json.decode(utf8.decode(decryptedBytes)) as Map; 127 | 128 | unknownTransactions = List.empty(growable: true); 129 | for (dynamic val in (jsonText['unknownTransactions'] as List)) { 130 | unknownTransactions.add(val.toString()); 131 | } 132 | 133 | sentTransactions = List.empty(growable: true); 134 | for (dynamic val in (jsonText['sentTransactions'] as List)) { 135 | sentTransactions.add(val.toString()); 136 | } 137 | } 138 | } 139 | -------------------------------------------------------------------------------- /lib/src/core/wallet_bg_tasks.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: empty_catches 2 | import 'dart:async'; 3 | import 'dart:convert'; 4 | import 'package:veil_wallet/src/states/static/base_static_state.dart'; 5 | import 'package:veil_wallet/src/states/static/wallet_static_state.dart'; 6 | import 'package:veil_wallet/src/core/wallet_helper.dart'; 7 | import 'package:http/http.dart' as http; 8 | 9 | class WalletBgTasks { 10 | static void runScanTask(Timer timer) async { 11 | try { 12 | await fetchData(); 13 | } catch (e) {} 14 | } 15 | 16 | static Future runConversionTask(Timer timer) async { 17 | if (!BaseStaticState.homePageShownOnce) return; 18 | 19 | await WalletBgTasks.fetchConversionRateIfPossible(); 20 | } 21 | 22 | static Future fetchConversionRateIfPossible() async { 23 | if (BaseStaticState.setConversionRateManually) return; 24 | try { 25 | var response = 26 | await http.get(Uri.parse(BaseStaticState.conversionApiAddress)); 27 | var json = jsonDecode(response.body); 28 | double convRate = json['price'].toDouble(); 29 | WalletHelper.updateConversionRate(convRate); 30 | } catch (e) {} 31 | } 32 | 33 | static fetchData() async { 34 | if (!WalletStaticState.walletWatching) return; 35 | 36 | for (var addr in WalletHelper.getAllAddresses()) { 37 | await WalletHelper.reloadTxes(addr); 38 | } 39 | 40 | await WalletHelper.uiReload(); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /lib/src/extensions/file_storage.dart: -------------------------------------------------------------------------------- 1 | import 'dart:io'; 2 | import 'dart:typed_data'; 3 | 4 | import 'package:path_provider/path_provider.dart'; 5 | 6 | Future get _localPath async { 7 | final directory = await getApplicationDocumentsDirectory(); 8 | return directory.path; 9 | } 10 | 11 | Future writeTxCache(int walId, Uint8List encryptedTxList) async { 12 | final path = await _localPath; 13 | final file = File('$path/$walId.veil'); 14 | 15 | return file.writeAsBytes(encryptedTxList); 16 | } 17 | 18 | Future readTxCache(int walId) async { 19 | try { 20 | final path = await _localPath; 21 | final file = File('$path/$walId.veil'); 22 | 23 | final contents = await file.readAsBytes(); 24 | return contents; 25 | } catch (e) { 26 | // If encountering an error, return 0 27 | return null; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /lib/src/extensions/misc.dart: -------------------------------------------------------------------------------- 1 | import 'dart:async'; 2 | 3 | // source: https://stackoverflow.com/a/68950494 4 | Timer makePeriodicTimer( 5 | Duration duration, 6 | void Function(Timer timer) callback, { 7 | bool fireNow = false, 8 | }) { 9 | var timer = Timer.periodic(duration, callback); 10 | if (fireNow) { 11 | callback(timer); 12 | } 13 | return timer; 14 | } 15 | -------------------------------------------------------------------------------- /lib/src/helpers/functions_check.dart: -------------------------------------------------------------------------------- 1 | import 'dart:io'; 2 | 3 | bool checkScanQROS() { 4 | return Platform.isIOS || Platform.isAndroid; 5 | } 6 | -------------------------------------------------------------------------------- /lib/src/helpers/responsive.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | const responsiveMaxDialogWidth = 300.0; 4 | const responsiveMaxDialogExtendedWidth = 400.0; 5 | const responsiveMaxMainWidth = 600.0; 6 | 7 | bool isBigScreen(BuildContext context) { 8 | return MediaQuery.of(context).size.width > 730; 9 | } 10 | -------------------------------------------------------------------------------- /lib/src/layouts/mobile/back_layout.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:veil_wallet/src/helpers/responsive.dart'; 3 | 4 | typedef VoidCallback = void Function(); 5 | 6 | class BackLayout extends StatefulWidget { 7 | const BackLayout( 8 | {super.key, @required this.child, @required this.title, this.back}); 9 | 10 | final Widget? child; 11 | final String? title; 12 | final VoidCallback? back; 13 | 14 | @override 15 | State createState() => _BackLayoutState(); 16 | } 17 | 18 | class _BackLayoutState extends State { 19 | late int selectedIndex; 20 | 21 | @override 22 | void initState() { 23 | super.initState(); 24 | } 25 | 26 | @override 27 | Widget build(BuildContext context) { 28 | var backFunc = widget.back; 29 | return Directionality( 30 | textDirection: TextDirection.ltr, 31 | child: Semantics( 32 | label: widget.title, 33 | child: Scaffold( 34 | appBar: AppBar( 35 | //backgroundColor: Colors.transparent, 36 | forceMaterialTransparency: true, 37 | centerTitle: true, 38 | leading: IconButton( 39 | icon: const Icon(Icons.chevron_left_rounded), 40 | color: Theme.of(context).colorScheme.primary, 41 | onPressed: backFunc), 42 | title: Text(widget.title ?? ''), 43 | ), 44 | extendBody: true, 45 | resizeToAvoidBottomInset: true, 46 | body: SafeArea( 47 | child: Center( 48 | child: Container( 49 | constraints: const BoxConstraints( 50 | minWidth: 100, maxWidth: responsiveMaxMainWidth), 51 | child: widget.child)), 52 | )))); 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /lib/src/layouts/mobile/loading_layout.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 3 | 4 | class LoadingLayout extends StatefulWidget { 5 | const LoadingLayout({super.key, @required this.child}); 6 | 7 | final Widget? child; 8 | 9 | @override 10 | State createState() => _LoadingLayoutState(); 11 | } 12 | 13 | class _LoadingLayoutState extends State { 14 | late int selectedIndex; 15 | 16 | @override 17 | void initState() { 18 | super.initState(); 19 | } 20 | 21 | @override 22 | Widget build(BuildContext context) { 23 | return Directionality( 24 | textDirection: TextDirection.ltr, 25 | child: Semantics( 26 | label: AppLocalizations.of(context)?.loadingAppSemantics, 27 | child: Scaffold( 28 | appBar: AppBar( 29 | //backgroundColor: Colors.transparent, 30 | forceMaterialTransparency: true, 31 | centerTitle: false, 32 | automaticallyImplyLeading: false, 33 | ), 34 | extendBody: true, 35 | resizeToAvoidBottomInset: true, 36 | body: SafeArea( 37 | child: Container(child: widget.child), 38 | )))); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /lib/src/layouts/mobile/welcome_layout.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 3 | import 'package:provider/provider.dart'; 4 | import 'package:veil_wallet/src/core/screen.dart'; 5 | import 'package:veil_wallet/src/states/provider/wallet_state.dart'; 6 | import 'package:veil_wallet/src/states/static/base_static_state.dart'; 7 | import 'package:veil_wallet/src/views/settings.dart'; 8 | 9 | class WelcomeLayout extends StatefulWidget { 10 | const WelcomeLayout({super.key, @required this.child}); 11 | 12 | final Widget? child; 13 | 14 | @override 15 | State createState() => _WelcomeLayoutState(); 16 | } 17 | 18 | class _WelcomeLayoutState extends State { 19 | late int selectedIndex; 20 | 21 | @override 22 | void initState() { 23 | super.initState(); 24 | } 25 | 26 | @override 27 | Widget build(BuildContext context) { 28 | return Directionality( 29 | textDirection: TextDirection.ltr, 30 | child: Semantics( 31 | label: AppLocalizations.of(context)?.welcomeTitle, 32 | child: Scaffold( 33 | appBar: AppBar( 34 | //backgroundColor: Colors.transparent, 35 | forceMaterialTransparency: true, 36 | centerTitle: false, 37 | automaticallyImplyLeading: false, 38 | 39 | /*leading: IconButton( 40 | icon: const Icon(Icons.notifications_rounded), 41 | color: Theme.of(context).colorScheme.primary, 42 | onPressed: () {}),*/ 43 | title: Container( 44 | width: 70, 45 | height: 28, 46 | decoration: BoxDecoration( 47 | image: DecorationImage( 48 | image: AssetImage( 49 | context.watch().darkMode 50 | ? './assets/images/logo_full.png' 51 | : './assets/images/logo_full_light.png'), 52 | fit: BoxFit.fitHeight))), 53 | actions: [ 54 | IconButton( 55 | icon: const Icon(Icons.settings_rounded), 56 | color: Theme.of(context).colorScheme.primary, 57 | onPressed: () { 58 | BaseStaticState.prevScreen = Screen.welcome; 59 | BaseStaticState.useHomeBack = false; 60 | Navigator.of(context).push(_createSettingsRoute()); 61 | }, 62 | tooltip: AppLocalizations.of(context)?.settingsButton, 63 | ), 64 | const SizedBox(width: 10) 65 | ], 66 | ), 67 | extendBody: true, 68 | resizeToAvoidBottomInset: true, 69 | body: SafeArea( 70 | child: Container(child: widget.child), 71 | )))); 72 | } 73 | } 74 | 75 | Route _createSettingsRoute() { 76 | return PageRouteBuilder( 77 | pageBuilder: (context, animation, secondaryAnimation) => const Settings(), 78 | transitionsBuilder: (context, animation, secondaryAnimation, child) { 79 | const begin = Offset(1.0, 0.0); 80 | const end = Offset.zero; 81 | const curve = Curves.ease; 82 | 83 | var tween = 84 | Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); 85 | 86 | return SlideTransition( 87 | position: animation.drive(tween), 88 | child: child, 89 | ); 90 | }); 91 | } 92 | -------------------------------------------------------------------------------- /lib/src/models/address_model.dart: -------------------------------------------------------------------------------- 1 | class AddressModel { 2 | final int id; 3 | final String label; 4 | final String address; 5 | 6 | AddressModel(this.id, this.label, this.address); 7 | 8 | AddressModel.fromJson(Map json) 9 | : id = json['id'] as int, 10 | label = json['label'] as String, 11 | address = json['address'] as String; 12 | 13 | Map toJson() => { 14 | 'id': id, 15 | 'label': label, 16 | 'address': address, 17 | }; 18 | } 19 | -------------------------------------------------------------------------------- /lib/src/states/provider/dialogs_state.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/foundation.dart'; 2 | 3 | class DialogsState with ChangeNotifier, DiagnosticableTreeMixin { 4 | bool _sendTxActive = false; 5 | bool _deleteWalletActive = false; 6 | 7 | bool get sendTxActive => _sendTxActive; 8 | bool get deleteWalletActive => _deleteWalletActive; 9 | 10 | void setSendTxActive(bool val) { 11 | _sendTxActive = val; 12 | notifyListeners(); 13 | } 14 | 15 | void setDeleteWalletActive(bool val) { 16 | _deleteWalletActive = val; 17 | notifyListeners(); 18 | } 19 | 20 | /// Makes `Counter` readable inside the devtools by listing all of its properties 21 | @override 22 | void debugFillProperties(DiagnosticPropertiesBuilder properties) { 23 | super.debugFillProperties(properties); 24 | properties.add(FlagProperty('sendTxActive', value: _sendTxActive)); 25 | properties 26 | .add(FlagProperty('deleteWalletActive', value: _deleteWalletActive)); 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /lib/src/states/provider/wallet_state.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/foundation.dart'; 2 | import 'package:flutter/material.dart'; 3 | import 'package:veil_light_plugin/veil_light.dart'; 4 | 5 | class OwnedAddress { 6 | final AccountType accountType; 7 | final String address; 8 | final int index; 9 | 10 | OwnedAddress(this.accountType, this.address, this.index); 11 | } 12 | 13 | enum SyncState { synced, scanning, failed } 14 | 15 | class WalletState with ChangeNotifier, DiagnosticableTreeMixin { 16 | int _selectedWallet = -1; 17 | String _selectedAddress = ''; 18 | List _ownedAddresses = []; 19 | double _balance = 0.0; 20 | double _conversionRate = 0.0; 21 | int _txRerender = 0; 22 | SyncState _syncState = SyncState.scanning; 23 | Locale? _locale; 24 | bool _darkMode = false; 25 | bool _hideBalance = false; 26 | 27 | int get selectedWallet => _selectedWallet; 28 | String get selectedAddress => _selectedAddress; 29 | List get ownedAddresses => _ownedAddresses; 30 | double get balance => _balance; 31 | double get conversionRate => _conversionRate; 32 | int get txRerender => _txRerender; 33 | SyncState get syncState => _syncState; 34 | Locale? get locale => _locale; 35 | bool get darkMode => _darkMode; 36 | bool get hideBalance => _hideBalance; 37 | 38 | void setSelectedWallet(int wal) { 39 | _selectedWallet = wal; 40 | notifyListeners(); 41 | } 42 | 43 | void setSelectedAddress(String addr) { 44 | _selectedAddress = addr; 45 | notifyListeners(); 46 | } 47 | 48 | void setOwnedAddresses(List addresses) { 49 | _ownedAddresses = addresses; 50 | notifyListeners(); 51 | } 52 | 53 | void setBalance(double balance) { 54 | _balance = balance; 55 | notifyListeners(); 56 | } 57 | 58 | void setConversionRate(double convRate) { 59 | _conversionRate = convRate; 60 | notifyListeners(); 61 | } 62 | 63 | void incrementTxRerender() { 64 | _txRerender++; 65 | notifyListeners(); 66 | } 67 | 68 | void setSyncState(SyncState val) { 69 | _syncState = val; 70 | notifyListeners(); 71 | } 72 | 73 | void setLocale(Locale? val) { 74 | _locale = val; 75 | notifyListeners(); 76 | } 77 | 78 | void setDarkMode(bool val) { 79 | _darkMode = val; 80 | notifyListeners(); 81 | } 82 | 83 | void setHideBalance(bool val) { 84 | _hideBalance = val; 85 | notifyListeners(); 86 | } 87 | 88 | /// Makes `Counter` readable inside the devtools by listing all of its properties 89 | @override 90 | void debugFillProperties(DiagnosticPropertiesBuilder properties) { 91 | super.debugFillProperties(properties); 92 | properties.add(IntProperty('selectedWallet', _selectedWallet)); 93 | } 94 | } 95 | -------------------------------------------------------------------------------- /lib/src/states/states_bridge.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class StatesBridge { 4 | static GlobalKey navigatorKey = GlobalKey(); 5 | } 6 | -------------------------------------------------------------------------------- /lib/src/states/static/base_static_state.dart: -------------------------------------------------------------------------------- 1 | import 'package:veil_wallet/src/core/constants.dart'; 2 | import 'package:veil_wallet/src/core/screen.dart'; 3 | 4 | class BaseStaticState { 5 | static List importWalletWords = []; 6 | static List newWalletWords = []; 7 | static Screen prevScreen = Screen.welcome; 8 | static Screen prevWalAdvancedScreen = Screen.importSeed; 9 | static Screen prevScanQRScreen = Screen.home; 10 | static Screen prevNodeFailSceren = Screen.notset; 11 | static bool useHomeBack = false; 12 | static bool biometricsActive = false; 13 | static bool initialBiometricsPassed = false; 14 | static bool isStartedWithDeepLink = false; 15 | static int biometricsTimestamp = 0; 16 | static bool homePageShownOnce = false; 17 | 18 | // advanced wallet settings 19 | static List walletMnemonic = []; 20 | static String walletEncryptionPassword = ''; 21 | static String tempWalletName = ''; 22 | 23 | // settings 24 | static String nodeAddress = defaultNodeAddress; 25 | static String nodeAuth = ''; 26 | static String explorerAddress = defaultExplorerAddress; 27 | static String txExplorerAddress = defaultTxExplorerAddress; 28 | static bool setConversionRateManually = false; 29 | static String conversionApiAddress = defaultConversionApiUrl; 30 | static String conversionCustomRate = '0.00'; 31 | static bool useMinimumUTXOs = false; 32 | 33 | // wallet settings 34 | static int walSettingsId = -1; 35 | static String walSettingsName = ''; 36 | static String walSettingsPassword = ''; 37 | } 38 | -------------------------------------------------------------------------------- /lib/src/states/static/wallet_static_state.dart: -------------------------------------------------------------------------------- 1 | import 'package:veil_light_plugin/veil_light.dart'; 2 | 3 | class WalletEntry { 4 | String name; 5 | int id; 6 | 7 | WalletEntry(this.name, this.id); 8 | } 9 | 10 | class WalletStaticState { 11 | static List? wallets; 12 | static int activeWallet = -1; 13 | static Lightwallet? lightwallet; 14 | static LightwalletAccount? account; 15 | 16 | static bool walletWatching = false; 17 | static double conversionRate = 0.0; 18 | 19 | static String? deepLinkTargetAddress; 20 | static String? deepLinkTargetAmount; 21 | 22 | static bool addressBookOpenedFromQR = false; 23 | static String prevAddressBookLabel = ''; 24 | static String tmpAddressBookAddress = ''; 25 | } 26 | -------------------------------------------------------------------------------- /lib/src/storage/storage_item.dart: -------------------------------------------------------------------------------- 1 | class StorageItem { 2 | StorageItem(this.key, this.value); 3 | 4 | final String key; 5 | final String value; 6 | } 7 | -------------------------------------------------------------------------------- /lib/src/storage/storage_service.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_secure_storage/flutter_secure_storage.dart'; 2 | import 'package:veil_wallet/src/storage/storage_item.dart'; 3 | 4 | class StorageService { 5 | final _secureStorage = const FlutterSecureStorage( 6 | aOptions: AndroidOptions( 7 | encryptedSharedPreferences: true, 8 | )); 9 | 10 | Future writeSecureData(StorageItem newItem) async { 11 | await _secureStorage.write(key: newItem.key, value: newItem.value); 12 | } 13 | 14 | Future readSecureData(String key) async { 15 | var readData = await _secureStorage.read(key: key); 16 | if(await _secureStorage.containsKey(key: key) && readData == null) { 17 | return ''; 18 | } 19 | return readData; 20 | } 21 | 22 | Future deleteSecureData(String key) async { 23 | await _secureStorage.delete(key: key); 24 | } 25 | 26 | Future deleteAllSecureData() async { 27 | await _secureStorage.deleteAll(); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /lib/src/views/home.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:veil_wallet/src/components/transactions_list_widget.dart'; 3 | import 'package:veil_wallet/src/layouts/mobile/main_layout.dart'; 4 | 5 | class Home extends StatelessWidget { 6 | const Home({super.key}); 7 | 8 | @override 9 | Widget build(BuildContext context) { 10 | return PopScope( 11 | canPop: false, 12 | child: MainLayout( 13 | noWidthLimit: true, 14 | child: Container( 15 | width: double.infinity, 16 | margin: const EdgeInsets.fromLTRB(0, 0, 0, 10), 17 | child: const TransactionsListWidget()), 18 | )); 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /lib/src/views/legal.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/services.dart'; 2 | import 'package:flutter/material.dart'; 3 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 4 | import 'package:veil_wallet/src/layouts/mobile/back_layout.dart'; 5 | import 'package:veil_wallet/src/views/about.dart'; 6 | 7 | class Legal extends StatelessWidget { 8 | const Legal({super.key}); 9 | 10 | @override 11 | Widget build(BuildContext context) { 12 | var legalFeature = rootBundle.loadString('assets/res/legal.txt'); 13 | return PopScope( 14 | onPopInvoked: (invoked) { 15 | Navigator.of(context).push(_createBackRoute()); 16 | }, 17 | child: BackLayout( 18 | title: AppLocalizations.of(context)?.legalTitle, 19 | back: () { 20 | Navigator.of(context).push(_createBackRoute()); 21 | }, 22 | child: Container( 23 | width: double.infinity, 24 | margin: const EdgeInsets.fromLTRB(5, 10, 5, 10), 25 | child: ListView(children: [ 26 | FutureBuilder( 27 | future: legalFeature, 28 | builder: 29 | (BuildContext context, AsyncSnapshot snapshot) { 30 | return SelectableText( 31 | snapshot.data ?? '', 32 | ); 33 | }) 34 | ]), 35 | ))); 36 | } 37 | } 38 | 39 | Route _createBackRoute() { 40 | return PageRouteBuilder( 41 | pageBuilder: (context, animation, secondaryAnimation) { 42 | return const About(); 43 | }, transitionsBuilder: (context, animation, secondaryAnimation, child) { 44 | const begin = Offset(-1.0, 0.0); 45 | const end = Offset.zero; 46 | const curve = Curves.ease; 47 | 48 | var tween = Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); 49 | 50 | return SlideTransition( 51 | position: animation.drive(tween), 52 | child: child, 53 | ); 54 | }); 55 | } 56 | -------------------------------------------------------------------------------- /lib/src/views/loading.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 3 | import 'package:provider/provider.dart'; 4 | import 'package:veil_wallet/src/layouts/mobile/loading_layout.dart'; 5 | import 'package:veil_wallet/src/states/provider/wallet_state.dart'; 6 | 7 | class Loading extends StatelessWidget { 8 | const Loading({super.key}); 9 | 10 | @override 11 | Widget build(BuildContext context) { 12 | return PopScope( 13 | canPop: false, 14 | child: LoadingLayout( 15 | child: Container( 16 | width: double.infinity, 17 | margin: const EdgeInsets.fromLTRB(0, 0, 0, 100), 18 | child: Column(mainAxisAlignment: MainAxisAlignment.center, children: [ 19 | Container( 20 | margin: const EdgeInsets.fromLTRB(0, 0, 0, 30), 21 | width: 70 * 1.8, 22 | height: 28 * 1.8, 23 | decoration: BoxDecoration( 24 | image: DecorationImage( 25 | image: AssetImage(context.watch().darkMode 26 | ? './assets/images/logo_full.png' 27 | : './assets/images/logo_full_light.png'), 28 | fit: BoxFit.fitWidth))), 29 | CircularProgressIndicator( 30 | semanticsLabel: AppLocalizations.of(context)?.loadingAppSemantics, 31 | ), 32 | ]), 33 | ))); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /lib/src/views/receive_coins.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: use_build_context_synchronously 2 | import 'package:flutter/material.dart'; 3 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 4 | import 'package:pretty_qr_code/pretty_qr_code.dart'; 5 | import 'package:screenshot/screenshot.dart'; 6 | import 'package:share_plus/share_plus.dart'; 7 | import 'package:provider/provider.dart'; 8 | import 'package:veil_wallet/src/core/constants.dart'; 9 | import 'package:veil_wallet/src/helpers/responsive.dart'; 10 | import 'package:veil_wallet/src/layouts/mobile/back_layout.dart'; 11 | import 'package:veil_wallet/src/layouts/mobile/main_layout.dart'; 12 | import 'package:veil_wallet/src/states/provider/wallet_state.dart'; 13 | import 'package:veil_wallet/src/views/home.dart'; 14 | 15 | class ReceiveCoins extends StatefulWidget { 16 | const ReceiveCoins({super.key}); 17 | 18 | @override 19 | State createState() => _ReceiveCoinsState(); 20 | } 21 | 22 | class _ReceiveCoinsState extends State { 23 | ScreenshotController screenshotController = ScreenshotController(); 24 | 25 | @override 26 | Widget build(BuildContext context) { 27 | var useVerticalBar = isBigScreen(context); 28 | double qrMaxSize = 300; 29 | 30 | var container = Container( 31 | width: double.infinity, 32 | margin: const EdgeInsets.fromLTRB(0, 0, 0, 10), 33 | child: Column( 34 | mainAxisAlignment: MainAxisAlignment.start, 35 | crossAxisAlignment: CrossAxisAlignment.center, 36 | children: [ 37 | Container( 38 | margin: const EdgeInsets.fromLTRB(10, 10, 10, 0), 39 | child: Text( 40 | AppLocalizations.of(context)?.shareDescriptionText ?? 41 | stringNotFoundText, 42 | style: const TextStyle(fontWeight: FontWeight.normal), 43 | textAlign: TextAlign.center)), 44 | Screenshot( 45 | controller: screenshotController, 46 | child: Container( 47 | constraints: 48 | BoxConstraints(maxWidth: qrMaxSize, maxHeight: qrMaxSize), 49 | color: Theme.of(context).colorScheme.background, 50 | padding: const EdgeInsets.all(30), 51 | child: PrettyQrView.data( 52 | data: 53 | 'veil:${context.watch().selectedAddress}', 54 | errorCorrectLevel: QrErrorCorrectLevel.M, 55 | decoration: PrettyQrDecoration( 56 | shape: PrettyQrSmoothSymbol( 57 | color: Theme.of(context).colorScheme.primary, 58 | ), 59 | /*image: const PrettyQrDecorationImage( 60 | image: AssetImage('assets/images/logo.png'), 61 | ),*/ 62 | ))), 63 | ), 64 | TextButton.icon( 65 | onPressed: () async { 66 | var image = await screenshotController.capture(); 67 | 68 | Share.shareXFiles([ 69 | XFile.fromData(image!, 70 | name: 'veil_qr.png', mimeType: 'image/png') 71 | ], 72 | subject: AppLocalizations.of(context)?.shareSubject, 73 | text: AppLocalizations.of(context)?.shareText( 74 | context.read().selectedAddress)); 75 | }, 76 | icon: const Icon(Icons.share_rounded), 77 | label: Text(AppLocalizations.of(context)?.shareAction ?? 78 | stringNotFoundText)) 79 | ]), 80 | ); 81 | 82 | return PopScope( 83 | canPop: false, 84 | onPopInvoked: (invoked) { 85 | if (useVerticalBar) return; 86 | 87 | Navigator.of(context).push(_createBackRoute(useVerticalBar)); 88 | }, 89 | child: useVerticalBar 90 | ? MainLayout( 91 | overrideTitle: AppLocalizations.of(context)?.shareTitle, 92 | child: container) 93 | : BackLayout( 94 | title: AppLocalizations.of(context)?.shareTitle, 95 | back: () { 96 | Navigator.of(context).push(_createBackRoute(useVerticalBar)); 97 | }, 98 | child: container)); 99 | } 100 | } 101 | 102 | Route _createBackRoute(bool useVerticalBar) { 103 | return PageRouteBuilder( 104 | pageBuilder: (context, animation, secondaryAnimation) { 105 | return const Home(); 106 | }, transitionsBuilder: (context, animation, secondaryAnimation, child) { 107 | if (useVerticalBar) { 108 | return child; 109 | } 110 | 111 | const begin = Offset(-1.0, 0.0); 112 | const end = Offset.zero; 113 | const curve = Curves.ease; 114 | 115 | var tween = Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); 116 | 117 | return SlideTransition( 118 | position: animation.drive(tween), 119 | child: child, 120 | ); 121 | }); 122 | } 123 | -------------------------------------------------------------------------------- /lib/src/views/welcome.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 3 | import 'package:veil_wallet/src/core/constants.dart'; 4 | import 'package:veil_wallet/src/core/screen.dart'; 5 | import 'package:veil_wallet/src/layouts/mobile/welcome_layout.dart'; 6 | import 'package:veil_wallet/src/states/static/base_static_state.dart'; 7 | import 'package:veil_wallet/src/views/import_seed.dart'; 8 | import 'package:veil_wallet/src/views/new_wallet_save_seed.dart'; 9 | import 'package:veil_light_plugin/veil_light.dart'; 10 | 11 | class Welcome extends StatelessWidget { 12 | const Welcome({super.key}); 13 | 14 | @override 15 | Widget build(BuildContext context) { 16 | return PopScope( 17 | canPop: false, 18 | child: WelcomeLayout( 19 | child: Container( 20 | width: double.infinity, 21 | margin: const EdgeInsets.fromLTRB(0, 0, 0, 100), 22 | child: Column(mainAxisAlignment: MainAxisAlignment.center, children: [ 23 | Text( 24 | AppLocalizations.of(context)?.welcomeTitle ?? stringNotFoundText, 25 | style: const TextStyle(fontSize: 28, fontWeight: FontWeight.bold), 26 | textAlign: TextAlign.center, 27 | ), 28 | Text( 29 | AppLocalizations.of(context)?.welcomeDescription ?? 30 | stringNotFoundText, 31 | style: const TextStyle(fontSize: 14), 32 | textAlign: TextAlign.center, 33 | ), 34 | Container( 35 | width: 170, 36 | margin: const EdgeInsets.fromLTRB(0, 15, 0, 6), 37 | child: FilledButton.icon( 38 | style: FilledButton.styleFrom( 39 | minimumSize: const Size.fromHeight(42)), 40 | onPressed: () { 41 | BaseStaticState.prevScreen = Screen.welcome; 42 | var mnemonic = Lightwallet.generateMnemonic(); 43 | BaseStaticState.newWalletWords = mnemonic; 44 | Navigator.of(context).push(_createSaveRoute()); 45 | }, 46 | icon: const Icon(Icons.new_label_rounded), 47 | label: Text( 48 | AppLocalizations.of(context)?.createWallet ?? 49 | stringNotFoundText, 50 | overflow: TextOverflow.ellipsis), 51 | )), 52 | SizedBox( 53 | width: 170, 54 | child: OutlinedButton.icon( 55 | style: FilledButton.styleFrom( 56 | minimumSize: const Size.fromHeight(42)), 57 | onPressed: () { 58 | BaseStaticState.prevScreen = Screen.welcome; 59 | BaseStaticState.importWalletWords = []; 60 | Navigator.of(context).push(_createImportRoute()); 61 | }, 62 | icon: const Icon(Icons.upload_rounded), 63 | label: Text( 64 | AppLocalizations.of(context)?.importWallet ?? 65 | stringNotFoundText, 66 | overflow: TextOverflow.ellipsis), 67 | )), 68 | ]), 69 | ))); 70 | } 71 | } 72 | 73 | Route _createSaveRoute() { 74 | return PageRouteBuilder( 75 | pageBuilder: (context, animation, secondaryAnimation) => 76 | const NewWalletSaveSeed(), 77 | transitionsBuilder: (context, animation, secondaryAnimation, child) { 78 | const begin = Offset(1.0, 0.0); 79 | const end = Offset.zero; 80 | const curve = Curves.ease; 81 | 82 | var tween = Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); 83 | 84 | return SlideTransition( 85 | position: animation.drive(tween), 86 | child: child, 87 | ); 88 | }, 89 | ); 90 | } 91 | 92 | Route _createImportRoute() { 93 | return PageRouteBuilder( 94 | pageBuilder: (context, animation, secondaryAnimation) => const ImportSeed(), 95 | transitionsBuilder: (context, animation, secondaryAnimation, child) { 96 | const begin = Offset(1.0, 0.0); 97 | const end = Offset.zero; 98 | const curve = Curves.ease; 99 | 100 | var tween = Tween(begin: begin, end: end).chain(CurveTween(curve: curve)); 101 | 102 | return SlideTransition( 103 | position: animation.drive(tween), 104 | child: child, 105 | ); 106 | }, 107 | ); 108 | } 109 | -------------------------------------------------------------------------------- /linux/.gitignore: -------------------------------------------------------------------------------- 1 | flutter/ephemeral 2 | -------------------------------------------------------------------------------- /linux/flutter/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # This file controls Flutter-level build steps. It should not be edited. 2 | cmake_minimum_required(VERSION 3.10) 3 | 4 | set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral") 5 | 6 | # Configuration provided via flutter tool. 7 | include(${EPHEMERAL_DIR}/generated_config.cmake) 8 | 9 | # TODO: Move the rest of this into files in ephemeral. See 10 | # https://github.com/flutter/flutter/issues/57146. 11 | 12 | # Serves the same purpose as list(TRANSFORM ... PREPEND ...), 13 | # which isn't available in 3.10. 14 | function(list_prepend LIST_NAME PREFIX) 15 | set(NEW_LIST "") 16 | foreach(element ${${LIST_NAME}}) 17 | list(APPEND NEW_LIST "${PREFIX}${element}") 18 | endforeach(element) 19 | set(${LIST_NAME} "${NEW_LIST}" PARENT_SCOPE) 20 | endfunction() 21 | 22 | # === Flutter Library === 23 | # System-level dependencies. 24 | find_package(PkgConfig REQUIRED) 25 | pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0) 26 | pkg_check_modules(GLIB REQUIRED IMPORTED_TARGET glib-2.0) 27 | pkg_check_modules(GIO REQUIRED IMPORTED_TARGET gio-2.0) 28 | 29 | set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/libflutter_linux_gtk.so") 30 | 31 | # Published to parent scope for install step. 32 | set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE) 33 | set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE) 34 | set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE) 35 | set(AOT_LIBRARY "${PROJECT_DIR}/build/lib/libapp.so" PARENT_SCOPE) 36 | 37 | list(APPEND FLUTTER_LIBRARY_HEADERS 38 | "fl_basic_message_channel.h" 39 | "fl_binary_codec.h" 40 | "fl_binary_messenger.h" 41 | "fl_dart_project.h" 42 | "fl_engine.h" 43 | "fl_json_message_codec.h" 44 | "fl_json_method_codec.h" 45 | "fl_message_codec.h" 46 | "fl_method_call.h" 47 | "fl_method_channel.h" 48 | "fl_method_codec.h" 49 | "fl_method_response.h" 50 | "fl_plugin_registrar.h" 51 | "fl_plugin_registry.h" 52 | "fl_standard_message_codec.h" 53 | "fl_standard_method_codec.h" 54 | "fl_string_codec.h" 55 | "fl_value.h" 56 | "fl_view.h" 57 | "flutter_linux.h" 58 | ) 59 | list_prepend(FLUTTER_LIBRARY_HEADERS "${EPHEMERAL_DIR}/flutter_linux/") 60 | add_library(flutter INTERFACE) 61 | target_include_directories(flutter INTERFACE 62 | "${EPHEMERAL_DIR}" 63 | ) 64 | target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}") 65 | target_link_libraries(flutter INTERFACE 66 | PkgConfig::GTK 67 | PkgConfig::GLIB 68 | PkgConfig::GIO 69 | ) 70 | add_dependencies(flutter flutter_assemble) 71 | 72 | # === Flutter tool backend === 73 | # _phony_ is a non-existent file to force this command to run every time, 74 | # since currently there's no way to get a full input/output list from the 75 | # flutter tool. 76 | add_custom_command( 77 | OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS} 78 | ${CMAKE_CURRENT_BINARY_DIR}/_phony_ 79 | COMMAND ${CMAKE_COMMAND} -E env 80 | ${FLUTTER_TOOL_ENVIRONMENT} 81 | "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.sh" 82 | ${FLUTTER_TARGET_PLATFORM} ${CMAKE_BUILD_TYPE} 83 | VERBATIM 84 | ) 85 | add_custom_target(flutter_assemble DEPENDS 86 | "${FLUTTER_LIBRARY}" 87 | ${FLUTTER_LIBRARY_HEADERS} 88 | ) 89 | -------------------------------------------------------------------------------- /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 | #include 11 | #include 12 | 13 | void fl_register_plugins(FlPluginRegistry* registry) { 14 | g_autoptr(FlPluginRegistrar) flutter_secure_storage_linux_registrar = 15 | fl_plugin_registry_get_registrar_for_plugin(registry, "FlutterSecureStorageLinuxPlugin"); 16 | flutter_secure_storage_linux_plugin_register_with_registrar(flutter_secure_storage_linux_registrar); 17 | g_autoptr(FlPluginRegistrar) url_launcher_linux_registrar = 18 | fl_plugin_registry_get_registrar_for_plugin(registry, "UrlLauncherPlugin"); 19 | url_launcher_plugin_register_with_registrar(url_launcher_linux_registrar); 20 | g_autoptr(FlPluginRegistrar) window_size_registrar = 21 | fl_plugin_registry_get_registrar_for_plugin(registry, "WindowSizePlugin"); 22 | window_size_plugin_register_with_registrar(window_size_registrar); 23 | } 24 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /linux/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | flutter_secure_storage_linux 7 | url_launcher_linux 8 | window_size 9 | ) 10 | 11 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 12 | veil_light_plugin 13 | ) 14 | 15 | set(PLUGIN_BUNDLED_LIBRARIES) 16 | 17 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 18 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin}) 19 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 20 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 21 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 22 | endforeach(plugin) 23 | 24 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 25 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin}) 26 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 27 | endforeach(ffi_plugin) 28 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /linux/my_application.cc: -------------------------------------------------------------------------------- 1 | #include "my_application.h" 2 | 3 | #include 4 | #ifdef GDK_WINDOWING_X11 5 | #include 6 | #endif 7 | 8 | #include "flutter/generated_plugin_registrant.h" 9 | 10 | struct _MyApplication 11 | { 12 | GtkApplication parent_instance; 13 | char **dart_entrypoint_arguments; 14 | }; 15 | 16 | G_DEFINE_TYPE(MyApplication, my_application, GTK_TYPE_APPLICATION) 17 | 18 | // Implements GApplication::activate. 19 | static void my_application_activate(GApplication *application) 20 | { 21 | MyApplication *self = MY_APPLICATION(application); 22 | GtkWindow *window = 23 | GTK_WINDOW(gtk_application_window_new(GTK_APPLICATION(application))); 24 | 25 | // Use a header bar when running in GNOME as this is the common style used 26 | // by applications and is the setup most users will be using (e.g. Ubuntu 27 | // desktop). 28 | // If running on X and not using GNOME then just use a traditional title bar 29 | // in case the window manager does more exotic layout, e.g. tiling. 30 | // If running on Wayland assume the header bar will work (may need changing 31 | // if future cases occur). 32 | gboolean use_header_bar = TRUE; 33 | #ifdef GDK_WINDOWING_X11 34 | GdkScreen *screen = gtk_window_get_screen(window); 35 | if (GDK_IS_X11_SCREEN(screen)) 36 | { 37 | const gchar *wm_name = gdk_x11_screen_get_window_manager_name(screen); 38 | if (g_strcmp0(wm_name, "GNOME Shell") != 0) 39 | { 40 | use_header_bar = FALSE; 41 | } 42 | } 43 | #endif 44 | if (use_header_bar) 45 | { 46 | GtkHeaderBar *header_bar = GTK_HEADER_BAR(gtk_header_bar_new()); 47 | gtk_widget_show(GTK_WIDGET(header_bar)); 48 | gtk_header_bar_set_title(header_bar, "veil-wallet"); 49 | gtk_header_bar_set_show_close_button(header_bar, TRUE); 50 | gtk_window_set_titlebar(window, GTK_WIDGET(header_bar)); 51 | } 52 | else 53 | { 54 | gtk_window_set_title(window, "veil-wallet"); 55 | } 56 | 57 | gtk_window_set_default_size(window, 1280, 720); 58 | gtk_widget_show(GTK_WIDGET(window)); 59 | 60 | g_autoptr(FlDartProject) project = fl_dart_project_new(); 61 | fl_dart_project_set_dart_entrypoint_arguments(project, self->dart_entrypoint_arguments); 62 | 63 | FlView *view = fl_view_new(project); 64 | gtk_widget_show(GTK_WIDGET(view)); 65 | gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(view)); 66 | 67 | fl_register_plugins(FL_PLUGIN_REGISTRY(view)); 68 | 69 | gtk_widget_grab_focus(GTK_WIDGET(view)); 70 | } 71 | 72 | // Implements GApplication::local_command_line. 73 | static gboolean my_application_local_command_line(GApplication *application, gchar ***arguments, int *exit_status) 74 | { 75 | MyApplication *self = MY_APPLICATION(application); 76 | // Strip out the first argument as it is the binary name. 77 | self->dart_entrypoint_arguments = g_strdupv(*arguments + 1); 78 | 79 | g_autoptr(GError) error = nullptr; 80 | if (!g_application_register(application, nullptr, &error)) 81 | { 82 | g_warning("Failed to register: %s", error->message); 83 | *exit_status = 1; 84 | return TRUE; 85 | } 86 | 87 | g_application_activate(application); 88 | *exit_status = 0; 89 | 90 | return TRUE; 91 | } 92 | 93 | // Implements GObject::dispose. 94 | static void my_application_dispose(GObject *object) 95 | { 96 | MyApplication *self = MY_APPLICATION(object); 97 | g_clear_pointer(&self->dart_entrypoint_arguments, g_strfreev); 98 | G_OBJECT_CLASS(my_application_parent_class)->dispose(object); 99 | } 100 | 101 | static void my_application_class_init(MyApplicationClass *klass) 102 | { 103 | G_APPLICATION_CLASS(klass)->activate = my_application_activate; 104 | G_APPLICATION_CLASS(klass)->local_command_line = my_application_local_command_line; 105 | G_OBJECT_CLASS(klass)->dispose = my_application_dispose; 106 | } 107 | 108 | static void my_application_init(MyApplication *self) {} 109 | 110 | MyApplication *my_application_new() 111 | { 112 | return MY_APPLICATION(g_object_new(my_application_get_type(), 113 | "application-id", APPLICATION_ID, 114 | "flags", G_APPLICATION_NON_UNIQUE, 115 | nullptr)); 116 | } 117 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /linux/packaging/appimage/make_config.yaml: -------------------------------------------------------------------------------- 1 | display_name: Veil Wallet 2 | 3 | icon: assets/images/icons/logo_linux.png 4 | 5 | keywords: 6 | - Veil 7 | - Cryptocurrency 8 | - Finance 9 | - Application 10 | 11 | generic_name: Cryptocurrency Wallet 12 | 13 | categories: 14 | - Finance 15 | 16 | startup_notify: true 17 | 18 | include: [] -------------------------------------------------------------------------------- /linux/packaging/deb/make_config.yaml: -------------------------------------------------------------------------------- 1 | display_name: Veil Wallet 2 | package_name: veil-wallet 3 | maintainer: 4 | name: Ivan Yurkov 5 | email: ivan.yurkov@steel-team.net 6 | priority: optional 7 | section: x11 8 | installed_size: 27618304 9 | essential: false 10 | icon: assets/images/icons/logo_linux.png 11 | 12 | postinstall_scripts: 13 | - echo "Installed Veil Wallet" 14 | postuninstall_scripts: 15 | - echo "Uninstalled Veil Wallet" 16 | 17 | keywords: 18 | - Veil 19 | - Cryptocurrency 20 | - Finance 21 | - Application 22 | 23 | generic_name: Cryptocurrency Wallet 24 | 25 | categories: 26 | - Finance 27 | 28 | startup_notify: true -------------------------------------------------------------------------------- /linux/packaging/rpm/make_config.yaml: -------------------------------------------------------------------------------- 1 | icon: assets/images/icons/logo_linux.png 2 | summary: Privacy focused VEIL coin crypto wallet 3 | vendor: Ivan Yurkov 4 | packager: Ivan Yurkov 5 | packagerEmail: ivan.yurkov@steel-team.net 6 | license: MIT 7 | url: https://github.com/steel97/veil_wallet 8 | 9 | display_name: Veil Wallet 10 | 11 | keywords: 12 | - Veil 13 | - Cryptocurrency 14 | - Finance 15 | - Application 16 | 17 | generic_name: Cryptocurrency Wallet 18 | 19 | categories: 20 | - Finance 21 | 22 | startup_notify: true 23 | 24 | -------------------------------------------------------------------------------- /macos/.gitignore: -------------------------------------------------------------------------------- 1 | # Flutter-related 2 | **/Flutter/ephemeral/ 3 | **/Pods/ 4 | 5 | # Xcode-related 6 | **/dgph 7 | **/xcuserdata/ 8 | -------------------------------------------------------------------------------- /macos/Flutter/Flutter-Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /macos/Flutter/Flutter-Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /macos/Flutter/GeneratedPluginRegistrant.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | import FlutterMacOS 6 | import Foundation 7 | 8 | import flutter_secure_storage_macos 9 | import local_auth_darwin 10 | import package_info_plus 11 | import path_provider_foundation 12 | import share_plus 13 | import shared_preferences_foundation 14 | import url_launcher_macos 15 | import window_size 16 | 17 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { 18 | FlutterSecureStoragePlugin.register(with: registry.registrar(forPlugin: "FlutterSecureStoragePlugin")) 19 | FLALocalAuthPlugin.register(with: registry.registrar(forPlugin: "FLALocalAuthPlugin")) 20 | FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin")) 21 | PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) 22 | SharePlusMacosPlugin.register(with: registry.registrar(forPlugin: "SharePlusMacosPlugin")) 23 | SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) 24 | UrlLauncherPlugin.register(with: registry.registrar(forPlugin: "UrlLauncherPlugin")) 25 | WindowSizePlugin.register(with: registry.registrar(forPlugin: "WindowSizePlugin")) 26 | } 27 | -------------------------------------------------------------------------------- /macos/Podfile: -------------------------------------------------------------------------------- 1 | platform :osx, '10.14' 2 | 3 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency. 4 | ENV['COCOAPODS_DISABLE_STATS'] = 'true' 5 | 6 | project 'Runner', { 7 | 'Debug' => :debug, 8 | 'Profile' => :release, 9 | 'Release' => :release, 10 | } 11 | 12 | def flutter_root 13 | generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'ephemeral', 'Flutter-Generated.xcconfig'), __FILE__) 14 | unless File.exist?(generated_xcode_build_settings_path) 15 | raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure \"flutter pub get\" is executed first" 16 | end 17 | 18 | File.foreach(generated_xcode_build_settings_path) do |line| 19 | matches = line.match(/FLUTTER_ROOT\=(.*)/) 20 | return matches[1].strip if matches 21 | end 22 | raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Flutter-Generated.xcconfig, then run \"flutter pub get\"" 23 | end 24 | 25 | require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) 26 | 27 | flutter_macos_podfile_setup 28 | 29 | target 'Runner' do 30 | use_frameworks! 31 | use_modular_headers! 32 | 33 | flutter_install_all_macos_pods File.dirname(File.realpath(__FILE__)) 34 | target 'RunnerTests' do 35 | inherit! :search_paths 36 | end 37 | end 38 | 39 | post_install do |installer| 40 | installer.pods_project.targets.each do |target| 41 | flutter_additional_macos_build_settings(target) 42 | end 43 | end 44 | -------------------------------------------------------------------------------- /macos/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - flutter_secure_storage_macos (6.1.1): 3 | - FlutterMacOS 4 | - FlutterMacOS (1.0.0) 5 | - local_auth_darwin (0.0.1): 6 | - Flutter 7 | - FlutterMacOS 8 | - package_info_plus (0.0.1): 9 | - FlutterMacOS 10 | - path_provider_foundation (0.0.1): 11 | - Flutter 12 | - FlutterMacOS 13 | - share_plus (0.0.1): 14 | - FlutterMacOS 15 | - shared_preferences_foundation (0.0.1): 16 | - Flutter 17 | - FlutterMacOS 18 | - url_launcher_macos (0.0.1): 19 | - FlutterMacOS 20 | - veil_light_plugin (0.0.1) 21 | - window_size (0.0.2): 22 | - FlutterMacOS 23 | 24 | DEPENDENCIES: 25 | - flutter_secure_storage_macos (from `Flutter/ephemeral/.symlinks/plugins/flutter_secure_storage_macos/macos`) 26 | - FlutterMacOS (from `Flutter/ephemeral`) 27 | - local_auth_darwin (from `Flutter/ephemeral/.symlinks/plugins/local_auth_darwin/darwin`) 28 | - package_info_plus (from `Flutter/ephemeral/.symlinks/plugins/package_info_plus/macos`) 29 | - path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin`) 30 | - share_plus (from `Flutter/ephemeral/.symlinks/plugins/share_plus/macos`) 31 | - shared_preferences_foundation (from `Flutter/ephemeral/.symlinks/plugins/shared_preferences_foundation/darwin`) 32 | - url_launcher_macos (from `Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos`) 33 | - veil_light_plugin (from `Flutter/ephemeral/.symlinks/plugins/veil_light_plugin/macos`) 34 | - window_size (from `Flutter/ephemeral/.symlinks/plugins/window_size/macos`) 35 | 36 | EXTERNAL SOURCES: 37 | flutter_secure_storage_macos: 38 | :path: Flutter/ephemeral/.symlinks/plugins/flutter_secure_storage_macos/macos 39 | FlutterMacOS: 40 | :path: Flutter/ephemeral 41 | local_auth_darwin: 42 | :path: Flutter/ephemeral/.symlinks/plugins/local_auth_darwin/darwin 43 | package_info_plus: 44 | :path: Flutter/ephemeral/.symlinks/plugins/package_info_plus/macos 45 | path_provider_foundation: 46 | :path: Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin 47 | share_plus: 48 | :path: Flutter/ephemeral/.symlinks/plugins/share_plus/macos 49 | shared_preferences_foundation: 50 | :path: Flutter/ephemeral/.symlinks/plugins/shared_preferences_foundation/darwin 51 | url_launcher_macos: 52 | :path: Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos 53 | veil_light_plugin: 54 | :path: Flutter/ephemeral/.symlinks/plugins/veil_light_plugin/macos 55 | window_size: 56 | :path: Flutter/ephemeral/.symlinks/plugins/window_size/macos 57 | 58 | SPEC CHECKSUMS: 59 | flutter_secure_storage_macos: 59459653abe1adb92abbc8ea747d79f8d19866c9 60 | FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24 61 | local_auth_darwin: 66e40372f1c29f383a314c738c7446e2f7fdadc3 62 | package_info_plus: f5790acc797bf17c3e959e9d6cf162cc68ff7523 63 | path_provider_foundation: 2b6b4c569c0fb62ec74538f866245ac84301af46 64 | share_plus: fd717ef89a2801d3491e737630112b80c310640e 65 | shared_preferences_foundation: fcdcbc04712aee1108ac7fda236f363274528f78 66 | url_launcher_macos: c82c93949963e55b228a30115bd219499a6fe404 67 | veil_light_plugin: 3f4cb272c28949175915f25454a46ca0ca4271f6 68 | window_size: 339dafa0b27a95a62a843042038fa6c3c48de195 69 | 70 | PODFILE CHECKSUM: 236401fc2c932af29a9fcf0e97baeeb2d750d367 71 | 72 | COCOAPODS: 1.15.2 73 | -------------------------------------------------------------------------------- /macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 37 | 38 | 39 | 40 | 43 | 49 | 50 | 51 | 52 | 53 | 63 | 65 | 71 | 72 | 73 | 74 | 80 | 82 | 88 | 89 | 90 | 91 | 93 | 94 | 97 | 98 | 99 | -------------------------------------------------------------------------------- /macos/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info": { 3 | "version": 1, 4 | "author": "xcode" 5 | }, 6 | "images": [ 7 | { 8 | "size": "16x16", 9 | "idiom": "mac", 10 | "filename": "app_icon_16.png", 11 | "scale": "1x" 12 | }, 13 | { 14 | "size": "16x16", 15 | "idiom": "mac", 16 | "filename": "app_icon_32.png", 17 | "scale": "2x" 18 | }, 19 | { 20 | "size": "32x32", 21 | "idiom": "mac", 22 | "filename": "app_icon_32.png", 23 | "scale": "1x" 24 | }, 25 | { 26 | "size": "32x32", 27 | "idiom": "mac", 28 | "filename": "app_icon_64.png", 29 | "scale": "2x" 30 | }, 31 | { 32 | "size": "128x128", 33 | "idiom": "mac", 34 | "filename": "app_icon_128.png", 35 | "scale": "1x" 36 | }, 37 | { 38 | "size": "128x128", 39 | "idiom": "mac", 40 | "filename": "app_icon_256.png", 41 | "scale": "2x" 42 | }, 43 | { 44 | "size": "256x256", 45 | "idiom": "mac", 46 | "filename": "app_icon_256.png", 47 | "scale": "1x" 48 | }, 49 | { 50 | "size": "256x256", 51 | "idiom": "mac", 52 | "filename": "app_icon_512.png", 53 | "scale": "2x" 54 | }, 55 | { 56 | "size": "512x512", 57 | "idiom": "mac", 58 | "filename": "app_icon_512.png", 59 | "scale": "1x" 60 | }, 61 | { 62 | "size": "512x512", 63 | "idiom": "mac", 64 | "filename": "app_icon_1024.png", 65 | "scale": "2x" 66 | } 67 | ] 68 | } -------------------------------------------------------------------------------- /macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -------------------------------------------------------------------------------- /macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -------------------------------------------------------------------------------- /macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -------------------------------------------------------------------------------- /macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -------------------------------------------------------------------------------- /macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png -------------------------------------------------------------------------------- /macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -------------------------------------------------------------------------------- /macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png -------------------------------------------------------------------------------- /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 = veil-wallet 9 | 10 | // The application's bundle identifier 11 | PRODUCT_BUNDLE_IDENTIFIER = org.veilproject.wallet 12 | 13 | // The copyright displayed in application information 14 | PRODUCT_COPYRIGHT = Copyright © 2023 veil-project. All rights reserved. 15 | -------------------------------------------------------------------------------- /macos/Runner/Configs/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Debug.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /macos/Runner/Configs/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Release.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /macos/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 | -------------------------------------------------------------------------------- /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 | keychain-access-groups 12 | 13 | $(AppIdentifierPrefix)org.veilproject.wallet 14 | 15 | com.apple.security.network.client 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /macos/Runner/Release.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | keychain-access-groups 8 | 9 | $(AppIdentifierPrefix)org.veilproject.wallet 10 | 11 | com.apple.security.network.client 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /macos/Runner/RunnerRelease.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | keychain-access-groups 6 | 7 | $(AppIdentifierPrefix)org.veilproject.wallet 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /macos/packaging/dmg/make_config.yaml: -------------------------------------------------------------------------------- 1 | title: Veil Wallet 2 | contents: 3 | - x: 448 4 | y: 344 5 | type: link 6 | path: "/Applications" 7 | - x: 192 8 | y: 344 9 | type: file 10 | path: veil-wallet.app -------------------------------------------------------------------------------- /metadata/en-US/changelogs/10.txt: -------------------------------------------------------------------------------- 1 | - it's now possible to hide balance by clicking on it 2 | - improvements in about page (added licenses of used libraries and link to official discord) 3 | - fixed transaction creation for some cases 4 | - new address creation (behaviour is similar to full node, so all created addresses are deterministic) 5 | - deeplinking support, now it's possible to use this kind of links: veil:your_address?amount=123.456 (those links can be embedded to an HTML page or used in QR codes, which can be scanned by OS natively, without opening QR scan dialog in wallet app) -------------------------------------------------------------------------------- /metadata/en-US/changelogs/11.txt: -------------------------------------------------------------------------------- 1 | - android hotfix -------------------------------------------------------------------------------- /metadata/en-US/changelogs/12.txt: -------------------------------------------------------------------------------- 1 | - android hotfix -------------------------------------------------------------------------------- /metadata/en-US/changelogs/13.txt: -------------------------------------------------------------------------------- 1 | - added Japanese and Lithuanian languages 2 | - added "Send max" button 3 | - added recipient address history 4 | - added "Delete all data" button 5 | - added address book 6 | - fixed known issues -------------------------------------------------------------------------------- /metadata/en-US/changelogs/14.txt: -------------------------------------------------------------------------------- 1 | - updated libraries -------------------------------------------------------------------------------- /metadata/en-US/changelogs/15.txt: -------------------------------------------------------------------------------- 1 | - updated libraries -------------------------------------------------------------------------------- /metadata/en-US/changelogs/16.txt: -------------------------------------------------------------------------------- 1 | - updated libraries -------------------------------------------------------------------------------- /metadata/en-US/changelogs/17.txt: -------------------------------------------------------------------------------- 1 | - updated libraries -------------------------------------------------------------------------------- /metadata/en-US/changelogs/18.txt: -------------------------------------------------------------------------------- 1 | - updated libraries -------------------------------------------------------------------------------- /metadata/en-US/changelogs/19.txt: -------------------------------------------------------------------------------- 1 | - added ability to change conversion API url 2 | - added ability to set conversion rate manually -------------------------------------------------------------------------------- /metadata/en-US/changelogs/20.txt: -------------------------------------------------------------------------------- 1 | - added ability to change conversion API url 2 | - added ability to set conversion rate manually -------------------------------------------------------------------------------- /metadata/en-US/changelogs/21.txt: -------------------------------------------------------------------------------- 1 | - added ability to change conversion API url 2 | - added ability to set conversion rate manually -------------------------------------------------------------------------------- /metadata/en-US/changelogs/22.txt: -------------------------------------------------------------------------------- 1 | - added ability to change conversion API url 2 | - added ability to set conversion rate manually -------------------------------------------------------------------------------- /metadata/en-US/changelogs/23.txt: -------------------------------------------------------------------------------- 1 | - added ability to change conversion API url 2 | - added ability to set conversion rate manually -------------------------------------------------------------------------------- /metadata/en-US/changelogs/24.txt: -------------------------------------------------------------------------------- 1 | - added ability to change conversion API url 2 | - added ability to set conversion rate manually 3 | - back button support on Android -------------------------------------------------------------------------------- /metadata/en-US/changelogs/25.txt: -------------------------------------------------------------------------------- 1 | - added ability to change conversion API url 2 | - added ability to set conversion rate manually 3 | - back button support on Android 4 | - removed nonkyc referral link -------------------------------------------------------------------------------- /metadata/en-US/changelogs/26.txt: -------------------------------------------------------------------------------- 1 | - added ability to change conversion API url 2 | - added ability to set conversion rate manually 3 | - back button support on Android 4 | - removed nonkyc referral link -------------------------------------------------------------------------------- /metadata/en-US/changelogs/27.txt: -------------------------------------------------------------------------------- 1 | - changed default price api url to veilproject.org 2 | - updated dependencies -------------------------------------------------------------------------------- /metadata/en-US/changelogs/28.txt: -------------------------------------------------------------------------------- 1 | - updated flutter -------------------------------------------------------------------------------- /metadata/en-US/changelogs/29.txt: -------------------------------------------------------------------------------- 1 | - updated flutter -------------------------------------------------------------------------------- /metadata/en-US/changelogs/9.txt: -------------------------------------------------------------------------------- 1 | - added Spanish and Esperanto languages 2 | - added language selection button in setings 3 | - added dark theme 4 | - added predefined node selection menu in settings 5 | - swapped website and explorer buttons -------------------------------------------------------------------------------- /metadata/en-US/full_description.txt: -------------------------------------------------------------------------------- 1 | Veil - Privacy without compromise 2 | 3 | Veil is creating an encrypted equivalent of the cash economy, where privacy is the most convenient choice. Learn more, download the wallet, and join the journey. 4 | 5 | PRIVACY BY DEFAULT 6 | 7 | Privacy should not be optional. Veil aims to make full-time privacy the most convenient choice. 8 | 9 | INCENTIVIZED PARTICIPATION 10 | 11 | By holding Veil, our users not only contribute to broadly distributed network security, but earn staking rewards — anonymously! 12 | 13 | FAIR LAUNCH 14 | 15 | No ICO. No premine. Veil's blockchain is secured via Proof-of-Work and Proof-of-Stake in order to combine both security and fair distribution. 16 | 17 | USER-FOCUSED 18 | 19 | In a digital cash society, participation extends to everybody, not just those who read user manuals. Veil aims to be one of the most user-friendly wallets in crypto. 20 | 21 | SELF-SUSTAINING 22 | 23 | The Veil network includes built-in self-funding for project development, operations, customer support, and ongoing research and development. 24 | 25 | FUTURE-SAFE 26 | 27 | Veil will continue to push the limits of cryptography and blockchain technology through Veil Labs, an entity dedicated to R&D and partnerships with leading academic institutions. 28 | 29 | 30 | Project website: 31 | https://veil-project.com 32 | Source code: 33 | https://github.com/steel97/veil_wallet 34 | Discord 35 | https://discord.veil-project.com -------------------------------------------------------------------------------- /metadata/en-US/images/featureGraphic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/en-US/images/featureGraphic.png -------------------------------------------------------------------------------- /metadata/en-US/images/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/en-US/images/icon.png -------------------------------------------------------------------------------- /metadata/en-US/images/phoneScreenshots/veil_screen_1_en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/en-US/images/phoneScreenshots/veil_screen_1_en.png -------------------------------------------------------------------------------- /metadata/en-US/images/phoneScreenshots/veil_screen_2_en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/en-US/images/phoneScreenshots/veil_screen_2_en.png -------------------------------------------------------------------------------- /metadata/en-US/images/phoneScreenshots/veil_screen_3_en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/en-US/images/phoneScreenshots/veil_screen_3_en.png -------------------------------------------------------------------------------- /metadata/en-US/images/phoneScreenshots/veil_screen_4_en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/en-US/images/phoneScreenshots/veil_screen_4_en.png -------------------------------------------------------------------------------- /metadata/en-US/short_description.txt: -------------------------------------------------------------------------------- 1 | Privacy focused VEIL coin crypto wallet -------------------------------------------------------------------------------- /metadata/en-US/title.txt: -------------------------------------------------------------------------------- 1 | Veil - Privacy focused wallet -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/10.txt: -------------------------------------------------------------------------------- 1 | - теперь можно скрыть баланс, нажав на него 2 | - улучшения на странице "О приложении" (добавлены лицензии используемых библиотек и ссылка на официальный дискорд) 3 | - исправлено создание транзакций для некоторых случаев 4 | - добавлена возможность создавать новый адрес (поведение аналогично оффициальному кошельку, поэтому все созданные адреса детерминированы) 5 | - поддержка deeplinking-а, теперь можно использовать ссылки такого вида: veil:your_address?amount=123.456 (эти ссылки можно встроить в HTML-страницу или использовать в QR-кодах, которые могут сканироваться операционной системой без открытия диалогового окна QR-сканирования в приложении кошелька) -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/11.txt: -------------------------------------------------------------------------------- 1 | - исправление ошибок -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/12.txt: -------------------------------------------------------------------------------- 1 | - исправление ошибок -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/13.txt: -------------------------------------------------------------------------------- 1 | - добавлены Японский и Литовский языки 2 | - добавлена кнопка "отправить всё" 3 | - добавлена история адресов-получателей 4 | - добавлена кнопка "Удалить все данные" 5 | - добавлена адресная книга 6 | - исправлены известные ошибки -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/14.txt: -------------------------------------------------------------------------------- 1 | - обновлены библиотеки -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/15.txt: -------------------------------------------------------------------------------- 1 | - обновлены библиотеки -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/16.txt: -------------------------------------------------------------------------------- 1 | - обновлены библиотеки -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/17.txt: -------------------------------------------------------------------------------- 1 | - обновлены библиотеки -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/18.txt: -------------------------------------------------------------------------------- 1 | - обновлены библиотеки -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/19.txt: -------------------------------------------------------------------------------- 1 | - добавлена возможность установить адрес API конвертации 2 | - добавлена возможность установить курс конвертации -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/20.txt: -------------------------------------------------------------------------------- 1 | - добавлена возможность установить адрес API конвертации 2 | - добавлена возможность установить курс конвертации -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/21.txt: -------------------------------------------------------------------------------- 1 | - добавлена возможность установить адрес API конвертации 2 | - добавлена возможность установить курс конвертации -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/22.txt: -------------------------------------------------------------------------------- 1 | - добавлена возможность установить адрес API конвертации 2 | - добавлена возможность установить курс конвертации -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/23.txt: -------------------------------------------------------------------------------- 1 | - добавлена возможность установить адрес API конвертации 2 | - добавлена возможность установить курс конвертации -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/24.txt: -------------------------------------------------------------------------------- 1 | - добавлена возможность установить адрес API конвертации 2 | - добавлена возможность установить курс конвертации 3 | - добавлена поддержка кнопки "назад" на Android -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/25.txt: -------------------------------------------------------------------------------- 1 | - добавлена возможность установить адрес API конвертации 2 | - добавлена возможность установить курс конвертации 3 | - добавлена поддержка кнопки "назад" на Android 4 | - удалена реферальная ссылка на nonkyc -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/26.txt: -------------------------------------------------------------------------------- 1 | - добавлена возможность установить адрес API конвертации 2 | - добавлена возможность установить курс конвертации 3 | - добавлена поддержка кнопки "назад" на Android 4 | - удалена реферальная ссылка на nonkyc -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/27.txt: -------------------------------------------------------------------------------- 1 | - API курса изменен на veilproject.org 2 | - обновлены зависимости -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/28.txt: -------------------------------------------------------------------------------- 1 | - обновлен flutter -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/29.txt: -------------------------------------------------------------------------------- 1 | - обновлен flutter -------------------------------------------------------------------------------- /metadata/ru-RU/changelogs/9.txt: -------------------------------------------------------------------------------- 1 | - добавлены новые языки: Испанский, Эсперанто 2 | - добавлена возможность выбирать язык в настройках 3 | - добавлена темная тема 4 | - добавлен выбор доступных нод в настройках 5 | - кнопки "веб-сайт" и "обозреватель" поменяны местами -------------------------------------------------------------------------------- /metadata/ru-RU/full_description.txt: -------------------------------------------------------------------------------- 1 | Veil - это анонимный эквивалент наличных денег, где конфиденциальность является приоритетом. Загружайте кошелек и присоединяйтесь к экосистеме veil. 2 | 3 | КОНФИДЕНЦИАЛЬНОСТЬ ПО УМОЛЧАНИЮ 4 | 5 | Конфиденциальность не должна быть опциональной. Veil стремится сделать конфиденциальность наиболее удобным выбором. 6 | 7 | СТЭЙКИНГ 8 | 9 | Держа Veil, наши пользователи не только вносят вклад в безопасность сети, но также получают вознаграждение за стейкинг — анонимно! 10 | 11 | ЧЕСТНЫЙ ЗАПУСК 12 | 13 | Никакого ICO. Никакого премайна. Блокчейн Veil защищен с помощью Proof-of-Work и Proof-of-Stake, чтобы объединить безопасность и справедливое распределение. 14 | 15 | ОРИЕНТИРОВАННОСТЬ НА ПОЛЬЗОВАТЕЛЯ 16 | 17 | Veil стремится стать одним из самых удобных для пользователя кошельков в сфере криптовалют. 18 | 19 | 20 | 21 | Сайт проекта: 22 | https://veil-project.com 23 | Исходный код: 24 | https://github.com/steel97/veil_wallet 25 | Discord: 26 | https://discord.veil-project.com -------------------------------------------------------------------------------- /metadata/ru-RU/images/featureGraphic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/ru-RU/images/featureGraphic.png -------------------------------------------------------------------------------- /metadata/ru-RU/images/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/ru-RU/images/icon.png -------------------------------------------------------------------------------- /metadata/ru-RU/images/phoneScreenshots/veil_screen_ru_1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/ru-RU/images/phoneScreenshots/veil_screen_ru_1.jpg -------------------------------------------------------------------------------- /metadata/ru-RU/images/phoneScreenshots/veil_screen_ru_2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/ru-RU/images/phoneScreenshots/veil_screen_ru_2.jpg -------------------------------------------------------------------------------- /metadata/ru-RU/images/phoneScreenshots/veil_screen_ru_3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/ru-RU/images/phoneScreenshots/veil_screen_ru_3.jpg -------------------------------------------------------------------------------- /metadata/ru-RU/images/phoneScreenshots/veil_screen_ru_4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/metadata/ru-RU/images/phoneScreenshots/veil_screen_ru_4.jpg -------------------------------------------------------------------------------- /metadata/ru-RU/short_description.txt: -------------------------------------------------------------------------------- 1 | Крипто-кошелек VEIL - анонимные переводы, конфиденциальность по умолчанию -------------------------------------------------------------------------------- /metadata/ru-RU/title.txt: -------------------------------------------------------------------------------- 1 | Veil - приватный криптокошелек -------------------------------------------------------------------------------- /pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: veil_wallet 2 | description: Veil light wallet made with flutter 3 | publish_to: 'none' # Remove this line if you wish to publish to pub.dev 4 | version: 1.0.23+29 5 | 6 | environment: 7 | sdk: '>=3.3.0 <4.0.0' 8 | 9 | dependencies: 10 | flutter: 11 | sdk: flutter 12 | flutter_localizations: 13 | sdk: flutter 14 | intl: any 15 | veil_light_plugin: 16 | path: ./submodules/veil_light_plugin 17 | window_size: 18 | git: 19 | url: https://github.com/google/flutter-desktop-embedding 20 | path: plugins/window_size 21 | extended_text: ^14.1.0 22 | file_picker: ^8.1.3 23 | flutter_secure_storage: ^9.2.2 24 | local_auth: ^2.3.0 25 | url_launcher: ^6.3.1 26 | provider: ^6.1.2 27 | pretty_qr_code: ^3.3.0 28 | screenshot: ^3.0.0 29 | share_plus: ^10.1.0 30 | qr_code_scanner: ^1.0.1 31 | http: ^1.2.2 32 | convert: ^3.1.2 33 | pointycastle: ^3.9.1 34 | path_provider: ^2.1.4 35 | package_info_plus: ^8.1.0 36 | shared_preferences: ^2.3.2 37 | l10n_esperanto: ^2.0.11 38 | 39 | dev_dependencies: 40 | flutter_test: 41 | sdk: flutter 42 | flutter_lints: ^5.0.0 43 | flutter_launcher_icons: ^0.14.1 44 | 45 | flutter: 46 | uses-material-design: true 47 | generate: true 48 | assets: 49 | - assets/images/logo.png 50 | - assets/images/logo_full.png 51 | - assets/images/logo_full_light.png 52 | - assets/images/pattern.png 53 | - assets/res/legal.txt 54 | 55 | flutter_native_splash: 56 | android_disable_fullscreen: true -------------------------------------------------------------------------------- /test/a11y_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_test/flutter_test.dart'; 3 | import 'package:flutter_gen/gen_l10n/app_localizations.dart'; 4 | import 'package:veil_wallet/src/layouts/mobile/back_layout.dart'; 5 | import 'package:veil_wallet/src/states/states_bridge.dart'; 6 | 7 | void main() { 8 | testWidgets('Test accessibility', (WidgetTester tester) async { 9 | final SemanticsHandle handle = tester.ensureSemantics(); 10 | 11 | var lightColorScheme = ColorScheme.fromSeed( 12 | seedColor: Colors.blue, 13 | primary: const Color.fromARGB(255, 35, 89, 247), 14 | surface: const Color.fromARGB(255, 233, 239, 247), 15 | ); 16 | await tester.pumpWidget(MaterialApp( 17 | debugShowCheckedModeBanner: false, 18 | onGenerateTitle: (context) => AppLocalizations.of(context)!.title, 19 | localizationsDelegates: AppLocalizations.localizationsDelegates, 20 | supportedLocales: AppLocalizations.supportedLocales, 21 | theme: ThemeData( 22 | colorScheme: lightColorScheme, 23 | useMaterial3: true, 24 | ), 25 | navigatorKey: StatesBridge.navigatorKey, 26 | home: const BackLayout( 27 | title: 'test', 28 | child: Text('test'), 29 | ))); 30 | 31 | // Checks that tappable nodes have a minimum size of 48 by 48 pixels 32 | // for Android. 33 | await expectLater(tester, meetsGuideline(androidTapTargetGuideline)); 34 | 35 | // Checks that tappable nodes have a minimum size of 44 by 44 pixels 36 | // for iOS. 37 | await expectLater(tester, meetsGuideline(iOSTapTargetGuideline)); 38 | 39 | // Checks that touch targets with a tap or long press action are labeled. 40 | await expectLater(tester, meetsGuideline(labeledTapTargetGuideline)); 41 | 42 | // Checks whether semantic nodes meet the minimum text contrast levels. 43 | // The recommended text contrast is 3:1 for larger text 44 | // (18 point and above regular). 45 | await expectLater(tester, meetsGuideline(textContrastGuideline)); 46 | handle.dispose(); 47 | }); 48 | } 49 | -------------------------------------------------------------------------------- /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:veil_wallet/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 WalletApp()); 17 | 18 | // TO-DO 19 | /* 20 | // Verify that our counter starts at 0. 21 | expect(find.text('0'), findsOneWidget); 22 | expect(find.text('1'), findsNothing); 23 | 24 | // Tap the '+' icon and trigger a frame. 25 | await tester.tap(find.byIcon(Icons.add)); 26 | await tester.pump(); 27 | 28 | // Verify that our counter has incremented. 29 | expect(find.text('0'), findsNothing); 30 | expect(find.text('1'), findsOneWidget); 31 | */ 32 | }); 33 | } 34 | -------------------------------------------------------------------------------- /veil_wallet.code-workspace: -------------------------------------------------------------------------------- 1 | { 2 | "folders": [ 3 | { 4 | "path": "." 5 | } 6 | ], 7 | "settings": {}, 8 | "extensions": { 9 | "recommendations": [ 10 | "google.arb-editor", 11 | "dart-code.dart-code", 12 | "dart-code.flutter" 13 | ] 14 | } 15 | } -------------------------------------------------------------------------------- /web/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/web/favicon.png -------------------------------------------------------------------------------- /web/icons/Icon-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/web/icons/Icon-192.png -------------------------------------------------------------------------------- /web/icons/Icon-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/web/icons/Icon-512.png -------------------------------------------------------------------------------- /web/icons/Icon-maskable-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/web/icons/Icon-maskable-192.png -------------------------------------------------------------------------------- /web/icons/Icon-maskable-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/web/icons/Icon-maskable-512.png -------------------------------------------------------------------------------- /web/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | veil_wallet 33 | 34 | 35 | 39 | 40 | 41 | 42 | 43 | 58 | 59 | 60 | -------------------------------------------------------------------------------- /web/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "veil_wallet", 3 | "short_name": "veil_wallet", 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 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /windows/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Project-level configuration. 2 | cmake_minimum_required(VERSION 3.14) 3 | project(veil_wallet LANGUAGES CXX) 4 | 5 | # The name of the executable created for the application. Change this to change 6 | # the on-disk name of your application. 7 | set(BINARY_NAME "veil-wallet") 8 | 9 | # Explicitly opt in to modern CMake behaviors to avoid warnings with recent 10 | # versions of CMake. 11 | cmake_policy(VERSION 3.14...3.25) 12 | 13 | # Define build configuration option. 14 | get_property(IS_MULTICONFIG GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG) 15 | if(IS_MULTICONFIG) 16 | set(CMAKE_CONFIGURATION_TYPES "Debug;Profile;Release" 17 | CACHE STRING "" FORCE) 18 | else() 19 | if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) 20 | set(CMAKE_BUILD_TYPE "Debug" CACHE 21 | STRING "Flutter build mode" FORCE) 22 | set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS 23 | "Debug" "Profile" "Release") 24 | endif() 25 | endif() 26 | # Define settings for the Profile build mode. 27 | set(CMAKE_EXE_LINKER_FLAGS_PROFILE "${CMAKE_EXE_LINKER_FLAGS_RELEASE}") 28 | set(CMAKE_SHARED_LINKER_FLAGS_PROFILE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE}") 29 | set(CMAKE_C_FLAGS_PROFILE "${CMAKE_C_FLAGS_RELEASE}") 30 | set(CMAKE_CXX_FLAGS_PROFILE "${CMAKE_CXX_FLAGS_RELEASE}") 31 | 32 | # Use Unicode for all projects. 33 | add_definitions(-DUNICODE -D_UNICODE) 34 | 35 | # Compilation settings that should be applied to most targets. 36 | # 37 | # Be cautious about adding new options here, as plugins use this function by 38 | # default. In most cases, you should add new options to specific targets instead 39 | # of modifying this function. 40 | function(APPLY_STANDARD_SETTINGS TARGET) 41 | target_compile_features(${TARGET} PUBLIC cxx_std_17) 42 | target_compile_options(${TARGET} PRIVATE /W4 /WX /wd"4100") 43 | target_compile_options(${TARGET} PRIVATE /EHsc) 44 | target_compile_definitions(${TARGET} PRIVATE "_HAS_EXCEPTIONS=0") 45 | target_compile_definitions(${TARGET} PRIVATE "$<$:_DEBUG>") 46 | endfunction() 47 | 48 | # Flutter library and tool build rules. 49 | set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter") 50 | add_subdirectory(${FLUTTER_MANAGED_DIR}) 51 | 52 | # Application build; see runner/CMakeLists.txt. 53 | add_subdirectory("runner") 54 | 55 | 56 | # Generated plugin build rules, which manage building the plugins and adding 57 | # them to the application. 58 | include(flutter/generated_plugins.cmake) 59 | 60 | 61 | # === Installation === 62 | # Support files are copied into place next to the executable, so that it can 63 | # run in place. This is done instead of making a separate bundle (as on Linux) 64 | # so that building and running from within Visual Studio will work. 65 | set(BUILD_BUNDLE_DIR "$") 66 | # Make the "install" step default, as it's required to run. 67 | set(CMAKE_VS_INCLUDE_INSTALL_TO_DEFAULT_BUILD 1) 68 | if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) 69 | set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE) 70 | endif() 71 | 72 | set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data") 73 | set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}") 74 | 75 | install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}" 76 | COMPONENT Runtime) 77 | 78 | install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" 79 | COMPONENT Runtime) 80 | 81 | install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" 82 | COMPONENT Runtime) 83 | 84 | if(PLUGIN_BUNDLED_LIBRARIES) 85 | install(FILES "${PLUGIN_BUNDLED_LIBRARIES}" 86 | DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" 87 | COMPONENT Runtime) 88 | endif() 89 | 90 | # Fully re-copy the assets directory on each build to avoid having stale files 91 | # from a previous install. 92 | set(FLUTTER_ASSET_DIR_NAME "flutter_assets") 93 | install(CODE " 94 | file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\") 95 | " COMPONENT Runtime) 96 | install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}" 97 | DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime) 98 | 99 | # Install the AOT library on non-Debug builds only. 100 | install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" 101 | CONFIGURATIONS Profile;Release 102 | COMPONENT Runtime) 103 | -------------------------------------------------------------------------------- /windows/flutter/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # This file controls Flutter-level build steps. It should not be edited. 2 | cmake_minimum_required(VERSION 3.14) 3 | 4 | set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral") 5 | 6 | # Configuration provided via flutter tool. 7 | include(${EPHEMERAL_DIR}/generated_config.cmake) 8 | 9 | # TODO: Move the rest of this into files in ephemeral. See 10 | # https://github.com/flutter/flutter/issues/57146. 11 | set(WRAPPER_ROOT "${EPHEMERAL_DIR}/cpp_client_wrapper") 12 | 13 | # Set fallback configurations for older versions of the flutter tool. 14 | if (NOT DEFINED FLUTTER_TARGET_PLATFORM) 15 | set(FLUTTER_TARGET_PLATFORM "windows-x64") 16 | endif() 17 | 18 | # === Flutter Library === 19 | set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/flutter_windows.dll") 20 | 21 | # Published to parent scope for install step. 22 | set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE) 23 | set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE) 24 | set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE) 25 | set(AOT_LIBRARY "${PROJECT_DIR}/build/windows/app.so" PARENT_SCOPE) 26 | 27 | list(APPEND FLUTTER_LIBRARY_HEADERS 28 | "flutter_export.h" 29 | "flutter_windows.h" 30 | "flutter_messenger.h" 31 | "flutter_plugin_registrar.h" 32 | "flutter_texture_registrar.h" 33 | ) 34 | list(TRANSFORM FLUTTER_LIBRARY_HEADERS PREPEND "${EPHEMERAL_DIR}/") 35 | add_library(flutter INTERFACE) 36 | target_include_directories(flutter INTERFACE 37 | "${EPHEMERAL_DIR}" 38 | ) 39 | target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}.lib") 40 | add_dependencies(flutter flutter_assemble) 41 | 42 | # === Wrapper === 43 | list(APPEND CPP_WRAPPER_SOURCES_CORE 44 | "core_implementations.cc" 45 | "standard_codec.cc" 46 | ) 47 | list(TRANSFORM CPP_WRAPPER_SOURCES_CORE PREPEND "${WRAPPER_ROOT}/") 48 | list(APPEND CPP_WRAPPER_SOURCES_PLUGIN 49 | "plugin_registrar.cc" 50 | ) 51 | list(TRANSFORM CPP_WRAPPER_SOURCES_PLUGIN PREPEND "${WRAPPER_ROOT}/") 52 | list(APPEND CPP_WRAPPER_SOURCES_APP 53 | "flutter_engine.cc" 54 | "flutter_view_controller.cc" 55 | ) 56 | list(TRANSFORM CPP_WRAPPER_SOURCES_APP PREPEND "${WRAPPER_ROOT}/") 57 | 58 | # Wrapper sources needed for a plugin. 59 | add_library(flutter_wrapper_plugin STATIC 60 | ${CPP_WRAPPER_SOURCES_CORE} 61 | ${CPP_WRAPPER_SOURCES_PLUGIN} 62 | ) 63 | apply_standard_settings(flutter_wrapper_plugin) 64 | set_target_properties(flutter_wrapper_plugin PROPERTIES 65 | POSITION_INDEPENDENT_CODE ON) 66 | set_target_properties(flutter_wrapper_plugin PROPERTIES 67 | CXX_VISIBILITY_PRESET hidden) 68 | target_link_libraries(flutter_wrapper_plugin PUBLIC flutter) 69 | target_include_directories(flutter_wrapper_plugin PUBLIC 70 | "${WRAPPER_ROOT}/include" 71 | ) 72 | add_dependencies(flutter_wrapper_plugin flutter_assemble) 73 | 74 | # Wrapper sources needed for the runner. 75 | add_library(flutter_wrapper_app STATIC 76 | ${CPP_WRAPPER_SOURCES_CORE} 77 | ${CPP_WRAPPER_SOURCES_APP} 78 | ) 79 | apply_standard_settings(flutter_wrapper_app) 80 | target_link_libraries(flutter_wrapper_app PUBLIC flutter) 81 | target_include_directories(flutter_wrapper_app PUBLIC 82 | "${WRAPPER_ROOT}/include" 83 | ) 84 | add_dependencies(flutter_wrapper_app flutter_assemble) 85 | 86 | # === Flutter tool backend === 87 | # _phony_ is a non-existent file to force this command to run every time, 88 | # since currently there's no way to get a full input/output list from the 89 | # flutter tool. 90 | set(PHONY_OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/_phony_") 91 | set_source_files_properties("${PHONY_OUTPUT}" PROPERTIES SYMBOLIC TRUE) 92 | add_custom_command( 93 | OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS} 94 | ${CPP_WRAPPER_SOURCES_CORE} ${CPP_WRAPPER_SOURCES_PLUGIN} 95 | ${CPP_WRAPPER_SOURCES_APP} 96 | ${PHONY_OUTPUT} 97 | COMMAND ${CMAKE_COMMAND} -E env 98 | ${FLUTTER_TOOL_ENVIRONMENT} 99 | "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.bat" 100 | ${FLUTTER_TARGET_PLATFORM} $ 101 | VERBATIM 102 | ) 103 | add_custom_target(flutter_assemble DEPENDS 104 | "${FLUTTER_LIBRARY}" 105 | ${FLUTTER_LIBRARY_HEADERS} 106 | ${CPP_WRAPPER_SOURCES_CORE} 107 | ${CPP_WRAPPER_SOURCES_PLUGIN} 108 | ${CPP_WRAPPER_SOURCES_APP} 109 | ) 110 | -------------------------------------------------------------------------------- /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 | FlutterSecureStorageWindowsPluginRegisterWithRegistrar( 17 | registry->GetRegistrarForPlugin("FlutterSecureStorageWindowsPlugin")); 18 | LocalAuthPluginRegisterWithRegistrar( 19 | registry->GetRegistrarForPlugin("LocalAuthPlugin")); 20 | SharePlusWindowsPluginCApiRegisterWithRegistrar( 21 | registry->GetRegistrarForPlugin("SharePlusWindowsPluginCApi")); 22 | UrlLauncherWindowsRegisterWithRegistrar( 23 | registry->GetRegistrarForPlugin("UrlLauncherWindows")); 24 | WindowSizePluginRegisterWithRegistrar( 25 | registry->GetRegistrarForPlugin("WindowSizePlugin")); 26 | } 27 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /windows/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | flutter_secure_storage_windows 7 | local_auth_windows 8 | share_plus 9 | url_launcher_windows 10 | window_size 11 | ) 12 | 13 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 14 | veil_light_plugin 15 | ) 16 | 17 | set(PLUGIN_BUNDLED_LIBRARIES) 18 | 19 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 20 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin}) 21 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 22 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 23 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 24 | endforeach(plugin) 25 | 26 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 27 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin}) 28 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 29 | endforeach(ffi_plugin) 30 | -------------------------------------------------------------------------------- /windows/packaging/exe/make_config.yaml: -------------------------------------------------------------------------------- 1 | app_id: 73655643-E26D-4C88-984F-E6AD5C0169AC 2 | publisher: Ivan Yurkov 3 | publisher_url: https://veilproject.org 4 | display_name: Veil Wallet 5 | create_desktop_icon: true 6 | # See: https://jrsoftware.org/ishelp/index.php?topic=setup_defaultdirname 7 | install_dir_name: "{autopf}\\Veil Wallet" 8 | locales: 9 | - en 10 | - ru -------------------------------------------------------------------------------- /windows/runner/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.14) 2 | project(runner LANGUAGES CXX) 3 | 4 | # Define the application target. To change its name, change BINARY_NAME in the 5 | # top-level CMakeLists.txt, not the value here, or `flutter run` will no longer 6 | # work. 7 | # 8 | # Any new source files that you add to the application should be added here. 9 | add_executable(${BINARY_NAME} WIN32 10 | "flutter_window.cpp" 11 | "main.cpp" 12 | "utils.cpp" 13 | "win32_window.cpp" 14 | "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc" 15 | "Runner.rc" 16 | "runner.exe.manifest" 17 | ) 18 | 19 | # Apply the standard set of build settings. This can be removed for applications 20 | # that need different build settings. 21 | apply_standard_settings(${BINARY_NAME}) 22 | 23 | # Add preprocessor definitions for the build version. 24 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION=\"${FLUTTER_VERSION}\"") 25 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MAJOR=${FLUTTER_VERSION_MAJOR}") 26 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MINOR=${FLUTTER_VERSION_MINOR}") 27 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_PATCH=${FLUTTER_VERSION_PATCH}") 28 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_BUILD=${FLUTTER_VERSION_BUILD}") 29 | 30 | # Disable Windows macros that collide with C++ standard library functions. 31 | target_compile_definitions(${BINARY_NAME} PRIVATE "NOMINMAX") 32 | 33 | # Add dependency libraries and include directories. Add any application-specific 34 | # dependencies here. 35 | target_link_libraries(${BINARY_NAME} PRIVATE flutter flutter_wrapper_app) 36 | target_link_libraries(${BINARY_NAME} PRIVATE "dwmapi.lib") 37 | target_include_directories(${BINARY_NAME} PRIVATE "${CMAKE_SOURCE_DIR}") 38 | 39 | # Run the Flutter tool portions of the build. This must not be removed. 40 | add_dependencies(${BINARY_NAME} flutter_assemble) 41 | -------------------------------------------------------------------------------- /windows/runner/Runner.rc: -------------------------------------------------------------------------------- 1 | // Microsoft Visual C++ generated resource script. 2 | // 3 | #pragma code_page(65001) 4 | #include "resource.h" 5 | 6 | #define APSTUDIO_READONLY_SYMBOLS 7 | ///////////////////////////////////////////////////////////////////////////// 8 | // 9 | // Generated from the TEXTINCLUDE 2 resource. 10 | // 11 | #include "winres.h" 12 | 13 | ///////////////////////////////////////////////////////////////////////////// 14 | #undef APSTUDIO_READONLY_SYMBOLS 15 | 16 | ///////////////////////////////////////////////////////////////////////////// 17 | // English (United States) resources 18 | 19 | #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) 20 | LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US 21 | 22 | #ifdef APSTUDIO_INVOKED 23 | ///////////////////////////////////////////////////////////////////////////// 24 | // 25 | // TEXTINCLUDE 26 | // 27 | 28 | 1 TEXTINCLUDE 29 | BEGIN 30 | "resource.h\0" 31 | END 32 | 33 | 2 TEXTINCLUDE 34 | BEGIN 35 | "#include ""winres.h""\r\n" 36 | "\0" 37 | END 38 | 39 | 3 TEXTINCLUDE 40 | BEGIN 41 | "\r\n" 42 | "\0" 43 | END 44 | 45 | #endif // APSTUDIO_INVOKED 46 | 47 | 48 | ///////////////////////////////////////////////////////////////////////////// 49 | // 50 | // Icon 51 | // 52 | 53 | // Icon with lowest ID value placed first to ensure application icon 54 | // remains consistent on all systems. 55 | IDI_APP_ICON ICON "resources\\app_icon.ico" 56 | 57 | 58 | ///////////////////////////////////////////////////////////////////////////// 59 | // 60 | // Version 61 | // 62 | 63 | #if defined(FLUTTER_VERSION_MAJOR) && defined(FLUTTER_VERSION_MINOR) && defined(FLUTTER_VERSION_PATCH) && defined(FLUTTER_VERSION_BUILD) 64 | #define VERSION_AS_NUMBER FLUTTER_VERSION_MAJOR,FLUTTER_VERSION_MINOR,FLUTTER_VERSION_PATCH,FLUTTER_VERSION_BUILD 65 | #else 66 | #define VERSION_AS_NUMBER 1,0,0,0 67 | #endif 68 | 69 | #if defined(FLUTTER_VERSION) 70 | #define VERSION_AS_STRING FLUTTER_VERSION 71 | #else 72 | #define VERSION_AS_STRING "1.0.0" 73 | #endif 74 | 75 | VS_VERSION_INFO VERSIONINFO 76 | FILEVERSION VERSION_AS_NUMBER 77 | PRODUCTVERSION VERSION_AS_NUMBER 78 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 79 | #ifdef _DEBUG 80 | FILEFLAGS VS_FF_DEBUG 81 | #else 82 | FILEFLAGS 0x0L 83 | #endif 84 | FILEOS VOS__WINDOWS32 85 | FILETYPE VFT_APP 86 | FILESUBTYPE 0x0L 87 | BEGIN 88 | BLOCK "StringFileInfo" 89 | BEGIN 90 | BLOCK "040904e4" 91 | BEGIN 92 | VALUE "CompanyName", "org.veilproject" "\0" 93 | VALUE "FileDescription", "veil-wallet" "\0" 94 | VALUE "FileVersion", VERSION_AS_STRING "\0" 95 | VALUE "InternalName", "veil_wallet" "\0" 96 | VALUE "LegalCopyright", "Copyright (C) 2023 veil-project. All rights reserved." "\0" 97 | VALUE "OriginalFilename", "veil-wallet.exe" "\0" 98 | VALUE "ProductName", "veil-wallet" "\0" 99 | VALUE "ProductVersion", VERSION_AS_STRING "\0" 100 | END 101 | END 102 | BLOCK "VarFileInfo" 103 | BEGIN 104 | VALUE "Translation", 0x409, 1252 105 | END 106 | END 107 | 108 | #endif // English (United States) resources 109 | ///////////////////////////////////////////////////////////////////////////// 110 | 111 | 112 | 113 | #ifndef APSTUDIO_INVOKED 114 | ///////////////////////////////////////////////////////////////////////////// 115 | // 116 | // Generated from the TEXTINCLUDE 3 resource. 117 | // 118 | 119 | 120 | ///////////////////////////////////////////////////////////////////////////// 121 | #endif // not APSTUDIO_INVOKED 122 | -------------------------------------------------------------------------------- /windows/runner/flutter_window.cpp: -------------------------------------------------------------------------------- 1 | #include "flutter_window.h" 2 | 3 | #include 4 | 5 | #include "flutter/generated_plugin_registrant.h" 6 | 7 | FlutterWindow::FlutterWindow(const flutter::DartProject& project) 8 | : project_(project) {} 9 | 10 | FlutterWindow::~FlutterWindow() {} 11 | 12 | bool FlutterWindow::OnCreate() { 13 | if (!Win32Window::OnCreate()) { 14 | return false; 15 | } 16 | 17 | RECT frame = GetClientArea(); 18 | 19 | // The size here must match the window dimensions to avoid unnecessary surface 20 | // creation / destruction in the startup path. 21 | flutter_controller_ = std::make_unique( 22 | frame.right - frame.left, frame.bottom - frame.top, project_); 23 | // Ensure that basic setup of the controller was successful. 24 | if (!flutter_controller_->engine() || !flutter_controller_->view()) { 25 | return false; 26 | } 27 | RegisterPlugins(flutter_controller_->engine()); 28 | SetChildContent(flutter_controller_->view()->GetNativeWindow()); 29 | 30 | flutter_controller_->engine()->SetNextFrameCallback([&]() { 31 | this->Show(); 32 | }); 33 | 34 | // Flutter can complete the first frame before the "show window" callback is 35 | // registered. The following call ensures a frame is pending to ensure the 36 | // window is shown. It is a no-op if the first frame hasn't completed yet. 37 | flutter_controller_->ForceRedraw(); 38 | 39 | return true; 40 | } 41 | 42 | void FlutterWindow::OnDestroy() { 43 | if (flutter_controller_) { 44 | flutter_controller_ = nullptr; 45 | } 46 | 47 | Win32Window::OnDestroy(); 48 | } 49 | 50 | LRESULT 51 | FlutterWindow::MessageHandler(HWND hwnd, UINT const message, 52 | WPARAM const wparam, 53 | LPARAM const lparam) noexcept { 54 | // Give Flutter, including plugins, an opportunity to handle window messages. 55 | if (flutter_controller_) { 56 | std::optional result = 57 | flutter_controller_->HandleTopLevelWindowProc(hwnd, message, wparam, 58 | lparam); 59 | if (result) { 60 | return *result; 61 | } 62 | } 63 | 64 | switch (message) { 65 | case WM_FONTCHANGE: 66 | flutter_controller_->engine()->ReloadSystemFonts(); 67 | break; 68 | } 69 | 70 | return Win32Window::MessageHandler(hwnd, message, wparam, lparam); 71 | } 72 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /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"veil_wallet", 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 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /windows/runner/resources/app_icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/steel97/veil_wallet/b9e532552024461b148308d35787adef97cf0ec8/windows/runner/resources/app_icon.ico -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /windows/runner/utils.cpp: -------------------------------------------------------------------------------- 1 | #include "utils.h" 2 | 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | #include 9 | 10 | void CreateAndAttachConsole() { 11 | if (::AllocConsole()) { 12 | FILE *unused; 13 | if (freopen_s(&unused, "CONOUT$", "w", stdout)) { 14 | _dup2(_fileno(stdout), 1); 15 | } 16 | if (freopen_s(&unused, "CONOUT$", "w", stderr)) { 17 | _dup2(_fileno(stdout), 2); 18 | } 19 | std::ios::sync_with_stdio(); 20 | FlutterDesktopResyncOutputStreams(); 21 | } 22 | } 23 | 24 | std::vector GetCommandLineArguments() { 25 | // Convert the UTF-16 command line arguments to UTF-8 for the Engine to use. 26 | int argc; 27 | wchar_t** argv = ::CommandLineToArgvW(::GetCommandLineW(), &argc); 28 | if (argv == nullptr) { 29 | return std::vector(); 30 | } 31 | 32 | std::vector command_line_arguments; 33 | 34 | // Skip the first argument as it's the binary name. 35 | for (int i = 1; i < argc; i++) { 36 | command_line_arguments.push_back(Utf8FromUtf16(argv[i])); 37 | } 38 | 39 | ::LocalFree(argv); 40 | 41 | return command_line_arguments; 42 | } 43 | 44 | std::string Utf8FromUtf16(const wchar_t* utf16_string) { 45 | if (utf16_string == nullptr) { 46 | return std::string(); 47 | } 48 | int target_length = ::WideCharToMultiByte( 49 | CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string, 50 | -1, nullptr, 0, nullptr, nullptr) 51 | -1; // remove the trailing null character 52 | int input_length = (int)wcslen(utf16_string); 53 | std::string utf8_string; 54 | if (target_length <= 0 || target_length > utf8_string.max_size()) { 55 | return utf8_string; 56 | } 57 | utf8_string.resize(target_length); 58 | int converted_length = ::WideCharToMultiByte( 59 | CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string, 60 | input_length, utf8_string.data(), target_length, nullptr, nullptr); 61 | if (converted_length == 0) { 62 | return std::string(); 63 | } 64 | return utf8_string; 65 | } 66 | -------------------------------------------------------------------------------- /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 | -------------------------------------------------------------------------------- /windows/runner/win32_window.h: -------------------------------------------------------------------------------- 1 | #ifndef RUNNER_WIN32_WINDOW_H_ 2 | #define RUNNER_WIN32_WINDOW_H_ 3 | 4 | #include 5 | 6 | #include 7 | #include 8 | #include 9 | 10 | // A class abstraction for a high DPI-aware Win32 Window. Intended to be 11 | // inherited from by classes that wish to specialize with custom 12 | // rendering and input handling 13 | class Win32Window { 14 | public: 15 | struct Point { 16 | unsigned int x; 17 | unsigned int y; 18 | Point(unsigned int x, unsigned int y) : x(x), y(y) {} 19 | }; 20 | 21 | struct Size { 22 | unsigned int width; 23 | unsigned int height; 24 | Size(unsigned int width, unsigned int height) 25 | : width(width), height(height) {} 26 | }; 27 | 28 | Win32Window(); 29 | virtual ~Win32Window(); 30 | 31 | // Creates a win32 window with |title| that is positioned and sized using 32 | // |origin| and |size|. New windows are created on the default monitor. Window 33 | // sizes are specified to the OS in physical pixels, hence to ensure a 34 | // consistent size this function will scale the inputted width and height as 35 | // as appropriate for the default monitor. The window is invisible until 36 | // |Show| is called. Returns true if the window was created successfully. 37 | bool Create(const std::wstring& title, const Point& origin, const Size& size); 38 | 39 | // Show the current window. Returns true if the window was successfully shown. 40 | bool Show(); 41 | 42 | // Release OS resources associated with window. 43 | void Destroy(); 44 | 45 | // Inserts |content| into the window tree. 46 | void SetChildContent(HWND content); 47 | 48 | // Returns the backing Window handle to enable clients to set icon and other 49 | // window properties. Returns nullptr if the window has been destroyed. 50 | HWND GetHandle(); 51 | 52 | // If true, closing this window will quit the application. 53 | void SetQuitOnClose(bool quit_on_close); 54 | 55 | // Return a RECT representing the bounds of the current client area. 56 | RECT GetClientArea(); 57 | 58 | protected: 59 | // Processes and route salient window messages for mouse handling, 60 | // size change and DPI. Delegates handling of these to member overloads that 61 | // inheriting classes can handle. 62 | virtual LRESULT MessageHandler(HWND window, 63 | UINT const message, 64 | WPARAM const wparam, 65 | LPARAM const lparam) noexcept; 66 | 67 | // Called when CreateAndShow is called, allowing subclass window-related 68 | // setup. Subclasses should return false if setup fails. 69 | virtual bool OnCreate(); 70 | 71 | // Called when Destroy is called. 72 | virtual void OnDestroy(); 73 | 74 | private: 75 | friend class WindowClassRegistrar; 76 | 77 | // OS callback called by message pump. Handles the WM_NCCREATE message which 78 | // is passed when the non-client area is being created and enables automatic 79 | // non-client DPI scaling so that the non-client area automatically 80 | // responds to changes in DPI. All other messages are handled by 81 | // MessageHandler. 82 | static LRESULT CALLBACK WndProc(HWND const window, 83 | UINT const message, 84 | WPARAM const wparam, 85 | LPARAM const lparam) noexcept; 86 | 87 | // Retrieves a class instance pointer for |window| 88 | static Win32Window* GetThisFromHandle(HWND const window) noexcept; 89 | 90 | // Update the window frame's theme to match the system theme. 91 | static void UpdateTheme(HWND const window); 92 | 93 | bool quit_on_close_ = false; 94 | 95 | // window handle for top level window. 96 | HWND window_handle_ = nullptr; 97 | 98 | // window handle for hosted content. 99 | HWND child_content_ = nullptr; 100 | }; 101 | 102 | #endif // RUNNER_WIN32_WINDOW_H_ 103 | --------------------------------------------------------------------------------