├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.md │ ├── new_question.it.yaml │ └── richiesta-nuova-feature.md └── workflows │ ├── check_file_domande.yml │ └── update_readme.yml ├── .gitignore ├── CONTRIBUTING.md ├── Domande RO con spiegazione.pdf ├── Domande.txt ├── LICENSE ├── Project Setup.md ├── README.md ├── app-desktop ├── .classpath ├── .project ├── .settings.json ├── .settings │ └── org.eclipse.jdt.core.prefs ├── Domande.txt ├── libs │ └── gson-2.8.9.jar ├── mods │ ├── .gitignore │ ├── application │ │ ├── theme_dark.css │ │ └── theme_light.css │ ├── gfx │ │ ├── debug.png │ │ ├── icon_back_dark.png │ │ ├── icon_back_light.png │ │ ├── icon_info_dark.png │ │ ├── icon_info_light.png │ │ ├── icon_next_dark.png │ │ ├── icon_next_light.png │ │ ├── icon_prev_dark.png │ │ ├── icon_prev_light.png │ │ ├── icon_questions_dark.png │ │ ├── icon_questions_light.png │ │ ├── icon_refresh_dark.png │ │ ├── icon_refresh_light.png │ │ ├── icon_settings_dark.png │ │ ├── icon_settings_light.png │ │ ├── icon_show_dark.png │ │ ├── icon_show_light.png │ │ ├── icon_star.png │ │ ├── icon_star_dark.png │ │ ├── icon_star_light.png │ │ ├── icon_timer_dark.png │ │ └── icon_timer_light.png │ └── gui │ │ ├── ViewMenu.fxml │ │ └── ViewQuiz.fxml ├── src │ ├── application │ │ ├── Main.java │ │ ├── theme_dark.css │ │ └── theme_light.css │ ├── gfx │ │ ├── debug.png │ │ ├── icon_back_dark.png │ │ ├── icon_back_light.png │ │ ├── icon_info_dark.png │ │ ├── icon_info_light.png │ │ ├── icon_next_dark.png │ │ ├── icon_next_light.png │ │ ├── icon_prev_dark.png │ │ ├── icon_prev_light.png │ │ ├── icon_questions_dark.png │ │ ├── icon_questions_light.png │ │ ├── icon_refresh_dark.png │ │ ├── icon_refresh_light.png │ │ ├── icon_settings_dark.png │ │ ├── icon_settings_light.png │ │ ├── icon_show_dark.png │ │ ├── icon_show_light.png │ │ ├── icon_star.png │ │ ├── icon_star_dark.png │ │ ├── icon_star_light.png │ │ ├── icon_timer_dark.png │ │ └── icon_timer_light.png │ ├── gui │ │ ├── ControllerMenu.java │ │ ├── ControllerQuiz.java │ │ ├── ViewMenu.fxml │ │ └── ViewQuiz.fxml │ ├── model │ │ ├── Answer.java │ │ ├── Question.java │ │ ├── Quiz.java │ │ └── Settings.java │ ├── module-info.java │ └── persistence │ │ ├── BadFileFormatException.java │ │ ├── IQuestionRepository.java │ │ ├── QuestionRepository.java │ │ └── SettingsManager.java └── test │ └── mods │ ├── .gitignore │ ├── application │ └── application.css │ └── gfx │ ├── icon_back.png │ ├── icon_info.png │ ├── icon_next.png │ ├── icon_prev.png │ ├── icon_qmark.png │ ├── icon_settings.png │ ├── icon_star.png │ └── icon_stop.png ├── app-mobile └── flutter_application │ ├── .gitignore │ ├── .metadata │ ├── .vscode │ └── launch.json │ ├── README.md │ ├── analysis_options.yaml │ ├── android │ ├── .gitignore │ ├── app │ │ ├── build.gradle.kts │ │ └── src │ │ │ ├── debug │ │ │ └── AndroidManifest.xml │ │ │ ├── main │ │ │ ├── AndroidManifest.xml │ │ │ ├── kotlin │ │ │ │ └── com │ │ │ │ │ └── example │ │ │ │ │ └── roquiz │ │ │ │ │ └── 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.kts │ ├── gradle.properties │ ├── gradle │ │ └── wrapper │ │ │ └── gradle-wrapper.properties │ └── settings.gradle.kts │ ├── assets │ ├── credits.json │ ├── domande.txt │ ├── icons │ │ └── logo.svg │ └── licenses.json │ ├── data │ └── Domande.txt │ ├── ios │ ├── .gitignore │ ├── Flutter │ │ ├── AppFrameworkInfo.plist │ │ ├── Debug.xcconfig │ │ └── Release.xcconfig │ ├── Runner.xcodeproj │ │ ├── project.pbxproj │ │ ├── project.xcworkspace │ │ │ ├── contents.xcworkspacedata │ │ │ └── xcshareddata │ │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ │ └── WorkspaceSettings.xcsettings │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ └── Runner.xcscheme │ ├── Runner.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ └── WorkspaceSettings.xcsettings │ ├── Runner │ │ ├── AppDelegate.swift │ │ ├── Assets.xcassets │ │ │ ├── AppIcon.appiconset │ │ │ │ ├── Contents.json │ │ │ │ ├── Icon-App-1024x1024@1x.png │ │ │ │ ├── Icon-App-20x20@1x.png │ │ │ │ ├── Icon-App-20x20@2x.png │ │ │ │ ├── Icon-App-20x20@3x.png │ │ │ │ ├── Icon-App-29x29@1x.png │ │ │ │ ├── Icon-App-29x29@2x.png │ │ │ │ ├── Icon-App-29x29@3x.png │ │ │ │ ├── Icon-App-40x40@1x.png │ │ │ │ ├── Icon-App-40x40@2x.png │ │ │ │ ├── Icon-App-40x40@3x.png │ │ │ │ ├── Icon-App-60x60@2x.png │ │ │ │ ├── Icon-App-60x60@3x.png │ │ │ │ ├── Icon-App-76x76@1x.png │ │ │ │ ├── Icon-App-76x76@2x.png │ │ │ │ └── Icon-App-83.5x83.5@2x.png │ │ │ └── LaunchImage.imageset │ │ │ │ ├── Contents.json │ │ │ │ ├── LaunchImage.png │ │ │ │ ├── LaunchImage@2x.png │ │ │ │ ├── LaunchImage@3x.png │ │ │ │ └── README.md │ │ ├── Base.lproj │ │ │ ├── LaunchScreen.storyboard │ │ │ └── Main.storyboard │ │ ├── Info.plist │ │ └── Runner-Bridging-Header.h │ └── RunnerTests │ │ └── RunnerTests.swift │ ├── lib │ ├── main.dart │ ├── model │ │ ├── Answer.dart │ │ ├── AppUpdater.dart │ │ ├── Contribution.dart │ │ ├── PlatformType.dart │ │ ├── Question.dart │ │ ├── Quiz.dart │ │ ├── Themes.dart │ │ ├── Utils.dart │ │ ├── license.dart │ │ └── palette.dart │ ├── persistence │ │ ├── QuestionRepository.dart │ │ └── Settings.dart │ ├── views │ │ ├── ViewCredits.dart │ │ ├── ViewEdit.dart │ │ ├── ViewInfo.dart │ │ ├── ViewLicenses.dart │ │ ├── ViewMenu.dart │ │ ├── ViewQuestions.dart │ │ ├── ViewQuiz.dart │ │ ├── ViewSettings.dart │ │ └── ViewTopics.dart │ └── widget │ │ ├── change_theme_button_widget.dart │ │ ├── confirmation_alert.dart │ │ ├── credits_widget.dart │ │ ├── icon_button_widget.dart │ │ ├── licenses_widget.dart │ │ ├── question_widget.dart │ │ ├── search_bar_widget.dart │ │ └── topics_widget.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 │ └── runner │ │ ├── CMakeLists.txt │ │ ├── main.cc │ │ ├── my_application.cc │ │ └── my_application.h │ ├── macos │ ├── .gitignore │ ├── Flutter │ │ ├── Flutter-Debug.xcconfig │ │ ├── Flutter-Release.xcconfig │ │ └── GeneratedPluginRegistrant.swift │ ├── Runner.xcodeproj │ │ ├── project.pbxproj │ │ ├── project.xcworkspace │ │ │ └── xcshareddata │ │ │ │ └── IDEWorkspaceChecks.plist │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ └── Runner.xcscheme │ ├── Runner.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ └── IDEWorkspaceChecks.plist │ ├── Runner │ │ ├── AppDelegate.swift │ │ ├── Assets.xcassets │ │ │ └── AppIcon.appiconset │ │ │ │ ├── Contents.json │ │ │ │ ├── app_icon_1024.png │ │ │ │ ├── app_icon_128.png │ │ │ │ ├── app_icon_16.png │ │ │ │ ├── app_icon_256.png │ │ │ │ ├── app_icon_32.png │ │ │ │ ├── app_icon_512.png │ │ │ │ └── app_icon_64.png │ │ ├── Base.lproj │ │ │ └── MainMenu.xib │ │ ├── Configs │ │ │ ├── AppInfo.xcconfig │ │ │ ├── Debug.xcconfig │ │ │ ├── Release.xcconfig │ │ │ └── Warnings.xcconfig │ │ ├── DebugProfile.entitlements │ │ ├── Info.plist │ │ ├── MainFlutterWindow.swift │ │ └── Release.entitlements │ └── RunnerTests │ │ └── RunnerTests.swift │ ├── pubspec.lock │ ├── pubspec.yaml │ ├── web │ ├── favicon.png │ ├── icons │ │ ├── Icon-192.png │ │ ├── Icon-512.png │ │ ├── Icon-maskable-192.png │ │ └── Icon-maskable-512.png │ ├── index.html │ └── manifest.json │ └── windows │ ├── .gitignore │ ├── CMakeLists.txt │ ├── flutter │ ├── CMakeLists.txt │ ├── generated_plugin_registrant.cc │ ├── generated_plugin_registrant.h │ └── generated_plugins.cmake │ └── runner │ ├── CMakeLists.txt │ ├── Runner.rc │ ├── flutter_window.cpp │ ├── flutter_window.h │ ├── main.cpp │ ├── resource.h │ ├── resources │ └── app_icon.ico │ ├── runner.exe.manifest │ ├── utils.cpp │ ├── utils.h │ ├── win32_window.cpp │ └── win32_window.h └── gfx ├── Download Build.png ├── Java Installation Guide ├── InstallJava (1).png ├── InstallJava (2).png ├── InstallJava (3).png ├── InstallJava (4).png ├── InstallJava (5).png ├── InstallJava (6).png ├── InstallJava (7).png └── InstallJava (8).png ├── Project Setup ├── Project Setup (1).png ├── Project Setup (2).png ├── Project Setup (3).png ├── Project Setup (4).png ├── Project Setup (5).png └── Project Setup (6).png ├── ROQuizDesktop.png ├── ROQuizDesktopResized.png ├── ROQuizMobile.png ├── ROQuizMobileOld.png ├── ROQuizMobileResized.png ├── Thumbnail.png ├── ThumbnailOld.png ├── ThumbnailOld2.png ├── [GIF] DesktopOld_EndQuiz.gif ├── [GIF] DesktopOld_Timeout.gif ├── [GIF] Desktop_PlayingAround.gif ├── [GIF] Desktop_QuizEnding.gif ├── [GIF] Mobile_Quiz.gif ├── [GIF] Mobile_Settings.gif └── [GIF] Mobile_TopicsQuestionList.gif /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Crea un report per aiutarci a migliorare l'app 4 | title: "[BUG]" 5 | labels: bug 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Descrivi il bug** 11 | Una descrizione chiara e coincisa di cosa consiste il bug. 12 | 13 | **Come riprodurre** 14 | Passaggi per riprodurre il bug: 15 | 1. Vai alla pagina '...' 16 | 2. Clicca sul bottone/controllo '....' 17 | 3. Scorri fino a '....' 18 | 4. Vedi l'errore 19 | 20 | **Comportamento previsto** 21 | Una descrizione chiara e coincisa di cosa ci si aspetterebbe che succeda. 22 | 23 | **Screenshot** 24 | Se possibile, includere screeshot del bug, o una registrazione dello schermo, per mostrare il problema. 25 | 26 | **Desktop:** 27 | - SO: [es: Windows] 28 | - Versione: [es: 1.6.0] 29 | 30 | **Mobile:** 31 | - (opzionale) Dispositivo: [es: Redmi Note 11] 32 | - (opzionale) SO: [es: Android 11] 33 | - Versione: [es: 1.6.0] 34 | 35 | **Informazioni aggiuntive** 36 | Aggiungi qui qualsiasi altro dettaglio di contesto che possa essere utile per risolvere il problema. 37 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/new_question.it.yaml: -------------------------------------------------------------------------------- 1 | name: Nuova Domanda ROQuiz 2 | description: Richiesta di aggiunta di una nuova domanda 3 | title: "[Nuova Domanda]: " 4 | labels: 5 | - new-question 6 | projects: 7 | - "mikyll/ROQuiz" 8 | assignees: 9 | - mikyll 10 | 11 | body: 12 | - type: markdown 13 | attributes: 14 | value: | 15 | **NB**: Sei un eroe. 16 | 17 | - type: dropdown 18 | id: topic-answer 19 | attributes: 20 | label: Argomento 21 | multiple: false 22 | options: 23 | - Programmazione Matematica 24 | - Programmazione Lineare 25 | - Algoritmo del Simplesso 26 | - Dualità 27 | - Programmazione Lineare Intera 28 | - Complessità 29 | default: 0 30 | validations: 31 | required: false 32 | 33 | - type: textarea 34 | id: question 35 | attributes: 36 | label: Domanda 37 | placeholder: Scrivi qui il corpo della domanda. 38 | render: text 39 | validations: 40 | required: true 41 | - type: input 42 | id: answerA 43 | attributes: 44 | label: Risposta A 45 | placeholder: Scrivi qui la risposta A 46 | validations: 47 | required: true 48 | - type: input 49 | id: answerB 50 | attributes: 51 | label: Risposta B 52 | placeholder: Scrivi qui la risposta B 53 | validations: 54 | required: true 55 | - type: input 56 | id: answerC 57 | attributes: 58 | label: Risposta C 59 | placeholder: Scrivi qui la risposta C 60 | validations: 61 | required: false 62 | - type: input 63 | id: answerD 64 | attributes: 65 | label: Risposta D 66 | placeholder: Scrivi qui la risposta D 67 | validations: 68 | required: false 69 | - type: input 70 | id: answerE 71 | attributes: 72 | label: Risposta E 73 | placeholder: Scrivi qui la risposta E 74 | validations: 75 | required: false 76 | 77 | - type: dropdown 78 | id: correct-answer 79 | attributes: 80 | label: Risposta Corretta 81 | multiple: false 82 | options: 83 | - A 84 | - B 85 | - C 86 | - D 87 | - E 88 | default: 0 89 | validations: 90 | required: false -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/richiesta-nuova-feature.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Richiesta nuova feature 3 | about: Suggerisci un'idea per il progetto 4 | title: "[FEATURE]" 5 | labels: new feaeture 6 | assignees: '' 7 | 8 | --- 9 | 10 | **La tua feature è legata ad un problema? Se puoi descrivilo.** 11 | Descrizione chiara e coincisa di cosa consiste il problema. Es: è frustrante che ogni volta succede questo [...] 12 | 13 | **Descrivi la soluzione che ti piacerebbe venisse aggiunta** 14 | Descrizione chiara e coincisa di cosa vorresti succedesse. 15 | 16 | **Descrivi eventuali alternative che hai considerato** 17 | Descrizione chiara e coincisa di qualsiasi soluzione alternativa o feature che hai considerato. 18 | 19 | 20 | **Informazioni aggiuntive** 21 | Aggiungi qui qualsiasi altro dettaglio di contesto, o immagini, che potrebbero essere utili all'implementazione della nuova feature. 22 | -------------------------------------------------------------------------------- /.github/workflows/check_file_domande.yml: -------------------------------------------------------------------------------- 1 | name: Validazione File Domande 2 | on: 3 | push: 4 | branches: 5 | - main 6 | 7 | defaults: 8 | run: 9 | shell: bash 10 | 11 | jobs: 12 | Validazione-File-Domande: 13 | runs-on: ubuntu-latest 14 | steps: 15 | - name: Check out repository code 16 | uses: actions/checkout@v2 17 | with: 18 | token: ${{ secrets.GITHUB_TOKEN }} 19 | - run: cd ${{ github.workspace }} 20 | - name: Controllo Codifica File 21 | run: | 22 | file_domande="Domande.txt" 23 | codifica="UTF-8" 24 | 25 | # Check Encoding 26 | charset=$(file -i "$file_domande" | cut -f 2 -d ";" | cut -f 2 -d "=") 27 | if [[ "${charset^^}" = "$codifica" ]] 28 | then 29 | echo "✔️ DEUBG: Codifica OK ($charset)" 30 | 31 | cp "$file_domande" "app-desktop/Domande.txt" 32 | cp "$file_domande" "app-mobile/flutter_application/assets/domande.txt" 33 | 34 | # Check if there are changes 35 | if [[ -n $(git status -s) ]] 36 | then 37 | # Commit & Push changes 38 | git add -f "app-desktop/Domande.txt" 39 | git add -f "app-mobile/flutter_application/assets/domande.txt" 40 | git config --global user.email "righi.michele98@gmail.com" 41 | git config --global user.name "mikyll" 42 | git commit -m "fix: update questions file" 43 | git push https://${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }} 44 | echo "✔️ File domande aggiornati!" 45 | else 46 | echo "Nessuna modifica necessaria." 47 | fi 48 | else 49 | echo "❌ ERRORE: Codifica file \"$file_domande\" errata ($charset)" 50 | exit 1 51 | fi 52 | -------------------------------------------------------------------------------- /.github/workflows/update_readme.yml: -------------------------------------------------------------------------------- 1 | name: Update Readme 2 | on: 3 | push: 4 | branches: 5 | - main 6 | 7 | defaults: 8 | run: 9 | shell: bash 10 | 11 | env: 12 | FILE_QUESTIONS: "Domande.txt" 13 | FILE_README: "README.md" 14 | 15 | jobs: 16 | Update-Contributors: 17 | runs-on: ubuntu-latest 18 | steps: 19 | - name: Aggiornamento contributors 20 | uses: akhilmhdh/contributors-readme-action@v2.3.10 21 | with: 22 | use_username: true 23 | committer_username: "mikyll" 24 | commit_message: "update README.md" 25 | env: 26 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 27 | Update-Readme: 28 | runs-on: ubuntu-latest 29 | steps: 30 | - name: Check out repository code 31 | uses: actions/checkout@v4 32 | with: 33 | token: ${{ secrets.GITHUB_TOKEN }} 34 | 35 | - run: cd ${{ github.workspace }} 36 | 37 | - name: Aggiornamento numero domande 38 | run: | 39 | # Count questions 40 | questions=0 41 | while IFS='' read -r LINE || [ -n "${LINE}" ] 42 | do 43 | # Question 44 | if [[ -n "$LINE" && ! "$LINE" == @* && ! "$LINE" =~ ^[A-E]\. && ! "$LINE" == [A-E] ]] 45 | then 46 | questions=$(expr $questions + 1) 47 | fi 48 | done < "$FILE_QUESTIONS" 49 | 50 | echo "Numero domande: $questions" 51 | 52 | # Update README: question shield 53 | sed -i "s/message=[0-9]*/message=$questions/" "$FILE_README" 54 | 55 | # Update README: question number 56 | sed -i "s|[0-9]*<\/span>|$questions<\/span>|" "$FILE_README" 57 | 58 | - name: Aggiornamento data ultimo aggiornamento 59 | run: | 60 | # Update date 61 | date=$(curl -s "https://api.github.com/repos/mikyll/ROQuiz/commits?path=${FILE_QUESTIONS}&page=1&per_page=1" | grep -m 1 \"date\" | xargs | cut -f2 -d' ' | cut -f1 -d'T') 62 | echo "$FILE_QUESTIONS ultima modifica: $date" 63 | sed -i "s|.*<\/span>|$date<\/span>|" "$FILE_README" 64 | 65 | - name: Commit e Push modifiche 66 | run: | 67 | # Check if there are changes 68 | if [[ -n $(git status -s) ]] 69 | then 70 | # Commit & Push changes 71 | git add "$FILE_README" 72 | git config --global user.email "righi.michele98@gmail.com" 73 | git config --global user.name "mikyll" 74 | git commit -m "docs: update README.md" 75 | git push https://${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }} 76 | echo "✔️ Readme aggiornato!" 77 | else 78 | echo "Nessuna modifica necessaria." 79 | fi 80 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled class file 2 | *.class 3 | 4 | # Log file 5 | *.log 6 | 7 | # BlueJ files 8 | *.ctxt 9 | 10 | # Mobile Tools for Java (J2ME) 11 | .mtj.tmp/ 12 | 13 | # Package Files # 14 | src/*.jar 15 | *.war 16 | *.nar 17 | *.ear 18 | *.zip 19 | *.tar.gz 20 | *.rar 21 | 22 | # virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml 23 | hs_err_pid* 24 | 25 | # file video 26 | *.mkv 27 | *.mp4 28 | 29 | # link 30 | *.url 31 | 32 | # directory 33 | deploy 34 | extra 35 | 36 | # scriptino per creare la jre per fx 37 | createFXJRE* 38 | 39 | backupDomandeANSI.txt 40 | 41 | ROQuiz App.md -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Come Contribuire 2 | 3 | ## Aggiunta domande o feature al progetto: 4 | 5 | 1. Fare una **fork** della repository. 6 | 2. Clonare la repository in locale. 7 | 3. (Opzionale) Creare un nuovo branch. 8 | 4. Aggiungere le modifiche: 9 | - Per aggiungere nuove domande: modificare il file 'Domande.txt', inserendo le nuove domande sotto gli argomenti relativi.
10 | **NB**: in caso non si sappia sotto quale argomento inserire una domanda, farlo presente in un commento nella pull request.
11 | - Per aggiungere delle feature: basta implementarle e integrarle col resto dell'applicazione. 12 | 5. Fare uno o più commit descrivendo le modifiche 13 | 6. Pushare i cambiamenti. 14 | 7. Creare una **pull request** aggiungendo riassumendo le modifiche ed eventuali motivazioni. 15 | 8. Ammirare il proprio nome inserito nella ✨ [meravigliosa lista](https://github.com/mikyll/ROQuiz/blob/main/README.md#contributors-attuali) ✨ che viene aggiornata automaticamente.
16 | **NB**: per far sì che il nome del contributor venga registrato correttamente nella lista, controllare che al commit corrispondano username ed e-mail appropriati dell'account GitHub. 17 | 18 | ## Proposta feature: 19 | 20 | 1. Aprire un issue spiegando in cosa consiste la feature da aggiungere. 21 | 2. Possibilmente aggiungervi la label "enhancement". 22 | -------------------------------------------------------------------------------- /Domande RO con spiegazione.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/Domande RO con spiegazione.pdf -------------------------------------------------------------------------------- /Project Setup.md: -------------------------------------------------------------------------------- 1 | # Eclipse Project Setup 2 | 3 | ## Indice 4 | 5 |
6 | 7 | 8 |
    9 |
  1. 10 | Installazione Java 11 | 14 |
  2. 15 |
  3. 16 | Setup progetto 17 |
  4. 18 |
  5. 19 | Build JRE con JavaFX 20 | 24 |
  6. 25 |
26 |
27 | 28 | ## Installazione Java 29 | 30 | ### Esempio Windows 31 | 1. Scaricare Java 11 (jdk-11.0.11) o una versione più recente: https://www.oracle.com/java/technologies/javase-jdk11-downloads.html 32 |

33 | 2. Estrarne il contenuto in una directory a piacere (meglio se nella stessa con le altre installazioni Java, di default è "C:\Program Files\Java\")
34 | 3. Impostare Path e JAVA_HOME nelle variabili di sistema: 35 | 36 | * Cerca > Variabili > Modifica le variabili di ambiente relative al sistema > Variabili d'ambiente... 37 |

38 | * Nel riquadro in alto aggiungere (o modificare se esiste già) alla variabile JAVA_HOME: Nuova... > Nome: JAVA_HOME, Valore: percorso in cui abbiamo scaricato il jdk 11
39 |

40 |

41 | * Nel riquadro in basso modificare la variabile Path, aggiungendovi il percorso della directory \bin dentro al jdk: 42 |

43 | * verificare che Java 11 sia installato correttamente: Cerca > cmd > "java -version" e "javac -version" 44 | 45 |

46 | 4. Download JavaFX 11 (javafx-sdk-11.0.2): https://gluonhq.com/products/javafx/ 47 |
48 | 5. Estrarne il contenuto in una directory a piacere (meglio se nella stessa con le altre installazioni Java, di default è "C:\Program Files\Java\"). 49 | 50 | ## Setup progetto 51 | 1. Installare l'ultima versione di Eclipse [download Eclipse](https://www.eclipse.org/downloads/). 52 | 2. Controllare che Eclipse utilizzi una JRE adeguata (almeno 11.0): Window > Preferences > Java > Installed JREs.
53 | In caso contrario aggiungerla: Add > Standard VM > Directory... (selezionare la directory dell'JDK). 54 | 3. Scaricare JavaFX 11 o più recente, sia SDK che JMOD (https://gluonhq.com/products/javafx/). 55 | 4. Clonare la repository. 56 | 5. Importare il progetto su Eclipse. 57 | 6. Creare una User Library con le librerie di JavaFX: Window > Preferences > Java > Build Path > User Libraries > New > User library name (es: "JavaFX11") > Add External JARs > aggiungere i .jar che si trovano nell'SDK, nella directory lib/ 58 |

59 | 7. Aggiungere la User Library appena creata al Modulepath: tasto destro sul progetto > Build Path > Configure Build Path... > Libraries > Modulepath > Add Library... > User Library > JavaFX (es. JavaFX11).
60 |
61 |

62 | 8. Aggiungere i moduli necessari come argomenti nella Run Configuration: 63 | Windows: Tasto destro sulla classe application.Main > Run > Run Configurations > Arguments > aggiungere in VM arguments: --module-path "mods;\lib" -m roquiz/application.Main > Apply. 64 | 65 | Linux: Tasto destro sulla classe application.Main > Run > Run Configurations > Arguments > aggiungere in VM arguments: --module-path "mods:\lib" -m roquiz/application.Main > Apply. 66 | NB: la differenza è il separatore ';' su Windows e ':' su Linux (avrei voluto scoprirlo subito invece di perdere 3 giorni a cercare di capire come mai non trovava il modulo roquiz :) ) 67 | Ora l'applicazione è pronta per essere eseguita all'interno di Eclipse. 68 | 69 | ## Build JRE con JavaFX 70 | Per eseguire l'applicazione standalone è necessario buildare una jre che includa JavaFX: per farlo si può usare jlink, che è compreso nell'installazione Java. 71 | ### Windows 72 |
73 | jlink --module-path "path/to/jaavafx-jmods";mods --add-modules=roquiz --output fxjreWin --compress=2 --strip-debug --no-header-files --no-man-pages
74 | 
75 | 76 | ### Linux 77 | NB: controllare con java -version che sia installato Java 11 o una versione più recente. 78 |
79 | jlink --module-path "path/to/jaavafx-jmods":mods --add-modules=roquiz --output fxjreLin --compress=2 --strip-debug --no-header-files --no-man-pages
80 | 
81 | 82 | 83 | -------------------------------------------------------------------------------- /app-desktop/.classpath: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /app-desktop/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | ROQuiz 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | 15 | org.eclipse.jdt.core.javanature 16 | 17 | 18 | -------------------------------------------------------------------------------- /app-desktop/.settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "questionFileDate": "2022-06-22T15:54:09Z", 3 | "questionNumber": 16, 4 | "timer": 18, 5 | "shuffleAnswers": true, 6 | "darkTheme": false, 7 | "checkQuestionsUpdate": true, 8 | "checkAppUpdate": true 9 | } -------------------------------------------------------------------------------- /app-desktop/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled 3 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=11 4 | org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve 5 | org.eclipse.jdt.core.compiler.compliance=11 6 | org.eclipse.jdt.core.compiler.debug.lineNumber=generate 7 | org.eclipse.jdt.core.compiler.debug.localVariable=generate 8 | org.eclipse.jdt.core.compiler.debug.sourceFile=generate 9 | org.eclipse.jdt.core.compiler.problem.assertIdentifier=error 10 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 11 | org.eclipse.jdt.core.compiler.problem.enumIdentifier=error 12 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning 13 | org.eclipse.jdt.core.compiler.release=enabled 14 | org.eclipse.jdt.core.compiler.source=11 15 | -------------------------------------------------------------------------------- /app-desktop/libs/gson-2.8.9.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/libs/gson-2.8.9.jar -------------------------------------------------------------------------------- /app-desktop/mods/.gitignore: -------------------------------------------------------------------------------- 1 | /application/ 2 | /gui/ 3 | /model/ 4 | /persistence/ 5 | -------------------------------------------------------------------------------- /app-desktop/mods/application/theme_dark.css: -------------------------------------------------------------------------------- 1 | /* 2 | Background: #202020 3 | Button Background: #404040 4 | */ 5 | 6 | .root { 7 | -fx-background-color: #202020; 8 | -fx-text-fill: white; 9 | } 10 | 11 | .list-view { 12 | -fx-base: #606060; 13 | -fx-border-color: #404040; 14 | -fx-border-width: 1px; 15 | -fx-control-inner-background: #000000; 16 | } 17 | 18 | .list-view .list-cell:even { 19 | -fx-background-color: #000000; 20 | } 21 | .list-view .list-cell:odd { 22 | -fx-background-color: #202020; 23 | } 24 | 25 | .scroll-bar { 26 | -fx-background-color: #404040; 27 | } 28 | 29 | .scroll-bar .thumb { 30 | -fx-base: #606060; 31 | } 32 | 33 | .scroll-bar .increment-button:hover, .scroll-bar .decrement-button:hover { 34 | -fx-background-color: #808080; 35 | } 36 | 37 | .label { 38 | -fx-text-fill: white; 39 | } 40 | 41 | .hyperlink:visited { 42 | -fx-text-fill: #707070; 43 | } 44 | 45 | .text-field { 46 | -fx-base: #404040; 47 | -fx-background-color: #404040; 48 | -fx-text-fill: white; 49 | } 50 | 51 | .text-area { 52 | -fx-base: #404040; 53 | -fx-control-inner-background: #404040; 54 | -fx-text-fill: white; 55 | 56 | -fx-faint-focus-color: transparent; 57 | -fx-focus-color: transparent; 58 | } 59 | .text-area .content { 60 | -fx-background-radius: 0 ; 61 | } 62 | 63 | .button, .spinner, .check-box, .radio-button { 64 | -fx-base: #404040; 65 | } 66 | 67 | .button { 68 | -fx-background-size: 30px; 69 | -fx-background-repeat: no-repeat; 70 | -fx-background-position: 50%; 71 | -fx-text-fill: white; 72 | } 73 | 74 | .tooltip { 75 | -fx-background-color: #808080; 76 | -fx-text-fill: black; 77 | } 78 | 79 | #questions { 80 | -fx-background-image: url('../gfx/icon_questions_light.png'); 81 | -fx-background-size: 20px; 82 | -fx-background-repeat: no-repeat; 83 | -fx-background-position: 0%; 84 | } 85 | 86 | #timer { 87 | -fx-background-image: url('../gfx/icon_timer_light.png'); 88 | -fx-background-size: 20px; 89 | -fx-background-repeat: no-repeat; 90 | -fx-background-position: 0%; 91 | } 92 | 93 | #star { 94 | -fx-background-image: url('../gfx/icon_star_light.png'); 95 | -fx-background-size: 25px; 96 | -fx-background-repeat: no-repeat; 97 | -fx-background-position: 0%; 98 | } 99 | 100 | #back { 101 | -fx-background-image: url('../gfx/icon_back_light.png'); 102 | } 103 | 104 | #settings { 105 | -fx-background-image: url('../gfx/icon_settings_light.png'); 106 | } 107 | 108 | #update { 109 | -fx-background-image: url('../gfx/icon_refresh_light.png'); 110 | -fx-background-size: 25px; 111 | } 112 | 113 | #info { 114 | -fx-background-image: url('../gfx/icon_info_light.png'); 115 | } 116 | 117 | #prev { 118 | -fx-background-image: url('../gfx/icon_prev_light.png'); 119 | } 120 | 121 | #next { 122 | -fx-background-image: url('../gfx/icon_next_light.png'); 123 | } 124 | 125 | #showQuestions { 126 | -fx-background-image: url('../gfx/icon_show_light.png'); 127 | -fx-background-size: 20px; 128 | -fx-background-radius: 5em; 129 | -fx-min-width: 25px; 130 | -fx-min-height: 25px; 131 | -fx-max-width: 25px; 132 | -fx-max-height: 25px; 133 | } 134 | 135 | .dialog-pane { 136 | -fx-background-color: #202020; 137 | } 138 | 139 | .dialog-pane .label { 140 | -fx-text-fill: white; 141 | } 142 | 143 | .dialog-pane:header .header-panel { 144 | -fx-background-color: #202020; 145 | } 146 | 147 | /*.dialog-pane:header .header-panel .label { 148 | -fx-font-style: italic; 149 | -fx-font-size: 2em; 150 | }*/ -------------------------------------------------------------------------------- /app-desktop/mods/application/theme_light.css: -------------------------------------------------------------------------------- 1 | .hyperlink:visited { 2 | -fx-text-fill: purple; 3 | } 4 | 5 | .button { 6 | -fx-background-size: 30px; 7 | -fx-background-repeat: no-repeat; 8 | -fx-background-position: 50%; 9 | } 10 | 11 | .list-view { 12 | -fx-border-width: 2px; 13 | } 14 | 15 | #questions { 16 | -fx-background-image: url('../gfx/icon_questions_dark.png'); 17 | -fx-background-size: 20px; 18 | -fx-background-repeat: no-repeat; 19 | -fx-background-position: 0%; 20 | } 21 | 22 | #timer { 23 | -fx-background-image: url('../gfx/icon_timer_dark.png'); 24 | -fx-background-size: 20px; 25 | -fx-background-repeat: no-repeat; 26 | -fx-background-position: 0%; 27 | } 28 | 29 | #star { 30 | -fx-background-image: url('../gfx/icon_star_dark.png'); 31 | -fx-background-size: 20px; 32 | -fx-background-repeat: no-repeat; 33 | -fx-background-position: 0%; 34 | } 35 | 36 | #back { 37 | -fx-background-image: url('../gfx/icon_back_dark.png'); 38 | } 39 | 40 | #settings { 41 | -fx-background-image: url('../gfx/icon_settings_dark.png'); 42 | } 43 | 44 | #update { 45 | -fx-background-image: url('../gfx/icon_refresh_dark.png'); 46 | -fx-background-size: 25px; 47 | } 48 | 49 | #info { 50 | -fx-background-image: url('../gfx/icon_info_dark.png'); 51 | } 52 | 53 | #prev { 54 | -fx-background-image: url('../gfx/icon_prev_dark.png'); 55 | } 56 | 57 | #next { 58 | -fx-background-image: url('../gfx/icon_next_dark.png'); 59 | } 60 | 61 | #showQuestions { 62 | -fx-background-image: url('../gfx/icon_show_dark.png'); 63 | -fx-background-size: 20px; 64 | -fx-background-radius: 5em; 65 | -fx-min-width: 25px; 66 | -fx-min-height: 25px; 67 | -fx-max-width: 25px; 68 | -fx-max-height: 25px; 69 | } -------------------------------------------------------------------------------- /app-desktop/mods/gfx/debug.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/debug.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_back_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_back_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_back_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_back_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_info_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_info_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_info_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_info_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_next_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_next_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_next_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_next_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_prev_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_prev_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_prev_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_prev_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_questions_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_questions_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_questions_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_questions_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_refresh_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_refresh_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_refresh_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_refresh_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_settings_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_settings_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_settings_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_settings_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_show_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_show_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_show_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_show_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_star.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_star.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_star_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_star_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_star_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_star_light.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_timer_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_timer_dark.png -------------------------------------------------------------------------------- /app-desktop/mods/gfx/icon_timer_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/mods/gfx/icon_timer_light.png -------------------------------------------------------------------------------- /app-desktop/src/application/Main.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/application/Main.java -------------------------------------------------------------------------------- /app-desktop/src/application/theme_dark.css: -------------------------------------------------------------------------------- 1 | /* 2 | Background: #202020 3 | Button Background: #404040 4 | */ 5 | 6 | .root { 7 | -fx-background-color: #202020; 8 | -fx-text-fill: white; 9 | } 10 | 11 | .list-view { 12 | -fx-base: #606060; 13 | -fx-border-color: #404040; 14 | -fx-border-width: 1px; 15 | -fx-control-inner-background: #000000; 16 | } 17 | 18 | .list-view .list-cell:even { 19 | -fx-background-color: #000000; 20 | } 21 | .list-view .list-cell:odd { 22 | -fx-background-color: #202020; 23 | } 24 | 25 | .scroll-bar { 26 | -fx-background-color: #404040; 27 | } 28 | 29 | .scroll-bar .thumb { 30 | -fx-base: #606060; 31 | } 32 | 33 | .scroll-bar .increment-button:hover, .scroll-bar .decrement-button:hover { 34 | -fx-background-color: #808080; 35 | } 36 | 37 | .label { 38 | -fx-text-fill: white; 39 | } 40 | 41 | .hyperlink:visited { 42 | -fx-text-fill: #707070; 43 | } 44 | 45 | .text-field { 46 | -fx-base: #404040; 47 | -fx-background-color: #404040; 48 | -fx-text-fill: white; 49 | } 50 | 51 | .text-area { 52 | -fx-base: #404040; 53 | -fx-control-inner-background: #404040; 54 | -fx-text-fill: white; 55 | 56 | -fx-faint-focus-color: transparent; 57 | -fx-focus-color: transparent; 58 | } 59 | .text-area .content { 60 | -fx-background-radius: 0 ; 61 | } 62 | 63 | .button, .spinner, .check-box, .radio-button { 64 | -fx-base: #404040; 65 | } 66 | 67 | .button { 68 | -fx-background-size: 30px; 69 | -fx-background-repeat: no-repeat; 70 | -fx-background-position: 50%; 71 | -fx-text-fill: white; 72 | } 73 | 74 | .tooltip { 75 | -fx-background-color: #808080; 76 | -fx-text-fill: black; 77 | } 78 | 79 | #questions { 80 | -fx-background-image: url('../gfx/icon_questions_light.png'); 81 | -fx-background-size: 20px; 82 | -fx-background-repeat: no-repeat; 83 | -fx-background-position: 0%; 84 | } 85 | 86 | #timer { 87 | -fx-background-image: url('../gfx/icon_timer_light.png'); 88 | -fx-background-size: 20px; 89 | -fx-background-repeat: no-repeat; 90 | -fx-background-position: 0%; 91 | } 92 | 93 | #star { 94 | -fx-background-image: url('../gfx/icon_star_light.png'); 95 | -fx-background-size: 25px; 96 | -fx-background-repeat: no-repeat; 97 | -fx-background-position: 0%; 98 | } 99 | 100 | #back { 101 | -fx-background-image: url('../gfx/icon_back_light.png'); 102 | } 103 | 104 | #settings { 105 | -fx-background-image: url('../gfx/icon_settings_light.png'); 106 | } 107 | 108 | #update { 109 | -fx-background-image: url('../gfx/icon_refresh_light.png'); 110 | -fx-background-size: 25px; 111 | } 112 | 113 | #info { 114 | -fx-background-image: url('../gfx/icon_info_light.png'); 115 | } 116 | 117 | #prev { 118 | -fx-background-image: url('../gfx/icon_prev_light.png'); 119 | } 120 | 121 | #next { 122 | -fx-background-image: url('../gfx/icon_next_light.png'); 123 | } 124 | 125 | #showQuestions { 126 | -fx-background-image: url('../gfx/icon_show_light.png'); 127 | -fx-background-size: 20px; 128 | -fx-background-radius: 5em; 129 | -fx-min-width: 25px; 130 | -fx-min-height: 25px; 131 | -fx-max-width: 25px; 132 | -fx-max-height: 25px; 133 | } 134 | 135 | .dialog-pane { 136 | -fx-background-color: #202020; 137 | } 138 | 139 | .dialog-pane .label { 140 | -fx-text-fill: white; 141 | } 142 | 143 | .dialog-pane:header .header-panel { 144 | -fx-background-color: #202020; 145 | } 146 | 147 | /*.dialog-pane:header .header-panel .label { 148 | -fx-font-style: italic; 149 | -fx-font-size: 2em; 150 | }*/ -------------------------------------------------------------------------------- /app-desktop/src/application/theme_light.css: -------------------------------------------------------------------------------- 1 | .hyperlink:visited { 2 | -fx-text-fill: purple; 3 | } 4 | 5 | .button { 6 | -fx-background-size: 30px; 7 | -fx-background-repeat: no-repeat; 8 | -fx-background-position: 50%; 9 | } 10 | 11 | .list-view { 12 | -fx-border-width: 2px; 13 | } 14 | 15 | #questions { 16 | -fx-background-image: url('../gfx/icon_questions_dark.png'); 17 | -fx-background-size: 20px; 18 | -fx-background-repeat: no-repeat; 19 | -fx-background-position: 0%; 20 | } 21 | 22 | #timer { 23 | -fx-background-image: url('../gfx/icon_timer_dark.png'); 24 | -fx-background-size: 20px; 25 | -fx-background-repeat: no-repeat; 26 | -fx-background-position: 0%; 27 | } 28 | 29 | #star { 30 | -fx-background-image: url('../gfx/icon_star_dark.png'); 31 | -fx-background-size: 20px; 32 | -fx-background-repeat: no-repeat; 33 | -fx-background-position: 0%; 34 | } 35 | 36 | #back { 37 | -fx-background-image: url('../gfx/icon_back_dark.png'); 38 | } 39 | 40 | #settings { 41 | -fx-background-image: url('../gfx/icon_settings_dark.png'); 42 | } 43 | 44 | #update { 45 | -fx-background-image: url('../gfx/icon_refresh_dark.png'); 46 | -fx-background-size: 25px; 47 | } 48 | 49 | #info { 50 | -fx-background-image: url('../gfx/icon_info_dark.png'); 51 | } 52 | 53 | #prev { 54 | -fx-background-image: url('../gfx/icon_prev_dark.png'); 55 | } 56 | 57 | #next { 58 | -fx-background-image: url('../gfx/icon_next_dark.png'); 59 | } 60 | 61 | #showQuestions { 62 | -fx-background-image: url('../gfx/icon_show_dark.png'); 63 | -fx-background-size: 20px; 64 | -fx-background-radius: 5em; 65 | -fx-min-width: 25px; 66 | -fx-min-height: 25px; 67 | -fx-max-width: 25px; 68 | -fx-max-height: 25px; 69 | } -------------------------------------------------------------------------------- /app-desktop/src/gfx/debug.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/debug.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_back_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_back_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_back_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_back_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_info_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_info_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_info_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_info_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_next_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_next_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_next_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_next_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_prev_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_prev_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_prev_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_prev_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_questions_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_questions_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_questions_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_questions_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_refresh_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_refresh_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_refresh_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_refresh_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_settings_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_settings_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_settings_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_settings_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_show_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_show_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_show_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_show_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_star.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_star.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_star_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_star_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_star_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_star_light.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_timer_dark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_timer_dark.png -------------------------------------------------------------------------------- /app-desktop/src/gfx/icon_timer_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gfx/icon_timer_light.png -------------------------------------------------------------------------------- /app-desktop/src/gui/ControllerMenu.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/gui/ControllerMenu.java -------------------------------------------------------------------------------- /app-desktop/src/model/Answer.java: -------------------------------------------------------------------------------- 1 | package model; 2 | 3 | public enum Answer { 4 | A, B, C, D, E, NONE 5 | } 6 | -------------------------------------------------------------------------------- /app-desktop/src/model/Question.java: -------------------------------------------------------------------------------- 1 | package model; 2 | 3 | import java.util.Collections; 4 | import java.util.HashMap; 5 | import java.util.ArrayList; 6 | import java.util.List; 7 | 8 | import persistence.SettingsManager; 9 | 10 | public class Question { 11 | private String question; 12 | private HashMap answers; 13 | private Answer correctAnswer; 14 | 15 | public Question(String question) 16 | { 17 | this.answers = new HashMap(SettingsManager.DEFAULT_ANSWER_NUMBER); 18 | this.question = question; 19 | } 20 | 21 | public String getQuestion() {return question;} 22 | public void setQuestion(String question) {this.question = question;} 23 | public HashMap getAnswers() {return answers;} 24 | public void setAnswers(HashMap answers) {this.answers = answers;} 25 | public void addAnswer(String answer) 26 | { 27 | if(this.answers.keySet().size() == SettingsManager.DEFAULT_ANSWER_NUMBER) 28 | throw new IllegalArgumentException("Answer number excedeed."); 29 | 30 | int index = this.answers.keySet().size(); 31 | Answer a = Answer.values()[index]; 32 | this.answers.put(a, answer); 33 | } 34 | public Answer getCorrectAnswer() {return this.correctAnswer;} 35 | public void setCorrectAnswer(int correctAnswer) 36 | { 37 | if(correctAnswer > SettingsManager.DEFAULT_ANSWER_NUMBER) 38 | throw new IllegalArgumentException("Error: the correct answer must be one of answers."); 39 | this.correctAnswer = Answer.values()[correctAnswer]; 40 | } 41 | public void setCorrectAnswer(Answer correctAnswer) 42 | { 43 | this.correctAnswer = correctAnswer; 44 | } 45 | 46 | public void shuffleAnswers() 47 | { 48 | List a = new ArrayList(); 49 | String ca = this.answers.get(this.correctAnswer); 50 | 51 | for(String s : this.answers.values()) 52 | a.add(s); 53 | 54 | Collections.shuffle(a); 55 | 56 | this.answers = new HashMap(SettingsManager.DEFAULT_ANSWER_NUMBER); 57 | for(int i = 0; i < a.size(); i++) 58 | { 59 | this.answers.put(Answer.values()[i], a.get(i)); 60 | if(a.get(i).equals(ca)) 61 | this.correctAnswer = Answer.values()[i]; 62 | } 63 | } 64 | 65 | } 66 | -------------------------------------------------------------------------------- /app-desktop/src/model/Quiz.java: -------------------------------------------------------------------------------- 1 | package model; 2 | 3 | import java.util.ArrayList; 4 | import java.util.Collections; 5 | import java.util.List; 6 | 7 | public class Quiz { 8 | private List quiz; 9 | private List answers; // user answers 10 | private int givenAnswers; 11 | private int correctAnswers; 12 | 13 | public Quiz(List questions, int qNum, boolean shuffleAnswers) 14 | { 15 | this.resetQuiz(questions, qNum, shuffleAnswers); 16 | } 17 | 18 | public Question getQuestionAt(int index) {return this.quiz.get(index);} 19 | public List getQuiz() {return this.quiz;} 20 | public List getAnswers() {return this.answers;} 21 | public int getGivenAnswers() {return givenAnswers;} 22 | public int getCorrectAnswers() {return correctAnswers;} 23 | 24 | public void setAnswer(int index, int value) 25 | { 26 | /*if(value < 0 || value > Settings.ANSWER_NUMBER - 1) 27 | throw new IllegalArgumentException();*/ 28 | if(this.answers.get(index).equals(Answer.NONE)) 29 | this.givenAnswers++; 30 | 31 | this.answers.set(index, Answer.values()[value]); 32 | } 33 | public void setAnswer(int index, Answer value) 34 | { 35 | /*if(value < 0 || value > Settings.ANSWER_NUMBER - 1) 36 | throw new IllegalArgumentException();*/ 37 | if(this.answers.get(index).equals(Answer.NONE)) 38 | this.givenAnswers++; 39 | 40 | this.answers.set(index, value); 41 | } 42 | 43 | public void resetQuiz(List questions, int qNum, boolean shuffleAnswers) 44 | { 45 | // reset questions & user answers 46 | this.quiz = new ArrayList(qNum); 47 | this.answers = new ArrayList(qNum); 48 | 49 | Collections.shuffle(questions); 50 | for(int i = 0; i < qNum; i++) 51 | { 52 | Question q = questions.get(i); 53 | 54 | if(shuffleAnswers) 55 | q.shuffleAnswers(); 56 | 57 | this.quiz.add(q); 58 | this.answers.add(Answer.NONE); 59 | } 60 | 61 | // reset counters 62 | this.givenAnswers = 0; 63 | this.correctAnswers = 0; 64 | } 65 | 66 | public void checkAnswers() 67 | { 68 | for(int i = 0; i < this.quiz.size(); i++) 69 | { 70 | Answer ca = this.quiz.get(i).getCorrectAnswer(); 71 | Answer ua = this.answers.get(i); 72 | 73 | if(ca.equals(ua)) 74 | this.correctAnswers++; 75 | } 76 | } 77 | } 78 | -------------------------------------------------------------------------------- /app-desktop/src/model/Settings.java: -------------------------------------------------------------------------------- 1 | package model; 2 | 3 | public class Settings { 4 | private String questionFileDate; 5 | private int questionNumber; 6 | private int timer; 7 | private boolean shuffleAnswers; 8 | private boolean darkTheme; 9 | private boolean checkQuestionsUpdate; 10 | private boolean checkAppUpdate; 11 | 12 | public Settings() {} 13 | public Settings(String qFDate, int qNum, int sTime, boolean shuffle, boolean dTheme, boolean qUpdate, boolean appUpdate) 14 | { 15 | this.questionFileDate = qFDate; 16 | this.questionNumber = qNum; 17 | this.timer = sTime; 18 | this.shuffleAnswers = shuffle; 19 | this.darkTheme = dTheme; 20 | this.checkQuestionsUpdate = qUpdate; 21 | this.checkAppUpdate = appUpdate; 22 | } 23 | 24 | public String getQuestionFileDate() {return this.questionFileDate;} 25 | public void setQuestionFileDate(String qFDate) {this.questionFileDate = qFDate;} 26 | public int getQuestionNumber() {return this.questionNumber;} 27 | public void setQuestionNumber(int qNum) {this.questionNumber = qNum;} 28 | public int getTimer() {return this.timer;} 29 | public void setTimer(int sTime) {this.timer = sTime;} 30 | public boolean isShuffleAnswers() {return this.shuffleAnswers;} 31 | public void setShuffleAnswers(boolean shuffleAnswers) {this.shuffleAnswers = shuffleAnswers;} 32 | public boolean isDarkTheme() {return this.darkTheme;} 33 | public void setDarkTheme(boolean dTheme) {this.darkTheme = dTheme;} 34 | public boolean isCheckQuestionsUpdate() {return this.checkQuestionsUpdate;} 35 | public void setCheckQuestionsUpdate(boolean qUpdate) {this.checkQuestionsUpdate = qUpdate;} 36 | public boolean isCheckAppUpdate() {return this.checkAppUpdate;} 37 | public void setCheckAppUpdate(boolean appUpdate) {this.checkAppUpdate = appUpdate;} 38 | 39 | public String toString() 40 | { 41 | return "Data file domande: " + this.questionFileDate + 42 | "\nNumero domande per quiz: " + this.questionNumber + 43 | "\nTimer per quiz (Minuti): " + this.timer + 44 | "\nMescola Risposte: " + this.shuffleAnswers + 45 | "\nTema scuro: " + this.darkTheme + 46 | "\nControllo domande aggiornate: " + this.checkQuestionsUpdate + 47 | "\nControllo aggiornamenti app: " + this.checkAppUpdate; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /app-desktop/src/module-info.java: -------------------------------------------------------------------------------- 1 | module roquiz { 2 | requires javafx.controls; 3 | requires javafx.fxml; 4 | requires transitive javafx.base; 5 | requires transitive javafx.graphics; 6 | requires com.google.gson; 7 | requires java.net.http; 8 | 9 | opens gui; 10 | opens model to com.google.gson; 11 | 12 | exports application; 13 | exports gui; 14 | exports model; 15 | exports persistence; 16 | } -------------------------------------------------------------------------------- /app-desktop/src/persistence/BadFileFormatException.java: -------------------------------------------------------------------------------- 1 | package persistence; 2 | 3 | public class BadFileFormatException extends Exception { 4 | private static final long serialVersionUID = 1L; 5 | private int lineNumber; 6 | 7 | public BadFileFormatException() { 8 | } 9 | 10 | public BadFileFormatException(String message) { 11 | super(message); 12 | } 13 | 14 | public BadFileFormatException(Throwable inner) { 15 | super(inner); 16 | } 17 | 18 | public BadFileFormatException(String message, Throwable inner) { 19 | super(message, inner); 20 | } 21 | 22 | public BadFileFormatException(int lineNumber) { 23 | this.lineNumber = lineNumber; 24 | } 25 | public BadFileFormatException(int lineNumber, String message) { 26 | super(message); 27 | this.lineNumber = lineNumber; 28 | } 29 | 30 | public int getExceptionLine() {return this.lineNumber;} 31 | } -------------------------------------------------------------------------------- /app-desktop/src/persistence/IQuestionRepository.java: -------------------------------------------------------------------------------- 1 | package persistence; 2 | 3 | import java.util.List; 4 | 5 | import model.Question; 6 | 7 | public interface IQuestionRepository { 8 | public List getQuestions(); 9 | public List getTopics(); 10 | public List getqNumPerTopics(); 11 | public boolean hasTopics(); 12 | } 13 | -------------------------------------------------------------------------------- /app-desktop/src/persistence/QuestionRepository.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/persistence/QuestionRepository.java -------------------------------------------------------------------------------- /app-desktop/src/persistence/SettingsManager.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/src/persistence/SettingsManager.java -------------------------------------------------------------------------------- /app-desktop/test/mods/.gitignore: -------------------------------------------------------------------------------- 1 | /gui/ 2 | -------------------------------------------------------------------------------- /app-desktop/test/mods/application/application.css: -------------------------------------------------------------------------------- 1 | /* JavaFX CSS - Leave this comment until you have at least create one rule which uses -fx-Property */ -------------------------------------------------------------------------------- /app-desktop/test/mods/gfx/icon_back.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/test/mods/gfx/icon_back.png -------------------------------------------------------------------------------- /app-desktop/test/mods/gfx/icon_info.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/test/mods/gfx/icon_info.png -------------------------------------------------------------------------------- /app-desktop/test/mods/gfx/icon_next.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/test/mods/gfx/icon_next.png -------------------------------------------------------------------------------- /app-desktop/test/mods/gfx/icon_prev.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/test/mods/gfx/icon_prev.png -------------------------------------------------------------------------------- /app-desktop/test/mods/gfx/icon_qmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/test/mods/gfx/icon_qmark.png -------------------------------------------------------------------------------- /app-desktop/test/mods/gfx/icon_settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/test/mods/gfx/icon_settings.png -------------------------------------------------------------------------------- /app-desktop/test/mods/gfx/icon_star.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/test/mods/gfx/icon_star.png -------------------------------------------------------------------------------- /app-desktop/test/mods/gfx/icon_stop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-desktop/test/mods/gfx/icon_stop.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/.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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/.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: "fcf2c11572af6f390246c056bc905eca609533a0" 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: fcf2c11572af6f390246c056bc905eca609533a0 17 | base_revision: fcf2c11572af6f390246c056bc905eca609533a0 18 | - platform: android 19 | create_revision: fcf2c11572af6f390246c056bc905eca609533a0 20 | base_revision: fcf2c11572af6f390246c056bc905eca609533a0 21 | - platform: linux 22 | create_revision: fcf2c11572af6f390246c056bc905eca609533a0 23 | base_revision: fcf2c11572af6f390246c056bc905eca609533a0 24 | - platform: web 25 | create_revision: fcf2c11572af6f390246c056bc905eca609533a0 26 | base_revision: fcf2c11572af6f390246c056bc905eca609533a0 27 | - platform: windows 28 | create_revision: fcf2c11572af6f390246c056bc905eca609533a0 29 | base_revision: fcf2c11572af6f390246c056bc905eca609533a0 30 | 31 | # User provided section 32 | 33 | # List of Local paths (relative to this file) that should be 34 | # ignored by the migrate tool. 35 | # 36 | # Files that are not part of the templates will be ignored by default. 37 | unmanaged_files: 38 | - 'lib/main.dart' 39 | - 'ios/Runner.xcodeproj/project.pbxproj' 40 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/.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": "flutter_application", 9 | "request": "launch", 10 | "type": "dart" 11 | }, 12 | { 13 | "name": "flutter_application (profile mode)", 14 | "request": "launch", 15 | "type": "dart", 16 | "flutterMode": "profile" 17 | }, 18 | { 19 | "name": "flutter_application (release mode)", 20 | "request": "launch", 21 | "type": "dart", 22 | "flutterMode": "release" 23 | } 24 | ] 25 | } -------------------------------------------------------------------------------- /app-mobile/flutter_application/README.md: -------------------------------------------------------------------------------- 1 | # ROQuiz 2 | 3 | Applicazione mobile di ROQuiz, per esercitarsi con i quiz del corso Ricerca Operativa M. 4 | 5 | ### Demo 6 | 7 | ### Esecuzione 8 | 1. Scaricare l'[apk](https://github.com/mikyll/ROQuiz/releases/download/v1.5/roquiz-mobile.apk). 9 | 2. Selezionare ```INSTALLA``` e ```INSTALLA COMUNQUE```. 10 | 11 | ### Roadmap 12 | Features da aggiungere e sviluppi futuri: 13 | - [ ] 14 | 15 | ### Compilazione APK 16 | - default: ```flutter build apk --split-per-abi``` 17 | - obfuscated: ```flutter build apk --obfuscate --split-debug-info=flutter_application/debug``` 18 | 19 | ### Built With 20 | Per l'implementazione ho utilizzato dell'app mobile ho utilizzato Flutter e come IDE Visual Studio Code (versione 1.63.2) + estensioni Flutter e Dart. 21 | 22 | versione Flutter: 3.0.5 (stable)
23 | versione SDK Dart: 2.17.6 (stable) 24 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/analysis_options.yaml: -------------------------------------------------------------------------------- 1 | # This file configures the analyzer, which statically analyzes Dart code to 2 | # check for errors, warnings, and lints. 3 | # 4 | # The issues identified by the analyzer are surfaced in the UI of Dart-enabled 5 | # IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be 6 | # invoked from the command line by running `flutter analyze`. 7 | 8 | # The following line activates a set of recommended lints for Flutter apps, 9 | # packages, and plugins designed to encourage good coding practices. 10 | include: package:flutter_lints/flutter.yaml 11 | 12 | linter: 13 | # The lint rules applied to this project can be customized in the 14 | # section below to disable rules from the `package:flutter_lints/flutter.yaml` 15 | # included above or to enable additional rules. A list of all available lints 16 | # and their documentation is published at 17 | # https://dart-lang.github.io/linter/lints/index.html. 18 | # 19 | # Instead of disabling a lint rule for the entire project in the 20 | # section below, it can also be suppressed for a single line of code 21 | # or a specific dart file by using the `// ignore: name_of_lint` and 22 | # `// ignore_for_file: name_of_lint` syntax on the line or in the file 23 | # producing the lint. 24 | rules: 25 | # avoid_print: false # Uncomment to disable the `avoid_print` rule 26 | # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule 27 | 28 | # Additional information about this file can be found at 29 | # https://dart.dev/guides/language/analysis-options 30 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/.gitignore: -------------------------------------------------------------------------------- 1 | gradle-wrapper.jar 2 | /.gradle 3 | /captures/ 4 | /gradlew 5 | /gradlew.bat 6 | /local.properties 7 | GeneratedPluginRegistrant.java 8 | .cxx/ 9 | 10 | # Remember to never publicly share your keystore. 11 | # See https://flutter.dev/to/reference-keystore 12 | key.properties 13 | **/*.keystore 14 | **/*.jks 15 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.android.application") 3 | id("kotlin-android") 4 | // The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins. 5 | id("dev.flutter.flutter-gradle-plugin") 6 | } 7 | 8 | android { 9 | namespace = "com.example.roquiz" 10 | compileSdk = flutter.compileSdkVersion 11 | ndkVersion = flutter.ndkVersion 12 | 13 | compileOptions { 14 | sourceCompatibility = JavaVersion.VERSION_11 15 | targetCompatibility = JavaVersion.VERSION_11 16 | } 17 | 18 | kotlinOptions { 19 | jvmTarget = JavaVersion.VERSION_11.toString() 20 | } 21 | 22 | defaultConfig { 23 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 24 | applicationId = "com.example.roquiz" 25 | // You can update the following values to match your application needs. 26 | // For more information, see: https://flutter.dev/to/review-gradle-config. 27 | minSdk = flutter.minSdkVersion 28 | targetSdk = flutter.targetSdkVersion 29 | versionCode = flutter.versionCode 30 | versionName = flutter.versionName 31 | } 32 | 33 | buildTypes { 34 | release { 35 | // TODO: Add your own signing config for the release build. 36 | // Signing with the debug keys for now, so `flutter run --release` works. 37 | signingConfig = signingConfigs.getByName("debug") 38 | } 39 | } 40 | } 41 | 42 | flutter { 43 | source = "../.." 44 | } 45 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 15 | 19 | 23 | 24 | 25 | 26 | 27 | 28 | 30 | 33 | 34 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/kotlin/com/example/roquiz/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.example.roquiz 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity : FlutterActivity() 6 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/drawable-v21/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/build.gradle.kts: -------------------------------------------------------------------------------- 1 | allprojects { 2 | repositories { 3 | google() 4 | mavenCentral() 5 | } 6 | } 7 | 8 | val newBuildDir: Directory = rootProject.layout.buildDirectory.dir("../../build").get() 9 | rootProject.layout.buildDirectory.value(newBuildDir) 10 | 11 | subprojects { 12 | val newSubprojectBuildDir: Directory = newBuildDir.dir(project.name) 13 | project.layout.buildDirectory.value(newSubprojectBuildDir) 14 | } 15 | subprojects { 16 | project.evaluationDependsOn(":app") 17 | } 18 | 19 | tasks.register("clean") { 20 | delete(rootProject.layout.buildDirectory) 21 | } 22 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx8G -XX:MaxMetaspaceSize=4G -XX:ReservedCodeCacheSize=512m -XX:+HeapDumpOnOutOfMemoryError 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.12-all.zip 6 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/android/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | pluginManagement { 2 | val flutterSdkPath = run { 3 | val properties = java.util.Properties() 4 | file("local.properties").inputStream().use { properties.load(it) } 5 | val flutterSdkPath = properties.getProperty("flutter.sdk") 6 | require(flutterSdkPath != null) { "flutter.sdk not set in local.properties" } 7 | flutterSdkPath 8 | } 9 | 10 | includeBuild("$flutterSdkPath/packages/flutter_tools/gradle") 11 | 12 | repositories { 13 | google() 14 | mavenCentral() 15 | gradlePluginPortal() 16 | } 17 | } 18 | 19 | plugins { 20 | id("dev.flutter.flutter-plugin-loader") version "1.0.0" 21 | id("com.android.application") version "8.7.3" apply false 22 | id("org.jetbrains.kotlin.android") version "2.1.0" apply false 23 | } 24 | 25 | include(":app") 26 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/assets/credits.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "author": "TryKatChup", 4 | "task": "Build macOS e iOS", 5 | "url": "https://github.com/TryKatChup" 6 | }, 7 | { 8 | "author": "Federyeeco", 9 | "task": "Build macOS e iOS", 10 | "url": "https://github.com/Federicoand98" 11 | }, 12 | { 13 | "author": "LolloFred", 14 | "task": "Spiegazione domande", 15 | "url": "https://github.com/lollofred" 16 | }, 17 | { 18 | "author": "filovero98", 19 | "task": "Spiegazione domande", 20 | "url": "https://github.com/filippoveronesi" 21 | }, 22 | { 23 | "author": "RedDuality", 24 | "task": "Nuove domande", 25 | "url": "https://github.com/RedDuality" 26 | }, 27 | { 28 | "author": "jchergu", 29 | "task": "Calcolo voto finale e nuove domande", 30 | "url": "https://github.com/jchergu" 31 | } 32 | ] -------------------------------------------------------------------------------- /app-mobile/flutter_application/assets/icons/logo.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | MinimumOSVersion 24 | 11.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import Flutter 3 | 4 | @UIApplicationMain 5 | @objc class AppDelegate: FlutterAppDelegate { 6 | override func application( 7 | _ application: UIApplication, 8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? 9 | ) -> Bool { 10 | GeneratedPluginRegistrant.register(with: self) 11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions) 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/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. -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleDisplayName 8 | Flutter Application 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | flutter_application 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 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UISupportedInterfaceOrientations~ipad 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationPortraitUpsideDown 41 | UIInterfaceOrientationLandscapeLeft 42 | UIInterfaceOrientationLandscapeRight 43 | 44 | UIViewControllerBasedStatusBarAppearance 45 | 46 | CADisableMinimumFrameDurationOnPhone 47 | 48 | UIApplicationSupportsIndirectInputEvents 49 | 50 | 51 | 52 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/main.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:provider/provider.dart'; 3 | import 'package:roquiz/model/PlatformType.dart'; 4 | import 'package:roquiz/persistence/Settings.dart'; 5 | import 'package:roquiz/views/ViewMenu.dart'; 6 | 7 | import 'package:roquiz/model/Themes.dart'; 8 | import 'package:shared_preferences/shared_preferences.dart'; 9 | 10 | import 'package:desktop_window/desktop_window.dart'; 11 | 12 | void main() { 13 | WidgetsFlutterBinding.ensureInitialized(); 14 | 15 | if (getPlatformType() == PlatformType.DESKTOP) { 16 | DesktopWindow.setWindowSize(const Size(800, 800)); 17 | } 18 | 19 | SharedPreferences.getInstance().then((prefs) { 20 | // Read from the SharedPreferences 21 | var isDarkTheme = prefs.getBool("darkTheme") ?? Settings.DEFAULT_DARK_THEME; 22 | 23 | return runApp( 24 | ChangeNotifierProvider( 25 | child: const MyApp(), 26 | create: (BuildContext context) { 27 | return ThemeProvider(isDarkTheme); 28 | }, 29 | ), 30 | ); 31 | }); 32 | } 33 | 34 | class MyApp extends StatelessWidget { 35 | const MyApp({Key? key}) : super(key: key); 36 | 37 | @override 38 | Widget build(BuildContext context) { 39 | return Consumer(builder: (context, value, child) { 40 | return MaterialApp( 41 | title: Settings.APP_TITLE, 42 | themeMode: value.themeMode, 43 | theme: MyThemes.themeLight, 44 | darkTheme: MyThemes.themeDark, 45 | home: const ViewMenu(), 46 | ); 47 | }); 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/Answer.dart: -------------------------------------------------------------------------------- 1 | enum Answer { A, B, C, D, E, NONE } 2 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/AppUpdater.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | import 'dart:io'; 3 | import 'package:http/http.dart' as http; 4 | import 'package:roquiz/model/PlatformType.dart'; 5 | 6 | class AppUpdater { 7 | static Future<(bool, String, String)> checkNewVersion( 8 | String currentVersion) async { 9 | bool newVersionPresent = false; 10 | String newVersion = ""; 11 | String newVersionDownloadURL = ""; 12 | 13 | if (getPlatformType() == PlatformType.WEB) { 14 | return (newVersionPresent, newVersion, newVersionDownloadURL); 15 | } 16 | 17 | http.Response response = await http.get(Uri.parse( 18 | 'https://api.github.com/repos/mikyll/ROQuiz/releases/latest')); 19 | 20 | try { 21 | Map json = jsonDecode(response.body); 22 | String tagName = json['tag_name']; 23 | 24 | if (compareVersions(currentVersion, tagName) == 1) { 25 | newVersionPresent = true; 26 | newVersion = tagName; 27 | 28 | // Retrieve asset link from APIs 29 | List assets = json['assets']; 30 | for (dynamic asset in assets) { 31 | String name = asset['name']; 32 | String downloadUrl = asset['browser_download_url']; 33 | if (getPlatformType() != PlatformType.WEB) { 34 | if (Platform.isAndroid && name.toLowerCase().contains('android')) { 35 | newVersionDownloadURL = downloadUrl; 36 | } else if (Platform.isWindows && 37 | name.toLowerCase().contains('windows')) { 38 | newVersionDownloadURL = downloadUrl; 39 | } else if (Platform.isLinux && 40 | name.toLowerCase().contains('linux')) { 41 | newVersionDownloadURL = downloadUrl; 42 | } 43 | } 44 | } 45 | } 46 | } catch (e) { 47 | print("Error: $e"); 48 | rethrow; 49 | } 50 | 51 | // Test 52 | //print("New version: $newVersionPresent\nVersion tag name: $newVersion\nVersion download URL: $newVersionDownloadURL"); 53 | 54 | return (newVersionPresent, newVersion, newVersionDownloadURL); 55 | } 56 | 57 | static int compareVersions(String localVersion, String remoteVersion) { 58 | List segmentsLocalV = localVersion.replaceAll("v", "").split("."); 59 | List segmentsRemoteV = remoteVersion.replaceAll("v", "").split("."); 60 | 61 | // Get max length 62 | int maxLength = segmentsLocalV.length > segmentsRemoteV.length 63 | ? segmentsLocalV.length 64 | : segmentsRemoteV.length; 65 | 66 | // Add padding '0' to ensure equal length 67 | segmentsLocalV.addAll(List.filled(maxLength - segmentsLocalV.length, '0')); 68 | segmentsRemoteV 69 | .addAll(List.filled(maxLength - segmentsRemoteV.length, '0')); 70 | 71 | // Compare versions 72 | for (int i = 0; i < maxLength; i++) { 73 | int localSegment = int.tryParse(segmentsLocalV[i]) ?? 0; 74 | int remoteSegment = int.tryParse(segmentsRemoteV[i]) ?? 0; 75 | if (remoteSegment > localSegment) { 76 | return 1; 77 | } else if (remoteSegment < localSegment) { 78 | return -1; 79 | } 80 | } 81 | return 0; 82 | } 83 | } 84 | 85 | // Test main 86 | void main(List args) { 87 | print("test"); 88 | // local, remote 89 | print(AppUpdater.compareVersions("v1.10.1", "v1.11.0")); 90 | print(AppUpdater.compareVersions("v1.11.1", "v1.10.0")); 91 | print(AppUpdater.compareVersions("v1.11.0", "v1.10.1")); 92 | print(AppUpdater.compareVersions("v1.11.0", "v1.11.0")); 93 | print(AppUpdater.compareVersions("v1.11.0", "v1.11.4")); 94 | } 95 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/Contribution.dart: -------------------------------------------------------------------------------- 1 | class Contribution { 2 | String author = ""; 3 | String task = ""; 4 | String url = ""; 5 | 6 | Contribution(this.author, this.task, this.url); 7 | 8 | Contribution.fromJson(Map json) { 9 | author = json['author']; 10 | task = json['task']; 11 | url = json['url']; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/PlatformType.dart: -------------------------------------------------------------------------------- 1 | import 'dart:io'; 2 | 3 | enum PlatformType { UNKNOWN, MOBILE, DESKTOP, WEB } 4 | 5 | PlatformType getPlatformType() { 6 | try { 7 | if (Platform.isAndroid || Platform.isIOS) { 8 | return PlatformType.MOBILE; 9 | } else if (Platform.isWindows || Platform.isLinux || Platform.isMacOS) { 10 | return PlatformType.DESKTOP; 11 | } 12 | } catch (e) { 13 | if (e.toString().contains("Unsupported operation")) { 14 | return PlatformType.WEB; 15 | } 16 | } 17 | return PlatformType.UNKNOWN; 18 | } 19 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/Question.dart: -------------------------------------------------------------------------------- 1 | import 'package:roquiz/model/Answer.dart'; 2 | import 'package:roquiz/persistence/Settings.dart'; 3 | 4 | class Question { 5 | int id = -1; 6 | String question = ""; 7 | List answers = []; 8 | Answer correctAnswer = Answer.NONE; 9 | String topic = ""; 10 | 11 | Question(this.id, this.question); 12 | 13 | void addAnswer(String answer) { 14 | if (answers.length == Settings.DEFAULT_ANSWER_NUMBER) { 15 | throw Exception("Answer number excedeed."); 16 | } 17 | //int index = answers.length; 18 | //Answer a = Answer.values[index]; 19 | answers.add(answer); 20 | } 21 | 22 | void setCorrectAnswerFromInt(int correctAnswer) { 23 | this.correctAnswer = Answer.values[correctAnswer]; 24 | } 25 | 26 | void setCorrectAnswerFromEnum(Answer correctAnswer) { 27 | this.correctAnswer = correctAnswer; 28 | } 29 | 30 | void setTopic(String topic) { 31 | this.topic = topic; 32 | } 33 | 34 | void shuffleAnswers() { 35 | List a = answers; 36 | String ca = answers[correctAnswer.index]; 37 | 38 | a.shuffle(); 39 | 40 | answers = []; 41 | for (int i = 0; i < a.length; i++) { 42 | answers.add(a[i]); 43 | if (a[i] == ca) { 44 | correctAnswer = Answer.values[i]; 45 | } 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/Quiz.dart: -------------------------------------------------------------------------------- 1 | import 'package:roquiz/model/Answer.dart'; 2 | import 'package:roquiz/model/Question.dart'; 3 | 4 | class Quiz { 5 | List questions = []; 6 | List answers = []; // user answers (selected or unselected) 7 | int givenAnswers = 0; // total given answers 8 | int correctAnswer = 0; // total correct answers 9 | 10 | /*Quiz(List questions, int qNum, bool shuffleAnswers) { 11 | _resetQuiz(questions, qNum, shuffleAnswers); 12 | }*/ 13 | 14 | void resetQuiz(List questions, int qNum, bool shuffleAnswers) { 15 | this.questions = []; 16 | answers = []; 17 | 18 | // reset Questions 19 | questions.shuffle(); 20 | for (int i = 0; i < qNum; i++) { 21 | if (shuffleAnswers) questions[i].shuffleAnswers(); 22 | 23 | this.questions.add(questions[i]); 24 | answers.add(Answer.NONE); 25 | } 26 | 27 | // reset Answer counters 28 | givenAnswers = 0; 29 | correctAnswer = 0; 30 | } 31 | 32 | void setAnswerFromInt(int index, int value) { 33 | if (answers[index] == Answer.NONE) { 34 | givenAnswers++; 35 | } 36 | 37 | answers[index] = Answer.values[value]; 38 | } 39 | 40 | void setAnswerFromEnum(int index, Answer value) { 41 | if (answers[index] == Answer.NONE) { 42 | givenAnswers++; 43 | } 44 | answers[index] = value; 45 | } 46 | 47 | } 48 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/Utils.dart: -------------------------------------------------------------------------------- 1 | import 'package:roquiz/persistence/QuestionRepository.dart'; 2 | 3 | class Utils { 4 | static String getParsedDateTime(DateTime date) { 5 | if (date == QuestionRepository.CUSTOM_DATE) { 6 | return "personalizzato"; 7 | } else { 8 | return "${date.day < 10 ? "0" : ""}${date.day}/${date.month < 10 ? "0" : ""}${date.month}/${date.year}, ${date.hour < 10 ? "0" : ""}${date.hour}:${date.minute < 10 ? "0" : ""}${date.minute}"; 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/license.dart: -------------------------------------------------------------------------------- 1 | class License { 2 | String title = ""; 3 | String text = ""; 4 | 5 | License(this.title, this.text); 6 | 7 | License.fromJson(Map json) { 8 | title = json['title']; 9 | text = json['text']; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/model/palette.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class IconButtonPalette { 4 | Color? color; 5 | Color? focusColor; 6 | Color? highlightColor; 7 | Color? hoverColor; 8 | Color? iconColor; 9 | Color? overlayColor; 10 | Color? splashColor; 11 | 12 | IconButtonPalette( 13 | {this.color, 14 | this.focusColor, 15 | this.highlightColor, 16 | this.hoverColor, 17 | this.iconColor, 18 | this.overlayColor, 19 | this.splashColor}); 20 | } 21 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/persistence/Settings.dart: -------------------------------------------------------------------------------- 1 | import 'package:shared_preferences/shared_preferences.dart'; 2 | 3 | class Settings { 4 | static const String APP_TITLE = "ROQuiz"; 5 | static const bool SHOW_APP_LOGO = false; 6 | static String VERSION_NUMBER = ""; 7 | static const int DEFAULT_ANSWER_NUMBER = 5; 8 | static const int MIN_QUESTIONS = 1; 9 | static const int MIN_TIMER = 2; 10 | 11 | static const bool DEFAULT_CHECK_APP_UPDATE = true; 12 | static const bool DEFAULT_CHECK_QUESTIONS_UPDATE = true; 13 | static const bool DEFAULT_MAX_QUESTIONS_PER_TOPIC = false; 14 | static int DEFAULT_QUESTION_NUMBER = 16; 15 | static int DEFAULT_TIMER = 18; 16 | static const bool DEFAULT_SHUFFLE_ANSWERS = true; 17 | static const bool DEFAULT_CONFIRM_ALERTS = true; 18 | static const bool DEFAULT_DARK_THEME = false; 19 | 20 | late bool checkAppUpdate = DEFAULT_CHECK_APP_UPDATE; 21 | late bool checkQuestionsUpdate = DEFAULT_CHECK_QUESTIONS_UPDATE; 22 | late bool maxQuestionPerTopic = DEFAULT_MAX_QUESTIONS_PER_TOPIC; 23 | late int questionNumber = DEFAULT_QUESTION_NUMBER; 24 | late int timer = DEFAULT_TIMER; 25 | late bool shuffleAnswers = DEFAULT_SHUFFLE_ANSWERS; 26 | late bool confirmAlerts = DEFAULT_CONFIRM_ALERTS; 27 | late bool darkTheme = DEFAULT_DARK_THEME; 28 | 29 | void loadFromSharedPreferences() async { 30 | final prefs = await SharedPreferences.getInstance(); 31 | 32 | checkAppUpdate = 33 | prefs.getBool("checkAppUpdate") ?? DEFAULT_CHECK_APP_UPDATE; 34 | checkQuestionsUpdate = 35 | prefs.getBool("checkQuestionsUpdate") ?? DEFAULT_CHECK_QUESTIONS_UPDATE; 36 | maxQuestionPerTopic = 37 | prefs.getBool("maxQuestionPerTopic") ?? DEFAULT_MAX_QUESTIONS_PER_TOPIC; 38 | questionNumber = prefs.getInt("questionNumber") ?? DEFAULT_QUESTION_NUMBER; 39 | timer = prefs.getInt("timer") ?? DEFAULT_TIMER; 40 | shuffleAnswers = prefs.getBool("shuffleAnswers") ?? DEFAULT_SHUFFLE_ANSWERS; 41 | confirmAlerts = prefs.getBool("confirmAlerts") ?? DEFAULT_CONFIRM_ALERTS; 42 | darkTheme = prefs.getBool("darkTheme") ?? DEFAULT_DARK_THEME; 43 | } 44 | 45 | void saveToSharedPreferences() async { 46 | final prefs = await SharedPreferences.getInstance(); 47 | 48 | prefs.setBool("checkAppUpdate", checkAppUpdate); 49 | prefs.setBool("checkQuestionsUpdate", checkQuestionsUpdate); 50 | prefs.setBool("maxQuestionPerTopic", maxQuestionPerTopic); 51 | prefs.setInt("questionNumber", questionNumber); 52 | prefs.setInt("timer", timer); 53 | prefs.setBool("shuffleAnswers", shuffleAnswers); 54 | prefs.setBool("confirmAlerts", confirmAlerts); 55 | prefs.setBool("darkTheme", darkTheme); 56 | } 57 | 58 | void resetDefault() async { 59 | final prefs = await SharedPreferences.getInstance(); 60 | 61 | prefs.setBool("checkAppUpdate", DEFAULT_CHECK_APP_UPDATE); 62 | prefs.setBool("checkQuestionsUpdate", DEFAULT_CHECK_QUESTIONS_UPDATE); 63 | prefs.setBool("maxQuestionPerTopic", DEFAULT_MAX_QUESTIONS_PER_TOPIC); 64 | prefs.setInt("questionNumber", DEFAULT_QUESTION_NUMBER); 65 | prefs.setInt("timer", DEFAULT_TIMER); 66 | prefs.setBool("shuffleAnswers", DEFAULT_SHUFFLE_ANSWERS); 67 | prefs.setBool("confirmAlerts", DEFAULT_CONFIRM_ALERTS); 68 | } 69 | 70 | String toString() { 71 | return ""; 72 | } 73 | } 74 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/views/ViewCredits.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | import 'package:flutter/material.dart'; 4 | import 'package:roquiz/model/Contribution.dart'; 5 | import 'package:roquiz/widget/credits_widget.dart'; 6 | 7 | class ViewCredits extends StatelessWidget { 8 | const ViewCredits({Key? key}) : super(key: key); 9 | 10 | Future> loadCredits(BuildContext context) async { 11 | final bundle = DefaultAssetBundle.of(context); 12 | final contributors = await bundle.loadString("assets/credits.json"); 13 | 14 | return json 15 | .decode(contributors) 16 | .map((contributor) => Contribution.fromJson(contributor)) 17 | .toList(); 18 | } 19 | 20 | @override 21 | Widget build(BuildContext context) { 22 | return Scaffold( 23 | extendBodyBehindAppBar: true, 24 | appBar: AppBar( 25 | title: const Text("Crediti"), 26 | centerTitle: true, 27 | automaticallyImplyLeading: true, 28 | leading: IconButton( 29 | icon: const Icon(Icons.arrow_back_ios), 30 | onPressed: () { 31 | Navigator.pop(context); 32 | }), 33 | ), 34 | body: SafeArea( 35 | child: FutureBuilder>( 36 | future: loadCredits(context), 37 | builder: (context, snapshot) { 38 | final licenses = snapshot.data; 39 | 40 | switch (snapshot.connectionState) { 41 | case ConnectionState.waiting: 42 | return const Center(child: CircularProgressIndicator()); 43 | default: 44 | if (snapshot.hasError) { 45 | return const Center(child: Text('Some error occurred!')); 46 | } else { 47 | return CreditsWidget(credits: licenses!); 48 | } 49 | } 50 | }, 51 | ), 52 | ), 53 | ); 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/views/ViewLicenses.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | import 'package:flutter/material.dart'; 4 | import 'package:roquiz/model/license.dart'; 5 | import 'package:roquiz/widget/licenses_widget.dart'; 6 | 7 | class ViewLicenses extends StatelessWidget { 8 | const ViewLicenses({Key? key}) : super(key: key); 9 | 10 | Future> loadLicenses(BuildContext context) async { 11 | final bundle = DefaultAssetBundle.of(context); 12 | final licenses = await bundle.loadString("assets/licenses.json"); 13 | 14 | return json 15 | .decode(licenses) 16 | .map((license) => License.fromJson(license)) 17 | .toList(); 18 | } 19 | 20 | @override 21 | Widget build(BuildContext context) { 22 | return Scaffold( 23 | extendBodyBehindAppBar: true, 24 | appBar: AppBar( 25 | title: const Text("Licenses"), 26 | centerTitle: true, 27 | automaticallyImplyLeading: true, 28 | leading: IconButton( 29 | icon: const Icon(Icons.arrow_back_ios), 30 | onPressed: () { 31 | Navigator.pop(context); 32 | }), 33 | ), 34 | body: SafeArea( 35 | child: FutureBuilder>( 36 | future: loadLicenses(context), 37 | builder: (context, snapshot) { 38 | final licenses = snapshot.data; 39 | 40 | switch (snapshot.connectionState) { 41 | case ConnectionState.waiting: 42 | return const Center(child: CircularProgressIndicator()); 43 | default: 44 | if (snapshot.hasError) { 45 | return const Center(child: Text('Some error occurred!')); 46 | } else { 47 | return LicensesWidget(licenses: licenses!); 48 | } 49 | } 50 | }, 51 | ), 52 | ), 53 | ); 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/widget/change_theme_button_widget.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:provider/provider.dart'; 3 | import 'package:roquiz/model/Themes.dart'; 4 | 5 | class ChangeThemeButtonWidget extends StatelessWidget { 6 | const ChangeThemeButtonWidget({Key? key}) : super(key: key); 7 | 8 | @override 9 | Widget build(BuildContext context) { 10 | final themeProvider = Provider.of(context); 11 | 12 | return Switch.adaptive( 13 | value: themeProvider.isDarkMode, 14 | onChanged: (v) { 15 | final provider = Provider.of(context, listen: false); 16 | 17 | provider.toggleTheme(v); 18 | }); 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/widget/confirmation_alert.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class ConfirmationAlert extends StatelessWidget { 4 | const ConfirmationAlert( 5 | {Key? key, 6 | this.onConfirm, 7 | this.onCancel, 8 | this.buttonConfirmText = "Conferma", 9 | this.buttonCancelText = "Annulla", 10 | required this.title, 11 | required this.content}) 12 | : super(key: key); 13 | 14 | static void showConfirmationDialog( 15 | BuildContext context, 16 | String title, 17 | String content, { 18 | String confirmButton = "Conferma", 19 | String cancelButton = "Annulla", 20 | void Function()? onConfirm, 21 | void Function()? onCancel, 22 | }) { 23 | showDialog( 24 | context: context, 25 | builder: (BuildContext context) { 26 | return ConfirmationAlert( 27 | title: title, 28 | content: content, 29 | buttonConfirmText: confirmButton, 30 | buttonCancelText: cancelButton, 31 | onConfirm: onConfirm == null 32 | ? null 33 | : () { 34 | onConfirm(); 35 | Navigator.pop(context); 36 | }, 37 | onCancel: onCancel == null 38 | ? null 39 | : () { 40 | onCancel(); 41 | Navigator.pop(context); 42 | }, 43 | ); 44 | }); 45 | } 46 | 47 | final String title; 48 | final String content; 49 | final String buttonConfirmText; 50 | final String buttonCancelText; 51 | final Function? onConfirm; 52 | final Function? onCancel; 53 | 54 | @override 55 | Widget build(BuildContext context) { 56 | return AlertDialog( 57 | title: Text(title), 58 | content: Text(content), 59 | actions: [ 60 | TextButton( 61 | onPressed: onConfirm != null 62 | ? () { 63 | onConfirm!(); 64 | } 65 | : null, 66 | child: Text(buttonConfirmText), 67 | ), 68 | TextButton( 69 | onPressed: onCancel != null 70 | ? () { 71 | onCancel!(); 72 | } 73 | : null, 74 | child: Text(buttonCancelText), 75 | ), 76 | ], 77 | ); 78 | } 79 | } 80 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/widget/credits_widget.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:roquiz/model/Contribution.dart'; 3 | import 'package:url_launcher/url_launcher.dart'; 4 | 5 | class CreditsWidget extends StatefulWidget { 6 | final List credits; 7 | 8 | const CreditsWidget({ 9 | Key? key, 10 | required this.credits, 11 | }) : super(key: key); 12 | 13 | @override 14 | State createState() => CreditsWidgetState(); 15 | } 16 | 17 | class CreditsWidgetState extends State { 18 | List credits = []; 19 | final List alreadyAddedCredits = []; 20 | final List creditWidgets = []; 21 | 22 | Future _launchInBrowser(String url) async { 23 | if (!await launchUrl(Uri.parse(url), 24 | mode: LaunchMode.externalApplication)) { 25 | throw 'Could not launch $url'; 26 | } 27 | } 28 | 29 | bool _containsContribution( 30 | List contributionList, Contribution other) { 31 | for (Contribution contribution in contributionList) { 32 | if (contribution.task == other.task) return true; 33 | } 34 | return false; 35 | } 36 | 37 | @override 38 | void initState() { 39 | super.initState(); 40 | 41 | setState(() { 42 | credits = widget.credits; 43 | }); 44 | 45 | for (int i = 0; i < credits.length; i++) { 46 | Contribution contribution = credits[i]; 47 | 48 | bool alreadyPresent = 49 | _containsContribution(alreadyAddedCredits, contribution); 50 | 51 | Padding widget = Padding( 52 | padding: EdgeInsets.only(top: !alreadyPresent ? 20.0 : 5.0), 53 | child: Row( 54 | children: [ 55 | Expanded( 56 | child: Text(!alreadyPresent ? "${contribution.task}: " : "", 57 | maxLines: 2, style: const TextStyle(fontSize: 18))), 58 | Row( 59 | children: [ 60 | Text(!alreadyPresent ? "" : "& ", 61 | textAlign: TextAlign.center, 62 | style: const TextStyle(fontSize: 18)), 63 | InkWell( 64 | onTap: () { 65 | _launchInBrowser(contribution.url); 66 | }, 67 | child: Text(contribution.author, 68 | textAlign: TextAlign.center, 69 | style: const TextStyle( 70 | fontSize: 18, decoration: TextDecoration.underline)), 71 | ), 72 | ], 73 | ), 74 | ], 75 | ), 76 | ); 77 | setState(() { 78 | creditWidgets.add(widget); 79 | 80 | if (!alreadyPresent) { 81 | alreadyAddedCredits.add(contribution); 82 | } 83 | }); 84 | } 85 | } 86 | 87 | @override 88 | Widget build(BuildContext context) => Container( 89 | alignment: Alignment.centerLeft, 90 | child: ListView.builder( 91 | shrinkWrap: true, 92 | padding: const EdgeInsets.all(25.0), 93 | itemCount: widget.credits.length, 94 | itemBuilder: (context, index) { 95 | return creditWidgets[index]; 96 | }, 97 | ), 98 | ); 99 | } 100 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/lib/widget/licenses_widget.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:roquiz/model/license.dart'; 3 | 4 | class LicensesWidget extends StatelessWidget { 5 | final List licenses; 6 | 7 | const LicensesWidget({ 8 | Key? key, 9 | required this.licenses, 10 | }) : super(key: key); 11 | 12 | @override 13 | Widget build(BuildContext context) => ListView.builder( 14 | padding: const EdgeInsets.only(bottom: 24), 15 | itemCount: licenses.length, 16 | itemBuilder: (context, index) { 17 | final license = licenses[index]; 18 | 19 | return ListTile( 20 | title: Container( 21 | padding: const EdgeInsets.symmetric(vertical: 24), 22 | child: SelectableText( 23 | license.title, 24 | style: 25 | const TextStyle(fontSize: 24, fontWeight: FontWeight.bold), 26 | ), 27 | ), 28 | subtitle: SelectableText( 29 | license.text, 30 | style: const TextStyle(fontSize: 18), 31 | ), 32 | ); 33 | }, 34 | ); 35 | } 36 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/linux/.gitignore: -------------------------------------------------------------------------------- 1 | flutter/ephemeral 2 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | 12 | void fl_register_plugins(FlPluginRegistry* registry) { 13 | g_autoptr(FlPluginRegistrar) desktop_window_registrar = 14 | fl_plugin_registry_get_registrar_for_plugin(registry, "DesktopWindowPlugin"); 15 | desktop_window_plugin_register_with_registrar(desktop_window_registrar); 16 | g_autoptr(FlPluginRegistrar) url_launcher_linux_registrar = 17 | fl_plugin_registry_get_registrar_for_plugin(registry, "UrlLauncherPlugin"); 18 | url_launcher_plugin_register_with_registrar(url_launcher_linux_registrar); 19 | } 20 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/linux/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | desktop_window 7 | url_launcher_linux 8 | ) 9 | 10 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 11 | ) 12 | 13 | set(PLUGIN_BUNDLED_LIBRARIES) 14 | 15 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 16 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin}) 17 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 18 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 19 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 20 | endforeach(plugin) 21 | 22 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 23 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin}) 24 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 25 | endforeach(ffi_plugin) 26 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/linux/my_application.cc: -------------------------------------------------------------------------------- 1 | #include "my_application.h" 2 | 3 | #include 4 | #ifdef GDK_WINDOWING_X11 5 | #include 6 | #endif 7 | 8 | #include "flutter/generated_plugin_registrant.h" 9 | 10 | struct _MyApplication { 11 | GtkApplication parent_instance; 12 | char** dart_entrypoint_arguments; 13 | }; 14 | 15 | G_DEFINE_TYPE(MyApplication, my_application, GTK_TYPE_APPLICATION) 16 | 17 | // Implements GApplication::activate. 18 | static void my_application_activate(GApplication* application) { 19 | MyApplication* self = MY_APPLICATION(application); 20 | GtkWindow* window = 21 | GTK_WINDOW(gtk_application_window_new(GTK_APPLICATION(application))); 22 | 23 | // Use a header bar when running in GNOME as this is the common style used 24 | // by applications and is the setup most users will be using (e.g. Ubuntu 25 | // desktop). 26 | // If running on X and not using GNOME then just use a traditional title bar 27 | // in case the window manager does more exotic layout, e.g. tiling. 28 | // If running on Wayland assume the header bar will work (may need changing 29 | // if future cases occur). 30 | gboolean use_header_bar = TRUE; 31 | #ifdef GDK_WINDOWING_X11 32 | GdkScreen* screen = gtk_window_get_screen(window); 33 | if (GDK_IS_X11_SCREEN(screen)) { 34 | const gchar* wm_name = gdk_x11_screen_get_window_manager_name(screen); 35 | if (g_strcmp0(wm_name, "GNOME Shell") != 0) { 36 | use_header_bar = FALSE; 37 | } 38 | } 39 | #endif 40 | if (use_header_bar) { 41 | GtkHeaderBar* header_bar = GTK_HEADER_BAR(gtk_header_bar_new()); 42 | gtk_widget_show(GTK_WIDGET(header_bar)); 43 | gtk_header_bar_set_title(header_bar, "flutter_application"); 44 | gtk_header_bar_set_show_close_button(header_bar, TRUE); 45 | gtk_window_set_titlebar(window, GTK_WIDGET(header_bar)); 46 | } else { 47 | gtk_window_set_title(window, "flutter_application"); 48 | } 49 | 50 | gtk_window_set_default_size(window, 1280, 720); 51 | gtk_widget_show(GTK_WIDGET(window)); 52 | 53 | g_autoptr(FlDartProject) project = fl_dart_project_new(); 54 | fl_dart_project_set_dart_entrypoint_arguments(project, self->dart_entrypoint_arguments); 55 | 56 | FlView* view = fl_view_new(project); 57 | gtk_widget_show(GTK_WIDGET(view)); 58 | gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(view)); 59 | 60 | fl_register_plugins(FL_PLUGIN_REGISTRY(view)); 61 | 62 | gtk_widget_grab_focus(GTK_WIDGET(view)); 63 | } 64 | 65 | // Implements GApplication::local_command_line. 66 | static gboolean my_application_local_command_line(GApplication* application, gchar*** arguments, int* exit_status) { 67 | MyApplication* self = MY_APPLICATION(application); 68 | // Strip out the first argument as it is the binary name. 69 | self->dart_entrypoint_arguments = g_strdupv(*arguments + 1); 70 | 71 | g_autoptr(GError) error = nullptr; 72 | if (!g_application_register(application, nullptr, &error)) { 73 | g_warning("Failed to register: %s", error->message); 74 | *exit_status = 1; 75 | return TRUE; 76 | } 77 | 78 | g_application_activate(application); 79 | *exit_status = 0; 80 | 81 | return TRUE; 82 | } 83 | 84 | // Implements GObject::dispose. 85 | static void my_application_dispose(GObject* object) { 86 | MyApplication* self = MY_APPLICATION(object); 87 | g_clear_pointer(&self->dart_entrypoint_arguments, g_strfreev); 88 | G_OBJECT_CLASS(my_application_parent_class)->dispose(object); 89 | } 90 | 91 | static void my_application_class_init(MyApplicationClass* klass) { 92 | G_APPLICATION_CLASS(klass)->activate = my_application_activate; 93 | G_APPLICATION_CLASS(klass)->local_command_line = my_application_local_command_line; 94 | G_OBJECT_CLASS(klass)->dispose = my_application_dispose; 95 | } 96 | 97 | static void my_application_init(MyApplication* self) {} 98 | 99 | MyApplication* my_application_new() { 100 | return MY_APPLICATION(g_object_new(my_application_get_type(), 101 | "application-id", APPLICATION_ID, 102 | "flags", G_APPLICATION_NON_UNIQUE, 103 | nullptr)); 104 | } 105 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/linux/runner/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.13) 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} 10 | "main.cc" 11 | "my_application.cc" 12 | "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc" 13 | ) 14 | 15 | # Apply the standard set of build settings. This can be removed for applications 16 | # that need different build settings. 17 | apply_standard_settings(${BINARY_NAME}) 18 | 19 | # Add preprocessor definitions for the application ID. 20 | add_definitions(-DAPPLICATION_ID="${APPLICATION_ID}") 21 | 22 | # Add dependency libraries. Add any application-specific dependencies here. 23 | target_link_libraries(${BINARY_NAME} PRIVATE flutter) 24 | target_link_libraries(${BINARY_NAME} PRIVATE PkgConfig::GTK) 25 | 26 | target_include_directories(${BINARY_NAME} PRIVATE "${CMAKE_SOURCE_DIR}") 27 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/linux/runner/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/linux/runner/my_application.cc: -------------------------------------------------------------------------------- 1 | #include "my_application.h" 2 | 3 | #include 4 | #ifdef GDK_WINDOWING_X11 5 | #include 6 | #endif 7 | 8 | #include "flutter/generated_plugin_registrant.h" 9 | 10 | struct _MyApplication { 11 | GtkApplication parent_instance; 12 | char** dart_entrypoint_arguments; 13 | }; 14 | 15 | G_DEFINE_TYPE(MyApplication, my_application, GTK_TYPE_APPLICATION) 16 | 17 | // Implements GApplication::activate. 18 | static void my_application_activate(GApplication* application) { 19 | MyApplication* self = MY_APPLICATION(application); 20 | GtkWindow* window = 21 | GTK_WINDOW(gtk_application_window_new(GTK_APPLICATION(application))); 22 | 23 | // Use a header bar when running in GNOME as this is the common style used 24 | // by applications and is the setup most users will be using (e.g. Ubuntu 25 | // desktop). 26 | // If running on X and not using GNOME then just use a traditional title bar 27 | // in case the window manager does more exotic layout, e.g. tiling. 28 | // If running on Wayland assume the header bar will work (may need changing 29 | // if future cases occur). 30 | gboolean use_header_bar = TRUE; 31 | #ifdef GDK_WINDOWING_X11 32 | GdkScreen* screen = gtk_window_get_screen(window); 33 | if (GDK_IS_X11_SCREEN(screen)) { 34 | const gchar* wm_name = gdk_x11_screen_get_window_manager_name(screen); 35 | if (g_strcmp0(wm_name, "GNOME Shell") != 0) { 36 | use_header_bar = FALSE; 37 | } 38 | } 39 | #endif 40 | if (use_header_bar) { 41 | GtkHeaderBar* header_bar = GTK_HEADER_BAR(gtk_header_bar_new()); 42 | gtk_widget_show(GTK_WIDGET(header_bar)); 43 | gtk_header_bar_set_title(header_bar, "flutter_application"); 44 | gtk_header_bar_set_show_close_button(header_bar, TRUE); 45 | gtk_window_set_titlebar(window, GTK_WIDGET(header_bar)); 46 | } else { 47 | gtk_window_set_title(window, "flutter_application"); 48 | } 49 | 50 | gtk_window_set_default_size(window, 1280, 720); 51 | gtk_widget_show(GTK_WIDGET(window)); 52 | 53 | g_autoptr(FlDartProject) project = fl_dart_project_new(); 54 | fl_dart_project_set_dart_entrypoint_arguments(project, self->dart_entrypoint_arguments); 55 | 56 | FlView* view = fl_view_new(project); 57 | gtk_widget_show(GTK_WIDGET(view)); 58 | gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(view)); 59 | 60 | fl_register_plugins(FL_PLUGIN_REGISTRY(view)); 61 | 62 | gtk_widget_grab_focus(GTK_WIDGET(view)); 63 | } 64 | 65 | // Implements GApplication::local_command_line. 66 | static gboolean my_application_local_command_line(GApplication* application, gchar*** arguments, int* exit_status) { 67 | MyApplication* self = MY_APPLICATION(application); 68 | // Strip out the first argument as it is the binary name. 69 | self->dart_entrypoint_arguments = g_strdupv(*arguments + 1); 70 | 71 | g_autoptr(GError) error = nullptr; 72 | if (!g_application_register(application, nullptr, &error)) { 73 | g_warning("Failed to register: %s", error->message); 74 | *exit_status = 1; 75 | return TRUE; 76 | } 77 | 78 | g_application_activate(application); 79 | *exit_status = 0; 80 | 81 | return TRUE; 82 | } 83 | 84 | // Implements GApplication::startup. 85 | static void my_application_startup(GApplication* application) { 86 | //MyApplication* self = MY_APPLICATION(object); 87 | 88 | // Perform any actions required at application startup. 89 | 90 | G_APPLICATION_CLASS(my_application_parent_class)->startup(application); 91 | } 92 | 93 | // Implements GApplication::shutdown. 94 | static void my_application_shutdown(GApplication* application) { 95 | //MyApplication* self = MY_APPLICATION(object); 96 | 97 | // Perform any actions required at application shutdown. 98 | 99 | G_APPLICATION_CLASS(my_application_parent_class)->shutdown(application); 100 | } 101 | 102 | // Implements GObject::dispose. 103 | static void my_application_dispose(GObject* object) { 104 | MyApplication* self = MY_APPLICATION(object); 105 | g_clear_pointer(&self->dart_entrypoint_arguments, g_strfreev); 106 | G_OBJECT_CLASS(my_application_parent_class)->dispose(object); 107 | } 108 | 109 | static void my_application_class_init(MyApplicationClass* klass) { 110 | G_APPLICATION_CLASS(klass)->activate = my_application_activate; 111 | G_APPLICATION_CLASS(klass)->local_command_line = my_application_local_command_line; 112 | G_APPLICATION_CLASS(klass)->startup = my_application_startup; 113 | G_APPLICATION_CLASS(klass)->shutdown = my_application_shutdown; 114 | G_OBJECT_CLASS(klass)->dispose = my_application_dispose; 115 | } 116 | 117 | static void my_application_init(MyApplication* self) {} 118 | 119 | MyApplication* my_application_new() { 120 | // Set the program name to the application ID, which helps various systems 121 | // like GTK and desktop environments map this running application to its 122 | // corresponding .desktop file. This ensures better integration by allowing 123 | // the application to be recognized beyond its binary name. 124 | g_set_prgname(APPLICATION_ID); 125 | 126 | return MY_APPLICATION(g_object_new(my_application_get_type(), 127 | "application-id", APPLICATION_ID, 128 | "flags", G_APPLICATION_NON_UNIQUE, 129 | nullptr)); 130 | } 131 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/linux/runner/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/.gitignore: -------------------------------------------------------------------------------- 1 | # Flutter-related 2 | **/Flutter/ephemeral/ 3 | **/Pods/ 4 | 5 | # Xcode-related 6 | **/dgph 7 | **/xcuserdata/ 8 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Flutter/Flutter-Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "ephemeral/Flutter-Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Flutter/Flutter-Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "ephemeral/Flutter-Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Flutter/GeneratedPluginRegistrant.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | import FlutterMacOS 6 | import Foundation 7 | 8 | import desktop_window 9 | import file_picker 10 | import package_info_plus 11 | import path_provider_foundation 12 | import shared_preferences_foundation 13 | import url_launcher_macos 14 | 15 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { 16 | DesktopWindowPlugin.register(with: registry.registrar(forPlugin: "DesktopWindowPlugin")) 17 | FilePickerPlugin.register(with: registry.registrar(forPlugin: "FilePickerPlugin")) 18 | FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin")) 19 | PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) 20 | SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) 21 | UrlLauncherPlugin.register(with: registry.registrar(forPlugin: "UrlLauncherPlugin")) 22 | } 23 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import Cocoa 2 | import FlutterMacOS 3 | 4 | @NSApplicationMain 5 | class AppDelegate: FlutterAppDelegate { 6 | override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool { 7 | return true 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "16x16", 5 | "idiom" : "mac", 6 | "filename" : "app_icon_16.png", 7 | "scale" : "1x" 8 | }, 9 | { 10 | "size" : "16x16", 11 | "idiom" : "mac", 12 | "filename" : "app_icon_32.png", 13 | "scale" : "2x" 14 | }, 15 | { 16 | "size" : "32x32", 17 | "idiom" : "mac", 18 | "filename" : "app_icon_32.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "32x32", 23 | "idiom" : "mac", 24 | "filename" : "app_icon_64.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "128x128", 29 | "idiom" : "mac", 30 | "filename" : "app_icon_128.png", 31 | "scale" : "1x" 32 | }, 33 | { 34 | "size" : "128x128", 35 | "idiom" : "mac", 36 | "filename" : "app_icon_256.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "256x256", 41 | "idiom" : "mac", 42 | "filename" : "app_icon_256.png", 43 | "scale" : "1x" 44 | }, 45 | { 46 | "size" : "256x256", 47 | "idiom" : "mac", 48 | "filename" : "app_icon_512.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "512x512", 53 | "idiom" : "mac", 54 | "filename" : "app_icon_512.png", 55 | "scale" : "1x" 56 | }, 57 | { 58 | "size" : "512x512", 59 | "idiom" : "mac", 60 | "filename" : "app_icon_1024.png", 61 | "scale" : "2x" 62 | } 63 | ], 64 | "info" : { 65 | "version" : 1, 66 | "author" : "xcode" 67 | } 68 | } 69 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 = flutter_application 9 | 10 | // The application's bundle identifier 11 | PRODUCT_BUNDLE_IDENTIFIER = com.example.flutterApplication 12 | 13 | // The copyright displayed in application information 14 | PRODUCT_COPYRIGHT = Copyright © 2023 com.example. All rights reserved. 15 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Configs/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Debug.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Configs/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Release.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/DebugProfile.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | com.apple.security.cs.allow-jit 8 | 9 | com.apple.security.network.server 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/macos/Runner/Release.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: roquiz 2 | description: Applicazione per esercitarsi con i quiz di Ricerca Operativa M. 3 | 4 | # The following line prevents the package from being accidentally published to 5 | # pub.dev using `flutter pub publish`. This is preferred for private packages. 6 | publish_to: "none" # Remove this line if you wish to publish to pub.dev 7 | 8 | # The following defines the version and build number for your application. 9 | # A version number is three numbers separated by dots, like 1.2.43 10 | # followed by an optional build number separated by a +. 11 | # Both the version and the builder number may be overridden in flutter 12 | # build by specifying --build-name and --build-number, respectively. 13 | # In Android, build-name is used as versionName while build-number used as versionCode. 14 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning 15 | # In iOS, build-name is used as CFBundleShortVersionString while build-number is used as CFBundleVersion. 16 | # Read more about iOS versioning at 17 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html 18 | # In Windows, build-name is used as the major, minor, and patch parts 19 | # of the product and file versions while build-number is used as the build suffix. 20 | version: 1.11.4 21 | 22 | environment: 23 | sdk: ">=3.0.6 <4.0.0" 24 | 25 | # Dependencies specify other packages that your package needs in order to work. 26 | # To automatically upgrade your package dependencies to the latest versions 27 | # consider running `flutter pub upgrade --major-versions`. Alternatively, 28 | # dependencies can be manually updated by changing the version numbers below to 29 | # the latest version available on pub.dev. To see which dependencies have newer 30 | # versions available, run `flutter pub outdated`. 31 | dependencies: 32 | flutter: 33 | sdk: flutter 34 | 35 | # state management 36 | provider: ^6.0.2 37 | 38 | # state management, intelligent dependency injection, and route management 39 | url_launcher: ^6.1.12 40 | shared_preferences: ^2.2.0 41 | package_info_plus: ^8.1.3 42 | path_provider: ^2.0.15 43 | file_picker: ^8.1.7 44 | desktop_window: ^0.4.0 45 | flutter_svg: ^2.0.9 46 | http: ^1.2.0 47 | 48 | dev_dependencies: 49 | flutter_test: 50 | sdk: flutter 51 | 52 | # The "flutter_lints" package below contains a set of recommended lints to 53 | # encourage good coding practices. The lint set provided by the package is 54 | # activated in the `analysis_options.yaml` file located at the root of your 55 | # package. See that file for information about deactivating specific lint 56 | # rules and activating additional ones. 57 | flutter_lints: ^5.0.0 58 | 59 | # For information on the generic Dart part of this file, see the 60 | # following page: https://dart.dev/tools/pub/pubspec 61 | 62 | # The following section is specific to Flutter packages. 63 | flutter: 64 | assets: 65 | - assets/licenses.json 66 | - assets/domande.txt 67 | - assets/credits.json 68 | - assets/icons/logo.svg 69 | 70 | # The following line ensures that the Material Icons font is 71 | # included with your application, so that you can use the icons in 72 | # the material Icons class. 73 | uses-material-design: true 74 | 75 | # To add assets to your application, add an assets section, like this: 76 | # assets: 77 | # - images/a_dot_burr.jpeg 78 | # - images/a_dot_ham.jpeg 79 | 80 | # An image asset can refer to one or more resolution-specific "variants", see 81 | # https://flutter.dev/assets-and-images/#resolution-aware 82 | 83 | # For details regarding adding assets from package dependencies, see 84 | # https://flutter.dev/assets-and-images/#from-packages 85 | 86 | # To add custom fonts to your application, add a fonts section here, 87 | # in this "flutter" section. Each entry in this list should have a 88 | # "family" key with the font family name, and a "fonts" key with a 89 | # list giving the asset and other descriptors for the font. For 90 | # example: 91 | # fonts: 92 | # - family: Schyler 93 | # fonts: 94 | # - asset: fonts/Schyler-Regular.ttf 95 | # - asset: fonts/Schyler-Italic.ttf 96 | # style: italic 97 | # - family: Trajan Pro 98 | # fonts: 99 | # - asset: fonts/TrajanPro.ttf 100 | # - asset: fonts/TrajanPro_Bold.ttf 101 | # weight: 700 102 | # 103 | # For details regarding fonts from package dependencies, 104 | # see https://flutter.dev/custom-fonts/#from-packages 105 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/web/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/web/favicon.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/web/icons/Icon-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/web/icons/Icon-192.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/web/icons/Icon-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/web/icons/Icon-512.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/web/icons/Icon-maskable-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/web/icons/Icon-maskable-192.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/web/icons/Icon-maskable-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/web/icons/Icon-maskable-512.png -------------------------------------------------------------------------------- /app-mobile/flutter_application/web/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | flutter_application 33 | 34 | 35 | 39 | 40 | 41 | 42 | 43 | 58 | 59 | 60 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/web/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "flutter_application", 3 | "short_name": "flutter_application", 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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/windows/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Project-level configuration. 2 | cmake_minimum_required(VERSION 3.14) 3 | project(roquiz 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 "roquiz") 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 | # Copy the native assets provided by the build.dart from all packages. 91 | set(NATIVE_ASSETS_DIR "${PROJECT_BUILD_DIR}native_assets/windows/") 92 | install(DIRECTORY "${NATIVE_ASSETS_DIR}" 93 | DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" 94 | COMPONENT Runtime) 95 | 96 | # Fully re-copy the assets directory on each build to avoid having stale files 97 | # from a previous install. 98 | set(FLUTTER_ASSET_DIR_NAME "flutter_assets") 99 | install(CODE " 100 | file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\") 101 | " COMPONENT Runtime) 102 | install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}" 103 | DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime) 104 | 105 | # Install the AOT library on non-Debug builds only. 106 | install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" 107 | CONFIGURATIONS Profile;Release 108 | COMPONENT Runtime) 109 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | 12 | void RegisterPlugins(flutter::PluginRegistry* registry) { 13 | DesktopWindowPluginRegisterWithRegistrar( 14 | registry->GetRegistrarForPlugin("DesktopWindowPlugin")); 15 | UrlLauncherWindowsRegisterWithRegistrar( 16 | registry->GetRegistrarForPlugin("UrlLauncherWindows")); 17 | } 18 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/windows/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | desktop_window 7 | url_launcher_windows 8 | ) 9 | 10 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 11 | ) 12 | 13 | set(PLUGIN_BUNDLED_LIBRARIES) 14 | 15 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 16 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin}) 17 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 18 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 19 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 20 | endforeach(plugin) 21 | 22 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 23 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin}) 24 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 25 | endforeach(ffi_plugin) 26 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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", "it.unibo" "\0" 93 | VALUE "FileDescription", "roquiz" "\0" 94 | VALUE "FileVersion", VERSION_AS_STRING "\0" 95 | VALUE "InternalName", "roquiz" "\0" 96 | VALUE "LegalCopyright", "Copyright (C) 2025 it.unibo. All rights reserved." "\0" 97 | VALUE "OriginalFilename", "roquiz.exe" "\0" 98 | VALUE "ProductName", "roquiz" "\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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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"roquiz", 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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/windows/runner/resources/app_icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/app-mobile/flutter_application/windows/runner/resources/app_icon.ico -------------------------------------------------------------------------------- /app-mobile/flutter_application/windows/runner/runner.exe.manifest: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PerMonitorV2 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | unsigned 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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /app-mobile/flutter_application/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 | -------------------------------------------------------------------------------- /gfx/Download Build.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Download Build.png -------------------------------------------------------------------------------- /gfx/Java Installation Guide/InstallJava (1).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Java Installation Guide/InstallJava (1).png -------------------------------------------------------------------------------- /gfx/Java Installation Guide/InstallJava (2).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Java Installation Guide/InstallJava (2).png -------------------------------------------------------------------------------- /gfx/Java Installation Guide/InstallJava (3).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Java Installation Guide/InstallJava (3).png -------------------------------------------------------------------------------- /gfx/Java Installation Guide/InstallJava (4).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Java Installation Guide/InstallJava (4).png -------------------------------------------------------------------------------- /gfx/Java Installation Guide/InstallJava (5).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Java Installation Guide/InstallJava (5).png -------------------------------------------------------------------------------- /gfx/Java Installation Guide/InstallJava (6).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Java Installation Guide/InstallJava (6).png -------------------------------------------------------------------------------- /gfx/Java Installation Guide/InstallJava (7).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Java Installation Guide/InstallJava (7).png -------------------------------------------------------------------------------- /gfx/Java Installation Guide/InstallJava (8).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Java Installation Guide/InstallJava (8).png -------------------------------------------------------------------------------- /gfx/Project Setup/Project Setup (1).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Project Setup/Project Setup (1).png -------------------------------------------------------------------------------- /gfx/Project Setup/Project Setup (2).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Project Setup/Project Setup (2).png -------------------------------------------------------------------------------- /gfx/Project Setup/Project Setup (3).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Project Setup/Project Setup (3).png -------------------------------------------------------------------------------- /gfx/Project Setup/Project Setup (4).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Project Setup/Project Setup (4).png -------------------------------------------------------------------------------- /gfx/Project Setup/Project Setup (5).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Project Setup/Project Setup (5).png -------------------------------------------------------------------------------- /gfx/Project Setup/Project Setup (6).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Project Setup/Project Setup (6).png -------------------------------------------------------------------------------- /gfx/ROQuizDesktop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/ROQuizDesktop.png -------------------------------------------------------------------------------- /gfx/ROQuizDesktopResized.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/ROQuizDesktopResized.png -------------------------------------------------------------------------------- /gfx/ROQuizMobile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/ROQuizMobile.png -------------------------------------------------------------------------------- /gfx/ROQuizMobileOld.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/ROQuizMobileOld.png -------------------------------------------------------------------------------- /gfx/ROQuizMobileResized.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/ROQuizMobileResized.png -------------------------------------------------------------------------------- /gfx/Thumbnail.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/Thumbnail.png -------------------------------------------------------------------------------- /gfx/ThumbnailOld.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/ThumbnailOld.png -------------------------------------------------------------------------------- /gfx/ThumbnailOld2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/ThumbnailOld2.png -------------------------------------------------------------------------------- /gfx/[GIF] DesktopOld_EndQuiz.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/[GIF] DesktopOld_EndQuiz.gif -------------------------------------------------------------------------------- /gfx/[GIF] DesktopOld_Timeout.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/[GIF] DesktopOld_Timeout.gif -------------------------------------------------------------------------------- /gfx/[GIF] Desktop_PlayingAround.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/[GIF] Desktop_PlayingAround.gif -------------------------------------------------------------------------------- /gfx/[GIF] Desktop_QuizEnding.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/[GIF] Desktop_QuizEnding.gif -------------------------------------------------------------------------------- /gfx/[GIF] Mobile_Quiz.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/[GIF] Mobile_Quiz.gif -------------------------------------------------------------------------------- /gfx/[GIF] Mobile_Settings.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/[GIF] Mobile_Settings.gif -------------------------------------------------------------------------------- /gfx/[GIF] Mobile_TopicsQuestionList.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mikyll/ROQuiz/9f767ede3c13d799ed2c75f476cb02e44c31e6b2/gfx/[GIF] Mobile_TopicsQuestionList.gif --------------------------------------------------------------------------------