diff --git a/CMakeGraphVizOptions.cmake b/CMakeGraphVizOptions.cmake index acd5748a7..c858e3ca7 100644 --- a/CMakeGraphVizOptions.cmake +++ b/CMakeGraphVizOptions.cmake @@ -4,7 +4,7 @@ # cmake --build . --target architecture ######################################## -SET(GRAPHVIZ_IGNORE_TARGETS AusweisAppGlobal;AusweisAppExternal;cvc;fuzz;OpenSsl;tlscheck;Test;Script) +SET(GRAPHVIZ_IGNORE_TARGETS AusweisAppGlobal;AusweisAppExternal;cvc;fuzz;OpenSsl;tlscheck;Test;Script;testbedtool;tsParserFU) SET(GRAPHVIZ_EXTERNAL_LIBS OFF) SET(GRAPHVIZ_EXECUTABLES ON) SET(GRAPHVIZ_GENERATE_PER_TARGET OFF) diff --git a/CMakeLists.txt b/CMakeLists.txt index 88a64d506..e9589549b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -36,8 +36,11 @@ ELSE() SET(LANGUAGES CXX) ENDIF() +IF(APPLE AND NOT IOS) + SET(CMAKE_OSX_DEPLOYMENT_TARGET 10.12 CACHE STRING "Required macOS version") +ENDIF() -PROJECT(AusweisApp2 VERSION 1.18.2 LANGUAGES ${LANGUAGES}) +PROJECT(AusweisApp2 VERSION 1.20.0 LANGUAGES ${LANGUAGES}) # Set TWEAK if not defined in PROJECT_VERSION above to # have a valid tweak version without propagating it @@ -45,13 +48,17 @@ IF(NOT PROJECT_VERSION_TWEAK) SET(PROJECT_VERSION_TWEAK 0) ENDIF() +IF(APPLE AND CMAKE_VERSION VERSION_GREATER_EQUAL "3.16" AND NOT tools.only) + ENABLE_LANGUAGE(OBJCXX) +ENDIF() -IF(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) +IF(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT AND (IOS OR ANDROID)) SET(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/dist" CACHE PATH "default install path" FORCE) ENDIF() SET(CMAKE_DIR "${PROJECT_SOURCE_DIR}/cmake") SET(CMAKE_MODULE_PATH "${CMAKE_DIR}") OPTION(BUILD_SHARED_LIBS "Enable build of shared libraries") +OPTION(INTEGRATED_SDK "Build platform specific SDK" OFF) INCLUDE(Helper) @@ -111,8 +118,11 @@ SET(SRC_DIR ${PROJECT_SOURCE_DIR}/src) SET(TEST_DIR ${PROJECT_SOURCE_DIR}/test) SET(RESOURCES_DIR ${PROJECT_SOURCE_DIR}/resources) SET(PACKAGING_DIR ${RESOURCES_DIR}/packaging) -SET(COPYRIGHT_TEXT "Ⓒ\; 2014-2019 ${VENDOR}") -STRING(REPLACE " \& " " \& " COPYRIGHT_TEXT ${COPYRIGHT_TEXT}) +SET(COPYRIGHT_TEXT "2014-2020 ${VENDOR}") +IF(APPLE) + STRING(REPLACE " \& " " \& " COPYRIGHT_TEXT ${COPYRIGHT_TEXT}) +ENDIF() +SET(BUNDLE_IDENTIFIER com.governikus.ausweisapp2) INCLUDE(Tools) INCLUDE(DVCS) @@ -126,22 +136,23 @@ IF(tools.only) RETURN() ENDIF() -INCLUDE(Libraries) -INCLUDE(CompilerFlags) - -ADD_SUBDIRECTORY(resources) -ADD_SUBDIRECTORY(src) - IF("${CMAKE_BUILD_TYPE}" STREQUAL "DEBUG") INCLUDE(CTest) CONFIGURE_FILE("${CMAKE_DIR}/CTestCustom.cmake.in" "${CMAKE_BINARY_DIR}/CTestCustom.cmake" @ONLY) CONFIGURE_FILE("${RESOURCES_DIR}/sonar-project.properties.in" "${CMAKE_BINARY_DIR}/sonar-project.properties" @ONLY) ENDIF() -IF(BUILD_TESTING) - ADD_SUBDIRECTORY(test) +INCLUDE(Libraries) +INCLUDE(CompilerFlags) + +IF(LINUX OR BSD) + INCLUDE(GNUInstallDirs) ENDIF() +ADD_SUBDIRECTORY(resources) +ADD_SUBDIRECTORY(src) +ADD_SUBDIRECTORY(test) + IF(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/utils") ADD_SUBDIRECTORY(utils) ENDIF() diff --git a/LICENSE.officially.txt b/LICENSE.officially.txt index 39ca56b78..10675c520 100644 --- a/LICENSE.officially.txt +++ b/LICENSE.officially.txt @@ -339,12 +339,12 @@ Die verwendeten Open-Source-Bibliotheken unterliegen den folgenden Nutzungsbedin OpenSSL Lizenz: OpenSSL license & SSLeay license - Version: 1.1.1c + Version: 1.1.1d Adresse: https://www.openssl.org/ Qt Lizenz: LGPL v3 - Version: 5.12.4 + Version: 5.12.5 Adresse: https://www.qt.io/ http_parser @@ -352,10 +352,10 @@ http_parser Version: 2.9.2 Adresse: https://github.com/nodejs/http-parser/ -Android Support Library V4 +AndroidX Support Library Lizenz: Apache 2.0 - Version: 21.0.3 - Adresse: https://developer.android.com/topic/libraries/support-library/ + Version: 1.1.0 + Adresse: https://developer.android.com/jetpack/androidx Die Lizenztexte lauten in ihrer originalen Fassung wie folgt: diff --git a/LICENSE.txt b/LICENSE.txt index a1de86129..e6bc60766 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -302,12 +302,12 @@ Die verwendeten Open-Source-Bibliotheken unterliegen den folgenden Nutzungsbedin OpenSSL Lizenz: OpenSSL license & SSLeay license - Version: 1.1.1c + Version: 1.1.1d Adresse: https://www.openssl.org/ Qt Lizenz: LGPL v3 - Version: 5.12.4 + Version: 5.12.5 Adresse: https://www.qt.io/ http_parser @@ -315,10 +315,10 @@ http_parser Version: 2.9.2 Adresse: https://github.com/nodejs/http-parser/ -Android Support Library V4 +AndroidX Support Library Lizenz: Apache 2.0 - Version: 21.0.3 - Adresse: https://developer.android.com/topic/libraries/support-library/ + Version: 1.1.0 + Adresse: https://developer.android.com/jetpack/androidx Die Lizenztexte lauten in ihrer originalen Fassung wie folgt: diff --git a/README.rst b/README.rst index 69b18bdfc..def6e2fa0 100644 --- a/README.rst +++ b/README.rst @@ -133,12 +133,12 @@ Für iOS wird die AusweisApp2 mittels XCode gebaut! :: $ cd build - $ cmake -DCMAKE_PREFIX_PATH=/Users/governikus/Toolchain/dist -DCMAKE_TOOLCHAIN_FILE=../AusweisApp2/cmake/iOS.toolchain.cmake -DCMAKE_BUILD_TYPE=release ../AusweisApp2 -GXcode - $ xcodebuild -configuration Release - $ xcodebuild -target ipa -configuration Release + $ cmake -DCMAKE_PREFIX_PATH=/Users/governikus/Toolchain/dist -DCMAKE_TOOLCHAIN_FILE=../AusweisApp2/cmake/iOS.toolchain.cmake -DCMAKE_BUILD_TYPE=MinSizeRel ../AusweisApp2 -GXcode + $ xcodebuild -configuration MinSizeRel -archivePath AusweisApp2.xcarchive -scheme AusweisApp archive + $ xcodebuild -configuration MinSizeRel -archivePath AusweisApp2.xcarchive -exportArchive -exportOptionsPlist exportOptions.plist -exportPath . -Im Build-Ordner befindet sich nun eine "AusweisApp2-x.y.z.ipa" Datei, welches das +Im Build-Ordner befindet sich nun ein *.ipa und ein *.xcarchive, welches jeweils das signierte Bundle enthält! diff --git a/cmake/CompilerFlags.cmake b/cmake/CompilerFlags.cmake index cfad5f61a..baee11a04 100644 --- a/cmake/CompilerFlags.cmake +++ b/cmake/CompilerFlags.cmake @@ -6,7 +6,7 @@ ADD_DEFINITIONS(-DQT_NO_FOREACH) ADD_DEFINITIONS(-DQT_NO_KEYWORDS) ADD_DEFINITIONS(-DQT_NO_EXCEPTIONS) -IF(NOT MSVC AND NOT CMAKE_CXX_SIMULATE_ID STREQUAL "MSVC") +IF(NOT MSVC AND NOT CMAKE_CXX_SIMULATE_ID STREQUAL "MSVC" AND "${Qt5Core_VERSION}" VERSION_LESS "6.0") ADD_DEFINITIONS(-DQT_STRICT_ITERATORS) ENDIF() @@ -125,10 +125,6 @@ ELSE() ENDIF() ENDIF() -IF(APPLE AND NOT IOS) - SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ObjC++ -mmacosx-version-min=10.12") -ENDIF() - INCLUDE(CompilerFlagsPersoSim) diff --git a/cmake/Helper.cmake b/cmake/Helper.cmake index cf37bdff3..0f6ef5710 100644 --- a/cmake/Helper.cmake +++ b/cmake/Helper.cmake @@ -219,6 +219,9 @@ FUNCTION(ADD_PLATFORM_LIBRARY _name) ADD_LIBRARY(${_name} ${FILES}) TARGET_INCLUDE_DIRECTORIES(${_name} INTERFACE "$") + IF(IOS) + SET_TARGET_PROPERTIES(${_name} PROPERTIES ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}) + ENDIF() ENDFUNCTION() diff --git a/cmake/Install.cmake b/cmake/Install.cmake index 33e8f8fe4..a13e029b7 100644 --- a/cmake/Install.cmake +++ b/cmake/Install.cmake @@ -47,12 +47,15 @@ IF(WIN32) ENDIF() IF(TARGET Qt5::Qml) - FETCH_TARGET_LOCATION(libEgl "Qt5::Gui_EGL") - FETCH_TARGET_LOCATION(libGLES "Qt5::Gui_GLESv2") FETCH_TARGET_LOCATION(libQuickControls2 "Qt5::QuickControls2") INSTALL(FILES ${libQuickControls2} DESTINATION . COMPONENT Runtime) - INSTALL(FILES ${libEgl} DESTINATION . COMPONENT Runtime) - INSTALL(FILES ${libGLES} DESTINATION . COMPONENT Runtime) + + IF(TARGET Qt5::Gui_EGL AND TARGET Qt5::Gui_GLESv2) + FETCH_TARGET_LOCATION(libEgl "Qt5::Gui_EGL") + FETCH_TARGET_LOCATION(libGLES "Qt5::Gui_GLESv2") + INSTALL(FILES ${libEgl} DESTINATION . COMPONENT Runtime) + INSTALL(FILES ${libGLES} DESTINATION . COMPONENT Runtime) + ENDIF() ENDIF() FETCH_TARGET_LOCATION(libSvg "Qt5::Svg") FETCH_TARGET_LOCATION(pluginSvg "Qt5::QSvgPlugin") @@ -192,16 +195,16 @@ ELSEIF(ANDROID) SET(RESOURCES_IMG_ANDROID_DIR ${RESOURCES_DIR}/images/android) IF(BUILD_PREVIEW) SET(ANDROID_LAUNCHER_ICON "npa_preview.png") - SET(ANDROID_PACKAGE_NAME "com.governikus.ausweisapp2.dev") + SET(ANDROID_PACKAGE_NAME "${BUNDLE_IDENTIFIER}.dev") ELSEIF(IS_DEVELOPER_VERSION) SET(ANDROID_LAUNCHER_ICON "npa_beta.png") - SET(ANDROID_PACKAGE_NAME "com.governikus.ausweisapp2") + SET(ANDROID_PACKAGE_NAME "${BUNDLE_IDENTIFIER}") ELSE() SET(ANDROID_LAUNCHER_ICON "npa.png") - SET(ANDROID_PACKAGE_NAME "com.governikus.ausweisapp2") + SET(ANDROID_PACKAGE_NAME "${BUNDLE_IDENTIFIER}") ENDIF() - IF(ANDROID_BUILD_AAR) + IF(INTEGRATED_SDK) SET(ANDROID_MANIFEST AndroidManifest.xml.aar.in) FOREACH(entry network/WifiInfo ui/aidl/AidlBinder activation/intent/AusweisApp2Service) SET(_java_file "${SRC_DIR}/${entry}.java") @@ -237,7 +240,7 @@ ELSEIF(ANDROID) ENDIF() CONFIGURE_FILE(${PACKAGING_DIR}/android/${ANDROID_MANIFEST} ${ANDROID_PACKAGE_SRC_DIR}/AndroidManifest.xml @ONLY) CONFIGURE_FILE(${PACKAGING_DIR}/android/backup_rules.xml ${ANDROID_PACKAGE_SRC_DIR}/res/xml/backup_rules.xml COPYONLY) - IF(NOT ANDROID_BUILD_AAR) + IF(NOT INTEGRATED_SDK) CONFIGURE_FILE(${PACKAGING_DIR}/android/fileprovider.xml ${ANDROID_PACKAGE_SRC_DIR}/res/xml/fileprovider.xml COPYONLY) ENDIF() @@ -260,7 +263,7 @@ ELSEIF(ANDROID) SET(ANDROID_DEPLOYMENT_SETTINGS ${PROJECT_BINARY_DIR}/libAusweisApp2.so-deployment-settings.json CACHE INTERNAL "apk deployment" FORCE) CONFIGURE_FILE(${PACKAGING_DIR}/android/libAusweisApp2.so-deployment-settings.json.in ${ANDROID_DEPLOYMENT_SETTINGS} @ONLY) - SET(TRANSLATION_DESTINATION ${ANDROID_PACKAGE_SRC_DIR}/assets/translations) + SET(TRANSLATION_DESTINATION ${ANDROID_PACKAGE_SRC_DIR}/assets/${TRANSLATION_DESTINATION}) SET(DEFAULT_FILE_DESTINATION ${ANDROID_PACKAGE_SRC_DIR}/assets) ELSEIF(UNIX) @@ -268,19 +271,14 @@ ELSEIF(UNIX) SET(CMAKE_INSTALL_RPATH "\$ORIGIN") ENDIF() - SET(DEFAULT_FILE_DESTINATION bin) - INSTALL(TARGETS AusweisApp DESTINATION ${DEFAULT_FILE_DESTINATION} COMPONENT Application) - INSTALL(CODE - " - ${DEPENDENCY_CHECK} - ${SEARCH_ADDITIONAL_DIRS} - INCLUDE(BundleUtilities) - FIXUP_BUNDLE(\"\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${DEFAULT_FILE_DESTINATION}/${PROJECT_NAME}\" \"\" \"\${ADDITIONAL_DIRS}\") - " COMPONENT Runtime) - - CONFIGURE_FILE(${PACKAGING_DIR}/linux/AusweisApp2.desktop.in ${CMAKE_CURRENT_BINARY_DIR}/AusweisApp2.desktop @ONLY) - INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/AusweisApp2.desktop DESTINATION share/applications COMPONENT Application) - #INSTALL(FILES ${RESOURCES_DIR}/images/AusweisApp2.svg DESTINATION share/icons/hicolor/scalable/apps COMPONENT Application) + SET(DEFAULT_FILE_DESTINATION ${CMAKE_INSTALL_DATADIR}/${VENDOR}/AusweisApp2) + SET(TRANSLATION_DESTINATION ${DEFAULT_FILE_DESTINATION}/${TRANSLATION_DESTINATION}) + INSTALL(TARGETS AusweisApp DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT Application) + CONFIGURE_FILE(${PACKAGING_DIR}/linux/${BUNDLE_IDENTIFIER}.metainfo.xml.in ${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_IDENTIFIER}.metainfo.xml @ONLY) + CONFIGURE_FILE(${PACKAGING_DIR}/linux/${BUNDLE_IDENTIFIER}.desktop.in ${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_IDENTIFIER}.desktop @ONLY) + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_IDENTIFIER}.metainfo.xml DESTINATION ${CMAKE_INSTALL_DATADIR}/metainfo COMPONENT Application) + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${BUNDLE_IDENTIFIER}.desktop DESTINATION ${CMAKE_INSTALL_DATADIR}/applications COMPONENT Application) + INSTALL(FILES ${RESOURCES_DIR}/images/npa.svg DESTINATION ${DEFAULT_FILE_DESTINATION} COMPONENT Application) ENDIF() @@ -304,31 +302,20 @@ IF(LINUX OR WIN32 OR MAC) ENDIF() ENDIF() -IF(WIN32) - IF(SIGNTOOL_CMD) - CONFIGURE_FILE(${CMAKE_DIR}/SignFiles.cmake.in ${CMAKE_BINARY_DIR}/SignFiles.cmake @ONLY) - INSTALL(CODE - " - EXECUTE_PROCESS(COMMAND \"${CMAKE_COMMAND}\" -DSIGN_EXT=*.exe -P \"${CMAKE_BINARY_DIR}/SignFiles.cmake\" WORKING_DIRECTORY \"\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${DEFAULT_FILE_DESTINATION}\") - " COMPONENT Application) - ENDIF() -ENDIF() - - IF(LINUX) INSTALL(FILES ${QM_FILES} DESTINATION ${TRANSLATION_DESTINATION} COMPONENT Translations) -ELSEIF(NOT ANDROID_BUILD_AAR) +ELSEIF(NOT INTEGRATED_SDK) INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/translations/ DESTINATION ${TRANSLATION_DESTINATION} COMPONENT Translations) ENDIF() -IF(NOT ANDROID_BUILD_AAR) +IF(NOT INTEGRATED_SDK) # resources file INSTALL(FILES ${RCC} DESTINATION ${DEFAULT_FILE_DESTINATION} COMPONENT Runtime) ENDIF() # qt qml plugins -IF(DESKTOP AND TARGET Qt5::Qml) +IF((WIN32 OR MAC) AND TARGET Qt5::Qml) FOREACH(entry QtQuick QtQuick.2 QtQml QtGraphicalEffects Qt) INSTALL(DIRECTORY ${QT_HOST_PREFIX}/qml/${entry} DESTINATION ${DEFAULT_FILE_DESTINATION}/qml COMPONENT Runtime PATTERN "*.dylib" EXCLUDE) ENDFOREACH() @@ -336,3 +323,14 @@ ENDIF() # secure storage file INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/config.json DESTINATION ${DEFAULT_FILE_DESTINATION} COMPONENT Runtime) + + +IF(WIN32) + IF(SIGNTOOL_CMD) + CONFIGURE_FILE(${CMAKE_DIR}/SignFiles.cmake.in ${CMAKE_BINARY_DIR}/SignFiles.cmake @ONLY) + INSTALL(CODE + " + EXECUTE_PROCESS(COMMAND \"${CMAKE_COMMAND}\" -DSIGN_EXT=*.exe -P \"${CMAKE_BINARY_DIR}/SignFiles.cmake\" WORKING_DIRECTORY \"\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${DEFAULT_FILE_DESTINATION}\") + " COMPONENT Application) + ENDIF() +ENDIF() diff --git a/cmake/Libraries.cmake b/cmake/Libraries.cmake index fed98dc9c..1eb779772 100644 --- a/cmake/Libraries.cmake +++ b/cmake/Libraries.cmake @@ -13,13 +13,13 @@ FIND_PACKAGE(Qt5Svg ${MIN_QT_VERSION} REQUIRED) FIND_PACKAGE(Qt5LinguistTools ${MIN_QT_VERSION} REQUIRED) FIND_PACKAGE(Qt5WebSockets ${MIN_QT_VERSION} REQUIRED) -IF(NOT ANDROID_BUILD_AAR) +IF(NOT INTEGRATED_SDK) FIND_PACKAGE(Qt5Qml ${MIN_QT_VERSION} REQUIRED) FIND_PACKAGE(Qt5Quick ${MIN_QT_VERSION} REQUIRED) FIND_PACKAGE(Qt5QuickControls2 ${MIN_QT_VERSION} REQUIRED) ENDIF() -IF(DESKTOP) +IF(DESKTOP AND NOT INTEGRATED_SDK) FIND_PACKAGE(Qt5Widgets ${MIN_QT_VERSION} REQUIRED) IF(WIN32) @@ -96,7 +96,6 @@ ELSEIF(IOS) FIND_LIBRARY(IOS_CORETEXT CoreText) FIND_LIBRARY(IOS_COREGRAPHICS CoreGraphics) FIND_LIBRARY(IOS_SECURITY Security) - FIND_LIBRARY(IOS_SYSTEMCONFIGURATION SystemConfiguration) FIND_LIBRARY(IOS_AUDIOTOOLBOX AudioToolbox) FIND_LIBRARY(IOS_IMAGEIO ImageIO) FIND_LIBRARY(IOS_CORENFC CoreNFC) @@ -121,7 +120,7 @@ ELSEIF(UNIX) ENDIF() -IF("${CMAKE_BUILD_TYPE}" STREQUAL "DEBUG") - FIND_PACKAGE(Qt5Test ${MIN_QT_VERSION} REQUIRED) - FIND_PACKAGE(Qt5QuickTest ${MIN_QT_VERSION} REQUIRED) +IF(BUILD_TESTING) + FIND_PACKAGE(Qt5Test ${MIN_QT_VERSION}) + FIND_PACKAGE(Qt5QuickTest ${MIN_QT_VERSION}) ENDIF() diff --git a/cmake/Messages.cmake b/cmake/Messages.cmake index bbacf969e..e3d96c1f1 100644 --- a/cmake/Messages.cmake +++ b/cmake/Messages.cmake @@ -11,6 +11,7 @@ MESSAGE(STATUS "CMAKE_SYSROOT_LINK: ${CMAKE_SYSROOT_LINK}") MESSAGE(STATUS "CMAKE_SYSROOT_COMPILE: ${CMAKE_SYSROOT_COMPILE}") IF(APPLE) MESSAGE(STATUS "CMAKE_OSX_SYSROOT: ${CMAKE_OSX_SYSROOT}") + MESSAGE(STATUS "CMAKE_OSX_DEPLOYMENT_TARGET: ${CMAKE_OSX_DEPLOYMENT_TARGET}") ENDIF() MESSAGE(STATUS "CMAKE_SYSTEM_PROCESSOR: ${CMAKE_SYSTEM_PROCESSOR}") MESSAGE(STATUS "CMAKE_CXX_SIMULATE_ID: ${CMAKE_CXX_SIMULATE_ID}") diff --git a/cmake/Notarization.cmake b/cmake/Notarization.cmake new file mode 100644 index 000000000..f756e9fdc --- /dev/null +++ b/cmake/Notarization.cmake @@ -0,0 +1,65 @@ +CMAKE_MINIMUM_REQUIRED(VERSION 3.8.0) + +IF(NOT CMAKE_SCRIPT_MODE_FILE) + MESSAGE(STATUS "Usage: cmake -P cmake/Notarization.cmake") +ENDIF() + +FUNCTION(FETCH_REGEX _output _regex _data) + STRING(REGEX MATCH "${_regex}" _unused "${_data}") + + IF(CMAKE_MATCH_1) + STRING(STRIP "${CMAKE_MATCH_1}" output) + SET(${_output} ${output} PARENT_SCOPE) + ENDIF() +ENDFUNCTION() + +FIND_PROGRAM(XCRUN xcrun) +IF(NOT XCRUN) + MESSAGE(FATAL_ERROR "Cannot find 'xcrun'") +ENDIF() + +FILE(GLOB DMG_FILE *.dmg) +LIST(LENGTH DMG_FILE DMG_FILE_LEN) +IF(NOT DMG_FILE_LEN EQUAL 1) + MESSAGE(FATAL_ERROR "Cannot determine *.dmg file: ${CMAKE_BINARY_DIR}") +ENDIF() +MESSAGE(STATUS "Using DMG: ${DMG_FILE}") + +IF(NOT USER) + SET(USER ausweisapp@governikus.com) +ENDIF() + +EXECUTE_PROCESS(COMMAND ${XCRUN} altool -t osx --notarize-app --verbose -u ${USER} -p @env:PASSWORD --primary-bundle-id com.governikus.ausweisapp2 -f ${DMG_FILE} + OUTPUT_VARIABLE UUID_OUTPUT) + +SET(regex_uuid "RequestUUID = ([-|0-9|a-z]+)") +FETCH_REGEX(UUID "${regex_uuid}" "${UUID_OUTPUT}") +IF(UUID) + MESSAGE(STATUS "Fetched UUID: ${UUID}") +ELSE() + MESSAGE(FATAL_ERROR "Cannot fetch UUID: ${UUID_OUTPUT}") +ENDIF() + +SET(regex_status "Status: ([a-z| ]+)") +WHILE(TRUE) + MESSAGE(STATUS "Wait 30 seconds...") + EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E sleep 30) + + EXECUTE_PROCESS(COMMAND ${XCRUN} altool -u ${USER} -p @env:PASSWORD --notarization-info ${UUID} + OUTPUT_VARIABLE STATUS_OUTPUT) + + FETCH_REGEX(STATUS "${regex_status}" "${STATUS_OUTPUT}") + + IF(STATUS STREQUAL "success") + MESSAGE(STATUS "Notarization succeeded...") + BREAK() + ELSEIF(STATUS STREQUAL "in progress") + MESSAGE(STATUS "Waiting...\n${STATUS_OUTPUT}") + ELSE() + MESSAGE(STATUS "Fetched Status: ${STATUS}") + MESSAGE(FATAL_ERROR "Notarization failed:\n${STATUS_OUTPUT}") + ENDIF() +ENDWHILE() + +EXECUTE_PROCESS(COMMAND ${XCRUN} stapler staple -v ${DMG_FILE}) +EXECUTE_PROCESS(COMMAND ${XCRUN} stapler validate -v ${DMG_FILE}) diff --git a/cmake/Packaging.cmake b/cmake/Packaging.cmake index c5b3a7076..0d5727324 100644 --- a/cmake/Packaging.cmake +++ b/cmake/Packaging.cmake @@ -3,7 +3,7 @@ SET(FILENAME ${PROJECT_NAME}-${PROJECT_VERSION}) -IF(ANDROID_BUILD_AAR) +IF(ANDROID AND INTEGRATED_SDK) STRING(TOLOWER "${FILENAME}" FILENAME) STRING(REGEX REPLACE "[0-9]*-" "-" FILENAME "${FILENAME}") ELSEIF(ANDROID) @@ -103,36 +103,55 @@ IF(WIN32) ELSEIF(IOS) FILE(WRITE ${PROJECT_BINARY_DIR}/ipa.cmake " - FUNCTION(FIND_BUNDLE _name _out_bundle _out_parent_dir) - SET(BUNDLE_DIRS \"\${CONFIG}-iphoneos;\${CONFIG};UninstalledProducts;UninstalledProducts/iphoneos\") - - FOREACH(dir \${BUNDLE_DIRS}) - SET(tmpDir ${PROJECT_BINARY_DIR}/src/\${dir}) - SET(tmpBundleDir \${tmpDir}/\${_name}) - IF(EXISTS \"\${tmpBundleDir}\") - SET(\${_out_bundle} \"\${tmpBundleDir}\" PARENT_SCOPE) - SET(\${_out_parent_dir} \"\${tmpDir}\" PARENT_SCOPE) - BREAK() - ENDIF() - ENDFOREACH() + FUNCTION(SELF_GENERATED) + FUNCTION(FIND_BUNDLE _name _out_bundle _out_parent_dir) + SET(BUNDLE_DIRS \"\${CONFIG}-iphoneos;\${CONFIG};UninstalledProducts;UninstalledProducts/iphoneos\") + + FOREACH(dir \${BUNDLE_DIRS}) + SET(tmpDir ${PROJECT_BINARY_DIR}/src/\${dir}) + SET(tmpBundleDir \${tmpDir}/\${_name}) + IF(EXISTS \"\${tmpBundleDir}\") + SET(\${_out_bundle} \"\${tmpBundleDir}\" PARENT_SCOPE) + SET(\${_out_parent_dir} \"\${tmpDir}\" PARENT_SCOPE) + BREAK() + ENDIF() + ENDFOREACH() + ENDFUNCTION() + + FIND_BUNDLE(${PROJECT_NAME}.app BundleDir ParentDir) + + IF(BundleDir) + MESSAGE(STATUS \"Use bundle: \${BundleDir}\") + ELSE() + MESSAGE(FATAL_ERROR \"Bundle directory does not exist\") + ENDIF() + + EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E copy_directory \${BundleDir} Payload/${PROJECT_NAME}.app) + EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E tar cf \"${CPACK_PACKAGE_FILE_NAME}.ipa\" --format=zip Payload) + EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E remove_directory Payload) + + FIND_BUNDLE(${PROJECT_NAME}.app.dSYM dSYM ParentDir) + IF(dSYM) + MESSAGE(STATUS \"Use dSYM: \${dSYM}\") + EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E tar cf \"\${CMAKE_BINARY_DIR}/${CPACK_PACKAGE_FILE_NAME}.dSYM.zip\" --format=zip ${PROJECT_NAME}.app.dSYM WORKING_DIRECTORY \${ParentDir}) + ENDIF() + + IF(ParentDir) + FILE(GLOB SymbolMap \${ParentDir}/*.bcsymbolmap) + MESSAGE(STATUS \"Use bcsymbolmap: \${SymbolMap}\") + EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E copy \${SymbolMap} ${CPACK_PACKAGE_FILE_NAME}.bcsymbolmap) + ENDIF() ENDFUNCTION() - FIND_BUNDLE(${PROJECT_NAME}.app BundleDir ParentDir) + FUNCTION(XCODE_GENERATED) + EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E tar cf \"\${CMAKE_BINARY_DIR}/${CPACK_PACKAGE_FILE_NAME}.xcarchive.zip\" --format=zip ${PROJECT_NAME}.xcarchive) + EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E rename AusweisApp.ipa ${CPACK_PACKAGE_FILE_NAME}.ipa) + ENDFUNCTION() - IF(BundleDir) - MESSAGE(STATUS \"Use bundle: \${BundleDir}\") + IF(EXISTS \"\${CMAKE_BINARY_DIR}/${PROJECT_NAME}.xcarchive\") + XCODE_GENERATED() ELSE() - MESSAGE(FATAL_ERROR \"Bundle directory does not exist\") - ENDIF() - - EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E copy_directory \${BundleDir} Payload/${PROJECT_NAME}.app) - EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E tar cf \"${CPACK_PACKAGE_FILE_NAME}.ipa\" --format=zip Payload) - EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E remove_directory Payload) - - FIND_BUNDLE(${PROJECT_NAME}.app.dSYM dSYM ParentDir) - IF(dSYM) - MESSAGE(STATUS \"Use dSYM: \${dSYM}\") - EXECUTE_PROCESS(COMMAND ${CMAKE_COMMAND} -E tar cf \"\${CMAKE_BINARY_DIR}/${CPACK_PACKAGE_FILE_NAME}.dSYM.zip\" --format=zip ${PROJECT_NAME}.app.dSYM WORKING_DIRECTORY \${ParentDir}) + SELF_GENERATED() ENDIF() ") @@ -148,15 +167,15 @@ ELSEIF(APPLE) SET(CPACK_BUNDLE_APPLE_CERT_APP "Developer ID Application: Governikus GmbH & Co. KG (G7EQCJU4BR)") SET(CPACK_BUNDLE_APPLE_CODESIGN_FILES ${ADDITIONAL_BUNDLE_FILES_TO_SIGN}) - SET(CPACK_APPLE_BUNDLE_ID "com.governikus.AusweisApp2") - SET(CPACK_BUNDLE_APPLE_CODESIGN_PARAMETER "--force") + SET(CPACK_APPLE_BUNDLE_ID "${BUNDLE_IDENTIFIER}") + SET(CPACK_BUNDLE_APPLE_CODESIGN_PARAMETER "-o runtime --force") OPTION(OSX_TIMESTAMP "Timestamp the application bundle" ON) IF(OSX_TIMESTAMP) SET(CPACK_BUNDLE_APPLE_CODESIGN_PARAMETER "${CPACK_BUNDLE_APPLE_CODESIGN_PARAMETER} --timestamp") ELSE() SET(CPACK_BUNDLE_APPLE_CODESIGN_PARAMETER "${CPACK_BUNDLE_APPLE_CODESIGN_PARAMETER} --timestamp=none") ENDIF() - SET(CPACK_PACKAGE_ICON ${RESOURCES_DIR}/images/dmg_icons.icns) + #SET(CPACK_PACKAGE_ICON ${RESOURCES_DIR}/images/dmg_icons.icns) https://gitlab.kitware.com/cmake/cmake/issues/19517 SET(CPACK_DMG_VOLUME_NAME ${CPACK_PACKAGE_NAME}) SET(CPACK_DMG_FORMAT UDBZ) SET(CPACK_DMG_BACKGROUND_IMAGE ${RESOURCES_DIR}/images/dmg_background.png) @@ -168,7 +187,7 @@ ELSEIF(APPLE) SET(CPACK_DMG_DS_STORE ${MACOS_PACKAGING_DIR}/DS_STORE) SET(INFO_PLIST_FILE_NAME Info.plist) - CONFIGURE_FILE(${MACOS_PACKAGING_DIR}/${INFO_PLIST_FILE_NAME} ${INFO_PLIST_FILE_NAME} @ONLY) + CONFIGURE_FILE(${MACOS_PACKAGING_DIR}/${INFO_PLIST_FILE_NAME}.in ${INFO_PLIST_FILE_NAME} @ONLY) SET(CPACK_BUNDLE_PLIST ${INFO_PLIST_FILE_NAME}) ELSEIF(ANDROID) @@ -180,7 +199,7 @@ ELSEIF(ANDROID) FILE(READ "${QT_HOST_PREFIX}/src/android/templates/build.gradle" BUILD_GRADLE) - IF(ANDROID_BUILD_AAR) + IF(INTEGRATED_SDK) STRING(REPLACE "apply plugin: 'com.android.application'" "apply plugin: 'com.android.library'" BUILD_GRADLE "${BUILD_GRADLE}") ENDIF() @@ -192,7 +211,7 @@ ELSEIF(ANDROID) FILE(APPEND "${CMAKE_INSTALL_PREFIX}/build.gradle" "tasks.lint.enabled = false") ENDIF() - IF(ANDROID_BUILD_AAR) + IF(INTEGRATED_SDK) SET(ANDROID_FILE_EXT aar) CONFIGURE_FILE(${PACKAGING_DIR}/android/pom.xml.in ${CMAKE_INSTALL_PREFIX}/${CPACK_PACKAGE_FILE_NAME}.pom @ONLY) CONFIGURE_FILE("${PACKAGING_DIR}/android/lint.aar.xml" "${CMAKE_INSTALL_PREFIX}/lint.xml" COPYONLY) @@ -205,7 +224,7 @@ ELSEIF(ANDROID) IF(${CMAKE_BUILD_TYPE} STREQUAL "RELEASE" OR ${CMAKE_BUILD_TYPE} STREQUAL "RELWITHDEBINFO" OR ${CMAKE_BUILD_TYPE} STREQUAL "MINSIZEREL") SET(DEPLOY_CMD_SIGN --release) - IF(ANDROID_BUILD_AAR) + IF(INTEGRATED_SDK) SET(ANDROID_FILE dist-release.aar) ELSEIF(APK_SIGN_KEYSTORE AND APK_SIGN_KEYSTORE_ALIAS AND APK_SIGN_KEYSTORE_PSW) MESSAGE(STATUS "Release build will be signed using: ${APK_SIGN_KEYSTORE} | Alias: ${APK_SIGN_KEYSTORE_ALIAS}") @@ -223,7 +242,7 @@ ELSEIF(ANDROID) SET(DEPLOY_CMD ${androiddeployqt} --verbose --gradle --input ${ANDROID_DEPLOYMENT_SETTINGS} --output ${CMAKE_INSTALL_PREFIX} ${DEPLOY_CMD_SIGN}) SET(SOURCE_ANDROID_FILE ${CMAKE_INSTALL_PREFIX}/build/outputs/${ANDROID_FILE_EXT}) - IF("${Qt5Core_VERSION}" VERSION_GREATER_EQUAL "5.12.0" AND NOT ANDROID_BUILD_AAR) + IF("${Qt5Core_VERSION}" VERSION_GREATER_EQUAL "5.12.0" AND NOT INTEGRATED_SDK) IF(${CMAKE_BUILD_TYPE} STREQUAL "DEBUG") SET(SOURCE_ANDROID_FILE ${SOURCE_ANDROID_FILE}/debug) ELSE() @@ -238,14 +257,15 @@ ELSEIF(ANDROID) # https://gitlab.kitware.com/cmake/cmake/issues/8438 ADD_CUSTOM_TARGET(${ANDROID_FILE_EXT} COMMAND ${DEPLOY_CMD} - COMMAND ${CMAKE_COMMAND} -E copy ${SOURCE_ANDROID_FILE} ${DESTINATION_ANDROID_FILE}) + COMMAND ${CMAKE_COMMAND} -E copy ${SOURCE_ANDROID_FILE} ${DESTINATION_ANDROID_FILE} + USES_TERMINAL) ADD_CUSTOM_COMMAND(TARGET ${ANDROID_FILE_EXT} POST_BUILD COMMAND ${CMAKE_INSTALL_PREFIX}/gradlew sourcesJar lint COMMAND ${CMAKE_COMMAND} -E copy build/libs/dist-sources.jar ${CPACK_PACKAGE_FILE_NAME}-sources.jar WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}) - IF(NOT ANDROID_BUILD_AAR) + IF(NOT INTEGRATED_SDK) FIND_PROGRAM(apksigner apksigner HINTS ${ANDROID_SDK}/build-tools/${ANDROID_BUILD_TOOLS_REVISION} CMAKE_FIND_ROOT_PATH_BOTH) IF(apksigner) ADD_CUSTOM_TARGET(verify.signature COMMAND ${apksigner} verify --verbose --print-certs -Werr ${DESTINATION_ANDROID_FILE}) diff --git a/cmake/Tools.cmake b/cmake/Tools.cmake index cf77720c8..2e4ee74e4 100644 --- a/cmake/Tools.cmake +++ b/cmake/Tools.cmake @@ -61,7 +61,7 @@ IF(DOXYGEN_FOUND) SET(DOXYGEN_CFG ${PROJECT_SOURCE_DIR}/Doxyfile.in) CONFIGURE_FILE(${DOXYGEN_CFG} ${PROJECT_BINARY_DIR}/Doxyfile @ONLY) - ADD_CUSTOM_COMMAND(OUTPUT ${DOXYGEN_BIN_DIR} COMMAND ${DOXYGEN_CMD}) + ADD_CUSTOM_COMMAND(OUTPUT ${DOXYGEN_BIN_DIR} COMMAND ${DOXYGEN_CMD} USES_TERMINAL) ADD_CUSTOM_TARGET(doxy DEPENDS ${DOXYGEN_BIN_DIR} WORKING_DIRECTORY ${PROJECT_BINARY_DIR} SOURCES ${DOXYGEN_CFG}) ENDIF() @@ -81,7 +81,7 @@ IF(UNCRUSTIFY) STRING(REPLACE "uncrustify " "" UNCRUSTIFY_VERSION ${UNCRUSTIFY_VERSION}) STRING(REPLACE "Uncrustify-" "" UNCRUSTIFY_VERSION ${UNCRUSTIFY_VERSION}) - SET(UNCRUSTIFY_NEEDED_VERSION "0.69") + SET(UNCRUSTIFY_NEEDED_VERSION "0.70.1") IF("${UNCRUSTIFY_VERSION}" STRLESS "${UNCRUSTIFY_NEEDED_VERSION}") MESSAGE(WARNING "Uncrustify seems to be too old. Use at least ${UNCRUSTIFY_NEEDED_VERSION}... you are using: ${UNCRUSTIFY_VERSION}") ELSE() @@ -143,40 +143,18 @@ IF(CONVERT) COMMAND ${CONVERT} -background transparent -define icon:auto-resize=256,96,64,48,40,32,24,20,16 npa.svg npa.ico WORKING_DIRECTORY ${RESOURCES_DIR}/images) - ADD_CUSTOM_TARGET(npaicons.android.background - COMMAND ${CONVERT} -background transparent -resize 81x81 android/npa_background.svg android/ldpi/background_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 108x108 android/npa_background.svg android/mdpi/background_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 162x162 android/npa_background.svg android/hdpi/background_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 216x216 android/npa_background.svg android/xhdpi/background_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 324x324 android/npa_background.svg android/xxhdpi/background_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 432x432 android/npa_background.svg android/xxxhdpi/background_npa.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) - - ADD_CUSTOM_TARGET(npaicons.android.foreground.preview - COMMAND ${CONVERT} -background transparent -resize 54x54 -gravity center -extent 81x81 android/npa_preview.svg android/ldpi/foreground_npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 72x72 -gravity center -extent 108x108 android/npa_preview.svg android/mdpi/foreground_npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 108x108 -gravity center -extent 162x162 android/npa_preview.svg android/hdpi/foreground_npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 144x144 -gravity center -extent 216x216 android/npa_preview.svg android/xhdpi/foreground_npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 216x216 -gravity center -extent 324x324 android/npa_preview.svg android/xxhdpi/foreground_npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 288x288 -gravity center -extent 432x432 android/npa_preview.svg android/xxxhdpi/foreground_npa_preview.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) + ADD_CUSTOM_TARGET(npaicons.android.playstore + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resize 512x512 playstore_release.svg playstore_release.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resize 512x512 playstore_preview.svg playstore_preview.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) - ADD_CUSTOM_TARGET(npaicons.android.legacy.preview - COMMAND ${CONVERT} -background transparent -resize 36x36 npa_preview.svg android/ldpi/npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 48x48 npa_preview.svg android/mdpi/npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 72x72 npa_preview.svg android/hdpi/npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 96x96 npa_preview.svg android/xhdpi/npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 144x144 npa_preview.svg android/xxhdpi/npa_preview.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 192x192 npa_preview.svg android/xxxhdpi/npa_preview.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) - - ADD_CUSTOM_TARGET(npaicons.android.foreground.beta - COMMAND ${CONVERT} -background transparent -resize 54x54 -gravity center -extent 81x81 android/npa_beta.svg android/ldpi/foreground_npa_beta.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 72x72 -gravity center -extent 78x78 android/npa_beta.svg android/mdpi/foreground_npa_beta.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 108x108 -gravity center -extent 162x162 android/npa_beta.svg android/hdpi/foreground_npa_beta.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 144x144 -gravity center -extent 216x216 android/npa_beta.svg android/xhdpi/foreground_npa_beta.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 216x216 -gravity center -extent 324x324 android/npa_beta.svg android/xxhdpi/foreground_npa_beta.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 288x288 -gravity center -extent 432x432 android/npa_beta.svg android/xxxhdpi/foreground_npa_beta.png + ADD_CUSTOM_TARGET(npaicons.android.legacy + COMMAND ${CONVERT} -background transparent -resize 36x36 npa.svg android/ldpi/npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 48x48 npa.svg android/mdpi/npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 72x72 npa.svg android/hdpi/npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 96x96 npa.svg android/xhdpi/npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 144x144 npa.svg android/xxhdpi/npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 192x192 npa.svg android/xxxhdpi/npa.png WORKING_DIRECTORY ${RESOURCES_DIR}/images) ADD_CUSTOM_TARGET(npaicons.android.legacy.beta @@ -188,189 +166,236 @@ IF(CONVERT) COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 192x192 npa_beta.svg android/xxxhdpi/npa_beta.png WORKING_DIRECTORY ${RESOURCES_DIR}/images) - - ADD_CUSTOM_TARGET(npaicons.android.foreground - COMMAND ${CONVERT} -background transparent -resize 54x54 -gravity center -extent 81x81 android/npa.svg android/ldpi/foreground_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 72x72 -gravity center -extent 108x108 android/npa.svg android/mdpi/foreground_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 108x108 -gravity center -extent 162x162 android/npa.svg android/hdpi/foreground_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 144x144 -gravity center -extent 216x216 android/npa.svg android/xhdpi/foreground_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 216x216 -gravity center -extent 324x324 android/npa.svg android/xxhdpi/foreground_npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 288x288 -gravity center -extent 432x432 android/npa.svg android/xxxhdpi/foreground_npa.png + ADD_CUSTOM_TARGET(npaicons.android.legacy.preview + COMMAND ${CONVERT} -background transparent -resize 36x36 npa_preview.svg android/ldpi/npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 48x48 npa_preview.svg android/mdpi/npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 72x72 npa_preview.svg android/hdpi/npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 96x96 npa_preview.svg android/xhdpi/npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 144x144 npa_preview.svg android/xxhdpi/npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 192x192 npa_preview.svg android/xxxhdpi/npa_preview.png WORKING_DIRECTORY ${RESOURCES_DIR}/images) - ADD_CUSTOM_TARGET(npaicons.android.legacy - COMMAND ${CONVERT} -background transparent -resize 36x36 npa.svg android/ldpi/npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 48x48 npa.svg android/mdpi/npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 72x72 npa.svg android/hdpi/npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 96x96 npa.svg android/xhdpi/npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 144x144 npa.svg android/xxhdpi/npa.png - COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 192x192 npa.svg android/xxxhdpi/npa.png + ADD_CUSTOM_TARGET(npaicons.android.adaptive.background + COMMAND ${CONVERT} -background transparent -resize 81x81 adaptive_background.svg ldpi/background_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 108x108 adaptive_background.svg mdpi/background_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 162x162 adaptive_background.svg hdpi/background_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 216x216 adaptive_background.svg xhdpi/background_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 324x324 adaptive_background.svg xxhdpi/background_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 432x432 adaptive_background.svg xxxhdpi/background_npa.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(npaicons.android.adaptive.foreground + COMMAND ${CONVERT} -background transparent -resize 81x81 adaptive_foreground_release.svg ldpi/foreground_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 108x108 adaptive_foreground_release.svg mdpi/foreground_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 162x162 adaptive_foreground_release.svg hdpi/foreground_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 216x216 adaptive_foreground_release.svg xhdpi/foreground_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 324x324 adaptive_foreground_release.svg xxhdpi/foreground_npa.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 432x432 adaptive_foreground_release.svg xxxhdpi/foreground_npa.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(npaicons.android.adaptive.foreground.beta + COMMAND ${CONVERT} -background transparent -resize 81x81 adaptive_foreground_beta.svg ldpi/foreground_npa_beta.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 108x108 adaptive_foreground_beta.svg mdpi/foreground_npa_beta.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 162x162 adaptive_foreground_beta.svg hdpi/foreground_npa_beta.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 216x216 adaptive_foreground_beta.svg xhdpi/foreground_npa_beta.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 324x324 adaptive_foreground_beta.svg xxhdpi/foreground_npa_beta.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 432x432 adaptive_foreground_beta.svg xxxhdpi/foreground_npa_beta.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(npaicons.android.adaptive.foreground.preview + COMMAND ${CONVERT} -background transparent -resize 81x81 adaptive_foreground_preview.svg ldpi/foreground_npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 160 -resize 108x108 adaptive_foreground_preview.svg mdpi/foreground_npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 240 -resize 162x162 adaptive_foreground_preview.svg hdpi/foreground_npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 320 -resize 216x216 adaptive_foreground_preview.svg xhdpi/foreground_npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 480 -resize 324x324 adaptive_foreground_preview.svg xxhdpi/foreground_npa_preview.png + COMMAND ${CONVERT} -background transparent -units PixelsPerInch -resample 640 -resize 432x432 adaptive_foreground_preview.svg xxxhdpi/foreground_npa_preview.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(npaicons.ios.launchimage + COMMAND ${CONVERT} -background none -resize 256x256 npa.svg iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage.png + COMMAND ${CONVERT} -background none -resize 512x512 npa.svg iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage@2x.png + COMMAND ${CONVERT} -background none -resize 768x768 npa.svg iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage@3x.png WORKING_DIRECTORY ${RESOURCES_DIR}/images) - ADD_CUSTOM_TARGET(npaicons.playstore - COMMAND ${CONVERT} -background '${BACKGROUND_COLOR}' -units PixelsPerInch -resample 1120 -resize 336x336 -gravity center -extent 512x512 ${RESOURCES_DIR}/images/npa.svg playstore.png - COMMAND ${CONVERT} -background '${BACKGROUND_COLOR}' -units PixelsPerInch -resample 1120 -resize 336x336 -gravity center -extent 512x512 ${RESOURCES_DIR}/images/npa_preview.svg playstore_preview.png - ) - - ADD_CUSTOM_TARGET(npaicons.ios.beta - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 20x20 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 40x40 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 60x60 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@3x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 29x29 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 58x58 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 87x87 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 40x40 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 80x80 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 120x120 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 120x120 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 180x180 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@3x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 76x76 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 152x152 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 167x167 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 1024x1024 iOS/appIcons/npa_beta.svg iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon1024.png + ADD_CUSTOM_TARGET(npaicons.ios.launchimage.beta COMMAND ${CONVERT} -background none -resize 256x256 npa_beta.svg iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage.png COMMAND ${CONVERT} -background none -resize 512x512 npa_beta.svg iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@2x.png COMMAND ${CONVERT} -background none -resize 768x768 npa_beta.svg iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@3x.png WORKING_DIRECTORY ${RESOURCES_DIR}/images) ADD_CUSTOM_TARGET(npaicons.ios - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 20x20 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 40x40 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 60x60 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@3x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 29x29 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 58x58 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 87x87 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 40x40 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 80x80 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 120x120 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 120x120 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 180x180 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@3x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 76x76 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 152x152 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 167x167 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png - COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 1024x1024 iOS/appIcons/npa.svg iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon1024.png - COMMAND ${CONVERT} -background none -resize 256x256 npa.svg iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage.png - COMMAND ${CONVERT} -background none -resize 512x512 npa.svg iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage@2x.png - COMMAND ${CONVERT} -background none -resize 768x768 npa.svg iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage@3x.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 20x20 npa.svg Images.xcassets/AppIcon.appiconset/icon20.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 40x40 npa.svg Images.xcassets/AppIcon.appiconset/icon20@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 60x60 npa.svg Images.xcassets/AppIcon.appiconset/icon20@3x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 29x29 npa.svg Images.xcassets/AppIcon.appiconset/iconSmall.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 58x58 npa.svg Images.xcassets/AppIcon.appiconset/iconSmall@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 87x87 npa.svg Images.xcassets/AppIcon.appiconset/iconSmall@3x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 40x40 npa.svg Images.xcassets/AppIcon.appiconset/iconSmall40.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 80x80 npa.svg Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 120x120 npa.svg Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 120x120 npa.svg Images.xcassets/AppIcon.appiconset/icon60@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 180x180 npa.svg Images.xcassets/AppIcon.appiconset/icon60@3x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 76x76 npa.svg Images.xcassets/AppIcon.appiconset/icon76.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 152x152 npa.svg Images.xcassets/AppIcon.appiconset/icon76@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 167x167 npa.svg Images.xcassets/AppIcon.appiconset/icon83.5@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 1024x1024 npa.svg Images.xcassets/AppIcon.appiconset/icon1024.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/iOS/appIcons) - ADD_CUSTOM_TARGET(npaicons DEPENDS npaicons.docs npaicons.win npaicons.ios npaicons.ios.beta npaicons.playstore npaicons.android.background npaicons.android.foreground npaicons.android.foreground.beta npaicons.android.foreground.preview npaicons.android.legacy npaicons.android.legacy.beta npaicons.android.legacy.preview) + ADD_CUSTOM_TARGET(npaicons.ios.beta + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 20x20 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon20.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 40x40 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon20@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 60x60 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon20@3x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 29x29 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/iconSmall.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 58x58 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 87x87 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 40x40 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/iconSmall40.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 80x80 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 120x120 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 120x120 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon60@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 180x180 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon60@3x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 76x76 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon76.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 152x152 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon76@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 167x167 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png + COMMAND ${CONVERT} -alpha off -background '${BACKGROUND_COLOR}' -resize 1024x1024 npa_beta.svg beta/Images.xcassets/AppIcon.appiconset/icon1024.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/iOS/appIcons) + + ADD_CUSTOM_TARGET(npaicons DEPENDS npaicons.docs npaicons.win npaicons.android.playstore npaicons.android.legacy npaicons.android.legacy.beta npaicons.android.legacy.preview npaicons.android.adaptive.background npaicons.android.adaptive.foreground npaicons.android.adaptive.foreground.beta npaicons.android.adaptive.foreground.preview npaicons.ios.launchimage npaicons.ios.launchimage.beta npaicons.ios npaicons.ios.beta) + + ADD_CUSTOM_TARGET(readerimages + COMMAND ${CONVERT} -background none -resize 512x512 img_RemoteReader.svg ${RESOURCES_DIR}/updatable-files/reader/img_RemoteReader.png + COMMAND ${CONVERT} -background none -resize 512x512 img_RemoteReader_mit_ausweis.svg ${RESOURCES_DIR}/updatable-files/reader/img_RemoteReader_mit_ausweis.png + COMMAND ${CONVERT} -background none -resize 512x512 img_PersoSim.svg ${RESOURCES_DIR}/updatable-files/reader/img_PersoSim.png + COMMAND ${CONVERT} -background none -resize 512x512 img_PersoSim_mit_ausweis.svg ${RESOURCES_DIR}/updatable-files/reader/img_PersoSim_mit_ausweis.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/reader/src) ENDIF() FIND_PROGRAM(PNGQUANT pngquant CMAKE_FIND_ROOT_PATH_BOTH) IF(PNGQUANT) SET(PNGQUANT_CMD pngquant -f -o) - ADD_CUSTOM_TARGET(pngquant.npaicons.docs + ADD_CUSTOM_TARGET(pngquant.docs COMMAND ${PNGQUANT_CMD} npa_docs.png -- npa_docs.png WORKING_DIRECTORY ${RESOURCES_DIR}/images) - ADD_CUSTOM_TARGET(pngquant.ios.beta - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@2x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@3x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@3x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@2x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@3x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@3x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76@2x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon1024.png -- iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon1024.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage.png -- iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@2x.png -- iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@3x.png -- iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@3x.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) - - ADD_CUSTOM_TARGET(pngquant.ios - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@2x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@3x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@3x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@2x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@3x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@3x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76@2x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon1024.png -- iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon1024.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage.png -- iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage@2x.png -- iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage@2x.png - COMMAND ${PNGQUANT_CMD} iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage@3x.png -- iOS/appIcons/Images.xcassets/LaunchImage.imageset/launchImage@3x.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) - - ADD_CUSTOM_TARGET(pngquant.android.background - COMMAND ${PNGQUANT_CMD} android/ldpi/background_npa.png -- android/ldpi/background_npa.png - COMMAND ${PNGQUANT_CMD} android/mdpi/background_npa.png -- android/mdpi/background_npa.png - COMMAND ${PNGQUANT_CMD} android/hdpi/background_npa.png -- android/hdpi/background_npa.png - COMMAND ${PNGQUANT_CMD} android/xhdpi/background_npa.png -- android/xhdpi/background_npa.png - COMMAND ${PNGQUANT_CMD} android/xxhdpi/background_npa.png -- android/xxhdpi/background_npa.png - COMMAND ${PNGQUANT_CMD} android/xxxhdpi/background_npa.png -- android/xxxhdpi/background_npa.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) - - ADD_CUSTOM_TARGET(pngquant.android.foreground.preview - COMMAND ${PNGQUANT_CMD} android/ldpi/foreground_npa_preview.png -- android/ldpi/foreground_npa_preview.png - COMMAND ${PNGQUANT_CMD} android/mdpi/foreground_npa_preview.png -- android/mdpi/foreground_npa_preview.png - COMMAND ${PNGQUANT_CMD} android/hdpi/foreground_npa_preview.png -- android/hdpi/foreground_npa_preview.png - COMMAND ${PNGQUANT_CMD} android/xhdpi/foreground_npa_preview.png -- android/xhdpi/foreground_npa_preview.png - COMMAND ${PNGQUANT_CMD} android/xxhdpi/foreground_npa_preview.png -- android/xxhdpi/foreground_npa_preview.png - COMMAND ${PNGQUANT_CMD} android/xxxhdpi/foreground_npa_preview.png -- android/xxxhdpi/foreground_npa_preview.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) - - ADD_CUSTOM_TARGET(pngquant.android.legacy.preview - COMMAND ${PNGQUANT_CMD} android/ldpi/npa_preview.png -- android/ldpi/npa_preview.png - COMMAND ${PNGQUANT_CMD} android/mdpi/npa_preview.png -- android/mdpi/npa_preview.png - COMMAND ${PNGQUANT_CMD} android/hdpi/npa_preview.png -- android/hdpi/npa_preview.png - COMMAND ${PNGQUANT_CMD} android/xhdpi/npa_preview.png -- android/xhdpi/npa_preview.png - COMMAND ${PNGQUANT_CMD} android/xxhdpi/npa_preview.png -- android/xxhdpi/npa_preview.png - COMMAND ${PNGQUANT_CMD} android/xxxhdpi/npa_preview.png -- android/xxxhdpi/npa_preview.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) - - ADD_CUSTOM_TARGET(pngquant.android.foreground.beta - COMMAND ${PNGQUANT_CMD} android/ldpi/foreground_npa_beta.png -- android/ldpi/foreground_npa_beta.png - COMMAND ${PNGQUANT_CMD} android/mdpi/foreground_npa_beta.png -- android/mdpi/foreground_npa_beta.png - COMMAND ${PNGQUANT_CMD} android/hdpi/foreground_npa_beta.png -- android/hdpi/foreground_npa_beta.png - COMMAND ${PNGQUANT_CMD} android/xhdpi/foreground_npa_beta.png -- android/xhdpi/foreground_npa_beta.png - COMMAND ${PNGQUANT_CMD} android/xxhdpi/foreground_npa_beta.png -- android/xxhdpi/foreground_npa_beta.png - COMMAND ${PNGQUANT_CMD} android/xxxhdpi/foreground_npa_beta.png -- android/xxxhdpi/foreground_npa_beta.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) + ADD_CUSTOM_TARGET(pngquant.android.legacy + COMMAND ${PNGQUANT_CMD} ldpi/npa.png -- ldpi/npa.png + COMMAND ${PNGQUANT_CMD} mdpi/npa.png -- mdpi/npa.png + COMMAND ${PNGQUANT_CMD} hdpi/npa.png -- hdpi/npa.png + COMMAND ${PNGQUANT_CMD} xhdpi/npa.png -- xhdpi/npa.png + COMMAND ${PNGQUANT_CMD} xxhdpi/npa.png -- xxhdpi/npa.png + COMMAND ${PNGQUANT_CMD} xxxhdpi/npa.png -- xxxhdpi/npa.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) ADD_CUSTOM_TARGET(pngquant.android.legacy.beta - COMMAND ${PNGQUANT_CMD} android/ldpi/npa_beta.png -- android/ldpi/npa_beta.png - COMMAND ${PNGQUANT_CMD} android/mdpi/npa_beta.png -- android/mdpi/npa_beta.png - COMMAND ${PNGQUANT_CMD} android/hdpi/npa_beta.png -- android/hdpi/npa_beta.png - COMMAND ${PNGQUANT_CMD} android/xhdpi/npa_beta.png -- android/xhdpi/npa_beta.png - COMMAND ${PNGQUANT_CMD} android/xxhdpi/npa_beta.png -- android/xxhdpi/npa_beta.png - COMMAND ${PNGQUANT_CMD} android/xxxhdpi/npa_beta.png -- android/xxxhdpi/npa_beta.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) + COMMAND ${PNGQUANT_CMD} ldpi/npa_beta.png -- ldpi/npa_beta.png + COMMAND ${PNGQUANT_CMD} mdpi/npa_beta.png -- mdpi/npa_beta.png + COMMAND ${PNGQUANT_CMD} hdpi/npa_beta.png -- hdpi/npa_beta.png + COMMAND ${PNGQUANT_CMD} xhdpi/npa_beta.png -- xhdpi/npa_beta.png + COMMAND ${PNGQUANT_CMD} xxhdpi/npa_beta.png -- xxhdpi/npa_beta.png + COMMAND ${PNGQUANT_CMD} xxxhdpi/npa_beta.png -- xxxhdpi/npa_beta.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) - ADD_CUSTOM_TARGET(pngquant.android.foreground - COMMAND ${PNGQUANT_CMD} android/ldpi/foreground_npa.png -- android/ldpi/foreground_npa.png - COMMAND ${PNGQUANT_CMD} android/mdpi/foreground_npa.png -- android/mdpi/foreground_npa.png - COMMAND ${PNGQUANT_CMD} android/hdpi/foreground_npa.png -- android/hdpi/foreground_npa.png - COMMAND ${PNGQUANT_CMD} android/xhdpi/foreground_npa.png -- android/xhdpi/foreground_npa.png - COMMAND ${PNGQUANT_CMD} android/xxhdpi/foreground_npa.png -- android/xxhdpi/foreground_npa.png - COMMAND ${PNGQUANT_CMD} android/xxxhdpi/foreground_npa.png -- android/xxxhdpi/foreground_npa.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) + ADD_CUSTOM_TARGET(pngquant.android.legacy.preview + COMMAND ${PNGQUANT_CMD} ldpi/npa_preview.png -- ldpi/npa_preview.png + COMMAND ${PNGQUANT_CMD} mdpi/npa_preview.png -- mdpi/npa_preview.png + COMMAND ${PNGQUANT_CMD} hdpi/npa_preview.png -- hdpi/npa_preview.png + COMMAND ${PNGQUANT_CMD} xhdpi/npa_preview.png -- xhdpi/npa_preview.png + COMMAND ${PNGQUANT_CMD} xxhdpi/npa_preview.png -- xxhdpi/npa_preview.png + COMMAND ${PNGQUANT_CMD} xxxhdpi/npa_preview.png -- xxxhdpi/npa_preview.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(pngquant.android.adaptive.background + COMMAND ${PNGQUANT_CMD} ldpi/background_npa.png -- ldpi/background_npa.png + COMMAND ${PNGQUANT_CMD} mdpi/background_npa.png -- mdpi/background_npa.png + COMMAND ${PNGQUANT_CMD} hdpi/background_npa.png -- hdpi/background_npa.png + COMMAND ${PNGQUANT_CMD} xhdpi/background_npa.png -- xhdpi/background_npa.png + COMMAND ${PNGQUANT_CMD} xxhdpi/background_npa.png -- xxhdpi/background_npa.png + COMMAND ${PNGQUANT_CMD} xxxhdpi/background_npa.png -- xxxhdpi/background_npa.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(pngquant.android.adaptive.foreground + COMMAND ${PNGQUANT_CMD} ldpi/foreground_npa.png -- ldpi/foreground_npa.png + COMMAND ${PNGQUANT_CMD} mdpi/foreground_npa.png -- mdpi/foreground_npa.png + COMMAND ${PNGQUANT_CMD} hdpi/foreground_npa.png -- hdpi/foreground_npa.png + COMMAND ${PNGQUANT_CMD} xhdpi/foreground_npa.png -- xhdpi/foreground_npa.png + COMMAND ${PNGQUANT_CMD} xxhdpi/foreground_npa.png -- xxhdpi/foreground_npa.png + COMMAND ${PNGQUANT_CMD} xxxhdpi/foreground_npa.png -- xxxhdpi/foreground_npa.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(pngquant.android.adaptive.foreground.beta + COMMAND ${PNGQUANT_CMD} ldpi/foreground_npa_beta.png -- ldpi/foreground_npa_beta.png + COMMAND ${PNGQUANT_CMD} mdpi/foreground_npa_beta.png -- mdpi/foreground_npa_beta.png + COMMAND ${PNGQUANT_CMD} hdpi/foreground_npa_beta.png -- hdpi/foreground_npa_beta.png + COMMAND ${PNGQUANT_CMD} xhdpi/foreground_npa_beta.png -- xhdpi/foreground_npa_beta.png + COMMAND ${PNGQUANT_CMD} xxhdpi/foreground_npa_beta.png -- xxhdpi/foreground_npa_beta.png + COMMAND ${PNGQUANT_CMD} xxxhdpi/foreground_npa_beta.png -- xxxhdpi/foreground_npa_beta.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(pngquant.android.adaptive.foreground.preview + COMMAND ${PNGQUANT_CMD} ldpi/foreground_npa_preview.png -- ldpi/foreground_npa_preview.png + COMMAND ${PNGQUANT_CMD} mdpi/foreground_npa_preview.png -- mdpi/foreground_npa_preview.png + COMMAND ${PNGQUANT_CMD} hdpi/foreground_npa_preview.png -- hdpi/foreground_npa_preview.png + COMMAND ${PNGQUANT_CMD} xhdpi/foreground_npa_preview.png -- xhdpi/foreground_npa_preview.png + COMMAND ${PNGQUANT_CMD} xxhdpi/foreground_npa_preview.png -- xxhdpi/foreground_npa_preview.png + COMMAND ${PNGQUANT_CMD} xxxhdpi/foreground_npa_preview.png -- xxxhdpi/foreground_npa_preview.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/android) + + ADD_CUSTOM_TARGET(pngquant.ios.launchimage + COMMAND ${PNGQUANT_CMD} launchImage.png -- launchImage.png + COMMAND ${PNGQUANT_CMD} launchImage@2x.png -- launchImage@2x.png + COMMAND ${PNGQUANT_CMD} launchImage@3x.png -- launchImage@3x.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/iOS/appIcons/Images.xcassets/LaunchImage.imageset) + + ADD_CUSTOM_TARGET(pngquant.ios.launchimage.beta + COMMAND ${PNGQUANT_CMD} launchImage.png -- launchImage.png + COMMAND ${PNGQUANT_CMD} launchImage@2x.png -- launchImage@2x.png + COMMAND ${PNGQUANT_CMD} launchImage@3x.png -- launchImage@3x.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset) - ADD_CUSTOM_TARGET(pngquant.android.legacy - COMMAND ${PNGQUANT_CMD} android/ldpi/npa.png -- android/ldpi/npa.png - COMMAND ${PNGQUANT_CMD} android/mdpi/npa.png -- android/mdpi/npa.png - COMMAND ${PNGQUANT_CMD} android/hdpi/npa.png -- android/hdpi/npa.png - COMMAND ${PNGQUANT_CMD} android/xhdpi/npa.png -- android/xhdpi/npa.png - COMMAND ${PNGQUANT_CMD} android/xxhdpi/npa.png -- android/xxhdpi/npa.png - COMMAND ${PNGQUANT_CMD} android/xxxhdpi/npa.png -- android/xxxhdpi/npa.png - WORKING_DIRECTORY ${RESOURCES_DIR}/images) + ADD_CUSTOM_TARGET(pngquant.ios + COMMAND ${PNGQUANT_CMD} icon20.png -- icon20.png + COMMAND ${PNGQUANT_CMD} icon20@2x.png -- icon20@2x.png + COMMAND ${PNGQUANT_CMD} icon20@3x.png -- icon20@3x.png + COMMAND ${PNGQUANT_CMD} iconSmall.png -- iconSmall.png + COMMAND ${PNGQUANT_CMD} iconSmall@2x.png -- iconSmall@2x.png + COMMAND ${PNGQUANT_CMD} iconSmall@3x.png -- iconSmall@3x.png + COMMAND ${PNGQUANT_CMD} iconSmall40.png -- iconSmall40.png + COMMAND ${PNGQUANT_CMD} iconSmall40@2x.png -- iconSmall40@2x.png + COMMAND ${PNGQUANT_CMD} iconSmall40@3x.png -- iconSmall40@3x.png + COMMAND ${PNGQUANT_CMD} icon60@2x.png -- icon60@2x.png + COMMAND ${PNGQUANT_CMD} icon60@3x.png -- icon60@3x.png + COMMAND ${PNGQUANT_CMD} icon76.png -- icon76.png + COMMAND ${PNGQUANT_CMD} icon76@2x.png -- icon76@2x.png + COMMAND ${PNGQUANT_CMD} icon83.5@2x.png -- icon83.5@2x.png + COMMAND ${PNGQUANT_CMD} icon1024.png -- icon1024.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset) - ADD_CUSTOM_TARGET(pngquant DEPENDS pngquant.npaicons.docs pngquant.ios pngquant.ios.beta pngquant.android.background pngquant.android.foreground pngquant.android.foreground.beta pngquant.android.foreground.preview pngquant.android.legacy pngquant.android.legacy.beta pngquant.android.legacy.preview) + ADD_CUSTOM_TARGET(pngquant.ios.beta + COMMAND ${PNGQUANT_CMD} icon20.png -- icon20.png + COMMAND ${PNGQUANT_CMD} icon20@2x.png -- icon20@2x.png + COMMAND ${PNGQUANT_CMD} icon20@3x.png -- icon20@3x.png + COMMAND ${PNGQUANT_CMD} iconSmall.png -- iconSmall.png + COMMAND ${PNGQUANT_CMD} iconSmall@2x.png -- iconSmall@2x.png + COMMAND ${PNGQUANT_CMD} iconSmall@3x.png -- iconSmall@3x.png + COMMAND ${PNGQUANT_CMD} iconSmall40.png -- iconSmall40.png + COMMAND ${PNGQUANT_CMD} iconSmall40@2x.png -- iconSmall40@2x.png + COMMAND ${PNGQUANT_CMD} iconSmall40@3x.png -- iconSmall40@3x.png + COMMAND ${PNGQUANT_CMD} icon60@2x.png -- icon60@2x.png + COMMAND ${PNGQUANT_CMD} icon60@3x.png -- icon60@3x.png + COMMAND ${PNGQUANT_CMD} icon76.png -- icon76.png + COMMAND ${PNGQUANT_CMD} icon76@2x.png -- icon76@2x.png + COMMAND ${PNGQUANT_CMD} icon83.5@2x.png -- icon83.5@2x.png + COMMAND ${PNGQUANT_CMD} icon1024.png -- icon1024.png + WORKING_DIRECTORY ${RESOURCES_DIR}/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset) + + ADD_CUSTOM_TARGET(pngquant DEPENDS pngquant.docs pngquant.android.legacy pngquant.android.legacy.beta pngquant.android.legacy.preview pngquant.android.adaptive.background pngquant.android.adaptive.foreground pngquant.android.adaptive.foreground.beta pngquant.android.adaptive.foreground.preview pngquant.ios.launchimage pngquant.ios.launchimage.beta pngquant.ios pngquant.ios.beta) + + ADD_CUSTOM_TARGET(pngquant.readerimages + COMMAND ${PNGQUANT_CMD} img_RemoteReader.png -- img_RemoteReader.png + COMMAND ${PNGQUANT_CMD} img_RemoteReader_mit_ausweis.png -- img_RemoteReader_mit_ausweis.png + COMMAND ${PNGQUANT_CMD} img_PersoSim.png -- img_PersoSim.png + COMMAND ${PNGQUANT_CMD} img_PersoSim_mit_ausweis.png -- img_PersoSim_mit_ausweis.png + WORKING_DIRECTORY ${RESOURCES_DIR}/updatable-files/reader) ENDIF() IF(NOT JAVA_EXECUTABLE) diff --git a/cmake/android.toolchain.cmake b/cmake/android.toolchain.cmake index 9b8682369..10e8a4916 100644 --- a/cmake/android.toolchain.cmake +++ b/cmake/android.toolchain.cmake @@ -21,9 +21,15 @@ ENDIF() IF(NOT ANDROID_BUILD_TOOLS_REVISION) SET(_android_build_tools_dir "${ANDROID_SDK}/build-tools") - FILE(GLOB build_tools ${_android_build_tools_dir}/*) - LIST(LENGTH build_tools build_tools_len) - IF(NOT build_tools_len EQUAL 1) + + FILE(GLOB build_tools_list ${_android_build_tools_dir}/*) + LIST(LENGTH build_tools_list build_tools_len) + IF(build_tools_len GREATER 0) + LIST(SORT build_tools_list) + LIST(GET build_tools_list -1 build_tools) + ENDIF() + + IF(NOT build_tools) MESSAGE(FATAL_ERROR "Cannot determine ANDROID_BUILD_TOOLS_REVISION: ${_android_build_tools_dir}") ENDIF() @@ -52,8 +58,6 @@ IF(NOT CMAKE_ANDROID_ARCH_ABI) ENDIF() -OPTION(ANDROID_BUILD_AAR "Build AAR file instead of APK" OFF) - SET(CMAKE_FIND_ROOT_PATH ${CMAKE_PREFIX_PATH} CACHE STRING "android find search path root") SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt index 7c650e83f..c7313a881 100644 --- a/docs/CMakeLists.txt +++ b/docs/CMakeLists.txt @@ -4,6 +4,8 @@ IF(SPHINX_FOUND) SPHINX_GEN("${CMAKE_CURRENT_SOURCE_DIR}/sdk" "sdk" BUILDER changes html latex DEFAULT_LANG en) SPHINX_GEN("${CMAKE_CURRENT_SOURCE_DIR}/installation" "inst" BUILDER changes html latex) + + SPHINX_GEN("${CMAKE_CURRENT_SOURCE_DIR}/integration" "inte" BUILDER changes html latex) ELSE() MESSAGE(STATUS "No documentation will be generated") ENDIF() diff --git a/docs/installation/CommunicationModel_de.graphml b/docs/installation/CommunicationModel_de.graphml index f3ff314bb..608b00778 100644 --- a/docs/installation/CommunicationModel_de.graphml +++ b/docs/installation/CommunicationModel_de.graphml @@ -83,7 +83,7 @@ - Dienstanbieter + Anbieter diff --git a/docs/installation/README.de.rst b/docs/installation/README.de.rst index 54d01b1a3..9ede05a58 100644 --- a/docs/installation/README.de.rst +++ b/docs/installation/README.de.rst @@ -72,7 +72,7 @@ UPDATECHECK Die Einstellung kann dann durch den Benutzer in der AusweisApp2 nicht geändert werden. Ohne Angabe ist die Überprüfung aktiviert, der Benutzer kann die Einstellung jedoch ändern. Der UPDATECHECK Parameter beeinflusst weder die - Aktualisierung der Diensteanbieterliste noch die Aktualisierung der + Aktualisierung der Anbieterliste noch die Aktualisierung der Kartenleserinformationen. ONSCREENKEYBOARD @@ -83,7 +83,7 @@ ONSCREENKEYBOARD HISTORY Jede Selbstauskunft oder Authentisierung wird im Verlauf gespeichert. Dabei werden jedoch keine persönlichen Daten gespeichert, sondern nur der Zeitpunkt, - der Diensteanbieter und die ausgelesenen Datenfelder (ohne Inhalt). Durch Setzen + der Anbieter und die ausgelesenen Datenfelder (ohne Inhalt). Durch Setzen von HISTORY auf false oder true kann der Verlauf deaktiviert bzw. aktiviert werden. Der Benutzer kann diese Einstellung anpassen. @@ -96,6 +96,12 @@ Kommando: msiexec /i AusweisApp2-X.YY.Z.msi /quiet TRANSFORMS=file.mst +Um den Start der AusweisApp2 auf Systemen mit fehlender Grafikbeschleunigung +zu optimieren, kann die Systemvariable "QT_QUICK_BACKEND" auf den Wert +"software" gesetzt werden. In diesem Fall verzichtet die AusweisApp2 auf den +Versuch die Grafikbeschleunigung zu nutzen und startet direkt mit dem +alternativen Softwarerenderer. + macOS ----- @@ -176,7 +182,7 @@ Die AusweisApp2 startet einen HTTP-Server, der über Port 24727 erreichbar ist. Der Server empfängt nur auf der localhost Netzwerkschnittstelle. Die Erreichbarkeit dieses lokalen Servers ist für die Onlineausweisfunktion -notwendig, da Diensteanbieter mit einem HTTP-Redirect auf den lokalen Server +notwendig, da Anbieter mit einem HTTP-Redirect auf den lokalen Server umleiten um den Ausweisvorgang in der AusweisApp2 fortzuführen (eID1). Außerdem wird über den Server die Verwendung der AusweisApp2 von anderen Anwendungen über eine Websocket-Schnittstelle angeboten (SDK-Funktion, eID-SDK). @@ -228,12 +234,12 @@ CA-Zertifikate im Windows-Truststore werden daher ignoriert. :widths: 8, 8, 8, 8, 8, 35, 25 "eID1", TCP, 24727, "eingehend", "Nein", "Online-Ausweisvorgang, eID-Aktivierung [#TR-03124]_", "Nur erreichbar von localhost [#TR-03124]_" - "eID2", TCP, 443, "ausgehend", "Nein", "Online-Ausweisvorgang, Verbindung zum Dienstanbieter, TLS-1-2-Kanal [#TR-03124]_", "TLS-Zertifikate verschränkt mit Berechtigungs-Zertifikat [#TR-03124]_" + "eID2", TCP, 443, "ausgehend", "Nein", "Online-Ausweisvorgang, Verbindung zum Anbieter, TLS-1-2-Kanal [#TR-03124]_", "TLS-Zertifikate verschränkt mit Berechtigungs-Zertifikat [#TR-03124]_" "eID3", TCP, 443, "ausgehend", "Nein", "Online-Ausweisvorgang, Verbindung zum eID-Server, TLS-2-Kanal [#TR-03124]_", "TLS-Zertifikate verschränkt mit Berechtigungs-Zertifikat [#TR-03124]_" "eID-SDK", TCP, 24727, "eingehend", "Nein", "Verwendung der SDK-Schnittstelle", "Nur erreichbar von localhost [#TR-03124]_" "SaK1", UDP, 24727, "eingehend", "Ja", "Smartphone als Kartenleser, Erkennung [#TR-03112]_", "Broadcasts" "SaK2", TCP, , "ausgehend", "Ja", "Smartphone als Kartenleser, Verwendung [#TR-03112]_", "Verbindung im lokalen Subnetz" - "Update", TCP, 443, "ausgehend", "Ja", "Updates [#govurl]_ zu Dienstanbietern und Kartenlesern sowie Informationen zu neuen AusweisApp2-Versionen [#updatecheck]_ .", "Die Zertifikate der TLS-Verbindung werden mit in der AusweisApp2 mitgelieferten CA-Zertifikaten validiert. Im Betriebssystem hinterlegte CA-Zertifikate werden ignoriert." + "Update", TCP, 443, "ausgehend", "Ja", "Updates [#govurl]_ zu Anbietern und Kartenlesern sowie Informationen zu neuen AusweisApp2-Versionen [#updatecheck]_ .", "Die Zertifikate der TLS-Verbindung werden mit in der AusweisApp2 mitgelieferten CA-Zertifikaten validiert. Im Betriebssystem hinterlegte CA-Zertifikate werden ignoriert." .. [#TR-03124] Siehe TR-03124 des BSI .. [#TR-03112] Siehe TR-03112-6 des BSI diff --git a/docs/installation/README.en.rst b/docs/installation/README.en.rst index 8c4a040c7..23537a2d3 100644 --- a/docs/installation/README.en.rst +++ b/docs/installation/README.en.rst @@ -75,7 +75,7 @@ ONSCREENKEYBOARD HISTORY Each authentication is saved in the history. No personal data is saved, only the - time of authentication, the service provider and the selected fields (without + time of authentication, the provider and the selected fields (without content). Indicating HISTORY as false or true, the history function is deactivated or activated. Users are able to adjust the settings. @@ -87,6 +87,11 @@ tables. The MST file can be transferred with the following command: msiexec /i AusweisApp2-X.YY.Z.msi /quiet TRANSFORMS=file.mst +In order to optimize the start of the AusweisApp2 on systems with no graphics +acceleration, the system variable "QT_QUICK_BACKEND" can be set to the value +"software". In this case, the AusweisApp2 does not attempt to use graphics +acceleration and starts directly with the alternative software renderer. + macOS ----- @@ -160,7 +165,7 @@ individual connections made by the AusweisApp2. The AusweisApp2 starts a HTTP-Server on port 24727. The server binds only to the localhost network interface. The availability of the local server is necessary for the online eID function, -because service providers will redirect the user with a HTTP redirect to the +because providers will redirect the user with a HTTP redirect to the local server to continue the authentication process in the AusweisApp2 (eID1). The server is also used to offer other local applications to use the AusweisApp2 via a websocket interface (SDK function, eID-SDK). @@ -208,12 +213,12 @@ TLS termination proxy. :widths: 8, 8, 8, 8, 8, 35, 25 "eID1", TCP, 24727, "incoming", "no", "Online eID function, eID activation [#TR-03124]_", "Only accessible from localhost [#TR-03124]_" - "eID2", TCP, 443, "outgoing", "no", "Online eID function, connection to the service provider, TLS-1-2 channel [#TR-03124]_", "TLS certificates interlaced with authorization certificate [#TR-03124]_" + "eID2", TCP, 443, "outgoing", "no", "Online eID function, connection to the provider, TLS-1-2 channel [#TR-03124]_", "TLS certificates interlaced with authorization certificate [#TR-03124]_" "eID3", TCP, 443, "outgoing", "no", "Online eID function, connection to eID-Server, TLS-2 channel [#TR-03124]_", "TLS certificates interlaced with authorization certificate [#TR-03124]_" "eID-SDK", TCP, 24727, "incoming", "no", "Usage of the SDK functionality", "Only accessible from localhost [#TR-03124]_" "SaC1", UDP, 24727, "incoming", "yes", "Smartphone as Card Reader, detection [#TR-03112]_", "Broadcasts" "SaC2", TCP, , "outgoing", "yes", "Smartphone as Card Reader, usage [#TR-03112]_", "Connection in local subnet" - "Update", TCP, 443, "outgoing", "yes", "Updates [#govurl]_ of service provider and card reader information as well as informations on new AusweisApp2 versions [#updatecheck]_ .", "TLS certificates will be validated against CA certificates included in the AusweisApp2. CA certificates provided by the OS are ignored." + "Update", TCP, 443, "outgoing", "yes", "Updates [#govurl]_ of provider and card reader information as well as informations on new AusweisApp2 versions [#updatecheck]_ .", "TLS certificates will be validated against CA certificates included in the AusweisApp2. CA certificates provided by the OS are ignored." .. [#TR-03124] See TR-03124 specification from the BSI .. [#TR-03112] See TR-03112-6 specifiaction from the BSI diff --git a/docs/installation/conf.py.in b/docs/installation/conf.py.in index a36922f69..8e612d863 100644 --- a/docs/installation/conf.py.in +++ b/docs/installation/conf.py.in @@ -42,7 +42,7 @@ master_doc = 'index' # General information about the project. project = 'AusweisApp2 Installation' -copyright = '2018-2019, Governikus GmbH & Co. KG' +copyright = '2018-2020, Governikus GmbH & Co. KG' author = 'Governikus GmbH & Co. KG' # The version info for the project you're documenting, acts as replacement for diff --git a/docs/integration/README.de.rst b/docs/integration/README.de.rst new file mode 100644 index 000000000..146dbf5af --- /dev/null +++ b/docs/integration/README.de.rst @@ -0,0 +1,54 @@ +Deutsch - Entwickleroptionen +============================ + +Die AusweisApp2 verfügt über sogenannte Entwickleroptionen. Diese sind +für die unterstützten Betriebssystem Windows und macOS verfügbar. Sie +unterstützen die Integration eines eID-Dienstes. + + +Windows & macOS +--------------- + +Das Aktivieren der Entwickleroptionen erfolgt sowohl für Windows als auch +für macOS über 10 Klicks auf die Versionsnummer im Bereich "Hilfe" -> +"Versionsinformationen". Nach der Aktivierung sind die Entwickleroptionen +über den Bereich "Einstellungen" erreichbar. + + +Android & iOS +------------- + +In den mobilen Versionen der AusweisApp2 ist der Entwicklermodus nicht +verfügbar. Lediglich der Testmodus (Test-PKI) für die Selbstauskunft kann +durch 10 Klicks auf die Lupe auf der Startseite aktiviert und deaktiviert werden. + + +Einstellungen +------------- + +Die Entwickleroptionen bieten zwei Einstellungsmöglichkeiten: + +Testmodus für die Selbstauskunft (Test-PKI) +''''''''''''''''''''''''''''''''''''''''''' + +Die Selbstauskunft ist ein fest integrierter Dienst der AusweisApp2 und kann +nur mit Echtausweisen genutzt werden. Wird der Testmodus (Test-PKI) aktiviert, +nutzt die AusweisApp2 einen Test-Dienst, der es ermöglicht, eine Selbstauskunft +mit einem Testausweis durchzuführen. + +Entwicklermodus +''''''''''''''' + +Mit der Aktivierung des Entwicklermodus werden einige Sicherheitsabfragen +während einer Authentisierung ignoriert. In Entwicklungsszenarien, in denen +ohnehin mit Test-Diensten gearbeitet wird, führt das Ignorieren der +Sicherheitsabfragen dazu, dass eine Authentisierung erfolgreich durchgeführt +werden kann. Dazu gehört beispielweise, dass neben sicheren TLS-Verbindungen +(https) auch unsichere Verbindungen ohne TLS (http) akzeptiert werden. Auch +werden abgelaufene Zertifikate ignoriert. Auf jede Sicherheitsverletzung wird +in den internen Benachrichtigungen der AusweisApp2 bzw. des Betriebssystems +hingewiesen. + + +**Wichtig:** Der Entwicklermodus kann nur für Test-Dienste verwendet werden, +eine Verwendung mit echten Berechtigungszertifikaten ist nicht möglich. diff --git a/docs/integration/README.en.rst b/docs/integration/README.en.rst new file mode 100644 index 000000000..719aa3cdf --- /dev/null +++ b/docs/integration/README.en.rst @@ -0,0 +1,52 @@ +English - Developer Options +=========================== + +AusweisApp2 features so-called developer options, available for the +supported operating systems of Windows and macOS. They facilitate +the integration of eID services. + + +Windows & macOS +--------------- + +Developer options are activated by the version number accessible via +"Help" -> "Version Information" 10 times. This is applicable for both +Windows and macOS. Once activated, the developer options are accessible +via "Settings". + + +Android & iOS +------------- + +The mobile version of AusweisApp2 does not feature the developer mode. Solely +the test mode (Test-PKI) for self-authentication may be activated and +deactivated by clicking the magnifying glass on the start screen 10 times. + + +Settings +-------- + +Developer options allow to adjust two different settings: + +Test mode for self-authentication (Test-PKI) +'''''''''''''''''''''''''''''''''''''''''''' + +In general, the self-authentication is a build-in service of AusweisApp2 and +can only be used with genuine ID cards. However, when in test mode, AusweisApp2 +uses a test service allowing for self-authentication with a test ID card. + +Developer mode +'''''''''''''' + +When the developer mode is activated, some safety measures during an +authentication process are ignored. Ignoring the safety measures with test +services usually employed in test scenarios, yields a successful authentication. +For example, secure TLS connections (https) as well as insecure connections +without TLS (http) are accepted. Invalid certificates will be ignored. Each +safety breach will be highlighted as an internal notification in AusweisApp2 +or the operating system respectively. + + +**Plese note:** +Developer mode can only be used for test services, usage with genuine provider +certificates is not possible. diff --git a/docs/integration/conf.py.in b/docs/integration/conf.py.in new file mode 100644 index 000000000..f7e994660 --- /dev/null +++ b/docs/integration/conf.py.in @@ -0,0 +1,171 @@ +#!/usr/bin/env python3 +# -*- coding: utf-8 -*- + +import sys +import os +import shlex + +# -- General configuration ------------------------------------------------ + +# If your documentation needs a minimal Sphinx version, state it here. +needs_sphinx = '1.4' + +# If true, figures, tables and code-blocks are automatically numbered +# if they has caption. For now, it works only with the HTML builder. +# Default is False. +numfig = True + +# Add any Sphinx extension module names here, as strings. They can be +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom +# ones. +extensions = [] + +locale_dirs = ['@SPHINX_DOCS_DIR@/locales/'] + +gettext_additional_targets = ['image'] +gettext_location = False +gettext_compact = True + +# Add any paths that contain templates here, relative to this directory. +#templates_path = ['@SPHINX_DOCS_DIR@/_templates'] + +# The suffix(es) of source filenames. +# You can specify multiple suffix as a list of string: +# source_suffix = ['.rst', '.md'] +source_suffix = '.rst' + +# The encoding of source files. +#source_encoding = 'utf-8-sig' + +# The master toctree document. +master_doc = 'index' + +# General information about the project. +project = 'AusweisApp2 Integration' +copyright = '2019-2020, Governikus GmbH & Co. KG' +author = 'Governikus GmbH & Co. KG' + +# The version info for the project you're documenting, acts as replacement for +# |version| and |release|, also used in various other places throughout the +# built documents. +# +# The short X.Y version. +version = '@PROJECT_VERSION@' +# The full version, including alpha/beta/rc tags. +release = '@VERSION_DVCS@' + +today = ' ' + +# The language for content autogenerated by Sphinx. Refer to documentation +# for a list of supported languages. +# +# This is also used if you do content translation via gettext catalogs. +# Usually you set "language" from the command line for these cases. +language = 'en' + +# List of patterns, relative to source directory, that match files and +# directories to ignore when looking for source files. +#exclude_patterns = [''] + + + +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = 'sphinx' + + +# The name of an image file (within the static path) to use as favicon of the +# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 +# pixels large. +html_favicon = '@SPHINX_DOCS_DIR@/../../resources/images/npa.ico' + +#html_theme_path = ['@SPHINX_DOCS_DIR@/_themes'] + +#html_theme = 'appcast' +html_theme = 'sphinx_rtd_theme' + +# If false, no module index is generated. +html_domain_indices = True + +# If false, no index is generated. +html_use_index = True + +# If true, "Created using Sphinx" is shown in the HTML footer. Default is True. +html_show_sphinx = False + +# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True. +html_show_copyright = True + +html_scaled_image_link = False + +# Output file base name for HTML help builder. +htmlhelp_basename = 'AusweisApp2Integration' + +html_context = { + 'display_github': False, + 'display_bitbucket': False, + 'show_source': False, + 'html_show_sourcelink': False, +} + +html_add_permalinks = "" + +# -- Options for LaTeX output --------------------------------------------- + +latex_elements = { +# The paper size ('letterpaper' or 'a4paper'). +'papersize': 'a4paper', + +# The font size ('10pt', '11pt' or '12pt'). +'pointsize': '11pt', + +# Additional stuff for the LaTeX preamble. +'preamble': ''' +\\usepackage{lscape} +\\hypersetup{pdfauthor={Governikus GmbH \& Co. KG}, + pdftitle={AusweisApp2}, + pdfsubject={Integration}, + pdfkeywords={Integration}, + pdfproducer={LaTeX}, + pdfcreator={Sphinx} +} +''', + +# Override tableofcontents +'tableofcontents': ''' +\\tableofcontents +\\newpage +\\pagestyle{plain} +\\pagenumbering{arabic} +''', + +# Latex figure (float) alignment +'figure_align': 'H', +} + +# Grouping the document tree into LaTeX files. List of tuples +# (source start file, target name, title, +# author, documentclass [howto, manual, or own class]). +latex_documents = [ + (master_doc, 'AusweisApp2-@VERSION_DVCS@-Integration.tex', 'AusweisApp2 Integration', + 'Governikus GmbH \& Co. KG', 'howto'), +] + +# The name of an image file (relative to this directory) to place at the top of +# the title page. +latex_logo = '@SPHINX_DOCS_DIR@/../../resources/images/npa_docs.png' + +# For "manual" documents, if this is true, then toplevel headings are parts, +# not chapters. +#latex_use_parts = False + +# If true, show page references after internal links. +latex_show_pagerefs = True + +# If true, show URL addresses after external links. +latex_show_urls = 'footnote' + +# Documents to append as an appendix to all manuals. +#latex_appendices = [] + +# If false, no module index is generated. +#latex_domain_indices = True diff --git a/docs/integration/index.rst b/docs/integration/index.rst new file mode 100644 index 000000000..5688de075 --- /dev/null +++ b/docs/integration/index.rst @@ -0,0 +1,13 @@ +Table of contents +----------------- + +.. raw:: latex + + \clearpage + +.. toctree:: + :maxdepth: 3 + :caption: Integration + + README.de + README.en diff --git a/docs/releasenotes/1.14.0.rst b/docs/releasenotes/1.14.0.rst index 683b160d7..738baab08 100644 --- a/docs/releasenotes/1.14.0.rst +++ b/docs/releasenotes/1.14.0.rst @@ -32,6 +32,8 @@ Anwender - Unter Windows 10 kommt es nicht mehr zu einem Absturz bei Proxies mit Passwort-Authentisierung. + - Unterstützung von OS X 10.9 wurde eingestellt. + Entwickler """""""""" diff --git a/docs/releasenotes/1.20.0.rst b/docs/releasenotes/1.20.0.rst new file mode 100644 index 000000000..bb0a29ab4 --- /dev/null +++ b/docs/releasenotes/1.20.0.rst @@ -0,0 +1,37 @@ +AusweisApp2 1.20.0 +^^^^^^^^^^^^^^^^^^ + +**Releasedatum:** 15. Januar 2020 + + + +Anwender +"""""""" + - Einführung der neuen grafischen Oberfläche für + Windows und macOS. + + - Das DMG für macOS ist nun notarisiert. + + - Unterstützung von Bildschirmlesern unter Android + und iOS. + + - Anpassungen der Farbkontraste zur besseren Lesbarkeit. + + - Optimierung des Menüs und Einführung eines + Einstellungsbereichs unter iOS und Android. + + - Optimierung der "Smartphone als Kartenleser"-Kopplung. + + - Unterstützung von OS X 10.11 wurde eingestellt. + + - Unterstützung von der x86-Architektur unter Android + wurde eingestellt. + + - Kleinere Fehlerbehebungen. + + +Entwickler +"""""""""" + - Aktualisierung von OpenSSL auf die Version 1.1.1d. + + - Aktualisierung von Qt auf die Version 5.12.5. diff --git a/docs/releasenotes/announce.rst b/docs/releasenotes/announce.rst index 6c7be6424..038eafa5e 100644 --- a/docs/releasenotes/announce.rst +++ b/docs/releasenotes/announce.rst @@ -1,39 +1,15 @@ Abkündigungen ============= -Mit der Version 1.20.0 der AusweisApp2 wird die Unterstützung -folgender Systeme eingestellt. - - - OS X 10.11 - - x86-Architektur unter Android - - -Mit der Version 1.16.0 der AusweisApp2 wurde die Unterstützung -folgender Systeme eingestellt. - - - OS X 10.10 - - Android 4.3 - - Android 4.4 - +Mit der Version 1.22.0 der AusweisApp2 wird die Unterstützung +folgender Funktionen eingestellt. -Mit der Version 1.16.0 der AusweisApp2 wurde die Unterstützung -folgender TLS-Cipher eingestellt. + - Vorherige grafische Oberfläche + - Bluetooth (Reiner SCT cyberJack Wave) - - DHE-DSS-AES256-GCM-SHA384 - - DHE-DSS-AES256-SHA256 - - DHE-DSS-AES128-GCM-SHA256 - - DHE-DSS-AES128-SHA256 - - DHE-DSS-AES256-SHA - - DHE-DSS-AES128-SHA - - ECDHE-ECDSA-AES256-SHA - - ECDHE-RSA-AES256-SHA - - DHE-RSA-AES256-SHA - - ECDHE-ECDSA-AES128-SHA - - ECDHE-RSA-AES128-SHA - - DHE-RSA-AES128-SHA - -Mit der Version 1.14.0 der AusweisApp2 wurde die Unterstützung +Mit der Version 1.20.0 der AusweisApp2 wurde die Unterstützung folgender Systeme eingestellt. - - OS X 10.9 + - OS X 10.11 + - x86-Architektur unter Android diff --git a/docs/releasenotes/appcast.rst b/docs/releasenotes/appcast.rst index e655b2be7..0156900b7 100644 --- a/docs/releasenotes/appcast.rst +++ b/docs/releasenotes/appcast.rst @@ -4,6 +4,6 @@ Release Notes .. toctree:: :maxdepth: 1 - 1.18.0 + 1.20.0 announce issues diff --git a/docs/releasenotes/conf.py.in b/docs/releasenotes/conf.py.in index 10c2a0e72..0d5c40ffd 100644 --- a/docs/releasenotes/conf.py.in +++ b/docs/releasenotes/conf.py.in @@ -42,7 +42,7 @@ master_doc = 'index' # General information about the project. project = 'AusweisApp2' -copyright = '2016-2019, Governikus GmbH & Co. KG' +copyright = '2016-2020, Governikus GmbH & Co. KG' author = 'Governikus GmbH & Co. KG' # The version info for the project you're documenting, acts as replacement for diff --git a/docs/releasenotes/general.rst b/docs/releasenotes/general.rst index 8d9c533ac..463b5b1a3 100644 --- a/docs/releasenotes/general.rst +++ b/docs/releasenotes/general.rst @@ -6,7 +6,7 @@ Ihrem Personalausweis bzw. Ihrem elektronischen Aufenthaltstitel online auszuwei Für die Nutzung der Online-Ausweisfunktion benötigen die Nutzerinnen und Nutzer eine Software, mit deren Hilfe eine sichere Verbindung zwischen Kartenleser oder Smartphone, -Personalausweis und eID-Diensteanbieter hergestellt werden kann. Sie ermöglicht den +Personalausweis und eID-Anbieter hergestellt werden kann. Sie ermöglicht den verschlüsselten Datenaustausch zwischen Personalausweis und eID-Dienst. Die im Auftrag des Bundesinnenministeriums von der Governikus KG entwickelte diff --git a/docs/releasenotes/issues.rst b/docs/releasenotes/issues.rst index 06c7e1898..b7d5e1d3b 100644 --- a/docs/releasenotes/issues.rst +++ b/docs/releasenotes/issues.rst @@ -11,22 +11,17 @@ Bekannte Fehler Die nachfolgende Liste bezieht sich auf die aktuelle Version der AusweisApp2. - - Mit der NFC-Schnittstelle des iPhone 7 und iPhone 7 Plus werden viele - Ausweise nicht erkannt (hauptsächlich NFC-A) und es kommt zu Abbrüchen der - Authentisierung. + - Mit der NFC-Schnittstelle des iPhone 7 (Plus) unter iOS 13.0 und 13.1 werden + viele Ausweise nicht erkannt (hauptsächlich NFC-A) und es kommt zu + Abbrüchen der Authentisierung. Aktualisieren Sie auf iOS 13.2 oder höher. - Auf Windows 10 Plattformen mit aktivierter Benutzerkontensteuerung kann es bei Benutzern mit eingeschränkten Berechtigungen zu Problemen mit der Online-Ausweisfunktion kommen. - - Bei Erhöhung der Schriftgröße über 175% kommt es zur Nutzungseinschränkung. - - Derzeit kommt es noch zu leichten Schwierigkeiten bei der Bedienbarkeit mit der Tastatur. - - Bei aktivierter Kontrasteinstellung ist unter Windows u. U. - die Darstellung der Farben nicht optimal. - - Bei Verwendung des Screenreaders JAWS unter Windows, kann es zu leichten Irritationen bei der angegebenen Bedienung kommen. @@ -35,7 +30,7 @@ Die nachfolgende Liste bezieht sich auf die aktuelle Version der AusweisApp2. unter Windows und macOS zu einem Absturz kommen. - Unter Umständen kommt es zu Stabilitätsproblemen der NFC-Schnittstelle - auf Android. + auf Android und iOS. - Längere Texte können unter Android u.U. bei kleinen Bildschirmgrößen abgeschnitten sein. @@ -57,3 +52,17 @@ Die nachfolgende Liste bezieht sich auf die aktuelle Version der AusweisApp2. das Verhalten von macOS geändert werden, sodass auch alle anderen Komponenten in der App fokussiert werden können. + - Bei einigen Links werden die Steuerzeichen vom Bildschirmleser vorgelesen. + + - Wird der Screenreader aktiviert, während die AusweisApp2 bereits läuft, + kann es zu Fehlverhalten kommen. + + - Die Online-Hilfe für die neue grafische Oberfläche ist noch nicht verfügbar. + + +Die nachfolgende Liste bezieht sich auf die alte grafische Oberfläche. + + - Bei Erhöhung der Schriftgröße über 175% kommt es zur Nutzungseinschränkung. + + - Bei aktivierter Kontrasteinstellung ist unter Windows u. U. + die Darstellung der Farben nicht optimal. diff --git a/docs/releasenotes/singlehtml.conf.py.in b/docs/releasenotes/singlehtml.conf.py.in index 6ffbbe412..613965989 100644 --- a/docs/releasenotes/singlehtml.conf.py.in +++ b/docs/releasenotes/singlehtml.conf.py.in @@ -42,7 +42,7 @@ master_doc = 'appcast' # General information about the project. project = 'AusweisApp2' -copyright = '2016-2019, Governikus GmbH & Co. KG' +copyright = '2016-2020, Governikus GmbH & Co. KG' author = 'Governikus GmbH & Co. KG' # The version info for the project you're documenting, acts as replacement for diff --git a/docs/releasenotes/support.rst b/docs/releasenotes/support.rst index ce5296d6e..caa735bca 100644 --- a/docs/releasenotes/support.rst +++ b/docs/releasenotes/support.rst @@ -14,6 +14,8 @@ Betriebssysteme - macOS 10.14 + - macOS 10.15 + - Windows 7 SP1 (32bit / 64bit) - Windows 8.1 (64bit) @@ -22,6 +24,7 @@ Betriebssysteme - Android 5.0 und höher (x86, armeabi-v7a) + - iOS 13 und höher Karten @@ -46,15 +49,15 @@ und sollte daher mit allen marktüblichen Browsern verwendet werden können. Im Rahmen der Qualitätssicherung werden die folgenden Browserversionen getestet. - - Firefox 66 + - Firefox 70 - - Chrome 74 + - Chrome 78 - Internet Explorer 11 - - Safari 12 + - Safari 13 - - Edge 44 + - Edge 44.5 @@ -109,12 +112,12 @@ der unabhängig vom verwendeten Browser ist. Durch die strikte Einhaltung der Vorgaben aus den entsprechenden Technischen Richtlinie des BSI (BSI TR-03124) ist die AusweisApp2 generell browserunabhängig. Im mobilen Umfeld ist die Funktionalität jedoch abhängig von der vom -Diensteanbieter umgesetzten Aktivierung. Daher empfehlen wir einen der +Anbieter umgesetzten Aktivierung. Daher empfehlen wir einen der folgenden Browser zu verwenden. - Firefox Klar 8 - - Chrome 73 + - Chrome 78 - Android System WebView 73 diff --git a/docs/releasenotes/versions.rst b/docs/releasenotes/versions.rst index 86a478ad3..d18ca6e78 100644 --- a/docs/releasenotes/versions.rst +++ b/docs/releasenotes/versions.rst @@ -1,6 +1,14 @@ Versionen ========= +Versionszweig 1.20 +------------------ +.. toctree:: + :maxdepth: 1 + + 1.20.0 + + Versionszweig 1.18 ------------------ .. toctree:: diff --git a/docs/sdk/conf.py.in b/docs/sdk/conf.py.in index 2b8291d45..dea02b40c 100644 --- a/docs/sdk/conf.py.in +++ b/docs/sdk/conf.py.in @@ -42,7 +42,7 @@ master_doc = 'index' # General information about the project. project = 'AusweisApp2 SDK' -copyright = '2016-2019, Governikus GmbH & Co. KG' +copyright = '2016-2020, Governikus GmbH & Co. KG' author = 'Governikus GmbH & Co. KG' # The version info for the project you're documenting, acts as replacement for diff --git a/docs/sdk/messages.rst b/docs/sdk/messages.rst index 3c37806a5..c6ca0a00b 100644 --- a/docs/sdk/messages.rst +++ b/docs/sdk/messages.rst @@ -30,7 +30,7 @@ the whole workflow. - **error**: This optional parameter indicates an error of a :ref:`set_access_rights` call if the command contained invalid data. - - **aux**: Optional auxiliary data of the service provider. + - **aux**: Optional auxiliary data of the provider. - **ageVerificationDate**: Optional required date of birth for AgeVerification as ISO 8601. @@ -41,7 +41,7 @@ the whole workflow. - **communityId**: Optional id of community. - - **chat**: Access rights of the service provider. + - **chat**: Access rights of the provider. - **effective**: Indicates the enabled access rights of **optional** and **required**. @@ -86,6 +86,17 @@ the whole workflow. } +Values +"""""" +.. versionadded:: 1.20.0 + The following write access rights are possible now: + + - WriteAddress + - WriteCommunityID + - WriteResidencePermitI + - WriteResidencePermitII + + The following access rights are possible: - Address @@ -106,6 +117,10 @@ The following access rights are possible: - CommunityID - AddressVerification - AgeVerification + - WriteAddress + - WriteCommunityID + - WriteResidencePermitI + - WriteResidencePermitII .. seealso:: @@ -463,8 +478,8 @@ again but without an error parameter. If AusweisApp2 sends :ref:`enter_puk` with field "inoperative" of embedded :ref:`reader` message set true it is not possible to unblock the PIN. You will have to show a message to the user that the card is inoperative -and the user should contact the authority responsible for issueing the -identification document to unblock the PIN. +and the user should contact the authority responsible for issuing the +identification card to unblock the PIN. You need to send a :ref:`cancel` to abort the workflow if card is operative. Please see the note for more information. diff --git a/docs/sdk/workflow.rst b/docs/sdk/workflow.rst index 1fc4bb0c8..00207c8f1 100644 --- a/docs/sdk/workflow.rst +++ b/docs/sdk/workflow.rst @@ -104,7 +104,7 @@ We assume that the user did not connect the card reader. {"cmd": "CANCEL"} - {"msg": "AUTH", "result": {"description":"The process was cancelled by the user.","language":"en","major":"http://www.bsi.bund.de/ecard/api/1.1/resultmajor#error","message":"The process was cancelled by the user.","minor":"http://www.bsi.bund.de/ecard/api/1.1/resultminor/sal#cancellationByUser"},"url":"https://test.governikus-eid.de/DEMO/?errID=123456"} + {"msg": "AUTH", "result": {"description":"The process has been cancelled.","language":"en","major":"http://www.bsi.bund.de/ecard/api/1.1/resultmajor#error","message":"The process has been cancelled.","minor":"http://www.bsi.bund.de/ecard/api/1.1/resultminor/sal#cancellationByUser"},"url":"https://test.governikus-eid.de/DEMO/?errID=123456"} @@ -134,5 +134,5 @@ We assume that the user did not connect the card reader. {"cmd": "CANCEL"} - {"msg": "AUTH", "result": {"description":"The process was cancelled by the user.","language":"en","major":"http://www.bsi.bund.de/ecard/api/1.1/resultmajor#error","message":"The process was cancelled by the user.","minor":"http://www.bsi.bund.de/ecard/api/1.1/resultminor/sal#cancellationByUser"},"url":"https://test.governikus-eid.de/DEMO/?errID=123456"} + {"msg": "AUTH", "result": {"description":"The process has been cancelled.","language":"en","major":"http://www.bsi.bund.de/ecard/api/1.1/resultmajor#error","message":"The process has been cancelled.","minor":"http://www.bsi.bund.de/ecard/api/1.1/resultminor/sal#cancellationByUser"},"url":"https://test.governikus-eid.de/DEMO/?errID=123456"} diff --git a/libs/CMakeLists.txt b/libs/CMakeLists.txt index e0428ff63..d944eced5 100644 --- a/libs/CMakeLists.txt +++ b/libs/CMakeLists.txt @@ -70,9 +70,6 @@ ELSE() ENDIF() FIND_HOST_PACKAGE(PythonInterp 2.7 REQUIRED) -IF(NOT "${PYTHON_VERSION_MAJOR}" STREQUAL "2") - MESSAGE(FATAL_ERROR "Cannot find 'python v2' command") -ENDIF() FIND_PROGRAM(PATCH_CMD patch CMAKE_FIND_ROOT_PATH_BOTH) IF(PATCH_CMD) @@ -102,11 +99,11 @@ INCLUDE(Messages) ################################## Versions -SET(QT 5.12.4) -SET(QT_HASH 85da5e0ee498759990180d5b8192efaa6060a313c5018b772f57d446bdd425e1) +SET(QT 5.12.5) +SET(QT_HASH a2299e21db7767caf98242767bffb18a2a88a42fee2d6a393bedd234f8c91298) -SET(OPENSSL 1.1.1c) -SET(OPENSSL_HASH f6fb3079ad15076154eda9413fed42877d668e7069d9b87396d0804fdb3f4c90) +SET(OPENSSL 1.1.1d) +SET(OPENSSL_HASH 1e3a91bc1f9dfce01af26026f856e064eab4c8ee0a8f457b5ae30b40b8b711f2) ################################## Files SET(QT_FILE qt-everywhere-src-${QT}.tar.xz) @@ -203,6 +200,7 @@ ExternalProject_Add(openssl DOWNLOAD_DIR ${PACKAGES_DIR} PATCH_COMMAND ${PATCH_CMD}/openssl-android-shlib_variant.patch && + ${PATCH_CMD}/openssl-Fix-an-overflow-bug-in-rsaz_512_sqr.patch && ${PATCH_CMD}/openssl-Adjust-iOS-target.patch CONFIGURE_COMMAND ${OPENSSL_ENV} ${PERL_EXECUTABLE} Configure --prefix=${DESTINATION_DIR} ${OPENSSL_CONFIGURE_FLAGS} "${OPENSSL_COMPILER_FLAGS}" BUILD_COMMAND ${OPENSSL_ENV} ${MAKE} ${MAKE_JOBS} @@ -238,7 +236,12 @@ ENDIF() LIST(APPEND ENABLED_TARGETS qt) IF(${CMAKE_BUILD_TYPE} STREQUAL "DEBUG") - SET(QT_CONFIGURE_FLAGS -debug -qml-debug) + IF(MAC) + SET(QT_CONFIGURE_FLAGS -debug-and-release) # debug-only framework builds are not supported on macOS + ELSE() + SET(QT_CONFIGURE_FLAGS -debug) + ENDIF() + SET(QT_CONFIGURE_FLAGS ${QT_CONFIGURE_FLAGS} -qml-debug) SET(QT_PATCH_COMMAND ${PATCH_CMD}/qt-Enable-debug-output-for-OpenSSL.patch &&) ELSE() SET(QT_CONFIGURE_FLAGS -release -optimize-size -no-qml-debug) @@ -357,11 +360,10 @@ ExternalProject_Add(qt ${PATCH_CMD}/qt-disable-designer.patch && ${PATCH_CMD}/qt-Disable-qmltime-for-shared-build.patch && ${PATCH_CMD}/qt-Add-Q_CORE_EXPORT-to-lcEventDispatcher.patch && - ${PATCH_CMD}/qt-Fix-build-with-no-feature-printer.patch && - ${PATCH_CMD}/qt-Fix-build-with-no-feature-printer-on-macOS.patch && - ${PATCH_CMD}/qt-Core-IO-Bluetooth-fix-ambiguous-conversions.patch && - ${PATCH_CMD}/qt-Core-IO-Bluetooth-fix-ambiguous-conversions-for-macO.patch && ${PATCH_CMD}/qt-Adjust-iOS-target.patch && + ${PATCH_CMD}/qt-Filesystem-avoid-crashes-on-exit-in-case-the-locale-.patch && + ${PATCH_CMD}/qt-Revert-Android-Stick-with-buildToolsVersion-28.0.3.patch && + ${PATCH_CMD}/qt-Remove-dead-code-to-fix-a-lint-warning.patch && ${CMAKE_COMMAND} -E touch qtbase/.gitignore CONFIGURE_COMMAND ${QT_ENV} ${QT_CONFIGURE} ${QT_CONFIGURE_FLAGS} ${QT_CONFIGURE_FLAGS_SKIP_MODULES} BUILD_COMMAND ${MAKE} ${MAKE_JOBS} @@ -414,7 +416,7 @@ IF(WIN32) ENDIF() ENDIF() -IF(CMAKE_VERSION VERSION_LESS "3.15") +IF(CMAKE_VERSION VERSION_LESS "3.15" OR BSD) SET(COMPRESSION cfJ) SET(COMPRESSION_FILENDING tar.xz) ELSE() diff --git a/libs/patches/openssl-Fix-an-overflow-bug-in-rsaz_512_sqr.patch b/libs/patches/openssl-Fix-an-overflow-bug-in-rsaz_512_sqr.patch new file mode 100644 index 000000000..434771480 --- /dev/null +++ b/libs/patches/openssl-Fix-an-overflow-bug-in-rsaz_512_sqr.patch @@ -0,0 +1,757 @@ +From 419102400a2811582a7a3d4a4e317d72e5ce0a8f Mon Sep 17 00:00:00 2001 +From: Andy Polyakov +Date: Wed, 4 Dec 2019 12:48:21 +0100 +Subject: [PATCH] Fix an overflow bug in rsaz_512_sqr + +There is an overflow bug in the x64_64 Montgomery squaring procedure used in +exponentiation with 512-bit moduli. No EC algorithms are affected. Analysis +suggests that attacks against 2-prime RSA1024, 3-prime RSA1536, and DSA1024 as a +result of this defect would be very difficult to perform and are not believed +likely. Attacks against DH512 are considered just feasible. However, for an +attack the target would have to re-use the DH512 private key, which is not +recommended anyway. Also applications directly using the low level API +BN_mod_exp may be affected if they use BN_FLG_CONSTTIME. + +CVE-2019-1551 + +Reviewed-by: Paul Dale +Reviewed-by: Bernd Edlinger +(Merged from https://github.com/openssl/openssl/pull/10575) +--- + crypto/bn/asm/rsaz-x86_64.pl | 381 ++++++++++++++++++----------------- + 1 file changed, 197 insertions(+), 184 deletions(-) + +diff --git x/crypto/bn/asm/rsaz-x86_64.pl y/crypto/bn/asm/rsaz-x86_64.pl +index b1797b649f..7534d5cd03 100755 +--- x/crypto/bn/asm/rsaz-x86_64.pl ++++ y/crypto/bn/asm/rsaz-x86_64.pl +@@ -116,7 +116,7 @@ rsaz_512_sqr: # 25-29% faster than rsaz_512_mul + subq \$128+24, %rsp + .cfi_adjust_cfa_offset 128+24 + .Lsqr_body: +- movq $mod, %rbp # common argument ++ movq $mod, %xmm1 # common off-load + movq ($inp), %rdx + movq 8($inp), %rax + movq $n0, 128(%rsp) +@@ -134,7 +134,8 @@ $code.=<<___; + .Loop_sqr: + movl $times,128+8(%rsp) + #first iteration +- movq %rdx, %rbx ++ movq %rdx, %rbx # 0($inp) ++ mov %rax, %rbp # 8($inp) + mulq %rdx + movq %rax, %r8 + movq 16($inp), %rax +@@ -173,31 +174,29 @@ $code.=<<___; + mulq %rbx + addq %rax, %r14 + movq %rbx, %rax +- movq %rdx, %r15 +- adcq \$0, %r15 ++ adcq \$0, %rdx + +- addq %r8, %r8 #shlq \$1, %r8 +- movq %r9, %rcx +- adcq %r9, %r9 #shld \$1, %r8, %r9 ++ xorq %rcx,%rcx # rcx:r8 = r8 << 1 ++ addq %r8, %r8 ++ movq %rdx, %r15 ++ adcq \$0, %rcx + + mulq %rax +- movq %rax, (%rsp) +- addq %rdx, %r8 +- adcq \$0, %r9 ++ addq %r8, %rdx ++ adcq \$0, %rcx + +- movq %r8, 8(%rsp) +- shrq \$63, %rcx ++ movq %rax, (%rsp) ++ movq %rdx, 8(%rsp) + + #second iteration +- movq 8($inp), %r8 + movq 16($inp), %rax +- mulq %r8 ++ mulq %rbp + addq %rax, %r10 + movq 24($inp), %rax + movq %rdx, %rbx + adcq \$0, %rbx + +- mulq %r8 ++ mulq %rbp + addq %rax, %r11 + movq 32($inp), %rax + adcq \$0, %rdx +@@ -205,7 +204,7 @@ $code.=<<___; + movq %rdx, %rbx + adcq \$0, %rbx + +- mulq %r8 ++ mulq %rbp + addq %rax, %r12 + movq 40($inp), %rax + adcq \$0, %rdx +@@ -213,7 +212,7 @@ $code.=<<___; + movq %rdx, %rbx + adcq \$0, %rbx + +- mulq %r8 ++ mulq %rbp + addq %rax, %r13 + movq 48($inp), %rax + adcq \$0, %rdx +@@ -221,7 +220,7 @@ $code.=<<___; + movq %rdx, %rbx + adcq \$0, %rbx + +- mulq %r8 ++ mulq %rbp + addq %rax, %r14 + movq 56($inp), %rax + adcq \$0, %rdx +@@ -229,39 +228,39 @@ $code.=<<___; + movq %rdx, %rbx + adcq \$0, %rbx + +- mulq %r8 ++ mulq %rbp + addq %rax, %r15 +- movq %r8, %rax ++ movq %rbp, %rax + adcq \$0, %rdx + addq %rbx, %r15 +- movq %rdx, %r8 +- movq %r10, %rdx +- adcq \$0, %r8 ++ adcq \$0, %rdx + +- add %rdx, %rdx +- lea (%rcx,%r10,2), %r10 #shld \$1, %rcx, %r10 +- movq %r11, %rbx +- adcq %r11, %r11 #shld \$1, %r10, %r11 ++ xorq %rbx, %rbx # rbx:r10:r9 = r10:r9 << 1 ++ addq %r9, %r9 ++ movq %rdx, %r8 ++ adcq %r10, %r10 ++ adcq \$0, %rbx + + mulq %rax ++ addq %rcx, %rax ++ movq 16($inp), %rbp ++ adcq \$0, %rdx + addq %rax, %r9 ++ movq 24($inp), %rax + adcq %rdx, %r10 +- adcq \$0, %r11 ++ adcq \$0, %rbx + + movq %r9, 16(%rsp) + movq %r10, 24(%rsp) +- shrq \$63, %rbx + + #third iteration +- movq 16($inp), %r9 +- movq 24($inp), %rax +- mulq %r9 ++ mulq %rbp + addq %rax, %r12 + movq 32($inp), %rax + movq %rdx, %rcx + adcq \$0, %rcx + +- mulq %r9 ++ mulq %rbp + addq %rax, %r13 + movq 40($inp), %rax + adcq \$0, %rdx +@@ -269,7 +268,7 @@ $code.=<<___; + movq %rdx, %rcx + adcq \$0, %rcx + +- mulq %r9 ++ mulq %rbp + addq %rax, %r14 + movq 48($inp), %rax + adcq \$0, %rdx +@@ -277,9 +276,7 @@ $code.=<<___; + movq %rdx, %rcx + adcq \$0, %rcx + +- mulq %r9 +- movq %r12, %r10 +- lea (%rbx,%r12,2), %r12 #shld \$1, %rbx, %r12 ++ mulq %rbp + addq %rax, %r15 + movq 56($inp), %rax + adcq \$0, %rdx +@@ -287,36 +284,40 @@ $code.=<<___; + movq %rdx, %rcx + adcq \$0, %rcx + +- mulq %r9 +- shrq \$63, %r10 ++ mulq %rbp + addq %rax, %r8 +- movq %r9, %rax ++ movq %rbp, %rax + adcq \$0, %rdx + addq %rcx, %r8 +- movq %rdx, %r9 +- adcq \$0, %r9 ++ adcq \$0, %rdx + +- movq %r13, %rcx +- leaq (%r10,%r13,2), %r13 #shld \$1, %r12, %r13 ++ xorq %rcx, %rcx # rcx:r12:r11 = r12:r11 << 1 ++ addq %r11, %r11 ++ movq %rdx, %r9 ++ adcq %r12, %r12 ++ adcq \$0, %rcx + + mulq %rax ++ addq %rbx, %rax ++ movq 24($inp), %r10 ++ adcq \$0, %rdx + addq %rax, %r11 ++ movq 32($inp), %rax + adcq %rdx, %r12 +- adcq \$0, %r13 ++ adcq \$0, %rcx + + movq %r11, 32(%rsp) + movq %r12, 40(%rsp) +- shrq \$63, %rcx + + #fourth iteration +- movq 24($inp), %r10 +- movq 32($inp), %rax ++ mov %rax, %r11 # 32($inp) + mulq %r10 + addq %rax, %r14 + movq 40($inp), %rax + movq %rdx, %rbx + adcq \$0, %rbx + ++ mov %rax, %r12 # 40($inp) + mulq %r10 + addq %rax, %r15 + movq 48($inp), %rax +@@ -325,9 +326,8 @@ $code.=<<___; + movq %rdx, %rbx + adcq \$0, %rbx + ++ mov %rax, %rbp # 48($inp) + mulq %r10 +- movq %r14, %r12 +- leaq (%rcx,%r14,2), %r14 #shld \$1, %rcx, %r14 + addq %rax, %r8 + movq 56($inp), %rax + adcq \$0, %rdx +@@ -336,32 +336,33 @@ $code.=<<___; + adcq \$0, %rbx + + mulq %r10 +- shrq \$63, %r12 + addq %rax, %r9 + movq %r10, %rax + adcq \$0, %rdx + addq %rbx, %r9 +- movq %rdx, %r10 +- adcq \$0, %r10 ++ adcq \$0, %rdx + +- movq %r15, %rbx +- leaq (%r12,%r15,2),%r15 #shld \$1, %r14, %r15 ++ xorq %rbx, %rbx # rbx:r13:r14 = r13:r14 << 1 ++ addq %r13, %r13 ++ movq %rdx, %r10 ++ adcq %r14, %r14 ++ adcq \$0, %rbx + + mulq %rax ++ addq %rcx, %rax ++ adcq \$0, %rdx + addq %rax, %r13 ++ movq %r12, %rax # 40($inp) + adcq %rdx, %r14 +- adcq \$0, %r15 ++ adcq \$0, %rbx + + movq %r13, 48(%rsp) + movq %r14, 56(%rsp) +- shrq \$63, %rbx + + #fifth iteration +- movq 32($inp), %r11 +- movq 40($inp), %rax + mulq %r11 + addq %rax, %r8 +- movq 48($inp), %rax ++ movq %rbp, %rax # 48($inp) + movq %rdx, %rcx + adcq \$0, %rcx + +@@ -369,97 +370,99 @@ $code.=<<___; + addq %rax, %r9 + movq 56($inp), %rax + adcq \$0, %rdx +- movq %r8, %r12 +- leaq (%rbx,%r8,2), %r8 #shld \$1, %rbx, %r8 + addq %rcx, %r9 + movq %rdx, %rcx + adcq \$0, %rcx + ++ mov %rax, %r14 # 56($inp) + mulq %r11 +- shrq \$63, %r12 + addq %rax, %r10 + movq %r11, %rax + adcq \$0, %rdx + addq %rcx, %r10 +- movq %rdx, %r11 +- adcq \$0, %r11 ++ adcq \$0, %rdx + +- movq %r9, %rcx +- leaq (%r12,%r9,2), %r9 #shld \$1, %r8, %r9 ++ xorq %rcx, %rcx # rcx:r8:r15 = r8:r15 << 1 ++ addq %r15, %r15 ++ movq %rdx, %r11 ++ adcq %r8, %r8 ++ adcq \$0, %rcx + + mulq %rax ++ addq %rbx, %rax ++ adcq \$0, %rdx + addq %rax, %r15 ++ movq %rbp, %rax # 48($inp) + adcq %rdx, %r8 +- adcq \$0, %r9 ++ adcq \$0, %rcx + + movq %r15, 64(%rsp) + movq %r8, 72(%rsp) +- shrq \$63, %rcx + + #sixth iteration +- movq 40($inp), %r12 +- movq 48($inp), %rax + mulq %r12 + addq %rax, %r10 +- movq 56($inp), %rax ++ movq %r14, %rax # 56($inp) + movq %rdx, %rbx + adcq \$0, %rbx + + mulq %r12 + addq %rax, %r11 + movq %r12, %rax +- movq %r10, %r15 +- leaq (%rcx,%r10,2), %r10 #shld \$1, %rcx, %r10 + adcq \$0, %rdx +- shrq \$63, %r15 + addq %rbx, %r11 +- movq %rdx, %r12 +- adcq \$0, %r12 ++ adcq \$0, %rdx + +- movq %r11, %rbx +- leaq (%r15,%r11,2), %r11 #shld \$1, %r10, %r11 ++ xorq %rbx, %rbx # rbx:r10:r9 = r10:r9 << 1 ++ addq %r9, %r9 ++ movq %rdx, %r12 ++ adcq %r10, %r10 ++ adcq \$0, %rbx + + mulq %rax ++ addq %rcx, %rax ++ adcq \$0, %rdx + addq %rax, %r9 ++ movq %r14, %rax # 56($inp) + adcq %rdx, %r10 +- adcq \$0, %r11 ++ adcq \$0, %rbx + + movq %r9, 80(%rsp) + movq %r10, 88(%rsp) + + #seventh iteration +- movq 48($inp), %r13 +- movq 56($inp), %rax +- mulq %r13 ++ mulq %rbp + addq %rax, %r12 +- movq %r13, %rax +- movq %rdx, %r13 +- adcq \$0, %r13 ++ movq %rbp, %rax ++ adcq \$0, %rdx + +- xorq %r14, %r14 +- shlq \$1, %rbx +- adcq %r12, %r12 #shld \$1, %rbx, %r12 +- adcq %r13, %r13 #shld \$1, %r12, %r13 +- adcq %r14, %r14 #shld \$1, %r13, %r14 ++ xorq %rcx, %rcx # rcx:r12:r11 = r12:r11 << 1 ++ addq %r11, %r11 ++ movq %rdx, %r13 ++ adcq %r12, %r12 ++ adcq \$0, %rcx + + mulq %rax ++ addq %rbx, %rax ++ adcq \$0, %rdx + addq %rax, %r11 ++ movq %r14, %rax # 56($inp) + adcq %rdx, %r12 +- adcq \$0, %r13 ++ adcq \$0, %rcx + + movq %r11, 96(%rsp) + movq %r12, 104(%rsp) + + #eighth iteration +- movq 56($inp), %rax ++ xorq %rbx, %rbx # rbx:r13 = r13 << 1 ++ addq %r13, %r13 ++ adcq \$0, %rbx ++ + mulq %rax +- addq %rax, %r13 ++ addq %rcx, %rax + adcq \$0, %rdx +- +- addq %rdx, %r14 +- +- movq %r13, 112(%rsp) +- movq %r14, 120(%rsp) ++ addq %r13, %rax ++ adcq %rbx, %rdx + + movq (%rsp), %r8 + movq 8(%rsp), %r9 +@@ -469,6 +472,10 @@ $code.=<<___; + movq 40(%rsp), %r13 + movq 48(%rsp), %r14 + movq 56(%rsp), %r15 ++ movq %xmm1, %rbp ++ ++ movq %rax, 112(%rsp) ++ movq %rdx, 120(%rsp) + + call __rsaz_512_reduce + +@@ -500,9 +507,9 @@ $code.=<<___; + .Loop_sqrx: + movl $times,128+8(%rsp) + movq $out, %xmm0 # off-load +- movq %rbp, %xmm1 # off-load + #first iteration + mulx %rax, %r8, %r9 ++ mov %rax, %rbx + + mulx 16($inp), %rcx, %r10 + xor %rbp, %rbp # cf=0, of=0 +@@ -510,40 +517,39 @@ $code.=<<___; + mulx 24($inp), %rax, %r11 + adcx %rcx, %r9 + +- mulx 32($inp), %rcx, %r12 ++ .byte 0xc4,0x62,0xf3,0xf6,0xa6,0x20,0x00,0x00,0x00 # mulx 32($inp), %rcx, %r12 + adcx %rax, %r10 + +- mulx 40($inp), %rax, %r13 ++ .byte 0xc4,0x62,0xfb,0xf6,0xae,0x28,0x00,0x00,0x00 # mulx 40($inp), %rax, %r13 + adcx %rcx, %r11 + +- .byte 0xc4,0x62,0xf3,0xf6,0xb6,0x30,0x00,0x00,0x00 # mulx 48($inp), %rcx, %r14 ++ mulx 48($inp), %rcx, %r14 + adcx %rax, %r12 + adcx %rcx, %r13 + +- .byte 0xc4,0x62,0xfb,0xf6,0xbe,0x38,0x00,0x00,0x00 # mulx 56($inp), %rax, %r15 ++ mulx 56($inp), %rax, %r15 + adcx %rax, %r14 + adcx %rbp, %r15 # %rbp is 0 + +- mov %r9, %rcx +- shld \$1, %r8, %r9 +- shl \$1, %r8 +- +- xor %ebp, %ebp +- mulx %rdx, %rax, %rdx +- adcx %rdx, %r8 +- mov 8($inp), %rdx +- adcx %rbp, %r9 ++ mulx %rdx, %rax, $out ++ mov %rbx, %rdx # 8($inp) ++ xor %rcx, %rcx ++ adox %r8, %r8 ++ adcx $out, %r8 ++ adox %rbp, %rcx ++ adcx %rbp, %rcx + + mov %rax, (%rsp) + mov %r8, 8(%rsp) + + #second iteration +- mulx 16($inp), %rax, %rbx ++ .byte 0xc4,0xe2,0xfb,0xf6,0x9e,0x10,0x00,0x00,0x00 # mulx 16($inp), %rax, %rbx + adox %rax, %r10 + adcx %rbx, %r11 + +- .byte 0xc4,0x62,0xc3,0xf6,0x86,0x18,0x00,0x00,0x00 # mulx 24($inp), $out, %r8 ++ mulx 24($inp), $out, %r8 + adox $out, %r11 ++ .byte 0x66 + adcx %r8, %r12 + + mulx 32($inp), %rax, %rbx +@@ -561,24 +567,25 @@ $code.=<<___; + .byte 0xc4,0x62,0xc3,0xf6,0x86,0x38,0x00,0x00,0x00 # mulx 56($inp), $out, %r8 + adox $out, %r15 + adcx %rbp, %r8 ++ mulx %rdx, %rax, $out + adox %rbp, %r8 ++ .byte 0x48,0x8b,0x96,0x10,0x00,0x00,0x00 # mov 16($inp), %rdx + +- mov %r11, %rbx +- shld \$1, %r10, %r11 +- shld \$1, %rcx, %r10 +- +- xor %ebp,%ebp +- mulx %rdx, %rax, %rcx +- mov 16($inp), %rdx ++ xor %rbx, %rbx ++ adcx %rcx, %rax ++ adox %r9, %r9 ++ adcx %rbp, $out ++ adox %r10, %r10 + adcx %rax, %r9 +- adcx %rcx, %r10 +- adcx %rbp, %r11 ++ adox %rbp, %rbx ++ adcx $out, %r10 ++ adcx %rbp, %rbx + + mov %r9, 16(%rsp) + .byte 0x4c,0x89,0x94,0x24,0x18,0x00,0x00,0x00 # mov %r10, 24(%rsp) + + #third iteration +- .byte 0xc4,0x62,0xc3,0xf6,0x8e,0x18,0x00,0x00,0x00 # mulx 24($inp), $out, %r9 ++ mulx 24($inp), $out, %r9 + adox $out, %r12 + adcx %r9, %r13 + +@@ -586,7 +593,7 @@ $code.=<<___; + adox %rax, %r13 + adcx %rcx, %r14 + +- mulx 40($inp), $out, %r9 ++ .byte 0xc4,0x62,0xc3,0xf6,0x8e,0x28,0x00,0x00,0x00 # mulx 40($inp), $out, %r9 + adox $out, %r14 + adcx %r9, %r15 + +@@ -594,27 +601,28 @@ $code.=<<___; + adox %rax, %r15 + adcx %rcx, %r8 + +- .byte 0xc4,0x62,0xc3,0xf6,0x8e,0x38,0x00,0x00,0x00 # mulx 56($inp), $out, %r9 ++ mulx 56($inp), $out, %r9 + adox $out, %r8 + adcx %rbp, %r9 ++ mulx %rdx, %rax, $out + adox %rbp, %r9 ++ mov 24($inp), %rdx + +- mov %r13, %rcx +- shld \$1, %r12, %r13 +- shld \$1, %rbx, %r12 +- +- xor %ebp, %ebp +- mulx %rdx, %rax, %rdx ++ xor %rcx, %rcx ++ adcx %rbx, %rax ++ adox %r11, %r11 ++ adcx %rbp, $out ++ adox %r12, %r12 + adcx %rax, %r11 +- adcx %rdx, %r12 +- mov 24($inp), %rdx +- adcx %rbp, %r13 ++ adox %rbp, %rcx ++ adcx $out, %r12 ++ adcx %rbp, %rcx + + mov %r11, 32(%rsp) +- .byte 0x4c,0x89,0xa4,0x24,0x28,0x00,0x00,0x00 # mov %r12, 40(%rsp) ++ mov %r12, 40(%rsp) + + #fourth iteration +- .byte 0xc4,0xe2,0xfb,0xf6,0x9e,0x20,0x00,0x00,0x00 # mulx 32($inp), %rax, %rbx ++ mulx 32($inp), %rax, %rbx + adox %rax, %r14 + adcx %rbx, %r15 + +@@ -629,25 +637,25 @@ $code.=<<___; + mulx 56($inp), $out, %r10 + adox $out, %r9 + adcx %rbp, %r10 ++ mulx %rdx, %rax, $out + adox %rbp, %r10 ++ mov 32($inp), %rdx + +- .byte 0x66 +- mov %r15, %rbx +- shld \$1, %r14, %r15 +- shld \$1, %rcx, %r14 +- +- xor %ebp, %ebp +- mulx %rdx, %rax, %rdx ++ xor %rbx, %rbx ++ adcx %rcx, %rax ++ adox %r13, %r13 ++ adcx %rbp, $out ++ adox %r14, %r14 + adcx %rax, %r13 +- adcx %rdx, %r14 +- mov 32($inp), %rdx +- adcx %rbp, %r15 ++ adox %rbp, %rbx ++ adcx $out, %r14 ++ adcx %rbp, %rbx + + mov %r13, 48(%rsp) + mov %r14, 56(%rsp) + + #fifth iteration +- .byte 0xc4,0x62,0xc3,0xf6,0x9e,0x28,0x00,0x00,0x00 # mulx 40($inp), $out, %r11 ++ mulx 40($inp), $out, %r11 + adox $out, %r8 + adcx %r11, %r9 + +@@ -658,18 +666,19 @@ $code.=<<___; + mulx 56($inp), $out, %r11 + adox $out, %r10 + adcx %rbp, %r11 ++ mulx %rdx, %rax, $out ++ mov 40($inp), %rdx + adox %rbp, %r11 + +- mov %r9, %rcx +- shld \$1, %r8, %r9 +- shld \$1, %rbx, %r8 +- +- xor %ebp, %ebp +- mulx %rdx, %rax, %rdx ++ xor %rcx, %rcx ++ adcx %rbx, %rax ++ adox %r15, %r15 ++ adcx %rbp, $out ++ adox %r8, %r8 + adcx %rax, %r15 +- adcx %rdx, %r8 +- mov 40($inp), %rdx +- adcx %rbp, %r9 ++ adox %rbp, %rcx ++ adcx $out, %r8 ++ adcx %rbp, %rcx + + mov %r15, 64(%rsp) + mov %r8, 72(%rsp) +@@ -682,18 +691,19 @@ $code.=<<___; + .byte 0xc4,0x62,0xc3,0xf6,0xa6,0x38,0x00,0x00,0x00 # mulx 56($inp), $out, %r12 + adox $out, %r11 + adcx %rbp, %r12 ++ mulx %rdx, %rax, $out + adox %rbp, %r12 ++ mov 48($inp), %rdx + +- mov %r11, %rbx +- shld \$1, %r10, %r11 +- shld \$1, %rcx, %r10 +- +- xor %ebp, %ebp +- mulx %rdx, %rax, %rdx ++ xor %rbx, %rbx ++ adcx %rcx, %rax ++ adox %r9, %r9 ++ adcx %rbp, $out ++ adox %r10, %r10 + adcx %rax, %r9 +- adcx %rdx, %r10 +- mov 48($inp), %rdx +- adcx %rbp, %r11 ++ adcx $out, %r10 ++ adox %rbp, %rbx ++ adcx %rbp, %rbx + + mov %r9, 80(%rsp) + mov %r10, 88(%rsp) +@@ -703,31 +713,31 @@ $code.=<<___; + adox %rax, %r12 + adox %rbp, %r13 + +- xor %r14, %r14 +- shld \$1, %r13, %r14 +- shld \$1, %r12, %r13 +- shld \$1, %rbx, %r12 +- +- xor %ebp, %ebp +- mulx %rdx, %rax, %rdx +- adcx %rax, %r11 +- adcx %rdx, %r12 ++ mulx %rdx, %rax, $out ++ xor %rcx, %rcx + mov 56($inp), %rdx +- adcx %rbp, %r13 ++ adcx %rbx, %rax ++ adox %r11, %r11 ++ adcx %rbp, $out ++ adox %r12, %r12 ++ adcx %rax, %r11 ++ adox %rbp, %rcx ++ adcx $out, %r12 ++ adcx %rbp, %rcx + + .byte 0x4c,0x89,0x9c,0x24,0x60,0x00,0x00,0x00 # mov %r11, 96(%rsp) + .byte 0x4c,0x89,0xa4,0x24,0x68,0x00,0x00,0x00 # mov %r12, 104(%rsp) + + #eighth iteration + mulx %rdx, %rax, %rdx +- adox %rax, %r13 +- adox %rbp, %rdx ++ xor %rbx, %rbx ++ adcx %rcx, %rax ++ adox %r13, %r13 ++ adcx %rbp, %rdx ++ adox %rbp, %rbx ++ adcx %r13, %rax ++ adcx %rdx, %rbx + +- .byte 0x66 +- add %rdx, %r14 +- +- movq %r13, 112(%rsp) +- movq %r14, 120(%rsp) + movq %xmm0, $out + movq %xmm1, %rbp + +@@ -741,6 +751,9 @@ $code.=<<___; + movq 48(%rsp), %r14 + movq 56(%rsp), %r15 + ++ movq %rax, 112(%rsp) ++ movq %rbx, 120(%rsp) ++ + call __rsaz_512_reducex + + addq 64(%rsp), %r8 +-- +2.24.0 + diff --git a/libs/patches/qt-Core-IO-Bluetooth-fix-ambiguous-conversions-for-macO.patch b/libs/patches/qt-Core-IO-Bluetooth-fix-ambiguous-conversions-for-macO.patch deleted file mode 100644 index bd6bd8af9..000000000 --- a/libs/patches/qt-Core-IO-Bluetooth-fix-ambiguous-conversions-for-macO.patch +++ /dev/null @@ -1,253 +0,0 @@ -From daf0e91b5be5a136d93b0e66efc3681f28a2ffde Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andr=C3=A9=20Klitzing?= -Date: Fri, 19 Jul 2019 11:06:59 +0200 -Subject: [PATCH] Core/IO/Bluetooth - fix ambiguous conversions for macOS - -This is a sibling of QTBUG-76847 on macOS instead of iOS. ---- - .../qbluetoothdevicediscoveryagent_osx.mm | 6 ++--- - src/bluetooth/qbluetoothlocaldevice_osx.mm | 2 +- - src/bluetooth/qbluetoothserver_osx.mm | 6 ++--- - src/bluetooth/qbluetoothserviceinfo_osx.mm | 2 +- - src/bluetooth/qbluetoothsocket_osx.mm | 26 +++++++++---------- - src/bluetooth/qbluetoothtransferreply_osx.mm | 10 +++---- - 6 files changed, 26 insertions(+), 26 deletions(-) - -diff --git x/qtconnectivity/src/bluetooth/qbluetoothdevicediscoveryagent_osx.mm y/qtconnectivity/src/bluetooth/qbluetoothdevicediscoveryagent_osx.mm -index 4657da82..bdc3c85e 100644 ---- x/qtconnectivity/src/bluetooth/qbluetoothdevicediscoveryagent_osx.mm -+++ y/qtconnectivity/src/bluetooth/qbluetoothdevicediscoveryagent_osx.mm -@@ -181,7 +181,7 @@ QBluetoothDeviceDiscoveryAgentPrivate::QBluetoothDeviceDiscoveryAgentPrivate(con - - QBluetoothDeviceDiscoveryAgentPrivate::~QBluetoothDeviceDiscoveryAgentPrivate() - { -- if (inquiryLE && agentState != NonActive) { -+ if (inquiryLE.data() && agentState != NonActive) { - // We want the LE scan to stop as soon as possible. - if (dispatch_queue_t leQueue = OSXBluetooth::qt_LE_queue()) { - // Local variable to be retained ... -@@ -195,7 +195,7 @@ QBluetoothDeviceDiscoveryAgentPrivate::~QBluetoothDeviceDiscoveryAgentPrivate() - - bool QBluetoothDeviceDiscoveryAgentPrivate::isValid() const - { -- return hostController && [hostController powerState] == kBluetoothHCIPowerStateON; -+ return hostController.data() && [hostController powerState] == kBluetoothHCIPowerStateON; - } - - bool QBluetoothDeviceDiscoveryAgentPrivate::isActive() const -@@ -292,7 +292,7 @@ void QBluetoothDeviceDiscoveryAgentPrivate::startLE() - - // Check queue and create scanner: - inquiryLE.reset([[LEDeviceInquiryObjC alloc] initWithNotifier:notifier.data()]); -- if (inquiryLE) -+ if (inquiryLE.data()) - notifier.take(); // Whatever happens next, inquiryLE is already the owner ... - - dispatch_queue_t leQueue(qt_LE_queue()); -diff --git x/qtconnectivity/src/bluetooth/qbluetoothlocaldevice_osx.mm y/qtconnectivity/src/bluetooth/qbluetoothlocaldevice_osx.mm -index 52b7bba8..e7dd9906 100644 ---- x/qtconnectivity/src/bluetooth/qbluetoothlocaldevice_osx.mm -+++ y/qtconnectivity/src/bluetooth/qbluetoothlocaldevice_osx.mm -@@ -149,7 +149,7 @@ QBluetoothLocalDevicePrivate::QBluetoothLocalDevicePrivate(QBluetoothLocalDevice - - bool QBluetoothLocalDevicePrivate::isValid() const - { -- return hostController; -+ return hostController.data(); - } - - void QBluetoothLocalDevicePrivate::requestPairing(const QBluetoothAddress &address, Pairing pairing) -diff --git x/qtconnectivity/src/bluetooth/qbluetoothserver_osx.mm y/qtconnectivity/src/bluetooth/qbluetoothserver_osx.mm -index eefaf4da..5d3b8fc4 100644 ---- x/qtconnectivity/src/bluetooth/qbluetoothserver_osx.mm -+++ y/qtconnectivity/src/bluetooth/qbluetoothserver_osx.mm -@@ -142,7 +142,7 @@ void QBluetoothServerPrivate::stopListener() - - void QBluetoothServerPrivate::openNotify(IOBluetoothRFCOMMChannel *channel) - { -- Q_ASSERT_X(listener, Q_FUNC_INFO, "invalid listener (nil)"); -+ Q_ASSERT_X(listener.data(), Q_FUNC_INFO, "invalid listener (nil)"); - Q_ASSERT_X(channel, Q_FUNC_INFO, "invalid channel (nil)"); - Q_ASSERT_X(q_ptr, Q_FUNC_INFO, "invalid q_ptr (null)"); - -@@ -154,7 +154,7 @@ void QBluetoothServerPrivate::openNotify(IOBluetoothRFCOMMChannel *channel) - - void QBluetoothServerPrivate::openNotify(IOBluetoothL2CAPChannel *channel) - { -- Q_ASSERT_X(listener, Q_FUNC_INFO, "invalid listener (nil)"); -+ Q_ASSERT_X(listener.data(), Q_FUNC_INFO, "invalid listener (nil)"); - Q_ASSERT_X(channel, Q_FUNC_INFO, "invalid channel (nil)"); - Q_ASSERT_X(q_ptr, Q_FUNC_INFO, "invalid q_ptr (null)"); - -@@ -293,7 +293,7 @@ bool QBluetoothServer::listen(const QBluetoothAddress &address, quint16 port) - - OSXBluetooth::qt_test_iobluetooth_runloop(); - -- if (d_ptr->listener) { -+ if (d_ptr->listener.data()) { - qCWarning(QT_BT_OSX) << "already in listen mode, close server first"; - return false; - } -diff --git x/qtconnectivity/src/bluetooth/qbluetoothserviceinfo_osx.mm y/qtconnectivity/src/bluetooth/qbluetoothserviceinfo_osx.mm -index 34de4695..7ce4c645 100644 ---- x/qtconnectivity/src/bluetooth/qbluetoothserviceinfo_osx.mm -+++ y/qtconnectivity/src/bluetooth/qbluetoothserviceinfo_osx.mm -@@ -152,7 +152,7 @@ bool QBluetoothServiceInfoPrivate::unregisterService() - if (!registered) - return false; - -- Q_ASSERT_X(serviceRecord, Q_FUNC_INFO, "service registered, but serviceRecord is nil"); -+ Q_ASSERT_X(serviceRecord.data(), Q_FUNC_INFO, "service registered, but serviceRecord is nil"); - - [serviceRecord removeServiceRecord]; - serviceRecord.reset(nil); -diff --git x/qtconnectivity/src/bluetooth/qbluetoothsocket_osx.mm y/qtconnectivity/src/bluetooth/qbluetoothsocket_osx.mm -index 7f630146..2a856092 100644 ---- x/qtconnectivity/src/bluetooth/qbluetoothsocket_osx.mm -+++ y/qtconnectivity/src/bluetooth/qbluetoothsocket_osx.mm -@@ -101,13 +101,13 @@ void QBluetoothSocketPrivate::connectToService(const QBluetoothAddress &address, - - if (socketType == QBluetoothServiceInfo::RfcommProtocol) { - rfcommChannel.reset([[ObjCRFCOMMChannel alloc] initWithDelegate:this]); -- if (rfcommChannel) -+ if (rfcommChannel.data()) - status = [rfcommChannel connectAsyncToDevice:address withChannelID:port]; - else - status = kIOReturnNoMemory; - } else if (socketType == QBluetoothServiceInfo::L2capProtocol) { - l2capChannel.reset([[ObjCL2CAPChannel alloc] initWithDelegate:this]); -- if (l2capChannel) -+ if (l2capChannel.data()) - status = [l2capChannel connectAsyncToDevice:address withPSM:port]; - else - status = kIOReturnNoMemory; -@@ -181,10 +181,10 @@ QString QBluetoothSocketPrivate::peerName() const - - NSString *nsName = nil; - if (socketType == QBluetoothServiceInfo::RfcommProtocol) { -- if (rfcommChannel) -+ if (rfcommChannel.data()) - nsName = [rfcommChannel peerName]; - } else if (socketType == QBluetoothServiceInfo::L2capProtocol) { -- if (l2capChannel) -+ if (l2capChannel.data()) - nsName = [l2capChannel peerName]; - } - -@@ -198,10 +198,10 @@ QBluetoothAddress QBluetoothSocketPrivate::peerAddress() const - { - BluetoothDeviceAddress addr = {}; - if (socketType == QBluetoothServiceInfo::RfcommProtocol) { -- if (rfcommChannel) -+ if (rfcommChannel.data()) - addr = [rfcommChannel peerAddress]; - } else if (socketType == QBluetoothServiceInfo::L2capProtocol) { -- if (l2capChannel) -+ if (l2capChannel.data()) - addr = [l2capChannel peerAddress]; - } - -@@ -211,10 +211,10 @@ QBluetoothAddress QBluetoothSocketPrivate::peerAddress() const - quint16 QBluetoothSocketPrivate::peerPort() const - { - if (socketType == QBluetoothServiceInfo::RfcommProtocol) { -- if (rfcommChannel) -+ if (rfcommChannel.data()) - return [rfcommChannel getChannelID]; - } else if (socketType == QBluetoothServiceInfo::L2capProtocol) { -- if (l2capChannel) -+ if (l2capChannel.data()) - return [l2capChannel getPSM]; - } - -@@ -231,7 +231,7 @@ void QBluetoothSocketPrivate::_q_writeNotify() - Q_ASSERT_X(socketType == QBluetoothServiceInfo::L2capProtocol - || socketType == QBluetoothServiceInfo::RfcommProtocol, - Q_FUNC_INFO, "invalid socket type"); -- Q_ASSERT_X(l2capChannel || rfcommChannel, Q_FUNC_INFO, -+ Q_ASSERT_X(l2capChannel.data() || rfcommChannel.data(), Q_FUNC_INFO, - "invalid socket (no open channel)"); - Q_ASSERT_X(q_ptr, Q_FUNC_INFO, "invalid q_ptr (null)"); - -@@ -275,13 +275,13 @@ bool QBluetoothSocketPrivate::setChannel(IOBluetoothRFCOMMChannel *channel) - - openMode = QIODevice::ReadWrite; - rfcommChannel.reset([[ObjCRFCOMMChannel alloc] initWithDelegate:this channel:channel]); -- if (rfcommChannel) {// We do not handle errors, up to an external user. -+ if (rfcommChannel.data()) {// We do not handle errors, up to an external user. - q_ptr->setOpenMode(QIODevice::ReadWrite); - state = QBluetoothSocket::ConnectedState; - socketType = QBluetoothServiceInfo::RfcommProtocol; - } - -- return rfcommChannel; -+ return rfcommChannel.data(); - } - - bool QBluetoothSocketPrivate::setChannel(IOBluetoothL2CAPChannel *channel) -@@ -299,13 +299,13 @@ bool QBluetoothSocketPrivate::setChannel(IOBluetoothL2CAPChannel *channel) - - openMode = QIODevice::ReadWrite; - l2capChannel.reset([[ObjCL2CAPChannel alloc] initWithDelegate:this channel:channel]); -- if (l2capChannel) {// We do not handle errors, up to an external user. -+ if (l2capChannel.data()) {// We do not handle errors, up to an external user. - q_ptr->setOpenMode(QIODevice::ReadWrite); - state = QBluetoothSocket::ConnectedState; - socketType = QBluetoothServiceInfo::L2capProtocol; - } - -- return l2capChannel; -+ return l2capChannel.data(); - } - - -diff --git x/qtconnectivity/src/bluetooth/qbluetoothtransferreply_osx.mm y/qtconnectivity/src/bluetooth/qbluetoothtransferreply_osx.mm -index 65c8f82d..40a747f8 100644 ---- x/qtconnectivity/src/bluetooth/qbluetoothtransferreply_osx.mm -+++ y/qtconnectivity/src/bluetooth/qbluetoothtransferreply_osx.mm -@@ -136,13 +136,13 @@ QBluetoothTransferReplyOSXPrivate::~QBluetoothTransferReplyOSXPrivate() - // The OBEX session will be closed then. If - // somehow IOBluetooth/OBEX still has a reference to our - // session, it will not call any of delegate's callbacks. -- if (session) -+ if (session.data()) - [session closeSession]; - } - - bool QBluetoothTransferReplyOSXPrivate::isActive() const - { -- return agent || (session && [session hasActiveRequest]); -+ return agent.data() || (session.data() && [session hasActiveRequest]); - } - - bool QBluetoothTransferReplyOSXPrivate::startOPP(const QBluetoothAddress &device) -@@ -218,7 +218,7 @@ void QBluetoothTransferReplyOSXPrivate::sendConnect(const QBluetoothAddress &dev - void QBluetoothTransferReplyOSXPrivate::sendPut() - { - Q_ASSERT_X(inputStream, Q_FUNC_INFO, "invalid input stream (null)"); -- Q_ASSERT_X(session, Q_FUNC_INFO, "invalid OBEX session (nil)"); -+ Q_ASSERT_X(session.data(), Q_FUNC_INFO, "invalid OBEX session (nil)"); - Q_ASSERT_X([session isConnected], Q_FUNC_INFO, "not connected"); - Q_ASSERT_X(![session hasActiveRequest], Q_FUNC_INFO, - "session already has an active request"); -@@ -268,7 +268,7 @@ void QBluetoothTransferReplyOSXPrivate::OBEXConnectError(OBEXError errorCode, OB - Q_UNUSED(errorCode) - Q_UNUSED(response) - -- if (session) { -+ if (session.data()) { - setReplyError(QBluetoothTransferReply::SessionError, - QCoreApplication::translate(TRANSFER_REPLY, TR_CONNECT_FAILED)); - } else { -@@ -283,7 +283,7 @@ void QBluetoothTransferReplyOSXPrivate::OBEXConnectError(OBEXError errorCode, OB - void QBluetoothTransferReplyOSXPrivate::OBEXConnectSuccess() - { - // Now that OBEX connect succeeded, we can send an OBEX put request. -- if (!session) { -+ if (!session.data()) { - // We're still in OBEXConnect(), it'll take care of next steps. - return; - } --- -2.22.0 - diff --git a/libs/patches/qt-Core-IO-Bluetooth-fix-ambiguous-conversions.patch b/libs/patches/qt-Core-IO-Bluetooth-fix-ambiguous-conversions.patch deleted file mode 100644 index a2279c726..000000000 --- a/libs/patches/qt-Core-IO-Bluetooth-fix-ambiguous-conversions.patch +++ /dev/null @@ -1,97 +0,0 @@ -From cd287186955f1c654a1f35197f0515ffc222e734 Mon Sep 17 00:00:00 2001 -From: Timur Pocheptsov -Date: Wed, 3 Jul 2019 15:26:31 +0200 -Subject: [PATCH] Core/IO/Bluetooth - fix ambiguous conversions - -... somewhat prospective fix (I do not have the new iOS yet), so far build -never failed with my current SDK. - -Fixes: QTBUG-76847 -Change-Id: Iab75c3cd47144cd83b679b1dbf82339e29c07bd1 ---- - src/bluetooth/osx/osxbtperipheralmanager.mm | 4 ++-- - src/bluetooth/qbluetoothdevicediscoveryagent_ios.mm | 6 +++--- - src/bluetooth/qlowenergycontroller_osx.mm | 6 +++--- - 3 files changed, 8 insertions(+), 8 deletions(-) - -diff --git x/qtconnectivity/src/bluetooth/osx/osxbtperipheralmanager.mm y/qtconnectivity/src/bluetooth/osx/osxbtperipheralmanager.mm -index 1998340a..39f9808c 100644 ---- x/qtconnectivity/src/bluetooth/osx/osxbtperipheralmanager.mm -+++ y/qtconnectivity/src/bluetooth/osx/osxbtperipheralmanager.mm -@@ -340,7 +340,7 @@ bool qt_validate_value_range(const QLowEnergyCharacteristicData &data) - - (void)startAdvertising - { - state = PeripheralState::waitingForPowerOn; -- if (manager) -+ if (manager.data()) - [manager setDelegate:nil]; - manager.reset([[CBPeripheralManager alloc] initWithDelegate:self - queue:OSXBluetooth::qt_LE_queue()]); -@@ -405,7 +405,7 @@ bool qt_validate_value_range(const QLowEnergyCharacteristicData &data) - - - (void) addServicesToPeripheral - { -- Q_ASSERT(manager); -+ Q_ASSERT(manager.data()); - - if (nextServiceToAdd < services.size()) - [manager addService:services[nextServiceToAdd++]]; -diff --git x/qtconnectivity/src/bluetooth/qbluetoothdevicediscoveryagent_ios.mm y/qtconnectivity/src/bluetooth/qbluetoothdevicediscoveryagent_ios.mm -index c50d546d..557785b4 100644 ---- x/qtconnectivity/src/bluetooth/qbluetoothdevicediscoveryagent_ios.mm -+++ y/qtconnectivity/src/bluetooth/qbluetoothdevicediscoveryagent_ios.mm -@@ -132,7 +132,7 @@ QBluetoothDeviceDiscoveryAgentPrivate::QBluetoothDeviceDiscoveryAgentPrivate(con - - QBluetoothDeviceDiscoveryAgentPrivate::~QBluetoothDeviceDiscoveryAgentPrivate() - { -- if (inquiryLE) { -+ if (inquiryLE.data()) { - // We want the LE scan to stop as soon as possible. - if (dispatch_queue_t leQueue = OSXBluetooth::qt_LE_queue()) { - // Local variable to be retained ... -@@ -151,7 +151,7 @@ bool QBluetoothDeviceDiscoveryAgentPrivate::isActive() const - if (stopPending) - return false; - -- return inquiryLE; -+ return !!inquiryLE.data(); - } - - void QBluetoothDeviceDiscoveryAgentPrivate::start(QBluetoothDeviceDiscoveryAgent::DiscoveryMethods /*methods*/) -@@ -178,7 +178,7 @@ void QBluetoothDeviceDiscoveryAgentPrivate::start(QBluetoothDeviceDiscoveryAgent - this, &QBluetoothDeviceDiscoveryAgentPrivate::LEdeviceFound); - - inquiryLE.reset([[LEDeviceInquiryObjC alloc] initWithNotifier:notifier.data()]); -- if (inquiryLE) -+ if (inquiryLE.data()) - notifier.take(); // Whatever happens next, inquiryLE is already the owner ... - - dispatch_queue_t leQueue(qt_LE_queue()); -diff --git x/qtconnectivity/src/bluetooth/qlowenergycontroller_osx.mm y/qtconnectivity/src/bluetooth/qlowenergycontroller_osx.mm -index 8bcdc22e..9aaee855 100644 ---- x/qtconnectivity/src/bluetooth/qlowenergycontroller_osx.mm -+++ y/qtconnectivity/src/bluetooth/qlowenergycontroller_osx.mm -@@ -165,7 +165,7 @@ QLowEnergyControllerPrivateOSX::QLowEnergyControllerPrivateOSX(QLowEnergyControl - #endif - } else { - centralManager.reset([[ObjCCentralManager alloc] initWith:notifier.data()]); -- if (!centralManager) { -+ if (!centralManager.data()) { - qCWarning(QT_BT_OSX) << "failed to initialize central manager"; - return; - } -@@ -200,9 +200,9 @@ QLowEnergyControllerPrivateOSX::~QLowEnergyControllerPrivateOSX() - bool QLowEnergyControllerPrivateOSX::isValid() const - { - #ifdef Q_OS_TVOS -- return centralManager; -+ return centralManager.data(); - #else -- return centralManager || peripheralManager; -+ return centralManager.data() || peripheralManager.data(); - #endif - } - --- -2.22.0 - diff --git a/libs/patches/qt-Filesystem-avoid-crashes-on-exit-in-case-the-locale-.patch b/libs/patches/qt-Filesystem-avoid-crashes-on-exit-in-case-the-locale-.patch new file mode 100644 index 000000000..f8b53dc5c --- /dev/null +++ b/libs/patches/qt-Filesystem-avoid-crashes-on-exit-in-case-the-locale-.patch @@ -0,0 +1,43 @@ +From a610554a21b259f70a194915cd37daa5be3f3550 Mon Sep 17 00:00:00 2001 +From: Thiago Macieira +Date: Tue, 17 Sep 2019 07:35:26 -0700 +Subject: [PATCH] Filesystem: avoid crashes on exit in case the locale codec is + null + +On exit, QLocale::codecForLocale() can return null as the codec may have +already been destroyed. In that case, pretend that Latin1 was the +locale, so any file name is acceptable. This matches QString: + + QTextCodec *codec = QTextCodec::codecForLocale(); + if (codec) + return codec->toUnicode(str, size); + #endif // textcodec + return fromLatin1(str, size); + +Note that if we're wrong and the locale was *not* Latin1, files that you +had a name to may not be encoded or decoded the same way. + +Fixes: QTBUG-78446 +Change-Id: Iece6e011237e4ab284ecfffd15c54077728a17ca +--- + src/corelib/io/qfilesystemiterator_unix.cpp | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git x/qtbase/src/corelib/io/qfilesystemiterator_unix.cpp y/qtbase/src/corelib/io/qfilesystemiterator_unix.cpp +index 92ebdf0341..0d178d062a 100644 +--- x/qtbase/src/corelib/io/qfilesystemiterator_unix.cpp ++++ y/qtbase/src/corelib/io/qfilesystemiterator_unix.cpp +@@ -69,7 +69,9 @@ static bool checkNameDecodable(const char *d_name, qsizetype len) + # ifdef QT_LOCALE_IS_UTF8 + int mibEnum = 106; + # else +- int mibEnum = codec->mibEnum(); ++ int mibEnum = 4; // Latin 1 ++ if (codec) ++ mibEnum = codec->mibEnum(); + # endif + if (Q_LIKELY(mibEnum == 106)) // UTF-8 + return QUtf8::isValidUtf8(d_name, len).isValidUtf8; +-- +2.23.0 + diff --git a/libs/patches/qt-Fix-build-with-no-feature-printer-on-macOS.patch b/libs/patches/qt-Fix-build-with-no-feature-printer-on-macOS.patch deleted file mode 100644 index bfe757e1e..000000000 --- a/libs/patches/qt-Fix-build-with-no-feature-printer-on-macOS.patch +++ /dev/null @@ -1,159 +0,0 @@ -From fdb01d0c01261008f9055339db55c6e9693f18c8 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andr=C3=A9=20Klitzing?= -Date: Tue, 23 Jul 2019 12:44:45 +0200 -Subject: [PATCH 2/2] Fix build with -no-feature-printer on macOS - -Fixes: QTBUG-62675 -Change-Id: I3bfcd6d78c3124769ff8662941472333c795fdbe ---- - src/plugins/platforms/cocoa/cocoa.pro | 42 +++++++++++-------- - .../platforms/cocoa/qcocoanativeinterface.mm | 6 +-- - .../platforms/cocoa/qpaintengine_mac.mm | 4 ++ - 3 files changed, 32 insertions(+), 20 deletions(-) - -diff --git x/qtbase/src/plugins/platforms/cocoa/cocoa.pro y/qtbase/src/plugins/platforms/cocoa/cocoa.pro -index 083b7c1655..4249bae2b1 100644 ---- x/qtbase/src/plugins/platforms/cocoa/cocoa.pro -+++ y/qtbase/src/plugins/platforms/cocoa/cocoa.pro -@@ -20,8 +20,6 @@ SOURCES += main.mm \ - qcocoamenuloader.mm \ - qcocoahelpers.mm \ - qmultitouch_mac.mm \ -- qcocoaaccessibilityelement.mm \ -- qcocoaaccessibility.mm \ - qcocoacursor.mm \ - qcocoaclipboard.mm \ - qcocoadrag.mm \ -@@ -55,8 +53,6 @@ HEADERS += qcocoaintegration.h \ - qcocoamenuloader.h \ - qcocoahelpers.h \ - qmultitouch_mac_p.h \ -- qcocoaaccessibilityelement.h \ -- qcocoaaccessibility.h \ - qcocoacursor.h \ - qcocoaclipboard.h \ - qcocoadrag.h \ -@@ -81,15 +77,24 @@ qtConfig(vulkan) { - HEADERS += qcocoavulkaninstance.h - } - -+qtConfig(accessibility) { -+ SOURCES += qcocoaaccessibilityelement.mm \ -+ qcocoaaccessibility.mm -+ HEADERS += qcocoaaccessibilityelement.h \ -+ qcocoaaccessibility.h -+} -+ - RESOURCES += qcocoaresources.qrc - - LIBS += -framework AppKit -framework CoreServices -framework Carbon -framework IOKit -framework QuartzCore -framework CoreVideo -framework Metal -framework IOSurface -lcups - - QT += \ - core-private gui-private \ -- accessibility_support-private clipboard_support-private theme_support-private \ -+ clipboard_support-private theme_support-private \ - fontdatabase_support-private graphics_support-private - -+qtConfig(accessibility): QT += accessibility_support-private -+ - qtConfig(vulkan): QT += vulkan_support-private - - CONFIG += no_app_extension_api_only -@@ -97,17 +102,19 @@ CONFIG += no_app_extension_api_only - qtHaveModule(widgets) { - QT_FOR_CONFIG += widgets - -- SOURCES += \ -- qpaintengine_mac.mm \ -- qprintengine_mac.mm \ -- qcocoaprintersupport.mm \ -- qcocoaprintdevice.mm \ -- -- HEADERS += \ -- qpaintengine_mac_p.h \ -- qprintengine_mac_p.h \ -- qcocoaprintersupport.h \ -- qcocoaprintdevice.h \ -+ SOURCES += qpaintengine_mac.mm -+ HEADERS += qpaintengine_mac_p.h -+ -+ qtHaveModule(printsupport) { -+ SOURCES += \ -+ qprintengine_mac.mm \ -+ qcocoaprintersupport.mm \ -+ qcocoaprintdevice.mm -+ HEADERS += \ -+ qcocoaprintersupport.h \ -+ qcocoaprintdevice.h \ -+ qprintengine_mac_p.h -+ } - - qtConfig(colordialog) { - SOURCES += qcocoacolordialoghelper.mm -@@ -124,7 +131,8 @@ qtHaveModule(widgets) { - HEADERS += qcocoafontdialoghelper.h - } - -- QT += widgets-private printsupport-private -+ QT += widgets-private -+ qtHaveModule(printsupport): QT += printsupport-private - } - - OTHER_FILES += cocoa.json -diff --git x/qtbase/src/plugins/platforms/cocoa/qcocoanativeinterface.mm y/qtbase/src/plugins/platforms/cocoa/qcocoanativeinterface.mm -index 7979e430ac..8c0bd1d158 100644 ---- x/qtbase/src/plugins/platforms/cocoa/qcocoanativeinterface.mm -+++ y/qtbase/src/plugins/platforms/cocoa/qcocoanativeinterface.mm -@@ -59,7 +59,7 @@ - #include "qguiapplication.h" - #include - --#ifndef QT_NO_WIDGETS -+#if !defined(QT_NO_WIDGETS) && defined(QT_PRINTSUPPORT_LIB) - #include "qcocoaprintersupport.h" - #include "qprintengine_mac_p.h" - #include -@@ -153,7 +153,7 @@ QPlatformNativeInterface::NativeResourceForIntegrationFunction QCocoaNativeInter - - QPlatformPrinterSupport *QCocoaNativeInterface::createPlatformPrinterSupport() - { --#if !defined(QT_NO_WIDGETS) && !defined(QT_NO_PRINTER) -+#if !defined(QT_NO_WIDGETS) && !defined(QT_NO_PRINTER) && defined(QT_PRINTSUPPORT_LIB) - return new QCocoaPrinterSupport(); - #else - qFatal("Printing is not supported when Qt is configured with -no-widgets"); -@@ -163,7 +163,7 @@ QPlatformPrinterSupport *QCocoaNativeInterface::createPlatformPrinterSupport() - - void *QCocoaNativeInterface::NSPrintInfoForPrintEngine(QPrintEngine *printEngine) - { --#if !defined(QT_NO_WIDGETS) && !defined(QT_NO_PRINTER) -+#if !defined(QT_NO_WIDGETS) && !defined(QT_NO_PRINTER) && defined(QT_PRINTSUPPORT_LIB) - QMacPrintEnginePrivate *macPrintEnginePriv = static_cast(printEngine)->d_func(); - if (macPrintEnginePriv->state == QPrinter::Idle && !macPrintEnginePriv->isPrintSessionInitialized()) - macPrintEnginePriv->initialize(); -diff --git x/qtbase/src/plugins/platforms/cocoa/qpaintengine_mac.mm y/qtbase/src/plugins/platforms/cocoa/qpaintengine_mac.mm -index 3677877538..00b2267f0d 100644 ---- x/qtbase/src/plugins/platforms/cocoa/qpaintengine_mac.mm -+++ y/qtbase/src/plugins/platforms/cocoa/qpaintengine_mac.mm -@@ -38,14 +38,18 @@ - ****************************************************************************/ - - #include "qpaintengine_mac_p.h" -+#if defined(QT_PRINTSUPPORT_LIB) - #include "qprintengine_mac_p.h" -+#endif - - #include - #include - #include - #include - #include -+#if defined(QT_PRINTSUPPORT_LIB) - #include -+#endif - #include - #include - #include --- -2.22.0 - diff --git a/libs/patches/qt-Fix-build-with-no-feature-printer.patch b/libs/patches/qt-Fix-build-with-no-feature-printer.patch deleted file mode 100644 index 1bb8cfaf9..000000000 --- a/libs/patches/qt-Fix-build-with-no-feature-printer.patch +++ /dev/null @@ -1,54 +0,0 @@ -From d8ac3ad8e4dfc26c6b2f4bb696d4ec8cc23d8cbf Mon Sep 17 00:00:00 2001 -From: Kai Koehne -Date: Tue, 9 Jul 2019 17:19:26 +0200 -Subject: [PATCH 1/2] Fix build with -no-feature-printer -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Skip printsupport subdirectory if printer feature is disabled. Also -removed android-embedded condition for the plugin: Such a -configuration should just disable the printer feature. - -Fixes: QTBUG-76941 -Change-Id: Ifca7d2311a575c1589ad6a87a775bd016591ee2c -Reviewed-by: Jörg Bornemann ---- - src/src.pro | 10 +++++++--- - 1 file changed, 7 insertions(+), 3 deletions(-) - -diff --git x/qtbase/src/src.pro y/qtbase/src/src.pro -index 1c76a2e46f..b704ccd7ab 100644 ---- x/qtbase/src/src.pro -+++ y/qtbase/src/src.pro -@@ -1,8 +1,10 @@ - TEMPLATE = subdirs - --QT_FOR_CONFIG += core-private gui-private -+QT_FOR_CONFIG += core-private gui-private printsupport -+ - include($$OUT_PWD/corelib/qtcore-config.pri) - include($$OUT_PWD/gui/qtgui-config.pri) -+include($$OUT_PWD/printsupport/qtprintsupport-config.pri) - - force_bootstrap|!qtConfig(commandlineparser): \ - CONFIG += force_dbus_bootstrap -@@ -221,11 +223,13 @@ qtConfig(gui) { - src_testlib.depends += src_gui # if QtGui is enabled, QtTest requires QtGui's headers - qtConfig(widgets) { - SUBDIRS += src_tools_uic src_widgets -- !android-embedded: SUBDIRS += src_printsupport - TOOLS += src_tools_uic - src_plugins.depends += src_widgets -- !android-embedded: src_plugins.depends += src_printsupport - src_testlib.depends += src_widgets # if QtWidgets is enabled, QtTest requires QtWidgets's headers -+ qtConfig(printer) { -+ SUBDIRS += src_printsupport -+ src_plugins.depends += src_printsupport -+ } - qtConfig(opengl) { - SUBDIRS += src_opengl - src_plugins.depends += src_opengl --- -2.22.0 - diff --git a/libs/patches/qt-Remove-dead-code-to-fix-a-lint-warning.patch b/libs/patches/qt-Remove-dead-code-to-fix-a-lint-warning.patch new file mode 100644 index 000000000..f679a2c6e --- /dev/null +++ b/libs/patches/qt-Remove-dead-code-to-fix-a-lint-warning.patch @@ -0,0 +1,51 @@ +From 2194895b59850f4c241dbf54c16240110604f0f2 Mon Sep 17 00:00:00 2001 +From: Lars Schmertmann +Date: Fri, 6 Dec 2019 07:52:05 +0100 +Subject: Remove dead code to fix a lint warning + +Obsolete SDK_INT Version Check +------------------------------ +This check flags version checks that are not necessary, +because the minSdkVersion (or surrounding known API level) +is already at least as high as the version checked for. + +The mindSdkVersion in templates/AndroidManifest.xml is 16 for Qt 5.12 +and androiddeployqt also ensures that the minSdkVersion is not below 16. + +Change-Id: Ifdb6f773dccdb75c35119df833c976b7b76b3356 +Reviewed-by: BogDan Vatra +--- + .../qt5/android/bindings/QtActivityLoader.java | 17 ----------------- + 1 file changed, 17 deletions(-) + +diff --git x/qtbase/src/android/java/src/org/qtproject/qt5/android/bindings/QtActivityLoader.java y/qtbase/src/android/java/src/org/qtproject/qt5/android/bindings/QtActivityLoader.java +index 759daf4393..fad9588425 100644 +--- x/qtbase/src/android/java/src/org/qtproject/qt5/android/bindings/QtActivityLoader.java ++++ y/qtbase/src/android/java/src/org/qtproject/qt5/android/bindings/QtActivityLoader.java +@@ -132,23 +132,6 @@ public class QtActivityLoader extends QtLoader { + return; + } + +- if (Build.VERSION.SDK_INT < 16) { +- // fatal error, show the error and quit +- AlertDialog errorDialog = new AlertDialog.Builder(m_activity).create(); +- if (m_contextInfo.metaData.containsKey("android.app.unsupported_android_version")) +- errorDialog.setMessage(m_contextInfo.metaData.getString("android.app.unsupported_android_version")); +- else +- errorDialog.setMessage("Unsupported Android version."); +- errorDialog.setButton(m_activity.getResources().getString(android.R.string.ok), new DialogInterface.OnClickListener() { +- @Override +- public void onClick(DialogInterface dialog, int which) { +- finish(); +- } +- }); +- errorDialog.show(); +- return; +- } +- + try { + m_activity.setTheme(Class.forName("android.R$style").getDeclaredField(QT_ANDROID_DEFAULT_THEME).getInt(null)); + } catch (Exception e) { +-- +2.23.0 + diff --git a/libs/patches/qt-Revert-Android-Stick-with-buildToolsVersion-28.0.3.patch b/libs/patches/qt-Revert-Android-Stick-with-buildToolsVersion-28.0.3.patch new file mode 100644 index 000000000..de42fdfa2 --- /dev/null +++ b/libs/patches/qt-Revert-Android-Stick-with-buildToolsVersion-28.0.3.patch @@ -0,0 +1,26 @@ +From d7f3fc88f38492d940a4c6685d65c493b63ad72a Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andr=C3=A9=20Klitzing?= +Date: Tue, 1 Oct 2019 15:37:16 +0200 +Subject: [PATCH] Revert "Android: Stick with buildToolsVersion 28.0.3" + +This reverts commit 1e4dec12d5c0152d5c3eee3b612a0af4bf389a37. +--- + src/android/templates/build.gradle | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git x/qtbase/src/android/templates/build.gradle y/qtbase/src/android/templates/build.gradle +index ed704c4957..989d0792cf 100644 +--- x/qtbase/src/android/templates/build.gradle ++++ y/qtbase/src/android/templates/build.gradle +@@ -36,7 +36,7 @@ android { + + compileSdkVersion androidCompileSdkVersion.toInteger() + +- buildToolsVersion '28.0.3' ++ buildToolsVersion androidBuildToolsVersion + + sourceSets { + main { +-- +2.23.0 + diff --git a/resources/ausweisapp.qrc b/resources/ausweisapp.qrc index 14484050d..f0095fafd 100644 --- a/resources/ausweisapp.qrc +++ b/resources/ausweisapp.qrc @@ -1,6 +1,7 @@ images/npa.svg + images/beta.svg images/bg_da.png images/bt_1.svg images/bt_1b.svg @@ -25,28 +26,31 @@ images/delete.svg images/NFCPhoneCard.png images/submit.svg - images/ausweis.png + images/ausweis.svg + images/visibility.svg + images/visibility_off.svg + images/settings_icon.svg + images/main_pin.svg + images/main_provider.svg images/provider/information.svg images/provider/purpose.svg images/provider/adresse.svg images/provider/mail.svg images/provider/telefon.svg images/provider/url.svg - images/provider/gradient-citizen.png - images/provider/gradient-insurance.png - images/provider/gradient-finance.png - images/provider/gradient-other.png images/provider/categoryIcons/general.svg images/provider/categoryIcons/citizen.svg images/provider/categoryIcons/finance.svg images/provider/categoryIcons/insurance.svg images/provider/categoryIcons/other.svg + images/provider/categoryIcons/+android/default_bg.svg images/provider/categoryIcons/+android/general_bg.svg images/provider/categoryIcons/+android/general.svg images/provider/categoryIcons/+android/citizen.svg images/provider/categoryIcons/+android/finance.svg images/provider/categoryIcons/+android/insurance.svg images/provider/categoryIcons/+android/other.svg + images/provider/categoryIcons/+android/default_bg.svg images/provider/categoryIcons/+android/general_bg.svg images/provider/categoryIcons/+android/general_button.svg images/provider/categoryIcons/+android/citizen_bg.svg @@ -57,11 +61,6 @@ images/provider/categoryIcons/+android/insurance_button.svg images/provider/categoryIcons/+android/other_bg.svg images/provider/categoryIcons/+android/other_button.svg - images/provider/categoryIcons/+android/general_section.svg - images/provider/categoryIcons/+android/citizen_section.svg - images/provider/categoryIcons/+android/finance_section.svg - images/provider/categoryIcons/+android/insurance_section.svg - images/provider/categoryIcons/+android/other_section.svg updatable-files/supported-providers.json images/icon_nfc.svg images/icon_remote.svg @@ -78,9 +77,9 @@ images/phone_bluetooth.svg images/location_flag_de.svg images/location_flag_en.svg + images/link_external.svg images/siteWithLogo.png - images/icon_pair.svg - images/icon_settings.svg + images/trash_icon_all.svg images/trash_icon_white.svg images/trash_icon.svg images/icon_save.svg diff --git a/resources/ausweisapp_desktop.qrc b/resources/ausweisapp_desktop.qrc index 9fbe50227..a2773c722 100644 --- a/resources/ausweisapp_desktop.qrc +++ b/resources/ausweisapp_desktop.qrc @@ -3,7 +3,6 @@ html_templates/alreadyactive.html html_templates/error.html stylesheets/desktop.qss - images/beta.svg images/MenuSelected.png images/MenuUnselected.png images/MenuUnselectedDisabled.png @@ -15,20 +14,15 @@ images/html_message_section.jpg images/search_icon.svg images/search_cancel.svg - images/desktop/bell_white.svg - images/desktop/bell_green.svg - images/desktop/bell_red.svg + images/desktop/bell.svg images/desktop/id_card.png - images/desktop/pin-letter-page1.png - images/desktop/pin-letter-page2.png + images/desktop/pin_letter_pinpuk_different_page.svg + images/desktop/pin_letter_pinpuk_same_page.svg images/desktop/help_icon.svg images/desktop/main_history.svg images/desktop/main_identify.svg images/desktop/main_info.svg - images/desktop/main_pin.svg - images/desktop/main_provider.svg images/desktop/sandglass.svg - images/desktop/settings_icon.svg images/desktop/titlebar_arrow.svg images/desktop/continue_arrow.svg images/desktop/info_questions.svg @@ -103,6 +97,8 @@ updatable-files/reader/img_Identive_SDI011_mit_ausweis.png updatable-files/reader/img_KOBIL_ID_Token.png updatable-files/reader/img_KOBIL_ID_Token_mit_ausweis.png + updatable-files/reader/img_PersoSim.png + updatable-files/reader/img_PersoSim_mit_ausweis.png updatable-files/reader/img_Reiner_SCT_cyberjack_RFID_basis.png updatable-files/reader/img_Reiner_SCT_cyberjack_RFID_basis_mit_ausweis.png updatable-files/reader/img_Reiner_SCT_cyberjack_RFID_komfort.png diff --git a/resources/ausweisapp_mobile.qrc b/resources/ausweisapp_mobile.qrc index 11659c3be..d741e0a6c 100644 --- a/resources/ausweisapp_mobile.qrc +++ b/resources/ausweisapp_mobile.qrc @@ -1,16 +1,13 @@ qtquickcontrols2.conf - images/zahnraeder.svg images/arrowLeft.svg images/arrowRight.svg images/share.svg images/android/navigation/ausweisen.svg - images/android/navigation/anbieter.svg images/android/navigation/balloon.svg images/android/navigation/remoteleser.svg images/android/navigation/verlauf.svg - images/android/navigation/pin.svg images/android/navigation/faq.svg images/android/navigation/support.svg images/android/navigation/bewerten.svg @@ -18,6 +15,7 @@ images/android/search_icon.svg images/iOS/search_icon.svg images/iOS/search_cancel.svg + images/iOS/more/icon_mehr_settings.svg images/iOS/more/icon_mehr_npa.svg images/iOS/more/icon_mehr_favorit.svg images/iOS/more/icon_mehr_fragen.svg @@ -40,7 +38,6 @@ images/tutorial/arrows.svg images/tutorial/button_de.png images/tutorial/button_en.png - images/tutorial/idcard.svg images/tutorial/identify.svg images/tutorial/questionmark.svg images/tutorial/hint.svg @@ -160,11 +157,8 @@ images/provider/categoryIcons/+android/other_bg.svg images/provider/categoryIcons/+android/other_button.svg images/android/navigation/remotesettings.svg - images/trash_icon_all.svg - images/iOS/tabBar/anbieter.svg images/iOS/tabBar/ausweisen.svg images/iOS/tabBar/more.svg - images/iOS/tabBar/pin.svg images/iOS/tabBar/remoteleser.svg diff --git a/resources/images/android/adaptive_background.svg b/resources/images/android/adaptive_background.svg new file mode 100644 index 000000000..c43e47ccd --- /dev/null +++ b/resources/images/android/adaptive_background.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/resources/images/android/adaptive_foreground_beta.svg b/resources/images/android/adaptive_foreground_beta.svg new file mode 100644 index 000000000..0e75a60e9 --- /dev/null +++ b/resources/images/android/adaptive_foreground_beta.svg @@ -0,0 +1,74 @@ + + + + + + + + + + + + + + + + + + + diff --git a/resources/images/android/adaptive_foreground_preview.svg b/resources/images/android/adaptive_foreground_preview.svg new file mode 100644 index 000000000..7fe43c9c6 --- /dev/null +++ b/resources/images/android/adaptive_foreground_preview.svg @@ -0,0 +1,6 @@ + + + + + PREVIEW + diff --git a/resources/images/android/adaptive_foreground_release.svg b/resources/images/android/adaptive_foreground_release.svg new file mode 100644 index 000000000..4dbc2a0a0 --- /dev/null +++ b/resources/images/android/adaptive_foreground_release.svg @@ -0,0 +1,4 @@ + + + + diff --git a/resources/images/android/hdpi/background_npa.png b/resources/images/android/hdpi/background_npa.png index 6ff0210dc..147624d15 100644 Binary files a/resources/images/android/hdpi/background_npa.png and b/resources/images/android/hdpi/background_npa.png differ diff --git a/resources/images/android/hdpi/foreground_npa.png b/resources/images/android/hdpi/foreground_npa.png index df85de4d7..8abb0b840 100644 Binary files a/resources/images/android/hdpi/foreground_npa.png and b/resources/images/android/hdpi/foreground_npa.png differ diff --git a/resources/images/android/hdpi/foreground_npa_beta.png b/resources/images/android/hdpi/foreground_npa_beta.png index e755bb9f1..6428609be 100644 Binary files a/resources/images/android/hdpi/foreground_npa_beta.png and b/resources/images/android/hdpi/foreground_npa_beta.png differ diff --git a/resources/images/android/hdpi/foreground_npa_preview.png b/resources/images/android/hdpi/foreground_npa_preview.png index ece6b8ec9..821f07793 100644 Binary files a/resources/images/android/hdpi/foreground_npa_preview.png and b/resources/images/android/hdpi/foreground_npa_preview.png differ diff --git a/resources/images/android/ldpi/background_npa.png b/resources/images/android/ldpi/background_npa.png index 5e373b6ad..cd0090c03 100644 Binary files a/resources/images/android/ldpi/background_npa.png and b/resources/images/android/ldpi/background_npa.png differ diff --git a/resources/images/android/ldpi/foreground_npa.png b/resources/images/android/ldpi/foreground_npa.png index 81c03603d..73a7a0b30 100644 Binary files a/resources/images/android/ldpi/foreground_npa.png and b/resources/images/android/ldpi/foreground_npa.png differ diff --git a/resources/images/android/ldpi/foreground_npa_beta.png b/resources/images/android/ldpi/foreground_npa_beta.png index 923da0ba6..d39a30c14 100644 Binary files a/resources/images/android/ldpi/foreground_npa_beta.png and b/resources/images/android/ldpi/foreground_npa_beta.png differ diff --git a/resources/images/android/ldpi/foreground_npa_preview.png b/resources/images/android/ldpi/foreground_npa_preview.png index 44934113a..e6628390f 100644 Binary files a/resources/images/android/ldpi/foreground_npa_preview.png and b/resources/images/android/ldpi/foreground_npa_preview.png differ diff --git a/resources/images/android/mdpi/background_npa.png b/resources/images/android/mdpi/background_npa.png index ede700332..135e2b174 100644 Binary files a/resources/images/android/mdpi/background_npa.png and b/resources/images/android/mdpi/background_npa.png differ diff --git a/resources/images/android/mdpi/foreground_npa.png b/resources/images/android/mdpi/foreground_npa.png index a95605986..32814c4e8 100644 Binary files a/resources/images/android/mdpi/foreground_npa.png and b/resources/images/android/mdpi/foreground_npa.png differ diff --git a/resources/images/android/mdpi/foreground_npa_beta.png b/resources/images/android/mdpi/foreground_npa_beta.png index 3b9577fc7..307ed40ab 100644 Binary files a/resources/images/android/mdpi/foreground_npa_beta.png and b/resources/images/android/mdpi/foreground_npa_beta.png differ diff --git a/resources/images/android/mdpi/foreground_npa_preview.png b/resources/images/android/mdpi/foreground_npa_preview.png index c62fef843..cbd2f4d9e 100644 Binary files a/resources/images/android/mdpi/foreground_npa_preview.png and b/resources/images/android/mdpi/foreground_npa_preview.png differ diff --git a/resources/images/android/navigation/anbieter.svg b/resources/images/android/navigation/anbieter.svg deleted file mode 100644 index 02f84697f..000000000 --- a/resources/images/android/navigation/anbieter.svg +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - diff --git a/resources/images/android/navigation/ausweisen.svg b/resources/images/android/navigation/ausweisen.svg index 5cd91c640..950846c26 100644 --- a/resources/images/android/navigation/ausweisen.svg +++ b/resources/images/android/navigation/ausweisen.svg @@ -1,6 +1,6 @@ - + - + fill="#86858A" /> + diff --git a/resources/images/android/navigation/bewerten.svg b/resources/images/android/navigation/bewerten.svg index 30662a2b8..b42605653 100644 --- a/resources/images/android/navigation/bewerten.svg +++ b/resources/images/android/navigation/bewerten.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/android/navigation/faq.svg b/resources/images/android/navigation/faq.svg index 4c485bcce..19604a6fb 100644 --- a/resources/images/android/navigation/faq.svg +++ b/resources/images/android/navigation/faq.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/android/navigation/pin.svg b/resources/images/android/navigation/pin.svg deleted file mode 100644 index b71a3e55f..000000000 --- a/resources/images/android/navigation/pin.svg +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - diff --git a/resources/images/android/navigation/remoteleser.svg b/resources/images/android/navigation/remoteleser.svg index 6385894b1..1ac73f734 100644 --- a/resources/images/android/navigation/remoteleser.svg +++ b/resources/images/android/navigation/remoteleser.svg @@ -5,5 +5,5 @@ m -4.153,-23.329 -6.181,0 0,-0.674 6.182,0 -0.001,0.674 0,0 z m 2.645,-0.308 c 0,0.326 -0.266,0.59 -0.591,0.59 -0.326,0 -0.591,-0.265 -0.591,-0.59 0,-0.325 0.265,-0.59 0.591,-0.59 0.326,-0.001 0.591,0.264 0.591,0.59 z m -2.922,27.19 -5.629,0 0,-1.732 5.629,0 0,1.732 z" - style="fill: #8e8e93;" /> + style="fill: #86858A;" /> diff --git a/resources/images/android/navigation/remotesettings.svg b/resources/images/android/navigation/remotesettings.svg index e0cee90b6..14e0c00fd 100644 --- a/resources/images/android/navigation/remotesettings.svg +++ b/resources/images/android/navigation/remotesettings.svg @@ -1,7 +1,7 @@ - + + style="fill: #86858A;" /> diff --git a/resources/images/android/navigation/support.svg b/resources/images/android/navigation/support.svg index 1f251afdc..32cdbea27 100644 --- a/resources/images/android/navigation/support.svg +++ b/resources/images/android/navigation/support.svg @@ -1,9 +1,9 @@ - + - + diff --git a/resources/images/android/navigation/tutorial.svg b/resources/images/android/navigation/tutorial.svg index 82e5b2f8d..fca0e1e85 100644 --- a/resources/images/android/navigation/tutorial.svg +++ b/resources/images/android/navigation/tutorial.svg @@ -1,9 +1,9 @@ - + - + diff --git a/resources/images/android/navigation/verlauf.svg b/resources/images/android/navigation/verlauf.svg index 61fe3f372..4d33cb62c 100644 --- a/resources/images/android/navigation/verlauf.svg +++ b/resources/images/android/navigation/verlauf.svg @@ -1,7 +1,7 @@ - - + + diff --git a/resources/images/android/npa.svg b/resources/images/android/npa.svg deleted file mode 100644 index 4a943b3ef..000000000 --- a/resources/images/android/npa.svg +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - diff --git a/resources/images/android/npa_background.svg b/resources/images/android/npa_background.svg deleted file mode 100644 index 9094ed261..000000000 --- a/resources/images/android/npa_background.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/resources/images/android/npa_beta.svg b/resources/images/android/npa_beta.svg deleted file mode 100644 index 0a49f29d9..000000000 --- a/resources/images/android/npa_beta.svg +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/resources/images/android/playstore_background.svg b/resources/images/android/playstore_background.svg new file mode 100644 index 000000000..3119b0c89 --- /dev/null +++ b/resources/images/android/playstore_background.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/resources/images/android/playstore_preview.png b/resources/images/android/playstore_preview.png new file mode 100644 index 000000000..b1876199f Binary files /dev/null and b/resources/images/android/playstore_preview.png differ diff --git a/resources/images/android/playstore_preview.svg b/resources/images/android/playstore_preview.svg new file mode 100644 index 000000000..d819bb890 --- /dev/null +++ b/resources/images/android/playstore_preview.svg @@ -0,0 +1,7 @@ + + + + + + PREVIEW + diff --git a/resources/images/android/playstore_release.png b/resources/images/android/playstore_release.png new file mode 100644 index 000000000..0caa818f2 Binary files /dev/null and b/resources/images/android/playstore_release.png differ diff --git a/resources/images/android/playstore_release.svg b/resources/images/android/playstore_release.svg new file mode 100644 index 000000000..3bb224a96 --- /dev/null +++ b/resources/images/android/playstore_release.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/resources/images/android/xhdpi/background_npa.png b/resources/images/android/xhdpi/background_npa.png index 582287408..6af8f275d 100644 Binary files a/resources/images/android/xhdpi/background_npa.png and b/resources/images/android/xhdpi/background_npa.png differ diff --git a/resources/images/android/xhdpi/foreground_npa.png b/resources/images/android/xhdpi/foreground_npa.png index 16450d178..9f42940fc 100644 Binary files a/resources/images/android/xhdpi/foreground_npa.png and b/resources/images/android/xhdpi/foreground_npa.png differ diff --git a/resources/images/android/xhdpi/foreground_npa_beta.png b/resources/images/android/xhdpi/foreground_npa_beta.png index e29fa51c4..f529eb61a 100644 Binary files a/resources/images/android/xhdpi/foreground_npa_beta.png and b/resources/images/android/xhdpi/foreground_npa_beta.png differ diff --git a/resources/images/android/xhdpi/foreground_npa_preview.png b/resources/images/android/xhdpi/foreground_npa_preview.png index 1ab642196..aa8ea8ec1 100644 Binary files a/resources/images/android/xhdpi/foreground_npa_preview.png and b/resources/images/android/xhdpi/foreground_npa_preview.png differ diff --git a/resources/images/android/xxhdpi/background_npa.png b/resources/images/android/xxhdpi/background_npa.png index 58f957869..f02fd8610 100644 Binary files a/resources/images/android/xxhdpi/background_npa.png and b/resources/images/android/xxhdpi/background_npa.png differ diff --git a/resources/images/android/xxhdpi/foreground_npa.png b/resources/images/android/xxhdpi/foreground_npa.png index f36de1f0a..68f09c4f5 100644 Binary files a/resources/images/android/xxhdpi/foreground_npa.png and b/resources/images/android/xxhdpi/foreground_npa.png differ diff --git a/resources/images/android/xxhdpi/foreground_npa_beta.png b/resources/images/android/xxhdpi/foreground_npa_beta.png index 666f698cb..1ece1877f 100644 Binary files a/resources/images/android/xxhdpi/foreground_npa_beta.png and b/resources/images/android/xxhdpi/foreground_npa_beta.png differ diff --git a/resources/images/android/xxhdpi/foreground_npa_preview.png b/resources/images/android/xxhdpi/foreground_npa_preview.png index a5183eb91..b9e3e4494 100644 Binary files a/resources/images/android/xxhdpi/foreground_npa_preview.png and b/resources/images/android/xxhdpi/foreground_npa_preview.png differ diff --git a/resources/images/android/xxxhdpi/background_npa.png b/resources/images/android/xxxhdpi/background_npa.png index fe37593cf..07d3d64e3 100644 Binary files a/resources/images/android/xxxhdpi/background_npa.png and b/resources/images/android/xxxhdpi/background_npa.png differ diff --git a/resources/images/android/xxxhdpi/foreground_npa.png b/resources/images/android/xxxhdpi/foreground_npa.png index 85fc9ab51..678bd9dac 100644 Binary files a/resources/images/android/xxxhdpi/foreground_npa.png and b/resources/images/android/xxxhdpi/foreground_npa.png differ diff --git a/resources/images/android/xxxhdpi/foreground_npa_beta.png b/resources/images/android/xxxhdpi/foreground_npa_beta.png index 9437e83e4..b5c327c8c 100644 Binary files a/resources/images/android/xxxhdpi/foreground_npa_beta.png and b/resources/images/android/xxxhdpi/foreground_npa_beta.png differ diff --git a/resources/images/android/xxxhdpi/foreground_npa_preview.png b/resources/images/android/xxxhdpi/foreground_npa_preview.png index c9856f4c2..aef64f54b 100644 Binary files a/resources/images/android/xxxhdpi/foreground_npa_preview.png and b/resources/images/android/xxxhdpi/foreground_npa_preview.png differ diff --git a/resources/images/ausweis.png b/resources/images/ausweis.png deleted file mode 100644 index 934f2ae4b..000000000 Binary files a/resources/images/ausweis.png and /dev/null differ diff --git a/resources/images/ausweis.svg b/resources/images/ausweis.svg new file mode 100644 index 000000000..6cb9bc910 --- /dev/null +++ b/resources/images/ausweis.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/resources/images/desktop/bell_white.svg b/resources/images/desktop/bell.svg similarity index 100% rename from resources/images/desktop/bell_white.svg rename to resources/images/desktop/bell.svg diff --git a/resources/images/desktop/bell_green.svg b/resources/images/desktop/bell_green.svg deleted file mode 100644 index 8d1506d3d..000000000 --- a/resources/images/desktop/bell_green.svg +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/resources/images/desktop/bell_red.svg b/resources/images/desktop/bell_red.svg deleted file mode 100644 index e7d119451..000000000 --- a/resources/images/desktop/bell_red.svg +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/resources/images/desktop/info_setup.svg b/resources/images/desktop/info_setup.svg index bdc623cc3..b1f62406e 100644 --- a/resources/images/desktop/info_setup.svg +++ b/resources/images/desktop/info_setup.svg @@ -1,4 +1,7 @@ - + + diff --git a/resources/images/desktop/pin-letter-page1.png b/resources/images/desktop/pin-letter-page1.png deleted file mode 100644 index b634c51cc..000000000 Binary files a/resources/images/desktop/pin-letter-page1.png and /dev/null differ diff --git a/resources/images/desktop/pin-letter-page2.png b/resources/images/desktop/pin-letter-page2.png deleted file mode 100644 index 78ae175fc..000000000 Binary files a/resources/images/desktop/pin-letter-page2.png and /dev/null differ diff --git a/resources/images/desktop/pin_letter_pinpuk_different_page.svg b/resources/images/desktop/pin_letter_pinpuk_different_page.svg new file mode 100644 index 000000000..e93f2c764 --- /dev/null +++ b/resources/images/desktop/pin_letter_pinpuk_different_page.svg @@ -0,0 +1,96 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + PIN + + + + + + + + + + + 1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + PUK + + + + + + + + + + + 2 + + diff --git a/resources/images/desktop/pin_letter_pinpuk_same_page.svg b/resources/images/desktop/pin_letter_pinpuk_same_page.svg new file mode 100644 index 000000000..6106cf363 --- /dev/null +++ b/resources/images/desktop/pin_letter_pinpuk_same_page.svg @@ -0,0 +1,85 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1 + + + + + + + + + + + + + + + PIN + PUK + + + + + + + + + + + + + + + + 2 + + diff --git a/resources/images/desktop/sandglass.svg b/resources/images/desktop/sandglass.svg index b0a3f3a09..d4f09a243 100755 --- a/resources/images/desktop/sandglass.svg +++ b/resources/images/desktop/sandglass.svg @@ -2,12 +2,12 @@ - - + + - + diff --git a/resources/images/desktop/settings_icon.svg b/resources/images/desktop/settings_icon.svg deleted file mode 100644 index 6de95126e..000000000 --- a/resources/images/desktop/settings_icon.svg +++ /dev/null @@ -1,80 +0,0 @@ - - - - - - - - diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20.png index 0d1f00400..12126baa5 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@2x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@2x.png index 26882a754..df75ac1c8 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@2x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@2x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@3x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@3x.png index a62ff8738..39b302550 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@3x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon20@3x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@2x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@2x.png index 77a048ac6..9fc30ac68 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@2x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@2x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@3x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@3x.png index 0b673858a..4420fd19c 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@3x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon60@3x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76.png index 5c30d2638..1a9ddbf74 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76@2x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76@2x.png index dec038531..d1e40d5b6 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76@2x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon76@2x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png index 50f84a5cc..5a438cb67 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall.png index 76b5ff0bc..c423a4d35 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40.png index 26882a754..df75ac1c8 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png index 22a7bbc8f..e2d1e75e8 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png index 77a048ac6..9fc30ac68 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png index d14b925c2..f4d5c8af7 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png differ diff --git a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png index 9edc4b42f..3ebf7552a 100644 Binary files a/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png and b/resources/images/iOS/appIcons/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20.png index a47884f58..a58481e0c 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@2x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@2x.png index ec81e49d7..14f14a357 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@2x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@2x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@3x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@3x.png index 7b68e5934..f9ab210e7 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@3x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon20@3x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@2x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@2x.png index 401bb7382..93a9d1e2f 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@2x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@2x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@3x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@3x.png index 46b220c4d..b44743a6f 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@3x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon60@3x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76.png index a746ad666..6d5e2ca93 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76@2x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76@2x.png index 2c0bea27c..9b663286e 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76@2x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon76@2x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png index fe5232421..e23bb2efb 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/icon83.5@2x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall.png index 4c6067f9e..3b14dad5e 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40.png index ec81e49d7..14f14a357 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png index c36f6d6ae..f162041e2 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@2x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png index 401bb7382..93a9d1e2f 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall40@3x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png index 9988c1380..9ca690891 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@2x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png index e6c6d18b5..20272e5b0 100644 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/AppIcon.appiconset/iconSmall@3x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage.png b/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage.png old mode 100755 new mode 100644 index 8332ab1ea..ba97c871f Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@2x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@2x.png old mode 100755 new mode 100644 index 0cabe4137..e675a0087 Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@2x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@2x.png differ diff --git a/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@3x.png b/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@3x.png old mode 100755 new mode 100644 index 280579ce8..50912000d Binary files a/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@3x.png and b/resources/images/iOS/appIcons/beta/Images.xcassets/LaunchImage.imageset/launchImage@3x.png differ diff --git a/resources/images/iOS/more/icon_mehr_favorit.svg b/resources/images/iOS/more/icon_mehr_favorit.svg index 248aff045..b5950e331 100644 --- a/resources/images/iOS/more/icon_mehr_favorit.svg +++ b/resources/images/iOS/more/icon_mehr_favorit.svg @@ -2,7 +2,7 @@ - + - + diff --git a/resources/images/iOS/more/icon_mehr_info.svg b/resources/images/iOS/more/icon_mehr_info.svg index 4a4db94a6..5b5008a60 100644 --- a/resources/images/iOS/more/icon_mehr_info.svg +++ b/resources/images/iOS/more/icon_mehr_info.svg @@ -2,7 +2,7 @@ - + diff --git a/resources/images/iOS/more/icon_mehr_license.svg b/resources/images/iOS/more/icon_mehr_license.svg index d43dc87e2..2f8f4d113 100644 --- a/resources/images/iOS/more/icon_mehr_license.svg +++ b/resources/images/iOS/more/icon_mehr_license.svg @@ -2,7 +2,7 @@ - + diff --git a/resources/images/iOS/more/icon_mehr_log.svg b/resources/images/iOS/more/icon_mehr_log.svg index cac5ce01b..39f42cb5e 100644 --- a/resources/images/iOS/more/icon_mehr_log.svg +++ b/resources/images/iOS/more/icon_mehr_log.svg @@ -2,7 +2,7 @@ - + diff --git a/resources/images/iOS/more/icon_mehr_npa.svg b/resources/images/iOS/more/icon_mehr_npa.svg index fb1935b93..8c65200da 100644 --- a/resources/images/iOS/more/icon_mehr_npa.svg +++ b/resources/images/iOS/more/icon_mehr_npa.svg @@ -2,7 +2,7 @@ - + diff --git a/resources/images/iOS/more/icon_mehr_report.svg b/resources/images/iOS/more/icon_mehr_report.svg index d98ef329c..ca397cfbb 100644 --- a/resources/images/iOS/more/icon_mehr_report.svg +++ b/resources/images/iOS/more/icon_mehr_report.svg @@ -2,7 +2,7 @@ - + diff --git a/resources/images/iOS/more/icon_mehr_settings.svg b/resources/images/iOS/more/icon_mehr_settings.svg new file mode 100644 index 000000000..57f746b24 --- /dev/null +++ b/resources/images/iOS/more/icon_mehr_settings.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/resources/images/iOS/more/icon_mehr_tutorial.svg b/resources/images/iOS/more/icon_mehr_tutorial.svg index 6b5064646..d5c56959c 100644 --- a/resources/images/iOS/more/icon_mehr_tutorial.svg +++ b/resources/images/iOS/more/icon_mehr_tutorial.svg @@ -2,7 +2,7 @@ - + diff --git a/resources/images/iOS/more/icon_mehr_upload.svg b/resources/images/iOS/more/icon_mehr_upload.svg index 1447cfe9c..2863bcca4 100644 --- a/resources/images/iOS/more/icon_mehr_upload.svg +++ b/resources/images/iOS/more/icon_mehr_upload.svg @@ -2,12 +2,12 @@ - + - + diff --git a/resources/images/iOS/more/icon_mehr_verlauf.svg b/resources/images/iOS/more/icon_mehr_verlauf.svg index 7072ed0a8..53f4c064c 100644 --- a/resources/images/iOS/more/icon_mehr_verlauf.svg +++ b/resources/images/iOS/more/icon_mehr_verlauf.svg @@ -5,7 +5,7 @@ id="defs19" /> - + diff --git a/resources/images/iOS/tabBar/anbieter.svg b/resources/images/iOS/tabBar/anbieter.svg deleted file mode 100644 index 11b0a22c9..000000000 --- a/resources/images/iOS/tabBar/anbieter.svg +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - diff --git a/resources/images/iOS/tabBar/pin.svg b/resources/images/iOS/tabBar/pin.svg deleted file mode 100644 index 85287683c..000000000 --- a/resources/images/iOS/tabBar/pin.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/resources/images/icon_Pin.svg b/resources/images/icon_Pin.svg index 7a8ed05ea..2054f0e68 100644 --- a/resources/images/icon_Pin.svg +++ b/resources/images/icon_Pin.svg @@ -1,6 +1,6 @@ - - - + + + diff --git a/resources/images/icon_bluetooth.svg b/resources/images/icon_bluetooth.svg index 2590c485b..b10003347 100644 --- a/resources/images/icon_bluetooth.svg +++ b/resources/images/icon_bluetooth.svg @@ -1,7 +1,7 @@ - + diff --git a/resources/images/icon_nfc.svg b/resources/images/icon_nfc.svg index fe01d4c32..5bd826fd8 100644 --- a/resources/images/icon_nfc.svg +++ b/resources/images/icon_nfc.svg @@ -1,5 +1,5 @@ - + diff --git a/resources/images/icon_pair.svg b/resources/images/icon_pair.svg deleted file mode 100644 index 54005a383..000000000 --- a/resources/images/icon_pair.svg +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/resources/images/icon_remote.svg b/resources/images/icon_remote.svg index 6f7223fd4..203bc3459 100644 --- a/resources/images/icon_remote.svg +++ b/resources/images/icon_remote.svg @@ -6,6 +6,6 @@ - + diff --git a/resources/images/icon_settings.svg b/resources/images/icon_settings.svg deleted file mode 100644 index 0f4b57b7a..000000000 --- a/resources/images/icon_settings.svg +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - - - diff --git a/resources/images/link_external.svg b/resources/images/link_external.svg new file mode 100644 index 000000000..14cec7663 --- /dev/null +++ b/resources/images/link_external.svg @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/resources/images/desktop/main_pin.svg b/resources/images/main_pin.svg similarity index 69% rename from resources/images/desktop/main_pin.svg rename to resources/images/main_pin.svg index 113cff42e..8dc825f79 100644 --- a/resources/images/desktop/main_pin.svg +++ b/resources/images/main_pin.svg @@ -2,8 +2,7 @@ + M 565 750 a 50 50 0 1 0 -40 0 l -20 100 h 80 z" /> diff --git a/resources/images/desktop/main_provider.svg b/resources/images/main_provider.svg similarity index 86% rename from resources/images/desktop/main_provider.svg rename to resources/images/main_provider.svg index 2252adb21..e7d8a8f8d 100644 --- a/resources/images/desktop/main_provider.svg +++ b/resources/images/main_provider.svg @@ -2,7 +2,7 @@ diff --git a/resources/images/npa.ico b/resources/images/npa.ico index c539c4434..f591f2f1b 100644 Binary files a/resources/images/npa.ico and b/resources/images/npa.ico differ diff --git a/resources/images/android/npa_preview.svg b/resources/images/npa_bar.svg similarity index 75% rename from resources/images/android/npa_preview.svg rename to resources/images/npa_bar.svg index f99cc1bc5..420539e03 100644 --- a/resources/images/android/npa_preview.svg +++ b/resources/images/npa_bar.svg @@ -1,41 +1,21 @@ - - - - - - - - - - - - - - - - - + + + + + - - - - - + + + - + - - + + - - - - - - - - PREVIEW - - - - - - - - - - - - diff --git a/resources/images/npa_circle.svg b/resources/images/npa_circle.svg new file mode 100644 index 000000000..325549b00 --- /dev/null +++ b/resources/images/npa_circle.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/resources/images/phone_bluetooth.svg b/resources/images/phone_bluetooth.svg index 4c59fec29..40a762302 100644 --- a/resources/images/phone_bluetooth.svg +++ b/resources/images/phone_bluetooth.svg @@ -6,7 +6,7 @@ - + diff --git a/resources/images/phone_nfc.svg b/resources/images/phone_nfc.svg index 54d8beedd..0ea30bcb9 100644 --- a/resources/images/phone_nfc.svg +++ b/resources/images/phone_nfc.svg @@ -3,11 +3,11 @@ - + - + diff --git a/resources/images/phone_remote.svg b/resources/images/phone_remote.svg index 0940f497a..af1b418c6 100644 --- a/resources/images/phone_remote.svg +++ b/resources/images/phone_remote.svg @@ -7,7 +7,7 @@ - + diff --git a/resources/images/phone_to_pc.svg b/resources/images/phone_to_pc.svg index 486ebb955..e3f8906df 100644 --- a/resources/images/phone_to_pc.svg +++ b/resources/images/phone_to_pc.svg @@ -3,11 +3,11 @@ - + - + diff --git a/resources/images/provider/categoryIcons/+android/citizen.svg b/resources/images/provider/categoryIcons/+android/citizen.svg index d7d090213..b1343abb9 100644 --- a/resources/images/provider/categoryIcons/+android/citizen.svg +++ b/resources/images/provider/categoryIcons/+android/citizen.svg @@ -6,7 +6,7 @@ - + diff --git a/resources/images/provider/categoryIcons/+android/citizen_bg.svg b/resources/images/provider/categoryIcons/+android/citizen_bg.svg index dba2a5b5c..9c3f28ae5 100644 --- a/resources/images/provider/categoryIcons/+android/citizen_bg.svg +++ b/resources/images/provider/categoryIcons/+android/citizen_bg.svg @@ -6,7 +6,7 @@ - + diff --git a/resources/images/provider/categoryIcons/+android/citizen_button.svg b/resources/images/provider/categoryIcons/+android/citizen_button.svg index a8bdbe609..0798e5c5d 100644 --- a/resources/images/provider/categoryIcons/+android/citizen_button.svg +++ b/resources/images/provider/categoryIcons/+android/citizen_button.svg @@ -7,7 +7,7 @@ - + diff --git a/resources/images/provider/categoryIcons/+android/citizen_section.svg b/resources/images/provider/categoryIcons/+android/citizen_section.svg deleted file mode 100644 index ac0abad31..000000000 --- a/resources/images/provider/categoryIcons/+android/citizen_section.svg +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - diff --git a/resources/images/provider/categoryIcons/+android/default_bg.svg b/resources/images/provider/categoryIcons/+android/default_bg.svg new file mode 100644 index 000000000..f7e7f0b2a --- /dev/null +++ b/resources/images/provider/categoryIcons/+android/default_bg.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/resources/images/provider/categoryIcons/+android/finance.svg b/resources/images/provider/categoryIcons/+android/finance.svg index 9affec017..873a09c50 100644 --- a/resources/images/provider/categoryIcons/+android/finance.svg +++ b/resources/images/provider/categoryIcons/+android/finance.svg @@ -3,11 +3,11 @@ - + - + - + diff --git a/resources/images/provider/categoryIcons/+android/finance_bg.svg b/resources/images/provider/categoryIcons/+android/finance_bg.svg index 66f2d698c..b98f4718d 100644 --- a/resources/images/provider/categoryIcons/+android/finance_bg.svg +++ b/resources/images/provider/categoryIcons/+android/finance_bg.svg @@ -3,16 +3,16 @@ - - + + - + - + - + diff --git a/resources/images/provider/categoryIcons/+android/finance_button.svg b/resources/images/provider/categoryIcons/+android/finance_button.svg index edfacb36b..9515bed7e 100644 --- a/resources/images/provider/categoryIcons/+android/finance_button.svg +++ b/resources/images/provider/categoryIcons/+android/finance_button.svg @@ -4,8 +4,8 @@ - + - + diff --git a/resources/images/provider/categoryIcons/+android/finance_section.svg b/resources/images/provider/categoryIcons/+android/finance_section.svg deleted file mode 100644 index 979985f04..000000000 --- a/resources/images/provider/categoryIcons/+android/finance_section.svg +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - - - - - diff --git a/resources/images/provider/categoryIcons/+android/general.svg b/resources/images/provider/categoryIcons/+android/general.svg index 5eff07da2..0dc8fbc46 100644 --- a/resources/images/provider/categoryIcons/+android/general.svg +++ b/resources/images/provider/categoryIcons/+android/general.svg @@ -1,14 +1,11 @@ - - - - - - - - - - + + + diff --git a/resources/images/provider/categoryIcons/+android/general_bg.svg b/resources/images/provider/categoryIcons/+android/general_bg.svg index 82022a804..6cd9f5770 100644 --- a/resources/images/provider/categoryIcons/+android/general_bg.svg +++ b/resources/images/provider/categoryIcons/+android/general_bg.svg @@ -2,10 +2,17 @@ - - + + - + + + + diff --git a/resources/images/provider/categoryIcons/+android/general_button.svg b/resources/images/provider/categoryIcons/+android/general_button.svg index 7979f02f2..3ad70dd0b 100644 --- a/resources/images/provider/categoryIcons/+android/general_button.svg +++ b/resources/images/provider/categoryIcons/+android/general_button.svg @@ -1,12 +1,11 @@ - - - - - - - - + + + diff --git a/resources/images/provider/categoryIcons/+android/general_section.svg b/resources/images/provider/categoryIcons/+android/general_section.svg deleted file mode 100644 index b78d990fe..000000000 --- a/resources/images/provider/categoryIcons/+android/general_section.svg +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - diff --git a/resources/images/provider/categoryIcons/+android/insurance.svg b/resources/images/provider/categoryIcons/+android/insurance.svg index 5cb427687..fef881f2b 100644 --- a/resources/images/provider/categoryIcons/+android/insurance.svg +++ b/resources/images/provider/categoryIcons/+android/insurance.svg @@ -3,7 +3,7 @@ - + diff --git a/resources/images/provider/categoryIcons/+android/insurance_bg.svg b/resources/images/provider/categoryIcons/+android/insurance_bg.svg index aaf40b0f6..e2e567c4e 100644 --- a/resources/images/provider/categoryIcons/+android/insurance_bg.svg +++ b/resources/images/provider/categoryIcons/+android/insurance_bg.svg @@ -3,7 +3,7 @@ - + diff --git a/resources/images/provider/categoryIcons/+android/insurance_button.svg b/resources/images/provider/categoryIcons/+android/insurance_button.svg index c3f3c0005..cc23024af 100644 --- a/resources/images/provider/categoryIcons/+android/insurance_button.svg +++ b/resources/images/provider/categoryIcons/+android/insurance_button.svg @@ -4,7 +4,7 @@ - + - + diff --git a/resources/images/provider/categoryIcons/+android/insurance_section.svg b/resources/images/provider/categoryIcons/+android/insurance_section.svg deleted file mode 100644 index cf4e961d3..000000000 --- a/resources/images/provider/categoryIcons/+android/insurance_section.svg +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/resources/images/provider/categoryIcons/+android/other.svg b/resources/images/provider/categoryIcons/+android/other.svg index e4bc6dd98..dd1d518bf 100644 --- a/resources/images/provider/categoryIcons/+android/other.svg +++ b/resources/images/provider/categoryIcons/+android/other.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/provider/categoryIcons/+android/other_bg.svg b/resources/images/provider/categoryIcons/+android/other_bg.svg index a8e32f305..cbbcdad24 100644 --- a/resources/images/provider/categoryIcons/+android/other_bg.svg +++ b/resources/images/provider/categoryIcons/+android/other_bg.svg @@ -2,12 +2,12 @@ - + - + diff --git a/resources/images/provider/categoryIcons/+android/other_button.svg b/resources/images/provider/categoryIcons/+android/other_button.svg index e90c1c3ca..a6afc7b69 100644 --- a/resources/images/provider/categoryIcons/+android/other_button.svg +++ b/resources/images/provider/categoryIcons/+android/other_button.svg @@ -1,5 +1,5 @@ - + diff --git a/resources/images/provider/categoryIcons/+android/other_section.svg b/resources/images/provider/categoryIcons/+android/other_section.svg deleted file mode 100644 index b6dda66d3..000000000 --- a/resources/images/provider/categoryIcons/+android/other_section.svg +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - - - diff --git a/resources/images/provider/categoryIcons/citizen.svg b/resources/images/provider/categoryIcons/citizen.svg index 590db160a..57fa499ae 100644 --- a/resources/images/provider/categoryIcons/citizen.svg +++ b/resources/images/provider/categoryIcons/citizen.svg @@ -6,7 +6,7 @@ - + diff --git a/resources/images/provider/categoryIcons/finance.svg b/resources/images/provider/categoryIcons/finance.svg index a88407309..ec5cb2b6a 100644 --- a/resources/images/provider/categoryIcons/finance.svg +++ b/resources/images/provider/categoryIcons/finance.svg @@ -3,16 +3,16 @@ - - + + - + - + - + diff --git a/resources/images/provider/categoryIcons/general.svg b/resources/images/provider/categoryIcons/general.svg index f163c3615..5d4c05863 100644 --- a/resources/images/provider/categoryIcons/general.svg +++ b/resources/images/provider/categoryIcons/general.svg @@ -2,20 +2,17 @@ - - + + - - - - - - - - - - + + + diff --git a/resources/images/provider/categoryIcons/insurance.svg b/resources/images/provider/categoryIcons/insurance.svg index 7a9a34160..98d2696de 100644 --- a/resources/images/provider/categoryIcons/insurance.svg +++ b/resources/images/provider/categoryIcons/insurance.svg @@ -3,7 +3,7 @@ - + diff --git a/resources/images/provider/categoryIcons/other.svg b/resources/images/provider/categoryIcons/other.svg index c5a6b7eee..74a90dc38 100644 --- a/resources/images/provider/categoryIcons/other.svg +++ b/resources/images/provider/categoryIcons/other.svg @@ -2,12 +2,12 @@ - + - + diff --git a/resources/images/provider/gradient-citizen.png b/resources/images/provider/gradient-citizen.png deleted file mode 100644 index a648aedc0..000000000 Binary files a/resources/images/provider/gradient-citizen.png and /dev/null differ diff --git a/resources/images/provider/gradient-finance.png b/resources/images/provider/gradient-finance.png deleted file mode 100644 index 6fc65f7a2..000000000 Binary files a/resources/images/provider/gradient-finance.png and /dev/null differ diff --git a/resources/images/provider/gradient-insurance.png b/resources/images/provider/gradient-insurance.png deleted file mode 100644 index 32b7c6924..000000000 Binary files a/resources/images/provider/gradient-insurance.png and /dev/null differ diff --git a/resources/images/provider/gradient-other.png b/resources/images/provider/gradient-other.png deleted file mode 100644 index 2b25f22a3..000000000 Binary files a/resources/images/provider/gradient-other.png and /dev/null differ diff --git a/resources/images/reader/src/img_PersoSim.svg b/resources/images/reader/src/img_PersoSim.svg new file mode 100644 index 000000000..7d0163b2b --- /dev/null +++ b/resources/images/reader/src/img_PersoSim.svg @@ -0,0 +1,5 @@ + + + + PersoSim + diff --git a/resources/images/reader/src/img_PersoSim_mit_ausweis.svg b/resources/images/reader/src/img_PersoSim_mit_ausweis.svg new file mode 100644 index 000000000..b387aab81 --- /dev/null +++ b/resources/images/reader/src/img_PersoSim_mit_ausweis.svg @@ -0,0 +1,6 @@ + + + + PersoSim + + diff --git a/resources/images/reader/src/img_Remote_Display.png b/resources/images/reader/src/img_Remote_Display.png index bb30187a6..4cfbd54bb 100644 Binary files a/resources/images/reader/src/img_Remote_Display.png and b/resources/images/reader/src/img_Remote_Display.png differ diff --git a/resources/images/settings_icon.svg b/resources/images/settings_icon.svg new file mode 100644 index 000000000..e0e1e11cc --- /dev/null +++ b/resources/images/settings_icon.svg @@ -0,0 +1,50 @@ + + + + + diff --git a/resources/images/status_info.svg b/resources/images/status_info.svg index 3a8f58743..97067bc8b 100644 --- a/resources/images/status_info.svg +++ b/resources/images/status_info.svg @@ -1,5 +1,5 @@ - - + + diff --git a/resources/images/tutorial/arrow_blue.svg b/resources/images/tutorial/arrow_blue.svg index a6b6125ff..04265299a 100644 --- a/resources/images/tutorial/arrow_blue.svg +++ b/resources/images/tutorial/arrow_blue.svg @@ -7,7 +7,7 @@ - + diff --git a/resources/images/tutorial/generated/how_desktop.svg b/resources/images/tutorial/generated/how_desktop.svg index d04c9e8d8..cca42124b 100644 --- a/resources/images/tutorial/generated/how_desktop.svg +++ b/resources/images/tutorial/generated/how_desktop.svg @@ -2,20 +2,20 @@ - + - + - + - + diff --git a/resources/images/tutorial/generated/how_device_lineup.svg b/resources/images/tutorial/generated/how_device_lineup.svg index 8c29283b5..d86f9b15e 100644 --- a/resources/images/tutorial/generated/how_device_lineup.svg +++ b/resources/images/tutorial/generated/how_device_lineup.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/generated/how_idcard_cycle.svg b/resources/images/tutorial/generated/how_idcard_cycle.svg index df4a3ce67..d7f9d1805 100644 --- a/resources/images/tutorial/generated/how_idcard_cycle.svg +++ b/resources/images/tutorial/generated/how_idcard_cycle.svg @@ -2,5 +2,5 @@ - + diff --git a/resources/images/tutorial/generated/how_method_bluetooth.svg b/resources/images/tutorial/generated/how_method_bluetooth.svg index 03acc3047..16f290c7d 100644 --- a/resources/images/tutorial/generated/how_method_bluetooth.svg +++ b/resources/images/tutorial/generated/how_method_bluetooth.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/generated/how_method_nfc.svg b/resources/images/tutorial/generated/how_method_nfc.svg index 96f4930b6..43a3efee5 100644 --- a/resources/images/tutorial/generated/how_method_nfc.svg +++ b/resources/images/tutorial/generated/how_method_nfc.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/generated/how_method_sac_desktop.svg b/resources/images/tutorial/generated/how_method_sac_desktop.svg index 2239b3b88..3db7b9204 100644 --- a/resources/images/tutorial/generated/how_method_sac_desktop.svg +++ b/resources/images/tutorial/generated/how_method_sac_desktop.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/generated/how_method_sac_mobile.svg b/resources/images/tutorial/generated/how_method_sac_mobile.svg index 0d685d328..f967e20f8 100644 --- a/resources/images/tutorial/generated/how_method_sac_mobile.svg +++ b/resources/images/tutorial/generated/how_method_sac_mobile.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/generated/how_questions_everywhere.svg b/resources/images/tutorial/generated/how_questions_everywhere.svg index d20926d5d..31c3756e0 100644 --- a/resources/images/tutorial/generated/how_questions_everywhere.svg +++ b/resources/images/tutorial/generated/how_questions_everywhere.svg @@ -2,7 +2,7 @@ - + diff --git a/resources/images/tutorial/generated/reader_bluetooth_card_inserted.svg b/resources/images/tutorial/generated/reader_bluetooth_card_inserted.svg index 80691e67f..288c51775 100644 --- a/resources/images/tutorial/generated/reader_bluetooth_card_inserted.svg +++ b/resources/images/tutorial/generated/reader_bluetooth_card_inserted.svg @@ -1,5 +1,5 @@ - + diff --git a/resources/images/tutorial/generated/reader_nfc_finished.svg b/resources/images/tutorial/generated/reader_nfc_finished.svg index ebc1c94bd..f36bcc3a0 100644 --- a/resources/images/tutorial/generated/reader_nfc_finished.svg +++ b/resources/images/tutorial/generated/reader_nfc_finished.svg @@ -1,5 +1,5 @@ - + diff --git a/resources/images/tutorial/generated/reader_nfc_smartphone_nfc_position.svg b/resources/images/tutorial/generated/reader_nfc_smartphone_nfc_position.svg index 0c1e07f63..98ad90244 100644 --- a/resources/images/tutorial/generated/reader_nfc_smartphone_nfc_position.svg +++ b/resources/images/tutorial/generated/reader_nfc_smartphone_nfc_position.svg @@ -3,22 +3,22 @@ NFC? NFC? NFC? NFC? diff --git a/resources/images/tutorial/generated/reader_nfc_userdata_example_de.svg b/resources/images/tutorial/generated/reader_nfc_userdata_example_de.svg index 8279abdb4..70713ebec 100644 --- a/resources/images/tutorial/generated/reader_nfc_userdata_example_de.svg +++ b/resources/images/tutorial/generated/reader_nfc_userdata_example_de.svg @@ -12,7 +12,7 @@ - + Zum Beispiel Name? Vorname? diff --git a/resources/images/tutorial/generated/reader_nfc_userdata_example_en.svg b/resources/images/tutorial/generated/reader_nfc_userdata_example_en.svg index 37a7e763c..9e9809e7c 100644 --- a/resources/images/tutorial/generated/reader_nfc_userdata_example_en.svg +++ b/resources/images/tutorial/generated/reader_nfc_userdata_example_en.svg @@ -12,7 +12,7 @@ - + For Example Surname? Given Name? diff --git a/resources/images/tutorial/generated/reader_sac_menu_android_de.svg b/resources/images/tutorial/generated/reader_sac_menu_android_de.svg index 054c1955a..8c7e6451d 100644 --- a/resources/images/tutorial/generated/reader_sac_menu_android_de.svg +++ b/resources/images/tutorial/generated/reader_sac_menu_android_de.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/generated/reader_sac_menu_android_en.svg b/resources/images/tutorial/generated/reader_sac_menu_android_en.svg index 8796870f4..f2293555a 100644 --- a/resources/images/tutorial/generated/reader_sac_menu_android_en.svg +++ b/resources/images/tutorial/generated/reader_sac_menu_android_en.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/generated/where_lay_down_id.svg b/resources/images/tutorial/generated/where_lay_down_id.svg index d3693bd37..6d9e45911 100644 --- a/resources/images/tutorial/generated/where_lay_down_id.svg +++ b/resources/images/tutorial/generated/where_lay_down_id.svg @@ -1,5 +1,5 @@ - + diff --git a/resources/images/tutorial/generated/where_overview_question.svg b/resources/images/tutorial/generated/where_overview_question.svg index 1ea069ffc..201594ad1 100644 --- a/resources/images/tutorial/generated/where_overview_question.svg +++ b/resources/images/tutorial/generated/where_overview_question.svg @@ -4,6 +4,6 @@ - + diff --git a/resources/images/tutorial/generated/where_userdata_example_de.svg b/resources/images/tutorial/generated/where_userdata_example_de.svg index 5b1d34b87..798252920 100644 --- a/resources/images/tutorial/generated/where_userdata_example_de.svg +++ b/resources/images/tutorial/generated/where_userdata_example_de.svg @@ -12,7 +12,7 @@ - + Zum Beispiel Name? diff --git a/resources/images/tutorial/generated/where_userdata_example_en.svg b/resources/images/tutorial/generated/where_userdata_example_en.svg index c3d77f3cc..a7b5d51b0 100644 --- a/resources/images/tutorial/generated/where_userdata_example_en.svg +++ b/resources/images/tutorial/generated/where_userdata_example_en.svg @@ -12,7 +12,7 @@ - + For Example Surname? diff --git a/resources/images/tutorial/idcard.svg b/resources/images/tutorial/idcard.svg deleted file mode 100644 index d83f08024..000000000 --- a/resources/images/tutorial/idcard.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/resources/images/tutorial/main_menu_how_caret.svg b/resources/images/tutorial/main_menu_how_caret.svg index ecb1aef2b..389215573 100644 --- a/resources/images/tutorial/main_menu_how_caret.svg +++ b/resources/images/tutorial/main_menu_how_caret.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/phone_list.svg b/resources/images/tutorial/phone_list.svg index ea011fc5a..fdb8db93b 100755 --- a/resources/images/tutorial/phone_list.svg +++ b/resources/images/tutorial/phone_list.svg @@ -7,8 +7,8 @@ - - + + diff --git a/resources/images/tutorial/screenshot_cert_android_de.png b/resources/images/tutorial/screenshot_cert_android_de.png index b5a66a5cd..c0fe7744e 100644 Binary files a/resources/images/tutorial/screenshot_cert_android_de.png and b/resources/images/tutorial/screenshot_cert_android_de.png differ diff --git a/resources/images/tutorial/screenshot_cert_android_en.png b/resources/images/tutorial/screenshot_cert_android_en.png index fbe0358a0..9012f5d48 100644 Binary files a/resources/images/tutorial/screenshot_cert_android_en.png and b/resources/images/tutorial/screenshot_cert_android_en.png differ diff --git a/resources/images/tutorial/screenshot_cert_ios_de.png b/resources/images/tutorial/screenshot_cert_ios_de.png index 5ac642d42..602060505 100644 Binary files a/resources/images/tutorial/screenshot_cert_ios_de.png and b/resources/images/tutorial/screenshot_cert_ios_de.png differ diff --git a/resources/images/tutorial/screenshot_cert_ios_en.png b/resources/images/tutorial/screenshot_cert_ios_en.png index 597ee9d14..21feddcf8 100644 Binary files a/resources/images/tutorial/screenshot_cert_ios_en.png and b/resources/images/tutorial/screenshot_cert_ios_en.png differ diff --git a/resources/images/tutorial/screenshot_choose_reader_android_de.png b/resources/images/tutorial/screenshot_choose_reader_android_de.png index 1aed789d5..9ec353983 100644 Binary files a/resources/images/tutorial/screenshot_choose_reader_android_de.png and b/resources/images/tutorial/screenshot_choose_reader_android_de.png differ diff --git a/resources/images/tutorial/screenshot_choose_reader_android_en.png b/resources/images/tutorial/screenshot_choose_reader_android_en.png index 71a315629..f1ae02156 100644 Binary files a/resources/images/tutorial/screenshot_choose_reader_android_en.png and b/resources/images/tutorial/screenshot_choose_reader_android_en.png differ diff --git a/resources/images/tutorial/screenshot_choose_reader_ios_de.png b/resources/images/tutorial/screenshot_choose_reader_ios_de.png index 8ef7580f0..3f8ad5d2b 100644 Binary files a/resources/images/tutorial/screenshot_choose_reader_ios_de.png and b/resources/images/tutorial/screenshot_choose_reader_ios_de.png differ diff --git a/resources/images/tutorial/screenshot_choose_reader_ios_en.png b/resources/images/tutorial/screenshot_choose_reader_ios_en.png index 0127f8125..5864eb12b 100644 Binary files a/resources/images/tutorial/screenshot_choose_reader_ios_en.png and b/resources/images/tutorial/screenshot_choose_reader_ios_en.png differ diff --git a/resources/images/tutorial/screenshot_menu_providerlist_android_de.png b/resources/images/tutorial/screenshot_menu_providerlist_android_de.png index 4c29d09bc..621089eb0 100644 Binary files a/resources/images/tutorial/screenshot_menu_providerlist_android_de.png and b/resources/images/tutorial/screenshot_menu_providerlist_android_de.png differ diff --git a/resources/images/tutorial/screenshot_menu_providerlist_android_en.png b/resources/images/tutorial/screenshot_menu_providerlist_android_en.png index 030c3030c..8901f925f 100644 Binary files a/resources/images/tutorial/screenshot_menu_providerlist_android_en.png and b/resources/images/tutorial/screenshot_menu_providerlist_android_en.png differ diff --git a/resources/images/tutorial/screenshot_pairing_de.png b/resources/images/tutorial/screenshot_pairing_de.png index ce26346b4..4ab432db8 100644 Binary files a/resources/images/tutorial/screenshot_pairing_de.png and b/resources/images/tutorial/screenshot_pairing_de.png differ diff --git a/resources/images/tutorial/screenshot_pairing_en.png b/resources/images/tutorial/screenshot_pairing_en.png index 85933f3c0..100678fba 100644 Binary files a/resources/images/tutorial/screenshot_pairing_en.png and b/resources/images/tutorial/screenshot_pairing_en.png differ diff --git a/resources/images/tutorial/screenshot_pin_management_menu_android_de.png b/resources/images/tutorial/screenshot_pin_management_menu_android_de.png index 89cc3f3c5..6da4296d0 100644 Binary files a/resources/images/tutorial/screenshot_pin_management_menu_android_de.png and b/resources/images/tutorial/screenshot_pin_management_menu_android_de.png differ diff --git a/resources/images/tutorial/screenshot_pin_management_menu_android_en.png b/resources/images/tutorial/screenshot_pin_management_menu_android_en.png index 12806051d..6e32509ec 100644 Binary files a/resources/images/tutorial/screenshot_pin_management_menu_android_en.png and b/resources/images/tutorial/screenshot_pin_management_menu_android_en.png differ diff --git a/resources/images/tutorial/screenshot_pin_management_menu_ios_de.png b/resources/images/tutorial/screenshot_pin_management_menu_ios_de.png old mode 100755 new mode 100644 index 16cf46eea..e567ce0d0 Binary files a/resources/images/tutorial/screenshot_pin_management_menu_ios_de.png and b/resources/images/tutorial/screenshot_pin_management_menu_ios_de.png differ diff --git a/resources/images/tutorial/screenshot_pin_management_menu_ios_en.png b/resources/images/tutorial/screenshot_pin_management_menu_ios_en.png old mode 100755 new mode 100644 index b78ef3d7a..b3c58013d Binary files a/resources/images/tutorial/screenshot_pin_management_menu_ios_en.png and b/resources/images/tutorial/screenshot_pin_management_menu_ios_en.png differ diff --git a/resources/images/tutorial/screenshot_providerlist_android_de.png b/resources/images/tutorial/screenshot_providerlist_android_de.png index d42b0aad7..8d00024e3 100644 Binary files a/resources/images/tutorial/screenshot_providerlist_android_de.png and b/resources/images/tutorial/screenshot_providerlist_android_de.png differ diff --git a/resources/images/tutorial/screenshot_providerlist_android_en.png b/resources/images/tutorial/screenshot_providerlist_android_en.png index c1346c1de..5802aa00b 100644 Binary files a/resources/images/tutorial/screenshot_providerlist_android_en.png and b/resources/images/tutorial/screenshot_providerlist_android_en.png differ diff --git a/resources/images/tutorial/screenshot_providerlist_ios_de.png b/resources/images/tutorial/screenshot_providerlist_ios_de.png old mode 100755 new mode 100644 index 84ec73fe2..dabf89bfd Binary files a/resources/images/tutorial/screenshot_providerlist_ios_de.png and b/resources/images/tutorial/screenshot_providerlist_ios_de.png differ diff --git a/resources/images/tutorial/screenshot_providerlist_ios_en.png b/resources/images/tutorial/screenshot_providerlist_ios_en.png old mode 100755 new mode 100644 index 6874a4bb4..b0c28197f Binary files a/resources/images/tutorial/screenshot_providerlist_ios_en.png and b/resources/images/tutorial/screenshot_providerlist_ios_en.png differ diff --git a/resources/images/tutorial/screenshot_remoteservice_ios_de.png b/resources/images/tutorial/screenshot_remoteservice_ios_de.png old mode 100755 new mode 100644 index e5877978b..e264580e9 Binary files a/resources/images/tutorial/screenshot_remoteservice_ios_de.png and b/resources/images/tutorial/screenshot_remoteservice_ios_de.png differ diff --git a/resources/images/tutorial/screenshot_remoteservice_ios_en.png b/resources/images/tutorial/screenshot_remoteservice_ios_en.png old mode 100755 new mode 100644 index b61ab9963..0014ce199 Binary files a/resources/images/tutorial/screenshot_remoteservice_ios_en.png and b/resources/images/tutorial/screenshot_remoteservice_ios_en.png differ diff --git a/resources/images/tutorial/screenshot_sac_menu_android_de.png b/resources/images/tutorial/screenshot_sac_menu_android_de.png index 85884fce0..c023dfffe 100644 Binary files a/resources/images/tutorial/screenshot_sac_menu_android_de.png and b/resources/images/tutorial/screenshot_sac_menu_android_de.png differ diff --git a/resources/images/tutorial/screenshot_sac_menu_android_en.png b/resources/images/tutorial/screenshot_sac_menu_android_en.png index 1bb3b25e2..feefb58e0 100644 Binary files a/resources/images/tutorial/screenshot_sac_menu_android_en.png and b/resources/images/tutorial/screenshot_sac_menu_android_en.png differ diff --git a/resources/images/tutorial/section_seperator_how.svg b/resources/images/tutorial/section_seperator_how.svg index d3b4c020b..abc4712b2 100644 --- a/resources/images/tutorial/section_seperator_how.svg +++ b/resources/images/tutorial/section_seperator_how.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/src/how_desktop.svg b/resources/images/tutorial/src/how_desktop.svg index 6a23bb9c1..1aeb198e9 100644 --- a/resources/images/tutorial/src/how_desktop.svg +++ b/resources/images/tutorial/src/how_desktop.svg @@ -2,20 +2,20 @@ - + - + - + - + diff --git a/resources/images/tutorial/src/how_device_lineup.svg b/resources/images/tutorial/src/how_device_lineup.svg index 2dde5f2b3..5bdcc3838 100644 --- a/resources/images/tutorial/src/how_device_lineup.svg +++ b/resources/images/tutorial/src/how_device_lineup.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/src/how_idcard_cycle.svg b/resources/images/tutorial/src/how_idcard_cycle.svg index b69f49fdf..90e9ce99f 100644 --- a/resources/images/tutorial/src/how_idcard_cycle.svg +++ b/resources/images/tutorial/src/how_idcard_cycle.svg @@ -2,5 +2,5 @@ - + diff --git a/resources/images/tutorial/src/how_method_bluetooth.svg b/resources/images/tutorial/src/how_method_bluetooth.svg index bc60bc550..cb2037f22 100644 --- a/resources/images/tutorial/src/how_method_bluetooth.svg +++ b/resources/images/tutorial/src/how_method_bluetooth.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/src/how_method_nfc.svg b/resources/images/tutorial/src/how_method_nfc.svg index e1ca760f3..c4db0b506 100644 --- a/resources/images/tutorial/src/how_method_nfc.svg +++ b/resources/images/tutorial/src/how_method_nfc.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/src/how_method_sac_desktop.svg b/resources/images/tutorial/src/how_method_sac_desktop.svg index 732f4806b..f86a5d486 100644 --- a/resources/images/tutorial/src/how_method_sac_desktop.svg +++ b/resources/images/tutorial/src/how_method_sac_desktop.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/src/how_method_sac_mobile.svg b/resources/images/tutorial/src/how_method_sac_mobile.svg index 3f2276bbe..151929fcc 100644 --- a/resources/images/tutorial/src/how_method_sac_mobile.svg +++ b/resources/images/tutorial/src/how_method_sac_mobile.svg @@ -1,6 +1,6 @@ - + diff --git a/resources/images/tutorial/src/how_questions_everywhere.svg b/resources/images/tutorial/src/how_questions_everywhere.svg index 74489d40c..84356aee9 100644 --- a/resources/images/tutorial/src/how_questions_everywhere.svg +++ b/resources/images/tutorial/src/how_questions_everywhere.svg @@ -2,7 +2,7 @@ - + diff --git a/resources/images/tutorial/src/reader_bluetooth_card_inserted.svg b/resources/images/tutorial/src/reader_bluetooth_card_inserted.svg index a8ac112ab..bb98bf99a 100644 --- a/resources/images/tutorial/src/reader_bluetooth_card_inserted.svg +++ b/resources/images/tutorial/src/reader_bluetooth_card_inserted.svg @@ -1,5 +1,5 @@ - + diff --git a/resources/images/tutorial/src/reader_nfc_finished.svg b/resources/images/tutorial/src/reader_nfc_finished.svg index 6e67f1c3e..d93571d7e 100644 --- a/resources/images/tutorial/src/reader_nfc_finished.svg +++ b/resources/images/tutorial/src/reader_nfc_finished.svg @@ -1,5 +1,5 @@ - + diff --git a/resources/images/tutorial/src/reader_nfc_smartphone_nfc_position.svg b/resources/images/tutorial/src/reader_nfc_smartphone_nfc_position.svg index 04e6e9301..9af71e061 100644 --- a/resources/images/tutorial/src/reader_nfc_smartphone_nfc_position.svg +++ b/resources/images/tutorial/src/reader_nfc_smartphone_nfc_position.svg @@ -3,22 +3,22 @@ NFC? NFC? NFC? NFC? diff --git a/resources/images/tutorial/src/reader_nfc_userdata_example_de.svg b/resources/images/tutorial/src/reader_nfc_userdata_example_de.svg index 174266e7d..28fb4c327 100644 --- a/resources/images/tutorial/src/reader_nfc_userdata_example_de.svg +++ b/resources/images/tutorial/src/reader_nfc_userdata_example_de.svg @@ -12,7 +12,7 @@ - + Zum Beispiel Name? Vorname? diff --git a/resources/images/tutorial/src/reader_nfc_userdata_example_en.svg b/resources/images/tutorial/src/reader_nfc_userdata_example_en.svg index 8276811c9..7bc05c05f 100644 --- a/resources/images/tutorial/src/reader_nfc_userdata_example_en.svg +++ b/resources/images/tutorial/src/reader_nfc_userdata_example_en.svg @@ -12,7 +12,7 @@ - + For Example Surname? Given Name? diff --git a/resources/images/tutorial/src/reader_sac_menu_android_de.svg b/resources/images/tutorial/src/reader_sac_menu_android_de.svg index 3b488345d..4f2130056 100644 --- a/resources/images/tutorial/src/reader_sac_menu_android_de.svg +++ b/resources/images/tutorial/src/reader_sac_menu_android_de.svg @@ -1,6 +1,6 @@ - - - + + + diff --git a/resources/images/tutorial/src/reader_sac_menu_android_en.svg b/resources/images/tutorial/src/reader_sac_menu_android_en.svg index 8d39c4a1c..6fb0b71e8 100644 --- a/resources/images/tutorial/src/reader_sac_menu_android_en.svg +++ b/resources/images/tutorial/src/reader_sac_menu_android_en.svg @@ -1,6 +1,6 @@ - - - + + + diff --git a/resources/images/tutorial/src/where_lay_down_id.svg b/resources/images/tutorial/src/where_lay_down_id.svg index 9304b115c..6abea6788 100644 --- a/resources/images/tutorial/src/where_lay_down_id.svg +++ b/resources/images/tutorial/src/where_lay_down_id.svg @@ -1,5 +1,5 @@ - + diff --git a/resources/images/tutorial/src/where_overview_question.svg b/resources/images/tutorial/src/where_overview_question.svg index 56cfbb0a8..c1c3cbdba 100644 --- a/resources/images/tutorial/src/where_overview_question.svg +++ b/resources/images/tutorial/src/where_overview_question.svg @@ -4,6 +4,6 @@ - + diff --git a/resources/images/tutorial/src/where_userdata_example_de.svg b/resources/images/tutorial/src/where_userdata_example_de.svg index fe0b08bb1..07c686bf8 100644 --- a/resources/images/tutorial/src/where_userdata_example_de.svg +++ b/resources/images/tutorial/src/where_userdata_example_de.svg @@ -12,7 +12,7 @@ - + Zum Beispiel Name? diff --git a/resources/images/tutorial/src/where_userdata_example_en.svg b/resources/images/tutorial/src/where_userdata_example_en.svg index a4dd021b4..942f160c8 100644 --- a/resources/images/tutorial/src/where_userdata_example_en.svg +++ b/resources/images/tutorial/src/where_userdata_example_en.svg @@ -12,7 +12,7 @@ - + For Example Surname? diff --git a/resources/images/visibility.svg b/resources/images/visibility.svg new file mode 100644 index 000000000..6d05adc41 --- /dev/null +++ b/resources/images/visibility.svg @@ -0,0 +1,7 @@ + + + + diff --git a/resources/images/visibility_off.svg b/resources/images/visibility_off.svg new file mode 100644 index 000000000..20ed3348c --- /dev/null +++ b/resources/images/visibility_off.svg @@ -0,0 +1,8 @@ + + + + diff --git a/resources/images/zahnraeder.svg b/resources/images/zahnraeder.svg deleted file mode 100644 index 6f4fe719f..000000000 --- a/resources/images/zahnraeder.svg +++ /dev/null @@ -1,80 +0,0 @@ - - - - - - - - diff --git a/resources/jenkins/docker/README.rst b/resources/jenkins/docker/README.rst deleted file mode 100644 index 849a6b4da..000000000 --- a/resources/jenkins/docker/README.rst +++ /dev/null @@ -1,24 +0,0 @@ -Jenkins Swarm -============= - -Diese Dockerfiles werden zum Generieren von Jenkins Agents -verwendet. Das Shellskript "generate.sh" erstellt alle -Docker Images anhand der Dockerfiles neu. - -Alle Basis-Images werden "FROM scratch" erzeugt. Dafür -ist es notwendig das "rootfs" manuell in die folgenden -Ordner zu kopieren. - -Alpine ------- - - https://alpinelinux.org/downloads/ - - alpine-minirootfs-*-x86_64.tar.gz - -Arch ----- - - https://mirrors.kernel.org/archlinux/iso/latest/ - - archlinux-bootstrap-*-x86_64.tar.gz - - - https://busybox.net/downloads/binaries/ - - busybox-x86_64 - diff --git a/resources/jenkins/docker/alpine/Dockerfile b/resources/jenkins/docker/alpine/Dockerfile deleted file mode 100644 index 79be345cb..000000000 --- a/resources/jenkins/docker/alpine/Dockerfile +++ /dev/null @@ -1,8 +0,0 @@ -FROM scratch -MAINTAINER Governikus KG - -ARG version="3.10.0" -ARG arch="x86_64" -ADD alpine-minirootfs-$version-$arch.tar.gz / - -RUN apk --no-cache upgrade diff --git a/resources/jenkins/docker/android/Dockerfile b/resources/jenkins/docker/android/Dockerfile new file mode 100644 index 000000000..ea438467f --- /dev/null +++ b/resources/jenkins/docker/android/Dockerfile @@ -0,0 +1,31 @@ +FROM ubuntu:swarm +MAINTAINER Governikus KG + +ARG ANDROID_SDK_TOOLS=4333796 +ARG ANDROID_NDK_VERSION=r18b +ENV NAME=Android LABELS="Android" PACKAGES_DIR=/home/governikus/packages + +RUN apt-get update && \ + apt-get -y install g++ cmake make ccache ninja-build perl unzip gradle maven patch openjdk-8-jdk-headless && \ + ln -s /usr/lib/jvm/java-8-openjdk-amd64 /usr/lib/jvm/java-8-openjdk && \ + rm -rf /var/lib/apt/lists/* + +ENV ANDROID_HOME /opt/android-sdk +RUN mkdir -p /tmp/dl/sdk && cd /tmp/dl/sdk && wget -O sdk.zip https://dl.google.com/android/repository/sdk-tools-linux-$ANDROID_SDK_TOOLS.zip && \ + unzip sdk.zip && mkdir -p $ANDROID_HOME && mv tools/ $ANDROID_HOME +RUN yes | $ANDROID_HOME/tools/bin/sdkmanager "build-tools;29.0.2" "platform-tools" "platforms;android-29" + +ENV ANDROID_NDK_HOME /opt/android-ndk +ENV ANDROID_NDK=${ANDROID_NDK_HOME} + +RUN mkdir -p /tmp/dl/ndk && \ + cd /tmp/dl/ndk && \ + wget -O ndk.zip https://dl.google.com/android/repository/android-ndk-${ANDROID_NDK_VERSION}-linux-x86_64.zip && \ + unzip ndk.zip && mv android-ndk-${ANDROID_NDK_VERSION} ${ANDROID_NDK} && \ + rm -rf /tmp/dl + +USER governikus +RUN mkdir -p /home/governikus/.ccache && mkdir -p /home/governikus/workspace && mkdir -p /home/governikus/packages + +ENTRYPOINT ["/usr/bin/tini", "--"] +CMD /swarm.sh diff --git a/resources/jenkins/docker/docs/Dockerfile b/resources/jenkins/docker/docs/Dockerfile index 5b21207fc..014cbc8ca 100644 --- a/resources/jenkins/docker/docs/Dockerfile +++ b/resources/jenkins/docker/docs/Dockerfile @@ -3,8 +3,8 @@ MAINTAINER Governikus KG ENV NAME=Docs LABELS=Docs -RUN apk --no-cache add cmake make py2-sphinx py2-setuptools py2-pip icu-libs poppler zziplib texlive-full && \ - pip install doc8 cloud_sptheme +RUN apk --no-cache add cmake make py3-sphinx py3-setuptools icu-libs poppler zziplib texlive-full && \ + pip3 install doc8 cloud_sptheme USER governikus diff --git a/resources/jenkins/docker/generate.py b/resources/jenkins/docker/generate.py index de27c7838..0c0bb2b10 100755 --- a/resources/jenkins/docker/generate.py +++ b/resources/jenkins/docker/generate.py @@ -1,6 +1,5 @@ #!/usr/bin/env python -import glob import subprocess import sys @@ -12,17 +11,11 @@ sys.exit(1) # Alpine -alpine_images = glob.glob("alpine/alpine-minirootfs-*.tar.gz") -if len(alpine_images) == 0: - print("No alpine image found in ./alpine") - sys.exit(1) - -print("Building base Alpine ...") -proc_args = ["docker", "build", "-t", "alpine:latest", "alpine"] -result = subprocess.run(proc_args).check_returncode() - images = ["swarm", "trigger", "common", "docs", "linux"] for image in images: print("Building %s ..." % (image)) proc_args = ["docker", "build", "-t", "alpine:%s" % (image), image] - subprocess.run().check_returncode(proc_args) + subprocess.run(proc_args).check_returncode() + proc_args = ["docker", "tag", "alpine:%s" % (image), + "dev-docker.governikus.de/ausweisapp2/alpine:%s" % image] + subprocess.run(proc_args).check_returncode() diff --git a/resources/jenkins/docker/linux/Dockerfile b/resources/jenkins/docker/linux/Dockerfile index 5a249aa94..626443349 100644 --- a/resources/jenkins/docker/linux/Dockerfile +++ b/resources/jenkins/docker/linux/Dockerfile @@ -4,7 +4,7 @@ MAINTAINER Governikus KG ENV NAME=Linux LABELS="Linux g++ clang++" PACKAGES_DIR=/home/governikus/packages RUN apk --no-cache add cmake make g++ clang clang-analyzer ccache gcovr cloc cppcheck pkgconf ninja pcsc-lite-dev binutils-gold lld \ - py-setuptools mesa-dev libx11-dev libxkbcommon-dev xcb-util-wm-dev xcb-util-image-dev xcb-util-keysyms-dev && \ + py3-setuptools mesa-dev libx11-dev libxkbcommon-dev xcb-util-wm-dev xcb-util-image-dev xcb-util-keysyms-dev && \ ln -s /usr/libexec/c++-analyzer /usr/local/bin && ln -s /usr/libexec/ccc-analyzer /usr/local/bin USER governikus diff --git a/resources/jenkins/docker/swarm-ubuntu/Dockerfile b/resources/jenkins/docker/swarm-ubuntu/Dockerfile new file mode 100644 index 000000000..a42ed7d41 --- /dev/null +++ b/resources/jenkins/docker/swarm-ubuntu/Dockerfile @@ -0,0 +1,13 @@ +FROM ubuntu:19.04 +MAINTAINER Governikus KG + +ARG JENKINS_SWARM_VERSION=3.17 +ENV EXECUTOR=3 LABELS= NAME= PASSWORD= + +RUN useradd -m governikus +RUN apt-get update && \ + apt-get -y install openjdk-8-jre-headless tini mercurial python-hglib wget && \ + rm -rf /var/lib/apt/lists/* +RUN wget -O /swarm-client.jar https://repo.jenkins-ci.org/releases/org/jenkins-ci/plugins/swarm-client/$JENKINS_SWARM_VERSION/swarm-client-$JENKINS_SWARM_VERSION.jar + +ADD swarm.sh / diff --git a/resources/jenkins/docker/swarm-ubuntu/swarm.sh b/resources/jenkins/docker/swarm-ubuntu/swarm.sh new file mode 100755 index 000000000..4a7ac1c00 --- /dev/null +++ b/resources/jenkins/docker/swarm-ubuntu/swarm.sh @@ -0,0 +1,24 @@ +#!/bin/sh + +dest=${DESTINATION:-/home/governikus} +name=${NAME:-undefined} +executor=${EXECUTOR:-1} +labels=${LABELS:-undefined} +mode=${MODE:-exclusive} +master=${MASTER:-https://ausweisapp-ci.govkg.de/} +user=${USER:-jenkins-swarm} +fingerprints=${FINGERPRINTS:-74:8C:AE:1C:05:99:95:04:66:CC:B1:27:6F:2B:59:E7:1E:64:47:45:D3:C1:E8:5B:E6:E5:1F:BD:98:97:18:FB} + +/usr/bin/java \ + -jar /swarm-client.jar \ + -name $name-$HOSTNAME \ + -mode $mode \ + -executors $executor \ + -labels "$labels" \ + -master $master \ + -username $user \ + -passwordEnvVariable PASSWORD \ + -sslFingerprints $fingerprints \ + -fsroot $dest \ + -disableClientsUniqueId + diff --git a/resources/jenkins/docker/swarm/Dockerfile b/resources/jenkins/docker/swarm/Dockerfile index 612a21b69..6e230bf82 100644 --- a/resources/jenkins/docker/swarm/Dockerfile +++ b/resources/jenkins/docker/swarm/Dockerfile @@ -1,11 +1,12 @@ -FROM alpine:latest +FROM alpine:3.11 MAINTAINER Governikus KG ARG JENKINS_SWARM_VERSION=3.17 ENV EXECUTOR=3 LABELS= NAME= PASSWORD= RUN adduser governikus -s /bin/sh -D -RUN apk --no-cache add openjdk8-jre tini mercurial py2-hglib wget +RUN apk --no-cache add openjdk8-jre tini mercurial py3-hglib wget && \ + ln -s /usr/bin/python3 /usr/bin/python RUN wget -O /swarm-client.jar https://repo.jenkins-ci.org/releases/org/jenkins-ci/plugins/swarm-client/$JENKINS_SWARM_VERSION/swarm-client-$JENKINS_SWARM_VERSION.jar ADD swarm.sh / diff --git a/resources/jenkins/dsl/Builds/Build_Android.groovy b/resources/jenkins/dsl/Builds/Build_Android.groovy index 06c04ae7a..8c83e6e5a 100644 --- a/resources/jenkins/dsl/Builds/Build_Android.groovy +++ b/resources/jenkins/dsl/Builds/Build_Android.groovy @@ -39,7 +39,7 @@ j.with } publishers { - androidLint('build/dist/build/outputs/lint-results-*.xml') + androidLint('build/dist/build/reports/lint-results.xml') { thresholds( unstableTotal: [all: 1] @@ -78,7 +78,7 @@ j.with mkdir -p build/${ARCH}; cd build/${ARCH}; cmake ../../source - -DANDROID_BUILD_AAR=ON + -DINTEGRATED_SDK=ON -DCMAKE_BUILD_TYPE=MinSizeRel -DCMAKE_INSTALL_PREFIX=\${WORKSPACE}/build/dist -DCMAKE_PREFIX_PATH="\${WORKSPACE}/libs/${ARCH}/build/dist;\${WORKSPACE}/libs/build/dist" @@ -92,7 +92,7 @@ j.with } publishers { - androidLint('build/dist/build/outputs/lint-results-*.xml') + androidLint('build/dist/build/reports/lint-results.xml') { thresholds( unstableTotal: [all: 0] diff --git a/resources/jenkins/dsl/Builds/Build_Docs.groovy b/resources/jenkins/dsl/Builds/Build_Docs.groovy index 7e4f91805..38cdb3e12 100644 --- a/resources/jenkins/dsl/Builds/Build_Docs.groovy +++ b/resources/jenkins/dsl/Builds/Build_Docs.groovy @@ -24,6 +24,8 @@ j.with shell('cd build; make inst.latex.pdf') + shell('cd build; make inte.latex.pdf') + shell('cd build; make doc8') } } diff --git a/resources/jenkins/dsl/Builds/Build_MacOS_DMG.groovy b/resources/jenkins/dsl/Builds/Build_MacOS_DMG.groovy index 76cbcc58d..36e085173 100644 --- a/resources/jenkins/dsl/Builds/Build_MacOS_DMG.groovy +++ b/resources/jenkins/dsl/Builds/Build_MacOS_DMG.groovy @@ -22,7 +22,6 @@ j.with -DCMAKE_PREFIX_PATH=\${WORKSPACE}/libs/build/dist -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_BUILD_TYPE=MinSizeRel - -DOSX_TIMESTAMP=OFF -DJENKINS_APPCAST=${MERCURIAL_REVISION_BRANCH}_Appcast """)) @@ -33,5 +32,7 @@ j.with '''.stripIndent().trim()) shell('cd build/_CPack_Packages/Darwin/Bundle/; codesign -vvvv **/*.app; spctl -a -vv **/*.app') + + shell('cd build/; cmake -P ../source/cmake/Notarization.cmake') } } diff --git a/resources/jenkins/dsl/Builds/Build_iOS_IPA.groovy b/resources/jenkins/dsl/Builds/Build_iOS_IPA.groovy index 714199235..f0ad8adb7 100644 --- a/resources/jenkins/dsl/Builds/Build_iOS_IPA.groovy +++ b/resources/jenkins/dsl/Builds/Build_iOS_IPA.groovy @@ -6,7 +6,7 @@ def j = new Build name: 'iOS_IPA', libraries: ['iOS'], label: 'iOS', - artifacts: 'build/*.ipa,build/*.zip' + artifacts: 'build/*.ipa,build/*.zip,build/*.bcsymbolmap' ).generate(this) @@ -25,7 +25,8 @@ j.with -GXcode ''')) - shell('cd build; xcodebuild -configuration MinSizeRel ARCHS=arm64') - shell('cd build; xcodebuild -target ipa -configuration MinSizeRel') + shell('cd build; xcodebuild -configuration MinSizeRel -archivePath AusweisApp2.xcarchive -scheme AusweisApp archive') + shell('cd build; xcodebuild -configuration MinSizeRel -archivePath AusweisApp2.xcarchive -exportArchive -exportOptionsPlist exportOptions.plist -exportPath .') + shell('cd build; xcodebuild -configuration MinSizeRel -target ipa') } } diff --git a/resources/jenkins/dsl/Releases/Release_Android.groovy b/resources/jenkins/dsl/Releases/Release_Android.groovy index 9a57c4e08..4004b5d98 100644 --- a/resources/jenkins/dsl/Releases/Release_Android.groovy +++ b/resources/jenkins/dsl/Releases/Release_Android.groovy @@ -89,7 +89,7 @@ j.with mkdir -p build/${ARCH}; cd build/${ARCH}; cmake ../../source - -DANDROID_BUILD_AAR=ON + -DINTEGRATED_SDK=ON -DCMAKE_INSTALL_PREFIX=\${WORKSPACE}/build/dist -DCMAKE_PREFIX_PATH="\${WORKSPACE}/libs/${ARCH}/build/dist;\${WORKSPACE}/libs/build/dist" -DCMAKE_TOOLCHAIN_FILE=../source/cmake/android.toolchain.cmake diff --git a/resources/jenkins/dsl/Releases/Release_Docs.groovy b/resources/jenkins/dsl/Releases/Release_Docs.groovy index d7c9035d2..b8ae93da6 100644 --- a/resources/jenkins/dsl/Releases/Release_Docs.groovy +++ b/resources/jenkins/dsl/Releases/Release_Docs.groovy @@ -28,5 +28,7 @@ j.with shell('cd build/docs/sdk/html; cmake -E tar cfJ ../AusweisApp2_SDK.tar.xz .') shell('cd build; make inst.latex.pdf') + + shell('cd build; make inte.latex.pdf') } } diff --git a/resources/jenkins/dsl/Releases/Release_MacOS.groovy b/resources/jenkins/dsl/Releases/Release_MacOS.groovy index 5589ca4bc..a5ddf10c9 100644 --- a/resources/jenkins/dsl/Releases/Release_MacOS.groovy +++ b/resources/jenkins/dsl/Releases/Release_MacOS.groovy @@ -31,5 +31,7 @@ j.with '''.stripIndent().trim()) shell('cd build/_CPack_Packages/Darwin/Bundle/; codesign -vvvv **/*.app; spctl -a -vv **/*.app') + + shell('cd build/; cmake -P ../source/cmake/Notarization.cmake') } } diff --git a/resources/jenkins/dsl/Releases/Release_iOS.groovy b/resources/jenkins/dsl/Releases/Release_iOS.groovy index a51dc7bb4..6cea754a1 100644 --- a/resources/jenkins/dsl/Releases/Release_iOS.groovy +++ b/resources/jenkins/dsl/Releases/Release_iOS.groovy @@ -6,7 +6,7 @@ def j = new Release name: 'iOS_IPA', libraries: ['iOS'], label: 'iOS', - artifacts: 'build/*.ipa,build/*.zip' + artifacts: 'build/*.ipa,build/*.zip,build/*.bcsymbolmap' ).generate(this) @@ -33,8 +33,9 @@ j.with -GXcode ''')) - shell('cd build; xcodebuild -configuration MinSizeRel ARCHS=arm64') - shell('cd build; xcodebuild -target ipa -configuration MinSizeRel') + shell('cd build; xcodebuild -configuration MinSizeRel -archivePath AusweisApp2.xcarchive -scheme AusweisApp archive') + shell('cd build; xcodebuild -configuration MinSizeRel -archivePath AusweisApp2.xcarchive -exportArchive -exportOptionsPlist exportOptions.plist -exportPath .') + shell('cd build; xcodebuild -configuration MinSizeRel -target ipa') conditionalSteps { diff --git a/resources/jenkins/dsl/Reviews/Review_Android.groovy b/resources/jenkins/dsl/Reviews/Review_Android.groovy index 96f1cc75e..8ada8bab1 100644 --- a/resources/jenkins/dsl/Reviews/Review_Android.groovy +++ b/resources/jenkins/dsl/Reviews/Review_Android.groovy @@ -38,7 +38,7 @@ j.with } publishers { - androidLint('build/dist/build/outputs/lint-results-*.xml') + androidLint('build/dist/build/reports/lint-results.xml') { thresholds( unstableTotal: [all: 1] @@ -84,7 +84,7 @@ j.with mkdir -p build/${ARCH}; cd build/${ARCH}; cmake -Werror=dev ../../source - -DANDROID_BUILD_AAR=ON + -DINTEGRATED_SDK=ON -DCMAKE_BUILD_TYPE=debug -DCMAKE_INSTALL_PREFIX=\${WORKSPACE}/build/dist -DCMAKE_PREFIX_PATH="\${WORKSPACE}/libs/${ARCH}/build/dist;\${WORKSPACE}/libs/build/dist" @@ -98,7 +98,7 @@ j.with } publishers { - androidLint('build/dist/build/outputs/lint-results-*.xml') + androidLint('build/dist/build/reports/lint-results.xml') { thresholds( unstableTotal: [all: 0] diff --git a/resources/jenkins/dsl/Reviews/Review_Docs.groovy b/resources/jenkins/dsl/Reviews/Review_Docs.groovy index 6db69b02a..d4bba702d 100644 --- a/resources/jenkins/dsl/Reviews/Review_Docs.groovy +++ b/resources/jenkins/dsl/Reviews/Review_Docs.groovy @@ -28,6 +28,8 @@ j.with shell('cd build; make inst.latex.pdf') + shell('cd build; make inte.latex.pdf') + shell('cd build; make doc8') } } diff --git a/resources/jenkins/dsl/Reviews/Review_Trigger.groovy b/resources/jenkins/dsl/Reviews/Review_Trigger.groovy index aed7a6348..64d0b7759 100644 --- a/resources/jenkins/dsl/Reviews/Review_Trigger.groovy +++ b/resources/jenkins/dsl/Reviews/Review_Trigger.groovy @@ -60,7 +60,7 @@ j.with phaseJob(getName('Docs')) } - phase('Packages') + phase('Packages', 'UNSTABLE') { phaseJob(getName('Android_AAR')) diff --git a/resources/jenkins/dsl/Reviews/Review_iOS_IPA.groovy b/resources/jenkins/dsl/Reviews/Review_iOS_IPA.groovy index 239953a3e..636d81dbe 100644 --- a/resources/jenkins/dsl/Reviews/Review_iOS_IPA.groovy +++ b/resources/jenkins/dsl/Reviews/Review_iOS_IPA.groovy @@ -6,7 +6,7 @@ def j = new Review name: 'iOS_IPA', libraries: ['iOS'], label: 'iOS', - artifacts: 'build/*.ipa,build/*.zip' + artifacts: 'build/*.ipa,build/*.zip,build/*.bcsymbolmap' ).generate(this) @@ -27,7 +27,7 @@ j.with -GXcode ''')) - shell('cd build; xcodebuild -configuration MinSizeRel ARCHS=arm64') - shell('cd build; xcodebuild -target ipa -configuration MinSizeRel') + shell('cd build; xcodebuild -configuration MinSizeRel') + shell('cd build; xcodebuild -configuration MinSizeRel -target ipa') } } diff --git a/resources/packaging/android/AndroidManifest.xml.aar.in b/resources/packaging/android/AndroidManifest.xml.aar.in index 429bfc608..3759ce6b5 100644 --- a/resources/packaging/android/AndroidManifest.xml.aar.in +++ b/resources/packaging/android/AndroidManifest.xml.aar.in @@ -1,6 +1,6 @@ - + diff --git a/resources/packaging/android/AndroidManifest.xml.apk.in b/resources/packaging/android/AndroidManifest.xml.apk.in index 41cfdda7a..3499303a5 100644 --- a/resources/packaging/android/AndroidManifest.xml.apk.in +++ b/resources/packaging/android/AndroidManifest.xml.apk.in @@ -1,6 +1,6 @@ - + @@ -28,6 +28,7 @@ android:name="org.qtproject.qt5.android.bindings.QtApplication" android:label="@string/app_name" android:icon="@mipmap/npa" + android:theme="@style/AppTheme" android:allowBackup="true" android:fullBackupContent="@xml/backup_rules"> @@ -38,7 +39,7 @@ - @@ -50,7 +51,6 @@ android:name="com.governikus.ausweisapp2.MainActivity" android:label="@string/app_name" android:launchMode="singleTask" - android:theme="@style/Theme.NoTitle" android:resizeableActivity="false"> diff --git a/resources/packaging/android/build.gradle.append b/resources/packaging/android/build.gradle.append index 88b043cc1..1b3fb1159 100644 --- a/resources/packaging/android/build.gradle.append +++ b/resources/packaging/android/build.gradle.append @@ -5,7 +5,7 @@ task sourcesJar(type: Jar) { } dependencies { - compile "com.android.support:support-v4:28.0.0" + implementation "androidx.appcompat:appcompat:1.1.0" } allprojects { diff --git a/resources/packaging/android/lint.aar.xml b/resources/packaging/android/lint.aar.xml index 0999fdc2d..959629daf 100644 --- a/resources/packaging/android/lint.aar.xml +++ b/resources/packaging/android/lint.aar.xml @@ -16,6 +16,16 @@ + + + + + + + + - - + + + @@ -28,7 +28,7 @@ ExeCommand="[SystemFolder]netsh.exe advfirewall firewall add rule name=AusweisApp2-Firewall-Rule-SaC-In [FirewallSacParams]" Execute="commit" Impersonate="no" - Return="asyncWait" /> + Return="ignore" /> (SYSTEMSETTINGS = "true") AND NOT Installed @@ -39,10 +39,10 @@ ExeCommand="[SystemFolder]netsh.exe advfirewall firewall delete rule name=AusweisApp2-Firewall-Rule-SaC-In" Execute="commit" Impersonate="no" - Return="asyncWait" /> + Return="ignore" /> - Installed AND NOT REINSTALL + REMOVE diff --git a/resources/qml/+desktop/main.qml b/resources/qml/+desktop/main.qml index 289ff26cc..aeb677f23 100644 --- a/resources/qml/+desktop/main.qml +++ b/resources/qml/+desktop/main.qml @@ -1,24 +1,25 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import Governikus.Global 1.0 import Governikus.TitleBar 1.0 +import Governikus.FeedbackView 1.0 import Governikus.MainView 1.0 import Governikus.HistoryView 1.0 import Governikus.SelfAuthenticationView 1.0 import Governikus.IdentifyView 1.0 import Governikus.ChangePinView 1.0 import Governikus.ProviderView 1.0 -import Governikus.InformationView 1.0 +import Governikus.MoreView 1.0 import Governikus.SettingsView 1.0 import Governikus.TutorialView 1.0 +import Governikus.UpdateView 1.0 import Governikus.View 1.0 import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.UiModule 1.0 import Governikus.Type.SettingsModel 1.0 import Governikus.Type.SelfAuthModel 1.0 -import Governikus.Type.SettingsModel 1.0 import Governikus.Type.ChangePinModel 1.0 import Governikus.Style 1.0 @@ -49,7 +50,7 @@ ApplicationWindow { minimumWidth: 480 minimumHeight: 360 - title: Qt.application.name + title: Qt.application.name + (plugin.developerVersion ? " - Beta - " + Qt.application.version : "") color: Style.color.background menuBar: TitleBar { id: titleBar @@ -57,7 +58,14 @@ ApplicationWindow { onRootClicked: d.activeView = SectionPage.Views.Main } - Component.onCompleted: menuBar.forceActiveFocus() + Component.onCompleted: { + if (SettingsModel.showNewUiHint) { + useWidgetsPopup.open() + } + else { + menuBar.forceActiveFocus() + } + } onWidthChanged: d.setScaleFactor() onHeightChanged: d.setScaleFactor() @@ -73,6 +81,15 @@ ApplicationWindow { } onVisibilityChanged: if (visibility !== ApplicationWindow.Minimized) d.lastVisibility = visibility + function showDetachedLogView() { + if (d.detachedLogView === null) { + d.detachedLogView = detachedLogViewWindow.createObject(appWindow) + } + else { + d.detachedLogView.raise() + } + } + QtObject { id: d @@ -80,6 +97,7 @@ ApplicationWindow { property int lastVisibility: ApplicationWindow.Windowed readonly property int initialWidth: ApplicationModel.dpiScale * 1600 readonly property int initialHeight: ApplicationModel.dpiScale * 1200 + property ApplicationWindow detachedLogView: null function closeOpenDialogs() { saveFileDialog.reject() @@ -87,10 +105,14 @@ ApplicationWindow { } function showMainWindow() { + if (active) { + return + } + var currentFlags = flags - // Force the window to the foreground if it was minimized (not closed to tray) + // Force the window to the foreground if it was minimized or is behind other windows (not closed to tray) if (Qt.platform.os === "windows") { - flags = currentFlags | Qt.WindowStaysOnTopHint + flags = currentFlags | Qt.WindowStaysOnTopHint | Qt.WindowTitleHint } if (d.lastVisibility === ApplicationWindow.Maximized) { @@ -149,7 +171,7 @@ ApplicationWindow { ToggleableOption { //: LABEL DESKTOP_QML text: qsTr("Do not show this dialog again.") + SettingsModel.translationTrigger - textStyle: Style.text.normal + textStyle: Style.text.normal_inverse checked: !SettingsModel.remindUserToClose @@ -194,6 +216,11 @@ ApplicationWindow { d.activeView = SectionPage.Views.SetupAssistant } break + case UiModule.UPDATEINFORMATION: + if (ApplicationModel.currentWorkflow === "" && d.activeView === SectionPage.Views.Main) { + d.activeView = SectionPage.Views.AppUpdateInfo + } + break } } onFireHideRequest: { @@ -204,39 +231,33 @@ ApplicationWindow { Connections { target: SettingsModel onFireAppUpdateDataChanged: { - var updateData = SettingsModel.appUpdateData - - if (!updateData.valid) { + if (!SettingsModel.appUpdateData.valid) { //: INFO DESKTOP_QML Message that the update data is invalid and can't be used. - ApplicationModel.showFeedback(qsTr("Unsupported version of %1.").arg(Qt.application.name)) + ApplicationModel.showFeedback(qsTr("Failed to retrieve update information.")) } - else { - if (pUpdateAvailable) { - //: INFO DESKTOP_QML An update was found which matches the current platform, the new version number is shown in the message. - ApplicationModel.showFeedback(qsTr("An update is available (Version: %1).").arg(updateData.version)) - //: INFO DESKTOP_QML An update was found. This is the caption of the download button, clicking it opens the link in the browser. - ApplicationModel.showFeedback("".arg(updateData.url) + qsTr("Download") + "") - //: INFO DESKTOP_QML An update was found. This is the caption of the release note button, clicking it opens the note in the browser. - ApplicationModel.showFeedback("".arg(updateData.notesUrl) + qsTr("Release notes") + "") - } - else { - //: INFO DESKTOP_QML The AA2 is up-to-date, this message is only shown if the update check is started by the user and not via the auto-update functionality. - ApplicationModel.showFeedback(qsTr("Current version %1 is up to date.").arg(updateData.currentVersion)) - } + else if (SettingsModel.appUpdateData.updateAvailable) { + //: INFO DESKTOP_QML An update was found which matches the current platform, the new version number is shown in the message. + ApplicationModel.showFeedback(qsTr("An update is available (version %1).").arg(SettingsModel.appUpdateData.version)) } } } - Action { - shortcut: "Ctrl+Alt+R" - onTriggered: plugin.developerBuild ? plugin.doRefresh() : "" - } - Shortcut { sequence: StandardKey.HelpContents onActivated: ApplicationModel.openOnlineHelp("index") } + Image { + visible: plugin.developerVersion && SettingsModel.showBetaTesting + height: 0.8 * parent.height + width: 0.8 * parent.width + anchors.centerIn: parent + + opacity: 0.2 + source: "qrc:///images/beta.svg" + fillMode: Image.PreserveAspectFit + } + Loader { id: contentLoader @@ -247,10 +268,11 @@ ApplicationWindow { Component {IdentifyView {}} Component {ChangePinView {}} Component {ProviderView {}} - Component {InformationView {}} + Component {MoreView {}} Component {SettingsView {}} Component {HistoryView {}} Component {SetupAssistantView {}} + Component {UpdateView { onLeaveView: d.activeView = SectionPage.Views.Main }} } Keys.onEscapePressed: { @@ -267,7 +289,10 @@ ApplicationWindow { anchors.fill: parent - onItemChanged: titleBar.updateActions() + onItemChanged: { + titleBar.updateActions() + item.setActive() + } sourceComponent: sectionPages.get(d.activeView) } @@ -318,4 +343,40 @@ ApplicationWindow { transformOrigin: Item.Left antialiasing: true } + + ConfirmationPopup { + id: useWidgetsPopup + + title: qsTr("New user interface released!") + SettingsModel.translationTrigger + text: qsTr("This release features a new and modern user interface. For this version of %1 (and this version only!) you may decide to switch back to the previous user interface. To do so click the Button \"%2\". It is highly recommend to use the new user interface as the old one will be removed with the next release of %3.").arg(Qt.application.name).arg(cancelButtonText).arg(Qt.application.name) + SettingsModel.translationTrigger + okButtonText: qsTr("Stick with new interface") + SettingsModel.translationTrigger + cancelButtonText: qsTr("Use old interface") + SettingsModel.translationTrigger + + onClosed: SettingsModel.showNewUiHint = false + onCancelled: plugin.switchUi() + } + + Component { + id: detachedLogViewWindow + + ApplicationWindow { + visible: true + width: d.initialWidth + height: d.initialHeight + minimumHeight: appWindow.minimumHeight + minimumWidth: appWindow.minimumWidth + + title: qsTr("%1 - Detached log viewer").arg(appWindow.title) + SettingsModel.translationTrigger + + DetachedLogView { + anchors.fill: parent + focus: true + } + + onClosing: { + d.detachedLogView.destroy() + d.detachedLogView = null + } + } + } } diff --git a/resources/qml/+mobile/main.qml b/resources/qml/+mobile/main.qml index 315b5f199..53678c42f 100644 --- a/resources/qml/+mobile/main.qml +++ b/resources/qml/+mobile/main.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -19,11 +19,17 @@ ApplicationWindow { id: appWindow visible: true - width: 750 / 2 //Screen.desktopAvailableWidth - height: 1334 / 2 - title: "Governikus AusweisApp2" - color: Style.color.background + // This is only relevant when running the mobile UI on the desktop. Use 4:3 in landscape mode for tablets and 16:9 in portrait for phones: + width: Constants.is_tablet ? 1024 : 432 + height: 768 + + // Workaround for qt 5.12 not calculating the highdpi scaling factor correctly. On some devices (like the pixel 3) + // this leads to a small light stripe above the dark statusbar. By setting the background to black and filling the + // rest of the window with the background color, it's still there but not noticeable. + color: "#000000" + Rectangle { anchors.fill: parent; color: Style.color.background } + Component.onCompleted: { flags |= Qt.MaximizeUsingFullscreenGeometryHint } @@ -72,7 +78,7 @@ ApplicationWindow { if (navBar.isOpen) { navBar.close() } - else if (navigationAction.state !== "hidden") { + else { navigationAction.clicked(undefined) } } @@ -89,7 +95,7 @@ ApplicationWindow { Action { shortcut: "Ctrl+Alt+R" - onTriggered: plugin.developerBuild ? plugin.doRefresh() : "" + onTriggered: plugin.debugBuild ? plugin.doRefresh() : "" } Action { @@ -134,8 +140,6 @@ ApplicationWindow { SplashScreen { id: splashScreen - - color: appWindow.color } Navigation { diff --git a/resources/qml/Governikus/ChangePinView/+desktop/ChangePinController.qml b/resources/qml/Governikus/ChangePinView/+desktop/ChangePinController.qml index cb6d881dd..e2a5c95a6 100644 --- a/resources/qml/Governikus/ChangePinView/+desktop/ChangePinController.qml +++ b/resources/qml/Governikus/ChangePinView/+desktop/ChangePinController.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -68,7 +68,7 @@ Controller { case "FinalState": if (d.showRemoveCardFeedback) { d.showRemoveCardFeedback = false - //: INFO DESKTOP_QML Changing the PIN was successful; hint that the id card may now be removed from the card reader. + //: INFO DESKTOP_QML Changing the PIN was successful; hint that the ID card may now be removed from the card reader. ApplicationModel.showFeedback(qsTr("You may now remove your ID card from the device.")) } if (ChangePinModel.shouldSkipResultView()) { diff --git a/resources/qml/Governikus/ChangePinView/+desktop/ChangePinView.qml b/resources/qml/Governikus/ChangePinView/+desktop/ChangePinView.qml index a8d301bcc..4556cf024 100644 --- a/resources/qml/Governikus/ChangePinView/+desktop/ChangePinView.qml +++ b/resources/qml/Governikus/ChangePinView/+desktop/ChangePinView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -36,13 +36,19 @@ SectionPage { ReaderSettings } + function showSettings() { + readerView.precedingView = d.activeView + d.view = ChangePinView.SubViews.ReaderSettings + ApplicationWindow.menuBar.updateActions() + } + Keys.onEscapePressed: if (d.cancelAllowed) ChangePinModel.cancelWorkflow() titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML text: qsTr("PIN Management") + SettingsModel.translationTrigger rootEnabled: false - helpTopic: "pinTab" + helpTopic: "pinManagement" showSettings: (changePinController.workflowState === ChangePinController.WorkflowStates.Initial || changePinController.workflowState === ChangePinController.WorkflowStates.Reader || changePinController.workflowState === ChangePinController.WorkflowStates.Card) @@ -54,7 +60,7 @@ SectionPage { ApplicationWindow.menuBar.updateActions() } else if (d.activeView === ChangePinView.SubViews.ReaderSettings) { - d.view = readerView.preceedingView + d.view = readerView.precedingView ApplicationWindow.menuBar.updateActions() } } @@ -72,11 +78,7 @@ SectionPage { } } - customSettingsHandler: function(){ - readerView.preceedingView = d.activeView - d.view = ChangePinView.SubViews.ReaderSettings - ApplicationWindow.menuBar.updateActions() - } + customSettingsHandler: baseItem.showSettings } QtObject { @@ -90,11 +92,11 @@ SectionPage { TabbedReaderView { id: readerView - property int preceedingView: ChangePinView.SubViews.Undefined + property int precedingView: ChangePinView.SubViews.Undefined visible: d.activeView === ChangePinView.SubViews.ReaderSettings onCloseView: { - d.view = preceedingView + d.view = precedingView ApplicationWindow.menuBar.updateActions() } } @@ -128,6 +130,7 @@ SectionPage { default: return Workflow.WaitingFor.None } + onSettingsRequested: baseItem.showSettings() } EnterPasswordView { @@ -169,7 +172,7 @@ SectionPage { //: LABEL DESKTOP_QML text: qsTr("Change PIN") + SettingsModel.translationTrigger //: INFO DESKTOP_QML Processing screen text while the card communication is running after the PIN has been entered during PIN change process. - subText: qsTr("Please wait a moment...") + SettingsModel.translationTrigger + subText: qsTr("Please don't move the ID card...") + SettingsModel.translationTrigger } ResultView { @@ -214,7 +217,7 @@ SectionPage { resultType: ResultView.Type.IsInfo //: INFO DESKTOP_QML The NFC signal is weak or unstable, the user is asked to change the card's position to (hopefully) reduce the distance to the NFC chip. - text: qsTr("Weak NFC signal.\nPlease reposition your card.") + SettingsModel.translationTrigger + text: qsTr("Weak NFC signal. Please\n- change the card position\n- remove the mobile phone case (if present)\n- connect the smartphone with a charging cable") + SettingsModel.translationTrigger onNextView: ChangePinModel.continueWorkflow() } diff --git a/resources/qml/Governikus/ChangePinView/+mobile/ChangePinController.qml b/resources/qml/Governikus/ChangePinView/+mobile/ChangePinController.qml index 50b21eef7..95e440f03 100644 --- a/resources/qml/Governikus/ChangePinView/+mobile/ChangePinController.qml +++ b/resources/qml/Governikus/ChangePinView/+mobile/ChangePinController.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -104,7 +104,7 @@ Item { break case "StateUnfortunateCardPosition": //: INFO IOS The NFC signal is weak or unstable. The scan is stopped with this information in the iOS dialog. - ApplicationModel.stopNfcScanWithError(qsTr("Weak NFC signal") + SettingsModel.translationTrigger) + ApplicationModel.stopNfcScanWithError(qsTr("Weak NFC signal. Please\n- change the card position\n- remove the mobile phone case (if present)\n- connect the smartphone with a charging cable")) baseItem.firePush(cardPositionView) break case "StateEnterNewPacePin": @@ -117,7 +117,7 @@ Item { case "FinalState": if (controller.showRemoveCardFeedback) { controller.showRemoveCardFeedback = false - //: INFO ANDROID IOS Hint that the id card may be removed from the card reader since the PIN was changed successfully. + //: INFO ANDROID IOS Hint that the ID card may be removed from the card reader since the PIN was changed successfully. ApplicationModel.showFeedback(qsTr("You may now remove your ID card from the device.")) } if (ChangePinModel.shouldSkipResultView()) { diff --git a/resources/qml/Governikus/ChangePinView/+mobile/ChangePinView.qml b/resources/qml/Governikus/ChangePinView/+mobile/ChangePinView.qml index 514b0d5b9..78effa0b2 100644 --- a/resources/qml/Governikus/ChangePinView/+mobile/ChangePinView.qml +++ b/resources/qml/Governikus/ChangePinView/+mobile/ChangePinView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -71,7 +71,7 @@ SectionPage { //: LABEL ANDROID IOS buttonText: qsTr("Retry") + SettingsModel.translationTrigger //: INFO ANDROID IOS The NFC signal is weak or unstable, the user is asked to change the card's position to (hopefully) reduce the distance to the NFC chip. - text: qsTr("Weak NFC signal. Please reposition your card.") + SettingsModel.translationTrigger + text: qsTr("Weak NFC signal. Please\n- change the card position\n- remove the mobile phone case (if present)\n- connect the smartphone with a charging cable") + SettingsModel.translationTrigger onClicked: { firePop() ChangePinModel.continueWorkflow() @@ -110,7 +110,10 @@ SectionPage { ProgressView { id: pinProgressView - navigationAction: NavigationAction { state: ChangePinModel.isBasicReader ? "cancel" : "hidden"; onClicked: ChangePinModel.cancelWorkflow() } + navigationAction: NavigationAction { + state: ChangePinModel.isBasicReader ? "cancel" : "hidden"; + onClicked: if (state !== "hidden") ChangePinModel.cancelWorkflow() + } //: LABEL ANDROID IOS title: qsTr("PIN Management") + SettingsModel.translationTrigger visible: false @@ -118,20 +121,20 @@ SectionPage { text: qsTr("Change PIN") + SettingsModel.translationTrigger subText: (!visible ? "" //: INFO ANDROID IOS Loading screen during PIN change process, data communcation is currently ongoing. Message is usually not visible since the password handling with basic reader is handled by EnterPasswordView. - : ChangePinModel.isBasicReader ? qsTr("Please wait a moment...") + : ChangePinModel.isBasicReader ? qsTr("Please don't move the ID card...") : !!NumberModel.inputError ? NumberModel.inputError //: INFO ANDROID IOS The card communcation was aborted, the online identification functionality is deactivated and needs to be actived by the authorities. - : NumberModel.pinDeactivated ? qsTr("The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function.") + : NumberModel.pinDeactivated ? qsTr("The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function.") : changePinController.workflowState === ChangePinController.WorkflowStates.Update || changePinController.workflowState === ChangePinController.WorkflowStates.Pin //: INFO ANDROID IOS Either an comfort card reader or smartphone-as-card-reader is used, the user needs to react to request on that device. || changePinController.workflowState === ChangePinController.WorkflowStates.NewPin ? qsTr("Please observe the display of your card reader.") //: INFO ANDROID IOS The wrong PIN was entered twice, the next attempt requires additional verifcation via CAN. - : changePinController.workflowState === ChangePinController.WorkflowStates.Can ? qsTr("You have entered the wrong PIN twice. Prior to a third attempt, you have to enter your six-digit card access number first. You can find your card access number on the front of your ID card.") - //: INFO ANDROID IOS The PIN (including the CAN) was entered wrongfully three times, the PUK is required to unlock the id card. - : changePinController.workflowState === ChangePinController.WorkflowStates.Puk ? qsTr("You have entered a wrong PIN three times. Your PIN is now blocked. You have to enter the PUK now for unblocking.") + : changePinController.workflowState === ChangePinController.WorkflowStates.Can ? qsTr("A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card.") + //: INFO ANDROID IOS The PIN (including the CAN) was entered wrongfully three times, the PUK is required to unlock the ID card. + : changePinController.workflowState === ChangePinController.WorkflowStates.Puk ? qsTr("A wrong PIN has been entered three times on your ID card. Your PIN is now blocked. To unblock your PIN you have to enter the PUK.") //: INFO ANDROID IOS Generic progress message during PIN change process. - : qsTr("Please wait a moment...")) + SettingsModel.translationTrigger + : qsTr("Please don't move the ID card...")) + SettingsModel.translationTrigger subTextColor: !ChangePinModel.isBasicReader && (NumberModel.inputError || NumberModel.pinDeactivated || changePinController.workflowState === ChangePinController.WorkflowStates.Can diff --git a/resources/qml/Governikus/ChangePinView/+mobile/ChangePinViewContent.qml b/resources/qml/Governikus/ChangePinView/+mobile/ChangePinViewContent.qml index b10d0b30f..ddd70315a 100644 --- a/resources/qml/Governikus/ChangePinView/+mobile/ChangePinViewContent.qml +++ b/resources/qml/Governikus/ChangePinView/+mobile/ChangePinViewContent.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -50,7 +50,6 @@ Item { //: LABEL ANDROID IOS text: qsTr("You have the opportunity to change your transport PIN into a personal PIN. You can also change the PIN at any time or unblock the PIN using the personal unblocking key (PUK). The transport PIN and the PUK can be found in the letter sent to you by your competent authority.") + SettingsModel.translationTrigger - textStyle: Style.text.normal horizontalAlignment: Text.AlignHCenter width: Math.min(parent.width - 2 * Constants.pane_padding, Style.dimens.max_text_width) diff --git a/resources/qml/Governikus/DeveloperView/+mobile/DeveloperView.qml b/resources/qml/Governikus/DeveloperView/+mobile/DeveloperView.qml new file mode 100644 index 000000000..6dc45d789 --- /dev/null +++ b/resources/qml/Governikus/DeveloperView/+mobile/DeveloperView.qml @@ -0,0 +1,110 @@ +/* + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.SettingsView 1.0 +import Governikus.TitleBar 1.0 +import Governikus.View 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.Type.LogModel 1.0 +import Governikus.Type.HistoryModel 1.0 +import Governikus.Type.ApplicationModel 1.0 + + +SectionPage { + id: root + navigationAction: NavigationAction { state: !topLevelPage ? "back" : ""; onClicked: firePop() } + //: LABEL ALL_PLATFORMS + title: qsTr("Developer options") + SettingsModel.translationTrigger + + content: Column { + id: mainColumn + width: root.width + padding: Constants.pane_padding + spacing: Constants.component_spacing + + readonly property int usableWidth: width - 2 * padding + + LabeledSwitch { + id: testUriSwitch + + width: parent.usableWidth + + //: LABEL ANDROID IOS + title: qsTr("Testmode for the self-authentication") + SettingsModel.translationTrigger + //: LABEL ANDROID IOS + description: qsTr("Use the test environment during a self-authentication") + SettingsModel.translationTrigger + checked: SettingsModel.useSelfauthenticationTestUri + onCheckedChanged: SettingsModel.useSelfauthenticationTestUri = testUriSwitch.checked + } + + LabeledSwitch { + id: devModeSwitch + + width: parent.usableWidth + + //: LABEL ANDROID IOS + title: qsTr("Developer Mode") + SettingsModel.translationTrigger + //: LABEL ANDROID IOS + description: qsTr("Use a more tolerant mode") + SettingsModel.translationTrigger + checked: SettingsModel.developerMode + onCheckedChanged: SettingsModel.developerMode = devModeSwitch.checked + } + + GText { + //: LABEL ALL_PLATFORMS + text: qsTr("Change the layout style") + SettingsModel.translationTrigger + textStyle: Style.text.normal_accent + } + + GRadioButton { + //: LABEL ALL_PLATFORMS + text: qsTr("iOS") + SettingsModel.translationTrigger + checked: plugin.platformStyle === text.toLowerCase() + onCheckedChanged: if (checked) { plugin.applyPlatformStyle(text.toLowerCase()) } + } + + GRadioButton { + //: LABEL ALL_PLATFORMS + text: qsTr("Android") + SettingsModel.translationTrigger + checked: plugin.platformStyle === text.toLowerCase() + onCheckedChanged: if (checked) { plugin.applyPlatformStyle(text.toLowerCase()) } + } + + GRadioButton { + //: LABEL ALL_PLATFORMS + text: qsTr("Tablet, Android") + SettingsModel.translationTrigger + checked: plugin.platformStyle === text.toLowerCase() + onCheckedChanged: if (checked) { plugin.applyPlatformStyle(text.toLowerCase()) } + } + + GText { + //: LABEL ALL_PLATFORMS + text: qsTr("Create dummy entries") + SettingsModel.translationTrigger + textStyle: Style.text.normal_accent + } + + GButton { + //: LABEL ALL_PLATFORMS + text: qsTr("Logfile") + SettingsModel.translationTrigger + onClicked: { + LogModel.saveDummyLogfile() + ApplicationModel.showFeedback("Created new logfile.") + } + } + + GButton { + //: LABEL ALL_PLATFORMS + text: qsTr("History") + SettingsModel.translationTrigger + onClicked: { + HistoryModel.createDummyEntry() + ApplicationModel.showFeedback("Created new history entry.") + } + } + } +} diff --git a/resources/qml/Governikus/DeveloperView/DeveloperView.qml b/resources/qml/Governikus/DeveloperView/DeveloperView.qml deleted file mode 100644 index c77483ebb..000000000 --- a/resources/qml/Governikus/DeveloperView/DeveloperView.qml +++ /dev/null @@ -1,144 +0,0 @@ -/* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.TitleBar 1.0 -import Governikus.View 1.0 -import Governikus.Type.SettingsModel 1.0 - - -SectionPage { - id: root - navigationAction: NavigationAction { state: !topLevelPage ? "back" : ""; onClicked: firePop() } - //: LABEL ALL_PLATFORMS - title: qsTr("Developer options") + SettingsModel.translationTrigger - - content: Column { - id: mainColumn - width: root.width - padding: Constants.pane_padding - spacing: Constants.component_spacing - - readonly property int usableWidth: width - 2 * padding - - Item { - id: testUriContainer - width: parent.usableWidth - height: Math.max(testUriText.height, testUriSwitch.height) - - Item { - id: testUriText - height: testUriNameText.height + testUriDateText.height - anchors.left: testUriContainer.left - anchors.right: testUriSwitch.left - anchors.rightMargin: Constants.component_spacing - anchors.verticalCenter: testUriContainer.verticalCenter - - GText { - id: testUriNameText - anchors.bottomMargin: 2 - //: LABEL ALL_PLATFORMS - text: qsTr("Test environment") + SettingsModel.translationTrigger - textStyle: Style.text.normal_accent - } - - GText { - id: testUriDateText - width: parent.width - anchors.top: testUriNameText.bottom - //: LABEL ALL_PLATFORMS - text: qsTr("Use the test environment during a self-authentication") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary - } - } - - GSwitch { - id: testUriSwitch - - anchors.right: testUriContainer.right - anchors.verticalCenter: testUriContainer.verticalCenter - - Accessible.name: qsTr("Test environment") + SettingsModel.translationTrigger - - initialState: SettingsModel.useSelfauthenticationTestUri - onSwitched: SettingsModel.useSelfauthenticationTestUri = testUriSwitch.isOn - } - } - - Item { - id: devModeContainer - width: parent.usableWidth - height: Math.max(devModeText.height, devModeSwitch.height) - - Item { - id: devModeText - height: devModeNameText.height + devModeDateText.height - anchors.left: devModeContainer.left - anchors.right: devModeSwitch.left - anchors.rightMargin: Constants.component_spacing - anchors.verticalCenter: devModeContainer.verticalCenter - - GText { - id: devModeNameText - anchors.bottomMargin: 2 - //: LABEL ALL_PLATFORMS - text: qsTr("Developer Mode") + SettingsModel.translationTrigger - textStyle: Style.text.normal_accent - } - - GText { - id: devModeDateText - width: parent.width - anchors.top: devModeNameText.bottom - //: LABEL ALL_PLATFORMS - text: qsTr("Use a more tolerant mode") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary - } - } - - GSwitch { - id: devModeSwitch - - anchors.right: devModeContainer.right - anchors.verticalCenter: devModeContainer.verticalCenter - - Accessible.name: qsTr("Developer mode") + SettingsModel.translationTrigger - - initialState: SettingsModel.developerMode - onSwitched: SettingsModel.developerMode = devModeSwitch.isOn - } - } - - GText { - //: LABEL ALL_PLATFORMS - text: qsTr("Change the layout style") + SettingsModel.translationTrigger - textStyle: Style.text.normal_accent - } - - GRadioButton { - //: LABEL ALL_PLATFORMS - text: qsTr("iOS") + SettingsModel.translationTrigger - checked: plugin.platformStyle === text.toLowerCase() - onCheckedChanged: if (checked) { plugin.applyPlatformStyle(text.toLowerCase()) } - } - - GRadioButton { - //: LABEL ALL_PLATFORMS - text: qsTr("Android") + SettingsModel.translationTrigger - checked: plugin.platformStyle === text.toLowerCase() - onCheckedChanged: if (checked) { plugin.applyPlatformStyle(text.toLowerCase()) } - } - - GRadioButton { - //: LABEL ALL_PLATFORMS - text: qsTr("Tablet, Android") + SettingsModel.translationTrigger - checked: plugin.platformStyle === text.toLowerCase() - onCheckedChanged: if (checked) { plugin.applyPlatformStyle(text.toLowerCase()) } - } - } -} diff --git a/resources/qml/Governikus/EnterPasswordView/+desktop/EnterPasswordView.qml b/resources/qml/Governikus/EnterPasswordView/+desktop/EnterPasswordView.qml index 8a39b090d..e5cb4b318 100644 --- a/resources/qml/Governikus/EnterPasswordView/+desktop/EnterPasswordView.qml +++ b/resources/qml/Governikus/EnterPasswordView/+desktop/EnterPasswordView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -10,7 +10,6 @@ import Governikus.Style 1.0 import Governikus.View 1.0 import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.AuthModel 1.0 -import Governikus.Type.CardReturnCode 1.0 import Governikus.Type.NumberModel 1.0 import Governikus.Type.RemoteServiceModel 1.0 import Governikus.Type.SettingsModel 1.0 @@ -27,13 +26,13 @@ SectionPage property alias statusIcon: statusIcon.source property int passwordType: NumberModel.passwordType - Accessible.name: qsTr("Enter %1 view. You can start to enter the number.").arg(d.passwordString) + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML %1 is the title, e.g. "PIN entry" + Accessible.name: qsTr("%1. You can start to enter the number.").arg(mainText.text) + SettingsModel.translationTrigger Accessible.description: qsTr("This is the enter password view of the AusweisApp2.") + SettingsModel.translationTrigger Keys.onPressed: { if (focus && event.key >= Qt.Key_0 && event.key <= Qt.Key_9) { numberField.append(event.key - Qt.Key_0) numberField.forceActiveFocus() - return } } @@ -43,13 +42,6 @@ SectionPage QtObject { id: d - readonly property string passwordString: passwordType === NumberModel.PASSWORD_PIN ? "PIN" - : passwordType === NumberModel.PASSWORD_NEW_PIN ? "PIN" - : passwordType === NumberModel.PASSWORD_CAN ? "CAN" - : passwordType === NumberModel.PASSWORD_PUK ? "PUK" - : passwordType === NumberModel.PASSWORD_REMOTE_PIN ? "Remote PIN" - : "UNKNOWN" - function setPassword() { if (!numberField.validInput) { return @@ -103,6 +95,7 @@ SectionPage anchors.margins: height activeFocusOnTab: true + Accessible.role: Accessible.StaticText //: LABEL DESKTOP_QML Accessible.name: qsTr("Remaining attempts: %1").arg(NumberModel.retryCounter) + SettingsModel.translationTrigger @@ -133,12 +126,20 @@ SectionPage anchors.topMargin: Constants.component_spacing activeFocusOnTab: true - Accessible.role: Accessible.Paragraph Accessible.name: mainText.text - //: LABEL DESKTOP_QML %1 can be "PIN, CAN, PUK or UNKNOWN" - text: qsTr("%1-Entry").arg(d.passwordString) + SettingsModel.translationTrigger - textStyle: Style.text.header + //: LABEL DESKTOP_QML + text: (passwordType === NumberModel.PASSWORD_PIN ? qsTr("PIN entry") + //: LABEL DESKTOP_QML + : passwordType === NumberModel.PASSWORD_NEW_PIN ? qsTr("PIN entry") + //: LABEL DESKTOP_QML + : passwordType === NumberModel.PASSWORD_CAN ? qsTr("CAN entry") + //: LABEL DESKTOP_QML + : passwordType === NumberModel.PASSWORD_PUK ? qsTr("PUK entry") + //: LABEL DESKTOP_QML + : passwordType === NumberModel.PASSWORD_REMOTE_PIN ? qsTr("Pairing code") + : console.error("Unknown type")) + SettingsModel.translationTrigger + textStyle: Style.text.header_inverse horizontalAlignment: Text.AlignHCenter FocusFrame {} @@ -154,57 +155,86 @@ SectionPage anchors.topMargin: Constants.text_spacing activeFocusOnTab: true - Accessible.role: Accessible.Paragraph Accessible.name: subText.text - Keys.onSpacePressed: onLinkActivated(d.passwordString) textFormat: Text.StyledText - linkColor: Constants.white + linkColor: Style.text.header_inverse.textColor text: { SettingsModel.translationTrigger if (!numberField.confirmedInput) { //: INFO DESKTOP_QML The changed PIN was entered wrongfully during the confirmation process. - return qsTr("The entered PIN does not match the new PIN. Please correct your input.") + return qsTr("The new PIN and the confirmation do not match. Please correct your input.") } if (passwordType === NumberModel.PASSWORD_PIN) { if (NumberModel.requestTransportPin) { - //: INFO DESKTOP_QML The AA2 expects a PIN with 5 digit which can be entered via the physical or onscreen keyboard. - return ("%1
%2").arg(qsTr("Please enter your 5-digit Transport PIN. Use the keyboard or numpad.")).arg(qsTr("More information")) + return ("%1
%2").arg( + //: INFO DESKTOP_QML The AA2 expects a PIN with 5 digits which can be entered via the physical or onscreen keyboard + qsTr("Please enter your 5-digit Transport PIN. Use the keyboard or numpad.") + ).arg( + //: INFO DESKTOP_QML Link text + qsTr("More information") + ) } else { - //: INFO DESKTOP_QML The AA2 expects a PIN with 6 digit which can be entered via the physical or onscreen keyboard. - return ("%1
%2").arg(qsTr("Please enter your 6-digit PIN. Use the keyboard or numpad.")).arg(qsTr("More information")) + return ("%1
%2").arg( + //: INFO DESKTOP_QML The AA2 expects a PIN with 6 digits which can be entered via the physical or onscreen keyboard. + qsTr("Please enter your 6-digit PIN. Use the keyboard or numpad.") + ).arg( + //: INFO DESKTOP_QML Link text + qsTr("More information") + ) } } if (passwordType === NumberModel.PASSWORD_CAN) { if (NumberModel.isCanAllowedMode) { - //: INFO DESKTOP_QML The user is required to enter the 6 digit CAN. - return qsTr("Please enter the 6-digit CAN you can find on the front of your ID card.") + return ("%1
%2").arg( + //: INFO DESKTOP_QML The operator is required to enter the 6-digit CAN in CAN-allowed authentication. + qsTr("Please enter the 6-digit card access number (CAN).") + ).arg( + //: INFO DESKTOP_QML Link text + qsTr("More information") + ) } - //: INFO DESKTOP_QML The PIN was entered wrongfully twice, this may have happened during an earlier session of the AA2, too. The user needs to enter the CAN for additional verification. - return ("%1
%2").arg(qsTr("You have entered the wrong PIN twice. Prior to a third attempt, you have to enter your six-digit card access number first. You can find your card access number on the front of your ID card.")).arg(qsTr("More information")) + return ("%1
%2").arg( + //: INFO DESKTOP_QML The PIN was entered wrongfully twice, this may have happened during an earlier session of the AA2, too. The user needs to enter the CAN for additional verification. + qsTr("A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card.") + ).arg( + //: INFO DESKTOP_QML Link text + qsTr("More information") + ) } if (passwordType === NumberModel.PASSWORD_PUK) { - //: INFO DESKTOP_QML The PUK is required to unlock the id card. - return ("%1
%2").arg(qsTr("The online identification function is blocked. Please use your personal unblocking key (PUK) to unblock your ID card.")).arg(qsTr("More information")) + return ("%1
%2").arg( + //: INFO DESKTOP_QML The PUK is required to unlock the ID card. + qsTr("The PIN of your ID card is blocked after three incorrect tries. The block can be lifted by entering your personal unblocking key (PUK).") + ).arg( + //: INFO DESKTOP_QML Link text + qsTr("More information") + ) } if (passwordType === NumberModel.PASSWORD_NEW_PIN) { if (numberField.inputConfirmation === "") { //: INFO DESKTOP_QML A new 6-digit PIN needs to be supplied. - return qsTr("Please enter a new 6-digit PIN of your choice.") + return qsTr("Please enter a new 6-digit PIN now.") } else { //: INFO DESKTOP_QML The new PIN needs to be entered again for verification. - return qsTr("Please enter your new 6-digit PIN again.") + return qsTr("Please confirm your new 6-digit PIN.") } } if (passwordType === NumberModel.PASSWORD_REMOTE_PIN) { - return ("%1
%2").arg(qsTr("Please start the remote service in order to use your smartphone as a card reader with AusweisApp2.")).arg(qsTr("More information")) + return ("%1
%2").arg( + //: INFO DESKTOP_QML The pairing code needs to be supplied. + qsTr("Start the pairing on your smartphone and enter the shown pairing code in order to use your smartphone as a card reader (SaC).") + ).arg( + //: INFO DESKTOP_QML Link text + qsTr("More information") + ) } //: INFO DESKTOP_QML Error message during PIN/CAN/PUK input procedure, the requested password type is unknown; internal error. return qsTr("Unknown password type:") + " " + passwordType } - textStyle: numberField.confirmedInput ? Style.text.header_secondary : Style.text.header_warning + textStyle: numberField.confirmedInput ? Style.text.header_secondary_inverse : Style.text.header_warning onLinkActivated: baseItem.requestPasswordInfo() horizontalAlignment: Text.AlignHCenter @@ -220,35 +250,20 @@ SectionPage NumberField { id: numberField - anchors.centerIn: parent - - activeFocusOnTab: true - Accessible.name: numberField.text + anchors { + centerIn: parent + horizontalCenterOffset: eyeWidth / 2 + } passwordLength: passwordType === NumberModel.PASSWORD_PIN && NumberModel.requestTransportPin ? 5 : passwordType === NumberModel.PASSWORD_PUK ? 10 : passwordType === NumberModel.PASSWORD_REMOTE_PIN ? 4 : 6 + onPasswordLengthChanged: numberField.text = "" onVisibleChanged: if (visible) forceActiveFocus() - MouseArea { - anchors.fill: parent - - onClicked: numberField.forceActiveFocus() - } - Keys.onPressed: { - if (event.key >= Qt.Key_0 && event.key <= Qt.Key_9) { - numberField.append(event.key - Qt.Key_0) - return - } - - if (event.key === Qt.Key_Backspace) { - numberField.removeLast() - return - } - if (event.key === Qt.Key_Enter || event.key === Qt.Key_Return) { d.setPassword() } @@ -256,35 +271,33 @@ SectionPage } GText { - id: changePinLengthText - - function changePinLength() { - baseItem.changePinLength() - } - visible: passwordType === NumberModel.PASSWORD_PIN - anchors.horizontalCenter: numberField.horizontalCenter - anchors.top: numberField.bottom - anchors.topMargin: Constants.text_spacing + anchors { + horizontalCenter: parent.horizontalCenter + top: numberField.bottom + topMargin: Constants.component_spacing + } activeFocusOnTab: true - Keys.onSpacePressed: changePinLengthText.changePinLength() Accessible.name: text + Accessible.role: Accessible.Button - textStyle: Style.text.hint + textStyle: Style.text.hint_inverse textFormat: Text.StyledText - //: LABEL DESKTOP_QML Button, mit dem der Benutzer eine TransportPIN-Änderung starten kann. - text: "" + (NumberModel.requestTransportPin ? qsTr("Your PIN has 6 digits?") : qsTr("Your PIN has 5 digits?")) + "" + SettingsModel.translationTrigger - linkColor: Constants.white - onLinkActivated: changePinLengthText.changePinLength() + text: "" + (NumberModel.requestTransportPin ? + //: LABEL DESKTOP_QML Button to switch to a 6-digit PIN. + qsTr("Does your PIN have 6 digits?") : + //: LABEL DESKTOP_QML Button to switch to a transport PIN or start a change of the transport PIN. + qsTr("Does your PIN have 5 digits?") + ) + "" + SettingsModel.translationTrigger + linkColor: textStyle.textColor + onLinkActivated: baseItem.changePinLength() FocusFrame {} } } NumberPad { - id: numberPad - anchors.right: parent.right anchors.bottom: parent.bottom @@ -306,8 +319,11 @@ SectionPage activeFocusOnTab: true - buttonType: Qt.ForwardButton + buttonType: NavigationButton.Type.Forward enabled: numberField.validInput - onClicked: d.setPassword() + onClicked: { + d.setPassword() + numberField.focus = true + } } } diff --git a/resources/qml/Governikus/EnterPasswordView/+desktop/NumberField.qml b/resources/qml/Governikus/EnterPasswordView/+desktop/NumberField.qml deleted file mode 100644 index 847ebbe1e..000000000 --- a/resources/qml/Governikus/EnterPasswordView/+desktop/NumberField.qml +++ /dev/null @@ -1,82 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Global 1.0 -import Governikus.View 1.0 -import Governikus.Type.ApplicationModel 1.0 - -Item { - id: baseItem - - property alias text: echoField.text - property alias passwordLength: echoField.maximumLength - readonly property bool validInput: echoField.acceptableInput && confirmedInput - - property string inputConfirmation - readonly property bool confirmedInput: inputConfirmation.length != text.length || inputConfirmation === text - - function append(number) { - echoField.insert(echoField.length, number) - } - function removeLast() { - echoField.remove(echoField.length-1, echoField.length) - } - - height: echoField.height + lines.anchors.topMargin + lines.height - width: lines.width - - FocusFrame { - marginFactor: 2 - } - - TextInput { - id: sample - visible: false - echoMode: echoField.echoMode - font: echoField.font - text: "0" - } - - TextInput { - id: echoField - anchors.top: parent.top - anchors.left: lines.left - anchors.leftMargin: sample.font.letterSpacing / 4 - - color: Constants.white - verticalAlignment: TextInput.AlignVCenter - echoMode: TextInput.Password - font.bold: true - font.pixelSize: ApplicationModel.scaleFactor * 50 - font.letterSpacing: ApplicationModel.scaleFactor * 40 - passwordMaskDelay: 500 - cursorVisible: false - activeFocusOnPress: false - focus: false - validator: RegExpValidator { - regExp: new RegExp("[0-9]{" + echoField.maximumLength + "}") - } - maximumLength: 6 - } - - Row { - id: lines - anchors.top: echoField.bottom - anchors.topMargin: Constants.groupbox_spacing - anchors.horizontalCenter: parent.horizontalCenter - - spacing: echoField.font.letterSpacing / 2 - - Repeater { - model: baseItem.passwordLength - delegate: Rectangle { - width: sample.contentWidth - (sample.font.letterSpacing / 2) - height: Math.max(ApplicationModel.scaleFactor * 4, 1) - color: Constants.white - } - } - } -} diff --git a/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPad.qml b/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPad.qml index 86985166a..7a7f6a023 100644 --- a/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPad.qml +++ b/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPad.qml @@ -1,10 +1,11 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import Governikus.Global 1.0 +import Governikus.Style 1.0 import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SettingsModel 1.0 @@ -22,88 +23,28 @@ Item { QtObject { id: d - property var numbers - - Component.onCompleted: orderNumbers() - - function orderNumbers() { - if (SettingsModel.shuffleScreenKeyboard) { - var newNumbers = [] - for (var i = 0; i < 10; i++) { - var random = Math.floor(Math.random() * (newNumbers.length + 1)) - newNumbers.splice(random, 0, i); - } - numbers = newNumbers - } - else { - numbers = [1, 2, 3, 4, 5, 6, 7, 8, 9, 0] + readonly property var numbers: { + var numbers = [1, 2, 3, 4, 5, 6, 7, 8, 9, 0] + if (visible && SettingsModel.shuffleScreenKeyboard) { + Utils.shuffle(numbers) } - } - } - - NumberPadTab { - id: numberPadTab - - height: ApplicationModel.scaleFactor * 100 - - anchors.top: numPadContainer.top - anchors.right: numPadContainer.left - anchors.rightMargin: -radius - - activeFocusOnTab: true - Accessible.role: Accessible.Grouping - Accessible.name: qsTr("Numberpad to enter the password") + SettingsModel.translationTrigger - Keys.onSpacePressed: numPadContainer.toggle() - - MouseArea { - anchors.fill: parent - onClicked: numPadContainer.toggle() + return numbers } } Rectangle { id: numPadContainer - property bool fadeIn: true - + visible: SettingsModel.useScreenKeyboard width: grid.width + 2 * Constants.pane_padding height: grid.height + 2 * Constants.pane_padding anchors.right: parent.right - anchors.rightMargin: fadeIn ? 0 : -width anchors.bottom: parent.bottom - color: Qt.lighter(Constants.blue, 1.15) + color: Qt.lighter(Style.color.background, 1.15) border.width: Math.max(1, ApplicationModel.scaleFactor * 3) - border.color: Constants.blue - - Component.onCompleted: init() - onVisibleChanged: init() - - function init() { - setVisible(SettingsModel.useScreenKeyboard) - } - - function toggle() { - if (!fadingAnimation.running) { - setVisible(!fadeIn) - } - } - - function setVisible(pVisible) { - if (pVisible) { - d.orderNumbers() - } - fadeIn = pVisible - } - - Behavior on anchors.rightMargin { - PropertyAnimation { - id: fadingAnimation - duration: 1000 - easing.type: Easing.InOutQuad - } - } + border.color: Style.color.accent Grid { id: grid @@ -119,9 +60,9 @@ Item { model: 9 NumberPadButton { - activeFocusOnTab: numPadContainer.fadeIn - text: d.numbers[index] + visualPrivacy: SettingsModel.visualPrivacy + onClicked: baseItem.digitPressed(text) } } @@ -129,8 +70,6 @@ Item { NumberPadButton { id: deleteButton - activeFocusOnTab: numPadContainer.fadeIn - text: "C" color: "yellow" fontScale: 0.75 @@ -141,17 +80,14 @@ Item { NumberPadButton { id: zeroButton - activeFocusOnTab: numPadContainer.fadeIn - text: d.numbers[9] + visualPrivacy: SettingsModel.visualPrivacy onClicked: baseItem.digitPressed(text) } NumberPadButton { id: submitButton - activeFocusOnTab: numPadContainer.fadeIn - text: "OK" color: "lime" fontScale: 0.75 diff --git a/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPadButton.qml b/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPadButton.qml index 74e00bb84..8c5c0e2b1 100644 --- a/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPadButton.qml +++ b/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPadButton.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -19,11 +19,12 @@ Button { padding: 0 property real fontScale: 1 + property bool visualPrivacy: false property alias color: circle.color contentItem: GText { text: control.text - textStyle: Style.text.header_inverse + textStyle: Style.text.header horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter font.pixelSize: fontScale * ApplicationModel.scaleFactor * 50 @@ -33,10 +34,10 @@ Button { background: Rectangle { id: circle - border.color: Constants.black - border.width: control.focus ? Math.max(1, ApplicationModel.scaleFactor * 2) : 0 + border.color: Style.text.header.textColor + border.width: !visualPrivacy && control.focus ? Math.max(1, ApplicationModel.scaleFactor * 2) : 0 radius: control.height / 2 - color: Constants.white + color: Style.color.background_pane visible: control.enabled Rectangle { @@ -46,7 +47,7 @@ Button { opacity: 0.1 SequentialAnimation on height { - running: control.pressed + running: !visualPrivacy && control.pressed alwaysRunToEnd: true NumberAnimation { from: 0; to: background.height } @@ -55,7 +56,7 @@ Button { } SequentialAnimation on width { - running: control.pressed + running: !visualPrivacy && control.pressed alwaysRunToEnd: true NumberAnimation { from: 0; to: background.width } diff --git a/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPadTab.qml b/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPadTab.qml deleted file mode 100644 index 4c9f69bf3..000000000 --- a/resources/qml/Governikus/EnterPasswordView/+desktop/NumberPadTab.qml +++ /dev/null @@ -1,121 +0,0 @@ -/* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Global 1.0 -import Governikus.Type.ApplicationModel 1.0 - - -Rectangle { - width: height / 2 + radius - - border.color: focus ? Constants.white : Constants.blue - border.width: Math.max(1, ApplicationModel.scaleFactor * 3) - color: Qt.lighter(Constants.blue, 1.15) - radius: height / 5 - - Timer { - id: onTimer - - property int index - - interval: 1500 - running: true - triggeredOnStart: true - - onTriggered: { - onTimer.triggeredOnStart = false - onTimer.index = Utils.getRandomInt(0, 12) - repeater.itemAt(onTimer.index).state = "on" - offTimer.restart() - } - } - - Timer { - id: offTimer - - interval: 500 - onTriggered: { - if (onTimer.index != undefined) - { - repeater.itemAt(onTimer.index).state = "" - } - - onTimer.restart() - } - } - - Rectangle { - id: reader - - width: 0.75 * height - height: parent.height - 2 * parent.radius - - anchors.left: parent.left - anchors.leftMargin: Math.max(1, ApplicationModel.scaleFactor * 4) - anchors.verticalCenter: parent.verticalCenter - - color: "skyblue" - radius: height * 0.1 - - Grid { - id: pinGrid - - anchors.fill: parent - - columns: 3 - padding: parent.width * 0.1 - spacing: parent.width * 0.1 - - Repeater { - id: repeater - - model: 12 - - Item { - id: pinButton - - width: (reader.width - 4 * pinGrid.spacing) / 3 - height: width - - Rectangle { - id: pinButtonCircle - - width: pinButton.width - height: width - - anchors.centerIn: parent - - state: parent.state - radius: width * 0.5 - color: index == 9 ? "yellow" : index == 11 ? "lime" : Constants.white - - Behavior on color { - ColorAnimation { - duration: 250 - } - } - - Behavior on width { - NumberAnimation { - duration: 1000 - easing.type: Easing.OutElastic - } - } - - states: [ - State { - name: "on" - - PropertyChanges {target: pinButtonCircle; color: Constants.blue} - PropertyChanges {target: pinButtonCircle; width: pinButton.width + pinButton.width * 0.3} - } - ] - } - } - } - } - } -} diff --git a/resources/qml/Governikus/EnterPasswordView/+desktop/PasswordInfoView.qml b/resources/qml/Governikus/EnterPasswordView/+desktop/PasswordInfoView.qml index 4572ced28..a52ae3eff 100644 --- a/resources/qml/Governikus/EnterPasswordView/+desktop/PasswordInfoView.qml +++ b/resources/qml/Governikus/EnterPasswordView/+desktop/PasswordInfoView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -31,17 +31,8 @@ SectionPage { titleBarAction: TitleBarAction { rootEnabled: false showSettings: false - text: d.passwordString - } - - QtObject { - id: d - - readonly property string passwordString: passwordType === NumberModel.PASSWORD_PIN ? "PIN" - : passwordType === NumberModel.PASSWORD_CAN ? "CAN" - : passwordType === NumberModel.PASSWORD_PUK ? "PUK" - : passwordType === NumberModel.PASSWORD_REMOTE_PIN ? "Remote PIN" - : "UNKNOWN" + text: headline.text + showHelp: false } GText { @@ -56,12 +47,17 @@ SectionPage { Accessible.name: headline.text wrapMode: Text.WordWrap - //: %1 can be "PIN, CAN, PUK or UNKNOWN" - text: qsTr("%1 information").arg(d.passwordString) + SettingsModel.translationTrigger - textStyle: Style.text.header - FocusFrame { - dynamic: false - } + //: LABEL DESKTOP_QML + text: (passwordType === NumberModel.PASSWORD_PIN ? qsTr("PIN information") + //: LABEL DESKTOP_QML + : passwordType === NumberModel.PASSWORD_CAN ? qsTr("CAN information") + //: LABEL DESKTOP_QML + : passwordType === NumberModel.PASSWORD_PUK ? qsTr("PUK information") + //: LABEL DESKTOP_QML + : passwordType === NumberModel.PASSWORD_REMOTE_PIN ? qsTr("Smartphone as card reader information") + : console.error("Unknown type")) + SettingsModel.translationTrigger + textStyle: Style.text.header_inverse + FocusFrame {} } GText { @@ -78,27 +74,30 @@ SectionPage { text: { SettingsModel.translationTrigger - if (passwordType === NumberModel.PASSWORD_CAN) { - //: INFO DESKTOP_QML Description text of CAN - return qsTr("The card access number (CAN) is only required if you have already entered the PIN incorrectly twice. In order to prevent a third incorrect entry and thus the blocking of the ID card without your consent, the CAN is also requested at this point. The CAN is a six-digit number that can be found on the front of the ID card. It is located at the bottom right next to the validity date (marked in red).") + if (passwordType === NumberModel.PASSWORD_CAN && NumberModel.isCanAllowedMode) { + //: INFO DESKTOP_QML Description text of CAN-allowed authentication + return qsTr("The card access number (CAN) allows to access the imprinted data of the ID card. In order to allow on-site reading of the personal data the service provider needs to acquire governmental authorization to do so. On-site reading is usually employed to automatically fill forms and prevent spelling mistakes when transfering the personal data.") + } + if (passwordType === NumberModel.PASSWORD_CAN && !NumberModel.isCanAllowedMode) { + //: INFO DESKTOP_QML Description text of CAN if required for third PIN attempt + return qsTr("The card access number (CAN) is required if the PIN has already been entered incorrectly twice. In order to prevent a third incorrect entry and thus the blocking of the PIN without your consent, the CAN is also requested at this point. The CAN is a 6-digit number that can be found on the front of the ID card. It is located at the bottom right next to the validity date (marked in red).") } if (passwordType === NumberModel.PASSWORD_PUK) { //: INFO DESKTOP_QML Description text of PUK - return qsTr("The personal unblocking key (PUK) is only required if you entered the the wrong PIN three times. The online eID function is blocked at this time. The PUK is a ten-digit number you received with the letter sent to you by your competent authority (marked in red). Please note that you can only use the PUK to unblock the PIN entry. If you have forgotten your PIN, you can have a new PIN set at your competent authority.") + return qsTr("The personal unblocking key (PUK) is required if the PIN has been entered three times. At this point the PIN is blocked. The PUK is a 10-digit number you received with the letter sent to you by your competent authority (marked in red). Please note that you can only use the PUK to unblock the PIN entry. If you have forgotten your PIN, you can have a new PIN set at your competent authority.") } if (passwordType === NumberModel.PASSWORD_REMOTE_PIN) { //: INFO DESKTOP_QML Description text of SaC pairing - return qsTr("You may use your smartphone as a card reader with AusweisApp2. The smartphone needs to feature a supported NFC chipset and both devices, your smartphone and this machine, need to be connected to the same WiFi network.

Please make sure that the remote service is running on your smartphone. Start the pairing process by clicking the \"Start pairing\" button and enter the shown 4-digit PIN.") + return qsTr("You may use your smartphone as a card reader with AusweisApp2. The smartphone needs to feature a supported NFC chipset and both devices, your smartphone and this machine, need to be connected to the same WiFi network.

To use your smartphone as a card reader you'll always need to activate the remote service in the AusweisApp2 on the smartphone. For the first time you'll also need to start the pairing mode on your smartphone, select the device from the list of available devices on this machine and then enter the pairing code shown on the phone.") } //: INFO DESKTOP_QML Description text of PIN - return qsTr("The personal identification number (PIN) is required for every use of the online eID function. You can change it anytime and indefinitely if you know your valid PIN. For your 6-digit PIN choose a combination of numbers, that is not easy to guess, neither \"123456\" nor your birth date, or any other numbers printed on the ID card. If you are no longer aware of your valid PIN, you will need to contact the authority responsible for issuing your identification document to renew your PIN.\n\nWhen changing the PIN for the first time, please use your 5-digit transport PIN. You will find the transport PIN in the letter you received from the authority responsible for issuing your identification document (marked in red) after you have applied for your identity card.\n\nPlease note that you can not use the online eID function with your 5-digit transport PIN. A change to a 6-digit PIN is mandatory.") + return qsTr("The personal identification number (PIN) is chosen by you and is required for every use of the online eID function. You can change it anytime and indefinitely if you know your valid PIN. For your 6-digit PIN choose a combination of numbers, that is not easy to guess, neither \"123456\" nor your birth date, or any other numbers printed on the ID card. If you are no longer aware of your valid PIN, you will need to contact the authority responsible for issuing your identification card to renew your PIN.

When changing the PIN for the first time, please use your 5-digit transport PIN. You will find the transport PIN in the letter you received from the authority responsible for issuing your identification card (marked in red) after you have applied for your identity card.

Please note that you can not use the online eID function with your 5-digit transport PIN. A change to a 6-digit PIN is mandatory.") } - textStyle: Style.text.header + textStyle: Style.text.header_inverse + horizontalAlignment: Text.AlignJustify - FocusFrame { - dynamic: false - } + FocusFrame {} } Image { @@ -112,9 +111,8 @@ SectionPage { verticalAlignment: Image.AlignTop fillMode: Image.PreserveAspectFit source: passwordType === NumberModel.PASSWORD_CAN ? "qrc:///images/desktop/id_card.png" - : passwordType === NumberModel.PASSWORD_PUK ? "qrc:///images/desktop/pin-letter-page2.png" - : passwordType === NumberModel.PASSWORD_REMOTE_PIN ? "qrc:///images/phone_to_pc.svg" - : "qrc:///images/desktop/pin-letter-page1.png" + : passwordType === NumberModel.PASSWORD_REMOTE_PIN ? "qrc:///images/phone_to_pc.svg" + : "qrc:///images/desktop/pin_letter_pinpuk_same_page.svg" Rectangle { visible: passwordType === NumberModel.PASSWORD_CAN @@ -129,6 +127,68 @@ SectionPage { border.color: Constants.red border.width: Math.max(1, 6 * ApplicationModel.scaleFactor) } + + GText { + visible: passwordType === NumberModel.PASSWORD_PIN || passwordType === NumberModel.PASSWORD_PUK + + anchors.top: parent.bottom + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: Constants.component_spacing + + textStyle: Style.text.normal_inverse + text: (imageChangeTimer.alternativeLetter ? + //: LABEL DESKTOP_QML + qsTr("PIN/PUK on different pages") : + //: LABEL DESKTOP_QML + qsTr("PIN/PUK on the same page") + ) + SettingsModel.translationTrigger + } + } + + states: State { + name: "alternativePinLetter" + when: imageChangeTimer.alternativeLetter + + PropertyChanges { + target: pinPukVariantB + opacity: 1 + } + } + + Timer { + id: imageChangeTimer + + property bool alternativeLetter: true + + interval: 6000 + running: passwordType === NumberModel.PASSWORD_PIN || passwordType === NumberModel.PASSWORD_PUK + repeat: true + onTriggered: alternativeLetter = !alternativeLetter + } + + transitions: Transition { + NumberAnimation { + properties: "opacity" + easing.type: Easing.InOutQuad + duration: Constants.animation_duration + } + } + + Image { + id: pinPukVariantB + + visible: passwordType === NumberModel.PASSWORD_PIN || passwordType === NumberModel.PASSWORD_PUK + + opacity: 0.0 + sourceSize.width: (passwordType === NumberModel.PASSWORD_CAN ? 800 : 560) * ApplicationModel.scaleFactor + anchors.top: headline.bottom + anchors.right: parent.right + anchors.margins: Constants.pane_padding + + verticalAlignment: Image.AlignTop + fillMode: Image.PreserveAspectFit + + source: "qrc:///images/desktop/pin_letter_pinpuk_different_page.svg" } NavigationButton { @@ -140,7 +200,7 @@ SectionPage { horizontalCenter: parent.horizontalCenter } - buttonType: Qt.BackButton + buttonType: NavigationButton.Type.Back onClicked: root.close() } } diff --git a/resources/qml/Governikus/EnterPasswordView/+mobile/EnterPasswordView.qml b/resources/qml/Governikus/EnterPasswordView/+mobile/EnterPasswordView.qml index e2a844eca..2f7e14ec2 100644 --- a/resources/qml/Governikus/EnterPasswordView/+mobile/EnterPasswordView.qml +++ b/resources/qml/Governikus/EnterPasswordView/+mobile/EnterPasswordView.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.1 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -30,20 +30,24 @@ SectionPage ColumnLayout { anchors.fill: parent - Item {/*spacer*/ Layout.fillHeight: true; width: parent.width } + anchors.margins: 0 + + spacing: 0 RowLayout { - spacing: Constants.component_spacing - width: parent.width + Layout.fillWidth: true + Layout.margins: Constants.pane_padding + + spacing: 0 + + Item {/*spacer*/ Layout.fillWidth: true; } - Item {/*spacer*/ Layout.fillWidth: true; height: parent.height} Image { Layout.alignment: Qt.AlignVCenter - width: 58 - height: width - // because RowLayout uses implicitHeight that is based on sourceSize we have to explicitly set the sourceSize - sourceSize.height: baseItem.state === "REMOTE_PIN" ? 58 : 143 - Layout.maximumWidth: width + Layout.preferredHeight: 58 + Layout.preferredWidth: 58 + Layout.rightMargin: Constants.component_spacing + source: baseItem.state === "REMOTE_PIN" ? "qrc:///images/icon_remote.svg" : "qrc:///images/NFCPhoneCard.png" fillMode: Image.PreserveAspectFit } @@ -65,7 +69,7 @@ SectionPage if (!pinField.confirmedInput) { //: INFO ANDROID IOS The changed PIN was entered wrongfully during confirmation. - return qsTr("The entered PIN does not match the new PIN. Please correct your input.") + return qsTr("The new PIN and the confirmation do not match. Please correct your input.") } if (!!NumberModel.inputError) { return NumberModel.inputError @@ -73,75 +77,103 @@ SectionPage if (baseItem.state === "CAN") { if (NumberModel.isCanAllowedMode) { //: INFO ANDROID IOS The CAN needs to be entered in CAN-allowed mode, hint where the CAN can be found. - return qsTr("Please enter the six-digit card access number. You can find the card access number on the front of the ID card.") + return qsTr("Please enter the 6-digit card access number (CAN). You can find it on the front of the ID card.") } //: INFO ANDROID IOS The wrong PIN was entered twice, the third attempt requires the CAN for additional verification, hint where the CAN is found. - return qsTr("You have entered the wrong PIN twice. Prior to a third attempt, you have to enter your six-digit card access number first. You can find your card access number on the front of your ID card.") + return qsTr("A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card.") } if (baseItem.state === "PUK") { - //: INFO ANDROID IOS The PUK is required to unlock the id card since the wrong PIN entered three times. - return qsTr("You have entered a wrong PIN three times. Your PIN is now blocked. You have to enter the PUK now for unblocking.") + //: INFO ANDROID IOS The PUK is required to unlock the ID card since the wrong PIN entered three times. + return qsTr("A wrong PIN has been entered three times on your ID card. Your PIN is now blocked. To unblock your PIN you have to enter the PUK.") } if (baseItem.state === "PIN_NEW") { //: INFO ANDROID IOS A new 6-digit PIN needs to be supplied. - return qsTr("Please enter a new 6-digit PIN of your choice.") + return qsTr("Please enter a new 6-digit PIN now.") } if (baseItem.state === "PIN_NEW_AGAIN") { //: INFO ANDROID IOS The new PIN needs to be confirmed. - return qsTr("Please enter your new 6-digit PIN again.") + return qsTr("Please confirm your new 6-digit PIN.") } if (baseItem.state === "PIN" && NumberModel.requestTransportPin) { //: INFO ANDROID IOS The transport PIN is required by AA2, it needs to be change to an actual PIN. - return qsTr("Please enter your transport PIN.") + return qsTr("Please enter the transport PIN from your PIN letter.") } if (baseItem.state === "REMOTE_PIN") { //: INFO ANDROID IOS The pairing code for the smartphone is required. - return qsTr("Enter the pairing code shown on your other device to use it as a card reader.") + return qsTr("Enter the pairing code shown on the device you want to pair.") } //: LABEL ANDROID IOS return qsTr("Please enter your PIN.") } } - Item {/*spacer*/ Layout.fillWidth: true; height: parent.height} + + Item {/*spacer*/ Layout.fillWidth: true; } } - Item {/*spacer*/ Layout.fillHeight: true; width: parent.width } + Item {/*spacer*/ Layout.fillHeight: true } - NumberField { - id: pinField + Rectangle { Layout.alignment: Qt.AlignHCenter - passwordLength: baseItem.state === "REMOTE_PIN" ? 4 - : baseItem.state === "PIN" && NumberModel.requestTransportPin ? 5 - : baseItem.state === "PUK" ? 10 - : 6 - Layout.preferredHeight: height - Layout.preferredWidth: width + Layout.preferredHeight: pinField.height + Constants.component_spacing + Layout.preferredWidth: pinField.width + Constants.component_spacing + + radius: Style.dimens.button_radius + border.color: Style.color.border + border.width: Style.dimens.separator_size + + NumberField { + id: pinField + + anchors.centerIn: parent + + passwordLength: baseItem.state === "REMOTE_PIN" ? 4 + : baseItem.state === "PIN" && NumberModel.requestTransportPin ? 5 + : baseItem.state === "PUK" ? 10 + : 6 + + onPasswordLengthChanged: pinField.text = "" + } } GText { id: transportPinLink + property alias enableTransportPinLink: myMouse.enabled visible: baseItem.state === "PIN" && enableTransportPinLink - //: LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung starten kann. - text: (NumberModel.requestTransportPin ? qsTr("Your PIN has 6 digits?") : qsTr("Your PIN has 5 digits?")) + SettingsModel.translationTrigger Layout.alignment: Qt.AlignHCenter + Layout.topMargin: Constants.text_spacing + Layout.margins: Constants.pane_padding + + Accessible.role: Accessible.Button + Accessible.onPressAction: if (Qt.platform.os === "ios") myMouse.clicked(null) + + text: (NumberModel.requestTransportPin ? + //: LABEL ANDROID IOS Button to switch to a 6-digit PIN. + qsTr("Does your PIN have 6 digits?") : + //: LABEL ANDROID IOS Button to switch to a transport PIN or start a change of the transport PIN. + qsTr("Does your PIN have 5 digits?") + ) + SettingsModel.translationTrigger textStyle: Style.text.hint_accent font.underline: true MouseArea { id: myMouse - enabled: true + anchors.fill: parent anchors.margins: -12 + + enabled: true + onClicked: baseItem.changePinLength() } } - Item {/*spacer*/ height: Constants.component_spacing; width: parent.width } + Item {/*spacer*/ Layout.fillHeight: true } NumberPad { state: baseItem.state + Layout.alignment: Qt.AlignHCenter Layout.preferredWidth: width Layout.preferredHeight: height @@ -180,7 +212,5 @@ SectionPage } } } - - Item {/*spacer*/ Layout.fillHeight: true; width: parent.width } } } diff --git a/resources/qml/Governikus/EnterPasswordView/+mobile/NumberField.qml b/resources/qml/Governikus/EnterPasswordView/+mobile/NumberField.qml deleted file mode 100644 index 4d3516898..000000000 --- a/resources/qml/Governikus/EnterPasswordView/+mobile/NumberField.qml +++ /dev/null @@ -1,71 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 - -Item { - id: baseItem - - property alias text: echoField.text - property int passwordLength: 6 - property string inputConfirmation - readonly property bool confirmedInput: inputConfirmation.length != text.length || inputConfirmation === text - readonly property bool validInput: echoField.acceptableInput && confirmedInput - - function append(number) { - echoField.insert(echoField.length, number) - } - function removeLast() { - echoField.remove(echoField.length-1, echoField.length) - } - - height: sample.implicitHeight * 1.5 - width: lines.width - clip: true - - TextInput { - id: echoField - color: Style.color.primary_text - verticalAlignment: TextInput.AlignVCenter - echoMode: TextInput.Password - font.pixelSize: 18 - font.letterSpacing: 10 - passwordMaskDelay: 500 - cursorVisible: false - activeFocusOnPress: false - focus: false - validator: RegExpValidator { - regExp: new RegExp("[0-9]{" + echoField.maximumLength + "}") - } - maximumLength: baseItem.passwordLength - clip: true - } - - TextInput { - id: sample - visible: false - echoMode: echoField.echoMode - font: echoField.font - text: "0" - } - - Row { - id: lines - anchors.bottom: baseItem.bottom - spacing: echoField.font.letterSpacing - anchors.left: echoField.left - - Repeater { - model: baseItem.passwordLength - delegate: Rectangle { - width: sample.contentWidth - sample.font.letterSpacing - height: 1 - color: "black" - } - } - } -} diff --git a/resources/qml/Governikus/EnterPasswordView/+mobile/NumberPad.qml b/resources/qml/Governikus/EnterPasswordView/+mobile/NumberPad.qml index 034690199..cadab9306 100644 --- a/resources/qml/Governikus/EnterPasswordView/+mobile/NumberPad.qml +++ b/resources/qml/Governikus/EnterPasswordView/+mobile/NumberPad.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.1 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Type.SettingsModel 1.0 @@ -18,6 +18,18 @@ GridLayout { signal deletePressed() signal submitPressed() + QtObject { + id: d + + readonly property var numbers: { + var numbers = [1, 2, 3, 4, 5, 6, 7, 8, 9, 0] + if (visible && SettingsModel.shuffleScreenKeyboard) { + Utils.shuffle(numbers) + } + return numbers + } + } + columns: 3 columnSpacing: 10 rowSpacing: columnSpacing @@ -26,44 +38,43 @@ GridLayout { Layout.fillHeight: false Layout.fillWidth: false - NumberPadButton { text: "1"; onClicked: baseItem.digitPressed("1"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { text: "2"; onClicked: baseItem.digitPressed("2"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { text: "3"; onClicked: baseItem.digitPressed("3"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { text: "4"; onClicked: baseItem.digitPressed("4"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { text: "5"; onClicked: baseItem.digitPressed("5"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { text: "6"; onClicked: baseItem.digitPressed("6"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { text: "7"; onClicked: baseItem.digitPressed("7"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { text: "8"; onClicked: baseItem.digitPressed("8"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { text: "9"; onClicked: baseItem.digitPressed("9"); Layout.fillHeight: true; Layout.fillWidth: true } - NumberPadButton { - visible: baseItem.deleteEnabled - Layout.fillHeight: true - Layout.fillWidth: true + Repeater { + id: numberRepeater + + model: 9 + + NumberPadButton { + text: d.numbers[index]; + visualPrivacy: SettingsModel.visualPrivacy - Accessible.name: qsTr("Delete last digit") + SettingsModel.translationTrigger + onClicked: baseItem.digitPressed(text) + } + } + + NumberPadButton { + enabled: baseItem.deleteEnabled - source: "qrc:///images/delete.svg" + text: qsTr("Delete last digit") + SettingsModel.translationTrigger + icon.source: "qrc:///images/delete.svg" onClicked: baseItem.deletePressed() } + NumberPadButton { - Layout.fillHeight: true - Layout.fillWidth: true Layout.column: 1 Layout.row: 3 - text: "0" + text: d.numbers[9] + visualPrivacy: SettingsModel.visualPrivacy - onClicked: baseItem.digitPressed("0") + onClicked: baseItem.digitPressed(text) } - NumberPadButton { - visible: baseItem.submitEnabled - Layout.fillHeight: true - Layout.fillWidth: true - Accessible.name: qsTr("Submit") + SettingsModel.translationTrigger + NumberPadButton { + enabled: baseItem.submitEnabled - source: "qrc:///images/submit.svg" + text: qsTr("Submit") + SettingsModel.translationTrigger + icon.source: "qrc:///images/submit.svg" onClicked: baseItem.submitPressed() } diff --git a/resources/qml/Governikus/EnterPasswordView/+mobile/NumberPadButton.qml b/resources/qml/Governikus/EnterPasswordView/+mobile/NumberPadButton.qml index 90da38c53..234eda38a 100644 --- a/resources/qml/Governikus/EnterPasswordView/+mobile/NumberPadButton.qml +++ b/resources/qml/Governikus/EnterPasswordView/+mobile/NumberPadButton.qml @@ -1,54 +1,73 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 +import Governikus.Type.SettingsModel 1.0 -MouseArea { - id: baseItem +Button { + id: numberPadButton - property alias text: textItem.text - property alias source: imageItem.source + property bool visualPrivacy: false - Accessible.role: Accessible.Button - Accessible.name: text - Accessible.onPressAction: if (Qt.platform.os === "ios" && enabled) clicked(null) + implicitHeight: 36 + implicitWidth: 36 + Layout.fillHeight: true + Layout.fillWidth: true - GText { - id: textItem + Accessible.name: numberPadButton.text + Accessible.description: numberPadButton.enabled ? "": qsTr("Disabled") + SettingsModel.translationTrigger + Accessible.ignored: Qt.platform.os === "ios" ? false : !numberPadButton.enabled + Accessible.onPressAction: if (Qt.platform.os === "ios" && numberPadButton.enabled) clicked(null) - anchors.centerIn: parent + contentItem: GText { + visible: numberPadButton.icon.source == "" && numberPadButton.enabled Accessible.ignored: true + text: numberPadButton.text textStyle: Style.text.title + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter } - Image { - id: imageItem - anchors.centerIn: parent - height: 36 - width: height + background: Image { + visible: numberPadButton.icon.source != "" && numberPadButton.enabled + anchors.centerIn: numberPadButton + + height: parent.implicitHeight + width: parent.implicitWidth fillMode: Image.PreserveAspectFit + source: numberPadButton.icon.source } Rectangle { id: darkLayer - anchors.centerIn: parent + height: width - radius: width /2 + radius: width / 2 + anchors.centerIn: parent + color: Constants.black opacity: 0.1 + SequentialAnimation on width { - running: baseItem.pressed + running: !visualPrivacy && numberPadButton.down alwaysRunToEnd: true - NumberAnimation { from: 0; to: Math.SQRT2 * baseItem.width } - PauseAnimation { duration: 100 } - PropertyAction { value: 0 } + PropertyAction { target: darkLayer; property: "opacity"; value: 0.1 } + NumberAnimation { from: 0; to: Math.SQRT2 * numberPadButton.width } + } + + NumberAnimation on opacity { + running: !visualPrivacy && !numberPadButton.down + from: 0.1 + to: 0.0 } } } diff --git a/resources/qml/Governikus/EnterPasswordView/qmldir b/resources/qml/Governikus/EnterPasswordView/qmldir index 5ff2ee690..dbd37681a 100644 --- a/resources/qml/Governikus/EnterPasswordView/qmldir +++ b/resources/qml/Governikus/EnterPasswordView/qmldir @@ -1,9 +1,7 @@ module EnterPasswordView -internal NumberField NumberField.qml internal NumberPad NumberPad.qml internal NumberPadButton NumberPadButton.qml -internal NumberPadTab NumberPadTab.qml PasswordInfoView 1.0 PasswordInfoView.qml EnterPasswordView 1.0 EnterPasswordView.qml diff --git a/resources/qml/Governikus/FeedbackView/+desktop/DetachedLogView.qml b/resources/qml/Governikus/FeedbackView/+desktop/DetachedLogView.qml new file mode 100644 index 000000000..52fbe79a5 --- /dev/null +++ b/resources/qml/Governikus/FeedbackView/+desktop/DetachedLogView.qml @@ -0,0 +1,105 @@ +/* + * \copyright Copyright (c) 2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.LogModel 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.View 1.0 + + +Item { + id: root + + Keys.onPressed: listView.handleKeyPress(event.key) + + ColumnLayout { + anchors.fill: parent + + spacing: 0 + + RowLayout { + Layout.fillWidth: true + Layout.margins: Constants.groupbox_spacing + + spacing: Constants.groupbox_spacing + + GText { + text: qsTr("Select logfile:") + SettingsModel.translationTrigger + textStyle: Style.text.normal + } + + GComboBox { + Layout.preferredWidth: ApplicationModel.scaleFactor * 350 + + model: LogModel.logFiles + + onCurrentIndexChanged: LogModel.setLogfile(currentIndex) + } + + GText { + text: qsTr("Font size:") + SettingsModel.translationTrigger + textStyle: Style.text.normal + } + + SpinBox { + id: fontSize + + from: 8 + to: 20 + value: 10 + } + + Item { + Layout.fillWidth: true + } + + GButton { + icon.source: "qrc:///images/icon_save.svg" + //: LABEL DESKTOP_QML + text: qsTr("Save logfile") + SettingsModel.translationTrigger + tintIcon: true + + onClicked: { + let filenameSuggestion = LogModel.createLogFileName(LogModel.getCurrentLogfileDate()) + appWindow.openSaveFileDialog(LogModel.saveCurrentLogfile, filenameSuggestion, "log") + } + } + } + + GSeparator { + Layout.fillWidth: true + Layout.leftMargin: Constants.groupbox_spacing + Layout.rightMargin: Constants.groupbox_spacing + } + + GListView { + id: listView + + Layout.fillHeight: true + Layout.fillWidth: true + Layout.leftMargin: Constants.groupbox_spacing + Layout.bottomMargin: Constants.groupbox_spacing + Layout.topMargin: Constants.groupbox_spacing + + clip: true + scrollBarEnabled: true + model: LogModel + delegate: LogViewDelegate { + width: listView.width - Constants.groupbox_spacing + pixelSize: fontSize.value + } + + Connections { + target: LogModel + onFireNewLogMsg: if (listView.atYEnd) listView.positionViewAtEnd() + } + } + } +} diff --git a/resources/qml/Governikus/FeedbackView/+desktop/LogView.qml b/resources/qml/Governikus/FeedbackView/+desktop/LogView.qml index e5665916e..4a4a29845 100644 --- a/resources/qml/Governikus/FeedbackView/+desktop/LogView.qml +++ b/resources/qml/Governikus/FeedbackView/+desktop/LogView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -19,12 +19,17 @@ SectionPage { id: root + signal keyPressed(int key) + Accessible.name: qsTr("Logfile viewer") + SettingsModel.translationTrigger Accessible.description: qsTr("This is the logfile viewer of the AusweisApp2.") + SettingsModel.translationTrigger + Keys.onPressed: keyPressed(event.key) + titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML text: qsTr("Application log") + SettingsModel.translationTrigger + helpTopic: "applicationLog" } TabbedPane { @@ -37,6 +42,7 @@ SectionPage onCurrentIndexChanged: LogModel.setLogfile(currentIndex) contentDelegate: logSectionDelegate + contentPadding: 0 footerItem: Item { height: buttonLayout.implicitHeight @@ -44,23 +50,25 @@ SectionPage ColumnLayout { id: buttonLayout - anchors.fill: parent - anchors.rightMargin: Constants.groupbox_spacing + anchors { + left: parent.left + right: parent.right + rightMargin: Constants.groupbox_spacing + } spacing: Constants.groupbox_spacing GButton { id: saveLog Layout.fillWidth: true - activeFocusOnTab: true icon.source: "qrc:///images/icon_save.svg" //: LABEL DESKTOP_QML text: qsTr("Save logfile") + SettingsModel.translationTrigger enabled: tabbedPane.sectionsModel.length > 0 + tintIcon: true onClicked: { - var creationDate = LogModel.getCurrentLogfileDate().toLocaleString(Qt.locale(), "yyyy-MM-dd_HH-mm") - var filenameSuggestion = "%1.%2.log".arg(Qt.application.name).arg(creationDate) + let filenameSuggestion = LogModel.createLogFileName(LogModel.getCurrentLogfileDate()) appWindow.openSaveFileDialog(LogModel.saveCurrentLogfile, filenameSuggestion, "log") } } @@ -69,12 +77,14 @@ SectionPage id: removeLog Layout.fillWidth: true - activeFocusOnTab: true icon.source: "qrc:///images/trash_icon_white.svg" //: LABEL DESKTOP_QML text: qsTr("Delete logfile") + SettingsModel.translationTrigger - enabled: tabbedPane.currentIndex > 0 + enableButton: tabbedPane.currentIndex > 0 + disabledTooltipText: qsTr("The current logfile will be automatically deleted at exit.") + SettingsModel.translationTrigger + + tintIcon: true onClicked: { confirmationPopup.deleteAll = false confirmationPopup.open() @@ -85,17 +95,29 @@ SectionPage id: removeAllLogs Layout.fillWidth: true - activeFocusOnTab: true icon.source: "qrc:///images/trash_icon_all.svg" //: LABEL DESKTOP_QML text: qsTr("Delete old logfiles") + SettingsModel.translationTrigger enabled: tabbedPane.sectionsModel.length > 1 + tintIcon: true onClicked: { confirmationPopup.deleteAll = true confirmationPopup.open() } } + + GButton { + property QtObject detachedLogViewItem: null + + Layout.fillWidth: true + + icon.source: "qrc:///images/link_external.svg" + text: qsTr("Detach log viewer") + SettingsModel.translationTrigger + tintIcon: true + + onClicked: appWindow.showDetachedLogView() + } } } } @@ -107,72 +129,61 @@ SectionPage height: tabbedPane.availableHeight width: parent.width - ListView { + GListView { id: logView - anchors.fill: parent + anchors { + fill: parent + topMargin: Constants.component_spacing + leftMargin: Constants.component_spacing + bottomMargin: Constants.component_spacing + } activeFocusOnTab: true displayMarginBeginning: Constants.pane_padding displayMarginEnd: Constants.pane_padding - boundsBehavior: Flickable.StopAtBounds + model: LogModel - delegate: GText { + spacing: Constants.text_spacing + delegate: LogViewDelegate { width: parent.width - 2 * Constants.pane_padding - bottomPadding: index % 2 ? Constants.groupbox_spacing : 0 - - textStyle: index % 2 ? Style.text.hint_inverse : Style.text.hint_secondary_inverse - text: display - } - ScrollBar.vertical: ScrollBar { - id: verticalScrollbar - - width: ApplicationModel.scaleFactor * 18 - anchors.horizontalCenter: parent.right - anchors.horizontalCenterOffset: Constants.pane_padding / 2 - - policy: ScrollBar.AlwaysOn - minimumSize: Style.dimens.minimumScrollBarSize - stepSize: logView.height / logView.contentHeight } Connections { target: LogModel onFireNewLogMsg: if (logView.atYEnd) logView.positionViewAtEnd() } + + Connections { + target: root + onKeyPressed: logView.handleKeyPress(key) + } } FocusFrame { scope: logView framee: logView - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } } - Keys.onPressed: { - if (event.key === Qt.Key_PageDown) - verticalScrollbar.increase() - else if (event.key === Qt.Key_PageUp) - verticalScrollbar.decrease() - else if (event.key === Qt.Key_End) - logView.positionViewAtEnd() - else if (event.key === Qt.Key_Home) - logView.positionViewAtBeginning() - } - ConfirmationPopup { id: confirmationPopup property bool deleteAll: true - //: LABEL DESKTOP_QML - title: (deleteAll ? qsTr("Delete old logfiles") : qsTr("Delete selected logfile")) + SettingsModel.translationTrigger - //: INFO DESKTOP_QML The current/all logfile(s) are about to be removed, user confirmation required. - text: (deleteAll ? qsTr("Please confirm that you want to delete your old logfiles.") - : qsTr("Please confirm that you want to delete the logfile.") + title: (deleteAll ? + //: LABEL DESKTOP_QML + qsTr("Delete old logfiles") : + //: LABEL DESKTOP_QML + qsTr("Delete selected logfile") + ) + SettingsModel.translationTrigger + //: INFO DESKTOP_QML All logfiles are about to be removed, user confirmation required. + text: (deleteAll ? qsTr("All old logfiles will be deleted.") + //: INFO DESKTOP_QML The current logfile is about to be removed, user confirmation required. + : qsTr("The logfile will be deleted.") ) + SettingsModel.translationTrigger onConfirmed: deleteAll ? LogModel.removeOtherLogfiles() : LogModel.removeCurrentLogfile() } diff --git a/resources/qml/Governikus/FeedbackView/+desktop/LogViewDelegate.qml b/resources/qml/Governikus/FeedbackView/+desktop/LogViewDelegate.qml new file mode 100644 index 000000000..634d1b552 --- /dev/null +++ b/resources/qml/Governikus/FeedbackView/+desktop/LogViewDelegate.qml @@ -0,0 +1,25 @@ +/* + * \copyright Copyright (c) 2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 + +GText { + readonly property var reCriticalMessage: new RegExp("[0-9]{3,} C") + readonly property var reWarningMessage: new RegExp("[0-9]{3,} W") + readonly property bool isCriticalMessage: reCriticalMessage.test(display) + readonly property bool isWarningMessage: reWarningMessage.test(display) + + property real pixelSize: textStyle.textSize + + font.family: plugin.fixedFontFamily + textStyle: Style.text.hint + font.pixelSize: pixelSize + textFormat: Text.PlainText + color: isCriticalMessage ? Style.color.warning_text : (isWarningMessage ? Style.color.accent : textStyle.textColor) + text: "%1 %2".arg(origin).arg(message) +} + diff --git a/resources/qml/Governikus/FeedbackView/+mobile/+android/StoreFeedbackPopup.qml b/resources/qml/Governikus/FeedbackView/+mobile/+android/StoreFeedbackPopup.qml index ffac994d5..5ba1c7aff 100644 --- a/resources/qml/Governikus/FeedbackView/+mobile/+android/StoreFeedbackPopup.qml +++ b/resources/qml/Governikus/FeedbackView/+mobile/+android/StoreFeedbackPopup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -12,13 +12,13 @@ import Governikus.Type.SettingsModel 1.0 ConfirmationPopup { //: INFO ANDROID Header of the app rating popup. - title: qsTr("Would you like to rate this app?") + SettingsModel.translationTrigger + title: qsTr("Are you satisfied with AusweisApp2?") + SettingsModel.translationTrigger //: INFO ANDROID Content of the app rating popup. text: qsTr("We would be very grateful if you could leave a rating on the Google Play Store!") + SettingsModel.translationTrigger //: LABEL ANDROID - cancelButtonText: qsTr("No, thanks") + SettingsModel.translationTrigger + cancelButtonText: qsTr("Don't ask again") + SettingsModel.translationTrigger //: LABEL ANDROID - okButtonText: qsTr("Rate") + SettingsModel.translationTrigger + okButtonText: qsTr("Rate app") + SettingsModel.translationTrigger onConfirmed: Qt.openUrlExternally("market://details?id=" + ApplicationModel.packageName) } diff --git a/resources/qml/Governikus/FeedbackView/+mobile/+ios/StoreFeedbackPopup.qml b/resources/qml/Governikus/FeedbackView/+mobile/+ios/StoreFeedbackPopup.qml index 711486117..1b86cf5cd 100644 --- a/resources/qml/Governikus/FeedbackView/+mobile/+ios/StoreFeedbackPopup.qml +++ b/resources/qml/Governikus/FeedbackView/+mobile/+ios/StoreFeedbackPopup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -10,4 +10,4 @@ Item { function open() { ApplicationModel.showAppStoreRatingDialog(); } -} \ No newline at end of file +} diff --git a/resources/qml/Governikus/FeedbackView/+mobile/Feedback.qml b/resources/qml/Governikus/FeedbackView/+mobile/Feedback.qml deleted file mode 100644 index f443eca20..000000000 --- a/resources/qml/Governikus/FeedbackView/+mobile/Feedback.qml +++ /dev/null @@ -1,124 +0,0 @@ -/* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Layouts 1.2 -import QtQuick.Controls 2.3 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.TitleBar 1.0 -import Governikus.View 1.0 -import Governikus.Type.ApplicationModel 1.0 -import Governikus.Type.SettingsModel 1.0 -import Governikus.Type.LogModel 1.0 - - -SectionPage { - id: root - //: LABEL ANDROID IOS - title: qsTr("Help & Feedback") + SettingsModel.translationTrigger - - Component { - id: lineSeparator - GSeparator { - } - } - Component { - id: subMenu - Item { - height: column.height - Column { - id: column - anchors.left: parent.left - anchors.right: parent.right - spacing: Constants.component_spacing - GText { - width: parent.width - text: titleText - textStyle: Style.text.normal_accent - } - GText { - width: parent.width - text: descriptionText - } - } - MouseArea { - anchors.fill: parent - onClicked: onClickFunction() - } - } - } - LogView { - id: logPage - visible: false - } - - content: Item { - width: root.width - height: childrenRect.height - - Column { - anchors.left: parent.left - anchors.right: parent.right - anchors.margins: Constants.component_spacing - spacing: Constants.component_spacing - padding: Constants.component_spacing - - Pane { - Loader { - //: LABEL ANDROID IOS - readonly property string titleText: qsTr("FAQ") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - readonly property string descriptionText: qsTr("Do you have questions how to use AusweisApp2?") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - function onClickFunction() { Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/")) } - width: parent.width - sourceComponent: subMenu - } - Loader { width: parent.width; sourceComponent: lineSeparator } - Loader { - //: LABEL ANDROID IOS - readonly property string titleText: qsTr("Support") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - readonly property string descriptionText: qsTr("You need further help?") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - function onClickFunction() { Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/support/")) } - width: parent.width - sourceComponent: subMenu - } - Loader { width: parent.width; sourceComponent: lineSeparator } - Loader { - //: LABEL ANDROID IOS - readonly property string titleText: qsTr("Rate AusweisApp2") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - readonly property string descriptionText: qsTr("Please rate us in the Google Play Store.") + SettingsModel.translationTrigger - function onClickFunction() { Qt.openUrlExternally("market://details?id=" + ApplicationModel.packageName) } - width: parent.width - sourceComponent: subMenu - } - Loader { width: parent.width; sourceComponent: lineSeparator } - Loader { - //: LABEL ANDROID IOS - readonly property string titleText: qsTr("Report error") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - readonly property string descriptionText: qsTr("You found a bug? Please tell us, so we can fix it.") + SettingsModel.translationTrigger - function onClickFunction() { LogModel.mailLog() } - width: parent.width - sourceComponent: subMenu - } - Loader { width: parent.width; sourceComponent: lineSeparator } - Loader { - //: LABEL ANDROID IOS - readonly property string titleText: qsTr("Show log") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - readonly property string descriptionText: qsTr("You can view the logs of the AusweisApp2 here.") + SettingsModel.translationTrigger - function onClickFunction() { firePush(logPage) } - width: parent.width - sourceComponent: subMenu - } - } - } - } -} diff --git a/resources/qml/Governikus/FeedbackView/+mobile/LogTitleBarControls.qml b/resources/qml/Governikus/FeedbackView/+mobile/LogTitleBarControls.qml index b07b76694..b48c9e495 100644 --- a/resources/qml/Governikus/FeedbackView/+mobile/LogTitleBarControls.qml +++ b/resources/qml/Governikus/FeedbackView/+mobile/LogTitleBarControls.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/FeedbackView/+mobile/LogView.qml b/resources/qml/Governikus/FeedbackView/+mobile/LogView.qml index 1a40f5244..96a733a50 100644 --- a/resources/qml/Governikus/FeedbackView/+mobile/LogView.qml +++ b/resources/qml/Governikus/FeedbackView/+mobile/LogView.qml @@ -1,9 +1,10 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -90,16 +91,42 @@ SectionPage displayMarginEnd: Constants.pane_padding model: LogModel - - delegate: GText { + spacing: Constants.text_spacing + delegate: Item { + height: layout.height width: logView.width - Constants.pane_padding + Accessible.role: Accessible.StaticText + Accessible.name: display Accessible.onScrollDownAction: logView.scrollPageDown() Accessible.onScrollUpAction: logView.scrollPageUp() - bottomPadding: index % 2 ? Constants.groupbox_spacing : 0 - text: model.display - textStyle: index % 2 ? Style.text.hint : Style.text.hint_secondary + ColumnLayout { + id: layout + + width: parent.width + + spacing: 0 + + GText { + Layout.fillWidth: true + + Accessible.ignored: true + + text: origin + textStyle: Style.text.hint + font.bold: true + } + + GText { + Layout.fillWidth: true + + Accessible.ignored: true + + text: message + textStyle: Style.text.hint + } + } } Connections { @@ -114,11 +141,16 @@ SectionPage property bool deleteAll: true - //: LABEL ANDROID IOS - title: (deleteAll ? qsTr("Delete all") : qsTr("Delete")) + SettingsModel.translationTrigger - //: INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confirmation required. - text: (deleteAll ? qsTr("Please confirm that you want to delete your old logfiles.") - : qsTr("Please confirm that you want to delete the logfile.") + title: (deleteAll ? + //: LABEL ANDROID IOS + qsTr("Delete all") : + //: LABEL ANDROID IOS + qsTr("Delete") + ) + SettingsModel.translationTrigger + //: INFO ANDROID IOS All logfiles are about to be removed, user confirmation required. + text: (deleteAll ? qsTr("All old logfiles will be deleted.") + //: INFO ANDROID IOS The current logfile is about to be removed, user confirmation required. + : qsTr("The logfile will be deleted.") ) + SettingsModel.translationTrigger //: LABEL ANDROID IOS okButtonText: qsTr("Delete") + SettingsModel.translationTrigger diff --git a/resources/qml/Governikus/FeedbackView/qmldir b/resources/qml/Governikus/FeedbackView/qmldir index e2f874c79..35b13ba16 100644 --- a/resources/qml/Governikus/FeedbackView/qmldir +++ b/resources/qml/Governikus/FeedbackView/qmldir @@ -1,7 +1,8 @@ module FeedbackView internal LogTitleBarControls LogTitleBarControls.qml +internal LogViewDelegate LogViewDelegate.qml -Feedback 1.0 Feedback.qml +DetachedLogView 1.0 DetachedLogView.qml LogView 1.0 LogView.qml StoreFeedbackPopup 1.0 StoreFeedbackPopup.qml diff --git a/resources/qml/Governikus/Global/+desktop/+mac/BrandConstants.qml b/resources/qml/Governikus/Global/+desktop/+mac/BrandConstants.qml index c4387f497..d0b6e6810 100644 --- a/resources/qml/Governikus/Global/+desktop/+mac/BrandConstants.qml +++ b/resources/qml/Governikus/Global/+desktop/+mac/BrandConstants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+desktop/+win/BrandConstants.qml b/resources/qml/Governikus/Global/+desktop/+win/BrandConstants.qml index c4387f497..d0b6e6810 100644 --- a/resources/qml/Governikus/Global/+desktop/+win/BrandConstants.qml +++ b/resources/qml/Governikus/Global/+desktop/+win/BrandConstants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantBinaryDecisionView.qml b/resources/qml/Governikus/Global/+desktop/BinaryDecisionView.qml similarity index 77% rename from resources/qml/Governikus/TutorialView/+desktop/SetupAssistantBinaryDecisionView.qml rename to resources/qml/Governikus/Global/+desktop/BinaryDecisionView.qml index e6b2b3207..6345b4559 100644 --- a/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantBinaryDecisionView.qml +++ b/resources/qml/Governikus/Global/+desktop/BinaryDecisionView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -16,9 +16,9 @@ SectionPage { property alias questionText: mainTextElement.text property alias questionSubText: subTextElement.text property string mainIconSource: "qrc:///images/status_info.svg" - property string agreeText: "" - property string disagreeText: "" - property bool addRingAroundIcon: false + property string agreeText: qsTr("Yes") + SettingsModel.translationTrigger + property string disagreeText: qsTr("No, later") + SettingsModel.translationTrigger + property bool addRingAroundIcon: true signal agree() signal disagree() @@ -54,14 +54,13 @@ SectionPage { anchors.horizontalCenter: parent.horizontalCenter anchors.top: parent.verticalCenter - Accessible.role: Accessible.Heading Accessible.name: text activeFocusOnTab: true horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter - textStyle: Style.text.header + textStyle: Style.text.header_inverse FocusFrame {} } @@ -75,22 +74,18 @@ SectionPage { anchors.top: mainTextElement.bottom anchors.topMargin: Constants.text_spacing - Accessible.role: Accessible.Heading Accessible.name: text activeFocusOnTab: true horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter - textStyle: Style.text.normal - FocusFrame {} } - SetupAssistantButton { + NavigationButton { id: disagreeButton - width: ApplicationModel.scaleFactor * 120 anchors.margins: Constants.component_spacing anchors.bottom: parent.bottom anchors.horizontalCenter: parent.horizontalCenter @@ -98,16 +93,14 @@ SectionPage { activeFocusOnTab: true - //: LABEL DESKTOP_QML - subText: qsTr("No") + SettingsModel.translationTrigger - buttonImage: "qrc:///images/cancel.svg" + subText: disagreeText + buttonType: NavigationButton.Type.Cancel onClicked: baseItem.disagree() } - SetupAssistantButton { + NavigationButton { id: agreeButton - width: ApplicationModel.scaleFactor * 120 anchors.margins: Constants.component_spacing anchors.bottom: parent.bottom anchors.horizontalCenter: parent.horizontalCenter @@ -115,9 +108,8 @@ SectionPage { activeFocusOnTab: true - //: LABEL DESKTOP_QML - subText: qsTr("Yes") + SettingsModel.translationTrigger - buttonImage: "qrc:///images/check.svg" + subText: agreeText + buttonType: NavigationButton.Type.Check onClicked: baseItem.agree() } } diff --git a/resources/qml/Governikus/Global/+desktop/ConfirmationPopup.qml b/resources/qml/Governikus/Global/+desktop/ConfirmationPopup.qml index 8b4ea1194..39ae40706 100644 --- a/resources/qml/Governikus/Global/+desktop/ConfirmationPopup.qml +++ b/resources/qml/Governikus/Global/+desktop/ConfirmationPopup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -13,6 +13,8 @@ import Governikus.Style 1.0 BaseConfirmationPopup { id: root + headerTextStyle: Style.text.header_inverse + buttons: Row { width: parent.width diff --git a/resources/qml/Governikus/Global/+desktop/GButton.qml b/resources/qml/Governikus/Global/+desktop/GButton.qml deleted file mode 100644 index 062006af5..000000000 --- a/resources/qml/Governikus/Global/+desktop/GButton.qml +++ /dev/null @@ -1,80 +0,0 @@ -/* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.3 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.View 1.0 -import Governikus.Type.ApplicationModel 1.0 - - -Button { - id: control - - property var textStyle: enabled ? Style.text.button : Style.text.button_disabled - property color buttonColor: Style.color.accent - property alias cursorShape: mouseArea.cursorShape - - padding: Constants.pane_padding / 2 - - contentItem: RowLayout { - spacing: Constants.groupbox_spacing - - Image { - visible: source.toString().length > 0 - sourceSize.height: ApplicationModel.scaleFactor * 40 - - source: control.icon.source - } - - Item { - id: textContainer - - Layout.fillWidth: true - implicitHeight: originalSize.implicitHeight - implicitWidth: originalSize.implicitWidth - - GText { - id: originalSize - - visible: false - anchors.fill: parent - - text: control.text - textStyle: control.textStyle - } - - GText { - anchors.fill: parent - - text: control.text - textStyle: control.textStyle - font.pixelSize: textStyle.textSize - ApplicationModel.scaleFactor * (control.down ? 1 : 0) - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - - FocusFrame { - scope: control - } - } - } - } - - background: Rectangle { - color: enabled ? buttonColor : Style.color.accent_disabled - radius: Style.dimens.button_radius - } - - MouseArea { - id: mouseArea - - anchors.fill: parent - - onPressed: mouse.accepted = false - cursorShape: Qt.PointingHandCursor - } -} diff --git a/resources/qml/Governikus/Global/+desktop/GCheckBox.qml b/resources/qml/Governikus/Global/+desktop/GCheckBox.qml index 185055b56..cbd070051 100644 --- a/resources/qml/Governikus/Global/+desktop/GCheckBox.qml +++ b/resources/qml/Governikus/Global/+desktop/GCheckBox.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+desktop/GComboBox.qml b/resources/qml/Governikus/Global/+desktop/GComboBox.qml deleted file mode 100644 index ad6818fe9..000000000 --- a/resources/qml/Governikus/Global/+desktop/GComboBox.qml +++ /dev/null @@ -1,61 +0,0 @@ -/* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 - -import Governikus.View 1.0 -import Governikus.Style 1.0 -import Governikus.Type.ApplicationModel 1.0 - -ComboBox { - id: control - - property var textStyle: Style.text.normal_inverse - - spacing: Constants.groupbox_spacing - font.pixelSize: textStyle.fontSize - - indicator: Image { - visible: control.model.length > 1 || control.model.count > 1 - x: control.width - width - control.rightPadding - y: control.topPadding + (control.availableHeight - height) / 2 - - source: "qrc:///images/triangle.svg" - sourceSize.width: ApplicationModel.scaleFactor * 20 - sourceSize.height: ApplicationModel.scaleFactor * 20 - } - - contentItem: GText { - padding: control.spacing - rightPadding: control.indicator.width + control.spacing - text: control.displayText - textStyle: control.textStyle - verticalAlignment: Text.AlignVCenter - elide: Text.ElideRight - } - - delegate: ItemDelegate { - width: control.width - highlighted: control.highlightedIndex === index - - GText { - anchors.verticalCenter: parent.verticalCenter - leftPadding: ApplicationModel.scaleFactor * 5 - - text: modelData - textStyle: control.textStyle - font.bold: control.currentIndex === index - } - } - - FocusFrame { - scope: control - marginFactor: 1.5 - } - - background: Rectangle { - border.color: Constants.black - } -} diff --git a/resources/qml/Governikus/Global/+desktop/GTextField.qml b/resources/qml/Governikus/Global/+desktop/GTextField.qml deleted file mode 100644 index e9929f7ac..000000000 --- a/resources/qml/Governikus/Global/+desktop/GTextField.qml +++ /dev/null @@ -1,63 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 - -import Governikus.Style 1.0 -import Governikus.View 1.0 -import Governikus.Type.ApplicationModel 1.0 - - -Item { - id: baseItem - - property alias text: field.text - property var textStyle: Style.text.normal - property alias displayText: field.displayText - property alias echoMode: field.echoMode - property alias textAnchors: field.anchors - property alias validator: field.validator - property alias maximumLength: field.maximumLength - readonly property alias acceptableInput: field.acceptableInput - signal accepted - - property bool valid: true - - height: field.height + 2 * textBackground.radius - width: ApplicationModel.scaleFactor * 240 - - Rectangle { - id: textBackground - - anchors.fill: parent - - radius: ApplicationModel.scaleFactor * 6 - color: enabled ? Constants.white : Constants.grey - border.color: Constants.red - border.width: valid ? 0 : ApplicationModel.scaleFactor * 2 - } - - TextField { - id: field - - anchors.top: parent.top - anchors.left: parent.left - anchors.right: parent.right - anchors.margins: textBackground.radius - - activeFocusOnTab: true - padding: 0 - font.pixelSize: baseItem.textStyle.textSize - color: baseItem.textStyle.textColor - onAccepted: baseItem.accepted() - background: Item {} - } - - onActiveFocusChanged: if (focus) field.forceActiveFocus() - - FocusFrame { - scope: field - } -} diff --git a/resources/qml/Governikus/Global/+desktop/LabeledText.qml b/resources/qml/Governikus/Global/+desktop/LabeledText.qml index 61f487e91..d29644163 100644 --- a/resources/qml/Governikus/Global/+desktop/LabeledText.qml +++ b/resources/qml/Governikus/Global/+desktop/LabeledText.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -14,10 +14,12 @@ Item { signal linkActivated(string link) property alias label: label.text + property alias labelStyle: label.textStyle property alias text: body.text property alias textFormat: body.textFormat property alias textUppercase: body.font.capitalization - property alias underlineLabel: label.font.underline + property alias maximumBodyLineCount: body.maximumLineCount + property alias bodyElide: body.elide readonly property double focusFrameMargins: focusFrame.anchors.margins implicitHeight: column.implicitHeight @@ -28,8 +30,7 @@ Item { FocusFrame { id: focusFrame - dynamic: false - border.color: Constants.black + border.color: Style.color.focus_indicator } Column { @@ -54,8 +55,7 @@ Item { width: parent.width - textStyle: Style.text.normal_inverse - onLinkActivated: baseItem.linkActivated(link) + textStyle: Style.text.normal } } } diff --git a/resources/qml/Governikus/Global/+desktop/NavigationButton.qml b/resources/qml/Governikus/Global/+desktop/NavigationButton.qml index 0d7bdd4a4..e1fd9f99c 100644 --- a/resources/qml/Governikus/Global/+desktop/NavigationButton.qml +++ b/resources/qml/Governikus/Global/+desktop/NavigationButton.qml @@ -1,9 +1,10 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 import Governikus.Style 1.0 import Governikus.View 1.0 @@ -14,47 +15,75 @@ import Governikus.Type.ApplicationModel 1.0 Button { id: control - property int buttonType // Qt.ForwardButton || Qt.BackButton + enum Type { + Forward, + Back, + Check, + Cancel + } + + property int buttonType + property string subText - width: ApplicationModel.scaleFactor * 160 - height: ApplicationModel.scaleFactor * 160 + width: column.width + height: column.height Accessible.role: Accessible.Button - //: LABEL DESKTOP_QML - Accessible.name: { - if (buttonType === Qt.ForwardButton) { - return qsTr("Continue") + SettingsModel.translationTrigger - } - console.assert(buttonType === Qt.BackButton, "Use either Qt.ForwardButton or Qt.BackButton") - return qsTr("Back") + SettingsModel.translationTrigger - } + text: subText !== "" ? subText : ((buttonType === NavigationButton.Type.Check ? qsTr("Yes") : + buttonType === NavigationButton.Type.Cancel ? qsTr("No") : + buttonType === NavigationButton.Type.Forward ? qsTr("Continue") : + qsTr("Back")) + SettingsModel.translationTrigger) - background: Rectangle { - anchors.fill: parent - anchors.margins: control.down ? control.height / 32 : 0 + background: Item {} + contentItem: Item {} + + Column { + id: column - radius: height / 2 - border.width: height / 40; - border.color: enabled ? Constants.white : Constants.red - color: Style.color.transparent + spacing: Constants.component_spacing Rectangle { - anchors.fill: parent - anchors.margins: parent.height / 8; + id: icon + + width: ApplicationModel.scaleFactor * 160 + height: width + anchors.horizontalCenter: parent.horizontalCenter radius: height / 2 - color: Qt.lighter(Constants.blue, 1.1) + border.width: height / 40; + border.color: enabled ? Style.color.primary_text_inverse : Constants.red + color: Style.color.button - Image { + TintableIcon { anchors.centerIn: parent - source: "qrc:///images/desktop/continue_arrow.svg" - sourceSize.height: parent.height / 2; + source: buttonType == NavigationButton.Type.Check ? "qrc:///images/check.svg" : + buttonType == NavigationButton.Type.Cancel ? "qrc:///images/cancel.svg" : + "qrc:///images/desktop/continue_arrow.svg" + sourceSize.height: Style.dimens.large_icon_size transformOrigin: Item.Center - rotation: buttonType === Qt.BackButton ? 180 : 0 + rotation: buttonType == NavigationButton.Type.Back ? 180 : 0 + tintColor: Style.color.button_text } } + + GText { + id: buttonText + + visible: control.subText !== "" + anchors.horizontalCenter: parent.horizontalCenter + + text: control.subText + textStyle: Style.text.header_inverse + } } FocusFrame {} + + MouseArea { + anchors.fill: parent + + onPressed: mouse.accepted = false + cursorShape: Qt.PointingHandCursor + } } diff --git a/resources/qml/Governikus/Global/+desktop/Pane.qml b/resources/qml/Governikus/Global/+desktop/Pane.qml index 7708a9461..95d2f9151 100644 --- a/resources/qml/Governikus/Global/+desktop/Pane.qml +++ b/resources/qml/Governikus/Global/+desktop/Pane.qml @@ -1,9 +1,8 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.0 import Governikus.View 1.0 import Governikus.Style 1.0 @@ -13,36 +12,28 @@ import Governikus.Type.ApplicationModel 1.0 Item { id: root - Accessible.role: Accessible.Heading + Accessible.role: Accessible.Grouping Accessible.name: titleText.text property alias title: titleText.text property alias titleTextStyle: titleText.textStyle - property alias checkBox: titleText.checkBox + readonly property int availableContentHeight: { + var availableHeight = height - containerCol.topPadding - containerCol.bottomPadding + + if (title === "") { + return availableHeight + } + + return availableHeight - titleText.height - containerCol.spacing + } + property alias content: paneContent default property alias children: paneContent.children implicitHeight: containerCol.implicitHeight implicitWidth: containerCol.implicitWidth - Keys.onPressed: if (event.key === Qt.Key_Space) checkBox.toggle() - - Item { - id: shadowLayer - - anchors.fill: parent - - layer.enabled: true - layer.effect: DropShadow { - radius: 8 - samples: 8 - source: background - color: Qt.darker(Constants.grey, 1.2) - verticalOffset: 2 - } - } - Rectangle { id: background @@ -50,6 +41,9 @@ Item { color: Style.color.background_pane radius: Style.dimens.corner_radius + + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border } Column { @@ -63,15 +57,16 @@ Item { bottomPadding: Constants.pane_padding spacing: Constants.pane_spacing - PaneTitle { + GText { id: titleText - width: Math.max(implicitWidth + 2 * Constants.pane_padding, parent.width) + width: Math.min(parent.width, implicitWidth) + + textStyle: Style.text.header_accent FocusFrame { scope: root - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } diff --git a/resources/qml/Governikus/Global/+desktop/PaneTitle.qml b/resources/qml/Governikus/Global/+desktop/PaneTitle.qml deleted file mode 100644 index 34224d800..000000000 --- a/resources/qml/Governikus/Global/+desktop/PaneTitle.qml +++ /dev/null @@ -1,32 +0,0 @@ -/* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Style 1.0 - -GText { - property alias checkBox: optionState - - visible: text !== "" - - textStyle: Style.text.header_accent - - GCheckBox { - id: optionState - - visible: false - - anchors.verticalCenter: parent.verticalCenter - anchors.right: parent.right - - activeFocusOnTab: false - } - MouseArea { - anchors.fill: parent - - onReleased: if (mouse.button === Qt.LeftButton) optionState.toggle() - cursorShape: optionState.visible ? Qt.PointingHandCursor : Qt.ArrowCursor - } -} diff --git a/resources/qml/Governikus/Global/+desktop/PlatformConstants.qml b/resources/qml/Governikus/Global/+desktop/PlatformConstants.qml index 2c85e0437..cebdb64ce 100644 --- a/resources/qml/Governikus/Global/+desktop/PlatformConstants.qml +++ b/resources/qml/Governikus/Global/+desktop/PlatformConstants.qml @@ -1,14 +1,13 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 +import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.ApplicationModel 1.0 BrandConstants { - readonly property color blue: "#5481ab" - readonly property int component_spacing: ApplicationModel.scaleFactor * 30 readonly property int pane_padding: ApplicationModel.scaleFactor * 30 readonly property int pane_spacing: ApplicationModel.scaleFactor * 30 diff --git a/resources/qml/Governikus/Global/+desktop/RoundedRectangle.qml b/resources/qml/Governikus/Global/+desktop/RoundedRectangle.qml index aecf01e99..c78796ae5 100644 --- a/resources/qml/Governikus/Global/+desktop/RoundedRectangle.qml +++ b/resources/qml/Governikus/Global/+desktop/RoundedRectangle.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+desktop/ScrollGradients.qml b/resources/qml/Governikus/Global/+desktop/ScrollGradients.qml index 3cab396dd..b373a42c6 100644 --- a/resources/qml/Governikus/Global/+desktop/ScrollGradients.qml +++ b/resources/qml/Governikus/Global/+desktop/ScrollGradients.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -11,16 +11,20 @@ import Governikus.Style 1.0 Item { id: baseItem + property real leftMargin: Constants.pane_padding + property real rightMargin: Constants.pane_padding property color color + visible: !Style.currentTheme.highContrast + Rectangle { height: Constants.pane_padding anchors { top: parent.top left: parent.left right: parent.right - leftMargin: Constants.pane_padding - rightMargin: Constants.pane_padding + leftMargin: leftMargin + rightMargin: rightMargin } gradient: Gradient { @@ -35,8 +39,8 @@ Item { bottom: parent.bottom left: parent.left right: parent.right - leftMargin: Constants.pane_padding - rightMargin: Constants.pane_padding + leftMargin: leftMargin + rightMargin: rightMargin } gradient: Gradient { diff --git a/resources/qml/Governikus/Global/+desktop/ScrollablePane.qml b/resources/qml/Governikus/Global/+desktop/ScrollablePane.qml index aea86e8ad..a6d44b740 100644 --- a/resources/qml/Governikus/Global/+desktop/ScrollablePane.qml +++ b/resources/qml/Governikus/Global/+desktop/ScrollablePane.qml @@ -1,11 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 import QtQuick.Layouts 1.3 -import QtGraphicalEffects 1.0 import Governikus.Style 1.0 import Governikus.View 1.0 @@ -30,27 +29,14 @@ Item { } } - Accessible.role: Accessible.Heading + Accessible.role: Accessible.Grouping Accessible.name: titleText.text property alias title: titleText.text property alias content: paneContent default property alias children: paneContent.children - Item { - id: shadowLayer - - anchors.fill: parent - - layer.enabled: true - layer.effect: DropShadow { - radius: 8 - samples: 8 - source: background - color: Qt.darker(Constants.grey, 1.2) - verticalOffset: 2 - } - } + implicitHeight: flickable.contentHeight + 2 * Constants.pane_padding Rectangle { id: background @@ -59,14 +45,17 @@ Item { color: Style.color.background_pane radius: Style.dimens.corner_radius + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border } Item { anchors.fill: parent + anchors.margins: Style.dimens.high_contrast_item_border clip: true - Flickable { + GFlickable { id: flickable anchors.fill: parent @@ -74,11 +63,7 @@ Item { anchors.leftMargin: Constants.pane_padding anchors.bottomMargin: Constants.pane_padding - boundsBehavior: Flickable.StopAtBounds contentHeight: contentColumn.implicitHeight - ScrollBar.vertical: ScrollBar { - policy: size === 1.0 ? ScrollBar.AlwaysOff : ScrollBar.AlwaysOn - } Column { id: contentColumn @@ -99,8 +84,7 @@ Item { FocusFrame { scope: root - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } @@ -116,6 +100,7 @@ Item { ScrollGradients { anchors.fill: parent + anchors.margins: Style.dimens.high_contrast_item_border color: background.color } } diff --git a/resources/qml/Governikus/Global/+desktop/SearchBar.qml b/resources/qml/Governikus/Global/+desktop/SearchBar.qml index 0fa994a70..0ba9bfbe8 100644 --- a/resources/qml/Governikus/Global/+desktop/SearchBar.qml +++ b/resources/qml/Governikus/Global/+desktop/SearchBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -22,12 +22,14 @@ GTextField { width: 400 * ApplicationModel.scaleFactor - Accessible.name: qsTr("Search") + SettingsModel.translationTrigger + Accessible.name: placeholderText - textAnchors.leftMargin: glassIcon.width + Constants.groupbox_spacing - textAnchors.rightMargin: iconItem.width + Constants.groupbox_spacing + leftPadding: glassIcon.width + Constants.groupbox_spacing + rightPadding: iconItem.width + Constants.groupbox_spacing - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal + //: LABEL DESKTOP_QML + placeholderText: qsTr("Search") + SettingsModel.translationTrigger Image { id: glassIcon @@ -41,15 +43,6 @@ GTextField { source: "qrc:///images/search_icon.svg" } - GText { - visible: searchField.text === "" - anchors.centerIn: searchField - - //: LABEL DESKTOP_QML - text: qsTr("Search") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary_inverse - } - Image { id: iconItem @@ -70,11 +63,13 @@ GTextField { MouseArea { anchors.fill: parent + cursorShape: Qt.PointingHandCursor + onClicked: searchField.clear() } FocusFrame { - border.color: Constants.black + borderColor: Style.color.focus_indicator } } } diff --git a/resources/qml/Governikus/Global/+desktop/TabbedPane.qml b/resources/qml/Governikus/Global/+desktop/TabbedPane.qml index a542a71cf..97318eec1 100644 --- a/resources/qml/Governikus/Global/+desktop/TabbedPane.qml +++ b/resources/qml/Governikus/Global/+desktop/TabbedPane.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -26,10 +26,9 @@ Item { property alias sectionCount: sectionNameList.count readonly property var currentItemModel: sectionNameList.currentItem ? sectionNameList.currentItem.itemModel : null - readonly property int horizonalSeparatorHeight: Math.max(ApplicationModel.scaleFactor * 1, 1) - readonly property int verticalSeparatorWidth: Math.max(ApplicationModel.scaleFactor * 4, 1) + readonly property var currentContentItem: contentLoader.item readonly property real relativeListViewWidth: 0.3 - readonly property int availableHeight: height - 2 * contentPadding + readonly property int availableHeight: height - 2 * contentPadding - 2 * Style.dimens.high_contrast_item_border property var contentPadding: Constants.pane_padding function scrollYPositionIntoView(pYposition) { @@ -41,20 +40,27 @@ Item { if (flickable.contentY < 0) flickable.contentY = 0 else if (flickable.contentY + flickable.height > flickable.contentHeight) - pFlickable.contentY = flickable.contentHeight - flickable.height + flickable.contentY = flickable.contentHeight - flickable.height } } - Row { + Item { anchors.fill: parent ColumnLayout { height: parent.height - width: parent.width * relativeListViewWidth + width: parent.width * relativeListViewWidth + 2 * Style.dimens.high_contrast_item_border + + anchors { + left: parent.left + top: parent.top + bottom: parent.bottom + } spacing: Constants.component_spacing + z: 1 - ListView { + GListView { id: sectionNameList Layout.fillWidth: true @@ -68,6 +74,9 @@ Item { highlightFollowsCurrentItem: true highlight: null delegate: sectionNameDelegate + scrollBarTopPadding: Constants.text_spacing + scrollBarBottomPadding: Constants.text_spacing + scrollBarAutohide: true } Loader { @@ -83,49 +92,56 @@ Item { height: parent.height width: parent.width * (1.0 - relativeListViewWidth) + anchors.right: parent.right + radius: Style.dimens.corner_radius - color: Style.color.background_pane_active + color: Style.color.background_pane topLeftCorner: false bottomLeftCorner: sectionNameList.contentHeight < height - clip: true - Flickable { - id: flickable + borderWidth: Style.dimens.high_contrast_item_border + borderColor: Style.color.high_contrast_item_border - anchors { - fill: parent - bottomMargin: contentPadding - topMargin: contentPadding - } + Item { + anchors.fill: parent + anchors.margins: Style.dimens.high_contrast_item_border - ScrollBar.vertical: ScrollBar { - policy: size === 1.0 ? ScrollBar.AlwaysOff : ScrollBar.AlwaysOn - } - contentHeight: contentLoader.item.height - boundsBehavior: Flickable.StopAtBounds + clip: true - Loader { - id: contentLoader + GFlickable { + id: flickable anchors { - top: parent.top - left: parent.left - right: parent.right - leftMargin: contentPadding - rightMargin: contentPadding + fill: parent + bottomMargin: contentPadding + topMargin: contentPadding } - sourceComponent: { - if (contentDelegate !== null) { - return contentDelegate - } + contentHeight: contentLoader.item.height + + Loader { + id: contentLoader - if (contentObjectModel === undefined) { - return null + anchors { + top: parent.top + left: parent.left + right: parent.right + leftMargin: contentPadding + rightMargin: contentPadding } - if (sectionNameList.currentIndex < contentObjectModel.count){ - return contentObjectModel.get(sectionNameList.currentIndex) + sourceComponent: { + if (contentDelegate !== null) { + return contentDelegate + } + + if (contentObjectModel === undefined) { + return null + } + + if (sectionNameList.currentIndex < contentObjectModel.count){ + return contentObjectModel.get(sectionNameList.currentIndex) + } } } } @@ -133,6 +149,7 @@ Item { ScrollGradients { anchors.fill: parent + anchors.margins: Style.dimens.high_contrast_item_border color: parent.color } } @@ -151,7 +168,9 @@ Item { readonly property bool isPreviousToCurrentItem: index === ListView.view.currentIndex - 1 readonly property var itemModel: model - Accessible.role: Accessible.Grouping + activeFocusOnTab: false + Accessible.role: Accessible.PageTab + Accessible.name: delegateLoader.item.sectionName width: parent.width height: delegateLoader.height + 2 * Constants.pane_padding @@ -159,60 +178,56 @@ Item { RoundedRectangle { id: background - anchors.fill: parent + anchors { + fill: parent + topMargin: isCurrentItem && !isFirstItem ? Style.dimens.tabbed_pane_separator_size : 0 + bottomMargin: isCurrentItem && !isLastItem ? Style.dimens.tabbed_pane_separator_size : 0 + rightMargin: !isCurrentItem ? (Style.dimens.tabbed_pane_separator_size + 2 * Style.dimens.high_contrast_item_border) : 0 + } radius: Style.dimens.corner_radius - color: isCurrentItem ? Style.color.background_pane_active : Style.color.background_pane + color: isCurrentItem ? Style.color.background_pane : Style.color.background_pane_inactive topLeftCorner: isFirstItem topRightCorner: false bottomRightCorner: false bottomLeftCorner: isLastItem - } - - Rectangle { - id: horizontalSeparator - - visible: !isLastItem - - width: parent.width - height: isCurrentItem || isPreviousToCurrentItem ? verticalSeparatorWidth : horizonalSeparatorHeight - anchors.bottom: parent.bottom - - color: isCurrentItem || isPreviousToCurrentItem ? Style.color.background : Style.color.border - } + borderWidth: Style.dimens.high_contrast_item_border + borderColor: Style.color.high_contrast_item_border - Rectangle { - id: verticalSeparator - - height: parent.height - width: verticalSeparatorWidth - anchors.right: parent.right + Rectangle { + width: isCurrentItem ? Style.dimens.high_contrast_item_border : 0 + anchors { + right: parent.right + top: parent.top + bottom: parent.bottom + topMargin: isFirstItem ? Style.dimens.high_contrast_item_border : 0 + bottomMargin: isLastItem ? Style.dimens.high_contrast_item_border : 0 + } - color: !isCurrentItem ? Style.color.background : Style.color.background_pane_active + color: background.color + } } - Rectangle { - id: missingPiece + GSeparator { + id: horizontalSeparator - visible: !isLastItem + visible: !isLastItem && !isCurrentItem && !isPreviousToCurrentItem - height: isCurrentItem ? verticalSeparatorWidth : horizonalSeparatorHeight - width: verticalSeparatorWidth anchors { + left: parent.left right: parent.right bottom: parent.bottom + rightMargin: (!isCurrentItem ? Style.dimens.tabbed_pane_separator_size : 0) + 2 * Style.dimens.high_contrast_item_border + leftMargin: Style.dimens.high_contrast_item_border } - - color: Style.color.background } FocusFrame { visible: delegateItem.focusReason !== Qt.MouseFocusReason framee: delegateLoader - border.color: Constants.black - dynamic: false + borderColor: Style.color.focus_indicator } Loader { @@ -225,7 +240,7 @@ Item { left: parent.left right: parent.right leftMargin: Constants.pane_padding - rightMargin: Constants.pane_padding + rightMargin: Constants.pane_padding + 2 * Style.dimens.high_contrast_item_border } sourceComponent: sectionDelegate diff --git a/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateIconAndText.qml b/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateIconAndText.qml index c79f51a85..acadfc0fc 100644 --- a/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateIconAndText.qml +++ b/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateIconAndText.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -13,9 +13,6 @@ Row { property string sectionName property string iconPath - Accessible.role: Accessible.PageTab - Accessible.name: sectionName - spacing: Constants.groupbox_spacing Image { @@ -34,7 +31,7 @@ Row { anchors.verticalCenter: parent.verticalCenter text: sectionName - textStyle: Style.text.header_inverse + textStyle: Style.text.header maximumLineCount: 1 elide: Text.ElideRight } diff --git a/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateIconAndThreeLineText.qml b/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateIconAndThreeLineText.qml index aab428c90..e5ef3768c 100644 --- a/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateIconAndThreeLineText.qml +++ b/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateIconAndThreeLineText.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Style 1.0 import Governikus.Type.ApplicationModel 1.0 @@ -11,14 +11,11 @@ import Governikus.Type.ApplicationModel 1.0 RowLayout { id: root - property string mainText + property string sectionName property string headerText property string footerText property string iconPath - Accessible.role: Accessible.PageTab - Accessible.name: headerText + " " + mainText + " " + footerText - width: parent.width spacing: Constants.groupbox_spacing @@ -43,15 +40,15 @@ RowLayout { width: parent.width text: headerText - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal maximumLineCount: 1 } GText { width: parent.width - text: mainText - textStyle: Style.text.header_inverse + text: sectionName + textStyle: Style.text.header maximumLineCount: 1 elide: Text.ElideRight } @@ -60,7 +57,7 @@ RowLayout { width: parent.width text: footerText - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal maximumLineCount: 1 elide: Text.ElideRight } diff --git a/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateOneLineText.qml b/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateOneLineText.qml index 1a1ffefda..a936e619d 100644 --- a/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateOneLineText.qml +++ b/resources/qml/Governikus/Global/+desktop/TabbedPaneDelegateOneLineText.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -11,12 +11,9 @@ GText { property string sectionName - Accessible.role: Accessible.PageTab - Accessible.name: sectionName - width: parent.width - textStyle: Style.text.header_inverse + textStyle: Style.text.header text: sectionName maximumLineCount: 1 elide: Text.ElideRight diff --git a/resources/qml/Governikus/Global/+desktop/ToggleableOption.qml b/resources/qml/Governikus/Global/+desktop/ToggleableOption.qml index 6c720e948..10c247e97 100644 --- a/resources/qml/Governikus/Global/+desktop/ToggleableOption.qml +++ b/resources/qml/Governikus/Global/+desktop/ToggleableOption.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -19,15 +19,14 @@ Item { property alias text: optionText.text property alias checked: optionState.checked - property TextStyle textStyle: enabled ? Style.text.normal_inverse : Style.text.normal_secondary_inverse + property TextStyle textStyle: enabled ? Style.text.normal : Style.text.normal_secondary implicitHeight: layout.implicitHeight implicitWidth: layout.implicitWidth activeFocusOnTab: true - Accessible.name: root.text + " " + (checked ? qsTr("is enabled") : qsTr("is disabled")) + SettingsModel.translationTrigger - Accessible.description: root.text + Accessible.name: root.text Accessible.role: Accessible.CheckBox Keys.onSpacePressed: optionState.toggle() @@ -59,7 +58,6 @@ Item { FocusFrame { border.color: optionText.color - dynamic: false } MouseArea { diff --git a/resources/qml/Governikus/Global/+mobile/+android/+phone/DeviceConstants.qml b/resources/qml/Governikus/Global/+mobile/+android/+phone/DeviceConstants.qml index 7c0ed0a2a..eb40a88f4 100644 --- a/resources/qml/Governikus/Global/+mobile/+android/+phone/DeviceConstants.qml +++ b/resources/qml/Governikus/Global/+mobile/+android/+phone/DeviceConstants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/+android/+tablet/DeviceConstants.qml b/resources/qml/Governikus/Global/+mobile/+android/+tablet/DeviceConstants.qml index 4afbd0168..9ce40f1e0 100644 --- a/resources/qml/Governikus/Global/+mobile/+android/+tablet/DeviceConstants.qml +++ b/resources/qml/Governikus/Global/+mobile/+android/+tablet/DeviceConstants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/+android/BrandConstants.qml b/resources/qml/Governikus/Global/+mobile/+android/BrandConstants.qml index 6b8d6482e..c7abdec10 100644 --- a/resources/qml/Governikus/Global/+mobile/+android/BrandConstants.qml +++ b/resources/qml/Governikus/Global/+mobile/+android/BrandConstants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/+android/ConfirmationPopup.qml b/resources/qml/Governikus/Global/+mobile/+android/ConfirmationPopup.qml index d944c247d..b1d21f3e7 100644 --- a/resources/qml/Governikus/Global/+mobile/+android/ConfirmationPopup.qml +++ b/resources/qml/Governikus/Global/+mobile/+android/ConfirmationPopup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -12,6 +12,8 @@ import Governikus.Style 1.0 BaseConfirmationPopup { id: root + headerTextStyle: Style.text.header + buttons: Row { width: parent.width diff --git a/resources/qml/Governikus/Global/+mobile/+android/GButton.qml b/resources/qml/Governikus/Global/+mobile/+android/GButton.qml deleted file mode 100644 index 960934378..000000000 --- a/resources/qml/Governikus/Global/+mobile/+android/GButton.qml +++ /dev/null @@ -1,116 +0,0 @@ -/* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtGraphicalEffects 1.0 - -import Governikus.Style 1.0 - -import "Utils.js" as Utils - -import Governikus.Style 1.0 - -/* - * Custom implementation to be replaced with template specialization of Qt.labs.controls Button - * Android style guide for material design is adapted. - */ -Item { - id: baseItem - property alias text: textItem.text - property var textStyle: enabled ? Style.text.button : Style.text.button_disabled - property color buttonColor: Style.color.accent - property int maxWidth: 0 - property alias iconSource: icon.source - property bool animationsDisabled: false - - signal clicked - - Accessible.role: Accessible.Button - Accessible.name: text - - height: Style.dimens.button_height - width: Math.max(textItem.implicitWidth + (icon.visible ? (icon.width + icon.anchors.leftMargin) : 0) + 2 * 16, 88) - - state: "normal" - states: [ - State { name: "normal"; when: baseItem.animationsDisabled || !mouseArea.pressed - PropertyChanges { target: darkLayer; width: 0 } - PropertyChanges { target: shadow; verticalOffset: 2 } - }, - State { name: "pressed"; when: !baseItem.animationsDisabled && mouseArea.pressed - PropertyChanges { target: darkLayer; width: 2 * rect.width } - PropertyChanges { target: shadow; verticalOffset: 8 } - } - ] - transitions: [ - Transition { - from: "normal"; to: "pressed"; reversible: false - PropertyAnimation { target: darkLayer; property: "width"} - PropertyAnimation { target: shadow; property: "verticalOffset"} - } - ] - - Rectangle { - id: rect - anchors.fill: parent - color: enabled ? buttonColor : Style.color.accent_disabled - radius: Style.dimens.button_radius - - Item { - anchors.fill: parent - clip: true - Rectangle { - id: darkLayer - x: mouseArea.containsMouse ? mouseArea.mouseX - width * 0.5 : 0 - height: parent.height - color: Constants.black - opacity: 0.2 - radius: Style.dimens.button_radius - } - } - } - - DropShadow { - id: shadow - anchors.fill: rect - radius: 8.0 - fast: true - color: "#40000000" - source: rect - } - - Image { - id: icon - visible: source.toString().length > 0 - height: rect.height - 10 - width: height - anchors.left: rect.left - anchors.leftMargin: 5 - anchors.verticalCenter: rect.verticalCenter - } - - GText { - id: textItem - - anchors.left: rect.left - anchors.right: rect.right - anchors.verticalCenter: rect.verticalCenter - anchors.leftMargin: icon.visible ? icon.width + icon.anchors.leftMargin : 0 - - Accessible.ignored: true - - horizontalAlignment: Text.AlignHCenter - font.capitalization: Font.AllUppercase - textStyle: baseItem.textStyle - } - - MouseArea { - id: mouseArea - anchors.fill: parent - preventStealing: true - hoverEnabled: true - onClicked: parent.clicked() - } -} - diff --git a/resources/qml/Governikus/Global/+mobile/+android/GCheckBox.qml b/resources/qml/Governikus/Global/+mobile/+android/GCheckBox.qml index 209199037..5db1bfb38 100644 --- a/resources/qml/Governikus/Global/+mobile/+android/GCheckBox.qml +++ b/resources/qml/Governikus/Global/+mobile/+android/GCheckBox.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -8,9 +8,6 @@ import QtQuick.Controls 2.3 import Governikus.Global 1.0 import Governikus.Style 1.0 -import "Utils.js" as Utils - - CheckBox { id: control diff --git a/resources/qml/Governikus/Global/+mobile/+android/LabeledText.qml b/resources/qml/Governikus/Global/+mobile/+android/LabeledText.qml index cacdcaa68..6deb84499 100644 --- a/resources/qml/Governikus/Global/+mobile/+android/LabeledText.qml +++ b/resources/qml/Governikus/Global/+mobile/+android/LabeledText.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -23,7 +23,6 @@ Item { anchors.leftMargin: margin anchors.right: parent.right anchors.rightMargin: margin - textStyle: Style.text.normal onLinkActivated: parent.linkActivated(link) } diff --git a/resources/qml/Governikus/Global/+mobile/+android/Pane.qml b/resources/qml/Governikus/Global/+mobile/+android/Pane.qml index 6ec2b2774..9faaa0a24 100644 --- a/resources/qml/Governikus/Global/+mobile/+android/Pane.qml +++ b/resources/qml/Governikus/Global/+mobile/+android/Pane.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -16,7 +16,9 @@ Rectangle { anchors.right: parent.right height: childrenRect.height color: Style.color.background_pane - radius: 16 + radius: Style.dimens.corner_radius + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border Column { anchors.left: parent.left @@ -38,12 +40,12 @@ Rectangle { } } - layer.enabled: true + layer.enabled: GraphicsInfo.api !== GraphicsInfo.Software layer.effect: DropShadow { radius: 8 samples: 8 source: root - color: Constants.grey + color: Style.color.shadow verticalOffset: 2 } } diff --git a/resources/qml/Governikus/Global/+mobile/+android/SearchBar.qml b/resources/qml/Governikus/Global/+mobile/+android/SearchBar.qml index b097f539e..3bc788b74 100644 --- a/resources/qml/Governikus/Global/+mobile/+android/SearchBar.qml +++ b/resources/qml/Governikus/Global/+mobile/+android/SearchBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -7,7 +7,7 @@ import QtQuick.Controls 2.3 import Governikus.Global 1.0 import Governikus.Style 1.0 - +import Governikus.Type.SettingsModel 1.0 Row { id: root @@ -32,6 +32,10 @@ Row { enterKeyType: Qt.EnterKeySearch + Accessible.role: Accessible.EditableText + //: LABEL ANDROID + Accessible.name: qsTr("Type provider to search for") + SettingsModel.translationTrigger + onAccepted: { iconItem.forceActiveFocus(Qt.MouseFocusReason) } @@ -51,8 +55,17 @@ Row { fillMode: Image.PreserveAspectFit source: "qrc:///images/android/search_icon.svg" + Accessible.role: Accessible.Button + //: LABEL ANDROID + Accessible.name: qsTr("Search") + SettingsModel.translationTrigger + //: LABEL ANDROID + Accessible.description: qsTr("Search provider list") + SettingsModel.translationTrigger + MouseArea { anchors.fill: parent + + Accessible.ignored: true + onClicked: { // Storage of the new value is needed because the query // of searchField.visible still delivers the old value. diff --git a/resources/qml/Governikus/Global/+mobile/+ios/+phone/DeviceConstants.qml b/resources/qml/Governikus/Global/+mobile/+ios/+phone/DeviceConstants.qml index 7c0ed0a2a..eb40a88f4 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/+phone/DeviceConstants.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/+phone/DeviceConstants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/+ios/+phone/Pane.qml b/resources/qml/Governikus/Global/+mobile/+ios/+phone/Pane.qml index 09ebb7967..c4017ba96 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/+phone/Pane.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/+phone/Pane.qml @@ -1,13 +1,12 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 +import Governikus.Global 1.0 import Governikus.Style 1.0 -import "Utils.js" as Utils - Column { id: root property alias title: titleText.text @@ -30,6 +29,8 @@ Column { width: parent.width height: paneContent.height + 2 * Constants.pane_padding radius: Style.dimens.corner_radius + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border Column { id: paneContent diff --git a/resources/qml/Governikus/Global/+mobile/+ios/+tablet/DeviceConstants.qml b/resources/qml/Governikus/Global/+mobile/+ios/+tablet/DeviceConstants.qml index 4afbd0168..9ce40f1e0 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/+tablet/DeviceConstants.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/+tablet/DeviceConstants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/+ios/+tablet/Pane.qml b/resources/qml/Governikus/Global/+mobile/+ios/+tablet/Pane.qml index e848b1108..fce10f9a8 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/+tablet/Pane.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/+tablet/Pane.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -18,6 +18,8 @@ Rectangle { height: content.implicitHeight + 2 * Constants.pane_padding color: Style.color.background_pane radius: Style.dimens.corner_radius + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border Column { id: content diff --git a/resources/qml/Governikus/Global/+mobile/+ios/BrandConstants.qml b/resources/qml/Governikus/Global/+mobile/+ios/BrandConstants.qml index 0aef4b281..74f618ad4 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/BrandConstants.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/BrandConstants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/+ios/ConfirmationPopup.qml b/resources/qml/Governikus/Global/+mobile/+ios/ConfirmationPopup.qml index 216ff2887..7a0d2ec1e 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/ConfirmationPopup.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/ConfirmationPopup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -13,6 +13,7 @@ import Governikus.Style 1.0 BaseConfirmationPopup { id: root + headerTextStyle: Style.text.header horizontalTextAlignment: Text.AlignHCenter buttons: ColumnLayout { diff --git a/resources/qml/Governikus/Global/+mobile/+ios/GButton.qml b/resources/qml/Governikus/Global/+mobile/+ios/GButton.qml deleted file mode 100644 index f23108371..000000000 --- a/resources/qml/Governikus/Global/+mobile/+ios/GButton.qml +++ /dev/null @@ -1,80 +0,0 @@ -/* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtGraphicalEffects 1.0 - -import "Utils.js" as Utils - -import Governikus.Style 1.0 - -/* Custom implementation to be replaced with template specialization of Qt.labs.controls Button*/ -Rectangle { - id: rect - property alias text: textItem.text - property var textStyle: enabled ? Style.text.button : Style.text.button_disabled - property color buttonColor : Style.color.accent - property int maxWidth: 0 - property int preferedWidth: Math.max(textItem.implicitWidth + (icon.visible ? (icon.width + icon.anchors.leftMargin) : 0) + (2 * 16), 88) - property alias iconSource: icon.source - property bool animationsDisabled: false - - signal clicked - - Accessible.role: Accessible.Button - Accessible.name: text - Accessible.onPressAction: clicked() - - color: enabled ? buttonColor : Style.color.accent_disabled - height: Style.dimens.button_height - width: maxWidth > 0 ? Math.min(maxWidth, preferedWidth) : preferedWidth - clip: true - radius: Style.dimens.button_radius - - Image { - id: icon - visible: source.toString().length > 0 - height: rect.height - 10 - width: height - anchors.left: rect.left - anchors.leftMargin: 5 - anchors.verticalCenter: rect.verticalCenter - } - - GText { - id: textItem - - anchors.left: rect.left - anchors.right: rect.right - anchors.verticalCenter: rect.verticalCenter - horizontalAlignment: Text.AlignHCenter - - Accessible.ignored: true - - opacity: mouseArea.containsMouse ? 0.5 : 1 - anchors.leftMargin: icon.visible ? icon.width + icon.anchors.leftMargin : 0 - textStyle: rect.textStyle - } - - MouseArea{ - id: mouseArea - anchors.fill: parent - preventStealing: true - hoverEnabled: true - onClicked: parent.clicked() - } - - RadialGradient { - x: mouseArea.mouseX - width * 0.5 - height: parent.height - width: height * 2 - visible: !rect.animationsDisabled && mouseArea.pressed - opacity: 1 - gradient: Gradient { - GradientStop { position: 0.0; color: Qt.rgba(255,255,255,1) } - GradientStop { position: 0.2; color: Qt.rgba(255,255,255,0.5) } - GradientStop { position: 0.4; color: Qt.rgba(255,255,255,0) } - } - } -} diff --git a/resources/qml/Governikus/Global/+mobile/+ios/GCheckBox.qml b/resources/qml/Governikus/Global/+mobile/+ios/GCheckBox.qml index c6ea829bd..98e439d5b 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/GCheckBox.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/GCheckBox.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -7,9 +7,6 @@ import QtQuick.Controls 2.3 import Governikus.Global 1.0 -import "Utils.js" as Utils - - CheckBox { id: control diff --git a/resources/qml/Governikus/Global/+mobile/+ios/LabeledText.qml b/resources/qml/Governikus/Global/+mobile/+ios/LabeledText.qml index 10094c514..338f917a8 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/LabeledText.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/LabeledText.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/+ios/SearchBar.qml b/resources/qml/Governikus/Global/+mobile/+ios/SearchBar.qml index ca34423d4..73ed6f312 100644 --- a/resources/qml/Governikus/Global/+mobile/+ios/SearchBar.qml +++ b/resources/qml/Governikus/Global/+mobile/+ios/SearchBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -83,7 +83,7 @@ Item { Accessible.ignored: true //: LABEL IOS - text: qsTr("Search") + SettingsModel.translationTrigger + text: qsTr("Search providers") + SettingsModel.translationTrigger color: Constants.grey font.pixelSize: Style.dimens.normal_font_size } @@ -119,8 +119,9 @@ Item { anchors.right: parent.right anchors.rightMargin: visible ? 8 : 0 anchors.verticalCenter: parent.verticalCenter + width: visible ? implicitWidth : 0 - width: visible ? preferedWidth : 0 + buttonColor: Style.color.transparent //: LABEL IOS text: qsTr("Cancel") + SettingsModel.translationTrigger onClicked: { diff --git a/resources/qml/Governikus/Global/+mobile/GComboBox.qml b/resources/qml/Governikus/Global/+mobile/GComboBox.qml deleted file mode 100644 index 688560a96..000000000 --- a/resources/qml/Governikus/Global/+mobile/GComboBox.qml +++ /dev/null @@ -1,92 +0,0 @@ -/* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 - -import "Utils.js" as Utils - -import Governikus.Style 1.0 - -ComboBox { - id: control - - property var textStyle: Style.text.normal - - Accessible.role: Accessible.ComboBox - Accessible.name: displayText - - spacing: Constants.groupbox_spacing - font.pixelSize: textStyle.fontSize - - onPressedChanged: canvas.requestPaint() - Component.onCompleted: canvas.requestPaint() - - delegate: ItemDelegate { - width: control.width - contentItem: GText { - text: modelData - textStyle: control.textStyle - elide: Text.ElideRight - verticalAlignment: Text.AlignVCenter - } - highlighted: control.highlightedIndex === index - } - - indicator: Canvas { - id: canvas - x: control.width - width - control.rightPadding - y: control.topPadding + (control.availableHeight - height) / 2 - width: 12 - height: 8 - contextType: "2d" - - onPaint: { - context.reset(); - context.moveTo(0, 0); - context.lineTo(width, 0); - context.lineTo(width / 2, height); - context.closePath(); - context.fillStyle = Constants.black - context.fill(); - } - } - - contentItem: GText { - padding: control.spacing - rightPadding: control.indicator.width + control.spacing - - text: control.displayText - textStyle: control.textStyle - verticalAlignment: Text.AlignVCenter - elide: Text.ElideRight - } - - background: Rectangle { - border.color: Constants.black - border.width: control.visualFocus ? 2 : 1 - radius: 2 - } - - popup: Popup { - y: control.height - 1 - width: control.width - implicitHeight: contentItem.implicitHeight - padding: 1 - - contentItem: ListView { - clip: true - implicitHeight: contentHeight - model: control.popup.visible ? control.delegateModel : null - currentIndex: control.highlightedIndex - - ScrollIndicator.vertical: ScrollIndicator { } - } - - background: Rectangle { - border.color: Constants.black - radius: 2 - } - } -} diff --git a/resources/qml/Governikus/Global/+mobile/GListView.qml b/resources/qml/Governikus/Global/+mobile/GListView.qml deleted file mode 100644 index ca063fd11..000000000 --- a/resources/qml/Governikus/Global/+mobile/GListView.qml +++ /dev/null @@ -1,51 +0,0 @@ -/* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 -import QtGraphicalEffects 1.10 - -import Governikus.Style 1.0 - -ListView { - id: baseItem - - property bool scrollBarEnabled: true - property real scrollBarTopPadding: 0 - property real scrollBarBottomPadding: 0 - - function scrollPageDown() { - if (contentHeight > height) { - Utils.scrollPageDown(baseItem) - } - } - - function scrollPageUp() { - if (contentHeight > height) { - Utils.scrollPageUp(baseItem) - } - } - - function highlightScrollbar() { - if (ScrollBar.vertical) ScrollBar.vertical.highlight() - } - - ScrollBar.vertical: scrollBarEnabled ? scrollBar.createObject() : null - - maximumFlickVelocity: Constants.scrolling_speed - flickableDirection: Flickable.VerticalFlick - - boundsMovement: Flickable.FollowBoundsBehavior - boundsBehavior: contentHeight <= height ? Flickable.StopAtBounds : Flickable.DragAndOvershootBounds - - onVisibleChanged: if (visible) highlightScrollbar() - - Component { - id: scrollBar - GScrollBar { - topPadding: baseItem.scrollBarTopPadding + Style.dimens.scrollbar_padding - bottomPadding: baseItem.scrollBarBottomPadding + Style.dimens.scrollbar_padding - } - } -} diff --git a/resources/qml/Governikus/Global/+mobile/GRadioButton.qml b/resources/qml/Governikus/Global/+mobile/GRadioButton.qml deleted file mode 100644 index 0d2055778..000000000 --- a/resources/qml/Governikus/Global/+mobile/GRadioButton.qml +++ /dev/null @@ -1,48 +0,0 @@ -/* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 - -import "Utils.js" as Utils - -import Governikus.Style 1.0 - -RadioButton { - id: control - - property var textStyle: Style.text.normal - - Accessible.name: text - - spacing: Constants.groupbox_spacing - - indicator: Rectangle { - implicitWidth: 26 - implicitHeight: implicitWidth - x: control.leftPadding - y: parent.height / 2 - height / 2 - radius: height / 2 - border.color: Qt.darker(Constants.blue, control.down ? 1.5 : 1) - - Rectangle { - width: 14 - height: width - x: (parent.width - width) / 2 - y: x - radius: width / 2 - color: Qt.darker(Constants.blue, control.down ? 1.5 : 1) - visible: control.checked - } - } - - contentItem: GText { - Accessible.ignored: true - - text: control.text - textStyle: control.textStyle - verticalAlignment: Text.AlignVCenter - leftPadding: control.indicator.width + control.spacing - } -} diff --git a/resources/qml/Governikus/Global/+mobile/GSwitch.qml b/resources/qml/Governikus/Global/+mobile/GSwitch.qml index 425301044..a2247efed 100644 --- a/resources/qml/Governikus/Global/+mobile/GSwitch.qml +++ b/resources/qml/Governikus/Global/+mobile/GSwitch.qml @@ -1,102 +1,51 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 - -import "Utils.js" as Utils +import QtQuick.Controls 2.10 import Governikus.Style 1.0 import Governikus.Type.SettingsModel 1.0 -MouseArea { - id: baseItem +Switch { + id: control - property bool initialState: false property color color: Style.color.accent - readonly property alias isOn: toggleswitch.isOn - signal switched() - - width: 60 - height: 48 - - Accessible.role: Accessible.CheckBox - Accessible.name: qsTr("Switch") + SettingsModel.translationTrigger - Accessible.checkable: true - Accessible.checked: isOn - Accessible.onPressAction: if (Qt.platform.os === "ios") clicked(null) - - onClicked: toggleswitch.toggle() - Component.onCompleted: toggleswitch.isOn = baseItem.initialState - Item { - id: toggleswitch - anchors.fill: parent - anchors.topMargin: 12 - anchors.bottomMargin: 12 + Accessible.onPressAction: if (Qt.platform.os === "ios") toggle() - onIsOnChanged: updateState() - property bool isOn: false - readonly property int dragMax: width - height + implicitWidth: indicator.implicitWidth + implicitHeight: indicator.implicitHeight + padding: 0 - function updateState() { - state = (isOn ? "on" : "off") - } - - function toggle() { - isOn = !isOn - switched() - } + // Empty item since we don't want the text + contentItem: Item {} - function captureSwitch() { - state = "moving" - } - - function releaseSwitch() { - if (isOn !== (button.x > dragMax / 2)) toggle() - updateState() - } + indicator: Item { + implicitWidth: 48 + implicitHeight: 24 Rectangle { - id: background - anchors.fill: parent - anchors.margins: parent.height / 4 + width: parent.width + height: parent.height / 2 + y: parent.height / 2 - height / 2 radius: height / 2 - color: isOn ? Qt.lighter(baseItem.color, 1.4) : Qt.darker(Style.color.accent_disabled, 1.1) + + color: control.checked ? Qt.lighter(control.color, 1.4) : Qt.darker(Style.color.accent_disabled, 1.1) } Rectangle { - id: button + width: parent.height height: parent.height - width: height - radius: width - color: isOn ? baseItem.color : Style.color.accent_disabled + x: control.checked ? parent.width - width : 0 + radius: height / 2 - MouseArea { - anchors.fill: parent - drag.target: button - drag.axis: Drag.XAxis - drag.minimumX: 0 - drag.maximumX: toggleswitch.dragMax - onClicked: toggleswitch.toggle() - onPressed: toggleswitch.captureSwitch() - onReleased: toggleswitch.releaseSwitch() - } - } + color: control.checked ? control.color : Style.color.accent_disabled - states: [ - State { - name: "on" - PropertyChanges { target: button; x: toggleswitch.dragMax } - }, - State { - name: "off" - PropertyChanges { target: button; x: 0 } + Behavior on x { + NumberAnimation {easing.type: Easing.InOutQuad; duration: 200} } - ] - - transitions: Transition { - NumberAnimation { properties: "x"; easing.type: Easing.InOutQuad; duration: 200 } } } } diff --git a/resources/qml/Governikus/Global/+mobile/GTextField.qml b/resources/qml/Governikus/Global/+mobile/GTextField.qml deleted file mode 100644 index 214d06afd..000000000 --- a/resources/qml/Governikus/Global/+mobile/GTextField.qml +++ /dev/null @@ -1,49 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 - -import Governikus.Style 1.0 - -import "Utils.js" as Utils - -Item { - property alias text: field.text - property alias displayText: field.displayText - property alias echoMode: field.echoMode - property int enterKeyType: Qt.EnterKeyDefault - signal accepted - - property bool valid: true - - height: 24 - width: 240 - - Accessible.role: Accessible.EditableText - Accessible.editable: true - Accessible.name: echoMode === TextInput.Normal ? displayText : "" - - Rectangle { - radius: 6 - anchors.fill: parent - border.color: Constants.red - color: enabled ? Constants.white : Constants.grey - border.width: valid ? 0 : 2 - } - - TextField { - id: field - anchors.fill: parent - anchors.leftMargin: 6 - anchors.rightMargin: 6 - padding: 0 - font.pixelSize: Style.dimens.normal_font_size - onAccepted: parent.accepted() - background: Item {} - EnterKey.type: enterKeyType - } - - onActiveFocusChanged: if (focus) field.forceActiveFocus() -} diff --git a/resources/qml/Governikus/Global/+mobile/LabeledSwitch.qml b/resources/qml/Governikus/Global/+mobile/LabeledSwitch.qml new file mode 100644 index 000000000..19fe94025 --- /dev/null +++ b/resources/qml/Governikus/Global/+mobile/LabeledSwitch.qml @@ -0,0 +1,60 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.0 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 + +Item { + property alias title: titleText.text + property alias description: descriptionText.text + property alias checked: entrySwitch.checked + + height: Math.max(textContainer.height, entrySwitch.height) + + Item { + id: textContainer + + height: titleText.height + descriptionText.height + anchors.left: parent.left + anchors.right: entrySwitch.left + anchors.rightMargin: Constants.component_spacing + anchors.verticalCenter: parent.verticalCenter + + GText { + id: titleText + + width: parent.width + + textStyle: Style.text.normal_accent + } + + GText { + id: descriptionText + + width: parent.width + anchors.top: titleText.bottom + anchors.topMargin: 2 + + textStyle: Style.text.normal_secondary + } + } + + MouseArea { + anchors.fill: parent + + onClicked: entrySwitch.toggle() + } + + GSwitch { + id: entrySwitch + + anchors.right: parent.right + anchors.verticalCenter: parent.verticalCenter + + text: titleText.text + } +} diff --git a/resources/qml/Governikus/Global/+mobile/ListItem.qml b/resources/qml/Governikus/Global/+mobile/ListItem.qml index 6b6609f4e..c8d1df120 100644 --- a/resources/qml/Governikus/Global/+mobile/ListItem.qml +++ b/resources/qml/Governikus/Global/+mobile/ListItem.qml @@ -1,10 +1,9 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Layouts 1.3 -import QtGraphicalEffects 1.10 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -14,6 +13,7 @@ Rectangle { id: baseItem property alias icon: imageItem.source + property alias tintIcon: imageItem.tintEnabled property alias headerText: headerItem.text property alias text: textItem.text property alias footerText: footerItem.text @@ -21,7 +21,8 @@ Rectangle { property real contentMarginLeft: Constants.groupbox_spacing property real contentMarginRight: Constants.groupbox_spacing - property bool showRightArrow: Constants.is_layout_ios + property bool showLinkIcon: Constants.is_layout_ios + property string linkIconSource: "qrc:///images/arrowRight.svg" property bool showSeparator: true property bool pressed: mouseArea.pressed property alias mouseAreaEnabled: mouseArea.enabled @@ -35,7 +36,7 @@ Rectangle { Accessible.name: headerText + ". " + text + ". " + footerText Accessible.onPressAction: if (Qt.platform.os === "ios") mouseArea.clicked(null) - color: pressed ? Constants.lightgrey : Style.color.background_pane + color: pressed ? Style.color.background_pane_active : Style.color.background_pane GSeparator { visible: showSeparator @@ -55,14 +56,14 @@ Rectangle { spacing: Constants.groupbox_spacing - Image { + TintableIcon { id: imageItem visible: baseItem.icon !== "" sourceSize.height: parent.height - 2 * Constants.groupbox_spacing - asynchronous: true - fillMode: Image.PreserveAspectFit + tintEnabled: false + tintColor: Style.color.secondary_text } ColumnLayout { @@ -94,7 +95,6 @@ Rectangle { Accessible.ignored: true elide: Text.ElideRight - textStyle: Style.text.normal maximumLineCount: 2 } @@ -108,24 +108,16 @@ Rectangle { elide: Text.ElideRight textStyle: Style.text.hint_secondary - maximumLineCount: 1 + maximumLineCount: headerText === "" ? 2 : 1 } } - Image { - id: arrowRight - - visible: showRightArrow + TintableIcon { + visible: showLinkIcon sourceSize.height: Style.dimens.small_icon_size - fillMode: Image.PreserveAspectFit - source: "qrc:///images/arrowRight.svg" - - ColorOverlay { - anchors.fill: arrowRight - source: arrowRight - color: Style.color.secondary_text - } + source: linkIconSource + tintColor: Style.color.secondary_text } } diff --git a/resources/qml/Governikus/Global/+mobile/LocationButton.qml b/resources/qml/Governikus/Global/+mobile/LocationButton.qml deleted file mode 100644 index 917037571..000000000 --- a/resources/qml/Governikus/Global/+mobile/LocationButton.qml +++ /dev/null @@ -1,64 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Style 1.0 -import Governikus.Type.SettingsModel 1.0 - -import "Utils.js" as Utils - - -MouseArea { - property string language - property string name - property string image - - function setLanguage() { - SettingsModel.language = language - if (typeof(navigationController) !== "undefined") { - navigationController.close() - } - } - - height: 48 - width: height - - Accessible.role: Accessible.Button - Accessible.onPressAction: if (Qt.platform.os === "ios") clicked(null) - onClicked: setLanguage() - - Rectangle { - opacity: 0.1 - border.color: "black" - border.width: SettingsModel.language === language ? 0 : 1 - color: SettingsModel.language === language ? Constants.black : Style.color.accent - anchors.fill: parent - radius: Style.dimens.button_radius - } - - GText { - id: nameText - - anchors.topMargin: 4 - anchors.top: parent.top - anchors.horizontalCenter: parent.horizontalCenter - - Accessible.ignored: true - - text: name - textStyle: Style.text.hint_secondary - } - - Image { - source: image - fillMode: Image.PreserveAspectFit - - anchors.margins: 4 - anchors.left: parent.left - anchors.bottom: parent.bottom - anchors.right: parent.right - anchors.top: nameText.bottom - } -} diff --git a/resources/qml/Governikus/Global/+mobile/PaneTitle.qml b/resources/qml/Governikus/Global/+mobile/PaneTitle.qml index 35e3278d4..fec706b3d 100644 --- a/resources/qml/Governikus/Global/+mobile/PaneTitle.qml +++ b/resources/qml/Governikus/Global/+mobile/PaneTitle.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/PlatformConstants.qml b/resources/qml/Governikus/Global/+mobile/PlatformConstants.qml index 2ef23f86b..a708d4108 100644 --- a/resources/qml/Governikus/Global/+mobile/PlatformConstants.qml +++ b/resources/qml/Governikus/Global/+mobile/PlatformConstants.qml @@ -1,16 +1,15 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 BrandConstants { - readonly property color blue: "#659bcd" - readonly property int component_spacing: 20 readonly property int pane_padding: 20 readonly property int pane_spacing: 20 readonly property int groupbox_spacing: 10 + readonly property int text_spacing: 10 readonly property bool is_desktop: false } diff --git a/resources/qml/Governikus/Global/+mobile/SwipeActionDelegate.qml b/resources/qml/Governikus/Global/+mobile/SwipeActionDelegate.qml index 927e70d1b..d2b0600c7 100644 --- a/resources/qml/Governikus/Global/+mobile/SwipeActionDelegate.qml +++ b/resources/qml/Governikus/Global/+mobile/SwipeActionDelegate.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/+mobile/TitledSeparator.qml b/resources/qml/Governikus/Global/+mobile/TitledSeparator.qml new file mode 100644 index 000000000..3bdecee03 --- /dev/null +++ b/resources/qml/Governikus/Global/+mobile/TitledSeparator.qml @@ -0,0 +1,32 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.0 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 + +RowLayout { + id: baseItem + + property alias title: titleText.text + property int topPadding: Constants.component_spacing + + spacing: Constants.component_spacing + + GText { + id: titleText + + Layout.topMargin: baseItem.topPadding + Layout.preferredWidth: titleText.implicitWidth + + textStyle: Style.text.title + } + + GSeparator { + Layout.fillWidth: true + Layout.topMargin: baseItem.topPadding + } +} diff --git a/resources/qml/Governikus/Global/BaseConfirmationPopup.qml b/resources/qml/Governikus/Global/BaseConfirmationPopup.qml index 9d80daa0c..b39ccc84c 100644 --- a/resources/qml/Governikus/Global/BaseConfirmationPopup.qml +++ b/resources/qml/Governikus/Global/BaseConfirmationPopup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -26,6 +26,7 @@ Popup { default property alias children: customContent.children property string title property string text + property TextStyle headerTextStyle //: LABEL ALL_PLATFORMS property string okButtonText: qsTr("Ok") + SettingsModel.translationTrigger //: LABEL ALL_PLATFORMS @@ -57,6 +58,7 @@ Popup { modal: true closePolicy: Popup.CloseOnPressOutside | Popup.CloseOnEscape + focus: true background: Rectangle { color: Style.color.background_popup @@ -78,13 +80,11 @@ Popup { activeFocusOnTab: true text: root.title - textStyle: Style.text.header + textStyle: root.headerTextStyle font.bold: true horizontalAlignment: root.horizontalTextAlignment - FocusFrame { - dynamic: false - } + FocusFrame {} } GText { @@ -96,12 +96,9 @@ Popup { activeFocusOnTab: true text: root.text - textStyle: Style.text.normal horizontalAlignment: root.horizontalTextAlignment - FocusFrame { - dynamic: false - } + FocusFrame {} } Column { diff --git a/resources/qml/Governikus/Global/Category.js b/resources/qml/Governikus/Global/Category.js deleted file mode 100644 index b40ee37e0..000000000 --- a/resources/qml/Governikus/Global/Category.js +++ /dev/null @@ -1,86 +0,0 @@ -function getTableValue(table, key, defaultValue) { - return key in table ? table[key] : defaultValue -} - - -function displayString(cat) { - var CATEGORY_TO_DISPLAY_STRING = { - "": qsTr("Provider"), - "all": qsTr("All"), - "citizen": qsTr("Citizen services"), - "insurance": qsTr("Insurances"), - "finance": qsTr("Financials"), - "other": qsTr("Other services") - } - return getTableValue(CATEGORY_TO_DISPLAY_STRING, cat, "") -} - - -var CATEGORY_COLOR_NONE = "#659bcd" -var CATEGORY_COLOR_ALL = "#659bcd" -var CATEGORY_COLOR_CITIZEN = "#aa4079" -var CATEGORY_COLOR_INSURANCE = "#52539f" -var CATEGORY_COLOR_FINANCE = "#ecc758" -var CATEGORY_COLOR_OTHER = "#00868e" - -var CATEGORY_TO_COLOR = { - "": CATEGORY_COLOR_ALL, - "all": CATEGORY_COLOR_ALL, - "citizen": CATEGORY_COLOR_CITIZEN, - "insurance": CATEGORY_COLOR_INSURANCE, - "finance": CATEGORY_COLOR_FINANCE, - "other": CATEGORY_COLOR_OTHER -} - -function displayColor(cat) { - return getTableValue(CATEGORY_TO_COLOR, cat, CATEGORY_COLOR_NONE) -} - - -var CATEGORY_TO_IMAGE_NAME = { - "citizen": "citizen", - "insurance": "insurance", - "finance": "finance", - "other": "other", - "all": "general", - "": "general" -} - -function imageName(cat) { - return getTableValue(CATEGORY_TO_IMAGE_NAME, cat, "general") -} - - -function getPlatform() { - return plugin.platformStyle.indexOf("android") !== -1 ? "+android/" : "" -} - - -function gradientImageSource(cat) { - if (cat !== "citizen" && cat !== "insurance" && cat !== "finance") { - return "qrc:///images/provider/gradient-other.png" - } - else { - return "qrc:///images/provider/gradient-" + cat + ".png" - } -} - - -function backgroundImageSource(cat) { - return "qrc:///images/provider/categoryIcons/" + getPlatform() + imageName(cat) + "_bg.svg" -} - - -function buttonImageSource(cat) { - return "qrc:///images/provider/categoryIcons/" + getPlatform() + imageName(cat) + "_button.svg" -} - - -function imageSource(cat) { - return "qrc:///images/provider/categoryIcons/" + getPlatform() + imageName(cat) + ".svg" -} - - -function sectionImageSource(cat) { - return "qrc:///images/provider/categoryIcons/" + getPlatform() + imageName(cat) + "_section.svg" -} diff --git a/resources/qml/Governikus/Global/Category.qml b/resources/qml/Governikus/Global/Category.qml new file mode 100644 index 000000000..08ba787c1 --- /dev/null +++ b/resources/qml/Governikus/Global/Category.qml @@ -0,0 +1,81 @@ +/* + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany + */ + +pragma Singleton + +import QtQuick 2.10 + +import Governikus.Type.Random 1.0 + +QtObject { + + readonly property color categoryColorNone: "#4d7aa4" + readonly property color categoryColorAll: "#4d7aa4" + readonly property color categoryColorCitizen: "#851e6b" + readonly property color categoryColorInsurance: "#53428c" + readonly property color categoryColorFinance: "#693800" + readonly property color categoryColorOther: "#00828a" + + readonly property var categoryToColor: { + "": categoryColorAll, + "all": categoryColorAll, + "citizen": categoryColorCitizen, + "insurance": categoryColorInsurance, + "finance": categoryColorFinance, + "other": categoryColorOther + } + + readonly property var categoryToImageName: { + "citizen": "citizen", + "insurance": "insurance", + "finance": "finance", + "other": "other", + "all": "general", + "": "default" + } + + function getTableValue(table, key, defaultValue) { + return key in table ? table[key] : defaultValue + } + + function displayString(cat) { + let categoryToDisplayString = { + "": qsTr("Provider"), + "all": qsTr("All"), + "citizen": qsTr("Citizen services"), + "insurance": qsTr("Insurances"), + "finance": qsTr("Financials"), + "other": qsTr("Other services") + } + return getTableValue(categoryToDisplayString, cat, "") + } + + function displayColor(cat) { + return getTableValue(categoryToColor, cat, categoryColorNone) + } + + function imageName(cat) { + return getTableValue(categoryToImageName, cat, "default") + } + + + function getPlatform() { + return plugin.platformStyle.indexOf("android") !== -1 ? "+android/" : "" + } + + + function backgroundImageSource(cat) { + return "qrc:///images/provider/categoryIcons/" + getPlatform() + imageName(cat) + "_bg.svg" + } + + + function buttonImageSource(cat) { + return "qrc:///images/provider/categoryIcons/" + getPlatform() + imageName(cat) + "_button.svg" + } + + + function imageSource(cat) { + return "qrc:///images/provider/categoryIcons/" + getPlatform() + imageName(cat) + ".svg" + } +} diff --git a/resources/qml/Governikus/Global/Constants.qml b/resources/qml/Governikus/Global/Constants.qml index a1f7982fe..55387d577 100644 --- a/resources/qml/Governikus/Global/Constants.qml +++ b/resources/qml/Governikus/Global/Constants.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ pragma Singleton @@ -7,7 +7,9 @@ pragma Singleton import QtQuick 2.10 PlatformConstants { + readonly property color blue: "#4d7aa4" readonly property color green: "#a3cb7f" + readonly property color darkgreen: "#017f01" readonly property color red: "#cc0000" readonly property color grey: "#8e8e93" readonly property color lightgrey: "#d5d5dc" @@ -15,6 +17,11 @@ PlatformConstants { readonly property color black: "#000000" readonly property double scrolling_speed: 7500.0 + readonly property var flickDeceleration: Constants.is_desktop ? 7500.0 : 1500.0 readonly property int animation_duration: 250 + + readonly property real highlightDarkerFactor: 1.3 + + readonly property int maximumDeviceNameLength: 33 } diff --git a/resources/qml/Governikus/Global/GButton.qml b/resources/qml/Governikus/Global/GButton.qml new file mode 100644 index 000000000..8fb065d8a --- /dev/null +++ b/resources/qml/Governikus/Global/GButton.qml @@ -0,0 +1,113 @@ +/* + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 +import QtGraphicalEffects 1.0 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.View 1.0 +import Governikus.Type.ApplicationModel 1.0 + + +Button { + id: root + + property TextStyle textStyle: enabled && enableButton ? Style.text.button : Style.text.button_disabled + property color buttonColor: Style.color.button + property int cursorShape: Qt.PointingHandCursor + property bool animationsDisabled: false + property color textHighlightColor: textStyle.textColor + + /// Similar to "enabled", but tooltips will continue to work + property bool enableButton: true + + property string enabledTooltipText + property string disabledTooltipText + property bool tintIcon: false + + activeFocusOnTab: enableButton + onActiveFocusOnTabChanged: if (!activeFocusOnTab) focus = false + Accessible.name: text + Accessible.onPressAction: if (Qt.platform.os === "ios") clicked(null) + + padding: Constants.text_spacing + + font.pixelSize: textStyle.textSize + + ToolTip.visible: hovered && ToolTip.text !== "" + ToolTip.text: enableButton ? enabledTooltipText : disabledTooltipText + + contentItem: RowLayout { + z: 1 + + spacing: root.icon.source != "" ? Constants.text_spacing : 0 + + TintableIcon { + readonly property color iconColor: root.textStyle.textColor + readonly property color pressColor: Qt.darker(iconColor, Constants.highlightDarkerFactor) + + Layout.preferredHeight: sourceSize.height + + source: root.icon.source + sourceSize.height: root.textStyle.textSize + root.horizontalPadding + + tintEnabled: tintIcon + tintColor: !animationsDisabled && root.pressed ? pressColor : iconColor + } + + GText { + Accessible.ignored: true + + Layout.fillWidth: true + + font: root.font + textStyle: root.textStyle + color: !animationsDisabled && root.pressed ? root.textHighlightColor : root.textStyle.textColor + text: root.text + horizontalAlignment: root.icon.source == "" ? Text.AlignHCenter : Text.AlignLeft + + FocusFrame { + scope: root + } + } + } + + background: Rectangle { + readonly property color pressColor: Qt.darker(buttonColor, Constants.highlightDarkerFactor) + + radius: Style.dimens.button_radius + color: { + if (!enabled || !enableButton) { + return Style.color.button_disabled + } + + return !animationsDisabled && pressed ? pressColor : buttonColor + } + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border + } + + MouseArea { + z: 2 + anchors.fill: parent + + onPressed: mouse.accepted = !enableButton + cursorShape: enableButton ? root.cursorShape : Qt.ArrowCursor + } + + DropShadow { + visible: !Constants.is_desktop && Constants.is_layout_android && GraphicsInfo.api !== GraphicsInfo.Software + anchors.fill: source + + source: root.background + radius: 8 + samples: 8 + fast: true + color: Style.color.shadow + verticalOffset: 2 + } +} diff --git a/resources/qml/Governikus/Global/GComboBox.qml b/resources/qml/Governikus/Global/GComboBox.qml new file mode 100644 index 000000000..98d29362b --- /dev/null +++ b/resources/qml/Governikus/Global/GComboBox.qml @@ -0,0 +1,81 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 + +import Governikus.View 1.0 +import Governikus.Style 1.0 +import Governikus.Type.ApplicationModel 1.0 + +ComboBox { + id: control + + property TextStyle textStyle: Style.text.normal + + Accessible.role: Accessible.ComboBox + Accessible.name: displayText + + spacing: Constants.groupbox_spacing + font.pixelSize: textStyle.fontSize + + indicator: TintableIcon { + visible: control.model.length > 1 || control.model.count > 1 + + width: height + height: Math.round(control.height / 4) + x: Math.round(control.width - width - control.rightPadding) + y: Math.round(control.topPadding + (control.availableHeight - height) / 2) + + source: "qrc:///images/triangle.svg" + tintColor: control.textStyle.textColor + } + + contentItem: GText { + padding: control.spacing + rightPadding: control.indicator.width + control.spacing + text: control.displayText + textStyle: control.textStyle + verticalAlignment: Text.AlignVCenter + elide: Text.ElideRight + maximumLineCount: 1 + } + + delegate: ItemDelegate { + width: control.width + contentItem: GText { + text: modelData + textStyle: control.textStyle + elide: Text.ElideRight + verticalAlignment: Text.AlignVCenter + } + highlighted: control.highlightedIndex === index + + background: Rectangle { + implicitWidth: 100 + implicitHeight: Style.dimens.list_item_height + color: highlighted ? Style.color.background_pane_active : Style.color.background_pane + + GSeparator { + anchors { + left: parent.left + right: parent.right + bottom: parent.bottom + } + } + } + } + + background: Rectangle { + border.color: Style.color.border + border.width: control.visualFocus ? 2 : 1 + radius: Style.dimens.separator_size + color: Style.color.background_pane + } + + FocusFrame { + scope: control + marginFactor: 1.5 + } +} diff --git a/resources/qml/Governikus/Global/+mobile/GFlickable.qml b/resources/qml/Governikus/Global/GFlickable.qml similarity index 50% rename from resources/qml/Governikus/Global/+mobile/GFlickable.qml rename to resources/qml/Governikus/Global/GFlickable.qml index d5f3570e9..dd0168183 100644 --- a/resources/qml/Governikus/Global/+mobile/GFlickable.qml +++ b/resources/qml/Governikus/Global/GFlickable.qml @@ -1,11 +1,12 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 +import Governikus.Global 1.0 import Governikus.Style 1.0 Flickable { @@ -16,15 +17,11 @@ Flickable { property real scrollBarBottomPadding: 0 function scrollPageDown() { - if (contentHeight > height) { - Utils.scrollPageDown(baseItem) - } + Utils.scrollPageDown(baseItem) } function scrollPageUp() { - if (contentHeight > height) { - Utils.scrollPageUp(baseItem) - } + Utils.scrollPageUp(baseItem) } function highlightScrollbar() { @@ -33,19 +30,33 @@ Flickable { ScrollBar.vertical: scrollBarEnabled ? scrollBar.createObject() : null + function handleKeyPress(key) { + if (key === Qt.Key_PageDown) + baseItem.scrollPageDown() + else if (key === Qt.Key_PageUp) + baseItem.scrollPageUp() + else if (key === Qt.Key_End) + baseItem.contentY = baseItem.contentHeight - baseItem.height + else if (key === Qt.Key_Home) + baseItem.contentY = baseItem.originY + } + + Keys.onPressed: handleKeyPress(event.key) + maximumFlickVelocity: Constants.scrolling_speed + flickDeceleration: Constants.flickDeceleration flickableDirection: Flickable.VerticalFlick boundsMovement: Flickable.FollowBoundsBehavior - boundsBehavior: contentHeight <= height ? Flickable.StopAtBounds : Flickable.DragAndOvershootBounds + boundsBehavior: Constants.is_desktop ? Flickable.StopAtBounds : (contentHeight <= height ? Flickable.StopAtBounds : Flickable.DragAndOvershootBounds) onVisibleChanged: if (visible) highlightScrollbar() Component { id: scrollBar GScrollBar { - topPadding: baseItem.scrollBarTopPadding + Style.dimens.scrollbar_padding - bottomPadding: baseItem.scrollBarBottomPadding + Style.dimens.scrollbar_padding + topPadding: baseItem.scrollBarTopPadding + Style.dimens.scrollbar_padding_vertical + bottomPadding: baseItem.scrollBarBottomPadding + Style.dimens.scrollbar_padding_vertical } } } diff --git a/resources/qml/Governikus/Global/+mobile/GGridView.qml b/resources/qml/Governikus/Global/GGridView.qml similarity index 51% rename from resources/qml/Governikus/Global/+mobile/GGridView.qml rename to resources/qml/Governikus/Global/GGridView.qml index 991edb57f..a6624c4cb 100644 --- a/resources/qml/Governikus/Global/+mobile/GGridView.qml +++ b/resources/qml/Governikus/Global/GGridView.qml @@ -1,11 +1,12 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 +import Governikus.Global 1.0 import Governikus.Style 1.0 GridView { @@ -16,15 +17,11 @@ GridView { property real scrollBarBottomPadding: 0 function scrollPageDown() { - if (contentHeight > height) { - Utils.scrollPageDown(baseItem) - } + Utils.scrollPageDown(baseItem) } function scrollPageUp() { - if (contentHeight > height) { - Utils.scrollPageUp(baseItem) - } + Utils.scrollPageUp(baseItem) } function highlightScrollbar() { @@ -33,19 +30,33 @@ GridView { ScrollBar.vertical: scrollBarEnabled ? scrollBar.createObject() : null + function handleKeyPress(key) { + if (key === Qt.Key_PageDown) + baseItem.scrollPageDown() + else if (key === Qt.Key_PageUp) + baseItem.scrollPageUp() + else if (key === Qt.Key_End) + baseItem.positionViewAtEnd() + else if (key === Qt.Key_Home) + baseItem.positionViewAtBeginning() + } + + Keys.onPressed: handleKeyPress(event.key) + maximumFlickVelocity: Constants.scrolling_speed + flickDeceleration: Constants.flickDeceleration flickableDirection: Flickable.VerticalFlick boundsMovement: Flickable.FollowBoundsBehavior - boundsBehavior: contentHeight <= height ? Flickable.StopAtBounds : Flickable.DragAndOvershootBounds + boundsBehavior: Constants.is_desktop ? Flickable.StopAtBounds : (contentHeight <= height ? Flickable.StopAtBounds : Flickable.DragAndOvershootBounds) onVisibleChanged: if (visible) highlightScrollbar() Component { id: scrollBar GScrollBar { - topPadding: baseItem.scrollBarTopPadding + Style.dimens.scrollbar_padding - bottomPadding: baseItem.scrollBarBottomPadding + Style.dimens.scrollbar_padding + topPadding: baseItem.scrollBarTopPadding + Style.dimens.scrollbar_padding_vertical + bottomPadding: baseItem.scrollBarBottomPadding + Style.dimens.scrollbar_padding_vertical } } } diff --git a/resources/qml/Governikus/Global/GListView.qml b/resources/qml/Governikus/Global/GListView.qml new file mode 100644 index 000000000..da0cd3fe7 --- /dev/null +++ b/resources/qml/Governikus/Global/GListView.qml @@ -0,0 +1,64 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtGraphicalEffects 1.0 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 + +ListView { + id: baseItem + + property bool scrollBarEnabled: true + property real scrollBarTopPadding: 0 + property real scrollBarBottomPadding: 0 + property bool scrollBarAutohide: !Constants.is_desktop + + function scrollPageDown() { + Utils.scrollPageDown(baseItem) + } + + function scrollPageUp() { + Utils.scrollPageUp(baseItem) + } + + function highlightScrollbar() { + if (ScrollBar.vertical) ScrollBar.vertical.highlight() + } + + ScrollBar.vertical: scrollBarEnabled ? scrollBar.createObject() : null + + function handleKeyPress(key) { + if (key === Qt.Key_PageDown) + baseItem.scrollPageDown() + else if (key === Qt.Key_PageUp) + baseItem.scrollPageUp() + else if (key === Qt.Key_End) + baseItem.positionViewAtEnd() + else if (key === Qt.Key_Home) + baseItem.positionViewAtBeginning() + } + + Keys.onPressed: handleKeyPress(event.key) + + maximumFlickVelocity: Constants.scrolling_speed + flickDeceleration: Constants.flickDeceleration + flickableDirection: Flickable.VerticalFlick + + boundsMovement: Flickable.FollowBoundsBehavior + boundsBehavior: Constants.is_desktop ? Flickable.StopAtBounds : (contentHeight <= height ? Flickable.StopAtBounds : Flickable.DragAndOvershootBounds) + + onVisibleChanged: if (visible) highlightScrollbar() + + Component { + id: scrollBar + GScrollBar { + topPadding: baseItem.scrollBarTopPadding + Style.dimens.scrollbar_padding_vertical + bottomPadding: baseItem.scrollBarBottomPadding + Style.dimens.scrollbar_padding_vertical + autohide: scrollBarAutohide + } + } +} diff --git a/resources/qml/Governikus/Global/GRadioButton.qml b/resources/qml/Governikus/Global/GRadioButton.qml new file mode 100644 index 000000000..d1ffd6356 --- /dev/null +++ b/resources/qml/Governikus/Global/GRadioButton.qml @@ -0,0 +1,80 @@ +/* + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.View 1.0 + +RadioButton { + id: root + + readonly property int indicatorHeight: Math.ceil((textStyle.textSize + horizontalPadding) / 2) * 2 + property var textStyle: Style.text.normal + property bool tintIcon: false + + Accessible.name: text + + spacing: Constants.groupbox_spacing + indicator: Item {} + contentItem: RowLayout { + spacing: root.spacing + + Rectangle { + Layout.preferredHeight: root.indicatorHeight + Layout.preferredWidth: root.indicatorHeight + + radius: height / 2 + border.color: Style.color.accent + border.width: 2 + + Rectangle { + visible: root.checked + anchors.centerIn: parent + anchors.alignWhenCentered: false + height: parent.height / 2 + width: height + + radius: height / 2 + color: Style.color.accent + } + } + + TintableIcon { + visible: source != "" + Layout.preferredHeight: sourceSize.height + + source: root.icon.source + sourceSize.height: root.indicatorHeight + + tintEnabled: tintIcon + tintColor: root.textStyle.textColor + } + + GText { + Layout.fillWidth: true + + Accessible.ignored: true + + text: root.text + textStyle: root.textStyle + + } + } + + FocusFrame { + borderColor: Style.color.focus_indicator + scope: root + } + + MouseArea { + anchors.fill: parent + + cursorShape: root.checked ? Qt.ArrowCursor : Qt.PointingHandCursor + acceptedButtons: Qt.NoButton + } +} diff --git a/resources/qml/Governikus/Global/+mobile/GScrollBar.qml b/resources/qml/Governikus/Global/GScrollBar.qml similarity index 58% rename from resources/qml/Governikus/Global/+mobile/GScrollBar.qml rename to resources/qml/Governikus/Global/GScrollBar.qml index e9ab49de9..4d1532835 100644 --- a/resources/qml/Governikus/Global/+mobile/GScrollBar.qml +++ b/resources/qml/Governikus/Global/GScrollBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -16,17 +16,18 @@ ScrollBar { } property bool highlighted: false + property bool autohide: !Constants.is_desktop // Using only ScrollBar.AsNeeded leads to the scrollbar becoming visible when highlighted policy: size < 1.0 ? ScrollBar.AlwaysOn : ScrollBar.AlwaysOff minimumSize: Style.dimens.minimumScrollBarSize - contentItem: Rectangle { - implicitWidth: 3 + contentItem: Item { + + implicitWidth: Style.dimens.scrollbar_width + Style.dimens.scrollbar_padding_horizontal implicitHeight: 100 - radius: width / 2 - color: baseItem.pressed ? Style.color.accent : Constants.grey - opacity: (active || highlighted) ? 1.0 : 0.0 + + opacity: (!autohide || active || highlighted) ? 1.0 : 0.0 Behavior on opacity { NumberAnimation { @@ -34,6 +35,17 @@ ScrollBar { easing.type: Easing.InOutCubic } } + + Rectangle { + id: handler + + width: Style.dimens.scrollbar_width + height: parent.height + anchors.left: parent.left + + radius: width / 2 + color: baseItem.pressed ? Style.color.button : Style.color.button_disabled + } } onPolicyChanged: if (policy == ScrollBar.AlwaysOn) highlight() diff --git a/resources/qml/Governikus/Global/GSeparator.qml b/resources/qml/Governikus/Global/GSeparator.qml index 41306b8c4..87f950b02 100644 --- a/resources/qml/Governikus/Global/GSeparator.qml +++ b/resources/qml/Governikus/Global/GSeparator.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Global/GText.qml b/resources/qml/Governikus/Global/GText.qml index ab63e0bdc..9342fbc10 100644 --- a/resources/qml/Governikus/Global/GText.qml +++ b/resources/qml/Governikus/Global/GText.qml @@ -1,31 +1,53 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import Governikus.Style 1.0 Text { - property TextStyle textStyle: Style.text.normal + property TextStyle textStyle: Constants.is_desktop ? Style.text.normal_inverse : Style.text.normal Accessible.role: Accessible.StaticText Accessible.name: text color: textStyle.textColor + linkColor: textStyle.linkColor font.pixelSize: textStyle.textSize - wrapMode: Text.Wrap + wrapMode: d.nonMultilineElided ? Text.NoWrap : Text.Wrap + onLinkActivated: if (link !== '#') Qt.openUrlExternally(link) onTextStyleChanged: { if (textStyle.textFamily !== "") { font.family = textStyle.textFamily } } + Keys.onSpacePressed: { + // Parse the text with a regular expression to see if there's a link somewhere. This has been done by Qt already, but there's no way to access this yet, see https://bugreports.qt.io/browse/QTBUG-79850 + let reg = /href="(.*?)"/g + let match = reg.exec(text) + if (!match) { // no link + return + } + let link = match[1] + if (reg.exec(text)) { + console.log("More than one link found!") + return + } + linkActivated(link) + } + + QtObject { + id: d + + readonly property bool nonMultilineElided: maximumLineCount == 1 && elide !== Text.ElideNone + } MouseArea { anchors.fill: parent acceptedButtons: Qt.NoButton - cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.ArrowCursor + cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : undefined } } diff --git a/resources/qml/Governikus/Global/GTextField.qml b/resources/qml/Governikus/Global/GTextField.qml new file mode 100644 index 000000000..7f7378588 --- /dev/null +++ b/resources/qml/Governikus/Global/GTextField.qml @@ -0,0 +1,45 @@ +/* + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 + +import Governikus.Style 1.0 +import Governikus.View 1.0 +import Governikus.Type.SettingsModel 1.0 + +TextField { + id: baseItem + + property var textStyle: Constants.is_desktop ? Style.text.normal_inverse : Style.text.normal + property int enterKeyType: Qt.EnterKeyDefault + property bool valid: true + + Accessible.role: Accessible.EditableText + Accessible.editable: true + Accessible.name: echoMode === TextInput.Normal ? displayText : "" + + EnterKey.type: enterKeyType + + activeFocusOnTab: true + font.pixelSize: textStyle.textSize + color: textStyle.textColor + selectByMouse: true + selectedTextColor: Style.color.primary_text_inverse + selectionColor: Style.color.accent + placeholderTextColor: Style.color.secondary_text + ToolTip.visible: text.length === maximumLength && focus + ToolTip.text: qsTr("Maximum allowed length reached.") + SettingsModel.translationTrigger + + background: Rectangle { + radius: Style.dimens.button_radius + color: baseItem.enabled ? Style.color.background_pane : Constants.grey + border.color: baseItem.valid ? Style.color.border : Constants.red + border.width: Style.dimens.separator_size + } + + FocusFrame { + scope: baseItem + } +} diff --git a/resources/qml/Governikus/Global/+desktop/LocationButton.qml b/resources/qml/Governikus/Global/LocationButton.qml similarity index 53% rename from resources/qml/Governikus/Global/+desktop/LocationButton.qml rename to resources/qml/Governikus/Global/LocationButton.qml index 02d516a8b..49cdd03de 100644 --- a/resources/qml/Governikus/Global/+desktop/LocationButton.qml +++ b/resources/qml/Governikus/Global/LocationButton.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -12,13 +12,12 @@ import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SettingsModel 1.0 -GButton { +GRadioButton { id: root property string language property alias image: root.icon.source - cursorShape: SettingsModel.language === language ? Qt.ArrowCursor : Qt.PointingHandCursor - opacity: SettingsModel.language === language ? 1.0 : 0.5 - onClicked: SettingsModel.language = language + checked: SettingsModel.language === language + onCheckedChanged: if (checked) SettingsModel.language = language } diff --git a/resources/qml/Governikus/Global/NumberField.qml b/resources/qml/Governikus/Global/NumberField.qml new file mode 100644 index 000000000..e998a13a7 --- /dev/null +++ b/resources/qml/Governikus/Global/NumberField.qml @@ -0,0 +1,162 @@ +/* + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.View 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.SettingsModel 1.0 + +Item { + id: root + + readonly property bool validInput: echoField.acceptableInput && confirmedInput + readonly property bool confirmedInput: inputConfirmation.length != text.length || inputConfirmation === text + readonly property real eyeWidth: eye.width + eye.anchors.leftMargin + property alias text: echoField.text + property alias passwordLength: echoField.maximumLength + property string inputConfirmation + + function append(number) { echoField.insert(echoField.length, number) } + function removeLast() { echoField.remove(echoField.length - 1, echoField.length) } + + height: Math.max(layout.height, eye.height) + width: layout.width + eyeWidth + + activeFocusOnTab: true + Accessible.role: Accessible.EditableText + Accessible.name: (eye.activated + //: LABEL DESKTOP_QML Screenreader text for the password field + ? qsTr("The password is visible.") + //: LABEL DESKTOP_QML Screenreader text for the password field + : qsTr("The password is hidden.") + //: LABEL DESKTOP_QML Screenreader text for the password field + ) + " " + qsTr("You entered %1 of %2 digits.").arg(text.length).arg(passwordLength) + + SettingsModel.translationTrigger + Keys.onPressed: { + if (event.key >= Qt.Key_0 && event.key <= Qt.Key_9) { + numberField.append(event.key - Qt.Key_0) + } + else if (event.key === Qt.Key_Backspace) { + numberField.removeLast() + } + } + + FontMetrics { + id: fontMetrics + + font.bold: true + font.pixelSize: Constants.is_desktop ? ApplicationModel.scaleFactor * 65 : 24 + } + + TextInput { + id: echoField + + visible: false + + maximumLength: 6 + validator: RegExpValidator { + regExp: new RegExp("[0-9]{" + echoField.maximumLength + "}") + } + } + + FocusFrame { + framee: layout + } + + RowLayout { + id: layout + + spacing: Constants.is_desktop ? Constants.component_spacing : Constants.groupbox_spacing + + Repeater { + model: root.passwordLength + + Text { + readonly property real markerWidth: fontMetrics.averageCharacterWidth * 1.4 + + Layout.preferredWidth: markerWidth + Layout.preferredHeight: fontMetrics.height + Constants.text_spacing + + verticalAlignment: Text.AlignTop + horizontalAlignment: Text.AlignHCenter + text: eye.activated ? root.text.substr(index, 1) : "" + color: Constants.is_desktop ? Style.color.primary_text_inverse : Style.color.primary_text + font: fontMetrics.font + + Rectangle { + width: parent.markerWidth + height: Constants.is_desktop ? Math.max(ApplicationModel.scaleFactor * 4, 1) : 1 + anchors { + bottom: parent.bottom + horizontalCenter: parent.horizontalCenter + } + + color: parent.color + } + + Rectangle { + visible: !eye.activated && root.text.charAt(index) !== "" + width: fontMetrics.averageCharacterWidth + height: width + anchors { + centerIn: parent + verticalCenterOffset: -Constants.text_spacing / 2 + } + + radius: height / 2 + color: parent.color + } + } + } + } + + Button { + id: eye + + property bool activated: false + + height: implicitHeight + (Constants.is_desktop ? 0 : Constants.text_spacing) + width: implicitWidth + (Constants.is_desktop ? 0 : Constants.text_spacing) + + anchors { + verticalCenter: parent.verticalCenter + leftMargin: Constants.groupbox_spacing + right: parent.right + } + + Accessible.onPressAction: if (Qt.platform.os === "ios") clicked(null) + + text: (activated + //: LABEL DESKTOP_QML Screenreader text for the eye icon to change the password visibility + ? qsTr("Press to hide the password") + //: LABEL DESKTOP_QML Screenreader text for the eye icon to change the password visibility + : qsTr("Press to show the password") + ) + SettingsModel.translationTrigger + + contentItem: Item {} + background: TintableIcon { + tintColor: Constants.is_desktop ? Style.color.secondary_text_inverse : Style.color.secondary_text + source: eye.activated ? "qrc:///images/visibility.svg" : "qrc:///images/visibility_off.svg" + sourceSize.height: Constants.is_desktop ? Style.dimens.large_icon_size : Style.dimens.small_icon_size + fillMode: Image.Pad + } + + onVisibleChanged: if (visible) activated = false + onClicked: eye.activated = !eye.activated + + MouseArea { + anchors.fill: parent + + cursorShape: Qt.PointingHandCursor + acceptedButtons: Qt.NoButton + } + + FocusFrame {} + } +} diff --git a/resources/qml/Governikus/Global/StatusIcon.qml b/resources/qml/Governikus/Global/StatusIcon.qml index 0254ec1be..e6d511e54 100644 --- a/resources/qml/Governikus/Global/StatusIcon.qml +++ b/resources/qml/Governikus/Global/StatusIcon.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -16,7 +16,7 @@ Rectangle { width: height radius: height / 2 border.width: height / 40; - border.color: Constants.white + border.color: Style.color.primary_text_inverse color: Style.color.transparent BusyIndicator { @@ -31,7 +31,9 @@ Rectangle { radius: height / 2 anchors.fill: parent anchors.margins: parent.height / 8; - color: Constants.white + color: Style.color.background_pane + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border Image { id: image diff --git a/resources/qml/Governikus/Global/TintableIcon.qml b/resources/qml/Governikus/Global/TintableIcon.qml new file mode 100644 index 000000000..3d539c42a --- /dev/null +++ b/resources/qml/Governikus/Global/TintableIcon.qml @@ -0,0 +1,38 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtGraphicalEffects 1.0 + +import Governikus.Style 1.0 + +Item { + property alias source: image.source + property alias sourceSize: image.sourceSize + property alias transformOrigin: image.transformOrigin + property alias fillMode: image.fillMode + property bool tintEnabled: true + property color tintColor: Style.color.primary_text + + implicitWidth: image.implicitWidth + implicitHeight: image.implicitHeight + + Image { + id: image + + visible: !tintEnabled || GraphicsInfo.api === GraphicsInfo.Software + anchors.fill: parent + + fillMode: Image.PreserveAspectFit + } + + ColorOverlay { + visible: tintEnabled && GraphicsInfo.api !== GraphicsInfo.Software + anchors.fill: parent + + cached: true + color: tintColor + source: image + } +} diff --git a/resources/qml/Governikus/Global/Utils.js b/resources/qml/Governikus/Global/Utils.js deleted file mode 100644 index 40b5c7bc7..000000000 --- a/resources/qml/Governikus/Global/Utils.js +++ /dev/null @@ -1,65 +0,0 @@ -function escapeHtml(str) -{ - return String(str).replace(/&/g, '&').replace(//g, '>').replace(/"/g, '"'); -} - -function isToday(date) -{ - var today = new Date; - return isSameDate(today, date); -} - -function isYesterday(date) -{ - var yesterday = new Date; - yesterday.setDate(yesterday.getDate() - 1); - return isSameDate(yesterday, date); -} - -function isThisWeek(date) -{ - var monday = new Date; - monday.setDate(monday.getDate()-monday.getDay()); - - date.setDate(date.getDate()-date.getDay()); - - return isSameDate(monday, date); -} - -function isSameDate(one, another) -{ - return one.getFullYear() === another.getFullYear() && one.getMonth() === another.getMonth() && one.getDate() === another.getDate(); -} - -function getRandomInt(min, max) -{ - return Math.floor(Math.random() * (max - min)) + min; -} - -function providerIconSource(baseName) { - var platform = plugin.platformStyle.indexOf("tablet") !== -1 ? "+tablet/" : "" - - return "qrc:///images/provider/" + platform + baseName + ".png" -} - -function scrollPageDown(pFlickable) { - if (pFlickable.height >= pFlickable.contentHeight) { - return - } - - pFlickable.contentY += pFlickable.height - if (pFlickable.contentY + pFlickable.height > pFlickable.contentHeight) { - pFlickable.contentY = pFlickable.contentHeight - pFlickable.height - } -} - -function scrollPageUp(pFlickable) { - if (pFlickable.height >= pFlickable.contentHeight) { - return - } - - pFlickable.contentY -= pFlickable.height - if (pFlickable.contentY < 0) { - pFlickable.contentY = 0 - } -} diff --git a/resources/qml/Governikus/Global/Utils.qml b/resources/qml/Governikus/Global/Utils.qml new file mode 100644 index 000000000..ce58475b6 --- /dev/null +++ b/resources/qml/Governikus/Global/Utils.qml @@ -0,0 +1,93 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +pragma Singleton + +import QtQuick 2.10 + +import Governikus.Type.Random 1.0 + +QtObject { + + function escapeHtml(str) + { + return String(str).replace(/&/g, '&').replace(//g, '>').replace(/"/g, '"'); + } + + function isToday(date) + { + var today = new Date; + return isSameDate(today, date); + } + + function isYesterday(date) + { + var yesterday = new Date; + yesterday.setDate(yesterday.getDate() - 1); + return isSameDate(yesterday, date); + } + + function isThisWeek(date) + { + var monday = new Date; + monday.setDate(monday.getDate()-monday.getDay()); + + date.setDate(date.getDate()-date.getDay()); + + return isSameDate(monday, date); + } + + function isSameDate(one, another) + { + return one.getFullYear() === another.getFullYear() && one.getMonth() === another.getMonth() && one.getDate() === another.getDate(); + } + + function providerIconSource(baseName) { + var platform = plugin.platformStyle.indexOf("tablet") !== -1 ? "+tablet/" : "" + + return "qrc:///images/provider/" + platform + baseName + ".png" + } + + function scrollPageDown(pFlickable) { + if (pFlickable.height >= pFlickable.contentHeight) { + return + } + + if (pFlickable.atYEnd) { + return + } + + pFlickable.contentY = Math.min(pFlickable.contentY + pFlickable.height, pFlickable.originY + pFlickable.contentHeight - pFlickable.height) + } + + function scrollPageUp(pFlickable) { + if (pFlickable.height >= pFlickable.contentHeight) { + return + } + + if (pFlickable.atYBeginning) { + return + } + + pFlickable.contentY = Math.max(pFlickable.contentY - pFlickable.height, pFlickable.originY) + } + + function shuffle(pArray) { + for (let i = pArray.length - 1; i > 0; i--) { + let j = Random.randomInt(0, i); + let x = pArray[i]; + pArray[i] = pArray[j]; + pArray[j] = x; + } + return pArray; + } + + function helpTopicOf(pComponent, pDefaultHelpTopic) { + if (pComponent && typeof(pComponent.helpTopic) !== "undefined") { + return pComponent.helpTopic + } else { + return pDefaultHelpTopic + } + } +} diff --git a/resources/qml/Governikus/Global/qmldir b/resources/qml/Governikus/Global/qmldir index b3fb4e21d..6e5161ee7 100644 --- a/resources/qml/Governikus/Global/qmldir +++ b/resources/qml/Governikus/Global/qmldir @@ -6,9 +6,10 @@ internal PlatformConstants PlatformConstants.qml internal BrandConstants BrandConstants.qml internal DeviceConstants DeviceConstants.qml -Utils 1.0 Utils.js -Category 1.0 Category.js +singleton Utils 1.0 Utils.qml +singleton Category 1.0 Category.qml +BinaryDecisionView 1.0 BinaryDecisionView.qml ConfirmationPopup 1.0 ConfirmationPopup.qml GButton 1.0 GButton.qml GCheckBox 1.0 GCheckBox.qml @@ -22,10 +23,12 @@ GFlickable 1.0 GFlickable.qml GGridView 1.0 GGridView.qml GListView 1.0 GListView.qml GScrollBar 1.0 GScrollBar.qml +LabeledSwitch 1.0 LabeledSwitch.qml LabeledText 1.0 LabeledText.qml ListItem 1.0 ListItem.qml LocationButton 1.0 LocationButton.qml NavigationButton 1.0 NavigationButton.qml +NumberField 1.0 NumberField.qml Pane 1.0 Pane.qml RoundedRectangle 1.0 RoundedRectangle.qml ScrollablePane 1.0 ScrollablePane.qml @@ -38,4 +41,6 @@ TabbedPane 1.0 TabbedPane.qml TabbedPaneDelegateIconAndText 1.0 TabbedPaneDelegateIconAndText.qml TabbedPaneDelegateIconAndThreeLineText 1.0 TabbedPaneDelegateIconAndThreeLineText.qml TabbedPaneDelegateOneLineText 1.0 TabbedPaneDelegateOneLineText.qml +TitledSeparator 1.0 TitledSeparator.qml +TintableIcon 1.0 TintableIcon.qml ToggleableOption 1.0 ToggleableOption.qml diff --git a/resources/qml/Governikus/HistoryView/+desktop/HistoryRemovalTimePeriodControl.qml b/resources/qml/Governikus/HistoryView/+desktop/HistoryRemovalTimePeriodControl.qml index 9484fecbf..5f1eb59f2 100644 --- a/resources/qml/Governikus/HistoryView/+desktop/HistoryRemovalTimePeriodControl.qml +++ b/resources/qml/Governikus/HistoryView/+desktop/HistoryRemovalTimePeriodControl.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -19,7 +19,7 @@ RowLayout { property alias description: description property alias removalPeriod: removalPeriod - Accessible.role: Accessible.Heading + Accessible.role: Accessible.Grouping Accessible.name: description.text spacing: Constants.groupbox_spacing @@ -31,10 +31,9 @@ RowLayout { //: LABEL DESKTOP_QML text: qsTr("Time period") + SettingsModel.translationTrigger + textStyle: Style.text.normal_inverse - FocusFrame { - dynamic: false - } + FocusFrame {} } GComboBox { diff --git a/resources/qml/Governikus/HistoryView/+desktop/HistoryView.qml b/resources/qml/Governikus/HistoryView/+desktop/HistoryView.qml index 903903712..8ac2d5ce7 100644 --- a/resources/qml/Governikus/HistoryView/+desktop/HistoryView.qml +++ b/resources/qml/Governikus/HistoryView/+desktop/HistoryView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQml 2.10 @@ -24,21 +24,24 @@ SectionPage { ConfirmationPopup { id: deleteHistoryConfirmationPopup + width: ApplicationModel.scaleFactor * 600 + //: INFO DESKTOP_QML Header of the confirmation dialog to clear the entire authentication history. title: qsTr("Delete history?") + SettingsModel.translationTrigger //: INFO DESKTOP_QML Content of the confirmation dialog to clear the entire authentication history. - text: qsTr("Please confirm that you want to delete your history entries.") + SettingsModel.translationTrigger + text: qsTr("All history entries will be deleted.") + SettingsModel.translationTrigger onConfirmed: { var timePeriod = removalPeriod.period var removedItemCount = SettingsModel.removeHistory(timePeriod) - tabbedPane.currentIndex = tabbedPane.count > 0 ? 0 : -1 + tabbedPane.currentIndex = tabbedPane.sectionCount > 0 ? 0 : -1 //: INFO DESKTOP_QML Feedback how many history entries were removed. - ApplicationModel.showFeedback(qsTr("Removed %1 entries from the history.").arg(removedItemCount)) + ApplicationModel.showFeedback(qsTr("Deleted %1 entries from the history.").arg(removedItemCount)) } HistoryRemovalTimePeriodControl { id: removalPeriod + width: parent.width } } @@ -46,10 +49,16 @@ SectionPage { titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML text: qsTr("History") + SettingsModel.translationTrigger + helpTopic: "history" customSubAction: SearchBar { id: searchBar + anchors.verticalCenter: parent ? parent.verticalCenter : undefined + onDisplayTextChanged: HistoryModel.searchFilter.setFilterString(displayText) + + //: LABEL DESKTOP_QML + placeholderText: qsTr("Search in history") + SettingsModel.translationTrigger } } @@ -69,7 +78,7 @@ SectionPage { Utils.isYesterday(model.dateTime) ? qsTr("yesterday") : Utils.isThisWeek(model.dateTime) ? model.dateTime.toLocaleString(Qt.locale(), qsTr("dddd")) : model.dateTime.toLocaleString(Qt.locale(), qsTr("dd.MM.yyyy")) ) : "") + SettingsModel.translationTrigger - mainText: model ? model.subject : "" + sectionName: model ? model.subject : "" footerText: model ? model.purpose : "" iconPath: model ? model.providerIcon : "" } @@ -81,67 +90,54 @@ SectionPage { } footerItem: Item { - height: Math.max(clearHistoryButton.implicitHeight, saveHistoryToPdf.implicitHeight) - - GButton { - id: clearHistoryButton + height: buttonLayout.implicitHeight - anchors { - top: parent.top - bottom: parent.bottom - left: parent.left - right: parent.horizontalCenter - rightMargin: (Constants.groupbox_spacing / 2) - } + ColumnLayout { + id: buttonLayout - Accessible.name: text - activeFocusOnTab: true + anchors.fill: parent + anchors.rightMargin: Constants.groupbox_spacing + spacing: Constants.groupbox_spacing - icon.source: "qrc:///images/trash_icon_white.svg" - //: LABEL DESKTOP_QML - text: qsTr("Clear history") + SettingsModel.translationTrigger - onClicked: deleteHistoryConfirmationPopup.open() - } + GButton { + id: clearHistoryButton - GButton { - id: saveHistoryToPdf + Layout.fillWidth: true - anchors { - top: parent.top - bottom: parent.bottom - left: parent.horizontalCenter - right: parent.right - rightMargin: Constants.groupbox_spacing - leftMargin: Math.floor(Constants.groupbox_spacing / 2) + icon.source: "qrc:///images/trash_icon_white.svg" + //: LABEL DESKTOP_QML + text: qsTr("Clear history") + SettingsModel.translationTrigger + tintIcon: true + onClicked: deleteHistoryConfirmationPopup.open() } - Accessible.name: text - activeFocusOnTab: true - - icon.source: "qrc:///images/icon_save.svg" - //: LABEL DESKTOP_QML - text: qsTr("Save to pdf") + SettingsModel.translationTrigger - onClicked: { - var now = new Date().toLocaleDateString(Qt.locale(), "yyyy-MM-dd") - var filenameSuggestion = "%1.%2.%3.pdf".arg(Qt.application.name).arg(qsTr("History")).arg(now) - console.log("filenameSuggestion", filenameSuggestion) - appWindow.openSaveFileDialog(HistoryModel.exportHistory, filenameSuggestion, "pdf") + GButton { + id: saveHistoryToPdf + + Layout.fillWidth: true + + icon.source: "qrc:///images/icon_save.svg" + //: LABEL DESKTOP_QML + text: qsTr("Save as PDF...") + SettingsModel.translationTrigger + tintIcon: true + onClicked: { + let now = new Date().toLocaleDateString(Qt.locale(), "yyyy-MM-dd") + let filenameSuggestion = "%1.%2.%3.pdf".arg(Qt.application.name).arg(qsTr("History")).arg(now) + appWindow.openSaveFileDialog(HistoryModel.exportHistory, filenameSuggestion, "pdf") + } } } } } GText { - id: textNoHistoryEntries - visible: tabbedPane.sectionCount === 0 anchors.centerIn: parent - Accessible.name: text activeFocusOnTab: true //: INFO DESKTOP_QML No authentication history, placeholder text. text: qsTr("Currently there are no history entries.") + SettingsModel.translationTrigger - textStyle: Style.text.header + textStyle: Style.text.header_inverse } } diff --git a/resources/qml/Governikus/HistoryView/+desktop/HistoryViewDetails.qml b/resources/qml/Governikus/HistoryView/+desktop/HistoryViewDetails.qml index 4fa72dc58..3ef0df417 100644 --- a/resources/qml/Governikus/HistoryView/+desktop/HistoryViewDetails.qml +++ b/resources/qml/Governikus/HistoryView/+desktop/HistoryViewDetails.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -85,7 +85,7 @@ Item { activeFocusOnTab: true //: LABEL DESKTOP_QML - label: qsTr("Requested data") + SettingsModel.translationTrigger + label: qsTr("Submitted data") + SettingsModel.translationTrigger text: historyModelItem ? historyModelItem.requestedData : "" } diff --git a/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryListViewDelegate.qml b/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryListViewDelegate.qml index 5fb8d1bed..cbee04512 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryListViewDelegate.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryListViewDelegate.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -7,6 +7,7 @@ import QtQuick 2.10 import Governikus.Global 1.0 import Governikus.Style 1.0 import Governikus.Type.HistoryModel 1.0 +import Governikus.Type.SettingsModel 1.0 HistoryListItem { id: listItem @@ -15,22 +16,28 @@ HistoryListItem { contentMarginRight: deleteButton.width + 2 * Constants.groupbox_spacing - showRightArrow: false - Image { id: deleteButton - sourceSize.width: Style.dimens.small_icon_size + anchors.right: parent.right - anchors.top: parent.top + anchors.verticalCenter: parent.verticalCenter anchors.margins: Constants.groupbox_spacing + sourceSize.width: Style.dimens.small_icon_size source: "qrc:///images/trash_icon.svg" fillMode: Image.PreserveAspectFit + } + + MouseArea { + height: parent.height + anchors.right: parent.right + anchors.left: deleteButton.left + anchors.leftMargin: - Constants.groupbox_spacing - MouseArea { - anchors.fill: parent - onClicked: HistoryModel.removeRows(historyModelItem ? historyModelItem.index : -1, 1) - } + //: LABEL ANDROID + Accessible.name: qsTr("Delete entry") + SettingsModel.translationTrigger + Accessible.role: Accessible.Button + onClicked: HistoryModel.removeRows(index, 1) } } diff --git a/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryView.qml b/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryView.qml index 34a688a34..f58ea3d48 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryView.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryView.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.View 1.0 diff --git a/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryViewTitleBarControls.qml b/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryViewTitleBarControls.qml index e48b7212e..d226f0c76 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryViewTitleBarControls.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/+android/HistoryViewTitleBarControls.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -8,14 +8,12 @@ import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 -import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SettingsModel 1.0 - RowLayout { - id: historyControls + id: baseItem - property bool showDeleteAll: true + property alias showDeleteAll: deleteEntriesButtonImage.visible height: Style.dimens.titlebar_height @@ -25,23 +23,9 @@ RowLayout { id: deleteHistoryConfirmationPopup } - GSwitch { - id: enableHistorySwitch - - color: Constants.green - initialState: SettingsModel.historyEnabled - onSwitched: { - SettingsModel.historyEnabled = enableHistorySwitch.isOn - //: LABEL ANDROID IOS - ApplicationModel.showFeedback((SettingsModel.historyEnabled ? qsTr("History enabled") : qsTr("History disabled")) + SettingsModel.translationTrigger) - } - } - Image { id: deleteEntriesButtonImage - visible: historyControls.showDeleteAll - sourceSize.height: 36 sourceSize.width: 36 @@ -49,10 +33,11 @@ RowLayout { source: "qrc:///images/trash_icon_white.svg" MouseArea { - id: deleteEntriesButton - anchors.fill: parent + //: LABEL ANDROID + Accessible.name: qsTr("Delete all entries") + SettingsModel.translationTrigger + Accessible.role: Accessible.Button onClicked: deleteHistoryConfirmationPopup.open() } } diff --git a/resources/qml/Governikus/HistoryView/+mobile/+ios/HistoryListViewDelegate.qml b/resources/qml/Governikus/HistoryView/+mobile/+ios/HistoryListViewDelegate.qml index 55b8387b3..f46ef5bae 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/+ios/HistoryListViewDelegate.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/+ios/HistoryListViewDelegate.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -14,6 +14,7 @@ SwipeActionDelegate { id: swipeComponent property var historyModelItem + property bool showSeparator: true actionColor: Constants.red actionIcon: "qrc:///images/trash_icon_white.svg" @@ -24,6 +25,7 @@ SwipeActionDelegate { historyModelItem: swipeComponent.historyModelItem mouseAreaEnabled: false pressed: swipeComponent.pressed + showSeparator: swipeComponent.showSeparator } onActionClicked: HistoryModel.removeRows(index, 1) diff --git a/resources/qml/Governikus/HistoryView/+mobile/+ios/HistoryView.qml b/resources/qml/Governikus/HistoryView/+mobile/+ios/HistoryView.qml index 64a78b1a5..87e9ee62d 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/+ios/HistoryView.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/+ios/HistoryView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/HistoryView/+mobile/BaseHistoryView.qml b/resources/qml/Governikus/HistoryView/+mobile/BaseHistoryView.qml index 9a8ec4b23..d8a3a08a6 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/BaseHistoryView.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/BaseHistoryView.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -56,8 +56,16 @@ SectionPage { Accessible.onScrollDownAction: historyListView.positionViewAtIndex(index, ListView.Beginning) Accessible.onScrollUpAction: historyListView.positionViewAtIndex(index, ListView.End) + showSeparator: index < listView.count - 1 + onClicked: firePushWithProperties(detailsHistoryView, {historyModelItem: historyModelItem}) } + + footer: Component { + GSeparator { + width: parent.width + } + } } Component { diff --git a/resources/qml/Governikus/HistoryView/+mobile/HistoryListItem.qml b/resources/qml/Governikus/HistoryView/+mobile/HistoryListItem.qml index 02b59466f..e5dda1fbd 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/HistoryListItem.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/HistoryListItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/HistoryView/+mobile/HistoryViewConfirmationPopup.qml b/resources/qml/Governikus/HistoryView/+mobile/HistoryViewConfirmationPopup.qml index 05f0d1863..8dca679ab 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/HistoryViewConfirmationPopup.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/HistoryViewConfirmationPopup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -14,7 +14,7 @@ ConfirmationPopup { //: LABEL ANDROID IOS title: qsTr("Delete history") + SettingsModel.translationTrigger //: LABEL ANDROID IOS Confirmaton popup to clear all history entries. - text: qsTr("Please confirm that you want to delete your complete history.") + SettingsModel.translationTrigger + text: qsTr("All history entries will be deleted.") + SettingsModel.translationTrigger //: LABEL ANDROID IOS okButtonText: qsTr("Delete") + SettingsModel.translationTrigger diff --git a/resources/qml/Governikus/HistoryView/+mobile/HistoryViewDetails.qml b/resources/qml/Governikus/HistoryView/+mobile/HistoryViewDetails.qml index 5e39751e7..45d5286c5 100644 --- a/resources/qml/Governikus/HistoryView/+mobile/HistoryViewDetails.qml +++ b/resources/qml/Governikus/HistoryView/+mobile/HistoryViewDetails.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.TitleBar 1.0 @@ -73,7 +73,7 @@ SectionPage { Accessible.onScrollUpAction: scrollPageUp() //: LABEL ANDROID IOS - label: qsTr("Requested data") + SettingsModel.translationTrigger + label: qsTr("Submitted data") + SettingsModel.translationTrigger text: historyModelItem ? historyModelItem.requestedData : "" width: parent.width } diff --git a/resources/qml/Governikus/IdentifyView/+desktop/CertificateDescriptionPage.qml b/resources/qml/Governikus/IdentifyView/+desktop/CertificateDescriptionPage.qml index 91153522b..e8776cfae 100644 --- a/resources/qml/Governikus/IdentifyView/+desktop/CertificateDescriptionPage.qml +++ b/resources/qml/Governikus/IdentifyView/+desktop/CertificateDescriptionPage.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -15,7 +15,7 @@ SectionPage { signal exit() - Accessible.name: qsTr("Self-authentication data view") + SettingsModel.translationTrigger + Accessible.name: qsTr("Self-Authentication data view") + SettingsModel.translationTrigger Accessible.description: qsTr("This is the self-authentication data view of the AusweisApp2.") + SettingsModel.translationTrigger titleBarAction: TitleBarAction { @@ -25,12 +25,10 @@ SectionPage showHelp: false } - Pane { + ScrollablePane { id: pane - anchors.top: parent.top - anchors.left: parent.left - anchors.right: parent.right + anchors.fill: parent anchors.margins: Constants.pane_padding //: LABEL DESKTOP_QML @@ -60,9 +58,6 @@ SectionPage anchors.bottom: pane.bottom anchors.margins: Constants.pane_padding - activeFocusOnTab: true - Accessible.name: button.text - //: LABEL DESKTOP_QML text: qsTr("Close") + SettingsModel.translationTrigger onClicked: parent.exit() diff --git a/resources/qml/Governikus/IdentifyView/+desktop/DataGroup.qml b/resources/qml/Governikus/IdentifyView/+desktop/DataGroup.qml index 10d66f403..3fadaaab3 100644 --- a/resources/qml/Governikus/IdentifyView/+desktop/DataGroup.qml +++ b/resources/qml/Governikus/IdentifyView/+desktop/DataGroup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -23,16 +23,16 @@ Column { visible: count > 0 spacing: Constants.pane_spacing - PaneTitle { + GText { id: dataTitle activeFocusOnTab: true - Accessible.role: Accessible.Heading Accessible.name: dataTitle.text + textStyle: Style.text.header_accent + FocusFrame { - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } @@ -48,20 +48,16 @@ Column { anchors.verticalCenter: parent.verticalCenter activeFocusOnTab: true - Accessible.role: Accessible.Paragraph Accessible.name: noDataText.text //: LABEL DESKTOP_QML text: qsTr("No data requested") + SettingsModel.translationTrigger - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal } - Rectangle { - height: Math.max(ApplicationModel.scaleFactor * 1, 1) + GSeparator { width: parent.width anchors.bottom: parent.bottom - - color: Constants.grey } } @@ -87,8 +83,12 @@ Column { height: dataText.height * 1.5 activeFocusOnTab: true - Accessible.role: optional ? Accessible.CheckBox : Accessible.Paragraph - Accessible.name: dataText.text + (optional ? ": " + (selected ? qsTr("selected") : qsTr("not selected")) : "") + SettingsModel.translationTrigger + Accessible.role: optional ? Accessible.CheckBox : Accessible.StaticText + Accessible.name: dataText.text + (optional ? ": " + ( + selected ? + qsTr("selected") : + qsTr("not selected") + ) : "") + SettingsModel.translationTrigger Keys.onSpacePressed: if (optional) selected = !selected @@ -101,22 +101,18 @@ Column { anchors.rightMargin: checkBox.visible ? checkBox.width + Constants.pane_spacing : 0 text: name - textStyle: Style.text.normal_inverse + textStyle: writeRight ? Style.text.normal_warning : Style.text.normal FocusFrame { scope: rightItem marginFactor: 0.7 - border.color: Constants.black - dynamic: false + borderColor: Style.color.focus_indicator } } - Rectangle { - height: Math.max(ApplicationModel.scaleFactor * 1, 1) + GSeparator { width: parent.width anchors.bottom: parent.bottom - - color: Constants.grey } GCheckBox { diff --git a/resources/qml/Governikus/IdentifyView/+desktop/EditRights.qml b/resources/qml/Governikus/IdentifyView/+desktop/EditRights.qml index 0e3fc3118..6147f7598 100644 --- a/resources/qml/Governikus/IdentifyView/+desktop/EditRights.qml +++ b/resources/qml/Governikus/IdentifyView/+desktop/EditRights.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -58,7 +58,7 @@ SectionPage { anchors.right: parent.right spacing: Constants.pane_spacing - topPadding: providerRect.height + topPadding: (providerImage.height / 2) + (Constants.pane_padding * 2) Rectangle { id: providerRect @@ -67,12 +67,25 @@ SectionPage { anchors.left: parent.left anchors.right: parent.right - color: Constants.white + color: Style.color.background_pane + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border + + Image { + id: providerImage + + anchors.left: parent.left + anchors.leftMargin: Constants.pane_padding + anchors.verticalCenter: parent.top + + source: "qrc:///images/npa.svg" + sourceSize.height: providerColumn.height + } Column { id: providerColumn - anchors.left: parent.left + anchors.left: providerImage.right anchors.right: parent.right anchors.margins: Constants.pane_padding @@ -81,84 +94,82 @@ SectionPage { spacing: Constants.pane_spacing Item { - height: providerText.height - width: parent.width + height: moreButton.height + anchors.left: parent.left + anchors.right: parent.right - Image { - id: providerImage + ProviderInfoSection { + id: providerInfo1 anchors.left: parent.left - anchors.bottom: parent.bottom + anchors.right: moreButton.left + anchors.rightMargin: Constants.component_spacing + anchors.top: parent.top - source: "qrc:///images/npa.svg" - sourceSize.height: providerText.height * 4 + activeFocusOnTab: true + + image: "qrc:///images/provider/information.svg" + //: LABEL DESKTOP_QML + title: qsTr("You are about to identify yourself towards the following provider") + SettingsModel.translationTrigger + name: certificateDescriptionModel.subjectName } - GText { - id: providerText + GButton { + id: moreButton - anchors.left: providerImage.right - anchors.leftMargin: Constants.pane_spacing anchors.right: parent.right + anchors.top: parent.top activeFocusOnTab: true - Accessible.role: Accessible.Heading - Accessible.name: providerText.text + Accessible.description: qsTr("Show more information about the service provider") + SettingsModel.translationTrigger //: LABEL DESKTOP_QML - text: qsTr("You are about to identify yourself towards the following service provider:") + SettingsModel.translationTrigger - textStyle: Style.text.normal_inverse - - FocusFrame { - border.color: Constants.black - dynamic: false - } + text: qsTr("more...") + SettingsModel.translationTrigger + onClicked: showProviderInformation(true) } } Item { - height: providerRow.height - width: parent.width - - Row { - id: providerRow - - spacing: Constants.component_spacing - - ProviderInfoSection { - id: purposeInfo + height: purposeInfo.height + anchors.left: parent.left + anchors.right: parent.right - activeFocusOnTab: true + ProviderInfoSection { + id: purposeInfo - image: "qrc:///images/provider/purpose.svg" - //: LABEL DESKTOP_QML - title: qsTr("Purpose for reading out requested data") + SettingsModel.translationTrigger - name: certificateDescriptionModel.purpose - } - - ProviderInfoSection { - id: providerInfo - - activeFocusOnTab: true + anchors.left: parent.left + anchors.right: confirmButton.left + anchors.rightMargin: Constants.component_spacing + activeFocusOnTab: true - image: "qrc:///images/provider/information.svg" - //: LABEL DESKTOP_QML - title: qsTr("Service provider") + SettingsModel.translationTrigger - name: certificateDescriptionModel.subjectName - } + image: "qrc:///images/provider/purpose.svg" + //: LABEL DESKTOP_QML + title: qsTr("Purpose for reading out requested data") + SettingsModel.translationTrigger + name: certificateDescriptionModel.purpose } GButton { - id: moreButton + id: confirmButton anchors.right: parent.right anchors.bottom: parent.bottom activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("more...") + SettingsModel.translationTrigger - onClicked: showProviderInformation(true) + Accessible.name: confirmButton.text + + icon.source: "qrc:///images/npa.svg" + //: LABEL DESKTOP_QML %1 can be "card access number (CAN)" or "PIN" + text: qsTr("Proceed to %1 entry").arg( + NumberModel.isCanAllowedMode ? + //: LABEL DESKTOP_QML Inserted into "Proceed to %1 entry" + qsTr("card access number (CAN)") : + //: LABEL DESKTOP_QML Inserted into "Proceed to %1 entry" + qsTr("PIN") + ) + SettingsModel.translationTrigger + onClicked: { + chatModel.transferAccessRights() + AuthModel.continueWorkflow() + } } } } @@ -172,16 +183,13 @@ SectionPage { anchors.margins: Constants.pane_padding activeFocusOnTab: true - Accessible.role: Accessible.Heading Accessible.name: dataIntroduction.text //: LABEL DESKTOP_QML - text: qsTr("The following data will be transferred to the service provider when you enter the PIN:") + SettingsModel.translationTrigger + text: qsTr("The following data will be transferred to the provider when you enter the PIN:") + SettingsModel.translationTrigger textStyle: Style.text.normal_inverse - FocusFrame { - dynamic: false - } + FocusFrame {} } Pane { @@ -203,7 +211,6 @@ SectionPage { width: parent.width activeFocusOnTab: true - Accessible.role: Accessible.Section Accessible.name: transactionHeading.text //: LABEL DESKTOP_QML @@ -211,8 +218,7 @@ SectionPage { textStyle: Style.text.header_accent FocusFrame { - border.color: Constants.black - dynamic: false + borderColor: Style.color.focus_indicator } } @@ -222,15 +228,13 @@ SectionPage { width: parent.width activeFocusOnTab: true - Accessible.role: Accessible.Paragraph Accessible.name: transactionText.text text: AuthModel.transactionInfo - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal FocusFrame { - border.color: Constants.black - dynamic: false + borderColor: Style.color.focus_indicator } } } @@ -264,23 +268,6 @@ SectionPage { chat: chatModel.optional } } - - GButton { - id: confirmButton - - anchors.right: parent.right - - activeFocusOnTab: true - Accessible.name: confirmButton.text - - icon.source: "qrc:///images/npa.svg" - //: LABEL DESKTOP_QML %1 can be CAN or PIN - text: qsTr("Proceed to %1 entry").arg(NumberModel.isCanAllowedMode ? "CAN" : "PIN") + SettingsModel.translationTrigger - onClicked: { - chatModel.transferAccessRights() - AuthModel.continueWorkflow() - } - } } } diff --git a/resources/qml/Governikus/IdentifyView/+desktop/IdentifyController.qml b/resources/qml/Governikus/IdentifyView/+desktop/IdentifyController.qml index 2872610ce..af9a75b77 100644 --- a/resources/qml/Governikus/IdentifyView/+desktop/IdentifyController.qml +++ b/resources/qml/Governikus/IdentifyView/+desktop/IdentifyController.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -8,7 +8,7 @@ import Governikus.View 1.0 import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.AuthModel 1.0 import Governikus.Type.NumberModel 1.0 -import Governikus.Type.CardReturnCode 1.0 +import Governikus.Type.SettingsModel 1.0 Controller { enum WorkflowStates { @@ -29,13 +29,21 @@ Controller { states: [ State { - when: AuthModel.currentState === "StateGetTcToken" && !connectivityManager.networkInterfaceActive + when: AuthModel.currentState === "StateGetTcToken" && SettingsModel.transportPinReminder + StateChangeScript { + script: controller.nextView(IdentifyView.SubViews.TransportPinReminder) + } + }, + State { + // "State when" seems weired with Qt 5.14, so add !SettingsModel.transportPinReminder + when: AuthModel.currentState === "StateGetTcToken" && !connectivityManager.networkInterfaceActive && !SettingsModel.transportPinReminder StateChangeScript { script: controller.nextView(IdentifyView.SubViews.Connectivity) } }, State { - when: AuthModel.currentState === "StateGetTcToken" && connectivityManager.networkInterfaceActive + // "State when" seems weired with Qt 5.14, so add !SettingsModel.transportPinReminder + when: AuthModel.currentState === "StateGetTcToken" && connectivityManager.networkInterfaceActive && !SettingsModel.transportPinReminder StateChangeScript { script: { controller.nextView(IdentifyView.SubViews.Progress) @@ -54,11 +62,16 @@ Controller { // working, when we need to process a state a second time. } - function showRemoveCardFeedback() { + function showRemoveCardFeedback(success) { if (controller.connectedToCard) { controller.connectedToCard = false - //: INFO DESKTOP_QML The authentication process is completed, the id card may be removed from the card reader. - ApplicationModel.showFeedback(qsTr("You may now remove your ID card from the device.")) + if (success) { + //: INFO DESKTOP_QML The authentication process finished successfully, the ID card may be removed from the card reader. + ApplicationModel.showFeedback(qsTr("Process finished successfully. You may now remove your ID card from the device.")) + } else { + //: INFO DESKTOP_QML The authentication process is completed, the ID card may be removed from the card reader. + ApplicationModel.showFeedback(qsTr("You may now remove your ID card from the device.")) + } } } @@ -95,9 +108,12 @@ Controller { controller.nextView(IdentifyView.SubViews.CardPosition) break case "StateSendDIDAuthenticateResponseEAC1": - controller.nextView(IdentifyView.SubViews.Progress) - if (NumberModel.inputErrorCode == CardReturnCode.OK) { + if (AuthModel.isCancellationByUser()) { + controller.nextView(IdentifyView.SubViews.Aborting) + } + else { controller.workflowProgressVisible = true + controller.nextView(IdentifyView.SubViews.Progress) } setIdentifyWorkflowStateAndContinue(IdentifyController.WorkflowStates.Processing) break @@ -106,7 +122,7 @@ Controller { AuthModel.continueWorkflow() break; case "StateWriteHistory": - showRemoveCardFeedback() + showRemoveCardFeedback(true) AuthModel.continueWorkflow() break case "FinalState": @@ -115,7 +131,7 @@ Controller { controller.nextView(IdentifyView.SubViews.ReturnToMain) AuthModel.continueWorkflow() } else { - showRemoveCardFeedback() + showRemoveCardFeedback(false) controller.nextView(IdentifyView.SubViews.Result) } } else if (ApplicationModel.currentWorkflow === "selfauthentication") { diff --git a/resources/qml/Governikus/IdentifyView/+desktop/IdentifyView.qml b/resources/qml/Governikus/IdentifyView/+desktop/IdentifyView.qml index 7ae316535..77c093a18 100644 --- a/resources/qml/Governikus/IdentifyView/+desktop/IdentifyView.qml +++ b/resources/qml/Governikus/IdentifyView/+desktop/IdentifyView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -19,7 +19,6 @@ import Governikus.Type.SettingsModel 1.0 import Governikus.Type.ChangePinModel 1.0 import Governikus.Type.AuthModel 1.0 import Governikus.Type.NumberModel 1.0 -import Governikus.Type.CardReturnCode 1.0 SectionPage @@ -28,6 +27,7 @@ SectionPage enum SubViews { Undefined, + TransportPinReminder, Connectivity, Progress, AccessRights, @@ -40,7 +40,14 @@ SectionPage Data, Result, ReturnToMain, - ReaderSettings + ReaderSettings, + Aborting + } + + function showSettings() { + readerView.precedingView = d.activeView + d.view = IdentifyView.SubViews.ReaderSettings + ApplicationWindow.menuBar.updateActions() } activeFocusOnTab: true @@ -50,7 +57,7 @@ SectionPage //: LABEL DESKTOP_QML text: qsTr("Identify") + SettingsModel.translationTrigger rootEnabled: false - helpTopic: "ausweisenPage" + helpTopic: "authentication" showSettings: (identifyController.workflowState === IdentifyController.WorkflowStates.Initial || identifyController.workflowState === IdentifyController.WorkflowStates.Reader || identifyController.workflowState === IdentifyController.WorkflowStates.Card) @@ -63,7 +70,7 @@ SectionPage ApplicationWindow.menuBar.updateActions() } else if (d.activeView === IdentifyView.SubViews.ReaderSettings) { - d.view = readerView.preceedingView + d.view = readerView.precedingView ApplicationWindow.menuBar.updateActions() } } @@ -81,11 +88,7 @@ SectionPage } } - customSettingsHandler: function(){ - readerView.preceedingView = d.activeView - d.view = IdentifyView.SubViews.ReaderSettings - ApplicationWindow.menuBar.updateActions() - } + customSettingsHandler: identifyView.showSettings } QtObject { @@ -99,11 +102,11 @@ SectionPage TabbedReaderView { id: readerView - property int preceedingView: IdentifyView.SubViews.Undefined + property int precedingView: IdentifyView.SubViews.Undefined visible: d.activeView === IdentifyView.SubViews.ReaderSettings onCloseView: { - d.view = preceedingView + d.view = precedingView ApplicationWindow.menuBar.updateActions() } } @@ -121,6 +124,22 @@ SectionPage } } + BinaryDecisionView { + visible: d.activeView === IdentifyView.SubViews.TransportPinReminder + + questionText: qsTr("Did you change the transport PIN already?") + SettingsModel.translationTrigger + questionSubText: qsTr("Prior to the first use of the online identification function you have to replace the transport PIN by an individual 6-digit PIN. Online identification with transport PIN is not possible.") + SettingsModel.translationTrigger + disagreeText: qsTr("No, change transport PIN now") + SettingsModel.translationTrigger + + onDisagree: { + SettingsModel.transportPinReminder = false + NumberModel.requestTransportPin = true + ChangePinModel.startWorkflow() + AuthModel.cancelWorkflowToChangePin() + } + onAgree: SettingsModel.transportPinReminder = false // causes fall-through to next state in IdentifyController + } + ProgressView { id: checkConnectivityView @@ -129,7 +148,7 @@ SectionPage //: INFO DESKTOP_QML Header of the message that no network connection is present during the authentication procedure. text: qsTr("No network connectivity") + SettingsModel.translationTrigger //: INFO DESKTOP_QML Content of the message that no network connection is present during the authentication procedure. - subText: qsTr("Please enable the network interface or cancel the workflow.") + SettingsModel.translationTrigger + subText: qsTr("Please establish an internet connection.") + SettingsModel.translationTrigger subTextColor: Constants.red } @@ -155,6 +174,7 @@ SectionPage default: return Workflow.WaitingFor.None } + onSettingsRequested: identifyView.showSettings() } EnterPasswordView { @@ -198,7 +218,7 @@ SectionPage //: LABEL DESKTOP_QML text: qsTr("Transport PIN") + SettingsModel.translationTrigger rootEnabled: false - helpTopic: "pinTab" + helpTopic: "pinEntry" customSubAction: CancelAction { onClicked: { d.view = IdentifyView.SubViews.Password @@ -208,7 +228,7 @@ SectionPage } resultType: ResultView.Type.IsInfo //: INFO DESKTOP_QML The user clicked that the current PIN has 5 digits (transport PIN) which needs to be changed to a 6-digit PIN. The current process will be aborted and needs to be restarted *manually* by the user. - text: qsTr("You have to change your transport PIN into a personal PIN to use the online ID function. You are currently leaving the started process and are forwarded to the PIN management. Please restart the desired process after the PIN has been changed.") + SettingsModel.translationTrigger + text: qsTr("First you have to change your 5-digit transport PIN you received in your in PIN letter into a 6-digit PIN. You are currently leaving the started process and are forwarded to the PIN management. Please restart the desired process after the PIN has been changed.") + SettingsModel.translationTrigger onNextView: { ChangePinModel.startWorkflow() AuthModel.cancelWorkflowToChangePin() @@ -239,10 +259,28 @@ SectionPage resultType: ResultView.Type.IsInfo //: INFO DESKTOP_QML A weak NFC signal was detected since the card communication was aborted. The card's position needs to be adjusted to hopefully achieve better signal strength. - text: qsTr("Weak NFC signal.\nPlease reposition your card.") + SettingsModel.translationTrigger + text: qsTr("Weak NFC signal. Please\n- change the card position\n- remove the mobile phone case (if present)\n- connect the smartphone with a charging cable") + SettingsModel.translationTrigger onNextView: AuthModel.continueWorkflow() } + ProgressView { + visible: d.activeView === IdentifyView.SubViews.Aborting + + //: INFO DESKTOP_QML The user aborted the authentication process, according to TR we need to inform the service provider + text: qsTr("Aborting process and informing the service provider") + SettingsModel.translationTrigger + subText: { + SettingsModel.translationTrigger + if (connectivityManager.networkInterfaceActive) { + //: INFO DESKTOP_QML Information message about cancellation process with present network connectivity + return qsTr("Please wait a moment...") + } + //: INFO DESKTOP_QML Information message about cancellation process without working network connectivity + return qsTr("Network problemes detected, trying to reach server within 30 seconds.") + } + progressBarVisible: false + subTextColor: !connectivityManager.networkInterfaceActive ? Style.color.warning_text : Style.color.secondary_text_inverse + } + ProgressView { id: identifyProgressView @@ -250,28 +288,36 @@ SectionPage visible: d.activeView === IdentifyView.SubViews.Progress - //: INFO DESKTOP_QML Header of the progress information during the authentication process. - text: (inProgress ? qsTr("Authentication in progress") : qsTr("Acquiring provider certificate")) + SettingsModel.translationTrigger + text: (inProgress ? + //: INFO DESKTOP_QML Header of the progress information during the authentication process. + qsTr("Authentication in progress") : + //: INFO DESKTOP_QML Header of the progress information during the authentication process. + qsTr("Acquiring provider certificate") + ) + SettingsModel.translationTrigger subText: { SettingsModel.translationTrigger; if (!visible) { return "" } + if (!inProgress || AuthModel.error) { + //: INFO DESKTOP_QML Generic progress status message while no card communication is active. + return qsTr("Please wait a moment...") + } if (AuthModel.isBasicReader) { //: INFO DESKTOP_QML Second line text if a basic card reader is used and data is exchanged with the card/server in the background. Is not actually visible since the basic reader password handling is done by EnterPasswordView. - return qsTr("Please wait a moment...") + return qsTr("Please don't move the ID card...") } if (!!NumberModel.inputError) { return NumberModel.inputError } if (NumberModel.pinDeactivated) { - //: INFO DESKTOP_QML The online authentication feature of the id card is deactivated and needs to be activated by the local authorities. - return qsTr("The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function.") + //: INFO DESKTOP_QML The online authentication feature of the ID card is deactivated and needs to be activated by the local authorities. + return qsTr("The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function.") } //: INFO DESKTOP_QML Generic progress status message during authentication. return qsTr("Please wait a moment...") } - subTextColor: !AuthModel.isBasicReader && (NumberModel.inputError || NumberModel.pinDeactivated) ? Style.color.warning_text : Style.color.secondary_text + subTextColor: !AuthModel.isBasicReader && (NumberModel.inputError || NumberModel.pinDeactivated) ? Style.color.warning_text : Style.color.secondary_text_inverse progressValue: AuthModel.progressValue progressText: AuthModel.progressMessage progressBarVisible: identifyController.workflowProgressVisible @@ -298,7 +344,7 @@ SectionPage identifyView.nextView(pName) AuthModel.continueWorkflow() } - emailButtonVisible: AuthModel.resultString + emailButtonVisible: AuthModel.error && !AuthModel.isCancellationByUser() onEmailButtonPressed: AuthModel.sendResultMail() } } diff --git a/resources/qml/Governikus/IdentifyView/+desktop/SelfAuthenticationData.qml b/resources/qml/Governikus/IdentifyView/+desktop/SelfAuthenticationData.qml index 990b75f93..ae00fdecd 100644 --- a/resources/qml/Governikus/IdentifyView/+desktop/SelfAuthenticationData.qml +++ b/resources/qml/Governikus/IdentifyView/+desktop/SelfAuthenticationData.qml @@ -1,9 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -19,100 +20,123 @@ SectionPage { id: baseItem - Accessible.name: qsTr("Self-authentication data view") + SettingsModel.translationTrigger - Accessible.description: qsTr("This is the self-authentication data view of the AusweisApp2.") + SettingsModel.translationTrigger + Accessible.name: qsTr("Self-Authentication result data view") + SettingsModel.translationTrigger + Accessible.description: qsTr("This is the self-authentication result data view of the AusweisApp2.") + SettingsModel.translationTrigger Keys.onReturnPressed: okButton.onClicked() Keys.onEnterPressed: okButton.onClicked() Keys.onEscapePressed: okButton.onClicked() titleBarAction: TitleBarAction { - //: LABEL DESKTOP_QML - text: qsTr("Read data") + //: LABEL DESKTOP_QML Title of the self authentication result data view + text: qsTr("Read self-authentication data") + SettingsModel.translationTrigger rootEnabled: false showHelp: false } - Row { - id: statusRow + ColumnLayout { + anchors.fill: parent + anchors.margins: Constants.pane_padding - height: parent.height / 4 - anchors.top: parent.top - anchors.topMargin: Constants.component_spacing - anchors.horizontalCenter: parent.horizontalCenter + Row { + id: statusRow - spacing: Constants.component_spacing + Layout.preferredHeight: baseItem.height / 4 + Layout.alignment: Qt.AlignHCenter - StatusIcon { - height: Style.dimens.status_icon_medium - anchors.verticalCenter: parent.verticalCenter + spacing: Constants.component_spacing - source: "qrc:///images/status_ok.svg" - } + StatusIcon { + height: Style.dimens.status_icon_medium + anchors.verticalCenter: parent.verticalCenter + + source: "qrc:///images/status_ok.svg" + } - GText { - id: successText + GText { + id: successText - anchors.verticalCenter: parent.verticalCenter + anchors.verticalCenter: parent.verticalCenter - activeFocusOnTab: true - Accessible.name: successText.text + activeFocusOnTab: true + Accessible.name: successText.text - //: INFO DESKTOP_QML Status message that the self authentication successfully completed. - text: qsTr("Successfully read data") + SettingsModel.translationTrigger - textStyle: Style.text.header + //: INFO DESKTOP_QML Status message that the self authentication successfully completed. + text: qsTr("Successfully read data") + SettingsModel.translationTrigger + textStyle: Style.text.header_inverse - FocusFrame {} + FocusFrame {} + } } - } - Pane { - id: pane + Item { + Layout.fillWidth: true + Layout.fillHeight: true - anchors.top: statusRow.bottom - anchors.left: parent.left - anchors.right: parent.right - anchors.margins: Constants.pane_padding + ScrollablePane { + id: pane + + width: parent.width + height: Math.min(parent.height, implicitHeight) - activeFocusOnTab: true + activeFocusOnTab: true - //: LABEL DESKTOP_QML - title: qsTr("Read data") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML Title of the self authentication result data view + title: qsTr("Read data") + SettingsModel.translationTrigger - Grid { - id: grid + Grid { + id: grid - width: parent.width + width: parent.width - columns: 3 - spacing: Constants.groupbox_spacing - verticalItemAlignment: Grid.AlignTop + columns: 3 + spacing: Constants.groupbox_spacing + verticalItemAlignment: Grid.AlignTop - Repeater { - id: dataRepeater - model: SelfAuthModel + Repeater { + id: dataRepeater + model: SelfAuthModel - LabeledText { - width: (pane.width - 2 * Constants.pane_padding - (grid.columns - 1) * grid.spacing) / grid.columns + LabeledText { + width: (pane.width - 2 * Constants.pane_padding - (grid.columns - 1) * grid.spacing) / grid.columns - activeFocusOnTab: true + activeFocusOnTab: true - label: name - text: value === "" ? "---" : value + label: name + text: value === "" ? "---" : value + } + } } - } - } - GButton { - id: okButton + RowLayout { + + anchors.right: parent.right + spacing: Constants.component_spacing + + GButton { + id: saveDataToPdfButton - anchors.right: parent.right + icon.source: "qrc:///images/icon_save.svg" + //: LABEL DESKTOP_QML + text: qsTr("Save as PDF...") + SettingsModel.translationTrigger + tintIcon: true + onClicked: { + let now = new Date().toLocaleDateString(Qt.locale(), "yyyy-MM-dd") + let filenameSuggestion = "%1.%2.%3.pdf".arg(Qt.application.name).arg(qsTr("Information")).arg(now) + appWindow.openSaveFileDialog(SelfAuthModel.exportData, filenameSuggestion, "pdf") + } + } - activeFocusOnTab: true - Accessible.name: okButton.text + GButton { + id: okButton - //: LABEL DESKTOP_QML - text: qsTr("OK") + SettingsModel.translationTrigger - onClicked: baseItem.nextView(SectionPage.Views.Main) + //: LABEL DESKTOP_QML + text: qsTr("OK") + SettingsModel.translationTrigger + onClicked: baseItem.nextView(SectionPage.Views.Main) + } + + } + + } } } } diff --git a/resources/qml/Governikus/IdentifyView/+mobile/+android/+phone/EditRights.qml b/resources/qml/Governikus/IdentifyView/+mobile/+android/+phone/EditRights.qml index da2ee631e..b1ba06cd0 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/+android/+phone/EditRights.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/+android/+phone/EditRights.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -36,7 +36,7 @@ SectionPage { GText { width: parent.width //: LABEL ANDROID_PHONE - text: qsTr("You are about to identify yourself towards the following service provider:") + SettingsModel.translationTrigger + text: qsTr("You are about to identify yourself towards the following provider:") + SettingsModel.translationTrigger } Pane { @@ -55,7 +55,7 @@ SectionPage { ProviderInfoSection { imageSource: "qrc:///images/provider/information.svg" //: LABEL ANDROID_PHONE - title: qsTr("Service provider") + SettingsModel.translationTrigger + title: qsTr("Provider") + SettingsModel.translationTrigger name: certificateDescriptionModel.subjectName } ProviderInfoSection { @@ -96,10 +96,16 @@ SectionPage { } GButton { - iconSource: "qrc:///images/npa.svg" + icon.source: "qrc:///images/npa.svg" anchors.horizontalCenter: parent.horizontalCenter - //: LABEL ANDROID_PHONE %1 can be CAN or PIN - text: qsTr("Proceed to %1 entry").arg(NumberModel.isCanAllowedMode ? "CAN" : "PIN") + SettingsModel.translationTrigger + //: LABEL ANDROID_PHONE %1 can be "card access number (CAN)" or "PIN" + text: qsTr("Proceed to %1 entry").arg( + NumberModel.isCanAllowedMode ? + //: LABEL ANDROID_PHONE Inserted into "Proceed to %1 entry" + qsTr("card access number (CAN)") : + //: LABEL ANDROID_PHONE Inserted into "Proceed to %1 entry" + qsTr("PIN") + ) + SettingsModel.translationTrigger onClicked: { chatModel.transferAccessRights() AuthModel.continueWorkflow() @@ -110,7 +116,7 @@ SectionPage { width: parent.width //: LABEL ANDROID_PHONE - text: qsTr("The following data will be transferred to the service provider when you enter the PIN:") + SettingsModel.translationTrigger + text: qsTr("The following data will be transferred to the provider when you enter the PIN:") + SettingsModel.translationTrigger } Pane { @@ -135,7 +141,6 @@ SectionPage { width: parent.width text: AuthModel.transactionInfo - textStyle: Style.text.normal } } diff --git a/resources/qml/Governikus/IdentifyView/+mobile/+android/+tablet/EditRights.qml b/resources/qml/Governikus/IdentifyView/+mobile/+android/+tablet/EditRights.qml index 2aea769ca..3882facbf 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/+android/+tablet/EditRights.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/+android/+tablet/EditRights.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -36,7 +36,7 @@ SectionPage { width: parent.width //: LABEL ANDROID_TABLET - text: qsTr("You are about to identify yourself towards the following service provider:") + SettingsModel.translationTrigger + text: qsTr("You are about to identify yourself towards the following provider:") + SettingsModel.translationTrigger } Pane { @@ -60,7 +60,7 @@ SectionPage { ProviderInfoSection { imageSource: "qrc:///images/provider/information.svg" //: LABEL ANDROID_TABLET - title: qsTr("Service provider") + SettingsModel.translationTrigger + title: qsTr("Provider") + SettingsModel.translationTrigger name: certificateDescriptionModel.subjectName } ProviderInfoSection { @@ -90,11 +90,17 @@ SectionPage { GButton { id: button - iconSource: "qrc:///images/npa.svg" + icon.source: "qrc:///images/npa.svg" anchors.horizontalCenter: parent.horizontalCenter anchors.verticalCenter: parent.verticalCenter - //: LABEL ANDROID_TABLET %1 can be CAN or PIN - text: qsTr("Proceed to %1 entry").arg(NumberModel.isCanAllowedMode ? "CAN" : "PIN") + SettingsModel.translationTrigger + //: LABEL ANDROID_TABLET %1 can be "card access number (CAN)" or "PIN" + text: qsTr("Proceed to %1 entry").arg( + NumberModel.isCanAllowedMode ? + //: LABEL ANDROID_TABLET Inserted into "Proceed to %1 entry" + qsTr("card access number (CAN)") : + //: LABEL ANDROID_TABLET Inserted into "Proceed to %1 entry" + qsTr("PIN") + ) + SettingsModel.translationTrigger onClicked: { chatModel.transferAccessRights() AuthModel.continueWorkflow() @@ -108,7 +114,7 @@ SectionPage { width: parent.width //: LABEL ANDROID_TABLET - text: qsTr("The following data will be transferred to the service provider when you enter the PIN:") + SettingsModel.translationTrigger + text: qsTr("The following data will be transferred to the provider when you enter the PIN:") + SettingsModel.translationTrigger } Pane { diff --git a/resources/qml/Governikus/IdentifyView/+mobile/+android/DataGroup.qml b/resources/qml/Governikus/IdentifyView/+mobile/+android/DataGroup.qml index 35e9649c8..36f721ec6 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/+android/DataGroup.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/+android/DataGroup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -10,7 +10,7 @@ import Governikus.Style 1.0 import Governikus.Type.SettingsModel 1.0 -Rectangle { +Item { id: root property string title; property int columns: 1 @@ -32,7 +32,7 @@ Rectangle { text: title } - Rectangle { + Item { width: parent.width height: 40 visible: repeater.count < 1 @@ -65,10 +65,9 @@ Rectangle { model: chat visible: repeater.count > 0 - Rectangle { + Item { width: (grid.width - ((grid.columns - 1) * grid.columnSpacing)) / grid.columns height: 40 - color: Constants.white GText { id: text @@ -78,7 +77,7 @@ Rectangle { anchors.right: checkBox.left text: name - textStyle: Style.text.normal_secondary + textStyle: writeRight ? Style.text.normal_warning : Style.text.normal_secondary } GSeparator { diff --git a/resources/qml/Governikus/IdentifyView/+mobile/+ios/+phone/DataGroup.qml b/resources/qml/Governikus/IdentifyView/+mobile/+ios/+phone/DataGroup.qml index 17d16f35a..14708e308 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/+ios/+phone/DataGroup.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/+ios/+phone/DataGroup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -24,7 +24,7 @@ Pane { Repeater { id: repeater - Rectangle { + Item { width: parent.width height: 40 @@ -36,9 +36,6 @@ Pane { Accessible.onScrollDownAction: baseItem.scrollPageDown() Accessible.onScrollUpAction: baseItem.scrollPageUp() - radius: 3 - color: Constants.white - GText { id: dataGroup @@ -50,7 +47,7 @@ Pane { Accessible.ignored: true text: name - textStyle: Style.text.normal_secondary + textStyle: writeRight ? Style.text.normal_warning : Style.text.normal_secondary } GSeparator { anchors.top: parent.bottom diff --git a/resources/qml/Governikus/IdentifyView/+mobile/+ios/+phone/EditRights.qml b/resources/qml/Governikus/IdentifyView/+mobile/+ios/+phone/EditRights.qml index 632cc1a83..4df239d11 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/+ios/+phone/EditRights.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/+ios/+phone/EditRights.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -38,7 +38,7 @@ SectionPage { width: parent.width //: LABEL IOS_PHONE - text: qsTr("You are about to identify yourself towards the following service provider:") + SettingsModel.translationTrigger + text: qsTr("You are about to identify yourself towards the following provider:") + SettingsModel.translationTrigger textStyle: Style.text.normal_secondary } @@ -48,7 +48,7 @@ SectionPage { width: parent.width height: providerEntries.height - Accessible.description: qsTr("Click for more information about the service provider") + SettingsModel.translationTrigger + Accessible.description: qsTr("Click for more information about the provider") + SettingsModel.translationTrigger Accessible.onPressAction: mouseArea.clicked(null) Column { @@ -61,7 +61,7 @@ SectionPage { ProviderInfoSection { imageSource: "qrc:///images/provider/information.svg" //: LABEL IOS_PHONE - title: qsTr("Service provider") + SettingsModel.translationTrigger + title: qsTr("Provider") + SettingsModel.translationTrigger name: certificateDescriptionModel.subjectName } ProviderInfoSection { @@ -105,10 +105,16 @@ SectionPage { } GButton { - iconSource: "qrc:///images/npa.svg" + icon.source: "qrc:///images/npa.svg" anchors.horizontalCenter: parent.horizontalCenter - //: LABEL IOS_PHONE %1 can be CAN or PIN - text: qsTr("Proceed to %1 entry").arg(NumberModel.isCanAllowedMode ? "CAN" : "PIN") + SettingsModel.translationTrigger + //: LABEL IOS_PHONE %1 can be "card access number (CAN)" or "PIN" + text: qsTr("Proceed to %1 entry").arg( + NumberModel.isCanAllowedMode ? + //: LABEL IOS_PHONE Inserted into "Proceed to %1 entry" + qsTr("card access number (CAN)") : + //: LABEL IOS_PHONE Inserted into "Proceed to %1 entry" + qsTr("PIN") + ) + SettingsModel.translationTrigger onClicked: { chatModel.transferAccessRights() AuthModel.continueWorkflow() @@ -119,7 +125,7 @@ SectionPage { width: parent.width //: LABEL IOS_PHONE - text: qsTr("The following data will be transferred to the service provider when you enter the PIN:") + SettingsModel.translationTrigger + text: qsTr("The following data will be transferred to the provider when you enter the PIN:") + SettingsModel.translationTrigger textStyle: Style.text.normal_secondary } diff --git a/resources/qml/Governikus/IdentifyView/+mobile/+ios/+tablet/DataGroup.qml b/resources/qml/Governikus/IdentifyView/+mobile/+ios/+tablet/DataGroup.qml index 44d5211a5..f4dba81d4 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/+ios/+tablet/DataGroup.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/+ios/+tablet/DataGroup.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -85,7 +85,7 @@ Rectangle { anchors.right: checkBox.left text: name - textStyle: Style.text.normal_secondary + textStyle: writeRight ? Style.text.normal_warning : Style.text.normal_secondary } GSeparator { diff --git a/resources/qml/Governikus/IdentifyView/+mobile/+ios/+tablet/EditRights.qml b/resources/qml/Governikus/IdentifyView/+mobile/+ios/+tablet/EditRights.qml index 7eb8e69ed..30f7771aa 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/+ios/+tablet/EditRights.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/+ios/+tablet/EditRights.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -37,7 +37,7 @@ SectionPage { width: parent.width //: LABEL IOS_TABLET - text: qsTr("You are about to identify yourself towards the following service provider:") + SettingsModel.translationTrigger + text: qsTr("You are about to identify yourself towards the following provider:") + SettingsModel.translationTrigger } Pane { @@ -46,7 +46,7 @@ SectionPage { width: parent.width height: providerEntries.height - Accessible.description: qsTr("Click for more information about the service provider") + SettingsModel.translationTrigger + Accessible.description: qsTr("Click for more information about the provider") + SettingsModel.translationTrigger Accessible.onPressAction: mouseArea.clicked(null) Column { @@ -59,7 +59,7 @@ SectionPage { ProviderInfoSection { imageSource: "qrc:///images/provider/information.svg" //: LABEL IOS_TABLET - title: qsTr("Service provider") + SettingsModel.translationTrigger + title: qsTr("Provider") + SettingsModel.translationTrigger name: certificateDescriptionModel.subjectName } ProviderInfoSection { @@ -103,10 +103,16 @@ SectionPage { } GButton { - iconSource: "qrc:///images/npa.svg" + icon.source: "qrc:///images/npa.svg" anchors.horizontalCenter: parent.horizontalCenter - //: LABEL IOS_TABLET %1 can be CAN or PIN - text: qsTr("Proceed to %1 entry").arg(NumberModel.isCanAllowedMode ? "CAN" : "PIN") + SettingsModel.translationTrigger + //: LABEL IOS_TABLET %1 can be "card access number (CAN)" or "PIN" + text: qsTr("Proceed to %1 entry").arg( + NumberModel.isCanAllowedMode ? + //: LABEL IOS_TABLET Inserted into "Proceed to %1 entry" + qsTr("card access number (CAN)") : + //: LABEL IOS_TABLET Inserted into "Proceed to %1 entry" + qsTr("PIN") + ) + SettingsModel.translationTrigger onClicked: { chatModel.transferAccessRights() AuthModel.continueWorkflow() @@ -117,7 +123,7 @@ SectionPage { width: parent.width //: LABEL IOS_TABLET - text: qsTr("The following data will be transferred to the service provider when you enter the PIN:") + SettingsModel.translationTrigger + text: qsTr("The following data will be transferred to the provider when you enter the PIN:") + SettingsModel.translationTrigger } Pane { diff --git a/resources/qml/Governikus/IdentifyView/+mobile/CertificateDescriptionPage.qml b/resources/qml/Governikus/IdentifyView/+mobile/CertificateDescriptionPage.qml index 8db3d80e9..d2bd67894 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/CertificateDescriptionPage.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/CertificateDescriptionPage.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/IdentifyView/+mobile/IdentifyController.qml b/resources/qml/Governikus/IdentifyView/+mobile/IdentifyController.qml index b75992d6b..c0ca10dff 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/IdentifyController.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/IdentifyController.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -19,6 +19,7 @@ Item { Update, Can, Pin, + Puk, Processing } @@ -89,7 +90,7 @@ Item { // happens with both the iOS toasts and our own toast-like replacement. To work around this, we'll only show the notification during a // self-authentication on iOS with VoiceOver running: if (Qt.platform.os !== "ios" || !ApplicationModel.isScreenReaderRunning() || ApplicationModel.currentWorkflow === "selfauthentication") { - //: INFO ANDROID IOS The authentication process is completed, the id card may (and should) be removed from the card reader. + //: INFO ANDROID IOS The authentication process is completed, the ID card may (and should) be removed from the card reader. ApplicationModel.showFeedback(qsTr("You may now remove your ID card from the device.")) } } @@ -98,6 +99,7 @@ Item { function processStateChange() { switch (AuthModel.currentState) { case "Initial": + firePopAll() break; case "StateGetTcToken": enterPinView.state = "INITIAL" @@ -136,12 +138,12 @@ Item { setIdentifyWorkflowStateAndRequestInput(IdentifyController.WorkflowStates.Can, "CAN") } else if (NumberModel.passwordType === NumberModel.PASSWORD_PUK) { - AuthModel.cancelWorkflowOnPinBlocked() + setIdentifyWorkflowStateAndRequestInput(IdentifyController.WorkflowStates.Puk, "PUK") } break case "StateUnfortunateCardPosition": //: INFO IOS The NFC signal is weak or unstable. The scan is stopped with this information in the iOS dialog. - ApplicationModel.stopNfcScanWithError(qsTr("Weak NFC signal") + SettingsModel.translationTrigger) + ApplicationModel.stopNfcScanWithError(qsTr("Weak NFC signal. Please\n- change the card position\n- remove the mobile phone case (if present)\n- connect the smartphone with a charging cable") + SettingsModel.translationTrigger) firePush(cardPositionView) break case "StateDidAuthenticateEac1": @@ -149,7 +151,12 @@ Item { setIdentifyWorkflowStateAndContinue(IdentifyController.WorkflowStates.Processing) break case "StateSendDIDAuthenticateResponseEAC1": - fireReplace(identifyProgressView) + if (AuthModel.isCancellationByUser()) { + fireReplace(identifyAbortedProgressView) + } + else { + fireReplace(identifyProgressView) + } AuthModel.continueWorkflow() break case "StateCleanUpReaderManager": diff --git a/resources/qml/Governikus/IdentifyView/+mobile/IdentifyView.qml b/resources/qml/Governikus/IdentifyView/+mobile/IdentifyView.qml index aaa4099bd..5d31ea164 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/IdentifyView.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/IdentifyView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -126,16 +126,43 @@ SectionPage } } + ProgressView { + id: identifyAbortedProgressView + + visible: false + + navigationAction: NavigationAction { state: "cancel"; onClicked: AuthModel.cancelWorkflow() } + //: INFO DESKTOP_QML The user aborted the authentication process, according to TR we need to inform the service provider + text: qsTr("Aborting process and informing the service provider") + SettingsModel.translationTrigger + subText: { + SettingsModel.translationTrigger + if (connectivityManager.networkInterfaceActive) { + //: INFO DESKTOP_QML Information message about cancellation process with present network connectivity + return qsTr("Please wait a moment...") + } + //: INFO DESKTOP_QML Information message about cancellation process without working network connectivity + return qsTr("Network problemes detected, trying to reach server within 30 seconds.") + } + progressBarVisible: false + subTextColor: !connectivityManager.networkInterfaceActive ? Style.color.warning_text : Style.color.secondary_text_inverse + } + ProgressView { id: identifyProgressView - navigationAction: NavigationAction { state: AuthModel.isBasicReader || identifyController.workflowProgressVisible ? "cancel" : "hidden"; onClicked: AuthModel.cancelWorkflow() } + + readonly property bool inProgress: identifyController.workflowState !== IdentifyController.WorkflowStates.Initial + + navigationAction: NavigationAction { + state: AuthModel.isBasicReader || identifyController.workflowProgressVisible ? "cancel" : "hidden" + onClicked: if (state !== "hidden") AuthModel.cancelWorkflow() + } //: LABEL ANDROID IOS title: qsTr("Identify") + SettingsModel.translationTrigger visible: false //: LABEL ANDROID IOS text: (AuthModel.error ? qsTr("Cancel authentication process") : //: INFO ANDROID IOS Header of the progress status message during the authentication process. - identifyController.workflowState === IdentifyController.WorkflowStates.Initial ? qsTr("Acquiring provider certificate") : + !inProgress ? qsTr("Acquiring provider certificate") : //: INFO ANDROID IOS Header of the progress status message during the authentication process. qsTr("Authentication in progress")) + SettingsModel.translationTrigger subText: { @@ -143,16 +170,20 @@ SectionPage if (!visible) { return "" } + //: INFO DESKTOP_QML Generic progress status message while no card communication is active. + if (!inProgress || AuthModel.error) { + return qsTr("Please wait a moment...") + } if (AuthModel.isBasicReader) { //: INFO ANDROID IOS Second line text if a basic card reader is used and background communication with the card/server is running. Is not actually visible since the basic reader password handling is done by EnterPasswordView. - return qsTr("Please wait a moment...") + return qsTr("Please don't move the ID card...") } if (!!NumberModel.inputError) { return NumberModel.inputError } if (NumberModel.pinDeactivated) { - //: INFO ANDROID IOS The online authentication feature of the id card is disabled and needs to be actived the be authorities. - return qsTr("The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function.") + //: INFO ANDROID IOS The online authentication feature of the ID card is disabled and needs to be actived the be authorities. + return qsTr("The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function.") } if (identifyController.workflowState === IdentifyController.WorkflowStates.Update || identifyController.workflowState === IdentifyController.WorkflowStates.Pin) { //: INFO ANDROID IOS The card reader requests the user's attention. @@ -160,8 +191,9 @@ SectionPage } if (identifyController.workflowState === IdentifyController.WorkflowStates.Can) { //: INFO ANDROID IOS The PIN was entered wrongfully two times, the third attempts requires additional CAN verification, hint where the CAN is found. - return qsTr("You have entered the wrong PIN twice. Prior to a third attempt, you have to enter your six-digit card access number first. You can find your card access number on the front of your ID card.") + return qsTr("A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card.") } + //: INFO ANDROID IOS Generic status message during the authentication process. return qsTr("Please wait a moment...") } @@ -183,7 +215,7 @@ SectionPage //: LABEL ANDROID IOS text: qsTr("No network connectivity") + SettingsModel.translationTrigger //: INFO ANDROID IOS No network connection, the user needs to active the network interface or abort the procedure. - subText: qsTr("Please enable the network interface or cancel the workflow.") + SettingsModel.translationTrigger + subText: qsTr("Please establish an internet connection.") + SettingsModel.translationTrigger subTextColor: Style.color.warning_text } @@ -195,8 +227,8 @@ SectionPage resultType: ResultView.Type.IsInfo //: LABEL ANDROID IOS buttonText: qsTr("Change PIN") + SettingsModel.translationTrigger - //: INFO ANDROID IOS The user clicked that the current PIN has 5 digits (transport PIN), it needs to be changed to an ordinary 6 digit PIN. The current process needs to be restarted *manually* by the user. - text: qsTr("You have to change your transport PIN into a personal PIN to use the online ID function. You are currently leaving the started process and are forwarded to the PIN management. Please restart the desired process after the PIN has been changed.") + SettingsModel.translationTrigger + //: INFO ANDROID IOS The user clicked that the current PIN has 5 digits (transport PIN), it needs to be changed to an ordinary 6-digit PIN. The current process needs to be restarted *manually* by the user. + text: qsTr("First you have to change your 5-digit transport PIN you received in your in PIN letter into a 6-digit PIN. You are currently leaving the started process and are forwarded to the PIN management. Please restart the desired process after the PIN has been changed.") + SettingsModel.translationTrigger onClicked: { firePop() AuthModel.setSkipRedirect(true) @@ -214,7 +246,7 @@ SectionPage //: LABEL ANDROID IOS buttonText: qsTr("Retry") + SettingsModel.translationTrigger //: INFO ANDROID IOS The NFC signal is weak, by repositioning the card the signal might improve. - text: qsTr("Weak NFC signal. Please reposition your card.") + SettingsModel.translationTrigger + text: qsTr("Weak NFC signal. Please\n- change the card position\n- remove the mobile phone case (if present)\n- connect the smartphone with a charging cable") + SettingsModel.translationTrigger onClicked: { firePop() AuthModel.continueWorkflow() diff --git a/resources/qml/Governikus/IdentifyView/+mobile/SelfAuthenticationData.qml b/resources/qml/Governikus/IdentifyView/+mobile/SelfAuthenticationData.qml index ab786f749..515c9f40d 100644 --- a/resources/qml/Governikus/IdentifyView/+mobile/SelfAuthenticationData.qml +++ b/resources/qml/Governikus/IdentifyView/+mobile/SelfAuthenticationData.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/InformationView/+desktop/DiagnosisView.qml b/resources/qml/Governikus/InformationView/+desktop/DiagnosisView.qml index 53985ff60..cf675b6da 100644 --- a/resources/qml/Governikus/InformationView/+desktop/DiagnosisView.qml +++ b/resources/qml/Governikus/InformationView/+desktop/DiagnosisView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -7,6 +7,7 @@ import QtQuick.Controls 2.3 import Governikus.View 1.0 import Governikus.Global 1.0 +import Governikus.Style 1.0 import Governikus.TitleBar 1.0 import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SelfDiagnosisModel 1.0 @@ -24,6 +25,7 @@ SectionPage { titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML text: qsTr("Diagnosis") + SettingsModel.translationTrigger + helpTopic: "diagnosis" } TabbedPane { @@ -57,7 +59,7 @@ SectionPage { label: title text: content - underlineLabel: title !== "" && content === "" + labelStyle: (title !== "" && content === "") ? Style.text.header_accent : Style.text.normal_accent onActiveFocusChanged: { if (activeFocus) { @@ -81,12 +83,12 @@ SectionPage { GButton { id: saveToFile - Accessible.name: saveToFile.text Accessible.description: qsTr("Save diagnosis to textfile") + SettingsModel.translationTrigger icon.source: "qrc:///images/icon_save.svg" //: LABEL DESKTOP_QML text: qsTr("Save to file") + SettingsModel.translationTrigger + tintIcon: true onClicked: { var filenameSuggestion = "%1.%2.%3.txt".arg(Qt.application.name).arg(qsTr("Diagnosis")).arg(SelfDiagnosisModel.getCreationTimeString()) appWindow.openSaveFileDialog(SelfDiagnosisModel.saveToFile, filenameSuggestion, "txt") diff --git a/resources/qml/Governikus/InformationView/+desktop/InformationView.qml b/resources/qml/Governikus/InformationView/+desktop/InformationView.qml deleted file mode 100644 index 08b120625..000000000 --- a/resources/qml/Governikus/InformationView/+desktop/InformationView.qml +++ /dev/null @@ -1,370 +0,0 @@ -/* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.3 - -import Governikus.FeedbackView 1.0 -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.TitleBar 1.0 -import Governikus.View 1.0 -import Governikus.Type.ApplicationModel 1.0 -import Governikus.Type.SettingsModel 1.0 - - -SectionPage { - id: sectionPage - - enum SubViews { - None, - Diagnosis, - ApplicationLog, - VersionInformation - } - - readonly property int cellHeight: (height - 2 * gridLayout.anchors.margins) / 4 - readonly property int informationViewIconWidth: width / 6 - readonly property int separatorHeight: Math.max(1, ApplicationModel.scaleFactor * 4) - property int activeSubView - - Accessible.name: qsTr("Help section") + SettingsModel.translationTrigger - Accessible.description: qsTr("This is the help section of the AusweisApp2.") + SettingsModel.translationTrigger - Keys.onEscapePressed: { - if (activeSubView === InformationView.SubViews.None) { - event.accepted = false - return - } - - activeSubView = InformationView.SubViews.None - } - - isAbstract: activeSubView !== InformationView.SubViews.None - - titleBarAction: TitleBarAction { - //: LABEL DESKTOP_QML - text: qsTr("Help") + SettingsModel.translationTrigger - onClicked: activeSubView = InformationView.SubViews.None - } - onVisibleChanged: activeSubView = InformationView.SubViews.None - - GridLayout { - id: gridLayout - - readonly property int iconAlignment: Qt.AlignTop | Qt.AlignHCenter - readonly property int longestText: Math.max(textQuestionsFeedbackRating.width, - textSetupManual.width, - textDiagnosisApplicationLog.width, - textVersionAndLicense.width) - - visible: activeSubView === InformationView.SubViews.None - anchors.fill: sectionPage - anchors.margins: Constants.pane_padding - anchors.topMargin: anchors.margins + (sectionPage.cellHeight - iconDiagnosis.implicitHeight) / 2 - - rowSpacing: 0 - columnSpacing: 0 - columns: 4 - rows: 4 - onVisibleChanged: if (visible) sectionPage.setActive() - - Column { - Layout.fillWidth: true - Layout.fillHeight: true - - topPadding: (implicitHeight - textQuestionsFeedbackRating.height - separatorHeight) / 2 - spacing: Constants.component_spacing - - GText { - id: textQuestionsFeedbackRating - - Accessible.name: text - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Questions, feedback, and rating") + SettingsModel.translationTrigger - textStyle: Style.text.header - - FocusFrame {} - } - Rectangle { - height: sectionPage.separatorHeight - width: gridLayout.longestText * 1.2 - - color: Constants.white - opacity: 0.5 - } - } - InformationViewIcon{ - id: iconQuestions - - width: sectionPage.informationViewIconWidth - - Layout.alignment: gridLayout.iconAlignment - Layout.minimumHeight: sectionPage.cellHeight - - activeFocusOnTab: true - - source: "qrc:/images/desktop/info_questions.svg" - //: LABEL DESKTOP_QML - text: qsTr("Questions") + SettingsModel.translationTrigger - onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/")) + SettingsModel.translationTrigger - } - InformationViewIcon { - id: iconReportError - - width: sectionPage.informationViewIconWidth - - Layout.alignment: gridLayout.iconAlignment - Layout.minimumHeight: sectionPage.cellHeight - - activeFocusOnTab: true - - source: "qrc:/images/desktop/info_report_error.svg" - //: LABEL DESKTOP_QML - text: qsTr("Report error") + SettingsModel.translationTrigger - onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/report-an-error/")) + SettingsModel.translationTrigger - } - InformationViewIcon { - id: iconRateApplication - - width: sectionPage.informationViewIconWidth - - Layout.alignment: gridLayout.iconAlignment - Layout.minimumHeight: sectionPage.cellHeight - - activeFocusOnTab: true - - source: "qrc:/images/desktop/info_rate_application.svg" - //: LABEL DESKTOP_QML - text: qsTr("Rate application") + SettingsModel.translationTrigger - onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/evaluate-us/")) + SettingsModel.translationTrigger - } - - Column { - Layout.fillHeight: true - Layout.fillWidth: true - - topPadding: (implicitHeight - textSetupManual.height - separatorHeight) / 2 - spacing: Constants.component_spacing - - GText { - id: textSetupManual - - Accessible.name: text - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Setup and manual") + SettingsModel.translationTrigger - textStyle: Style.text.header - - FocusFrame {} - } - Rectangle { - height: sectionPage.separatorHeight - width: gridLayout.longestText * 1.2 - - color: Constants.white - opacity: 0.5 - } - } - Item { - id: placeHolder1 - - width: 1 - height: 1 - } - InformationViewIcon { - id: iconSetup - - width: sectionPage.informationViewIconWidth - - Layout.alignment: gridLayout.iconAlignment - Layout.minimumHeight: sectionPage.cellHeight - - activeFocusOnTab: true - - source: "qrc:/images/desktop/info_setup.svg" - //: LABEL DESKTOP_QML - text: qsTr("Setup") + SettingsModel.translationTrigger - onClicked: sectionPage.nextView(SectionPage.Views.SetupAssistant) - } - InformationViewIcon { - id: iconManual - - width: sectionPage.informationViewIconWidth - - Layout.minimumHeight: sectionPage.cellHeight - Layout.alignment: gridLayout.iconAlignment - - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Online help") + SettingsModel.translationTrigger - source: "qrc:/images/desktop/info_manual.svg" - onClicked: ApplicationModel.openOnlineHelp("index") - } - - Column { - Layout.fillHeight: true - Layout.fillWidth: true - - topPadding: (implicitHeight - textDiagnosisApplicationLog.height - separatorHeight) / 2 - spacing: Constants.component_spacing - - GText { - id: textDiagnosisApplicationLog - - Accessible.name: text - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Diagnosis and application log") + SettingsModel.translationTrigger - textStyle: Style.text.header - - FocusFrame {} - } - Rectangle { - height: sectionPage.separatorHeight - width: gridLayout.longestText * 1.2 - - color: Constants.white - opacity: 0.5 - } - } - Item { - id: placeHolder2 - - width: 1 - height: 1 - } - InformationViewIcon { - id: iconDiagnosis - - width: sectionPage.informationViewIconWidth - - Layout.alignment: gridLayout.iconAlignment - Layout.minimumHeight: sectionPage.cellHeight - - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Diagnosis") + SettingsModel.translationTrigger - source: "qrc:/images/desktop/info_diagnosis.svg" - onClicked: activeSubView = InformationView.SubViews.Diagnosis - } - InformationViewIcon { - id: iconApplicationLog - - width: sectionPage.informationViewIconWidth - - Layout.alignment: gridLayout.iconAlignment - Layout.minimumHeight: sectionPage.cellHeight - - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Application log") + SettingsModel.translationTrigger - source: "qrc:/images/desktop/info_application_log.svg" - onClicked: activeSubView = InformationView.SubViews.ApplicationLog - } - - Column { - Layout.fillHeight: true - Layout.fillWidth: true - - topPadding: (implicitHeight - textVersionAndLicense.height - separatorHeight) / 2 - spacing: Constants.component_spacing - - GText { - id: textVersionAndLicense - - Accessible.name: text - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Version and license information") + SettingsModel.translationTrigger - textStyle: Style.text.header - - FocusFrame {} - } - Rectangle { - height: sectionPage.separatorHeight - width: gridLayout.longestText * 1.2 - - color: Constants.white - opacity: 0.5 - } - } - Item { - id: placeHolder3 - - width: 1 - height: 1 - } - InformationViewIcon { - id: iconVersionInformation - - width: sectionPage.informationViewIconWidth - - Layout.minimumHeight: sectionPage.cellHeight - Layout.alignment: gridLayout.iconAlignment - - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Version information") + SettingsModel.translationTrigger - source: "qrc:/images/desktop/info_version.svg" - onClicked: activeSubView = InformationView.SubViews.VersionInformation - } - InformationViewIcon { - id: iconLicense - - width: sectionPage.informationViewIconWidth - - Layout.minimumHeight: sectionPage.cellHeight - Layout.alignment: gridLayout.iconAlignment - - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - text: qsTr("Software licenses") + SettingsModel.translationTrigger - source: "qrc:/images/desktop/info_license.svg" - onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/windows-and-mac/")) - } - } - - Component { - id: diagnosisView - - DiagnosisView {} - } - - Component { - id: versionInformation - - VersionInformation {} - } - - Component { - id: logFileView - - LogView {} - } - - Loader { - readonly property bool sectionPageTypeMarker: true - property var titleBarAction: item ? item.titleBarAction : undefined - - visible: item // Otherwise onVisibleChildrenChanged and onVisibleChanged won't be triggered - anchors.fill: parent - - sourceComponent: switch(sectionPage.activeSubView) { - case InformationView.SubViews.Diagnosis: return diagnosisView - case InformationView.SubViews.VersionInformation: return versionInformation - case InformationView.SubViews.ApplicationLog: return logFileView - } - } -} diff --git a/resources/qml/Governikus/InformationView/+desktop/InformationViewIcon.qml b/resources/qml/Governikus/InformationView/+desktop/InformationViewIcon.qml deleted file mode 100644 index efdbeb240..000000000 --- a/resources/qml/Governikus/InformationView/+desktop/InformationViewIcon.qml +++ /dev/null @@ -1,60 +0,0 @@ -/* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Global 1.0 -import Governikus.View 1.0 -import Governikus.Type.ApplicationModel 1.0 -import Governikus.Type.SettingsModel 1.0 - - -FocusScope { - id: root - - property alias source: img.source - property alias text: label.text - property int iconSize: ApplicationModel.scaleFactor * 120 - - signal clicked() - - implicitHeight: label.height + label.anchors.topMargin + img.height - implicitWidth: Math.max(label.width, img.width) - - Accessible.role: Accessible.Button - Accessible.name: text - - Keys.onSpacePressed: root.clicked() - - MouseArea { - anchors.fill: focusFrame - cursorShape: Qt.PointingHandCursor - onPressed: parent.focus = true - onClicked: parent.clicked() - } - - FocusFrame { - id: focusFrame - framee: img - marginFactor: 2.0 - } - - FramedImage { - id: img - width: iconSize - height: iconSize - anchors.top: parent.top - border.color: Constants.white - anchors.horizontalCenter: parent.horizontalCenter - } - - GText { - id: label - width: parent.width - anchors.top: img.bottom - anchors.topMargin: Constants.component_spacing - horizontalAlignment: Text.AlignHCenter - font.bold: true - } -} diff --git a/resources/qml/Governikus/InformationView/+desktop/VersionInformation.qml b/resources/qml/Governikus/InformationView/+desktop/VersionInformation.qml index 0e026f342..8b0b877b9 100644 --- a/resources/qml/Governikus/InformationView/+desktop/VersionInformation.qml +++ b/resources/qml/Governikus/InformationView/+desktop/VersionInformation.qml @@ -1,58 +1,66 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 -import Governikus.TitleBar 1.0 import Governikus.View 1.0 +import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SettingsModel 1.0 +Item { + id: baseItem -SectionPage { - id: root + implicitWidth: column.implicitWidth + implicitHeight: column.implicitHeight - Accessible.name: qsTr("Version information") + SettingsModel.translationTrigger - Accessible.description: qsTr("This is the version information section of the AusweisApp2.") + SettingsModel.translationTrigger + readonly property string helpTopic: "helpVersioninformation" - titleBarAction: TitleBarAction { - //: LABEL DESKTOP_QML - text: qsTr("Version information") + SettingsModel.translationTrigger - } - - ScrollablePane { - id: pane - - anchors.fill: root - anchors.margins: Constants.pane_padding - - //: LABEL DESKTOP_QML - title: qsTr("Version information") + SettingsModel.translationTrigger + ColumnLayout { + id: column - activeFocusOnTab: true + anchors.fill: parent - Column { - id: column + spacing: Constants.component_spacing - spacing: Constants.component_spacing + Repeater { + id: repeater - Repeater { - id: repeater + model: versionInformationModel + delegate: LabeledText { + id: delegate - model: versionInformationModel - delegate: LabeledText { - id: delegate + width: baseItem.width - width: root.width + Accessible.name: model.label + ": " + model.text + activeFocusOnTab: true - Accessible.name: model.label + ": " + model.text - activeFocusOnTab: true + label: model.label + text: model.text + } + } + } - label: model.label - text: model.text - } + MouseArea { + property int counter: 0 + + anchors.fill: parent + + onClicked: { + counter += 1 + if (counter === 10) { + SettingsModel.developerOptions = !SettingsModel.developerOptions + ApplicationModel.showFeedback( + SettingsModel.developerOptions ? + //: LABEL DESKTOP_QML + qsTr("Developer options activated.") : + //: LABEL DESKTOP_QML + qsTr("Developer options deactivated.") + ) + counter = 0 } } } diff --git a/resources/qml/Governikus/InformationView/+mobile/InformationView.qml b/resources/qml/Governikus/InformationView/+mobile/InformationView.qml deleted file mode 100644 index 443ff1f33..000000000 --- a/resources/qml/Governikus/InformationView/+mobile/InformationView.qml +++ /dev/null @@ -1,109 +0,0 @@ -/* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Layouts 1.2 -import QtQuick.Controls 2.3 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.TitleBar 1.0 -import Governikus.View 1.0 -import Governikus.Type.SettingsModel 1.0 - - -SectionPage { - id: root - //: LABEL ANDROID IOS - title: qsTr("Information") + SettingsModel.translationTrigger - - Component { - id: subMenu - Item { - height: column.height - - Accessible.role: Accessible.Button - Accessible.name: titleText + " " + descriptionText - - Column { - id: column - anchors.left: parent.left - anchors.right: parent.right - spacing: Constants.component_spacing - GText { - width: parent.width - - Accessible.ignored: true - - text: titleText - textStyle: Style.text.normal_accent - } - GText { - width: parent.width - - Accessible.ignored: true - - text: descriptionText - textStyle: Style.text.normal - } - } - MouseArea { - anchors.fill: parent - onClicked: onClickFunction() - } - } - } - VersionInformation { - id: versionInformationPage - visible: false - } - - content: Item { - width: root.width - height: childrenRect.height - - Column { - anchors.left: parent.left - anchors.right: parent.right - anchors.margins: Constants.component_spacing - spacing: Constants.component_spacing - padding: Constants.component_spacing - - Pane { - Loader { - //: LABEL ANDROID IOS - readonly property string titleText: qsTr("Version information") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - readonly property string descriptionText: qsTr("Here you can see detailed information about AusweisApp2.") + SettingsModel.translationTrigger - function onClickFunction() { firePush(versionInformationPage) } - width: parent.width - sourceComponent: subMenu - } - GSeparator { width: parent.width } - Loader { - //: LABEL ANDROID IOS - readonly property string titleText: qsTr("Software license") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - readonly property string descriptionText: qsTr("Read the software license text on the application homepage.") + SettingsModel.translationTrigger - function onClickFunction() { - if (Qt.platform.os === "android") { - //: LABEL ANDROID IOS - Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/android/")) - } - else if (Qt.platform.os === "ios") { - //: LABEL ANDROID IOS - Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/ios/")) - } - else { - //: LABEL ANDROID IOS - Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/windows-and-mac/")) - } - } - width: parent.width - sourceComponent: subMenu - } - } - } - } -} diff --git a/resources/qml/Governikus/InformationView/+mobile/VersionInformation.qml b/resources/qml/Governikus/InformationView/+mobile/VersionInformation.qml index 3384da46a..fa739d096 100644 --- a/resources/qml/Governikus/InformationView/+mobile/VersionInformation.qml +++ b/resources/qml/Governikus/InformationView/+mobile/VersionInformation.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/InformationView/qmldir b/resources/qml/Governikus/InformationView/qmldir index 765a84e96..8764fd631 100644 --- a/resources/qml/Governikus/InformationView/qmldir +++ b/resources/qml/Governikus/InformationView/qmldir @@ -1,8 +1,4 @@ module InformationView -internal DiagnosisView DiagnosisView.qml -internal InformationViewIcon InformationViewIcon.qml - -InformationView 1.0 InformationView.qml +DiagnosisView 1.0 DiagnosisView.qml VersionInformation 1.0 VersionInformation.qml - diff --git a/resources/qml/Governikus/MainView/+desktop/MainView.qml b/resources/qml/Governikus/MainView/+desktop/MainView.qml index 81a71190f..22042b9fa 100644 --- a/resources/qml/Governikus/MainView/+desktop/MainView.qml +++ b/resources/qml/Governikus/MainView/+desktop/MainView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -39,7 +39,7 @@ SectionPage { width: view.horizontalItemSpace //: LABEL DESKTOP_QML - title: qsTr("Self-authentication") + SettingsModel.translationTrigger + title: qsTr("Self-Authentication") + SettingsModel.translationTrigger image: "qrc:/images/desktop/main_identify.svg" onClicked: sectionPage.nextView(SectionPage.Views.SelfAuthentication) @@ -62,7 +62,7 @@ SectionPage { //: LABEL DESKTOP_QML title: qsTr("Provider") + SettingsModel.translationTrigger - image: "qrc:/images/desktop/main_provider.svg" + image: "qrc:/images/main_provider.svg" onClicked: sectionPage.nextView(SectionPage.Views.Provider) @@ -113,7 +113,7 @@ SectionPage { //: LABEL DESKTOP_QML title: qsTr("Settings") + SettingsModel.translationTrigger - image: "qrc:/images/desktop/settings_icon.svg" + image: "qrc:/images/settings_icon.svg" onClicked: sectionPage.nextView(SectionPage.Views.Settings) @@ -134,8 +134,8 @@ SectionPage { width: view.horizontalItemSpace //: LABEL DESKTOP_QML - title: qsTr("PIN management") + SettingsModel.translationTrigger - image: "qrc:/images/desktop/main_pin.svg" + title: qsTr("PIN-Management") + SettingsModel.translationTrigger + image: "qrc:/images/main_pin.svg" onClicked: ChangePinModel.startWorkflow() @@ -161,7 +161,7 @@ SectionPage { activeFocusOnTab: true - onClicked: sectionPage.nextView(SectionPage.Views.Information) + onClicked: sectionPage.nextView(SectionPage.Views.MoreView) } } } diff --git a/resources/qml/Governikus/MainView/+desktop/Tile.qml b/resources/qml/Governikus/MainView/+desktop/Tile.qml index 0a6f44ddb..7e861dee7 100644 --- a/resources/qml/Governikus/MainView/+desktop/Tile.qml +++ b/resources/qml/Governikus/MainView/+desktop/Tile.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -31,6 +31,7 @@ FocusScope { FocusFrame { marginFactor: -2 + dynamic: true } Column { @@ -38,11 +39,13 @@ FocusScope { spacing: Constants.component_spacing - Image { + TintableIcon { id: image sourceSize.height: ApplicationModel.scaleFactor * 200 anchors.horizontalCenter: parent.horizontalCenter + + tintColor: text.textStyle.textColor } GText { @@ -50,7 +53,7 @@ FocusScope { anchors.horizontalCenter: parent.horizontalCenter - textStyle: Style.text.title + textStyle: Style.text.title_inverse font.bold: true } } diff --git a/resources/qml/Governikus/MoreView/+desktop/MoreView.qml b/resources/qml/Governikus/MoreView/+desktop/MoreView.qml new file mode 100644 index 000000000..d69c42104 --- /dev/null +++ b/resources/qml/Governikus/MoreView/+desktop/MoreView.qml @@ -0,0 +1,106 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQml.Models 2.3 + +import Governikus.Global 1.0 +import Governikus.View 1.0 +import Governikus.TitleBar 1.0 +import Governikus.FeedbackView 1.0 +import Governikus.InformationView 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.SettingsModel 1.0 + + +SectionPage { + id: sectionPage + + enum SubViews { + None, + Diagnosis, + ApplicationLog + } + + property int activeSubView + + //: LABEL DESKTOP_QML + Accessible.name: qsTr("Help section") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + Accessible.description: qsTr("This is the help section of the AusweisApp2.") + SettingsModel.translationTrigger + Keys.onEscapePressed: { + if (activeSubView === MoreView.SubViews.None) { + event.accepted = false + return + } + + activeSubView = MoreView.SubViews.None + } + + titleBarAction: TitleBarAction { + //: LABEL DESKTOP_QML + text: qsTr("Help") + SettingsModel.translationTrigger + helpTopic: Utils.helpTopicOf(tabbedPane.currentContentItem, "helpSection") + onClicked: activeSubView = MoreView.SubViews.None + } + + TabbedPane { + id: tabbedPane + + visible: activeSubView === MoreView.SubViews.None + anchors.fill: parent + anchors.margins: Constants.pane_spacing + + sectionsModel: [ + //: LABEL DESKTOP_QML + qsTr("General") + SettingsModel.translationTrigger, + //: LABEL DESKTOP_QML + qsTr("Diagnosis and log") + SettingsModel.translationTrigger, + //: LABEL DESKTOP_QML + qsTr("Version information") + SettingsModel.translationTrigger + ] + + sectionDelegate: TabbedPaneDelegateOneLineText { + sectionName: model ? model.modelData : "" + } + + contentObjectModel: ObjectModel { + Component { MoreViewGeneral {} } + Component { MoreViewDiagnosis {} } + Component { VersionInformation {} } + } + } + + Component { + id: diagnosisView + + DiagnosisView {} + } + + Component { + id: versionInformation + + VersionInformation {} + } + + Component { + id: logFileView + + LogView {} + } + + Loader { + readonly property bool sectionPageTypeMarker: true + property var titleBarAction: item ? item.titleBarAction : undefined + + visible: item // Otherwise onVisibleChildrenChanged and onVisibleChanged won't be triggered + anchors.fill: parent + + sourceComponent: switch(sectionPage.activeSubView) { + case MoreView.SubViews.Diagnosis: return diagnosisView + case MoreView.SubViews.ApplicationLog: return logFileView + } + } +} diff --git a/resources/qml/Governikus/MoreView/+desktop/MoreViewDiagnosis.qml b/resources/qml/Governikus/MoreView/+desktop/MoreViewDiagnosis.qml new file mode 100644 index 000000000..36ea0f599 --- /dev/null +++ b/resources/qml/Governikus/MoreView/+desktop/MoreViewDiagnosis.qml @@ -0,0 +1,46 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.View 1.0 +import Governikus.Type.SettingsModel 1.0 + +ColumnLayout { + + spacing: Constants.component_spacing + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Diagnosis") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("You can view and save the diagnosis information of the AusweisApp2 and your system here.") + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/info_diagnosis.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Show diagnosis") + SettingsModel.translationTrigger + onClicked: sectionPage.activeSubView = MoreView.SubViews.Diagnosis + } + + GSeparator { + Layout.fillWidth: true + } + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Application log") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("You can view the logs of the AusweisApp2 here.") + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/info_application_log.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Show logs") + SettingsModel.translationTrigger + onClicked: sectionPage.activeSubView = MoreView.SubViews.ApplicationLog + } + +} diff --git a/resources/qml/Governikus/MoreView/+desktop/MoreViewGeneral.qml b/resources/qml/Governikus/MoreView/+desktop/MoreViewGeneral.qml new file mode 100644 index 000000000..cba720d41 --- /dev/null +++ b/resources/qml/Governikus/MoreView/+desktop/MoreViewGeneral.qml @@ -0,0 +1,168 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.View 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.Type.ApplicationModel 1.0 + +ColumnLayout { + + spacing: Constants.component_spacing + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("FAQ") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("Do you have questions how to use %1?").arg(Qt.application.name) + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/info_questions.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Open website") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + buttonTooltip: qsTr("https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/") + SettingsModel.translationTrigger + buttonIconSource: "qrc:///images/link_external.svg" + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/")) + SettingsModel.translationTrigger + } + + GSeparator { + Layout.fillWidth: true + } + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Support") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("Do you need further help?") + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/help_icon.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Open website") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + buttonTooltip: qsTr("https://www.ausweisapp.bund.de/en/qa/support/") + SettingsModel.translationTrigger + buttonIconSource: "qrc:///images/link_external.svg" + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/support/")) + SettingsModel.translationTrigger + } + + GSeparator { + Layout.fillWidth: true + } + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Report error") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("Did you find a bug? Please tell us, so we can fix it.") + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/info_report_error.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Open website") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + buttonTooltip: qsTr("https://www.ausweisapp.bund.de/en/qa/report-an-error/") + SettingsModel.translationTrigger + buttonIconSource: "qrc:///images/link_external.svg" + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/report-an-error/")) + SettingsModel.translationTrigger + } + + GSeparator { + Layout.fillWidth: true + } + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Rate %1").arg(Qt.application.name) + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("Do you want to rate the %1?").arg(Qt.application.name) + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/info_rate_application.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Open website") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + buttonTooltip: qsTr("https://www.ausweisapp.bund.de/en/qa/evaluate-us/") + SettingsModel.translationTrigger + buttonIconSource: "qrc:///images/link_external.svg" + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/evaluate-us/")) + SettingsModel.translationTrigger + } + + GSeparator { + Layout.fillWidth: true + } + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Online help") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("Do you need further help?") + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/info_manual.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Open website") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + buttonTooltip: qsTr("Help") + SettingsModel.translationTrigger + buttonIconSource: "qrc:///images/link_external.svg" + onClicked: ApplicationModel.openOnlineHelp("index") + } + + GSeparator { + Layout.fillWidth: true + } + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Software licenses") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("Do you want to read about the software licenses?") + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/info_license.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Open website") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + buttonTooltip: qsTr("https://www.ausweisapp.bund.de/en/download/windows-and-mac/") + SettingsModel.translationTrigger + buttonIconSource: "qrc:///images/link_external.svg" + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/windows-and-mac/")) + SettingsModel.translationTrigger + } + + GSeparator { + Layout.fillWidth: true + } + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Release notes") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("Do you want to read the release notes?") + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/main_info.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Open website") + SettingsModel.translationTrigger + buttonTooltip: ApplicationModel.releaseNotesUrl + buttonIconSource: "qrc:///images/link_external.svg" + onClicked: Qt.openUrlExternally(ApplicationModel.releaseNotesUrl) + } + + GSeparator { + Layout.fillWidth: true + } + + MoreViewMenuItem { + Layout.fillWidth: true + + //: LABEL DESKTOP_QML + title: qsTr("Setup assistant") + SettingsModel.translationTrigger + //: LABEL DESKTOP_QML + description: qsTr("Do you want to run the setup assistant again?") + SettingsModel.translationTrigger + iconSource: "qrc:/images/desktop/info_setup.svg" + //: LABEL DESKTOP_QML + buttonText: qsTr("Start setup assistant") + SettingsModel.translationTrigger + onClicked: sectionPage.nextView(SectionPage.Views.SetupAssistant) + } +} diff --git a/resources/qml/Governikus/MoreView/+desktop/MoreViewMenuItem.qml b/resources/qml/Governikus/MoreView/+desktop/MoreViewMenuItem.qml new file mode 100644 index 000000000..5e1db5420 --- /dev/null +++ b/resources/qml/Governikus/MoreView/+desktop/MoreViewMenuItem.qml @@ -0,0 +1,48 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 + +RowLayout { + id: baseItem + + property alias title: labeledText.label + property alias description: labeledText.text + property alias iconSource: icon.source + + property alias buttonText: button.text + property alias buttonTooltip: button.enabledTooltipText + property alias buttonIconSource: button.icon.source + + signal clicked() + + spacing: Constants.component_spacing + + TintableIcon { + id: icon + + sourceSize.width: Style.dimens.icon_size + + tintColor: Style.color.accent + } + + LabeledText { + id: labeledText + + Layout.fillWidth: true + + activeFocusOnTab: true + } + + GButton { + id: button + + tintIcon: true + onClicked: baseItem.clicked() + } +} diff --git a/resources/qml/Governikus/MoreView/+mobile/+android/MoreView.qml b/resources/qml/Governikus/MoreView/+mobile/+android/MoreView.qml new file mode 100644 index 000000000..e80fa0d68 --- /dev/null +++ b/resources/qml/Governikus/MoreView/+mobile/+android/MoreView.qml @@ -0,0 +1,122 @@ +/* + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Layouts 1.3 +import QtQuick.Controls 2.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.TitleBar 1.0 +import Governikus.View 1.0 +import Governikus.TutorialView 1.0 +import Governikus.FeedbackView 1.0 +import Governikus.InformationView 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.Type.LogModel 1.0 + + +SectionPage { + id: root + + //: LABEL ANDROID IOS + title: qsTr("Help & Feedback") + SettingsModel.translationTrigger + + content: ColumnLayout { + width: root.width + + spacing: 0 + + MoreViewMenuItem { + //: LABEL ANDROID + text: qsTr("Tutorial") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Do you want to know how to use %1?").arg(Qt.application.name) + SettingsModel.translationTrigger + onClicked: firePush(tutorialPage) + } + + MoreViewLinkMenuItem { + //: LABEL ANDROID + text: qsTr("FAQ") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Do you have further questions about %1?").arg(Qt.application.name) + SettingsModel.translationTrigger + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/")) + } + + MoreViewLinkMenuItem { + //: LABEL ANDROID + text: qsTr("Support") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Do you need further support?") + SettingsModel.translationTrigger + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/support/")) + } + + MoreViewLinkMenuItem { + //: LABEL ANDROID + text: qsTr("Rate AusweisApp2") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Do you want to rate us in the Google Play Store?") + SettingsModel.translationTrigger + onClicked: Qt.openUrlExternally("market://details?id=" + ApplicationModel.packageName) + } + + MoreViewLinkMenuItem { + //: LABEL ANDROID + text: qsTr("Release notes") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Do you want to view the release notes of %1?").arg(Qt.application.name) + SettingsModel.translationTrigger + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/android/")) + } + + MoreViewMenuItem { + //: LABEL ANDROID + text: qsTr("Report error") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Did you find a bug? Please tell us, so we can fix it.") + SettingsModel.translationTrigger + onClicked: LogModel.mailLog() + } + + MoreViewMenuItem { + //: LABEL ANDROID + text: qsTr("Show log") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Do you want to view the logs of %1?").arg(Qt.application.name) + SettingsModel.translationTrigger + onClicked: firePush(logPage) + } + + MoreViewMenuItem { + //: LABEL ANDROID + text: qsTr("Version information") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Do you want to see detailed information about %1?").arg(Qt.application.name) + SettingsModel.translationTrigger + onClicked: firePush(versionInformationPage) + } + + MoreViewLinkMenuItem { + //: LABEL ANDROID + text: qsTr("Software license") + SettingsModel.translationTrigger + //: LABEL ANDROID + footerText: qsTr("Do you want to read the software licenses?") + SettingsModel.translationTrigger + onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/android/")) + } + } + + Component { + id: logPage + + LogView {} + } + + Component { + id: tutorialPage + + TutorialView {} + } + + Component { + id: versionInformationPage + + VersionInformation {} + } +} diff --git a/resources/qml/Governikus/MoreView/+mobile/MoreView.qml b/resources/qml/Governikus/MoreView/+mobile/+ios/MoreView.qml similarity index 74% rename from resources/qml/Governikus/MoreView/+mobile/MoreView.qml rename to resources/qml/Governikus/MoreView/+mobile/+ios/MoreView.qml index 3754a1bb9..cd7c5c2b5 100644 --- a/resources/qml/Governikus/MoreView/+mobile/MoreView.qml +++ b/resources/qml/Governikus/MoreView/+mobile/+ios/MoreView.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.TitleBar 1.0 @@ -13,6 +13,7 @@ import Governikus.HistoryView 1.0 import Governikus.DeveloperView 1.0 import Governikus.TutorialView 1.0 import Governikus.View 1.0 +import Governikus.SettingsView 1.0 import Governikus.Type.RemoteServiceModel 1.0 import Governikus.Type.SettingsModel 1.0 import Governikus.Type.LogModel 1.0 @@ -40,19 +41,40 @@ SectionPage { //: LABEL ANDROID IOS DESKTOP_QML text: qsTr("Version information") + SettingsModel.translationTrigger icon: "qrc:///images/iOS/more/icon_mehr_npa.svg" - showRightArrow: true onClicked: firePush(versionInformationPage) } + MoreViewMenuItem { + //: LABEL ANDROID IOS DESKTOP_QML + text: qsTr("Settings") + SettingsModel.translationTrigger + icon: "qrc:///images/iOS/more/icon_mehr_settings.svg" + onClicked: firePush(settingsView) + } + + MoreViewMenuItem { + //: LABEL ANDROID IOS DESKTOP_QML + text: qsTr("History") + SettingsModel.translationTrigger + icon: "qrc:///images/iOS/more/icon_mehr_verlauf.svg" + onClicked: { + firePush(historyView) + } + } + MoreViewMenuItem { //: LABEL ANDROID IOS DESKTOP_QML text: qsTr("Tutorial") + SettingsModel.translationTrigger icon: "qrc:///images/iOS/more/icon_mehr_tutorial.svg" - showRightArrow: true onClicked: firePush(tutorialView) } MoreViewMenuItem { + //: LABEL ANDROID IOS DESKTOP_QML + text: qsTr("Show log") + SettingsModel.translationTrigger + icon: "qrc:///images/iOS/more/icon_mehr_log.svg" + onClicked: firePush(logView) + } + + MoreViewLinkMenuItem { //: LABEL ANDROID IOS DESKTOP_QML text: qsTr("FAQ") + SettingsModel.translationTrigger icon: "qrc:///images/iOS/more/icon_mehr_info.svg" @@ -60,7 +82,7 @@ SectionPage { onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/")) } - MoreViewMenuItem { + MoreViewLinkMenuItem { //: LABEL ANDROID IOS DESKTOP_QML text: qsTr("Support") + SettingsModel.translationTrigger icon: "qrc:///images/iOS/more/icon_mehr_fragen.svg" @@ -68,7 +90,7 @@ SectionPage { onClicked: Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/qa/support/")) } - MoreViewMenuItem { + MoreViewLinkMenuItem { //: LABEL ANDROID IOS DESKTOP_QML text: qsTr("Rate app") + SettingsModel.translationTrigger; icon: "qrc:///images/iOS/more/icon_mehr_favorit.svg"; @@ -79,17 +101,17 @@ SectionPage { } } - MoreViewMenuItem { + MoreViewLinkMenuItem { //: LABEL ANDROID IOS DESKTOP_QML text: qsTr("Report error") + SettingsModel.translationTrigger icon: "qrc:///images/iOS/more/icon_mehr_report.svg" onClicked: LogModel.mailLog() } - MoreViewMenuItem { + MoreViewLinkMenuItem { //: LABEL ANDROID IOS DESKTOP_QML - text: qsTr("Software license") + SettingsModel.translationTrigger - icon: "qrc:///images/iOS/more/icon_mehr_license.svg" + text: qsTr("Release notes") + SettingsModel.translationTrigger; + icon: "qrc:///images/iOS/more/icon_mehr_info.svg"; onClicked: { if (Qt.platform.os === "android") { //: LABEL ANDROID IOS DESKTOP_QML @@ -106,99 +128,78 @@ SectionPage { } } - MoreViewMenuItem { + MoreViewLinkMenuItem { //: LABEL ANDROID IOS DESKTOP_QML - text: qsTr("History") + SettingsModel.translationTrigger - icon: "qrc:///images/iOS/more/icon_mehr_verlauf.svg" - showRightArrow: true + text: qsTr("Software license") + SettingsModel.translationTrigger + icon: "qrc:///images/iOS/more/icon_mehr_license.svg" + showSeparator: plugin.debugBuild onClicked: { - firePush(historyView) + if (Qt.platform.os === "android") { + //: LABEL ANDROID IOS DESKTOP_QML + Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/android/")) + } + else if (Qt.platform.os === "ios") { + //: LABEL ANDROID IOS DESKTOP_QML + Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/ios/")) + } + else { + //: LABEL ANDROID IOS DESKTOP_QML + Qt.openUrlExternally(qsTr("https://www.ausweisapp.bund.de/en/download/windows-and-mac/")) + } } } MoreViewMenuItem { - //: LABEL ANDROID IOS DESKTOP_QML - text: qsTr("Show log") + SettingsModel.translationTrigger - icon: "qrc:///images/iOS/more/icon_mehr_log.svg" - showRightArrow: true - showSeparator: plugin.developerBuild - onClicked: firePush(logView) - } + visible: plugin.debugBuild - MoreViewMenuItem { - visible: plugin.developerBuild //: LABEL ANDROID IOS DESKTOP_QML text: qsTr("Developer options") + SettingsModel.translationTrigger - icon: "qrc:///images/zahnraeder.svg" - showRightArrow: true + icon: "qrc:///images/settings_icon.svg" showSeparator: false + tintIcon: true + onClicked: firePush(developerView) } GSeparator { - Layout.bottomMargin: 2 * Constants.component_spacing + languageButtons.childrenRect.height + Layout.bottomMargin: Constants.component_spacing Layout.fillWidth: true } } - Item { - id: languageButtons - - anchors.left: parent.left - anchors.right: parent.right - anchors.bottom: parent.bottom - - LocationButton { - id: lang_de - - anchors.margins: Constants.component_spacing - anchors.bottom: parent.bottom - anchors.right: lang_en.left - - Accessible.name: qsTr("Set language to german") + SettingsModel.translationTrigger - - language: "de" - name: "DE" - image: "qrc:///images/location_flag_de.svg" - } - - LocationButton { - id: lang_en - - anchors.margins: Constants.component_spacing - anchors.bottom: parent.bottom - anchors.right: parent.right - - Accessible.name: qsTr("Set language to english") + SettingsModel.translationTrigger - - language: "en" - name: "EN" - image: "qrc:///images/location_flag_en.svg" - } - } - Component { id: versionInformationPage + VersionInformation {} } Component { id: historyView + HistoryView {} } Component { id: developerView + DeveloperView {} } Component { id: logView + LogView {} } Component { id: tutorialView + TutorialView {} } + + Component { + id: settingsView + + SettingsView {} + } } diff --git a/resources/qml/Governikus/MoreView/+mobile/MoreViewLinkMenuItem.qml b/resources/qml/Governikus/MoreView/+mobile/MoreViewLinkMenuItem.qml new file mode 100644 index 000000000..df8510751 --- /dev/null +++ b/resources/qml/Governikus/MoreView/+mobile/MoreViewLinkMenuItem.qml @@ -0,0 +1,14 @@ +/* + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtGraphicalEffects 1.0 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 + +MoreViewMenuItem { + showLinkIcon: true + linkIconSource: "qrc:///images/link_external.svg" +} diff --git a/resources/qml/Governikus/MoreView/+mobile/MoreViewMenuItem.qml b/resources/qml/Governikus/MoreView/+mobile/MoreViewMenuItem.qml index ede3576bf..2540414d4 100644 --- a/resources/qml/Governikus/MoreView/+mobile/MoreViewMenuItem.qml +++ b/resources/qml/Governikus/MoreView/+mobile/MoreViewMenuItem.qml @@ -1,16 +1,14 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 ListItem { - implicitHeight: 44 + implicitHeight: Constants.is_layout_ios ? 44 : Style.dimens.list_item_height implicitWidth: parent.width - - showRightArrow: false } diff --git a/resources/qml/Governikus/MoreView/qmldir b/resources/qml/Governikus/MoreView/qmldir index 81c2505b5..5ba2e2a04 100644 --- a/resources/qml/Governikus/MoreView/qmldir +++ b/resources/qml/Governikus/MoreView/qmldir @@ -1,5 +1,8 @@ module MoreView internal MoreViewMenuItem MoreViewMenuItem.qml +internal MoreViewLinkMenuItem MoreViewLinkMenuItem.qml +internal MoreViewGeneral MoreViewGeneral.qml +internal MoreViewDiagnosis MoreViewDiagnosis.qml MoreView 1.0 MoreView.qml diff --git a/resources/qml/Governikus/Navigation/+android/Navigation.qml b/resources/qml/Governikus/Navigation/+android/Navigation.qml index 79861ed15..0ac12de28 100644 --- a/resources/qml/Governikus/Navigation/+android/Navigation.qml +++ b/resources/qml/Governikus/Navigation/+android/Navigation.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -66,7 +66,6 @@ Item { anchors.top: parent.top anchors.bottom: parent.bottom orientation: Qt.Vertical - color: Style.color.border_dark } } @@ -97,5 +96,18 @@ Item { onClicked: drawer.close() } } + + background: Rectangle { + anchors.fill: parent + color: Style.color.background + GSeparator { + anchors { + top: parent.top + bottom: parent.bottom + right: parent.right + } + orientation: Qt.Vertical + } + } } } diff --git a/resources/qml/Governikus/Navigation/+android/NavigationItem.qml b/resources/qml/Governikus/Navigation/+android/NavigationItem.qml index ec9ea47cf..a8cb677cc 100644 --- a/resources/qml/Governikus/Navigation/+android/NavigationItem.qml +++ b/resources/qml/Governikus/Navigation/+android/NavigationItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -12,7 +12,7 @@ Item { property alias text: tabText.text signal clicked - Accessible.role: Accessible.Button + Accessible.role: Accessible.MenuItem Accessible.name: text Item { @@ -21,13 +21,14 @@ Item { width: Style.dimens.menubar_width anchors.left: parent.left - Image { + TintableIcon { id: tabImage height: 35 sourceSize.width: height fillMode: Image.PreserveAspectFit anchors.horizontalCenter: parent.horizontalCenter anchors.verticalCenter: parent.verticalCenter + tintColor: Style.color.menu_icon_tint_color } } @@ -39,7 +40,7 @@ Item { Accessible.ignored: true - textStyle: Style.text.hint_secondary + textStyle: Style.text.hint } MouseArea { diff --git a/resources/qml/Governikus/Navigation/+android/NavigationView.qml b/resources/qml/Governikus/Navigation/+android/NavigationView.qml index f0003f7ad..5a4f11ed5 100644 --- a/resources/qml/Governikus/Navigation/+android/NavigationView.qml +++ b/resources/qml/Governikus/Navigation/+android/NavigationView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -10,14 +10,14 @@ import Governikus.Style 1.0 import Governikus.Type.SettingsModel 1.0 -Rectangle { +Item { id: content - height: appWindow.height - Style.dimens.titlebar_height - width: 250 - color: Style.color.background property var navigationController: null + height: appWindow.height - Style.dimens.titlebar_height + width: 250 + ListModel { id: navModel @@ -28,7 +28,7 @@ Rectangle { } ListElement { - image: "qrc:///images/android/navigation/anbieter.svg" + image: "qrc:///images/main_provider.svg" desc: QT_TR_NOOP("Provider") condition: "provider" } @@ -40,7 +40,7 @@ Rectangle { } ListElement { - image: "qrc:///images/android/navigation/pin.svg" + image: "qrc:///images/main_pin.svg" desc: QT_TR_NOOP("PIN Management") condition: "pin" } @@ -52,50 +52,75 @@ Rectangle { } ListElement { - image: "qrc:///images/android/navigation/tutorial.svg" - desc: QT_TR_NOOP("Tutorial") - condition: "tutorial" + image: "qrc:///images/settings_icon.svg" + desc: QT_TR_NOOP("Settings") + condition: "settings" + section: "settings" } ListElement { image: "qrc:///images/android/navigation/support.svg" desc: QT_TR_NOOP("Help & Feedback") condition: "feedback" + section: "settings" } ListElement { - image: "qrc:///images/android/navigation/faq.svg" - desc: QT_TR_NOOP("Information") - condition: "information" - } - - ListElement { - image: "qrc:///images/zahnraeder.svg" desc: QT_TR_NOOP("Developer options") + image: "qrc:///images/settings_icon.svg" condition: "developeroptions" + section: "settings" } } - GListView { id: listView + anchors.fill: parent + boundsBehavior: Flickable.StopAtBounds model: navModel currentIndex: navigationController.currentIndex - + section.property: "section" + section.delegate: Item { + height: Constants.component_spacing + width: parent.width + + GSeparator { + width: parent.width + anchors.verticalCenter: parent.verticalCenter + } + } highlight: Rectangle { - color: "black" - opacity: 0.1 + y: listView.currentItem.y height: 45 width: content.width - y: listView.currentItem.y + + color: "#1A000000" //10% transparent black + + GSeparator { + anchors { + top: parent.top + left: parent.left + right: parent.right + } + } + + GSeparator { + anchors { + bottom: parent.bottom + left: parent.left + right: parent.right + } + } } highlightFollowsCurrentItem: false - delegate: NavigationItem { + // Hide developer options if we are not using developer build (debug build) + visible: condition !== "developeroptions" || plugin.debugBuild height: 45 width: content.width + source: image text: qsTr(desc) + SettingsModel.translationTrigger onClicked: { @@ -107,38 +132,6 @@ Rectangle { } navigationController.close() } - // Hide developer options if we are not using developer build (debug build) - visible: condition !== "developeroptions" || plugin.developerBuild } } - - LocationButton { - id: lang_de - - anchors.margins: Constants.component_spacing - anchors.bottomMargin: plugin.safeAreaMargins.bottom + Constants.component_spacing - anchors.bottom: parent.bottom - anchors.right: lang_en.left - - Accessible.name: qsTr("Set language to german") + SettingsModel.translationTrigger - - language: "de" - name: "DE" - image: "qrc:///images/location_flag_de.svg" - } - - LocationButton { - id: lang_en - - anchors.margins: Constants.component_spacing - anchors.bottom: parent.bottom - anchors.right: parent.right - anchors.bottomMargin: plugin.safeAreaMargins.bottom + Constants.component_spacing - - Accessible.name: qsTr("Set language to english") + SettingsModel.translationTrigger - - language: "en" - name: "EN" - image: "qrc:///images/location_flag_en.svg" - } } diff --git a/resources/qml/Governikus/Navigation/+ios/Navigation.qml b/resources/qml/Governikus/Navigation/+ios/Navigation.qml index 09758753d..9e7bca32b 100644 --- a/resources/qml/Governikus/Navigation/+ios/Navigation.qml +++ b/resources/qml/Governikus/Navigation/+ios/Navigation.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -27,7 +27,7 @@ Rectangle { visible: !lockedAndHidden height: lockedAndHidden ? 0 : (Style.dimens.tabbar_height + bottomSafeAreaMargin) - color: Constants.white + color: Style.color.background_pane Component.onCompleted: { state = SettingsModel.showSetupAssistantOnStart ? "tutorial" : "identify" diff --git a/resources/qml/Governikus/Navigation/+ios/NavigationItem.qml b/resources/qml/Governikus/Navigation/+ios/NavigationItem.qml index 571874a01..35226648d 100644 --- a/resources/qml/Governikus/Navigation/+ios/NavigationItem.qml +++ b/resources/qml/Governikus/Navigation/+ios/NavigationItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -15,7 +15,7 @@ Item { property var iconPadding: 4 signal clicked - Accessible.role: Accessible.Button + Accessible.role: Accessible.PageTab Accessible.name: text Accessible.onPressAction: clicked() @@ -46,8 +46,8 @@ Item { onClicked: parent.clicked() } - layer.enabled: true + layer.enabled: GraphicsInfo.api !== GraphicsInfo.Software layer.effect: ColorOverlay { - color: selected ? Style.color.accent : Constants.grey + color: selected ? Style.text.hint_accent.textColor : Style.text.hint_secondary.textColor } } diff --git a/resources/qml/Governikus/Navigation/+ios/NavigationView.qml b/resources/qml/Governikus/Navigation/+ios/NavigationView.qml index 34cef1989..a7d42ec28 100644 --- a/resources/qml/Governikus/Navigation/+ios/NavigationView.qml +++ b/resources/qml/Governikus/Navigation/+ios/NavigationView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -26,7 +26,7 @@ Item { } ListElement { - image: "qrc:///images/iOS/tabBar/anbieter.svg" + image: "qrc:///images/main_provider.svg" desc: QT_TR_NOOP("Provider") condition: "provider" } @@ -38,7 +38,7 @@ Item { } ListElement { - image: "qrc:///images/iOS/tabBar/pin.svg" + image: "qrc:///images/main_pin.svg" desc: QT_TR_NOOP("PIN") condition: "pin" } diff --git a/resources/qml/Governikus/ProgressView/+desktop/ProgressView.qml b/resources/qml/Governikus/ProgressView/+desktop/ProgressView.qml index 33d764cec..97145439d 100644 --- a/resources/qml/Governikus/ProgressView/+desktop/ProgressView.qml +++ b/resources/qml/Governikus/ProgressView/+desktop/ProgressView.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -47,14 +47,11 @@ SectionPage anchors.horizontalCenter: parent.horizontalCenter anchors.top: parent.verticalCenter - Accessible.role: Accessible.Paragraph activeFocusOnTab: true Accessible.name: text.text horizontalAlignment: Text.AlignHCenter - textStyle: Style.text.header - - onLinkActivated: Qt.openUrlExternally(link) + textStyle: Style.text.header_inverse FocusFrame {} } @@ -68,14 +65,11 @@ SectionPage anchors.top: text.bottom anchors.topMargin: Constants.text_spacing - Accessible.role: Accessible.Paragraph activeFocusOnTab: true Accessible.name: subText.text horizontalAlignment: Text.AlignHCenter - textStyle: Style.text.header_secondary - - onLinkActivated: Qt.openUrlExternally(link) + textStyle: Style.text.header_secondary_inverse FocusFrame {} } @@ -89,12 +83,10 @@ SectionPage anchors.bottomMargin: ApplicationModel.scaleFactor * 20 anchors.horizontalCenter: parent.horizontalCenter - Accessible.role: Accessible.Paragraph activeFocusOnTab: true Accessible.name: progressText.text horizontalAlignment: Text.AlignHCenter - textStyle: Style.text.normal FocusFrame {} } @@ -111,7 +103,7 @@ SectionPage Accessible.role: Accessible.ProgressBar activeFocusOnTab: true - Accessible.name: qsTr("Step %1 of %2").arg(value).arg(to) + SettingsModel.translationTrigger + Accessible.name: qsTr("%1 percent done").arg(value) + SettingsModel.translationTrigger from: 0 to: 100 diff --git a/resources/qml/Governikus/ProgressView/+mobile/ProgressView.qml b/resources/qml/Governikus/ProgressView/+mobile/ProgressView.qml index 6d51981f5..405e73d89 100644 --- a/resources/qml/Governikus/ProgressView/+mobile/ProgressView.qml +++ b/resources/qml/Governikus/ProgressView/+mobile/ProgressView.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 diff --git a/resources/qml/Governikus/Provider/+desktop/ProviderContactInfo.qml b/resources/qml/Governikus/Provider/+desktop/ProviderContactInfo.qml index 7a63a9fcd..dc993fb1b 100644 --- a/resources/qml/Governikus/Provider/+desktop/ProviderContactInfo.qml +++ b/resources/qml/Governikus/Provider/+desktop/ProviderContactInfo.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -20,8 +20,8 @@ Item { height: columnLayout.height Accessible.name: qsTr("Provider contact information") + SettingsModel.translationTrigger - Accessible.description: qsTr("Contact information of the selected service provider.") + SettingsModel.translationTrigger - Accessible.role: Accessible.Heading + Accessible.description: qsTr("Contact information of the selected provider.") + SettingsModel.translationTrigger + Accessible.role: Accessible.Grouping ColumnLayout { id: columnLayout @@ -37,7 +37,7 @@ Item { //: LABEL DESKTOP_QML text: qsTr("Contact") + SettingsModel.translationTrigger - textStyle: Style.text.title + textStyle: Style.text.title_inverse } Repeater { diff --git a/resources/qml/Governikus/Provider/+desktop/ProviderContactInfoItem.qml b/resources/qml/Governikus/Provider/+desktop/ProviderContactInfoItem.qml index 9cce98a03..d11df0ee3 100644 --- a/resources/qml/Governikus/Provider/+desktop/ProviderContactInfoItem.qml +++ b/resources/qml/Governikus/Provider/+desktop/ProviderContactInfoItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -36,12 +36,12 @@ Item { spacing: Constants.groupbox_spacing - Image { + TintableIcon { id: image sourceSize.height: ApplicationModel.scaleFactor * 40 sourceSize.width: ApplicationModel.scaleFactor * 40 - fillMode: Image.PreserveAspectFit + tintColor: text.textStyle.textColor } GText { @@ -50,13 +50,10 @@ Item { Layout.fillWidth: true linkColor: color - - onLinkActivated: Qt.openUrlExternally(link) } } FocusFrame { - dynamic: false framee: layout } } diff --git a/resources/qml/Governikus/Provider/+desktop/ProviderDetailButtonBar.qml b/resources/qml/Governikus/Provider/+desktop/ProviderDetailButtonBar.qml index baefda329..4ad863efe 100644 --- a/resources/qml/Governikus/Provider/+desktop/ProviderDetailButtonBar.qml +++ b/resources/qml/Governikus/Provider/+desktop/ProviderDetailButtonBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -31,42 +31,77 @@ Rectangle { } } - Accessible.name: qsTr("Link to service provider") + SettingsModel.translationTrigger - Accessible.description: qsTr("Clicking this link will open the website of the service provider in your web browser. The URL of the provider is") + " " + address + SettingsModel.translationTrigger - Accessible.role: Accessible.Button - activeFocusOnTab: true - Keys.onSpacePressed: clickButton() - color: Constants.white + color: Style.color.background_pane + + GSeparator { + anchors { + top: parent.top + left: parent.left + right: parent.right + } + + height: Style.dimens.high_contrast_item_border + color: Style.color.high_contrast_item_border + } + + GSeparator { + anchors { + bottom: parent.bottom + left: parent.left + right: parent.right + } + + height: Style.dimens.high_contrast_item_border + color: Style.color.high_contrast_item_border + } + + Rectangle { + id: iconContainer - Image { - id: icon + height: ApplicationModel.scaleFactor * 135 + width: height anchors.left: parent.left anchors.leftMargin: Constants.component_spacing anchors.verticalCenter: baseItem.top - height: ApplicationModel.scaleFactor * 135 - width: height + radius: Style.dimens.corner_radius + color: Constants.white + border.color: Style.color.border + border.width: Style.dimens.separator_size + + Image { + id: icon - source: baseItem.providerIcon - asynchronous: true - fillMode: Image.PreserveAspectFit + anchors.fill: parent + anchors.margins: iconContainer.radius / 2 + + source: baseItem.providerIcon + asynchronous: true + fillMode: Image.PreserveAspectFit + } } GText { width: parent.width / 2 - anchors.left: icon.right + anchors.left: iconContainer.right anchors.right: button.left anchors.leftMargin: Constants.component_spacing anchors.rightMargin: Constants.component_spacing anchors.verticalCenter: parent.verticalCenter - textStyle: Style.text.header_inverse + activeFocusOnTab: true + + textStyle: Style.text.header text: shortDescription !== "" ? shortDescription : shortName elide: Text.ElideRight maximumLineCount: 2 + + FocusFrame { + borderColor: Style.color.focus_indicator + } } GButton { diff --git a/resources/qml/Governikus/Provider/+desktop/ProviderDetailHistory.qml b/resources/qml/Governikus/Provider/+desktop/ProviderDetailHistory.qml index 0f2e93df7..37ba66845 100644 --- a/resources/qml/Governikus/Provider/+desktop/ProviderDetailHistory.qml +++ b/resources/qml/Governikus/Provider/+desktop/ProviderDetailHistory.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -20,7 +20,7 @@ Item { height: columnLayout.height Accessible.name: qsTr("List of your past interactions with this provider") + SettingsModel.translationTrigger - Accessible.description: HistoryModel.nameFilter.count === 0 ? qsTr("The list is empty, no recorded interaction with this service provider.") + SettingsModel.translationTrigger : "" + Accessible.description: HistoryModel.nameFilter.count === 0 ? qsTr("The list is empty, no recorded interaction with this provider.") + SettingsModel.translationTrigger : "" Accessible.role: Accessible.List ColumnLayout { @@ -62,17 +62,14 @@ Item { } GText { - id: textNoHistoryEntries - visible: repeater.count === 0 width: parent.width - Accessible.name: text activeFocusOnTab: true - textStyle: Style.text.normal_secondary_inverse //: INFO DESKTOP_QML No authentication history, placeholder text. text: qsTr("Currently there are no history entries.") + SettingsModel.translationTrigger + textStyle: Style.text.normal } } } diff --git a/resources/qml/Governikus/Provider/+desktop/ProviderDetailHistoryItem.qml b/resources/qml/Governikus/Provider/+desktop/ProviderDetailHistoryItem.qml index 2a5c6dc7d..4656d6ab3 100644 --- a/resources/qml/Governikus/Provider/+desktop/ProviderDetailHistoryItem.qml +++ b/resources/qml/Governikus/Provider/+desktop/ProviderDetailHistoryItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -7,6 +7,7 @@ import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 +import Governikus.View 1.0 import Governikus.Type.SettingsModel 1.0 @@ -16,6 +17,9 @@ Item { property string providerName: "" property string purposeText: "" + Accessible.role: Accessible.ListItem + Accessible.name: date.text + ". " + providerName + ". " + purposeText + height: columnLayout.height ColumnLayout { @@ -30,7 +34,7 @@ Item { GText { id: date - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal font.capitalization: Font.AllUppercase text: ( Utils.isToday(dateTime) ? qsTr("today") : Utils.isYesterday(dateTime) ? qsTr("yesterday") : @@ -39,44 +43,47 @@ Item { ) + SettingsModel.translationTrigger } - Row { + GridLayout { Layout.fillWidth: true - GText { - width: parent.width * 0.25 + columnSpacing: Constants.text_spacing + columns: 2 - textStyle: Style.text.normal_inverse + GText { + textStyle: Style.text.normal //: LABEL DESKTOP_QML text: qsTr("Service:") + SettingsModel.translationTrigger font.weight: Font.Bold } GText { - width: parent.width * 0.75 + Layout.fillWidth: true - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal text: purposeText + maximumLineCount: 1 + elide: Text.ElideRight } - } - - Row { - Layout.fillWidth: true GText { - width: parent.width * 0.25 - - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal //: LABEL DESKTOP_QML text: qsTr("Provider:") + SettingsModel.translationTrigger font.weight: Font.Bold } GText { - width: parent.width * 0.75 + Layout.fillWidth: true - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal text: providerName + maximumLineCount: 1 + elide: Text.ElideRight } } } + + FocusFrame { + borderColor: Style.color.focus_indicator + } } diff --git a/resources/qml/Governikus/Provider/+desktop/ProviderDetailView.qml b/resources/qml/Governikus/Provider/+desktop/ProviderDetailView.qml index b98426dd5..4f8303307 100644 --- a/resources/qml/Governikus/Provider/+desktop/ProviderDetailView.qml +++ b/resources/qml/Governikus/Provider/+desktop/ProviderDetailView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.0 @@ -15,18 +15,17 @@ import Governikus.Type.SettingsModel 1.0 SectionPage { id: baseItem - readonly property color titleBarColor: Category.displayColor(provider.category) - readonly property real titleBarOpacity: 1 + readonly property color titleBarColor: Style.currentTheme.highContrast ? Style.color.background_pane : Category.displayColor(provider.category) signal showDetailView(var pModel) property alias historyModelItem: provider.modelItem property alias providerModelItem: provider.modelItem Accessible.name: qsTr("Provider detail view") + SettingsModel.translationTrigger - Accessible.description: qsTr("This view shows a detailed description of a service provider.") + SettingsModel.translationTrigger + Accessible.description: qsTr("This view shows a detailed description of a provider.") + SettingsModel.translationTrigger titleBarAction: TitleBarAction { text: provider.shortName - helpTopic: "providerPage" + helpTopic: "providerDetails" } ProviderModelItem { @@ -124,23 +123,26 @@ SectionPage { //: LABEL DESKTOP_QML title: qsTr("Description") + SettingsModel.translationTrigger + onVisibleChanged: scrollYPositionIntoView(0) + GText { id: leftColumn width: parent.width - Accessible.name: qsTr("Description of the service provider.") + SettingsModel.translationTrigger + Accessible.name: qsTr("Description of the provider.") + SettingsModel.translationTrigger Accessible.description: text Accessible.role: Accessible.StaticText activeFocusOnTab: true //: LABEL DESKTOP_QML - text: !!provider.longDescription ? provider.longDescription : qsTr("The service provider did not provide a description.") + SettingsModel.translationTrigger - textStyle: Style.text.normal_inverse + text: !!provider.longDescription ? provider.longDescription : qsTr("The provider did not provide a description.") + SettingsModel.translationTrigger + textStyle: Style.text.normal } } FocusFrame { + marginFactor: 2 framee: leftPane scope: leftColumn } @@ -159,6 +161,8 @@ SectionPage { //: LABEL DESKTOP_QML title: qsTr("History") + SettingsModel.translationTrigger + onVisibleChanged: scrollYPositionIntoView(0) + ProviderDetailHistory { id: rightColumn @@ -169,6 +173,7 @@ SectionPage { } FocusFrame { + marginFactor: 2 framee: rightPane scope: rightColumn } @@ -177,6 +182,6 @@ SectionPage { } FocusPoint { - color: Constants.black + color: Style.color.focus_indicator } } diff --git a/resources/qml/Governikus/Provider/+desktop/ProviderInfoSection.qml b/resources/qml/Governikus/Provider/+desktop/ProviderInfoSection.qml index 6e1d2200d..f23bfb42b 100644 --- a/resources/qml/Governikus/Provider/+desktop/ProviderInfoSection.qml +++ b/resources/qml/Governikus/Provider/+desktop/ProviderInfoSection.qml @@ -1,21 +1,24 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import Governikus.Global 1.0 +import Governikus.Style 1.0 import Governikus.View 1.0 import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SettingsModel 1.0 Item { + id: baseItem + property alias image: icon.source property alias title: text.label property string name: "" - Accessible.role: Accessible.Section + Accessible.role: Accessible.StaticText Accessible.name: text.Accessible.name height: contentRow.height @@ -34,13 +37,15 @@ Item { LabeledText { id: text + width: baseItem.width - icon.width - Constants.groupbox_spacing //: LABEL DESKTOP_QML text: name.length > 0 ? name : qsTr("See details under \"more...\"") + SettingsModel.translationTrigger + maximumBodyLineCount: 1 + bodyElide: Text.ElideRight } } FocusFrame { - border.color: Constants.black - dynamic: false + borderColor: Style.color.focus_indicator } } diff --git a/resources/qml/Governikus/Provider/+desktop/ProviderModelItem.qml b/resources/qml/Governikus/Provider/+desktop/ProviderModelItem.qml index 2c3628f79..5f806499c 100644 --- a/resources/qml/Governikus/Provider/+desktop/ProviderModelItem.qml +++ b/resources/qml/Governikus/Provider/+desktop/ProviderModelItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Provider/+mobile/+android/ProviderDetailTab.qml b/resources/qml/Governikus/Provider/+mobile/+android/ProviderDetailTab.qml index 643b4e267..f966b7532 100644 --- a/resources/qml/Governikus/Provider/+mobile/+android/ProviderDetailTab.qml +++ b/resources/qml/Governikus/Provider/+mobile/+android/ProviderDetailTab.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -33,7 +33,7 @@ TabButton { width: parent.width radius: 3 - color: button.checked ? Constants.white : Style.color.border + color: button.checked ? Style.color.background_pane : Style.color.border border.color: Style.color.border border.width: Style.dimens.separator_size } diff --git a/resources/qml/Governikus/Provider/+mobile/+ios/ProviderDetailTab.qml b/resources/qml/Governikus/Provider/+mobile/+ios/ProviderDetailTab.qml index 5fb671b0c..02cc0970e 100644 --- a/resources/qml/Governikus/Provider/+mobile/+ios/ProviderDetailTab.qml +++ b/resources/qml/Governikus/Provider/+mobile/+ios/ProviderDetailTab.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -15,6 +15,8 @@ TabButton { Accessible.name: text contentItem: GText { + Accessible.ignored: true + text: button.text textStyle: button.checked ? Style.text.hint_inverse : Style.text.hint_accent horizontalAlignment: Text.AlignHCenter @@ -32,7 +34,7 @@ TabButton { anchors.leftMargin: button.TabBar.index === 0 ? 0 : -radius radius: 3 - color: button.checked ? Style.color.accent : (button.pressed ? Constants.lightgrey : Constants.white) + color: button.checked ? Style.color.accent : (button.pressed ? Style.color.background_pane_active : Style.color.background_pane) border.color: Constants.blue border.width: 1 } diff --git a/resources/qml/Governikus/Provider/+mobile/+phone/ProviderDetailView.qml b/resources/qml/Governikus/Provider/+mobile/+phone/ProviderDetailView.qml index 9488d32ec..42a2f2bfb 100644 --- a/resources/qml/Governikus/Provider/+mobile/+phone/ProviderDetailView.qml +++ b/resources/qml/Governikus/Provider/+mobile/+phone/ProviderDetailView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -70,6 +70,8 @@ SectionPage { anchors.topMargin: tabBarSpacing anchors.horizontalCenter: swipeBar.horizontalCenter + color: Style.color.background_pane + SwipeView { id: swipeView @@ -90,7 +92,6 @@ SectionPage { padding: Constants.component_spacing //: LABEL ANDROID_PHONE IOS_PHONE text: (!!provider.longDescription ? provider.longDescription : qsTr("Description not available")) + SettingsModel.translationTrigger - textStyle: Style.text.normal horizontalAlignment: Text.AlignLeft } diff --git a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderContactInfo.qml b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderContactInfo.qml index 9058aea36..25a744d0f 100644 --- a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderContactInfo.qml +++ b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderContactInfo.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 diff --git a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderContactInfoItem.qml b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderContactInfoItem.qml index 2faa6700e..a57431d18 100644 --- a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderContactInfoItem.qml +++ b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderContactInfoItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailButtonBar.qml b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailButtonBar.qml index f97acb5ed..8e92cff94 100644 --- a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailButtonBar.qml +++ b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailButtonBar.qml @@ -1,10 +1,11 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import Governikus.Global 1.0 +import Governikus.Style 1.0 import Governikus.Type.SettingsModel 1.0 @@ -19,16 +20,31 @@ Item { property string address: "" property color titleBarColor - Image { - id: icon - source: baseItem.providerIcon - asynchronous: true + Rectangle { + id: iconContainer + height: 2 * baseItem.height width: height - fillMode: Image.PreserveAspectFit + anchors.left: parent.left anchors.leftMargin: Constants.component_spacing anchors.verticalCenter: baseItem.top + + radius: Style.dimens.corner_radius + color: Constants.white + border.color: Style.color.border + border.width: Style.dimens.separator_size + + Image { + id: icon + + anchors.fill: parent + anchors.margins: iconContainer.radius / 2 + + source: baseItem.providerIcon + asynchronous: true + fillMode: Image.PreserveAspectFit + } } GButton { @@ -36,10 +52,9 @@ Item { //: LABEL ANDROID_TABLET IOS_TABLET text: qsTr("ONLINE APPLICATION") + SettingsModel.translationTrigger buttonColor: baseItem.titleBarColor - maxWidth: parent.width - icon.width - 3 * Constants.component_spacing - anchors.left: icon.right + anchors.left: iconContainer.right anchors.leftMargin: Constants.component_spacing - anchors.bottom: icon.bottom + anchors.bottom: iconContainer.bottom enabled: baseItem.address !== "" onClicked: { diff --git a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailDescription.qml b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailDescription.qml index bf38a8350..dff12e7ab 100644 --- a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailDescription.qml +++ b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailDescription.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistory.qml b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistory.qml index 640b1ded8..bc372a61b 100644 --- a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistory.qml +++ b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistory.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -33,6 +33,8 @@ Column { } Repeater { + id: historyItemRepeater + model: HistoryModel.nameFilter ProviderDetailHistoryItem { @@ -53,4 +55,14 @@ Column { openInfoFunction: baseItem.openHistoryInfoFunc } } + + GText { + visible: historyItemRepeater.count === 0 + width: parent.width + + activeFocusOnTab: true + + //: INFO ANDROID_TABLET IOS_TABLET No authentication history, placeholder text. + text: qsTr("Currently there are no history entries.") + SettingsModel.translationTrigger + } } diff --git a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistoryInfo.qml b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistoryInfo.qml index 34ceaa0f7..843da375c 100644 --- a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistoryInfo.qml +++ b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistoryInfo.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -61,7 +61,7 @@ Item { ProviderInfoSection { imageSource: "qrc:///images/provider/information.svg" //: LABEL ANDROID_TABLET IOS_TABLET - title: qsTr("Service provider") + SettingsModel.translationTrigger + title: qsTr("Provider") + SettingsModel.translationTrigger name: baseItem.providerName } diff --git a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistoryItem.qml b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistoryItem.qml index 0d3923953..28abacdee 100644 --- a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistoryItem.qml +++ b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailHistoryItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailView.qml b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailView.qml index a4eaf92bf..799ab4e8b 100644 --- a/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailView.qml +++ b/resources/qml/Governikus/Provider/+mobile/+tablet/ProviderDetailView.qml @@ -1,10 +1,12 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 +import Governikus.Style 1.0 import Governikus.Provider 1.0 import Governikus.TitleBar 1.0 import Governikus.View 1.0 @@ -58,13 +60,21 @@ SectionPage { anchors.verticalCenter: parent.verticalCenter } - Image { + Item { height: parent.height - width: height / 2 + width: image.width / 4 anchors.right: image.right anchors.top: parent.top - fillMode: Image.Stretch - source: Category.gradientImageSource(provider.category) + + LinearGradient { + anchors.fill: parent + start: Qt.point(0, 0) + end: Qt.point(parent.width, 0) + gradient: Gradient { + GradientStop { position: 0.0; color: Style.color.transparent } + GradientStop { position: 0.95; color: Category.displayColor(provider.category) } + } + } } Rectangle { diff --git a/resources/qml/Governikus/Provider/+mobile/ProviderContactTab.qml b/resources/qml/Governikus/Provider/+mobile/ProviderContactTab.qml index 5433b13ab..d8feb95c9 100644 --- a/resources/qml/Governikus/Provider/+mobile/ProviderContactTab.qml +++ b/resources/qml/Governikus/Provider/+mobile/ProviderContactTab.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.2 -import QtGraphicalEffects 1.10 +import QtQuick.Layouts 1.3 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -68,7 +68,6 @@ Item { textFormat: Text.RichText text: !!model.text ? model.text : qsTr("Unknown") + SettingsModel.translationTrigger verticalAlignment: Text.AlignVCenter - textStyle: Style.text.normal } MouseArea { diff --git a/resources/qml/Governikus/Provider/+mobile/ProviderHeader.qml b/resources/qml/Governikus/Provider/+mobile/ProviderHeader.qml index 63bb46435..63b8a3005 100644 --- a/resources/qml/Governikus/Provider/+mobile/ProviderHeader.qml +++ b/resources/qml/Governikus/Provider/+mobile/ProviderHeader.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -25,7 +25,6 @@ Rectangle { readonly property color shadowColor: Category.displayColor(selectedCategory) readonly property bool customProviderImage: !!selectedProvider && !!selectedProvider.image readonly property string backgroundImage: customProviderImage ? selectedProvider.image : Category.backgroundImageSource(selectedCategory) - readonly property string categoryIcon: selectedProvider || selectedCategory !== "all" ? "" : Category.imageSource(selectedCategory) readonly property bool withButtons: selectedCategory === "" && !selectedProvider readonly property real shadowOpacity: Math.min(1, headerOffsetY / (backgroundImage.height - Style.dimens.titlebar_height)) @@ -56,35 +55,32 @@ Rectangle { anchors.topMargin: -titleBarTopBounce // When flicking over the top, scale the image (similar to native iOS apps) fillMode: Image.PreserveAspectCrop - Image { - id: categoryIcon - source: baseItem.categoryIcon - asynchronous: true - height: parent.height * 0.5 - width: height - fillMode: Image.PreserveAspectFit - anchors.horizontalCenter: backgroundImage.horizontalCenter - anchors.bottom: backgroundImage.bottom - anchors.bottomMargin: Constants.component_spacing - - visible: baseItem.categoryIcon !== "" - - opacity: baseItem.headerOffsetY <= maxContentY ? 1 : 0 - Behavior on opacity { - NumberAnimation {} - } - } + Rectangle { + id: iconContainer - Image { - source: selectedProvider ? selectedProvider.icon : "" - asynchronous: true + visible: !!selectedProvider height: 70 width: height - fillMode: Image.PreserveAspectFit + anchors.margins: Constants.component_spacing anchors.left: parent.left anchors.bottom: parent.bottom - visible: !!selectedProvider + + radius: Style.dimens.corner_radius + color: Constants.white + border.color: Style.color.border + border.width: Style.dimens.separator_size + + Image { + id: icon + + anchors.fill: parent + anchors.margins: iconContainer.radius / 2 + + source: selectedProvider ? selectedProvider.icon : "" + asynchronous: true + fillMode: Image.PreserveAspectFit + } } } @@ -112,6 +108,9 @@ Rectangle { asynchronous: true anchors.fill: parent fillMode: Image.PreserveAspectFit + + Accessible.name: Category.displayString(modelData) + SettingsModel.translationTrigger + Accessible.role: Accessible.Button } MouseArea { @@ -140,6 +139,8 @@ Rectangle { visible: !!selectedProvider + color: Style.color.background_pane + Column { id: column anchors.margins: Constants.pane_padding @@ -152,7 +153,6 @@ Rectangle { id: providerText width: parent.width text: selectedProvider ? selectedProvider.shortDescription : "" - textStyle: Style.text.normal visible: text.length > 0 } @@ -161,7 +161,7 @@ Rectangle { anchors.right: parent.right buttonColor: shadowColor //: LABEL ANDROID IOS - text: qsTr("To service provider") + SettingsModel.translationTrigger + text: qsTr("To provider") + SettingsModel.translationTrigger onClicked: { Qt.openUrlExternally(selectedProvider ? selectedProvider.address : "") } diff --git a/resources/qml/Governikus/Provider/+mobile/ProviderInfoSection.qml b/resources/qml/Governikus/Provider/+mobile/ProviderInfoSection.qml index dc112d425..b9486071e 100644 --- a/resources/qml/Governikus/Provider/+mobile/ProviderInfoSection.qml +++ b/resources/qml/Governikus/Provider/+mobile/ProviderInfoSection.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -8,7 +8,7 @@ import Governikus.Global 1.0 import Governikus.Type.SettingsModel 1.0 -Rectangle { +Item { property string imageSource; property string title; @@ -17,7 +17,6 @@ Rectangle { width: parent.width height: Math.max(image.height, providerTitle.height) - color: Constants.white clip: true Image { diff --git a/resources/qml/Governikus/Provider/+mobile/ProviderModelItem.qml b/resources/qml/Governikus/Provider/+mobile/ProviderModelItem.qml index 2aabdae92..1b69abf22 100644 --- a/resources/qml/Governikus/Provider/+mobile/ProviderModelItem.qml +++ b/resources/qml/Governikus/Provider/+mobile/ProviderModelItem.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/ProviderView/+desktop/AdditionalResultsItem.qml b/resources/qml/Governikus/ProviderView/+desktop/AdditionalResultsItem.qml index 5f1c92238..a13f68c84 100644 --- a/resources/qml/Governikus/ProviderView/+desktop/AdditionalResultsItem.qml +++ b/resources/qml/Governikus/ProviderView/+desktop/AdditionalResultsItem.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Layouts 1.3 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -30,12 +30,12 @@ Item { anchors.fill: parent - layer.enabled: true + layer.enabled: GraphicsInfo.api !== GraphicsInfo.Software layer.effect: DropShadow { radius: 4 samples: 8 source: background - color: Qt.darker(Constants.grey, 1.2) + color: Style.color.shadow } } @@ -77,8 +77,6 @@ Item { //: LABEL DESKTOP_QML text: qsTr("Additional results in other categories:") + " " + baseItem.totalHits + SettingsModel.translationTrigger - - textStyle: Style.text.normal } GButton { @@ -97,5 +95,7 @@ Item { onClicked: baseItem.clicked() } - FocusFrame {} + FocusFrame { + borderColor: Style.color.focus_indicator + } } diff --git a/resources/qml/Governikus/ProviderView/+desktop/ProviderCard.qml b/resources/qml/Governikus/ProviderView/+desktop/ProviderCard.qml index ef201fbe0..ef25721cf 100644 --- a/resources/qml/Governikus/ProviderView/+desktop/ProviderCard.qml +++ b/resources/qml/Governikus/ProviderView/+desktop/ProviderCard.qml @@ -1,17 +1,18 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Window 2.10 import QtQuick.Layouts 1.3 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 import Governikus.Provider 1.0 import Governikus.Type.SettingsModel 1.0 import Governikus.View 1.0 +import Governikus.Type.ApplicationModel 1.0 Item { id: baseItem @@ -23,8 +24,10 @@ Item { Keys.onSpacePressed: mouseArea.clicked(undefined) Accessible.role: Accessible.Button - Accessible.name: qsTr("Provider:") + " " + (!!providerModelItem ? provider.shortName : qsTr("Unknown error")) + SettingsModel.translationTrigger - Accessible.description: qsTr("Provider description:") + " " + (!!providerModelItem ? provider.shortDescription : qsTr("Unknown error")) + SettingsModel.translationTrigger + Accessible.name: qsTr("Provider:") + " " + (!!providerModelItem ? provider.shortName : + qsTr("Unknown error")) + SettingsModel.translationTrigger + Accessible.description: qsTr("Provider description:") + " " + (!!providerModelItem ? provider.shortDescription : + qsTr("Unknown error")) + SettingsModel.translationTrigger ProviderModelItem { id: provider @@ -48,7 +51,7 @@ Item { asynchronous: true fillMode: Image.PreserveAspectCrop - layer.enabled: true + layer.enabled: GraphicsInfo.api !== GraphicsInfo.Software layer.effect: OpacityMask { maskSource: Item { width: image.width @@ -69,7 +72,7 @@ Item { width: baseItem.width height: Math.floor(baseItem.width * 0.2) - color: Constants.white + color: Style.color.background_pane GText { id: nameText @@ -85,7 +88,7 @@ Item { elide: Text.ElideRight maximumLineCount: 2 - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal } } @@ -94,10 +97,21 @@ Item { height: Math.floor(baseItem.width * 0.08) radius: Style.dimens.corner_radius - color: Category.displayColor(provider.category) + color: Style.currentTheme.highContrast ? Style.color.background_pane : Category.displayColor(provider.category) topLeftCorner: false topRightCorner: false + GSeparator { + anchors { + top: parent.top + left: parent.left + right: parent.right + } + + height: Style.dimens.high_contrast_item_border + color: Style.color.high_contrast_item_border + } + GText { id: providerText @@ -112,11 +126,19 @@ Item { elide: Text.ElideRight maximumLineCount: 1 - textStyle: Style.text.hint + textStyle: Style.text.hint_inverse } } } + RoundedRectangle { + anchors.fill: column + + color: Style.color.transparent + borderColor: Style.color.border + borderWidth: ApplicationModel.scaleFactor * 1 + } + MouseArea { id: mouseArea @@ -127,9 +149,8 @@ Item { } FocusFrame { - dynamic: false marginFactor: 2 radius: Style.dimens.corner_radius - border.color: Constants.black + borderColor: Style.color.focus_indicator } } diff --git a/resources/qml/Governikus/ProviderView/+desktop/ProviderOverview.qml b/resources/qml/Governikus/ProviderView/+desktop/ProviderOverview.qml index cae3bf088..631e17a8d 100644 --- a/resources/qml/Governikus/ProviderView/+desktop/ProviderOverview.qml +++ b/resources/qml/Governikus/ProviderView/+desktop/ProviderOverview.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -84,7 +84,7 @@ SectionPage { height: tabbedPane.availableHeight width: parent.width - GridView { + GGridView { id: gridView property int columns: Math.floor(width / (ApplicationModel.scaleFactor * 400)) @@ -108,14 +108,11 @@ SectionPage { highlightFollowsCurrentItem: true highlight: null activeFocusOnTab: true + scrollBarTopPadding: spacing / 2 + scrollBarBottomPadding: spacing / 2 model: ProviderCategoryFilterModel - boundsBehavior: Flickable.StopAtBounds - ScrollBar.vertical: ScrollBar { - policy: size === 1.0 ? ScrollBar.AlwaysOff : ScrollBar.AlwaysOn - } - delegate: Item { width: gridView.cellWidth height: gridView.cellHeight @@ -124,7 +121,7 @@ SectionPage { anchors.fill: parent anchors.margins: Math.floor(gridView.spacing / 2) - focus: gridView.currentIndex === index + focus: gridView.activeFocus && gridView.currentIndex === index providerModelItem: model onShowDetailView: baseItem.showDetailView(pModelItem) @@ -133,7 +130,10 @@ SectionPage { Connections { target: ProviderCategoryFilterModel - onFireCriteriaChanged: gridView.contentY = gridView.originY + onFireCriteriaChanged: { + gridView.currentIndex = 0 + gridView.contentY = gridView.originY + } } } @@ -155,17 +155,20 @@ SectionPage { activeFocusOnTab: true - onActiveFocusChanged: { - if (activeFocus) { - gridView.positionViewAtIndex(index, GridView.Center) - } - } - onClicked: { ProviderCategoryFilterModel.setCategorySelection("all") tabbedPane.currentIndex = 0 } } + + GText { + visible: ProviderCategoryFilterModel.rowCount === 0 && !additionalResults.visible + + anchors.centerIn: parent + //: LABEL DESKTOP_QML The text entered into the provider search field results in no matches + text: qsTr("No results matching your search query found") + SettingsModel.translationTrigger + textStyle: Style.text.normal + } } } } diff --git a/resources/qml/Governikus/ProviderView/+desktop/ProviderView.qml b/resources/qml/Governikus/ProviderView/+desktop/ProviderView.qml index b8ca54ada..ebe6e2301 100644 --- a/resources/qml/Governikus/ProviderView/+desktop/ProviderView.qml +++ b/resources/qml/Governikus/ProviderView/+desktop/ProviderView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -36,14 +36,19 @@ SectionPage { titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML text: qsTr("Provider") + SettingsModel.translationTrigger - helpTopic: "providerPage" + helpTopic: "provider" onClicked: { d.activeView = ProviderView.SubViews.None } customSubAction: SearchBar { + anchors.verticalCenter: parent ? parent.verticalCenter : undefined + onDisplayTextChanged: ProviderCategoryFilterModel.searchString = displayText + + //: LABEL DESKTOP_QML + placeholderText: qsTr("Search providers") + SettingsModel.translationTrigger } } @@ -71,6 +76,8 @@ SectionPage { visible: d.activeView === ProviderView.SubViews.None + Component.onCompleted: setActive() + activeFocusOnTab: true onNextView: baseItem.nextView(pName) diff --git a/resources/qml/Governikus/ProviderView/+mobile/+android/+phone/ProviderView.qml b/resources/qml/Governikus/ProviderView/+mobile/+android/+phone/ProviderView.qml index 8cb958315..439d32e23 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+android/+phone/ProviderView.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+android/+phone/ProviderView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/ProviderView/+mobile/+android/+tablet/ProviderView.qml b/resources/qml/Governikus/ProviderView/+mobile/+android/+tablet/ProviderView.qml index 0e855e327..bfff0c4d8 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+android/+tablet/ProviderView.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+android/+tablet/ProviderView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -126,9 +126,9 @@ SectionPage { id: noResultsText anchors.centerIn: mainPane - //: LABEL ANDROID_TABLET - text: qsTr("No match found") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary + //: LABEL ANDROID_TABLET The text entered into the provider search field results in no matches + text: qsTr("No results matching your search query found") + SettingsModel.translationTrigger + textStyle: Style.text.normal visible: !flickable.visible } diff --git a/resources/qml/Governikus/ProviderView/+mobile/+ios/+phone/ProviderView.qml b/resources/qml/Governikus/ProviderView/+mobile/+ios/+phone/ProviderView.qml index 5ae542316..d7db03e27 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+ios/+phone/ProviderView.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+ios/+phone/ProviderView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/ProviderView/+mobile/+ios/+tablet/ProviderView.qml b/resources/qml/Governikus/ProviderView/+mobile/+ios/+tablet/ProviderView.qml index 7993d9d10..efc4375cd 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+ios/+tablet/ProviderView.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+ios/+tablet/ProviderView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -128,9 +128,9 @@ SectionPage { id: noResultsText anchors.centerIn: mainPane - //: LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein Ergebnis - text: qsTr("No match found") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary + //: LABEL IOS_TABLET The text entered into the provider search field results in no matches + text: qsTr("No results matching your search query found") + SettingsModel.translationTrigger + textStyle: Style.text.normal visible: !flickable.visible } diff --git a/resources/qml/Governikus/ProviderView/+mobile/+phone/AdditionalResultsItem.qml b/resources/qml/Governikus/ProviderView/+mobile/+phone/AdditionalResultsItem.qml index 62c851c7c..7c4e9dae4 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+phone/AdditionalResultsItem.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+phone/AdditionalResultsItem.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -20,7 +20,7 @@ ListItem { icon: Category.imageSource("all") text: qsTr("Additional results:") + ' ' + totalHits + SettingsModel.translationTrigger - showRightArrow: false + showLinkIcon: false showSeparator: false onClicked: ProviderCategoryFilterModel.setCategorySelection("") diff --git a/resources/qml/Governikus/ProviderView/+mobile/+phone/BaseProviderView.qml b/resources/qml/Governikus/ProviderView/+mobile/+phone/BaseProviderView.qml index ba9482bc7..b85b72228 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+phone/BaseProviderView.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+phone/BaseProviderView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -55,9 +55,9 @@ SectionPage { GText { anchors.centerIn: parent - //: LABEL IOS_PHONE ANDROID_PHONE Der in das Suchfeld eingegebene String erzielte kein Ergebnis - text: qsTr("No match found") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary + //: LABEL IOS_PHONE ANDROID_PHONE The text entered into the provider search field results in no matches + text: qsTr("No results matching your search query found") + SettingsModel.translationTrigger + textStyle: Style.text.normal } } diff --git a/resources/qml/Governikus/ProviderView/+mobile/+phone/ProviderListItemDelegate.qml b/resources/qml/Governikus/ProviderView/+mobile/+phone/ProviderListItemDelegate.qml index 0c81c0fed..0ae3915a0 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+phone/ProviderListItemDelegate.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+phone/ProviderListItemDelegate.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Type.SettingsModel 1.0 diff --git a/resources/qml/Governikus/ProviderView/+mobile/+phone/ProviderSectionDelegate.qml b/resources/qml/Governikus/ProviderView/+mobile/+phone/ProviderSectionDelegate.qml index e99ead501..3cc3f99a4 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+phone/ProviderSectionDelegate.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+phone/ProviderSectionDelegate.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Type.SettingsModel 1.0 diff --git a/resources/qml/Governikus/ProviderView/+mobile/+tablet/AdditionalResultsItem.qml b/resources/qml/Governikus/ProviderView/+mobile/+tablet/AdditionalResultsItem.qml index 1319c7727..fa32ea600 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+tablet/AdditionalResultsItem.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+tablet/AdditionalResultsItem.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -39,18 +39,6 @@ Rectangle { width: parent.width fillMode: Image.PreserveAspectCrop anchors.horizontalCenter: parent.horizontalCenter - - Image { - id: icon - source: Category.imageSource("all") - asynchronous: true - height: backgroundImage.height * 0.5 - width: height - fillMode: Image.PreserveAspectFit - anchors.horizontalCenter: backgroundImage.horizontalCenter - anchors.bottom: backgroundImage.bottom - anchors.bottomMargin: 20 - } } Rectangle { @@ -65,7 +53,6 @@ Rectangle { //: LABEL ANDROID_TABLET IOS_TABLET text: '' + qsTr("Additional results:") + " " + baseItem.totalHits + '' + SettingsModel.translationTrigger - textStyle: Style.text.normal } } diff --git a/resources/qml/Governikus/ProviderView/+mobile/+tablet/CategoryCheckbox.qml b/resources/qml/Governikus/ProviderView/+mobile/+tablet/CategoryCheckbox.qml index e5fbf3c60..987f0a7cc 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+tablet/CategoryCheckbox.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+tablet/CategoryCheckbox.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -46,8 +46,6 @@ Item { anchors.verticalCenter: parent.verticalCenter Accessible.ignored: true - - textStyle: Style.text.normal } GCheckBox { diff --git a/resources/qml/Governikus/ProviderView/+mobile/+tablet/ProviderCard.qml b/resources/qml/Governikus/ProviderView/+mobile/+tablet/ProviderCard.qml index a01dbb407..3b633821a 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+tablet/ProviderCard.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+tablet/ProviderCard.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 diff --git a/resources/qml/Governikus/ProviderView/+mobile/+tablet/ProviderCardNameRow.qml b/resources/qml/Governikus/ProviderView/+mobile/+tablet/ProviderCardNameRow.qml index 2f93dc50c..07269e76c 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/+tablet/ProviderCardNameRow.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/+tablet/ProviderCardNameRow.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -21,8 +21,8 @@ Rectangle { Image { id: image source: parent.headerIcon !== "" ? - parent.headerIcon : - Category.buttonImageSource(parent.providerCategory) + parent.headerIcon : (parent.providerCategory !== "" ? + Category.buttonImageSource(parent.providerCategory) : Category.buttonImageSource("all")) asynchronous: true height: parent.height width: height diff --git a/resources/qml/Governikus/ProviderView/+mobile/ProviderDelegateModel.qml b/resources/qml/Governikus/ProviderView/+mobile/ProviderDelegateModel.qml index 49c0330cd..85ab4a868 100644 --- a/resources/qml/Governikus/ProviderView/+mobile/ProviderDelegateModel.qml +++ b/resources/qml/Governikus/ProviderView/+mobile/ProviderDelegateModel.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQml.Models 2.2 diff --git a/resources/qml/Governikus/RemoteServiceView/+mobile/DevicesListDelegate.qml b/resources/qml/Governikus/RemoteServiceView/+mobile/DevicesListDelegate.qml new file mode 100644 index 000000000..19c5e5083 --- /dev/null +++ b/resources/qml/Governikus/RemoteServiceView/+mobile/DevicesListDelegate.qml @@ -0,0 +1,59 @@ +/* + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.Type.SettingsModel 1.0 + + +MouseArea { + property alias title: titleText.text + property alias description: descriptionText.text + property alias linkQuality: linkQualityItem.percent + property alias linkInactive: linkQualityItem.inactive + + height: content.implicitHeight + width: content.implicitWidth + + Accessible.role: Accessible.ListItem + Accessible.name: qsTr("Device %1").arg(title) + SettingsModel.translationTrigger + Accessible.description: description + Accessible.onPressAction: if (Qt.platform.os === "ios") clicked(null) + + RowLayout { + id: content + + anchors.fill: parent + spacing: Constants.groupbox_spacing + + ColumnLayout { + Layout.fillWidth: true + spacing: 2 + + GText { + id: titleText + + Layout.fillWidth: true + + textStyle: Style.text.normal_accent + } + + GText { + id: descriptionText + + Layout.fillWidth: true + + textStyle: Style.text.hint_secondary + } + } + + LinkQuality { + id: linkQualityItem + } + } +} diff --git a/resources/qml/Governikus/RemoteServiceView/+mobile/RemoteServiceView.qml b/resources/qml/Governikus/RemoteServiceView/+mobile/RemoteServiceView.qml new file mode 100644 index 000000000..54a00844e --- /dev/null +++ b/resources/qml/Governikus/RemoteServiceView/+mobile/RemoteServiceView.qml @@ -0,0 +1,242 @@ +/* + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.TitleBar 1.0 +import Governikus.Style 1.0 +import Governikus.View 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.Type.RemoteServiceModel 1.0 + + +SectionPage { + id: baseItem + + readonly property string currentPin: RemoteServiceModel.psk.toString() + readonly property bool isPairing: RemoteServiceModel.running && currentPin !== "" + + navigationAction: NavigationAction { + state: RemoteServiceModel.running ? "cancel" : "" + onClicked: { + RemoteServiceModel.setPairing(false) + RemoteServiceModel.running = false + } + } + + //: LABEL ANDROID IOS + title: qsTr("Remote service") + SettingsModel.translationTrigger + + Connections { + target: RemoteServiceModel + //: ERROR ANDROID IOS An error occurred while pairing the device. + onFirePairingFailed: ApplicationModel.showFeedback(qsTr("Pairing failed. Please start a new pairing process on your other device and enter the shown pairing code.")) + } + + RemoteServiceController { + id: controller + } + + content: Item { + implicitHeight: baseItem.height + implicitWidth: baseItem.width + + ColumnLayout { + height: parent.height - 2 * Constants.pane_padding + width: Math.min(parent.width - 2 * Constants.pane_padding, Style.dimens.max_text_width) + anchors.centerIn: parent + + spacing: Constants.pane_spacing + + Image { + Layout.fillWidth: true + Layout.maximumHeight: width * (sourceSize.height / sourceSize.width) + + source: "qrc:///images/phone_to_pc.svg" + fillMode: Image.PreserveAspectFit + } + + RowLayout { + Layout.fillWidth: true + + spacing: Constants.text_spacing + + TintableIcon { + source: "qrc:/images/info_filled.svg" + sourceSize.width: Style.dimens.small_icon_size + tintColor: Style.text.normal_secondary.textColor + } + + GText { + Layout.fillWidth: true + + //: INFO ANDROID IOS The remote service is active. Hint that both devices need to be connected to the same network. + text: qsTr("Both of your devices have to be connected to the same WiFi.") + SettingsModel.translationTrigger + textStyle: Style.text.normal_secondary + } + } + + GButton { + id: startButton + + property bool serviceIsStarting: false + readonly property bool running: RemoteServiceModel.running + readonly property bool canEnableNfc: RemoteServiceModel.canEnableNfc + + Layout.preferredWidth: Math.max(pairingButton.implicitWidth, startButton.implicitWidth) + Layout.alignment: Qt.AlignHCenter + + buttonColor: running ? Constants.red : Constants.darkgreen + enabled: (canEnableNfc || RemoteServiceModel.runnable || running) && !serviceIsStarting + text: { + SettingsModel.translationTrigger; // Bind this evaluation to the trigger. + + if (canEnableNfc) { + //: LABEL ANDROID IOS + return qsTr("Enable NFC"); + } else if (running) { + //: LABEL ANDROID IOS + return qsTr("Stop remote service"); + } else { + //: LABEL ANDROID IOS + return qsTr("Start remote service"); + } + } + onClicked: { + if (canEnableNfc) { + ApplicationModel.showSettings(ApplicationModel.SETTING_NFC) + } else { + if (!running) { + serviceIsStarting = true + } else { + RemoteServiceModel.setPairing(false) + } + RemoteServiceModel.running = !running + } + } + onRunningChanged: { + serviceIsStarting = false + navBar.lockedAndHidden = running + } + } + + GButton { + id: pairingButton + + visible: opacity > 0 + Layout.preferredWidth: Math.max(pairingButton.implicitWidth, startButton.implicitWidth) + Layout.alignment: Qt.AlignHCenter + + opacity: 0 + text: (isPairing ? + //: LABEL ANDROID IOS + qsTr("Stop pairing") : + //: LABEL ANDROID IOS + qsTr("Start pairing") + ) + SettingsModel.translationTrigger + onClicked: RemoteServiceModel.setPairing(!isPairing) + } + + GText { + id: pairingCode + + visible: isPairing && opacity > 0 + Layout.fillWidth: true + + //: LABEL ANDROID IOS + Accessible.name: qsTr("Pairing code: %1").arg(currentPin.split("").join(" ")) + SettingsModel.translationTrigger; + + //: LABEL ANDROID IOS + text: qsTr("Pairing code: %1").arg(currentPin) + SettingsModel.translationTrigger + textStyle: Style.text.header_accent + horizontalAlignment: Text.AlignHCenter + } + + Item {/*spacer*/ Layout.fillHeight: true } + + GText { + visible: !RemoteServiceModel.runnable + Layout.fillWidth: true + + text: RemoteServiceModel.errorMessage + textStyle: Style.text.normal_warning + horizontalAlignment: Text.AlignHCenter + } + + GText { + id: infoMessage + + visible: RemoteServiceModel.runnable && opacity > 0 + Layout.fillWidth: true + + text: isPairing ? + //: INFO ANDROID IOS + qsTr("Enter this code on your other device to use your smartphone as a card reader (SaC)") + //: INFO ANDROID IOS + : RemoteServiceModel.running ? qsTr("Waiting for connection from a paired device...") + //: INFO ANDROID IOS + : qsTr("Start the remote access, in order to make this smartphone visible and to use it as a card reader (SaC)") + SettingsModel.translationTrigger + textStyle: Style.text.normal_secondary + horizontalAlignment: Text.AlignHCenter + } + + GText { + id: headText + + visible: opacity > 0 + Layout.fillWidth: true + + opacity: 0 + //: LABEL ANDROID IOS + text: qsTr("Card access in progress") + SettingsModel.translationTrigger; + textStyle: Style.text.header_accent + horizontalAlignment: Text.AlignHCenter + } + + GText { + id: subText + + visible: opacity > 0 + Layout.fillWidth: true + + opacity: 0 + text: RemoteServiceModel.connectionInfo + textStyle: Style.text.normal_secondary + horizontalAlignment: Text.AlignHCenter + } + + states: [ + State { name: "UNCONNECTED"; when: RemoteServiceModel.running && !RemoteServiceModel.connectedToPairedDevice + PropertyChanges { target: pairingButton; opacity: 1 } + PropertyChanges { target: pairingCode; opacity: 1 } + PropertyChanges { target: infoMessage; opacity: 1 } + PropertyChanges { target: headText; opacity: 0 } + PropertyChanges { target: subText; opacity: 0 } + PropertyChanges { target: ApplicationModel; nfcRunning: false; restoreEntryValues: false } + }, + State { name: "CONNECTED"; when: RemoteServiceModel.running && RemoteServiceModel.connectedToPairedDevice + PropertyChanges { target: pairingButton; opacity: 0 } + PropertyChanges { target: pairingCode; opacity: 0 } + PropertyChanges { target: infoMessage; opacity: 0 } + PropertyChanges { target: headText; opacity: 1 } + PropertyChanges { target: subText; opacity: 1 } + PropertyChanges { target: ApplicationModel; nfcRunning: true; restoreEntryValues: false } + } + ] + transitions: [ + Transition { + NumberAnimation { + property: "opacity" + duration: Constants.animation_duration + easing.type: Easing.InOutQuad + } + } + ] + } + } +} diff --git a/resources/qml/Governikus/RemoteServiceView/+mobile/RemoteServiceViewRemote.qml b/resources/qml/Governikus/RemoteServiceView/+mobile/RemoteServiceViewRemote.qml new file mode 100644 index 000000000..3c547b439 --- /dev/null +++ b/resources/qml/Governikus/RemoteServiceView/+mobile/RemoteServiceViewRemote.qml @@ -0,0 +1,163 @@ +/* + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 + +import Governikus.EnterPasswordView 1.0 +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.TitleBar 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.Type.RemoteServiceModel 1.0 + + +Item { + id: baseItem + height: mainColumn.height + + Column { + id: mainColumn + width: baseItem.width + leftPadding: Constants.pane_padding + rightPadding: Constants.pane_padding + spacing: Constants.component_spacing + + readonly property int usableWidth: width - leftPadding - rightPadding + Column { + width: parent.usableWidth + + spacing: Constants.component_spacing + + TitledSeparator { + width: parent.width + //: LABEL ANDROID IOS + title: qsTr("Paired devices") + SettingsModel.translationTrigger + } + + GText { + width: parent.width + visible: !knownDeviceList.visible + + Accessible.role: Accessible.StaticText + Accessible.name: text + + //: LABEL ANDROID IOS + text: qsTr("No device is paired.") + SettingsModel.translationTrigger + textStyle: Style.text.normal_secondary + } + + ListView { + id: knownDeviceList + width: parent.width + height: childrenRect.height + spacing: Constants.component_spacing + model: RemoteServiceModel.knownDevices + delegate: DevicesListDelegate { + width: knownDeviceList.width + + title: remoteDeviceName + //: LABEL ANDROID IOS + description: qsTr("Click to remove device") + SettingsModel.translationTrigger + linkQuality: linkQualityInPercent + linkInactive: !isNetworkVisible + + onClicked: { + deleteDevicePopup.deviceId = deviceId + deleteDevicePopup.deviceName = remoteDeviceName + deleteDevicePopup.open() + } + } + visible: count > 0 + interactive: false + } + } + + ConfirmationPopup { + id: deleteDevicePopup + + property var deviceId + property string deviceName + + //: INFO ANDROID IOS + title: qsTr("Remove pairing") + SettingsModel.translationTrigger + //: INFO ANDROID IOS + text: qsTr("Do you want to remove the pairing of the device \"%1\"?").arg(deviceName) + SettingsModel.translationTrigger + //: INFO ANDROID IOS + okButtonText: qsTr("Remove") + SettingsModel.translationTrigger + onConfirmed: RemoteServiceModel.forgetDevice(deviceId) + } + + Column { + width: parent.usableWidth + + spacing: Constants.component_spacing + + TitledSeparator { + width: parent.width + //: LABEL ANDROID IOS + title: qsTr("Available devices") + SettingsModel.translationTrigger + } + + GText { + width: parent.width + visible: !searchDeviceList.visible + + Accessible.role: Accessible.StaticText + Accessible.name: text + + //: INFO ANDROID IOS No SaC was found on the network, both devices need to be connected to the same wifi network. + text: qsTr("No unpaired smartphone as card reader (SaC) available. Please make sure that the smartphone as card reader (SaC) functionality in AusweisApp2 on your other device is activated an that both devices are connected to the same WiFi.") + SettingsModel.translationTrigger + textStyle: Style.text.normal_secondary + } + + ListView { + id: searchDeviceList + width: parent.width + height: childrenRect.height + model: RemoteServiceModel.availableRemoteDevices + spacing: Constants.component_spacing + delegate: DevicesListDelegate { + width: searchDeviceList.width + + title: remoteDeviceName + (isSupported ? "" : (" (" + remoteDeviceStatus + ")")) + //: LABEL ANDROID IOS + description: qsTr("Click to pair") + SettingsModel.translationTrigger + linkQuality: linkQualityInPercent + + onClicked: { + if (isSupported && RemoteServiceModel.rememberServer(deviceId)) { + informationPairingPopup.open() + } + } + } + visible: count > 0 + interactive: false + } + } + } + + ConfirmationPopup { + id: informationPairingPopup + + style: ConfirmationPopup.PopupStyle.OkButton + //: INFO ANDROID IOS + title: qsTr("Pairing mode") + SettingsModel.translationTrigger + //: INFO ANDROID IOS Information dialog that requests the user to start the pairing mode on the smarthpone. + text: qsTr("Start the pairing mode on your smartphone if you haven't done it already.") + SettingsModel.translationTrigger + onConfirmed: firePush(enterPinView) + } + + Component { + id: enterPinView + + EnterPasswordView { + state: "REMOTE_PIN" + navigationAction: NavigationAction { state: "cancel"; onClicked: { firePop() } } + //: LABEL ANDROID IOS + title: qsTr("Pairing code") + SettingsModel.translationTrigger + onPasswordEntered: firePop() + } + } +} diff --git a/resources/qml/Governikus/RemoteServiceView/AvailableDevicesListDelegate.qml b/resources/qml/Governikus/RemoteServiceView/AvailableDevicesListDelegate.qml deleted file mode 100644 index d04bab795..000000000 --- a/resources/qml/Governikus/RemoteServiceView/AvailableDevicesListDelegate.qml +++ /dev/null @@ -1,80 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.1 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.Type.SettingsModel 1.0 - - -MouseArea { - signal requestPairing(string pDeviceId) - - height: textColumn.height + separator.height + (Constants.groupbox_spacing / 2) - - Accessible.role: Accessible.ListItem - Accessible.name: qsTr("Device %1 is available for pairing").arg(nameText.text) + SettingsModel.translationTrigger - Accessible.onPressAction: if (Qt.platform.os === "ios" && isSupported) clicked(null) - - onClicked: if (isSupported) requestPairing(deviceId) - - LinkQuality { - id: linkQual - - height: nameText.height - width: height - anchors.verticalCenter: parent.verticalCenter - - percent: linkQualityInPercent - } - - Column { - id: textColumn - - width: parent.width - linkQual.width - anchors.leftMargin - anchors.left: linkQual.right - anchors.leftMargin: Constants.component_spacing - - spacing: 2 - topPadding: spacing - bottomPadding: spacing - - GText { - id: nameText - - width: parent.width - - text: { - SettingsModel.translationTrigger - - if (isSupported) { - return remoteDeviceName; - } - return remoteDeviceName + " (" + remoteDeviceStatus + ")" - } - textStyle: Style.text.normal_secondary - } - - GText { - id: dateText - - width: parent.width - - //: LABEL ANDROID IOS - text: (linkQualityInPercent >= 50 ? qsTr("Great quality") : qsTr("Bad quality")) + SettingsModel.translationTrigger - textStyle: Style.text.hint_secondary - } - } - - GSeparator { - id: separator - - width: parent.width - anchors.bottom: parent.bottom - color: Style.color.border_dark - } -} diff --git a/resources/qml/Governikus/RemoteServiceView/KnownDevicesListDelegate.qml b/resources/qml/Governikus/RemoteServiceView/KnownDevicesListDelegate.qml deleted file mode 100644 index a31592eb2..000000000 --- a/resources/qml/Governikus/RemoteServiceView/KnownDevicesListDelegate.qml +++ /dev/null @@ -1,105 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Layouts 1.1 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.Type.SettingsModel 1.0 -import Governikus.Type.RemoteServiceModel 1.0 - - -Item { - id: root - - height: textColumn.height + separator.height + (Constants.groupbox_spacing / 2) - - Accessible.role: Accessible.ListItem - Accessible.name: qsTr("Device %1 has status %2").arg(nameText.text).arg(statusText.text) + SettingsModel.translationTrigger - Accessible.onPressAction: if (Qt.platform === "ios") iconClick.clicked(null) - - LinkQuality { - id: linkQual - - height: nameText.height - anchors.verticalCenter: textColumn.verticalCenter - - percent: linkQualityInPercent - inactive: !isNetworkVisible - } - - Column { - id: textColumn - - width: parent.width - linkQual.width - iconClick.width - 2 * anchors.leftMargin - anchors.left: linkQual.right - anchors.right: deleteIcon.left - anchors.margins: Constants.component_spacing - - spacing: 2 - topPadding: spacing - bottomPadding: spacing - - GText { - id: nameText - - width: parent.width - - text: remoteDeviceName - textStyle: Style.text.normal_secondary - } - - GText { - id: statusText - - width: parent.width - - text: { - SettingsModel.translationTrigger - - if (!isNetworkVisible) { - //: LABEL ANDROID IOS - return qsTr("Not available"); - } - //: LABEL ANDROID IOS - return remoteDeviceStatus + ", " + (linkQualityInPercent >= 50 ? qsTr("Great quality") : qsTr("Bad quality")) + SettingsModel.translationTrigger - } - textStyle: Style.text.hint_secondary - } - - GText { - width: parent.width - - //: LABEL ANDROID IOS - text: qsTr("Last connection:") + " " + lastConnected + SettingsModel.translationTrigger - textStyle: Style.text.hint_secondary - } - } - - Image { - id: deleteIcon - - sourceSize.width: Style.dimens.small_icon_size - anchors.right: root.right - anchors.verticalCenter: root.verticalCenter - source: "qrc:///images/iOS/search_cancel.svg" - - MouseArea { - id: iconClick - - anchors.fill: parent - - onClicked: RemoteServiceModel.forgetDevice(deviceId) - } - } - - GSeparator { - id: separator - - width: parent.width - anchors.bottom: root.bottom - color: Style.color.border_dark - } -} diff --git a/resources/qml/Governikus/RemoteServiceView/LinkQuality.qml b/resources/qml/Governikus/RemoteServiceView/LinkQuality.qml index 591171478..cb593d924 100644 --- a/resources/qml/Governikus/RemoteServiceView/LinkQuality.qml +++ b/resources/qml/Governikus/RemoteServiceView/LinkQuality.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -13,7 +13,7 @@ Image { property bool inactive: false fillMode: Image.PreserveAspectFit - sourceSize.width: Style.dimens.small_icon_size + sourceSize.width: Style.dimens.icon_size source: { if (inactive) { return "qrc:///images/icon_remote_inactive.svg" diff --git a/resources/qml/Governikus/RemoteServiceView/RemoteServiceController.qml b/resources/qml/Governikus/RemoteServiceView/RemoteServiceController.qml index 5a41b3c55..ef5ccbb7f 100644 --- a/resources/qml/Governikus/RemoteServiceView/RemoteServiceController.qml +++ b/resources/qml/Governikus/RemoteServiceView/RemoteServiceController.qml @@ -1,8 +1,9 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 +import QtQuick.Controls 2.10 import Governikus.Type.RemoteServiceModel 1.0 import Governikus.EnterPasswordView 1.0 @@ -55,33 +56,41 @@ Item { function setWorkflowStateAndRequestInput(pState, pEnterPinState) { setWorkflowState(pState) if (RemoteServiceModel.isBasicReader && RemoteServiceModel.pinPadModeOn()) { - enterPinView.state = pEnterPinState - firePush(enterPinView) + firePushWithProperties(enterPinView, {state: pEnterPinState}) ApplicationModel.nfcRunning = false } else { RemoteServiceModel.continueWorkflow() } } - EnterPasswordView { + Component { id: enterPinView - visible: false - enableTransportPinLink: RemoteServiceModel.isSaCPinChangeWorkflow - navigationAction: NavigationAction { - state: "cancel" - onClicked: { + EnterPasswordView { + id: passwordView + + enableTransportPinLink: RemoteServiceModel.isSaCPinChangeWorkflow + + navigationAction: NavigationAction { + state: "cancel" + onClicked: { + firePop() + RemoteServiceModel.cancelPasswordRequest() + } + } + + onPasswordEntered: { firePop() - RemoteServiceModel.cancelPasswordRequest() + RemoteServiceModel.continueWorkflow() + ApplicationModel.nfcRunning = true } - } - onPasswordEntered: { - firePop() - RemoteServiceModel.continueWorkflow() - ApplicationModel.nfcRunning = true - } + onChangePinLength: NumberModel.requestTransportPin = !NumberModel.requestTransportPin - onChangePinLength: NumberModel.requestTransportPin = !NumberModel.requestTransportPin + Connections { + target: RemoteServiceModel + onFireConnectedChanged: if (!pConnected && passwordView.StackView.visible) firePop() + } + } } } diff --git a/resources/qml/Governikus/RemoteServiceView/RemoteServicePairingPopup.qml b/resources/qml/Governikus/RemoteServiceView/RemoteServicePairingPopup.qml deleted file mode 100644 index cb4fe71d2..000000000 --- a/resources/qml/Governikus/RemoteServiceView/RemoteServicePairingPopup.qml +++ /dev/null @@ -1,43 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.3 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.Type.SettingsModel 1.0 -import Governikus.Type.RemoteServiceModel 1.0 - -ConfirmationPopup { - id: popup - - property alias pin: name.text - property var deviceId - - style: ConfirmationPopup.PopupStyle.NoButtons - //: INFO ANDROID IOS Header of the pairing dialog when using the smartphone as card reader - title: qsTr("Pairing code") + SettingsModel.translationTrigger - //: INFO ANDROID IOS Main text of the pairing dialog when using the smartphone as card reader. - text: qsTr("Enter this code on your other device to use this device as a card reader") + SettingsModel.translationTrigger - - TextField { - id: name - - width: parent.width - - Accessible.role: Accessible.StaticText - Accessible.name: displayText - Accessible.description: qsTr("Click to close dialog") + SettingsModel.translationTrigger - Accessible.onPressAction: if (Qt.platform.os === "ios") popup.close() - - focus: true - horizontalAlignment: Text.AlignHCenter - font.letterSpacing: 5 - font.pixelSize: 50 - font.bold: true - readOnly: true - } -} diff --git a/resources/qml/Governikus/RemoteServiceView/RemoteServiceSettings.qml b/resources/qml/Governikus/RemoteServiceView/RemoteServiceSettings.qml index 007196188..b8b74f49d 100644 --- a/resources/qml/Governikus/RemoteServiceView/RemoteServiceSettings.qml +++ b/resources/qml/Governikus/RemoteServiceView/RemoteServiceSettings.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.1 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.TitleBar 1.0 @@ -20,7 +20,5 @@ SectionPage { content: RemoteServiceViewRemote { width: rootPage.width - visible: true - parentSectionPage: rootPage } } diff --git a/resources/qml/Governikus/RemoteServiceView/RemoteServiceView.qml b/resources/qml/Governikus/RemoteServiceView/RemoteServiceView.qml deleted file mode 100644 index f0cfaf999..000000000 --- a/resources/qml/Governikus/RemoteServiceView/RemoteServiceView.qml +++ /dev/null @@ -1,95 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.3 - -import Governikus.Global 1.0 -import Governikus.TitleBar 1.0 -import Governikus.View 1.0 -import Governikus.Type.ApplicationModel 1.0 -import Governikus.Type.SettingsModel 1.0 -import Governikus.Type.RemoteServiceModel 1.0 - - -SectionPage { - id: baseItem - - navigationAction: NavigationAction { - state: RemoteServiceModel.running ? "cancel" : "" - onClicked: RemoteServiceModel.running = false - } - - //: LABEL ANDROID IOS - title: sectionSwitch.selectedSection === "LOCAL" ? qsTr("Configure local settings") + SettingsModel.translationTrigger - //: LABEL ANDROID IOS - : sectionSwitch.selectedSection === "REMOTE" ? qsTr("Pair remote devices")+ SettingsModel.translationTrigger - //: LABEL ANDROID IOS - : qsTr("Remote service") + SettingsModel.translationTrigger - - Connections { - target: RemoteServiceModel - //: ERROR ANDROID IOS An error occurred while pairing the device. - onFirePairingFailed: ApplicationModel.showFeedback(qsTr("Pairing failed. Please try again to activate pairing on your other device and enter the shown pairing code.")) - } - - onVisibleChanged: { - if (visible && sectionSwitch.selectedSection === "REMOTE" && !RemoteServiceModel.detectRemoteDevices) { - RemoteServiceModel.detectRemoteDevices = true - } - if (!visible && RemoteServiceModel.detectRemoteDevices && !remoteSettingsView.pinEntryInProgress) { - RemoteServiceModel.detectRemoteDevices = false - } - } - - content: ColumnLayout { - height: baseItem.height - - RemoteServiceViewStartStop { - visible: sectionSwitch.selectedSection == SectionSwitch.Section.STARTSTOP - width: baseItem.width - Layout.fillHeight: true - } - GFlickable { - id: flickable - - visible: sectionSwitch.selectedSection == SectionSwitch.Section.REMOTE - width: baseItem.width - Layout.fillHeight: true - - contentHeight: remoteSettingsView.height - RemoteServiceViewRemote { - id: remoteSettingsView - width: baseItem.width - parentSectionPage: baseItem - } - } - RemoteServiceViewLocal { - visible: sectionSwitch.selectedSection == SectionSwitch.Section.LOCAL - width: baseItem.width - Layout.fillHeight: true - } - - SectionSwitch { - id: sectionSwitch - - visible: !RemoteServiceModel.running - Layout.fillWidth: true - - onSelectedSectionChanged: { - if (selectedSection == SectionSwitch.Section.REMOTE) { - RemoteServiceModel.detectRemoteDevices = true - flickable.highlightScrollbar() - } else { - RemoteServiceModel.detectRemoteDevices = false - } - } - } - } - - RemoteServiceController { - id: controller - } -} diff --git a/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewLocal.qml b/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewLocal.qml deleted file mode 100644 index dc56f1d1f..000000000 --- a/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewLocal.qml +++ /dev/null @@ -1,135 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.Type.SettingsModel 1.0 -import Governikus.Type.RemoteServiceModel 1.0 - - -Item { - id: baseItem - height: mainColumn.height - - Column { - id: mainColumn - width: baseItem.width - padding: Constants.pane_padding - spacing: Constants.component_spacing - - readonly property int usableWidth: width - 2 * padding - - GText { - id: errorMsg - - visible: text !== "" - width: parent.usableWidth - - Accessible.role: Accessible.StaticText - Accessible.name: text - - verticalAlignment: Text.AlignVCenter - text: "" - textStyle: Style.text.normal_warning - } - - Column { - id: nameContainer - width: parent.usableWidth - - GText { - Accessible.role: Accessible.StaticText - Accessible.name: text - - //: LABEL ANDROID IOS - text: qsTr("Device name") + SettingsModel.translationTrigger - textStyle: Style.text.normal_accent - } - - GText { - width: parent.width - - Accessible.role: Accessible.StaticText - Accessible.name: text - - //: LABEL ANDROID IOS - text: qsTr("Set device name:") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary - } - - Item { - id: spacing - height: 5 - width: height - } - - GTextField { - id: serverName - width: parent.width - onAccepted: { - SettingsModel.serverName = text - text = SettingsModel.serverName - nameContainer.forceActiveFocus(Qt.MouseFocusReason) - } - onVisibleChanged: { - nameContainer.forceActiveFocus(Qt.MouseFocusReason) - if (visible) text = SettingsModel.serverName - } - } - } - - Item { - id: pinPadModeContainer - - width: parent.usableWidth - height: Math.max(pinPadModeText.height, pinPadModeSwitch.height) - - Item { - id: pinPadModeText - - height: nameText.height + dateText.height - anchors.left: pinPadModeContainer.left - anchors.right: pinPadModeSwitch.left - anchors.rightMargin: Constants.component_spacing - anchors.verticalCenter: pinPadModeContainer.verticalCenter - GText { - id: nameText - - anchors.bottomMargin: 2 - - Accessible.role: Accessible.StaticText - Accessible.name: text - - //: LABEL ANDROID IOS - text: qsTr("PIN pad mode") + SettingsModel.translationTrigger - textStyle: Style.text.normal_accent - } - - GText { - id: dateText - - width: parent.width - anchors.top: nameText.bottom - - Accessible.role: Accessible.StaticText - Accessible.name: text - - //: LABEL ANDROID IOS - text: qsTr("Enter PIN on this device") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary - } - } - - GSwitch { - id: pinPadModeSwitch - anchors.right: pinPadModeContainer.right - anchors.verticalCenter: pinPadModeContainer.verticalCenter - initialState: SettingsModel.pinPadMode - onSwitched: SettingsModel.pinPadMode = pinPadModeSwitch.isOn - } - } - } -} diff --git a/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewRemote.qml b/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewRemote.qml deleted file mode 100644 index 05310b87d..000000000 --- a/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewRemote.qml +++ /dev/null @@ -1,144 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 - -import Governikus.EnterPasswordView 1.0 -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.TitleBar 1.0 -import Governikus.Type.SettingsModel 1.0 -import Governikus.Type.RemoteServiceModel 1.0 - - -Item { - id: baseItem - height: mainColumn.height - - property var parentSectionPage: undefined - - property bool pinEntryInProgress: false - - Column { - id: mainColumn - width: baseItem.width - padding: Constants.pane_padding - spacing: Constants.component_spacing - - readonly property int usableWidth: width - 2 * padding - Column { - width: parent.usableWidth - - GText { - Accessible.role: Accessible.StaticText - Accessible.name: text - - //: LABEL ANDROID IOS - text: qsTr("Paired devices") + SettingsModel.translationTrigger - textStyle: Style.text.normal_accent - bottomPadding: Constants.groupbox_spacing - } - - GText { - width: parent.width - visible: !knownDeviceList.visible - - Accessible.role: Accessible.StaticText - Accessible.name: text - - //: LABEL ANDROID IOS - text: qsTr("No device is paired.") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary - } - - ListView { - id: knownDeviceList - width: parent.width - height: childrenRect.height - spacing: Constants.groupbox_spacing / 2 - model: RemoteServiceModel.knownDevices - delegate: KnownDevicesListDelegate { - width: knownDeviceList.width - } - visible: count > 0 - interactive: false - } - } - - Column { - width: parent.usableWidth - - GText { - Accessible.role: Accessible.StaticText - Accessible.name: text - - //: LABEL ANDROID IOS - text: qsTr("Available devices") + SettingsModel.translationTrigger - textStyle: Style.text.normal_accent - bottomPadding: Constants.groupbox_spacing - } - - GText { - width: parent.width - visible: !searchDeviceList.visible - - Accessible.role: Accessible.StaticText - Accessible.name: text - - //: INFO ANDROID IOS No remote reader was found on the network, both devices need to be connected to the same wifi network. - text: qsTr("No new remote reader was found on your network. Make sure that the remote reader functionality in AusweisApp2 on your other device is activated and that your devices are connected to the same network.") + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary - } - - ListView { - id: searchDeviceList - width: parent.width - height: childrenRect.height - model: RemoteServiceModel.availableRemoteDevices - spacing: Constants.groupbox_spacing / 2 - delegate: AvailableDevicesListDelegate { - width: searchDeviceList.width - onRequestPairing: { - if (!RemoteServiceModel.rememberServer(pDeviceId)) { - return - } - informationPairingPopup.open() - } - } - visible: count > 0 - interactive: false - } - } - } - - ConfirmationPopup { - id: informationPairingPopup - - style: ConfirmationPopup.PopupStyle.OkButton - //: INFO ANDROID IOS - title: qsTr("Pairing mode") + SettingsModel.translationTrigger - //: INFO ANDROID IOS Information dialog that requests the user to start the pairing mode on the smarthpone. - text: qsTr("Please start pairing mode first.") + SettingsModel.translationTrigger - - onConfirmed: { - pinEntryInProgress = true - firePush(enterPinView) - } - } - - EnterPasswordView { - id: enterPinView - state: "REMOTE_PIN" - navigationAction: NavigationAction { state: "cancel"; onClicked: { firePop(); pinEntryInProgress = false } } - //: LABEL ANDROID IOS - title: qsTr("Pairing code") + SettingsModel.translationTrigger - visible: false - - onPasswordEntered: { - firePop() - pinEntryInProgress = false - } - } -} diff --git a/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewStartStop.qml b/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewStartStop.qml deleted file mode 100644 index bb90b64f0..000000000 --- a/resources/qml/Governikus/RemoteServiceView/RemoteServiceViewStartStop.qml +++ /dev/null @@ -1,223 +0,0 @@ -/* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.TitleBar 1.0 -import Governikus.Type.ApplicationModel 1.0 -import Governikus.Type.SettingsModel 1.0 -import Governikus.Type.RemoteServiceModel 1.0 - - -Item { - id: baseItem - - readonly property int maxWidth: Math.min(width - 2 * Constants.component_spacing, Style.dimens.max_text_width) - - RemoteServicePairingPopup { - id: popup - x: (baseItem.width - width) / 2 - y: (baseItem.height - height) / 2 - - pin: RemoteServiceModel.psk.toString() - onPinChanged: { - if (pin === "") { - close() - } - } - onVisibleChanged: RemoteServiceModel.setPairing(visible) - } - - Image { - id: image - source: "qrc:///images/phone_to_pc.svg" - anchors.top: parent.top - anchors.margins: Constants.component_spacing - anchors.horizontalCenter: parent.horizontalCenter - width: parent.maxWidth - fillMode: Image.PreserveAspectFit - } - - GText { - id: text - - Accessible.role: Accessible.StaticText - Accessible.name: text.text - - width: parent.maxWidth - anchors.top: image.bottom - anchors.margins: Constants.component_spacing - anchors.horizontalCenter: parent.horizontalCenter - - //: INFO ANDROID IOS The remote service is active. Hint that both devices need to be connected to the same network. - text: qsTr("Please start the remote service in order to use your smartphone as a card reader with AusweisApp2." - + " Please note: Both your devices have to be connected to the same WiFi.") - + SettingsModel.translationTrigger - textStyle: Style.text.normal_secondary - } - - - GButton { - readonly property bool running: RemoteServiceModel.running - readonly property bool canEnableNfc: RemoteServiceModel.canEnableNfc - property bool serviceIsStarting: false - id: startButton - buttonColor: running ? Constants.red : Constants.green - anchors.top: text.bottom - anchors.horizontalCenter: parent.horizontalCenter - anchors.margins: Constants.component_spacing - enabled: (canEnableNfc || RemoteServiceModel.runnable || running) && !serviceIsStarting - onClicked: { - if (canEnableNfc) { - ApplicationModel.showSettings(ApplicationModel.SETTING_NFC) - } else { - if (!running) { - serviceIsStarting = true - } - RemoteServiceModel.running = !running - } - } - text: { - SettingsModel.translationTrigger; // Bind this evaluation to the trigger. - - if (canEnableNfc) { - //: LABEL ANDROID IOS - return qsTr("Enable NFC"); - } else if (running) { - //: LABEL ANDROID IOS - return qsTr("Stop remote service"); - } else { - //: LABEL ANDROID IOS - return qsTr("Start remote service"); - } - } - onRunningChanged: { - serviceIsStarting = false - navBar.lockedAndHidden = running - } - } - - GButton { - id: pairingButton - anchors.top: startButton.bottom - anchors.horizontalCenter: parent.horizontalCenter - anchors.margins: Constants.component_spacing - //: LABEL ANDROID IOS - text: qsTr("Start pairing") + SettingsModel.translationTrigger - opacity: 0 - enabled: opacity === 1 - onClicked: popup.open() - } - - Item { - id: statusText - - anchors.top: startButton.bottom - anchors.bottom: parent.bottom - anchors.left: parent.left - anchors.right: parent.right - anchors.margins: Constants.component_spacing - anchors.topMargin: Constants.component_spacing * 2 - - GText { - id: error - - width: text.width - anchors.top: parent.top - anchors.bottom: parent.bottom - anchors.horizontalCenter: parent.horizontalCenter - - Accessible.role: Accessible.StaticText - Accessible.name: error.text - - horizontalAlignment: Text.AlignHCenter - visible: !RemoteServiceModel.runnable - text: RemoteServiceModel.errorMessage - textStyle: Style.text.normal_warning - } - - Item { - id: connectedText - anchors.fill: parent - opacity: 0 - - GText { - id: headText - - anchors.top: connectedText.top - anchors.horizontalCenter: parent.horizontalCenter - - Accessible.role: Accessible.StaticText - Accessible.name: headText.text - - //: LABEL ANDROID IOS - text: qsTr("Card access in progress") + SettingsModel.translationTrigger; - textStyle: Style.text.header_accent - } - GText { - id: subText - - anchors.top: headText.bottom - anchors.topMargin: 10 - anchors.horizontalCenter: parent.horizontalCenter - width: connectedText.width * 0.8 - - Accessible.role: Accessible.StaticText - Accessible.name: subText.text - - verticalAlignment: Text.AlignVCenter - horizontalAlignment: Text.AlignHCenter - text: RemoteServiceModel.connectionInfo - textStyle: Style.text.normal_secondary - } - - states: [ - State { name: "UNCONNECTED"; when: RemoteServiceModel.running && !RemoteServiceModel.connected - PropertyChanges { target: connectedText; opacity: 0 } - PropertyChanges { target: pairingButton; opacity: 1 } - PropertyChanges { target: ApplicationModel; nfcRunning: false; restoreEntryValues: false } - }, - State { name: "CONNECTED"; when: RemoteServiceModel.running && RemoteServiceModel.connected - PropertyChanges { target: connectedText; opacity: 1 } - PropertyChanges { target: pairingButton; opacity: 0 } - PropertyChanges { target: ApplicationModel; nfcRunning: true; restoreEntryValues: false } - } - ] - transitions: [ - Transition { - NumberAnimation { - property: "opacity" - duration: 500 - easing.type: Easing.InOutQuad - } - } - ] - } - } - - states: [ - State { name: "OFF"; when: !RemoteServiceModel.running - PropertyChanges { target: pairingButton; opacity: 0 } - AnchorChanges { target: statusText; anchors.top: startButton.bottom } - }, - State { name: "ON"; when: RemoteServiceModel.running - PropertyChanges { target: pairingButton; opacity: 1 } - AnchorChanges { target: statusText; anchors.top: pairingButton.bottom } - } - ] - transitions: [ - Transition { - NumberAnimation { - property: "opacity" - duration: 500 - easing.type: Easing.InOutQuad - } - AnchorAnimation { - duration: 500 - } - } - ] -} diff --git a/resources/qml/Governikus/RemoteServiceView/SectionSwitch.qml b/resources/qml/Governikus/RemoteServiceView/SectionSwitch.qml deleted file mode 100644 index 024c7ff1d..000000000 --- a/resources/qml/Governikus/RemoteServiceView/SectionSwitch.qml +++ /dev/null @@ -1,56 +0,0 @@ -/* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.TechnologyInfo 1.0 -import Governikus.Type.SettingsModel 1.0 -import Governikus.Type.RemoteServiceModel 1.0 - - -Rectangle { - id: baseItem - height: sectionRow.height - color: Style.color.background - - enum Section { - STARTSTOP = 0, - REMOTE = 1, - LOCAL = 2 - } - property int selectedSection: SectionSwitch.Section.STARTSTOP - - Row { - id: sectionRow - spacing: 30 - anchors.bottom: parent.bottom - anchors.horizontalCenter: parent.horizontalCenter - - TechnologySwitchButton { - buttonActive: selectedSection !== SectionSwitch.Section.STARTSTOP - onClicked: selectedSection = SectionSwitch.Section.STARTSTOP - imageSource: "qrc:///images/icon_remote.svg" - //: LABEL ANDROID IOS - text: qsTr("Service") + SettingsModel.translationTrigger - } - - TechnologySwitchButton { - buttonActive: selectedSection !== SectionSwitch.Section.REMOTE - onClicked: selectedSection = SectionSwitch.Section.REMOTE - imageSource: "qrc:///images/icon_pair.svg" - //: LABEL ANDROID IOS - text: qsTr("Pairing") + SettingsModel.translationTrigger - } - - TechnologySwitchButton { - buttonActive: selectedSection !== SectionSwitch.Section.LOCAL - onClicked: selectedSection = SectionSwitch.Section.LOCAL - imageSource: "qrc:///images/icon_settings.svg" - //: LABEL ANDROID IOS - text: qsTr("Settings") + SettingsModel.translationTrigger - } - } -} diff --git a/resources/qml/Governikus/RemoteServiceView/qmldir b/resources/qml/Governikus/RemoteServiceView/qmldir index f54cc0de7..59ef0a4b5 100644 --- a/resources/qml/Governikus/RemoteServiceView/qmldir +++ b/resources/qml/Governikus/RemoteServiceView/qmldir @@ -1,13 +1,8 @@ module RemoteServiceView -internal AvailableDevicesListDelegate AvailableDevicesListDelegate.qml -internal KnownDevicesListDelegate KnownDevicesListDelegate.qml +internal DevicesListDelegate DevicesListDelegate.qml internal RemoteServiceController RemoteServiceController.qml -internal RemoteServicePairingPopup RemoteServicePairingPopup.qml -internal RemoteServiceViewLocal RemoteServiceViewLocal.qml internal RemoteServiceViewRemote RemoteServiceViewRemote.qml -internal RemoteServiceViewStartStop RemoteServiceViewStartStop.qml -internal SectionSwitch SectionSwitch.qml RemoteServiceSettings 1.0 RemoteServiceSettings.qml RemoteServiceView 1.0 RemoteServiceView.qml diff --git a/resources/qml/Governikus/ResultView/+desktop/ResultView.qml b/resources/qml/Governikus/ResultView/+desktop/ResultView.qml index b647eee1f..1116841ab 100644 --- a/resources/qml/Governikus/ResultView/+desktop/ResultView.qml +++ b/resources/qml/Governikus/ResultView/+desktop/ResultView.qml @@ -1,8 +1,9 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 +import QtQuick.Layouts 1.3 import QtQuick.Controls 2.3 import Governikus.Global 1.0 @@ -25,7 +26,8 @@ SectionPage { signal emailButtonPressed() property alias emailButtonVisible: emailButton.visible property alias text: resultText.text - property int resultType: Type.IsSuccess + property int resultType: ResultView.Type.IsSuccess + property alias buttonType: button.buttonType Accessible.name: qsTr("Result view") + SettingsModel.translationTrigger Accessible.description: qsTr("This is the result of an authentication.") + SettingsModel.translationTrigger @@ -33,75 +35,66 @@ SectionPage { Keys.onEnterPressed: button.onClicked() Keys.onEscapePressed: button.onClicked() - StatusIcon { - height: Style.dimens.status_icon_large - anchors.horizontalCenter: parent.horizontalCenter - anchors.verticalCenter: parent.top - anchors.verticalCenterOffset: baseItem.height / 4 - - source: { - switch (resultType) { - case ResultView.Type.IsSuccess: - return "qrc:///images/status_ok.svg" - case ResultView.Type.IsInfo: - return "qrc:///images/status_info.svg" - case ResultView.Type.IsError: - return "qrc:///images/status_error.svg" + ColumnLayout { + anchors.fill: parent + + StatusIcon { + Layout.alignment: Qt.AlignHCenter + Layout.preferredWidth: Style.dimens.status_icon_large + Layout.preferredHeight: Style.dimens.status_icon_large + + source: { + switch (resultType) { + case ResultView.Type.IsSuccess: + return "qrc:///images/status_ok.svg" + case ResultView.Type.IsInfo: + return "qrc:///images/status_info.svg" + case ResultView.Type.IsError: + return "qrc:///images/status_error.svg" + } } } - } - - GText { - id: resultText - visible: text !== "" - width: Math.min(parent.width - (2 * Constants.pane_padding), Style.dimens.max_text_width) - anchors.horizontalCenter: parent.horizontalCenter - anchors.top: parent.verticalCenter + GText { + id: resultText - activeFocusOnTab: true - Accessible.role: Accessible.Heading - Accessible.name: resultText.text + visible: text !== "" + Layout.alignment: Qt.AlignHCenter + Layout.maximumWidth: Style.dimens.max_text_width - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - textStyle: Style.text.title + activeFocusOnTab: true + Accessible.name: resultText.text - onLinkActivated: Qt.openUrlExternally(link) + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter + textStyle: Style.text.title_inverse - FocusFrame { - dynamic: false + FocusFrame {} } - } - GButton { - id: emailButton + GButton { + id: emailButton - visible: false + visible: false + Layout.alignment: Qt.AlignHCenter - icon.source: "qrc:///images/provider/mail.svg" - //: LABEL DESKTOP_QML - text: qsTr("Send email") + SettingsModel.translationTrigger - anchors { - horizontalCenter: parent.horizontalCenter - verticalCenter: parent.top - verticalCenterOffset: baseItem.height * 3 / 4 + icon.source: "qrc:///images/provider/mail.svg" + //: LABEL DESKTOP_QML + text: qsTr("Send email") + SettingsModel.translationTrigger + onClicked: baseItem.emailButtonPressed() } - onClicked: baseItem.emailButtonPressed() - } - NavigationButton { - id: button + NavigationButton { + id: button - anchors { - margins: Constants.component_spacing - bottom: parent.bottom - horizontalCenter: parent.horizontalCenter - } + Layout.alignment: Qt.AlignHCenter + Layout.preferredWidth: width + Layout.preferredHeight: height - activeFocusOnTab: true + activeFocusOnTab: true - buttonType: Qt.ForwardButton - onClicked: baseItem.nextView(SectionPage.Views.Main) + buttonType: NavigationButton.Type.Forward + onClicked: baseItem.nextView(SectionPage.Views.Main) + } } } diff --git a/resources/qml/Governikus/ResultView/+mobile/ResultView.qml b/resources/qml/Governikus/ResultView/+mobile/ResultView.qml index 4f221b46f..5ef7e3cf6 100644 --- a/resources/qml/Governikus/ResultView/+mobile/ResultView.qml +++ b/resources/qml/Governikus/ResultView/+mobile/ResultView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -61,8 +61,6 @@ SectionPage { horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter textStyle: resultType !== ResultView.Type.IsError ? Style.text.header_accent : Style.text.header_warning - - onLinkActivated: Qt.openUrlExternally(link) } Row { @@ -86,7 +84,7 @@ SectionPage { visible: false //: LABEL ANDROID IOS - text: qsTr("Send log file") + SettingsModel.translationTrigger + text: qsTr("Send logfile") + SettingsModel.translationTrigger onClicked: LogModel.mailLog() } } diff --git a/resources/qml/Governikus/SelfAuthenticationView/+desktop/SelfAuthenticationView.qml b/resources/qml/Governikus/SelfAuthenticationView/+desktop/SelfAuthenticationView.qml index f08ffe866..2d40b41c2 100644 --- a/resources/qml/Governikus/SelfAuthenticationView/+desktop/SelfAuthenticationView.qml +++ b/resources/qml/Governikus/SelfAuthenticationView/+desktop/SelfAuthenticationView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import Governikus.Global 1.0 @@ -16,8 +16,15 @@ SectionPage { titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML text: qsTr("Identify") + SettingsModel.translationTrigger + helpTopic: "selfauthentication" } + //: LABEL DESKTOP_QML + Accessible.name: qsTr("Self-Authentication.") + SettingsModel.translationTrigger + Accessible.description: qsTr("This is the self-authentication view of the AusweisApp2.") + SettingsModel.translationTrigger + Keys.onReturnPressed: startWorkflowButton.onClicked() + Keys.onEnterPressed: startWorkflowButton.onClicked() + Column { width: Style.dimens.max_text_width anchors.centerIn: parent @@ -45,10 +52,14 @@ SectionPage { anchors.left: useNpa.right anchors.right: parent.right - textStyle: Style.text.header + activeFocusOnTab: true + + textStyle: Style.text.header_inverse //: LABEL DESKTOP_QML text: qsTr("You can use your ID card anywhere you see this logo.") + SettingsModel.translationTrigger + + FocusFrame {} } } Pane { @@ -64,24 +75,35 @@ SectionPage { width: parent.width - textStyle: Style.text.normal_inverse + activeFocusOnTab: true + + textStyle: Style.text.normal //: LABEL DESKTOP_QML text: qsTr("Use the button 'See my personal data' to display the data stored on your ID card." + " An Internet connection is required to display the data.") + "

" + //: LABEL DESKTOP_QML + qsTr("Your personal data is neither saved nor processed in any way. Please see our %1 for details on how your personal data is processed.") - .arg('' + qsTr("data privacy statement") + '') + .arg('' + + //: LABEL DESKTOP_QML + qsTr("data privacy statement") + '') + "" + SettingsModel.translationTrigger - onLinkActivated: Qt.openUrlExternally(link) + FocusFrame { + borderColor: Style.color.focus_indicator + } } GButton { + id: startWorkflowButton + anchors.right: parent.right icon.source: "qrc:///images/npa.svg" - buttonColor: SettingsModel.useSelfauthenticationTestUri ? Constants.red : Style.color.accent + buttonColor: SettingsModel.useSelfauthenticationTestUri ? Constants.red : Style.color.button //: LABEL DESKTOP_QML text: qsTr("See my personal data") + SettingsModel.translationTrigger onClicked: SelfAuthModel.startWorkflow() diff --git a/resources/qml/Governikus/SelfAuthenticationView/+mobile/SelfAuthenticationView.qml b/resources/qml/Governikus/SelfAuthenticationView/+mobile/SelfAuthenticationView.qml index 82db62e5f..cbb9d83fd 100644 --- a/resources/qml/Governikus/SelfAuthenticationView/+mobile/SelfAuthenticationView.qml +++ b/resources/qml/Governikus/SelfAuthenticationView/+mobile/SelfAuthenticationView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -25,14 +25,17 @@ Item { case 7: case 8: case 9: - ApplicationModel.showFeedback(qsTr("%1 more presses to toggle test PKI.").arg(10 - d.testPkiCounter) + SettingsModel.translationTrigger, true) + //: INFO ANDROID IOS Used in notifications when the user taps the magnifying glass + ApplicationModel.showFeedback(qsTr("%1 more presses to toggle the testmode for the self-authentication.").arg(10 - d.testPkiCounter) + SettingsModel.translationTrigger, true) break; case 10: SettingsModel.useSelfauthenticationTestUri = !SettingsModel.useSelfauthenticationTestUri - if(SettingsModel.useSelfauthenticationTestUri) { - ApplicationModel.showFeedback(qsTr("Test PKI activated.") + SettingsModel.translationTrigger, true) + if (SettingsModel.useSelfauthenticationTestUri) { + //: INFO ANDROID IOS Used in notifications when the user taps the magnifying glass + ApplicationModel.showFeedback(qsTr("Testmode for the self-authentication activated.") + SettingsModel.translationTrigger, true) } else { - ApplicationModel.showFeedback(qsTr("Test PKI deactivated.") + SettingsModel.translationTrigger, true) + //: INFO ANDROID IOS Used in notifications when the user taps the magnifying glass + ApplicationModel.showFeedback(qsTr("Testmode for the self-authentication deactivated.") + SettingsModel.translationTrigger, true) } d.testPkiCounter = 0; break; @@ -95,7 +98,7 @@ Item { Accessible.role: Accessible.Link Accessible.name: ApplicationModel.stripHtmlTags(text) Accessible.description: qsTr("Click to open link to data privacy statement in browser: %1").arg(htmlLink) + SettingsModel.translationTrigger - Accessible.onPressAction: if (Qt.platform.os === "ios") Qt.openUrlExternally(htmlLink) + Accessible.onPressAction: Qt.openUrlExternally(htmlLink) wrapMode: Text.WordWrap //: LABEL ANDROID IOS @@ -107,14 +110,13 @@ Item { .arg('' + qsTr("data privacy statement") + '') + "" + SettingsModel.translationTrigger - onLinkActivated: Qt.openUrlExternally(link) } } } GButton { id: selfAuthButton - iconSource: "qrc:///images/npa.svg" + icon.source: "qrc:///images/npa.svg" anchors.bottom: baseItem.bottom anchors.bottomMargin: Constants.pane_padding anchors.horizontalCenter: parent.horizontalCenter diff --git a/resources/qml/Governikus/SettingsView/+desktop/CardReaderDelegate.qml b/resources/qml/Governikus/SettingsView/+desktop/CardReaderDelegate.qml index e6efeba4c..7f71ab167 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/CardReaderDelegate.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/CardReaderDelegate.qml @@ -1,13 +1,14 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.12 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.SettingsModel 1.0 import Governikus.View 1.0 @@ -17,9 +18,11 @@ Item { implicitHeight: rowLayout.implicitHeight activeFocusOnTab: true + Accessible.role: Accessible.Button + Accessible.name: readerName + ". " + readerStatus + FocusFrame { - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } RowLayout { @@ -49,14 +52,14 @@ Item { GText { Layout.fillWidth: true - textStyle: Style.text.header_inverse + textStyle: Style.text.header text: readerName } GText { Layout.fillWidth: true - textStyle: Style.text.normal_inverse + textStyle: Style.text.normal text: readerStatus } @@ -65,8 +68,15 @@ Item { Layout.fillWidth: true - textStyle: Style.text.normal_inverse + activeFocusOnTab: true + Accessible.description: qsTr("Press space to open the link in your browser") + SettingsModel.translationTrigger + + textStyle: Style.text.normal text: readerHTMLDescription + + FocusFrame { + borderColor: Style.color.focus_indicator + } } } diff --git a/resources/qml/Governikus/SettingsView/+desktop/CardReaderView.qml b/resources/qml/Governikus/SettingsView/+desktop/CardReaderView.qml index dac561087..9afa9cbbe 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/CardReaderView.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/CardReaderView.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.12 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -11,15 +11,32 @@ import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SettingsModel 1.0 import Governikus.Type.ReaderDriverModel 1.0 import Governikus.Type.ReaderScanEnabler 1.0 +import Governikus.Type.ReaderPlugIn 1.0 import Governikus.View 1.0 Column { id: root + readonly property string helpTopic: "settingsPcscReader" + spacing: Constants.component_spacing ReaderScanEnabler { + plugInType: ReaderPlugIn.PCSC + } + + GText { + width: parent.width + + activeFocusOnTab: true + + textStyle: Style.text.header_accent + text: qsTr("Connected USB card reader") + SettingsModel.translationTrigger + + FocusFrame { + borderColor: Style.color.focus_indicator + } } Column { @@ -54,14 +71,10 @@ Column { text: ReaderDriverModel.emptyListDescriptionString verticalAlignment: Text.AlignVCenter - textStyle: Style.text.normal_inverse - - Keys.onSpacePressed: ApplicationModel.openOnlineHelp("readerDeviceTab") - onLinkActivated: Qt.openUrlExternally(link) + textStyle: Style.text.normal FocusFrame { - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } @@ -74,13 +87,12 @@ Column { width: parent.width - spacing: Constants.component_spacing - - Image { - Layout.preferredHeight: hintText.height * 1.5 + spacing: Constants.text_spacing - fillMode: Image.PreserveAspectFit - source: "qrc:/images/desktop/info_version.svg" + TintableIcon { + source: "qrc:/images/info_filled.svg" + sourceSize.height: Style.dimens.icon_size + tintColor: Style.color.accent } GText { @@ -92,12 +104,11 @@ Column { activeFocusOnTab: true verticalAlignment: Text.AlignBottom - textStyle: Style.text.hint_inverse + textStyle: Style.text.hint text: qsTr("After connecting a new card reader it may take a few seconds to recognize the driver. It may be necessary to restart your system after installing the driver. Only supported and connected card reader are shown here. %1").arg(ReaderDriverModel.lastUpdatedInformation) + SettingsModel.translationTrigger FocusFrame { - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } } diff --git a/resources/qml/Governikus/SettingsView/+desktop/DebugSettings.qml b/resources/qml/Governikus/SettingsView/+desktop/DebugSettings.qml new file mode 100644 index 000000000..2861b079a --- /dev/null +++ b/resources/qml/Governikus/SettingsView/+desktop/DebugSettings.qml @@ -0,0 +1,50 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.View 1.0 +import Governikus.Style 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.HistoryModel 1.0 +import Governikus.Type.LogModel 1.0 +import Governikus.Type.SettingsModel 1.0 + +ColumnLayout { + + spacing: Constants.component_spacing + + GText { + //: LABEL DESKTOP_QML + text: qsTr("Create dummy entries") + SettingsModel.translationTrigger + textStyle: Style.text.header_accent + } + + RowLayout { + GButton { + //: LABEL DESKTOP_QML + text: qsTr("Logfile") + SettingsModel.translationTrigger + onClicked: { + LogModel.saveDummyLogfile() + ApplicationModel.showFeedback("Created new logfile.") + } + } + GButton { + //: LABEL DESKTOP_QML + text: qsTr("History") + SettingsModel.translationTrigger + onClicked: { + HistoryModel.createDummyEntry() + ApplicationModel.showFeedback("Created new history entry.") + } + } + } + + ToggleableOption { + //: LABEL DESKTOP_QML + text: qsTr("Show beta testing image") + SettingsModel.translationTrigger + checked: SettingsModel.showBetaTesting + onCheckedChanged: SettingsModel.showBetaTesting = checked + } +} diff --git a/resources/qml/Governikus/SettingsView/+desktop/DeveloperSettings.qml b/resources/qml/Governikus/SettingsView/+desktop/DeveloperSettings.qml index e71a88b85..829f43665 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/DeveloperSettings.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/DeveloperSettings.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick.Layouts 1.3 @@ -7,23 +7,33 @@ import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.View 1.0 import Governikus.Style 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.HistoryModel 1.0 +import Governikus.Type.LogModel 1.0 import Governikus.Type.SettingsModel 1.0 ColumnLayout { + readonly property string helpTopic: "settingsDeveloper" spacing: Constants.component_spacing GText { + activeFocusOnTab: true + //: LABEL DESKTOP_QML text: qsTr("Developer options") + SettingsModel.translationTrigger textStyle: Style.text.header_accent + + FocusFrame { + borderColor: Style.color.focus_indicator + } } ToggleableOption { activeFocusOnTab: true //: LABEL DESKTOP_QML - text: qsTr("Test PKI") + SettingsModel.translationTrigger + text: qsTr("Testmode for the self-authentication") + SettingsModel.translationTrigger checked: SettingsModel.useSelfauthenticationTestUri onCheckedChanged: SettingsModel.useSelfauthenticationTestUri = checked } @@ -42,13 +52,12 @@ ColumnLayout { activeFocusOnTab: true - //: LABEL DESKTOP_QML Only visible when the user activates the developer mode in the settings. + //: LABEL DESKTOP_QML text: qsTr("The developer mode is aimed at integrators / developers for new service applications. For this reason, the developer mode works only in the test PKI. By activating the developer mode, some safety tests are deactivated. This means that the authentication process continues although the AusweisApp2 would usually abort the process with an error message when used in normal operation mode. Information on the disregarded error in the developer mode is displayed in the attached window below the AusweisApp2.") + SettingsModel.translationTrigger textStyle: Style.text.hint_warning FocusFrame { - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } } diff --git a/resources/qml/Governikus/SettingsView/+desktop/GeneralSettings.qml b/resources/qml/Governikus/SettingsView/+desktop/GeneralSettings.qml index 0648501c7..ca8ca7f7a 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/GeneralSettings.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/GeneralSettings.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -7,6 +7,7 @@ import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 +import Governikus.View 1.0 import Governikus.Type.SettingsModel 1.0 ColumnLayout { @@ -14,31 +15,35 @@ ColumnLayout { spacing: Constants.component_spacing GText { + activeFocusOnTab: true + //: LABEL DESKTOP_QML text: qsTr("Language selection") + SettingsModel.translationTrigger textStyle: Style.text.header_accent + + FocusFrame { + borderColor: Style.color.focus_indicator + } } RowLayout { spacing: Constants.component_spacing LocationButton { - activeFocusOnTab: true Accessible.name: qsTr("German") + SettingsModel.translationTrigger Accessible.description: qsTr("Set language to german") + SettingsModel.translationTrigger language: "de" - text: "DE" + text: "Deutsch" image: "qrc:///images/location_flag_de.svg" } LocationButton { - activeFocusOnTab: true Accessible.name: qsTr("English") + SettingsModel.translationTrigger Accessible.description: qsTr("Set language to english") + SettingsModel.translationTrigger language: "en" - text: "EN" + text: "English" image: "qrc:///images/location_flag_en.svg" } @@ -49,17 +54,39 @@ ColumnLayout { } GText { + activeFocusOnTab: true + //: LABEL DESKTOP_QML text: qsTr("UI settings") + SettingsModel.translationTrigger textStyle: Style.text.header_accent + + FocusFrame { + borderColor: Style.color.focus_indicator + } } - GButton { - activeFocusOnTab: true + RowLayout { + Layout.fillWidth: true + spacing: Constants.component_spacing - //: LABEL DESKTOP_QML - text: qsTr("Switch back to old UI") + SettingsModel.translationTrigger - onClicked: plugin.switchUi() + GButton { + //: LABEL DESKTOP_QML + text: qsTr("Switch back to old UI") + SettingsModel.translationTrigger + onClicked: plugin.switchUi() + } + + GText { + Layout.fillWidth: true + + activeFocusOnTab: true + + text: qsTr("Please note that the old UI will be removed in the next version of %1!").arg(Qt.application.name) + SettingsModel.translationTrigger + textStyle: Style.text.normal_warning + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } } GSeparator { @@ -67,9 +94,15 @@ ColumnLayout { } GText { + activeFocusOnTab: true + //: LABEL DESKTOP_QML text: qsTr("Behavior") + SettingsModel.translationTrigger textStyle: Style.text.header_accent + + FocusFrame { + borderColor: Style.color.focus_indicator + } } ToggleableOption { @@ -78,7 +111,7 @@ ColumnLayout { //: LABEL DESKTOP_QML text: qsTr("Auto start AusweisApp2 after boot") + SettingsModel.translationTrigger checked: SettingsModel.autoStartApp - enabled: !SettingsModel.autoStartSetByAdmin + enabled: !SettingsModel.autoStartSetByAdmin && SettingsModel.autoStartAvailable onCheckedChanged: SettingsModel.autoStartApp = checked } @@ -91,4 +124,28 @@ ColumnLayout { onCheckedChanged: SettingsModel.autoCloseWindowAfterAuthentication = checked } + ToggleableOption { + activeFocusOnTab: true + + //: LABEL DESKTOP_QML + text: qsTr("Use internal notifications") + SettingsModel.translationTrigger + checked: SettingsModel.showInAppNotifications + enabled: !SettingsModel.developerMode + onCheckedChanged: SettingsModel.showInAppNotifications = checked + } + + GText { + visible: SettingsModel.developerMode + Layout.fillWidth: true + + activeFocusOnTab: true + + //: LABEL DESKTOP_QML Only visible when the user activates the developer mode in the settings. + text: qsTr("Using the developer mode forces the notifications to be enabled.") + SettingsModel.translationTrigger + textStyle: Style.text.hint_warning + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } } diff --git a/resources/qml/Governikus/SettingsView/+desktop/RemoteReaderDelegate.qml b/resources/qml/Governikus/SettingsView/+desktop/RemoteReaderDelegate.qml index 61ea10de0..f67310ee1 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/RemoteReaderDelegate.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/RemoteReaderDelegate.qml @@ -1,9 +1,10 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.12 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -20,11 +21,22 @@ Item { property int iconHeight: ApplicationModel.scaleFactor * 80 implicitHeight: rowLayout.implicitHeight + activeFocusOnTab: true + Accessible.role: Accessible.Button + Accessible.name: { + SettingsModel.translationTrigger + + var msg = qsTr("Smartphone named \"%1\"").arg(remoteDeviceName) + subtext.text + if (isPaired) { + return msg + qsTr("Press space to unpair the smartphone \"%1\".").arg(remoteDeviceName) + } + return msg + qsTr("Press space to pair the smartphone \"%1\".").arg(remoteDeviceName) + } + Keys.onSpacePressed: isPaired ? unpairDevice(deviceId) : pairDevice(deviceId) FocusFrame { - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } RowLayout { @@ -32,20 +44,26 @@ Item { width: parent.width - spacing: 0 + spacing: Constants.component_spacing - ColumnLayout { - Layout.fillHeight: true + Column { + Layout.fillWidth: true GText { - Layout.preferredWidth: implicitWidth - textStyle: Style.text.header_inverse + width: parent.width + + textStyle: Style.text.header text: remoteDeviceName + elide: Text.ElideRight + maximumLineCount: 1 } GText { - Layout.preferredWidth: implicitWidth - textStyle: Style.text.normal_inverse + id: subtext + + width: parent.width + + textStyle: Style.text.normal text: { if (!isPaired) { return qsTr("Click to pair") + SettingsModel.translationTrigger @@ -58,7 +76,6 @@ Item { Row { Layout.preferredHeight: iconHeight - Layout.alignment: Qt.AlignRight spacing: Constants.component_spacing @@ -98,9 +115,17 @@ Item { fillMode: Image.PreserveAspectFit MouseArea { + id: trashMouse + anchors.fill: parent - onClicked: unpairDevice(deviceId) + + hoverEnabled: true cursorShape: Qt.PointingHandCursor + onClicked: unpairDevice(deviceId) + + ToolTip.delay: 500 + ToolTip.visible: trashMouse.containsMouse + ToolTip.text: qsTr("Remove remote device") + SettingsModel.translationTrigger } } diff --git a/resources/qml/Governikus/SettingsView/+desktop/RemoteReaderView.qml b/resources/qml/Governikus/SettingsView/+desktop/RemoteReaderView.qml index 291e61c6a..ae9a7100f 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/RemoteReaderView.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/RemoteReaderView.qml @@ -1,35 +1,33 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.12 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 import Governikus.TitleBar 1.0 import Governikus.Type.NumberModel 1.0 -import Governikus.Type.ReaderScanEnabler 1.0 import Governikus.Type.RemoteServiceModel 1.0 import Governikus.Type.SettingsModel 1.0 +import Governikus.Type.ReaderScanEnabler 1.0 +import Governikus.Type.ReaderPlugIn 1.0 import Governikus.View 1.0 Item { id: root + readonly property string helpTopic: "settingsRemoteReader" + signal pairDevice(string pDeviceId) signal unpairDevice(string pDeviceId) + signal moreInformation() - Component.onCompleted: { - RemoteServiceModel.detectRemoteDevices = visible - } - - Component.onDestruction: { - RemoteServiceModel.detectRemoteDevices = false + ReaderScanEnabler { + plugInType: ReaderPlugIn.REMOTE } - onVisibleChanged: RemoteServiceModel.detectRemoteDevices = visible - Column { anchors.fill: parent spacing: Constants.component_spacing @@ -40,8 +38,14 @@ Item { width: parent.width + activeFocusOnTab: true + textStyle: Style.text.header_accent text: qsTr("Paired remote devices") + SettingsModel.translationTrigger + + FocusFrame { + borderColor: Style.color.focus_indicator + } } Column { @@ -67,22 +71,28 @@ Item { GText { width: parent.width + + activeFocusOnTab: true + textStyle: Style.text.header_accent text: qsTr("Available remote devices") + SettingsModel.translationTrigger + + FocusFrame { + borderColor: Style.color.focus_indicator + } } - Column { - width: parent.width + GListView { + id: availableDevices - Repeater { - id: availableDevices + width: parent.width + height: contentHeight - model: RemoteServiceModel.availableRemoteDevices - delegate: RemoteReaderDelegate { - width: parent.width - height: implicitHeight + Constants.pane_padding - onPairDevice: root.pairDevice(pDeviceId) - } + model: RemoteServiceModel.availableRemoteDevices + delegate: RemoteReaderDelegate { + width: parent.width + height: implicitHeight + Constants.pane_padding + onPairDevice: root.pairDevice(pDeviceId) } } @@ -92,27 +102,30 @@ Item { width: parent.width activeFocusOnTab: true - textStyle: Style.text.normal_inverse - text: qsTr("No devices with enabled remote service were found on the current WiFi network") + SettingsModel.translationTrigger + + textStyle: Style.text.normal + text: RemoteServiceModel.availableRemoteDevices.emptyListDescriptionString FocusFrame { - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } + GSeparator { + width: parent.width + } + RowLayout { id: hint width: parent.width - spacing: Constants.component_spacing - - Image { - Layout.preferredHeight: hintText.height * 1.5 + spacing: Constants.text_spacing - fillMode: Image.PreserveAspectFit - source: "qrc:/images/desktop/info_version.svg" + TintableIcon { + source: "qrc:/images/info_filled.svg" + sourceSize.height: Style.dimens.icon_size + tintColor: Style.color.accent } GText { @@ -125,14 +138,19 @@ Item { wrapMode: Text.WordWrap verticalAlignment: Text.AlignBottom - textStyle: Style.text.hint_inverse + textStyle: Style.text.hint text: qsTr("Only devices that are already paired or are connected to the same WiFi network and have the remote service enabled are shown here.") + SettingsModel.translationTrigger FocusFrame { - dynamic: false - border.color: Constants.black + borderColor: Style.color.focus_indicator } } } + + GButton { + //: LABEL DESKTOP_QML + text: qsTr("More information") + SettingsModel.translationTrigger + onClicked: moreInformation() + } } } diff --git a/resources/qml/Governikus/SettingsView/+desktop/SecurityAndPrivacySettings.qml b/resources/qml/Governikus/SettingsView/+desktop/SecurityAndPrivacySettings.qml index c9eaa8cac..be2945659 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/SecurityAndPrivacySettings.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/SecurityAndPrivacySettings.qml @@ -1,21 +1,32 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ +import QtQuick 2.10 +import QtQuick.Controls 2.3 import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 import Governikus.Type.SettingsModel 1.0 +import Governikus.Type.HistoryModel 1.0 +import Governikus.View 1.0 ColumnLayout { + readonly property string helpTopic: "settingsSecurityPrivacy" spacing: Constants.component_spacing GText { + activeFocusOnTab: true + //: LABEL DESKTOP_QML text: qsTr("History") + SettingsModel.translationTrigger textStyle: Style.text.header_accent + + FocusFrame { + borderColor: Style.color.focus_indicator + } } ToggleableOption { @@ -28,11 +39,11 @@ ColumnLayout { } GButton { - activeFocusOnTab: true - //: LABEL DESKTOP_QML text: qsTr("Clear entire history") + SettingsModel.translationTrigger - onClicked: SettingsModel.removeEntireHistory() + onClicked: confirmationPopup.open() + enableButton: !HistoryModel.empty + disabledTooltipText: qsTr("History is empty") + SettingsModel.translationTrigger } GSeparator { @@ -40,9 +51,15 @@ ColumnLayout { } GText { + activeFocusOnTab: true + //: LABEL DESKTOP_QML text: qsTr("Onscreen keypad") + SettingsModel.translationTrigger textStyle: Style.text.header_accent + + FocusFrame { + borderColor: Style.color.focus_indicator + } } ToggleableOption { @@ -54,6 +71,16 @@ ColumnLayout { onCheckedChanged: SettingsModel.useScreenKeyboard = checked } + ToggleableOption { + activeFocusOnTab: true + + //: LABEL DESKTOP_QML + text: qsTr("Avoid visual feedback in the on screen keypad") + SettingsModel.translationTrigger + checked: SettingsModel.visualPrivacy + enabled: SettingsModel.useScreenKeyboard + onCheckedChanged: SettingsModel.visualPrivacy = checked + } + ToggleableOption { activeFocusOnTab: true @@ -69,9 +96,15 @@ ColumnLayout { } GText { + activeFocusOnTab: true + //: LABEL DESKTOP_QML text: qsTr("Software updates") + SettingsModel.translationTrigger textStyle: Style.text.header_accent + + FocusFrame { + borderColor: Style.color.focus_indicator + } } ToggleableOption { @@ -80,16 +113,68 @@ ColumnLayout { //: LABEL DESKTOP_QML text: qsTr("Check at program start") + SettingsModel.translationTrigger checked: SettingsModel.autoUpdateCheck - enabled: !SettingsModel.autoUpdateCeckSetByAdmin + enabled: !SettingsModel.autoUpdateCheckSetByAdmin && SettingsModel.autoUpdateAvailable onCheckedChanged: SettingsModel.autoUpdateCheck = checked } - GButton { - activeFocusOnTab: true + RowLayout { + readonly property bool updateAvailable: SettingsModel.appUpdateData.updateAvailable + readonly property bool updateValid: SettingsModel.appUpdateData.valid - //: LABEL DESKTOP_QML - text: qsTr("Check now") + SettingsModel.translationTrigger - onClicked: SettingsModel.updateApp() + Layout.fillWidth: true + spacing: Constants.component_spacing + + GButton { + text: (parent.updateAvailable ? + //: LABEL DESKTOP_QML + qsTr("Show update") : + //: LABEL DESKTOP_QML + qsTr("Check now") + ) + SettingsModel.translationTrigger + enabled: SettingsModel.autoUpdateAvailable + onClicked: SettingsModel.updateApp() + } + + GText { + Layout.fillWidth: true + + activeFocusOnTab: true + + text: { + SettingsModel.translationTrigger + + if (parent.updateAvailable && parent.updateValid) { + //: LABEL DESKTOP_QML An update is available, the new version is supplied to the user. + return qsTr("An update is available (version %1)!").arg(SettingsModel.appUpdateData.version) + } + else if (parent.updateAvailable && !parent.updateValid) { + //: LABEL DESKTOP_QML The updater found an update but not all required update information are valid, this should be a very rare case. + return qsTr("An update is available but retrieving the information failed.") + } + else if (!parent.updateAvailable && parent.updateValid) { + //: LABEL DESKTOP_QML The current version is up to date, no user action is required. + return qsTr("Your version %1 of %2 is up to date.").arg(Qt.application.version).arg(Qt.application.name) + } + else { + //: LABEL DESKTOP_QML The automatic update check is disabled (or no network connection was present during app start), a manual check for update is required. + return qsTr("No update information available, please check for update manually.") + } + } + textStyle: (parent.updateAvailable || !parent.updateValid) ? Style.text.normal_warning : Style.text.normal_accent + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } } + ConfirmationPopup { + id: confirmationPopup + + //: LABEL DESKTOP_QML + title: qsTr("Delete history")+ SettingsModel.translationTrigger + //: INFO DESKTOP_QML The current history is about to be removed, user confirmation required. + text: qsTr("All history entries will be deleted.") + SettingsModel.translationTrigger + onConfirmed: SettingsModel.removeEntireHistory() + } } diff --git a/resources/qml/Governikus/SettingsView/+desktop/SettingsView.qml b/resources/qml/Governikus/SettingsView/+desktop/SettingsView.qml index 2132acca9..28c5ede3b 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/SettingsView.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/SettingsView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -14,7 +14,10 @@ import Governikus.Type.SettingsModel 1.0 import Governikus.Type.UiModule 1.0 import Governikus.Type.RemoteServiceModel 1.0 import Governikus.EnterPasswordView 1.0 -import Governikus.Type.NumberModel 1.0 +import Governikus.Type.NumberModel 1.0 +import Governikus.ProgressView 1.0 +import Governikus.ResultView 1.0 +import Governikus.UpdateView 1.0 SectionPage { @@ -23,7 +26,10 @@ SectionPage { enum SubView { None, EnterPassword, - PairingInfo + PairingInfo, + WaitForPairing, + PairingFailed, + AppUpdateView } Accessible.name: qsTr("Settings view") + SettingsModel.translationTrigger @@ -37,21 +43,26 @@ SectionPage { d.view = SettingsView.SubView.None } - isAbstract: d.view !== SettingsView.SubView.None - titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML text: qsTr("Settings") + SettingsModel.translationTrigger + helpTopic: Utils.helpTopicOf(tabbedPane.currentContentItem, "settings") onClicked: { d.view = SettingsView.SubView.None } } + Connections { + target: SettingsModel + onFireAppUpdateDataChanged: d.view = SettingsView.SubView.AppUpdateView + } + QtObject { id: d property int view: SettingsView.SubView.None + property int precedingView } TabbedPane { @@ -73,7 +84,14 @@ SectionPage { qsTr("Security and privacy") + SettingsModel.translationTrigger ] - if (plugin.developerBuild) { + if (plugin.debugBuild) { + model.push( + //: LABEL DESKTOP_QML + qsTr("Debug options") + SettingsModel.translationTrigger + ) + } + + if (SettingsModel.developerOptions) { model.push( //: LABEL DESKTOP_QML qsTr("Developer options") + SettingsModel.translationTrigger @@ -100,6 +118,11 @@ SectionPage { } } onUnpairDevice: RemoteServiceModel.forgetDevice(pDeviceId) + onMoreInformation: { + d.precedingView = d.view + d.view = TabbedReaderView.SubView.PairingInfo + appWindow.menuBar.updateActions() + } } } Component { @@ -109,8 +132,33 @@ SectionPage { } } Component { SecurityAndPrivacySettings {} } - Component { DeveloperSettings {} } } + + Component { + id: debugSettings + DebugSettings {} + } + + Component { + id: developerSettings + DeveloperSettings {} + } + + Component.onCompleted: { + if (plugin.debugBuild) { + contentObjectModel.append(debugSettings) + } + if (SettingsModel.developerOptions) { + contentObjectModel.append(developerSettings) + } + } + } + + UpdateView { + visible: d.view === SettingsView.SubView.AppUpdateView + anchors.fill: parent + + onLeaveView: d.view = SettingsView.SubView.None } EnterPasswordView { @@ -121,9 +169,10 @@ SectionPage { statusIcon: "qrc:///images/phone_to_pc.svg" passwordType: NumberModel.PASSWORD_REMOTE_PIN - onPasswordEntered: d.view = SettingsView.SubView.None + onPasswordEntered: d.view = SettingsView.SubView.WaitForPairing onRequestPasswordInfo: { + d.precedingView = d.view d.view = SettingsView.SubView.PairingInfo appWindow.menuBar.updateActions() } @@ -137,8 +186,45 @@ SectionPage { passwordType: NumberModel.PASSWORD_REMOTE_PIN onClose: { - d.view = SettingsView.SubView.EnterPassword + d.view = d.precedingView appWindow.menuBar.updateActions() } } + + ProgressView { + visible: d.view === SettingsView.SubView.WaitForPairing + + //: LABEL DESKTOP_QML + text: qsTr("Pairing the device ...") + SettingsModel.translationTrigger + + Connections { + enabled: visible + target: RemoteServiceModel + + onFirePairingFailed: { + pairingFailedView.deviceName = pDeviceName + pairingFailedView.errorMessage = pErrorMessage + d.view = SettingsView.SubView.PairingFailed + } + + onFirePairingSuccess: { + ApplicationModel.showFeedback(qsTr("The device \"%1\" has been paired.").arg(pDeviceName)) + d.view = SettingsView.SubView.None + } + } + } + + ResultView { + id: pairingFailedView + + property string deviceName + property string errorMessage + + visible: d.view === SettingsView.SubView.PairingFailed + + //: ERROR DESKTOP_QML An error occurred while pairing the device. + text: qsTr("Pairing to \"%1\" failed:").arg(deviceName) + "
\"%2\"".arg(errorMessage) + SettingsModel.translationTrigger + resultType: ResultView.Type.IsError + onNextView: d.view = SettingsView.SubView.None + } } diff --git a/resources/qml/Governikus/SettingsView/+desktop/TabbedReaderView.qml b/resources/qml/Governikus/SettingsView/+desktop/TabbedReaderView.qml index 47ece8dfb..239af2598 100644 --- a/resources/qml/Governikus/SettingsView/+desktop/TabbedReaderView.qml +++ b/resources/qml/Governikus/SettingsView/+desktop/TabbedReaderView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -18,7 +18,11 @@ SectionPage { id: root property alias rootEnabled: titleBarAction.rootEnabled - property bool showPairingInfoPopup: false + + property alias paneAnchors: tabbedPane.anchors + + readonly property int currentView: d.view + signal closeView() enum SubView { @@ -31,6 +35,7 @@ SectionPage { id: d property int view + property int precedingView } onVisibleChanged: d.view = TabbedReaderView.SubView.None @@ -40,7 +45,7 @@ SectionPage { //: LABEL DESKTOP_QML text: qsTr("Card Readers") + SettingsModel.translationTrigger - helpTopic: "readerDeviceTab" + helpTopic: Utils.helpTopicOf(tabbedPane.currentContentItem, "settings") rootEnabled: false customSubAction: CancelAction { visible: d.view === TabbedReaderView.SubView.EnterPassword @@ -54,8 +59,13 @@ SectionPage { visible: d.view === TabbedReaderView.SubView.None - anchors.fill: parent - anchors.margins: Constants.pane_padding + anchors { + top: parent.top + left: parent.left + right: parent.right + bottom: parent.bottom + margins: Constants.pane_padding + } sectionsModel: [ qsTr("Smartphone as card reader") + SettingsModel.translationTrigger, @@ -68,16 +78,16 @@ SectionPage { height: Math.max(implicitHeight, tabbedPane.availableHeight) onPairDevice: { if (RemoteServiceModel.rememberServer(pDeviceId)) { - if (showPairingInfoPopup) { - pairingInfo.open() - } - else { - d.view = TabbedReaderView.SubView.EnterPassword - appWindow.menuBar.updateActions() - } + d.view = TabbedReaderView.SubView.EnterPassword + appWindow.menuBar.updateActions() } } onUnpairDevice: RemoteServiceModel.forgetDevice(pDeviceId) + onMoreInformation: { + d.precedingView = d.view + d.view = TabbedReaderView.SubView.PairingInfo + appWindow.menuBar.updateActions() + } } } @@ -88,25 +98,19 @@ SectionPage { } } } - footerItem: Item { - height: childrenRect.height - - NavigationButton { - buttonType: Qt.BackButton - onClicked: root.closeView() - } - } } - ConfirmationPopup { - id: pairingInfo + NavigationButton { + visible: tabbedPane.visible - //: LABEL DESKTOP_QML - text: qsTr("Please start pairing mode first.") + SettingsModel.translationTrigger - onConfirmed: { - d.view = TabbedReaderView.SubView.EnterPassword - appWindow.menuBar.updateActions() + anchors { + left: parent.left + bottom: parent.bottom + margins: Constants.pane_padding } + + buttonType: NavigationButton.Type.Back + onClicked: root.closeView() } EnterPasswordView { @@ -120,6 +124,7 @@ SectionPage { onPasswordEntered: d.view = TabbedReaderView.SubView.None onRequestPasswordInfo: { + d.precedingView = d.view d.view = TabbedReaderView.SubView.PairingInfo appWindow.menuBar.updateActions() } @@ -133,7 +138,7 @@ SectionPage { passwordType: NumberModel.PASSWORD_REMOTE_PIN onClose: { - d.view = TabbedReaderView.SubView.EnterPassword + d.view = d.precedingView appWindow.menuBar.updateActions() } } diff --git a/resources/qml/Governikus/SettingsView/+mobile/LanguageSelectionPopup.qml b/resources/qml/Governikus/SettingsView/+mobile/LanguageSelectionPopup.qml new file mode 100644 index 000000000..2782dda6d --- /dev/null +++ b/resources/qml/Governikus/SettingsView/+mobile/LanguageSelectionPopup.qml @@ -0,0 +1,45 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.Type.SettingsModel 1.0 + +ConfirmationPopup { + id: baseItem + + //: LABEL ANDROID IOS + title: qsTr("Select language") + SettingsModel.translationTrigger + + style: ConfirmationPopup.PopupStyle.CancelButton + + ColumnLayout { + spacing: Constants.component_spacing + + LocationButton { + Accessible.name: qsTr("German") + SettingsModel.translationTrigger + Accessible.description: qsTr("Set language to german") + SettingsModel.translationTrigger + + language: "de" + text: "Deutsch" + image: "qrc:///images/location_flag_de.svg" + + onClicked: close() + } + + LocationButton { + Accessible.name: qsTr("English") + SettingsModel.translationTrigger + Accessible.description: qsTr("Set language to english") + SettingsModel.translationTrigger + + language: "en" + text: "English" + image: "qrc:///images/location_flag_en.svg" + + onClicked: close() + } + } +} diff --git a/resources/qml/Governikus/SettingsView/+mobile/SettingsEntry.qml b/resources/qml/Governikus/SettingsView/+mobile/SettingsEntry.qml new file mode 100644 index 000000000..3128c3226 --- /dev/null +++ b/resources/qml/Governikus/SettingsView/+mobile/SettingsEntry.qml @@ -0,0 +1,70 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.0 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 + +Item { + id: baseItem + + property alias title: titleText.text + property alias description: descriptionText.text + property var icon: "qrc:///images/arrowRight.svg" + property alias tintIcon: iconItem.tintEnabled + signal clicked() + + height: Math.max(textContainer.height, iconItem.height) + + Item { + id: textContainer + + height: titleText.height + descriptionText.height + anchors.left: parent.left + anchors.right: iconItem.left + anchors.rightMargin: Constants.component_spacing * 2 + anchors.verticalCenter: parent.verticalCenter + + GText { + id: titleText + + width: parent.width + + textStyle: Style.text.normal_accent + } + + GText { + id: descriptionText + + width: parent.width + anchors.top: titleText.bottom + anchors.topMargin: 2 + + textStyle: Style.text.normal_secondary + } + } + + TintableIcon { + id: iconItem + + width: Style.dimens.icon_size + sourceSize.height: Style.dimens.small_icon_size + anchors.right: parent.right + anchors.verticalCenter: parent.verticalCenter + + Accessible.role: Accessible.Button + Accessible.name: description + + source: baseItem.icon + tintColor: Style.color.secondary_text + } + + MouseArea { + anchors.fill: parent + + onClicked: baseItem.clicked() + } +} diff --git a/resources/qml/Governikus/SettingsView/+mobile/SettingsView.qml b/resources/qml/Governikus/SettingsView/+mobile/SettingsView.qml new file mode 100644 index 000000000..46627de4c --- /dev/null +++ b/resources/qml/Governikus/SettingsView/+mobile/SettingsView.qml @@ -0,0 +1,178 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.TitleBar 1.0 +import Governikus.View 1.0 +import Governikus.RemoteServiceView 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.RemoteServiceModel 1.0 + +SectionPage { + id: baseItem + + navigationAction: NavigationAction { state: topLevelPage ? "" : "back"; onClicked: firePop() } + //: LABEL ANDROID IOS + title: qsTr("Settings") + SettingsModel.translationTrigger + + content: Column { + id: mainColumn + + readonly property int usableWidth: width - 2 * padding + + width: baseItem.width + padding: Constants.pane_padding + spacing: Constants.component_spacing + + + TitledSeparator { + width: parent.usableWidth + topPadding: 0 + //: LABEL ANDROID IOS + title: qsTr("General") + SettingsModel.translationTrigger + } + + SettingsEntry { + width: parent.usableWidth + //: LABEL ANDROID IOS + title: qsTr("Change language") + SettingsModel.translationTrigger + icon: "qrc:///images/location_flag_%1.svg".arg(SettingsModel.language) + tintIcon: false + description: { + switch(SettingsModel.language) { + case "de": + return "Deutsch" + default: + return "English" + } + } + + onClicked: popup.open() + + LanguageSelectionPopup { + id: popup + } + } + + TitledSeparator { + width: parent.usableWidth + //: LABEL ANDROID IOS + title: qsTr("Smartphone as card reader") + SettingsModel.translationTrigger + } + + Item { + id: serverNameBase + + height: serverNameText.height + serverName.height + width: parent.usableWidth + + GText { + id: serverNameText + + width: parent.width + + //: LABEL ANDROID IOS + text: qsTr("Device name") + SettingsModel.translationTrigger + textStyle: Style.text.normal_accent + } + + GTextField { + id: serverName + + function saveInput() { + focus = false + SettingsModel.serverName = text + text = SettingsModel.serverName + } + + width: parent.width + anchors.top: serverNameText.bottom + anchors.topMargin: 2 + + Component.onCompleted: text = SettingsModel.serverName + + maximumLength: Constants.maximumDeviceNameLength + onAccepted: saveInput() + onFocusChanged: if (!focus) saveInput() + onVisibleChanged: if (!visible) saveInput() + } + } + + LabeledSwitch { + width: parent.usableWidth + + //: LABEL ANDROID IOS + title: qsTr("PIN pad mode") + SettingsModel.translationTrigger + //: LABEL ANDROID IOS + description: qsTr("Enter PIN on this device") + SettingsModel.translationTrigger + checked: SettingsModel.pinPadMode + onCheckedChanged: SettingsModel.pinPadMode = checked + } + + SettingsEntry { + width: parent.usableWidth + + //: LABEL ANDROID IOS + title: qsTr("Remote card reader") + SettingsModel.translationTrigger + //: LABEL ANDROID IOS + description: qsTr("Click here to use another smartphone as a card reader") + SettingsModel.translationTrigger + onClicked: baseItem.firePush(remoteServiceSettings) + + Component { + id: remoteServiceSettings + RemoteServiceSettings { + Component.onCompleted: RemoteServiceModel.detectRemoteDevices = true + Component.onDestruction: RemoteServiceModel.detectRemoteDevices = false + } + } + } + + TitledSeparator { + width: parent.usableWidth + + //: LABEL ANDROID IOS + title: qsTr("Security and privacy") + SettingsModel.translationTrigger + } + + LabeledSwitch { + width: parent.usableWidth + + //: LABEL ANDROID IOS + title: qsTr("Shuffle keypad buttons") + SettingsModel.translationTrigger + //: LABEL ANDROID IOS + description: qsTr("Randomize the order of the on screen keypad buttons") + SettingsModel.translationTrigger + + checked: SettingsModel.shuffleScreenKeyboard + onCheckedChanged: SettingsModel.shuffleScreenKeyboard = checked + } + + LabeledSwitch { + width: parent.usableWidth + + //: LABEL ANDROID IOS + title: qsTr("Privacy keypad") + SettingsModel.translationTrigger + //: LABEL ANDROID IOS + description: qsTr("Avoid visual feedback in the on screen keypad") + SettingsModel.translationTrigger + checked: SettingsModel.visualPrivacy + onCheckedChanged: SettingsModel.visualPrivacy = checked + } + + LabeledSwitch { + width: parent.usableWidth + + //: LABEL ANDROID IOS + title: qsTr("History") + SettingsModel.translationTrigger + //: LABEL ANDROID IOS + description: qsTr("Save authentification history") + SettingsModel.translationTrigger + checked: SettingsModel.historyEnabled + onCheckedChanged: SettingsModel.historyEnabled = checked + } + } +} diff --git a/resources/qml/Governikus/SettingsView/qmldir b/resources/qml/Governikus/SettingsView/qmldir index cfab5a329..77f04b95f 100644 --- a/resources/qml/Governikus/SettingsView/qmldir +++ b/resources/qml/Governikus/SettingsView/qmldir @@ -4,7 +4,10 @@ internal CardReaderDelegate CardReaderDelegate.qml internal RemoteReaderDelegate RemoteReaderDelegate.qml internal GeneralSettings GeneralSettings.qml internal DeveloperSettings DeveloperSettings.qml +internal DebugSettings DebugSettings.qml internal SecurityAndPrivacySettings SecurityAndPrivacySettings.qml +internal SettingsEntry SettingsEntry.qml +internal LanguageSelectionPopup LanguageSelectionPopup.qml CardReaderView 1.0 CardReaderView.qml RemoteReaderView 1.0 RemoteReaderView.qml diff --git a/resources/qml/Governikus/SplashScreen/SplashScreen.qml b/resources/qml/Governikus/SplashScreen/SplashScreen.qml index 70c183081..1d633d144 100644 --- a/resources/qml/Governikus/SplashScreen/SplashScreen.qml +++ b/resources/qml/Governikus/SplashScreen/SplashScreen.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -8,9 +8,12 @@ import Governikus.Style 1.0 Rectangle { id: splashScreen + visible: true anchors.fill: parent + color: Style.color.background + signal fireHiding() readonly property var startTime: new Date().getTime() diff --git a/resources/qml/Governikus/Style/+desktop/HighContrastColors.qml b/resources/qml/Governikus/Style/+desktop/HighContrastColors.qml new file mode 100644 index 000000000..93a2922ed --- /dev/null +++ b/resources/qml/Governikus/Style/+desktop/HighContrastColors.qml @@ -0,0 +1,41 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 + +Colors { + readonly property var palette: SystemPalette { colorGroup: SystemPalette.Active } + readonly property var disabledPalette: SystemPalette { colorGroup: SystemPalette.Disabled } + + readonly property color shadow: transparent + readonly property color high_contrast_item_border: palette.text + readonly property color border: palette.text + + readonly property color primary_text: palette.text + readonly property color primary_text_inverse: palette.text + readonly property color secondary_text: palette.text + readonly property color secondary_text_inverse: palette.text + readonly property color accent_text: palette.text + readonly property color accent_text_inverse: palette.text + readonly property color warning_text: "#ff0000" + + readonly property color background: palette.base + readonly property color background_popup: background + readonly property color background_pane: background + readonly property color background_pane_active: background + readonly property color background_pane_inactive: background + + readonly property color accent: palette.highlight + readonly property color accent_disabled: disabledPalette.highlight + + readonly property color button: palette.button + readonly property color button_disabled: disabledPalette.button + readonly property color button_text: palette.text + readonly property color button_text_disabled: disabledPalette.text + + readonly property color navigation: background_pane + + readonly property color focus_indicator: primary_text + readonly property color focus_indicator_inverse: primary_text_inverse +} diff --git a/resources/qml/Governikus/Style/+desktop/HighContrastDimensions.qml b/resources/qml/Governikus/Style/+desktop/HighContrastDimensions.qml new file mode 100644 index 000000000..4c174ae63 --- /dev/null +++ b/resources/qml/Governikus/Style/+desktop/HighContrastDimensions.qml @@ -0,0 +1,12 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQml 2.10 +import Governikus.Type.ApplicationModel 1.0 + +Dimensions { + readonly property int tabbed_pane_separator_size: 0 + + readonly property int high_contrast_item_border: Math.max(ApplicationModel.scaleFactor * 2, 1) +} diff --git a/resources/qml/Governikus/Style/+desktop/PlatformColors.qml b/resources/qml/Governikus/Style/+desktop/PlatformColors.qml index f2dfffdd1..3d8b31b86 100644 --- a/resources/qml/Governikus/Style/+desktop/PlatformColors.qml +++ b/resources/qml/Governikus/Style/+desktop/PlatformColors.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQml 2.10 @@ -7,18 +7,11 @@ import QtQml 2.10 QtObject { readonly property color border: "#bbbbbb" - readonly property color background: "#659bcd" + readonly property color background: "#6399cb" readonly property color background_popup: background readonly property color background_pane: "#ffffff" - readonly property color background_pane_active: "#d0e1f0" + readonly property color background_pane_active: "#d5d5dc" + readonly property color background_pane_inactive: "#d0e1f0" - readonly property color accent: "#5481ab" - readonly property color accent_disabled: "#d0d0d0" - - readonly property color primary_text: "#ffffff" - readonly property color primary_text_inverse: "#333333" - readonly property color secondary_text: "#dadada" - readonly property color secondary_text_inverse: "#666666" - readonly property color warning_text: "#cc0000" - readonly property color button_text: "#ffffff" + readonly property color navigation: accent } diff --git a/resources/qml/Governikus/Style/+desktop/PlatformDimensions.qml b/resources/qml/Governikus/Style/+desktop/PlatformDimensions.qml index 3b2d3f6e2..4ab2fc01d 100644 --- a/resources/qml/Governikus/Style/+desktop/PlatformDimensions.qml +++ b/resources/qml/Governikus/Style/+desktop/PlatformDimensions.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQml 2.10 @@ -9,17 +9,27 @@ QtObject { readonly property int title_font_size: ApplicationModel.scaleFactor * 42 readonly property int header_font_size: ApplicationModel.scaleFactor * 32 readonly property int normal_font_size: ApplicationModel.scaleFactor * 26 - readonly property int hint_font_size: ApplicationModel.scaleFactor * 20 + readonly property int hint_font_size: ApplicationModel.scaleFactor * 22 readonly property int corner_radius: ApplicationModel.scaleFactor * 20 readonly property int corner_radius_popup: corner_radius readonly property int button_radius: ApplicationModel.scaleFactor * 15 readonly property int separator_size: Math.max(ApplicationModel.scaleFactor * 2, 1) + readonly property int tabbed_pane_separator_size: Math.max(ApplicationModel.scaleFactor * 4, 1) readonly property real max_text_width: ApplicationModel.scaleFactor * 1000 + readonly property int list_item_height: ApplicationModel.scaleFactor * 64 + readonly property int high_contrast_item_border: ApplicationModel.scaleFactor * 0 readonly property int titlebar_padding: ApplicationModel.scaleFactor * 20 + readonly property int scrollbar_padding_vertical: ApplicationModel.scaleFactor * 0 + readonly property int scrollbar_padding_horizontal: ApplicationModel.scaleFactor * 5 + readonly property int scrollbar_width: ApplicationModel.scaleFactor * 10 + readonly property int status_icon_large: ApplicationModel.scaleFactor * 350 readonly property int status_icon_medium: ApplicationModel.scaleFactor * 200 readonly property int status_icon_small: ApplicationModel.scaleFactor * 100 + + readonly property int icon_size: ApplicationModel.scaleFactor * 48 + readonly property int large_icon_size: ApplicationModel.scaleFactor * 72 } diff --git a/resources/qml/Governikus/Style/+desktop/PlatformTextStyles.qml b/resources/qml/Governikus/Style/+desktop/PlatformTextStyles.qml index 1ffb07607..559963e55 100644 --- a/resources/qml/Governikus/Style/+desktop/PlatformTextStyles.qml +++ b/resources/qml/Governikus/Style/+desktop/PlatformTextStyles.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Style/+mobile/+android/BrandColors.qml b/resources/qml/Governikus/Style/+mobile/+android/BrandColors.qml index 198819149..14dfa8cd2 100644 --- a/resources/qml/Governikus/Style/+mobile/+android/BrandColors.qml +++ b/resources/qml/Governikus/Style/+mobile/+android/BrandColors.qml @@ -1,8 +1,9 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQml 2.10 QtObject { + readonly property color menu_icon_tint_color: "#86858A" } diff --git a/resources/qml/Governikus/Style/+mobile/+android/BrandDimensions.qml b/resources/qml/Governikus/Style/+mobile/+android/BrandDimensions.qml index 2414bbb7f..b470834ae 100644 --- a/resources/qml/Governikus/Style/+mobile/+android/BrandDimensions.qml +++ b/resources/qml/Governikus/Style/+mobile/+android/BrandDimensions.qml @@ -1,15 +1,13 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import Governikus.Global 1.0 QtObject { - readonly property int corner_radius: 20 readonly property int corner_radius_popup: 2 - readonly property int button_height: 36 readonly property int menubar_width: 64 readonly property int title_font_size: 22 diff --git a/resources/qml/Governikus/Style/+mobile/+android/PlatformTextStyles.qml b/resources/qml/Governikus/Style/+mobile/+android/PlatformTextStyles.qml index 60874d284..656b9d4dd 100644 --- a/resources/qml/Governikus/Style/+mobile/+android/PlatformTextStyles.qml +++ b/resources/qml/Governikus/Style/+mobile/+android/PlatformTextStyles.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Style/+mobile/+ios/BrandColors.qml b/resources/qml/Governikus/Style/+mobile/+ios/BrandColors.qml index 198819149..8007d81a0 100644 --- a/resources/qml/Governikus/Style/+mobile/+ios/BrandColors.qml +++ b/resources/qml/Governikus/Style/+mobile/+ios/BrandColors.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQml 2.10 diff --git a/resources/qml/Governikus/Style/+mobile/+ios/BrandDimensions.qml b/resources/qml/Governikus/Style/+mobile/+ios/BrandDimensions.qml index db2bfcbc1..0a94aa829 100644 --- a/resources/qml/Governikus/Style/+mobile/+ios/BrandDimensions.qml +++ b/resources/qml/Governikus/Style/+mobile/+ios/BrandDimensions.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -7,10 +7,8 @@ import QtQuick.Window 2.2 import Governikus.Global 1.0 QtObject { - readonly property int corner_radius: 10 readonly property int corner_radius_popup: corner_radius - readonly property int button_height: 40 readonly property int tabbar_height: 49 readonly property int searchbar_height: 48 diff --git a/resources/qml/Governikus/Style/+mobile/+ios/PlatformTextStyles.qml b/resources/qml/Governikus/Style/+mobile/+ios/PlatformTextStyles.qml index 77378f394..baa095dea 100644 --- a/resources/qml/Governikus/Style/+mobile/+ios/PlatformTextStyles.qml +++ b/resources/qml/Governikus/Style/+mobile/+ios/PlatformTextStyles.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Style/+mobile/HighContrastColors.qml b/resources/qml/Governikus/Style/+mobile/HighContrastColors.qml new file mode 100644 index 000000000..53515d2ac --- /dev/null +++ b/resources/qml/Governikus/Style/+mobile/HighContrastColors.qml @@ -0,0 +1,9 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 + +Colors { + +} diff --git a/resources/qml/Governikus/Style/+mobile/HighContrastDimensions.qml b/resources/qml/Governikus/Style/+mobile/HighContrastDimensions.qml new file mode 100644 index 000000000..726edd359 --- /dev/null +++ b/resources/qml/Governikus/Style/+mobile/HighContrastDimensions.qml @@ -0,0 +1,9 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQml 2.10 + +Dimensions { + +} diff --git a/resources/qml/Governikus/Style/+mobile/PlatformColors.qml b/resources/qml/Governikus/Style/+mobile/PlatformColors.qml index b1ddf3f5c..b2a9b7bfe 100644 --- a/resources/qml/Governikus/Style/+mobile/PlatformColors.qml +++ b/resources/qml/Governikus/Style/+mobile/PlatformColors.qml @@ -1,31 +1,22 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ BrandColors { - readonly property color border: "#ebebeb" - readonly property color border_dark: "#dadada" + readonly property color border: "#a0858585" readonly property color background: "#dcebf6" readonly property color background_popup: "#ffffff" readonly property color background_pane: "#ffffff" + readonly property color background_pane_active: "#d5d5dc" - readonly property color accent: "#659bcd" - readonly property color accent_disabled: "#d0d0d0" - - readonly property color primary_text: "#333333" - readonly property color primary_text_inverse: "#ffffff" - readonly property color secondary_text: "#666666" - readonly property color secondary_text_inverse: "#dadada" readonly property color warning_text: "#cc0000" - readonly property color button_text: "#ffffff" readonly property color tutorial_what: "#f9a501" readonly property color tutorial_where: "#73d7b3" - readonly property color tutorial_how: "#659bcd" + readonly property color tutorial_how: "#4d7aa4" readonly property color tutorial_important: "#fb7a59" readonly property color tutorial_box_background: "#f2f2f2" readonly property color card_reader: "#444445" - readonly property color id_card: "#77add7" } diff --git a/resources/qml/Governikus/Style/+mobile/PlatformDimensions.qml b/resources/qml/Governikus/Style/+mobile/PlatformDimensions.qml index b2cd21ed1..2b1d88cae 100644 --- a/resources/qml/Governikus/Style/+mobile/PlatformDimensions.qml +++ b/resources/qml/Governikus/Style/+mobile/PlatformDimensions.qml @@ -1,16 +1,20 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQml 2.10 import Governikus.Global 1.0 BrandDimensions { - readonly property int button_radius: 3 + readonly property int button_radius: 6 + readonly property int corner_radius: 10 readonly property int separator_size: 1 readonly property int list_item_height: 64 - readonly property int scrollbar_padding: 5 + readonly property int scrollbar_padding_vertical: 5 + readonly property int scrollbar_padding_horizontal: 0 + readonly property int scrollbar_width: 5 readonly property int tutorial_component_spacing: 40 + readonly property int high_contrast_item_border: 0 readonly property int titlebar_height: 48 readonly property int titlebar_padding: 8 diff --git a/resources/qml/Governikus/Style/Colors.qml b/resources/qml/Governikus/Style/Colors.qml index 16379263b..1d06908bc 100644 --- a/resources/qml/Governikus/Style/Colors.qml +++ b/resources/qml/Governikus/Style/Colors.qml @@ -1,8 +1,30 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ PlatformColors { readonly property color transparent: "transparent" + + readonly property color shadow: "#808080" + readonly property color high_contrast_item_border: transparent + + readonly property color primary_text: "#333333" + readonly property color primary_text_inverse: "#ffffff" + readonly property color secondary_text: "#666666" + readonly property color secondary_text_inverse: "#dadada" + readonly property color accent_text: accent + readonly property color accent_text_inverse: "#cde1f3" + readonly property color warning_text: "#cc0000" + + readonly property color accent: "#4d7aa4" + readonly property color accent_disabled: "#d0d0d0" + + readonly property color button: accent + readonly property color button_disabled: accent_disabled + readonly property color button_text: primary_text_inverse + readonly property color button_text_disabled: secondary_text + + readonly property color focus_indicator: primary_text + readonly property color focus_indicator_inverse: primary_text_inverse } diff --git a/resources/qml/Governikus/Style/Dimensions.qml b/resources/qml/Governikus/Style/Dimensions.qml index 0b0e2fd00..69570662f 100644 --- a/resources/qml/Governikus/Style/Dimensions.qml +++ b/resources/qml/Governikus/Style/Dimensions.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ PlatformDimensions { diff --git a/resources/qml/Governikus/Style/NpaBusyIndicatorStyle.qml b/resources/qml/Governikus/Style/NpaBusyIndicatorStyle.qml index 3e1281ac3..d3fb7cf0f 100644 --- a/resources/qml/Governikus/Style/NpaBusyIndicatorStyle.qml +++ b/resources/qml/Governikus/Style/NpaBusyIndicatorStyle.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -8,8 +8,9 @@ import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 +import Governikus.Type.Random 1.0 - Item { +Item { property real factor: 1.1 id: busyIndicator @@ -61,8 +62,8 @@ import Governikus.Style 1.0 id: timer interval: 1000; repeat: true onTriggered: { - green.rotation = green.rotation + Utils.getRandomInt(0, 135) - blue.rotation = blue.rotation + Utils.getRandomInt(0, 195) + green.rotation = green.rotation + Random.randomInt(0, 134) + blue.rotation = blue.rotation + Random.randomInt(0, 194) busyIndicator.rotation = busyIndicator.rotation + 100 } } diff --git a/resources/qml/Governikus/Style/Style.qml b/resources/qml/Governikus/Style/Style.qml index 19970c0f8..4de70f454 100644 --- a/resources/qml/Governikus/Style/Style.qml +++ b/resources/qml/Governikus/Style/Style.qml @@ -1,13 +1,36 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ pragma Singleton -import QtQml 2.10 +import QtQuick 2.10 -QtObject { - property var text: TextStyles {} - property var color: Colors {} - property var dimens: Dimensions {} +Item { + id: style + + QtObject { + id: highContrastTheme + + readonly property var text: TextStyles {} + readonly property var color: HighContrastColors {} + readonly property var dimens: HighContrastDimensions {} + + property bool highContrast: true + } + + QtObject { + id: defaultTheme + + readonly property var text: TextStyles {} + readonly property var color: Colors {} + readonly property var dimens: Dimensions {} + + readonly property bool highContrast: false + } + + readonly property var currentTheme: plugin.highContrastEnabled ? highContrastTheme : defaultTheme + readonly property var text: currentTheme.text + readonly property var color: currentTheme.color + readonly property var dimens: currentTheme.dimens } diff --git a/resources/qml/Governikus/Style/TextStyle.qml b/resources/qml/Governikus/Style/TextStyle.qml index 4002b28d7..95f9c7f31 100644 --- a/resources/qml/Governikus/Style/TextStyle.qml +++ b/resources/qml/Governikus/Style/TextStyle.qml @@ -1,11 +1,12 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 QtObject { property color textColor: Style.color.primary_text + property color linkColor: Style.color.accent_text property int textSize: Style.dimens.normal_font_size /// An empty string means "unspecified" diff --git a/resources/qml/Governikus/Style/TextStyles.qml b/resources/qml/Governikus/Style/TextStyles.qml index 35cea28b1..b1023e1f6 100644 --- a/resources/qml/Governikus/Style/TextStyles.qml +++ b/resources/qml/Governikus/Style/TextStyles.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -10,6 +10,12 @@ PlatformTextStyles { textSize: Style.dimens.title_font_size } + readonly property var title_inverse: TextStyle { + textSize: Style.dimens.title_font_size + textColor: Style.color.primary_text_inverse + linkColor: Style.color.accent_text_inverse + } + readonly property var title_secondary: TextStyle { textSize: Style.dimens.title_font_size textColor: Style.color.secondary_text @@ -17,7 +23,7 @@ PlatformTextStyles { readonly property var title_accent: TextStyle { textSize: Style.dimens.title_font_size - textColor: Style.color.accent + textColor: Style.color.accent_text } readonly property var title_warning: TextStyle { @@ -32,6 +38,7 @@ PlatformTextStyles { readonly property var header_inverse: TextStyle { textSize: Style.dimens.header_font_size textColor: Style.color.primary_text_inverse + linkColor: Style.color.accent_text_inverse } readonly property var header_secondary: TextStyle { @@ -42,11 +49,12 @@ PlatformTextStyles { readonly property var header_secondary_inverse: TextStyle { textSize: Style.dimens.header_font_size textColor: Style.color.secondary_text_inverse + linkColor: Style.color.accent_text_inverse } readonly property var header_accent: TextStyle { textSize: Style.dimens.header_font_size - textColor: Style.color.accent + textColor: Style.color.accent_text } readonly property var header_warning: TextStyle { @@ -58,6 +66,7 @@ PlatformTextStyles { readonly property var normal_inverse: TextStyle { textColor: Style.color.primary_text_inverse + linkColor: Style.color.accent_text_inverse } readonly property var normal_secondary: TextStyle { @@ -66,10 +75,11 @@ PlatformTextStyles { readonly property var normal_secondary_inverse: TextStyle { textColor: Style.color.secondary_text_inverse + linkColor: Style.color.accent_text_inverse } readonly property var normal_accent: TextStyle { - textColor: Style.color.accent + textColor: Style.color.accent_text } readonly property var normal_warning: TextStyle { @@ -83,6 +93,7 @@ PlatformTextStyles { readonly property var hint_inverse: TextStyle { textSize: Style.dimens.hint_font_size textColor: Style.color.primary_text_inverse + linkColor: Style.color.accent_text_inverse } readonly property var hint_secondary: TextStyle { @@ -93,11 +104,12 @@ PlatformTextStyles { readonly property var hint_secondary_inverse: TextStyle { textSize: Style.dimens.hint_font_size textColor: Style.color.secondary_text_inverse + linkColor: Style.color.accent_text_inverse } readonly property var hint_accent: TextStyle { textSize: Style.dimens.hint_font_size - textColor: Style.color.accent + textColor: Style.color.accent_text } readonly property var hint_warning: TextStyle { @@ -110,6 +122,6 @@ PlatformTextStyles { } readonly property var button_disabled: TextStyle { - textColor: Style.color.secondary_text_inverse + textColor: Style.color.button_text_disabled } } diff --git a/resources/qml/Governikus/Style/qmldir b/resources/qml/Governikus/Style/qmldir index 9950fbdb6..79b8fd5c7 100644 --- a/resources/qml/Governikus/Style/qmldir +++ b/resources/qml/Governikus/Style/qmldir @@ -3,6 +3,8 @@ module Style internal BrandColors BrandColors.qml internal BrandDimensions BrandDimensions.qml internal Colors Colors.qml +internal HighContrastColors HighContrastColors.qml +internal HighContrastDimensions HighContrastDimensions.qml internal PlatformColors PlatformColors.qml internal TextStyles TextStyles.qml internal PlatformTextStyles PlatformTextStyles.qml diff --git a/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologyInfo.qml b/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologyInfo.qml index e62fe21c7..c4ebbb717 100644 --- a/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologyInfo.qml +++ b/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologyInfo.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologySwitch.qml b/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologySwitch.qml index f8ec4f1d0..1e8845c33 100644 --- a/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologySwitch.qml +++ b/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologySwitch.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologySwitchButton.qml b/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologySwitchButton.qml index ba5b888de..821eed6c9 100644 --- a/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologySwitchButton.qml +++ b/resources/qml/Governikus/TechnologyInfo/+mobile/TechnologySwitchButton.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -25,8 +25,8 @@ MouseArea { GSeparator { width: parent.width * 1.5 anchors.horizontalCenter: parent.horizontalCenter - color: Style.color.border_dark } + Image { id: img anchors.top: parent.top @@ -36,6 +36,7 @@ MouseArea { fillMode: Image.PreserveAspectFit smooth: true } + GText { id: infoText @@ -45,25 +46,16 @@ MouseArea { Accessible.ignored: true - textStyle: Style.text.normal_accent + textStyle: (!parent.enabled || buttonActive) ? Style.text.normal_secondary : Style.text.normal_accent } + Colorize { id: grayLevel source: img anchors.fill: img saturation: 0 hue: 0 - lightness: 0.3 - cached: true - visible: !parent.enabled || buttonActive - } - Colorize { - id: grayLevel2 - source: infoText - anchors.fill: infoText - saturation: 0 - hue: 0 - lightness: 0.3 + lightness: 0.0 cached: true visible: !parent.enabled || buttonActive } diff --git a/resources/qml/Governikus/TitleBar/+desktop/CancelAction.qml b/resources/qml/Governikus/TitleBar/+desktop/CancelAction.qml index d8e281c5d..6d5d34f71 100644 --- a/resources/qml/Governikus/TitleBar/+desktop/CancelAction.qml +++ b/resources/qml/Governikus/TitleBar/+desktop/CancelAction.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -12,55 +12,28 @@ import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SettingsModel 1.0 -Button { - id: button - visible: ApplicationModel.currentWorkflow !== "" - - Accessible.role: Accessible.Button - Accessible.name: qsTr("Cancel") + SettingsModel.translationTrigger - - background: Row { - id: row - spacing: ApplicationModel.scaleFactor * 20 - - Rectangle { - height: text.height - width: Math.max(ApplicationModel.scaleFactor * 2, 1) - } +GButton { + readonly property color pressColor: Qt.darker(textStyle.textColor, Constants.highlightDarkerFactor) - Image { - sourceSize.height: text.height - source: "qrc:///images/cancel.svg" - } - - Item { - id: text - height: sizeBase.height - width: sizeBase.width - readonly property GText sizeBase: GText { - text: qsTr("Cancel") + SettingsModel.translationTrigger - textStyle: Style.text.header - font.bold: true - } + visible: ApplicationModel.currentWorkflow !== "" - FocusFrame { - scope: button - } + text: qsTr("Cancel") + SettingsModel.translationTrigger + textStyle: Style.text.header_inverse + buttonColor: Style.color.transparent + icon.source: "qrc:///images/cancel.svg" + font.bold: true + tintIcon: true + padding: 0 + leftPadding: Constants.component_spacing + rightPadding: Constants.component_spacing + textHighlightColor: pressed ? pressColor : textStyle.textColor - GText { - anchors.centerIn: parent + GSeparator { + visible: !Style.currentTheme.highContrast - text: text.sizeBase.text - textStyle: Style.text.header - font.bold: true - font.pixelSize: Style.text.header.textSize * (button.down ? 0.9 : 1) - } - } - } + height: parent.height - MouseArea { - cursorShape: Qt.PointingHandCursor - anchors.fill: parent - onPressed: mouse.accepted = false + orientation: Qt.Vertical + color: Style.text.header_inverse.textColor } } diff --git a/resources/qml/Governikus/TitleBar/+desktop/Notifications.qml b/resources/qml/Governikus/TitleBar/+desktop/Notifications.qml index b67976adf..ce9bb584b 100644 --- a/resources/qml/Governikus/TitleBar/+desktop/Notifications.qml +++ b/resources/qml/Governikus/TitleBar/+desktop/Notifications.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -10,6 +10,7 @@ import Governikus.Style 1.0 import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.NotificationModel 1.0 import Governikus.Type.SettingsModel 1.0 +import Governikus.View 1.0 Item { @@ -17,20 +18,21 @@ Item { visible: SettingsModel.showInAppNotifications - readonly property string icon: { + readonly property color iconColor: { if (d.unreadMsg) { - if (NotificationModel.lastType === "developermode") return "qrc:///images/desktop/bell_red.svg" - if (NotificationModel.lastType === "feedback") return "qrc:///images/desktop/bell_green.svg" + if (NotificationModel.lastType === "developermode") return Constants.red + if (NotificationModel.lastType === "feedback") return Constants.green } - return "qrc:///images/desktop/bell_white.svg" + return Style.text.header_inverse.textColor } signal newNotification() function toggle() { if (!fadingAnimation.running) d.fadeIn = !d.fadeIn if (d.fadeIn) { logEntryList.positionViewAtEnd() - d.unreadMsg = false } + d.unreadMsg = false + fadeOutTimer.stop() } QtObject { @@ -40,12 +42,10 @@ Item { property bool unreadMsg: false } - Connections { - target: NotificationModel - onRowsInserted: { - if (!d.fadeIn) d.unreadMsg = true - baseItem.newNotification() - } + Timer { + id: fadeOutTimer + interval: 1800 // The notification button blinks 3 times for 600ms + onTriggered: d.fadeIn = false } Rectangle { @@ -62,7 +62,7 @@ Item { radius: logEntryList.spacing border.color: Constants.blue border.width: Math.max(1, ApplicationModel.scaleFactor * 3) - color: Qt.lighter(Constants.blue, 1.15) + color: Style.color.background Behavior on anchors.bottomMargin { PropertyAnimation { @@ -76,37 +76,71 @@ Item { anchors.fill: parent } - ListView { + GListView { id: logEntryList anchors.fill: parent - anchors.margins: spacing - anchors.rightMargin: 2 * spacing + anchors.topMargin: logList.radius + anchors.rightMargin: spacing + anchors.bottomMargin: logList.border.width clip: true - spacing: ApplicationModel.scaleFactor * 10 + spacing: Constants.text_spacing + topMargin: spacing + bottomMargin: spacing + leftMargin: spacing + scrollBarTopPadding: spacing + scrollBarBottomPadding: spacing model: NotificationModel - delegate: Row { - spacing: logEntryList.spacing + delegate: Item { + width: row.width + height: row.height - GText { - id: notificationTime + activeFocusOnTab: d.fadeIn && !fadeOutTimer.running + Accessible.name: notificationTime.text + " " + notificationBody.text - text: model.time - } + Row { + id: row + + spacing: logEntryList.spacing + + Component.onCompleted: { + d.unreadMsg = true + if (!d.fadeIn) { + d.fadeIn = true + fadeOutTimer.restart() + } + if (fadeOutTimer.running) { + // Calling logEntryList.positionViewAtEnd() only works unreliably. + // Delay it so that the ListView has *really* completed adding the Row: + positionViewAtEndTimer.restart() + } + baseItem.newNotification() + } + + GText { + id: notificationTime + + text: model.time + } + + GText { + id: notificationBody - GText { - width: logEntryList.width - notificationTime.width - spacing + width: logEntryList.width - notificationTime.width - 3 * logEntryList.spacing - text: model.text - textStyle: model.type === "developermode" ? Style.text.normal_warning : Style.text.normal + text: model.text + textStyle: model.type === "developermode" ? Style.text.normal_warning : Style.text.normal_inverse - onLinkActivated: Qt.openUrlExternally(link) + } } + FocusFrame {} } - ScrollBar.vertical: ScrollBar { - policy: ScrollBar.AlwaysOn + Timer { + id: positionViewAtEndTimer + interval: 1 + onTriggered: logEntryList.positionViewAtEnd() } } } diff --git a/resources/qml/Governikus/TitleBar/+desktop/TitleBar.qml b/resources/qml/Governikus/TitleBar/+desktop/TitleBar.qml index 7751d398c..4772894f0 100644 --- a/resources/qml/Governikus/TitleBar/+desktop/TitleBar.qml +++ b/resources/qml/Governikus/TitleBar/+desktop/TitleBar.qml @@ -1,8 +1,9 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -42,47 +43,76 @@ Item { } } - Notifications { - id: notifications - - anchors.right: parent.right - anchors.top: parent.bottom - - onNewNotification: notifyButton.notify() - } - Rectangle { anchors.fill: parent - color: Constants.blue + color: Style.color.navigation + + GSeparator { + anchors { + bottom: parent.bottom + left: parent.left + right: parent.right + } + + height: Style.dimens.high_contrast_item_border + color: Style.color.high_contrast_item_border + } FocusPoint { scope: titleBar } - Row { - id: actionRow - - height: rootAction.height + Item { + height: parent.height anchors.left: parent.left - anchors.leftMargin: Style.dimens.titlebar_padding - anchors.verticalCenter: parent.verticalCenter + anchors.right: rightTitleBarActions.left + anchors.rightMargin: Style.dimens.titlebar_padding - spacing: Style.dimens.titlebar_padding + clip: true + + Row { + id: actionRow - readonly property Item lastAction: children && children.length > 0 ? children[children.length - 1] : rootAction + height: rootAction.height + anchors.leftMargin: Style.dimens.titlebar_padding + anchors.verticalCenter: parent.verticalCenter + anchors.left: parent.left + anchors.right: parent.right - TitleBarAction { - id: rootAction + spacing: Style.dimens.titlebar_padding - activeFocusOnTab: true + readonly property bool childrenFitSpace: childrenRect.width <= width + readonly property Item lastAction: children && children.length > 0 ? children[children.length - 1] : rootAction - showArrow: false - //: LABEL DESKTOP_QML - text: qsTr("Start") + SettingsModel.translationTrigger - enabled: rightMostAction.rootEnabled + TitleBarAction { + id: rootAction - onClicked: titleBar.rootClicked() + activeFocusOnTab: true + + showArrow: false + //: LABEL DESKTOP_QML + text: qsTr("Start") + SettingsModel.translationTrigger + enabled: rightMostAction.rootEnabled + helpTopic: "applicationOverview" + + onClicked: titleBar.rootClicked() + } + } + } + + LinearGradient { + visible: !actionRow.childrenFitSpace + height: parent.height + width: Constants.pane_padding + anchors.right: rightTitleBarActions.left + anchors.rightMargin: Style.dimens.titlebar_padding + + start: Qt.point(0, 0) + end: Qt.point(Constants.pane_padding, 0) + gradient: Gradient { + GradientStop { position: 0.0; color: Style.color.transparent } + GradientStop { position: 1.0; color: Constants.blue } } } @@ -95,22 +125,22 @@ Item { anchors.margins: Style.dimens.titlebar_padding spacing: Style.dimens.titlebar_padding - children: [ - rightMostAction.customSubAction, - settingsButton, - helpButton, - notifyButton - ] + Item { + height: parent.height + width: childrenRect.width + + data: rightMostAction.customSubAction + } TitleBarButton { id: settingsButton height: rightTitleBarActions.height - source: "qrc:///images/desktop/settings_icon.svg" + source: "qrc:///images/settings_icon.svg" visible: rightMostAction.showSettings - activeFocusOnTab: true - Accessible.name: qsTr("Settings") + SettingsModel.translationTrigger + text: qsTr("Settings") + SettingsModel.translationTrigger + Accessible.description: qsTr("Open settings view of %1").arg(Qt.application.name) + SettingsModel.translationTrigger onClicked: rightMostAction.settingsHandler() } @@ -122,8 +152,8 @@ Item { source: "qrc:///images/desktop/info_manual.svg" visible: rightMostAction.showHelp - activeFocusOnTab: true - Accessible.name: qsTr("Help") + SettingsModel.translationTrigger + text: qsTr("Help") + SettingsModel.translationTrigger + Accessible.description: qsTr("Open the online help of %1").arg(Qt.application.name) + SettingsModel.translationTrigger onClicked: ApplicationModel.openOnlineHelp(rightMostAction.helpTopic) } @@ -132,14 +162,25 @@ Item { id: notifyButton height: rightTitleBarActions.height - source: notifications.icon + source: "qrc:///images/desktop/bell.svg" + iconColor: notifications.iconColor visible: SettingsModel.showInAppNotifications - activeFocusOnTab: true - Accessible.name: qsTr("Notifications") + SettingsModel.translationTrigger + text: qsTr("Notifications") + SettingsModel.translationTrigger + Accessible.description: qsTr("Show the in-app notifications of %1").arg(Qt.application.name) + SettingsModel.translationTrigger onClicked: notifications.toggle() } } } + + Notifications { + id: notifications + + z: -1 // Draw below the title bar, but place Notifications after the notifyButton, so that the tab order makes sense + anchors.right: parent.right + anchors.top: parent.bottom + + onNewNotification: notifyButton.notify() + } } diff --git a/resources/qml/Governikus/TitleBar/+desktop/TitleBarAction.qml b/resources/qml/Governikus/TitleBar/+desktop/TitleBarAction.qml index 26a5cfb0f..a50769926 100644 --- a/resources/qml/Governikus/TitleBar/+desktop/TitleBarAction.qml +++ b/resources/qml/Governikus/TitleBar/+desktop/TitleBarAction.qml @@ -1,11 +1,12 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import Governikus.Global 1.0 import Governikus.Style 1.0 +import Governikus.Type.ApplicationModel 1.0 import Governikus.View 1.0 FocusScope { @@ -42,27 +43,35 @@ FocusScope { height: text.height spacing: Style.dimens.titlebar_padding - Image { + TintableIcon { id: arrow - sourceSize.height: text.height / 2.5 - anchors.verticalCenter: text.verticalCenter - anchors.verticalCenterOffset: height / 6 + + sourceSize.width: Style.dimens.icon_size + anchors.bottom: text.baseline + anchors.bottomMargin: 1 * ApplicationModel.scaleFactor + source: "qrc:///images/desktop/titlebar_arrow.svg" + tintColor: text.textStyle.textColor } TitleBarText { id: text + readonly property color textColor: scope.enabled ? Style.text.header_inverse.textColor : Style.text.header_secondary_inverse.textColor + readonly property color pressColor: Qt.darker(textColor, Constants.highlightDarkerFactor) + Accessible.role: Accessible.Button Accessible.name: text.text - color: scope.enabled ? Constants.white : Constants.lightgrey + color: mouseArea.containsPress ? pressColor : textColor FocusFrame { scope: scope } MouseArea { + id: mouseArea + anchors.fill: parent cursorShape: Qt.PointingHandCursor onPressed: scope.focus = true diff --git a/resources/qml/Governikus/TitleBar/+desktop/TitleBarButton.qml b/resources/qml/Governikus/TitleBar/+desktop/TitleBarButton.qml index 55b679fca..ded44355a 100644 --- a/resources/qml/Governikus/TitleBar/+desktop/TitleBarButton.qml +++ b/resources/qml/Governikus/TitleBar/+desktop/TitleBarButton.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -7,6 +7,7 @@ import QtQuick.Controls 2.3 import Governikus.Global 1.0 import Governikus.View 1.0 +import Governikus.Style 1.0 import Governikus.Type.NotificationModel 1.0 @@ -14,25 +15,36 @@ Button { id: button property alias source: image.source + property color iconColor: Style.text.header_inverse.textColor function notify() { blinkerAnimation.start() } width: height - Accessible.role: Accessible.Button - enabled: visible - background: Image { - id: image - height: button.height * (button.down ? 0.9 : 1) + padding: 0 + background: Item {} + contentItem: Item { + + height: button.height width: height anchors.centerIn: parent - sourceSize.height: height - sourceSize.width: width + TintableIcon { + id: image + + readonly property color pressColor: Qt.darker(iconColor, Constants.highlightDarkerFactor) + + anchors.fill: parent + + sourceSize.height: height + sourceSize.width: width + + tintColor: button.pressed ? pressColor : iconColor + } Rectangle { id: blinker @@ -69,7 +81,7 @@ Button { ToolTip { visible: mouseArea.containsMouse - text: parent.Accessible.name + text: button.text delay: 500 } } diff --git a/resources/qml/Governikus/TitleBar/+desktop/TitleBarText.qml b/resources/qml/Governikus/TitleBar/+desktop/TitleBarText.qml index 98163713e..4a0efcd64 100644 --- a/resources/qml/Governikus/TitleBar/+desktop/TitleBarText.qml +++ b/resources/qml/Governikus/TitleBar/+desktop/TitleBarText.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -8,6 +8,6 @@ import Governikus.Global 1.0 import Governikus.Style 1.0 GText { - textStyle: Style.text.header + textStyle: Style.text.header_inverse font.bold: true } diff --git a/resources/qml/Governikus/TitleBar/+mobile/+android/Hamburger.qml b/resources/qml/Governikus/TitleBar/+mobile/+android/Hamburger.qml index f4e0c3335..60101b37a 100644 --- a/resources/qml/Governikus/TitleBar/+mobile/+android/Hamburger.qml +++ b/resources/qml/Governikus/TitleBar/+mobile/+android/Hamburger.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import Governikus.Global 1.0 @@ -60,13 +60,6 @@ Item { } states: [ - State { - // While creating this state seems unnecessary because it's also implicitly defined, it's needed to avoid a - // bug where the Animation hangs and overrides the "" state properties with those of the "back" state. This - // can be seen when selecting "Quit Tutorial" from "TutorialReaderMethodNfc" (or any other subview of the - // tutorial) on Android. - name: "" - }, State { id: backState name: "back" diff --git a/resources/qml/Governikus/TitleBar/+mobile/+android/TitleBar.qml b/resources/qml/Governikus/TitleBar/+mobile/+android/TitleBar.qml index 73e87ec22..20143e045 100644 --- a/resources/qml/Governikus/TitleBar/+mobile/+android/TitleBar.qml +++ b/resources/qml/Governikus/TitleBar/+mobile/+android/TitleBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -32,7 +32,7 @@ Item { leftAction: Hamburger { id: burger - height: parent.height + height: titleBar.contentHeight state: navBar.isOpen ? "back" : (baseItem.navigationAction ? baseItem.navigationAction.state : "") enabled: baseItem.navigationAction ? baseItem.navigationAction.enabled : true diff --git a/resources/qml/Governikus/TitleBar/+mobile/+ios/TitleBar.qml b/resources/qml/Governikus/TitleBar/+mobile/+ios/TitleBar.qml index f3ffbb8db..703a98447 100644 --- a/resources/qml/Governikus/TitleBar/+mobile/+ios/TitleBar.qml +++ b/resources/qml/Governikus/TitleBar/+mobile/+ios/TitleBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TitleBar/+mobile/+ios/TitleBarNavigation.qml b/resources/qml/Governikus/TitleBar/+mobile/+ios/TitleBarNavigation.qml index 0bf87f78e..5139830a7 100644 --- a/resources/qml/Governikus/TitleBar/+mobile/+ios/TitleBarNavigation.qml +++ b/resources/qml/Governikus/TitleBar/+mobile/+ios/TitleBarNavigation.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 diff --git a/resources/qml/Governikus/TitleBar/+mobile/BaseTitleBar.qml b/resources/qml/Governikus/TitleBar/+mobile/BaseTitleBar.qml index 89afdf4ea..003fb6549 100644 --- a/resources/qml/Governikus/TitleBar/+mobile/BaseTitleBar.qml +++ b/resources/qml/Governikus/TitleBar/+mobile/BaseTitleBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -16,6 +16,7 @@ Item { Left } + property alias contentHeight: contentLayout.height property alias titleBarOpacity: background.opacity property alias title: titleText.text @@ -29,6 +30,8 @@ Item { height: contentLayout.height + topSafeAreaMargin + Accessible.role: Accessible.TitleBar + function updateLeftAction() { if (leftActionStack.activeActionItem && typeof leftActionStack.activeActionItem.iconOnly !== "undefined") { leftActionStack.activeActionItem.iconOnly = titleText.implicitWidth > titleText.implicitAvailableWidth diff --git a/resources/qml/Governikus/TitleBar/+mobile/NavigationAction.qml b/resources/qml/Governikus/TitleBar/+mobile/NavigationAction.qml index f863fc03e..edac56588 100644 --- a/resources/qml/Governikus/TitleBar/+mobile/NavigationAction.qml +++ b/resources/qml/Governikus/TitleBar/+mobile/NavigationAction.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TitleBar/+mobile/TitleBarAction.qml b/resources/qml/Governikus/TitleBar/+mobile/TitleBarAction.qml index db1892529..47042dd84 100644 --- a/resources/qml/Governikus/TitleBar/+mobile/TitleBarAction.qml +++ b/resources/qml/Governikus/TitleBar/+mobile/TitleBarAction.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtGraphicalEffects 1.10 +import QtGraphicalEffects 1.0 import Governikus.Global 1.0 import Governikus.Style 1.0 diff --git a/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantButton.qml b/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantButton.qml deleted file mode 100644 index d91720958..000000000 --- a/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantButton.qml +++ /dev/null @@ -1,72 +0,0 @@ -/* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 -import QtQuick.Controls 2.3 - -import Governikus.Global 1.0 -import Governikus.Style 1.0 -import Governikus.View 1.0 -import Governikus.Type.SettingsModel 1.0 - -Button { - id: baseItem - - property string subText: "" - property alias buttonImage: image.source - - height: icon.height + Constants.component_spacing + buttonText.height - - Accessible.role: Accessible.Button - Accessible.name: subText - - background: Item { - id: content - - anchors.fill: parent - - Rectangle { - id: icon - - width: baseItem.width - height: baseItem.width - anchors.horizontalCenter: parent.horizontalCenter - anchors.margins: baseItem.down ? baseItem.width / 32 : 0 - anchors.top: parent.top - - radius: baseItem.width / 2 - border.width: baseItem.width / 40; - border.color: Constants.white - color: Style.color.transparent - - Rectangle { - anchors.fill: parent - anchors.margins: parent.height / 8; - - radius: height / 2 - color: Qt.lighter(Constants.blue, 1.1) - - Image { - id: image - anchors.centerIn: parent - - sourceSize.height: parent.height / 2; - } - } - } - - GText { - id: buttonText - - anchors.horizontalCenter: parent.horizontalCenter - anchors.bottom: parent.bottom - - text: baseItem.subText - textStyle: Style.text.header - } - } - - FocusFrame {} -} - diff --git a/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantCardReaderView.qml b/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantCardReaderView.qml deleted file mode 100644 index 6a9193168..000000000 --- a/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantCardReaderView.qml +++ /dev/null @@ -1,34 +0,0 @@ -/* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany - */ - -import QtQuick 2.10 - -import Governikus.Global 1.0 -import Governikus.View 1.0 -import Governikus.Type.ApplicationModel 1.0 -import Governikus.Type.SettingsModel 1.0 - -SectionPage { - id: baseItem - - signal advanceSetupAssistant() - - activeFocusOnTab: false - - SetupAssistantButton { - id: disagreeButton - - width: ApplicationModel.scaleFactor * 120 - anchors.bottom: parent.bottom - anchors.right: parent.right - anchors.margins: Constants.component_spacing - - activeFocusOnTab: true - - //: LABEL DESKTOP_QML - subText: qsTr("Advance") + SettingsModel.translationTrigger - buttonImage: "qrc:///images/desktop/continue_arrow.svg" - onClicked: baseItem.advanceSetupAssistant() - } -} diff --git a/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantView.qml b/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantView.qml index 6043024a3..37e589ae1 100644 --- a/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantView.qml +++ b/resources/qml/Governikus/TutorialView/+desktop/SetupAssistantView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -27,9 +27,8 @@ SectionPage { Finished } - activeFocusOnTab: false - isAbstract: true + onVisibleChanged: if (visible) d.reset() titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML @@ -54,6 +53,11 @@ SectionPage { ResultView { visible: d.activeView === SetupAssistantView.SubViews.Welcome + Component.onCompleted: setActive() + + Accessible.name: qsTr("Setup assistant view") + SettingsModel.translationTrigger + Accessible.description: qsTr("This is the setup assistant view which will guide you through the basic setup of %1").arg(Qt.application.name) + SettingsModel.translationTrigger + resultType: ResultView.Type.IsInfo //: INFO DESKTOP_QML Welcome message when starting the setup assistant. text: qsTr("Welcome to the AusweisApp2. Please take a few moments to setup the environment to your needs. Every decision you make can later be changed in the settings menu.") + SettingsModel.translationTrigger @@ -61,14 +65,17 @@ SectionPage { onNextView: d.activeView = SetupAssistantView.SubViews.HistorySetting } - SetupAssistantBinaryDecisionView { + BinaryDecisionView { visible: d.activeView === SetupAssistantView.SubViews.HistorySetting + Accessible.name: qsTr("History setup step") + SettingsModel.translationTrigger + mainIconSource: "qrc:///images/desktop/main_history.svg" + addRingAroundIcon: false //: INFO DESKTOP_QML Question if the authentication history shall be stored. - questionText: qsTr("Do you want to save a history of performed authentications?") + SettingsModel.translationTrigger + questionText: qsTr("Do you want to save a history of performed authentications on your device?") + SettingsModel.translationTrigger //: INFO DESKTOP_QML Information text which data is stored in the history record. - questionSubText: qsTr("The following data is saved: authentication date, service provider contact data, read data.") + SettingsModel.translationTrigger + questionSubText: qsTr("The history is only saved locally. You can use it to see on what date you transmitted which data to which party. After enabling the history you can view and delete the entries anytime.") + SettingsModel.translationTrigger titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML @@ -94,87 +101,40 @@ SectionPage { visible: d.activeView === SetupAssistantView.SubViews.CardReader + Accessible.name: qsTr("Card reader setup step") + SettingsModel.translationTrigger + rootEnabled: d.allowNavigation onCloseView: d.activeView = SetupAssistantView.SubViews.HistorySetting - Button { - id: button - - anchors.bottom: parent.bottom - anchors.right: parent.right - anchors.rightMargin: Constants.component_spacing - anchors.bottomMargin: Constants.component_spacing - width: icon.width + ApplicationModel.scaleFactor * 10 + buttonText.width - height: icon.height - - Accessible.role: Accessible.Button - Accessible.name: qsTr("Continue") + SettingsModel.translationTrigger - - activeFocusOnTab: true - onClicked: d.activeView = SetupAssistantView.SubViews.TransportPin - - background: Item { - id: content - - readonly property int imageWidth: ApplicationModel.scaleFactor * 60 - - anchors.fill: parent - - GText { - id: buttonText - anchors.verticalCenter: parent.verticalCenter - anchors.left: parent.left + paneAnchors.bottom: forwardButton.top - //: LABEL DESKTOP_QML - text: qsTr("Continue") + SettingsModel.translationTrigger - textStyle: Style.text.normal - } + NavigationButton { + id: forwardButton - Rectangle { - id: icon + visible: readerView.currentView === TabbedReaderView.SubView.None - width: content.imageWidth - height: content.imageWidth - anchors.verticalCenter: parent.verticalCenter - anchors.right: parent.right - - radius: button.width / 2 - border.width: content.imageWidth / 40 - border.color: Constants.white - color: Style.color.transparent - - Rectangle { - anchors.fill: parent - anchors.margins: parent.height / 8 - - radius: height / 2 - color: Qt.lighter(Constants.blue, 1.1) - - Image { - id: image - anchors.centerIn: parent - source: "qrc:///images/desktop/continue_arrow.svg" - - sourceSize.height: parent.height / 2 - } - } - } + anchors { + right: parent.right + bottom: parent.bottom + margins: Constants.pane_padding } - FocusFrame {} + buttonType: NavigationButton.Type.Forward + onClicked: d.activeView = SetupAssistantView.SubViews.TransportPin } } - SetupAssistantBinaryDecisionView { + BinaryDecisionView { visible: d.activeView === SetupAssistantView.SubViews.TransportPin + Accessible.name: qsTr("Change transport PIN setup step") + SettingsModel.translationTrigger + mainIconSource: "qrc:///images/reader/default_reader.png" - //: INFO DESKTOP_QML Inquiry message if the 5 digit transport PIN should be changed to an ordinary PIN (now). - questionText: qsTr("Do you want to change your transport PIN to a personal PIN now?") + SettingsModel.translationTrigger - //: INFO DESKTOP_QML Hint that this change may be carried out form the main menu as well and that it is required to use the online authentication feature of the id card. - questionSubText: qsTr("This process can always be started from the main menu. The online-ID function is only usable with a personal PIN.") + SettingsModel.translationTrigger - addRingAroundIcon: true + //: INFO DESKTOP_QML Inquiry message if the 5-digit transport PIN should be changed to an ordinary PIN (now). + questionText: qsTr("Do you want to set your PIN now?") + SettingsModel.translationTrigger + //: INFO DESKTOP_QML Hint that this change may be carried out form the main menu as well and that it is required to use the online authentication feature of the ID card. + questionSubText: qsTr("If you have not already done so you have to change your 5-digit transport PIN to a 6-digit PIN before you can use the online-ID function.") + SettingsModel.translationTrigger titleBarAction: TitleBarAction { //: LABEL DESKTOP_QML @@ -185,22 +145,25 @@ SectionPage { } onAgree: { + SettingsModel.showSetupAssistantOnStart = false // We don't wan't to show the setup assistant again, as the only subview left is "Setup assistant done" NumberModel.requestTransportPin = true ChangePinModel.startWorkflow() } - onDisagree: d.activeView = SetupAssistantView.SubViews.Finished + onDisagree: { + SettingsModel.showSetupAssistantOnStart = false + d.activeView = SetupAssistantView.SubViews.Finished + } } ResultView { visible: d.activeView === SetupAssistantView.SubViews.Finished + Accessible.name: qsTr("Setup assistant done") + SettingsModel.translationTrigger + resultType: ResultView.Type.IsSuccess //: INFO DESKTOP_QML Success message after completing the setup assistant. text: qsTr("You have completed the setup of the AusweisApp2 successfully.") + SettingsModel.translationTrigger - onNextView: { - SettingsModel.showSetupAssistantOnStart = false - baseItem.nextView(pName) - } + onNextView: baseItem.nextView(pName) } } diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialCollapseAnimation.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialCollapseAnimation.qml index 1bd15209f..2c497dbe3 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialCollapseAnimation.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialCollapseAnimation.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialContent.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialContent.qml index d4c4d59c4..148df8257 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialContent.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialContent.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialExpandAnimation.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialExpandAnimation.qml index 220617647..67dbb22fd 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialExpandAnimation.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialExpandAnimation.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialFooter.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialFooter.qml index af3ca237d..4fcae354a 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialFooter.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialFooter.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialHeader.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialHeader.qml index 6eb5bdbea..728450eb5 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialHeader.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialHeader.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -57,7 +57,7 @@ Item { font.bold: true textStyle: Style.text.tutorial_title - layer.enabled: true + layer.enabled: GraphicsInfo.api !== GraphicsInfo.Software layer.effect: DropShadow { verticalOffset: 3 horizontalOffset: 3 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialHow.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialHow.qml index 449b8ae6a..20f0df778 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialHow.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialHow.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -53,6 +53,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: INFO ANDROID IOS text: (Constants.is_layout_ios ? qsTr("How can I use the AusweisApp2 on my iPhone?") : qsTr("How can I use the AusweisApp2 on my smartphone?")) @@ -84,7 +88,7 @@ TutorialContent { Item { width: parent.width - height: noticeImage.height + height: Math.max(noticeText.height, noticeImage.height) TutorialImage { id: noticeImage @@ -96,10 +100,15 @@ TutorialContent { } GText { + id: noticeText width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: INFO ANDROID IOS - text: (Constants.is_layout_ios ? qsTr("Many iPhones (iPhone 7 and newer) can access the id card via the built-in NFC interface.") - : qsTr("Many Android devices can access the id card via the built-in NFC interface.")) + text: (Constants.is_layout_ios ? qsTr("Many iPhones (iPhone 7 and newer) can access the ID card via the built-in NFC interface.") + : qsTr("Many Android devices can access the ID card via the built-in NFC interface.")) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content font.bold: true @@ -125,10 +134,9 @@ TutorialContent { width: parent.width * 0.9 visible: Constants.is_layout_android //: LABEL ANDROID IOS - text: "%1".arg(qsTr("https://www.ausweisapp.bund.de/mobile-geraete/")) + SettingsModel.translationTrigger + text: "%1".arg(qsTr("https://www.ausweisapp.bund.de/en/compatible-devices/mobile-phones-and-tablets/")) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content horizontalAlignment: Text.AlignHCenter - onLinkActivated: Qt.openUrlExternally(link) } Image { @@ -142,8 +150,12 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("The AusweisApp2 offers the following options to access your id card:") + SettingsModel.translationTrigger + text: qsTr("The AusweisApp2 offers the following options to access your ID card:") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header font.italic: true horizontalAlignment: Text.AlignHCenter @@ -165,6 +177,10 @@ TutorialContent { MouseArea { anchors.fill: parent onClicked: firePush(readerMethodNfc) + + //: LABEL ANDROID IOS + Accessible.name: qsTr("Direct connection via NFC chip tutorial") + SettingsModel.translationTrigger + Accessible.role: Accessible.Button } Column { @@ -176,6 +192,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Direct connection via NFC chip") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -194,6 +214,10 @@ TutorialContent { GText { id: numberOne anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + text: "1" textStyle: Style.text.tutorial_header_secondary font.bold: true @@ -212,6 +236,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: (Constants.is_layout_ios ? qsTr("App on iPhone with NFC chip as card reader") : qsTr("App on Android smartphone with NFC chip as card reader")) @@ -245,6 +273,10 @@ TutorialContent { MouseArea { anchors.fill: parent onClicked: firePush(readerMethodSacDesktop) + + //: LABEL ANDROID IOS + Accessible.name: qsTr("Smartphone as card reader tutorial") + SettingsModel.translationTrigger + Accessible.role: Accessible.Button } Column { @@ -256,6 +288,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Smartphone as card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -274,6 +310,10 @@ TutorialContent { GText { id: numberTwo anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + text: "2" textStyle: Style.text.tutorial_header_secondary font.bold: true @@ -316,6 +356,10 @@ TutorialContent { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("App on computer without NFC chip") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -327,6 +371,10 @@ TutorialContent { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Smartphone with NFC chip as card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -362,6 +410,10 @@ TutorialContent { MouseArea { anchors.fill: parent onClicked: firePush(readerMethodSacMobile) + + //: LABEL ANDROID IOS + Accessible.name: qsTr("Smartphone as card reader mobile tutorial") + SettingsModel.translationTrigger + Accessible.role: Accessible.Button } Column { @@ -381,6 +433,10 @@ TutorialContent { GText { id: numberThree anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + text: "3" textStyle: Style.text.tutorial_header_secondary font.bold: true @@ -423,6 +479,10 @@ TutorialContent { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("App on tablet or smartphone without NFC chip") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -434,6 +494,10 @@ TutorialContent { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Smartphone with NFC chip as card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -469,6 +533,10 @@ TutorialContent { MouseArea { anchors.fill: parent onClicked: firePush(readerMethodBluetooth) + + //: LABEL ANDROID IOS + Accessible.name: qsTr("Using a bluetooth card reader tutorial") + SettingsModel.translationTrigger + Accessible.role: Accessible.Button } Column { @@ -480,6 +548,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Using a bluetooth card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -498,6 +570,10 @@ TutorialContent { GText { id: numberFour anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + text: "4" textStyle: Style.text.tutorial_header_secondary font.bold: true @@ -540,6 +616,10 @@ TutorialContent { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("App on smartphone or tablet") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -551,6 +631,10 @@ TutorialContent { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Bluetooth card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -580,6 +664,10 @@ TutorialContent { GText { id: textContent anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + color: Constants.white width: parent.width * 0.8 textStyle: Style.text.tutorial_header @@ -597,6 +685,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("For lenghty forms, e.g. a BAf\u00F6G application, we recommend you to use the AusweisApp2 on a computer...") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -618,6 +710,11 @@ TutorialContent { GText { width: parent.width * 0.5 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Filling long forms is no fun on a smartphone!") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -632,6 +729,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("... and to use a smartphone to communicate with your ID card. A USB reader is of course also an alternative.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialImage.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialImage.qml index e1067fc2d..0adb7bb2b 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialImage.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialImage.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialImportant.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialImportant.qml index 3d65695d5..4ac41eb10 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialImportant.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialImportant.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -19,8 +19,12 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("Please exchange your") : qsTr("Before you use the online ID function please change the")) + SettingsModel.translationTrigger + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("Please exchange your") : + //: LABEL ANDROID IOS + qsTr("Before you use the online ID function please change the") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } @@ -93,8 +97,12 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("before you use the online ID function!") : qsTr("change!")) + SettingsModel.translationTrigger + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("before you use the online ID function!") : + //: LABEL ANDROID IOS + qsTr("change!") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } @@ -198,12 +206,33 @@ TutorialContent { } } + GText { + width: parent.width * 0.9 + anchors.horizontalCenter: parent.horizontalCenter + + //: LABEL ANDROID IOS + text: qsTr("Please note: The transport PIN can only be used for your first PIN change. If you have already set your personal PIN (e.g. while picking up your ID card) only the set PIN is valid.") + SettingsModel.translationTrigger + textStyle: Style.text.tutorial_header_secondary + horizontalAlignment: Text.AlignHCenter + } + + GText { + width: parent.width * 0.9 + anchors.horizontalCenter: parent.horizontalCenter + + //: LABEL ANDROID IOS + text: qsTr("You can always set a new PIN at the issuing authority if the (transport) PIN is not known.") + SettingsModel.translationTrigger + textStyle: Style.text.tutorial_header_secondary + horizontalAlignment: Text.AlignHCenter + } + TutorialSeperator { source: "qrc:///images/tutorial/section_seperator_important.svg" } Column { width: parent.width + spacing: Constants.component_spacing Image { @@ -216,13 +245,15 @@ TutorialContent { MouseArea { anchors.fill: parent + //: LABEL ANDROID IOS onClicked: Qt.openUrlExternally(qsTr("https://www.youtube.com/watch?v=wZglRda5Y60&index=4&list=PLLB5ERhVkn25qQXgMHQr-1KgyZsJKoSAm")) } } GText { - anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + anchors.horizontalCenter: parent.horizontalCenter + //: LABEL ANDROID IOS text: qsTr("Learn more about this in the YouTube video") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -291,11 +322,18 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 - //: LABEL ANDROID IOS - text: "%1
%2
%3".arg(qsTr("www.ausweisapp.bund.de")).arg(qsTr("or")).arg(qsTr("www.personalausweisportal.de")) + SettingsModel.translationTrigger + text: "%1
%2
%3".arg( + //: LABEL ANDROID IOS + qsTr("www.ausweisapp.bund.de") + ).arg( + //: LABEL ANDROID IOS + qsTr("or") + ).arg( + //: LABEL ANDROID IOS + qsTr("www.personalausweisportal.de") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary horizontalAlignment: Text.AlignHCenter - onLinkActivated: Qt.openUrlExternally(link) } } @@ -306,10 +344,12 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 - //: LABEL ANDROID IOS - text: (Constants.is_layout_ios ? qsTr("You can always access this tutorial again from the \"More\" section in the menu bar.") - : qsTr("You can always access this tutorial again from the side bar.")) - + SettingsModel.translationTrigger + text: (Constants.is_layout_ios ? + //: LABEL IOS + qsTr("You can always access this tutorial again from the \"More\" section in the menu bar.") : + //: LABEL ANDROID + qsTr("You can always access this tutorial again from the \"Help & Feedback\" section in the side bar.") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodBluetooth.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodBluetooth.qml index 7b155781b..090c7cdfb 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodBluetooth.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodBluetooth.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -52,6 +52,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Using a bluetooth card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -70,6 +74,10 @@ SectionPage { GText { id: numberFour anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + text: "4" textStyle: Style.text.tutorial_header_secondary font.bold: true @@ -112,6 +120,10 @@ SectionPage { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("App on smartphone or tablet") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -123,6 +135,10 @@ SectionPage { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Bluetooth card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -151,6 +167,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("You need a suitable card reader if you want to use the bluetooth connection.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -174,6 +194,10 @@ SectionPage { width: parent.width * 0.4 anchors.left: parent.left leftPadding: 30 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Set the card reader visible first...") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -185,6 +209,10 @@ SectionPage { width: parent.width * 0.4 anchors.right: parent.right rightPadding: 30 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("... and then pair it with your device.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -211,8 +239,12 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Click the link on the website of the service provider.") + SettingsModel.translationTrigger + text: qsTr("Click the link on the website of the provider.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter textStyle: Style.text.tutorial_header_secondary } @@ -246,6 +278,11 @@ SectionPage { GText { id: textOpenAutomatic width: parent.width * 0.6 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The App opens automatically.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -258,6 +295,11 @@ SectionPage { GText { id: textAccessWhoWhat width: parent.width * 0.6 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The AusweisApp2 will display who wants to access which data.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -279,6 +321,10 @@ SectionPage { GText { id: startProcessText anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + textStyle: Style.text.tutorial_header_secondary //: LABEL ANDROID IOS text: qsTr("Start the process with a click on:") + SettingsModel.translationTrigger @@ -299,7 +345,11 @@ SectionPage { GButton { id: identifyButton - iconSource: "qrc:///images/npa.svg" + icon.source: "qrc:///images/npa.svg" + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Proceed to PIN entry") + SettingsModel.translationTrigger; animationsDisabled: true @@ -340,6 +390,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Tap on Bluetooth") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -359,6 +413,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Insert card into card reader") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -376,6 +434,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("... and confirm the displayed information.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -397,8 +459,16 @@ SectionPage { GText { width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("Enter") : qsTr("Now")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("Enter") : + //: LABEL ANDROID IOS + qsTr("Now") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -418,6 +488,10 @@ SectionPage { GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("6 digits long PIN") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -432,8 +506,16 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("now on the card reader!") : qsTr("enter on the card reader!")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("now on the card reader!") : + //: LABEL ANDROID IOS + qsTr("enter on the card reader!") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -458,6 +540,10 @@ SectionPage { GText { id: noticeText width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("This is only possible if you have exchanged the 5 digits long transport PIN with a 6 digits long personal PIN beforehand.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodFooter.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodFooter.qml index 02facab8c..ce0277f01 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodFooter.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodFooter.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodNfc.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodNfc.qml index f6a46ee5f..d07d323a0 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodNfc.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodNfc.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -52,6 +52,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Direct connection via NFC chip") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -70,6 +74,10 @@ SectionPage { GText { id: numberOne anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + text: "1" textStyle: Style.text.tutorial_header_secondary font.bold: true @@ -88,8 +96,13 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.6 - //: LABEL ANDROID IOS + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + //: LABEL IOS text: (Constants.is_layout_ios ? qsTr("App on iPhone with NFC chip as card reader") + //: LABEL ANDROID : qsTr("App on Android smartphone with NFC chip as card reader")) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -118,8 +131,12 @@ SectionPage { GText { width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Click link on the website of the service provider.") + SettingsModel.translationTrigger + text: qsTr("Click link on the website of the provider.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter textStyle: Style.text.tutorial_header_secondary @@ -156,6 +173,11 @@ SectionPage { GText { id: textOpenAutomatic width: parent.width * 0.6 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The App opens automatically.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -168,6 +190,11 @@ SectionPage { GText { id: textAccessWhoWhat width: parent.width * 0.6 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The AusweisApp2 will display who wants to access which data.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -189,6 +216,10 @@ SectionPage { GText { id: startProcessText anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + textStyle: Style.text.tutorial_header_secondary //: LABEL ANDROID IOS text: qsTr("Start the process with a click on:") + SettingsModel.translationTrigger @@ -209,7 +240,11 @@ SectionPage { GButton { id: identifyButton - iconSource: "qrc:///images/npa.svg" + icon.source: "qrc:///images/npa.svg" + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Proceed to PIN entry") + SettingsModel.translationTrigger; animationsDisabled: true @@ -237,9 +272,14 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 - //: LABEL ANDROID IOS - text: (Constants.is_layout_ios ? qsTr("... and place the top of the iPhone onto the id card.") - : qsTr("... and place the id card flat onto the NFC interface.")) + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + //: LABEL IOS + text: (Constants.is_layout_ios ? qsTr("... and place the top of the iPhone onto the ID card.") + //: LABEL ANDROID + : qsTr("... and place the ID card flat onto the NFC interface.")) + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter textStyle: Style.text.tutorial_header_secondary @@ -260,8 +300,12 @@ SectionPage { GText { width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Do not move device or id card!") + SettingsModel.translationTrigger + text: qsTr("Do not move device or ID card!") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content font.bold: true horizontalAlignment: Text.AlignLeft @@ -293,6 +337,11 @@ SectionPage { GText { width: parent.width * 0.5 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The correct position is specific for your device...") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -305,13 +354,22 @@ SectionPage { GText { width: parent.width * 0.5 - //: LABEL ANDROID IOS - text: "%2".arg(qsTr("https://www.ausweisapp.bund.de/mobile-geraete/")).arg(qsTr("To mobile devices")) + SettingsModel.translationTrigger + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: "%2".arg( + //: LABEL ANDROID IOS + qsTr("https://www.ausweisapp.bund.de/en/compatible-devices/mobile-phones-and-tablets/") + ).arg( + //: LABEL ANDROID IOS + qsTr("To mobile devices") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary font.bold: true font.underline: true horizontalAlignment: Text.AlignLeft - onLinkActivated: Qt.openUrlExternally(link) x: (parent.width * 0.75) - (width / 2) y: (parent.height * 0.7) - (height / 2) @@ -332,8 +390,16 @@ SectionPage { GText { width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("Enter") : qsTr("Now")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("Enter") : + //: LABEL ANDROID IOS + qsTr("Now") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -353,6 +419,10 @@ SectionPage { GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("6 digits long PIN") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -367,8 +437,16 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("now!") : qsTr("enter!")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("now!") : + //: LABEL ANDROID IOS + qsTr("enter!") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -393,6 +471,10 @@ SectionPage { GText { id: noticeText2 width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("This is only possible if you have exchanged the 5 digits long transport PIN with a 6 digits long personal PIN beforehand.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -409,16 +491,51 @@ SectionPage { source: "qrc:///images/tutorial/section_seperator_how.svg" } + Image { + width: parent.width * 0.7 + height: width * (sourceSize.height / sourceSize.width) + anchors.horizontalCenter: parent.horizontalCenter + + source: "qrc:///images/tutorial/play_movie.png" + fillMode: Image.PreserveAspectFit + + MouseArea { + anchors.fill: parent + + onClicked: Constants.is_layout_ios ? Qt.openUrlExternally("https://www.youtube.com/watch?v=qArkIGs0cFM&list=PLLB5ERhVkn25qQXgMHQr-1KgyZsJKoSAm&index=1") + : Qt.openUrlExternally("https://www.youtube.com/watch?v=OtduiptNKQI&list=PLLB5ERhVkn25qQXgMHQr-1KgyZsJKoSAm&index=2") + } + } + + GText { + width: parent.width * 0.9 + anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + //: LABEL ANDROID IOS + text: qsTr("You can also watch this YouTube video explaining the process.") + SettingsModel.translationTrigger + textStyle: Style.text.tutorial_header_secondary + horizontalAlignment: Text.AlignHCenter + } + + TutorialSeperator { + source: "qrc:///images/tutorial/section_seperator_how.svg" + } + MouseArea { width: parent.width height: finishedButton.height Image { id: finishedButton - source: "qrc:///images/tutorial/generated/reader_nfc_finished.svg" - anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 height: width * (sourceSize.height / sourceSize.width) + + anchors.horizontalCenter: parent.horizontalCenter + + source: "qrc:///images/tutorial/generated/reader_nfc_finished.svg" fillMode: Image.PreserveAspectFit } diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodSacDesktop.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodSacDesktop.qml index 39ab98ab1..b4baaea9c 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodSacDesktop.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodSacDesktop.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -52,6 +52,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Smartphone as card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -70,6 +74,10 @@ SectionPage { GText { id: numberTwo anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + text: "2" textStyle: Style.text.tutorial_header_secondary font.bold: true @@ -112,6 +120,10 @@ SectionPage { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("App on computer without NFC chip") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -123,6 +135,10 @@ SectionPage { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Smartphone with NFC chip as card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -150,6 +166,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Install AusweisApp2 on both your computer and your smartphone with NFC capability.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -184,6 +204,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Both devices have to be connected to the same wifi network") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -211,10 +235,16 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 - //: LABEL ANDROID IOS - text: (Constants.is_layout_ios ? qsTr("Now choose \"Remote\" in the AusweisApp2 on your smartphone...") - : qsTr("Now choose \"Smartphone as card reader\" in the AusweisApp2 on your smartphone...")) - + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (Constants.is_layout_ios ? + //: LABEL IOS + qsTr("Now choose \"Remote\" in the AusweisApp2 on your smartphone...") : + //: LABEL ANDROID + qsTr("Now choose \"Smartphone as card reader\" in the AusweisApp2 on your smartphone...") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } @@ -239,6 +269,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Now") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -247,8 +281,12 @@ SectionPage { GButton { id: remoteButton - buttonColor: Constants.green + buttonColor: Constants.darkgreen anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Start remote service") + SettingsModel.translationTrigger animationsDisabled: true @@ -265,6 +303,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Next") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -274,6 +316,10 @@ SectionPage { GButton { id: pairingButton anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Start pairing") + SettingsModel.translationTrigger animationsDisabled: true @@ -306,6 +352,10 @@ SectionPage { anchors.horizontalCenter: parent.horizontalCenter anchors.top: greyBackgroundRect.top topPadding: 30 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Pairing code") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -318,6 +368,10 @@ SectionPage { anchors.bottom: greyBackgroundRect.bottom bottomPadding: 30 anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("appears!") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -345,6 +399,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Start the App now on your computer and enter the settings.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -354,8 +412,12 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Select the Card Readers tab.") + SettingsModel.translationTrigger + text: qsTr("Select the Smartphone as card reader tab.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } @@ -385,8 +447,12 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Select smartphone from list and click \"pair\"") + SettingsModel.translationTrigger + text: qsTr("Select smartphone from list") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } @@ -406,6 +472,10 @@ SectionPage { GText { width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Enter pairing code next.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -436,8 +506,12 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Click link on the website of the service provider.") + SettingsModel.translationTrigger + text: qsTr("Click link on the website of the provider.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter textStyle: Style.text.tutorial_header_secondary } @@ -472,6 +546,11 @@ SectionPage { GText { id: textOpenAutomatic width: parent.width * 0.6 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The App opens automatically.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -484,6 +563,11 @@ SectionPage { GText { id: textAccessWhoWhat width: parent.width * 0.6 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The AusweisApp2 will display who wants to access which data.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -505,6 +589,10 @@ SectionPage { GText { id: startProcessText anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + textStyle: Style.text.tutorial_header_secondary //: LABEL ANDROID IOS text: qsTr("Start the process with a click on:") + SettingsModel.translationTrigger @@ -525,7 +613,11 @@ SectionPage { GButton { id: identifyButton - iconSource: "qrc:///images/npa.svg" + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + icon.source: "qrc:///images/npa.svg" //: LABEL ANDROID IOS text: qsTr("Proceed to PIN entry") + SettingsModel.translationTrigger; animationsDisabled: true @@ -553,8 +645,12 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("... and place the id card onto the NFC interface.") + SettingsModel.translationTrigger + text: qsTr("... and place the ID card onto the NFC interface.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter textStyle: Style.text.tutorial_header_secondary } @@ -574,8 +670,12 @@ SectionPage { GText { width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Do not move device or id card!") + SettingsModel.translationTrigger + text: qsTr("Do not move device or ID card!") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content font.bold: true horizontalAlignment: Text.AlignLeft @@ -605,6 +705,11 @@ SectionPage { GText { width: parent.width * 0.5 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The correct position is specific for your device...") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -617,13 +722,22 @@ SectionPage { GText { width: parent.width * 0.5 - //: LABEL ANDROID IOS - text: "%2".arg(qsTr("https://www.ausweisapp.bund.de/mobile-geraete/")).arg(qsTr("To mobile devices")) + SettingsModel.translationTrigger + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: "%2".arg( + //: LABEL ANDROID IOS + qsTr("https://www.ausweisapp.bund.de/en/compatible-devices/mobile-phones-and-tablets/") + ).arg( + //: LABEL ANDROID IOS + qsTr("To mobile devices") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary font.bold: true font.underline: true horizontalAlignment: Text.AlignLeft - onLinkActivated: Qt.openUrlExternally(link) x: (parent.width * 0.75) - (width / 2) y: (parent.height * 0.7) - (height / 2) @@ -644,8 +758,16 @@ SectionPage { GText { width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("Enter") : qsTr("Now")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("Enter") : + //: LABEL ANDROID IOS + qsTr("Now") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -665,6 +787,10 @@ SectionPage { GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("6 digits long PIN") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -679,8 +805,16 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("now!") : qsTr("enter!")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("now!") : + //: LABEL ANDROID IOS + qsTr("enter!") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -705,6 +839,10 @@ SectionPage { GText { id: noticeText2 width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("This is only possible if you have exchanged the 5 digits long transport PIN with a 6 digits long personal PIN beforehand.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -721,6 +859,38 @@ SectionPage { source: "qrc:///images/tutorial/section_seperator_how.svg" } + Image { + width: parent.width * 0.7 + height: width * (sourceSize.height / sourceSize.width) + anchors.horizontalCenter: parent.horizontalCenter + + source: "qrc:///images/tutorial/play_movie.png" + fillMode: Image.PreserveAspectFit + + MouseArea { + anchors.fill: parent + + onClicked: Qt.openUrlExternally("https://www.youtube.com/watch?v=PWF1kEwfQ0Y&list=PLLB5ERhVkn25qQXgMHQr-1KgyZsJKoSAm&index=3") + } + } + + GText { + width: parent.width * 0.9 + anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + //: LABEL ANDROID IOS + text: qsTr("You can also watch this YouTube video explaining the process.") + SettingsModel.translationTrigger + textStyle: Style.text.tutorial_header_secondary + horizontalAlignment: Text.AlignHCenter + } + + TutorialSeperator { + source: "qrc:///images/tutorial/section_seperator_how.svg" + } + MouseArea { width: parent.width height: finishedButton.height diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodSacMobile.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodSacMobile.qml index 5c2f621b0..756302a81 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodSacMobile.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialReaderMethodSacMobile.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -60,6 +60,10 @@ SectionPage { GText { id: numberThree anchors.centerIn: parent + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + text: "3" textStyle: Style.text.tutorial_header_secondary font.bold: true @@ -102,6 +106,10 @@ SectionPage { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("App on tablet or smartphone without NFC chip") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -113,6 +121,10 @@ SectionPage { GText { width: parent.width * 0.4 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Smartphone with NFC chip as card reader") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -140,6 +152,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Install AusweisApp2 on both your device without NFC and your smartphone with NFC capability.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -174,6 +190,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Both devices have to be connected to the same wifi network") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -206,10 +226,16 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 - //: LABEL ANDROID IOS - text: (Constants.is_layout_ios ? qsTr("Now choose \"Remote\" in the AusweisApp2 on your smartphone...") - : qsTr("Now choose \"Smartphone as card reader\" in the AusweisApp2 on your smartphone...")) - + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (Constants.is_layout_ios ? + //: LABEL IOS + qsTr("Now choose \"Remote\" in the AusweisApp2 on your smartphone...") : + //: LABEL ANDROID + qsTr("Now choose \"Smartphone as card reader\" in the AusweisApp2 on your smartphone...") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } @@ -234,6 +260,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Now") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -242,8 +272,12 @@ SectionPage { GButton { id: remoteButton - buttonColor: Constants.green + buttonColor: Constants.darkgreen anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Start remote service") + SettingsModel.translationTrigger animationsDisabled: true @@ -260,6 +294,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Next") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -269,6 +307,10 @@ SectionPage { GButton { id: pairingButton anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Start pairing") + SettingsModel.translationTrigger animationsDisabled: true @@ -301,6 +343,10 @@ SectionPage { anchors.horizontalCenter: parent.horizontalCenter anchors.top: greyBackgroundRect.top topPadding: 30 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Pairing code") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -313,6 +359,10 @@ SectionPage { anchors.bottom: greyBackgroundRect.bottom bottomPadding: 30 anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("appears!") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -345,10 +395,16 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 - //: LABEL ANDROID IOS - text: (Constants.is_layout_ios ? qsTr("Now open the AusweisApp2 on your device without NFC and select Configure remote service.") - : qsTr("Now open the AusweisApp2 on your device without NFC and select Smartphone as card reader.")) - + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (Constants.is_layout_ios ? + //: LABEL IOS + qsTr("Now open the AusweisApp2 on your device without NFC and select Configure remote service.") : + //: LABEL ANDROID + qsTr("Now open the AusweisApp2 on your device without NFC and select Smartphone as card reader.") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } @@ -356,6 +412,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Now select Settings.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -382,6 +442,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.7 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Choose smartphone from list") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -403,6 +467,10 @@ SectionPage { GText { width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Enter pairing code next.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -438,8 +506,12 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Click link on the website of the service provider on the device without NFC.") + SettingsModel.translationTrigger + text: qsTr("Click link on the website of the provider on the device without NFC.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter textStyle: Style.text.tutorial_header_secondary } @@ -474,6 +546,11 @@ SectionPage { GText { id: textOpenAutomatic width: parent.width * 0.6 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The App opens automatically.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -486,6 +563,11 @@ SectionPage { GText { id: textAccessWhoWhat width: parent.width * 0.6 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The AusweisApp2 will display who wants to access which data.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -507,6 +589,10 @@ SectionPage { GText { id: startProcessText anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + textStyle: Style.text.tutorial_header_secondary //: LABEL ANDROID IOS text: qsTr("Start the process with a click on:") + SettingsModel.translationTrigger @@ -527,7 +613,11 @@ SectionPage { GButton { id: identifyButton - iconSource: "qrc:///images/npa.svg" + icon.source: "qrc:///images/npa.svg" + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Proceed to PIN entry") + SettingsModel.translationTrigger; animationsDisabled: true @@ -569,6 +659,10 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Tap on Wifi") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter @@ -596,8 +690,12 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("... and place the id card onto the NFC interface.") + SettingsModel.translationTrigger + text: qsTr("... and place the ID card onto the NFC interface.") + SettingsModel.translationTrigger horizontalAlignment: Text.AlignHCenter textStyle: Style.text.tutorial_header_secondary @@ -618,8 +716,12 @@ SectionPage { GText { width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("Do not move device or id card!") + SettingsModel.translationTrigger + text: qsTr("Do not move device or ID card!") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content font.bold: true horizontalAlignment: Text.AlignLeft @@ -649,6 +751,11 @@ SectionPage { GText { width: parent.width * 0.5 + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The correct position is specific for your device...") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -661,13 +768,22 @@ SectionPage { GText { width: parent.width * 0.5 - //: LABEL ANDROID IOS - text: "%2".arg(qsTr("https://www.ausweisapp.bund.de/mobile-geraete/")).arg(qsTr("To mobile devices")) + SettingsModel.translationTrigger + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: "%2".arg( + //: LABEL ANDROID IOS + qsTr("https://www.ausweisapp.bund.de/en/compatible-devices/mobile-phones-and-tablets/") + ).arg( + //: LABEL ANDROID IOS + qsTr("To mobile devices") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary font.bold: true font.underline: true horizontalAlignment: Text.AlignLeft - onLinkActivated: Qt.openUrlExternally(link) x: (parent.width * 0.75) - (width / 2) y: (parent.height * 0.7) - (height / 2) @@ -688,8 +804,16 @@ SectionPage { GText { width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("Enter") : qsTr("Now")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("Enter") : + //: LABEL ANDROID IOS + qsTr("Now") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -709,6 +833,10 @@ SectionPage { GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("6 digits long PIN") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -723,8 +851,16 @@ SectionPage { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("now!") : qsTr("enter!")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("now!") : + //: LABEL ANDROID IOS + qsTr("enter!") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -749,6 +885,10 @@ SectionPage { GText { id: noticeText2 width: parent.width * 0.6 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("This is only possible if you have exchanged the 5 digits long transport PIN with a 6 digits long personal PIN beforehand.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialSeperator.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialSeperator.qml index 8cd4e1b69..a737ad6f2 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialSeperator.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialSeperator.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialSpacer.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialSpacer.qml index c07972cd4..ee9923334 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialSpacer.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialSpacer.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -8,6 +8,8 @@ import Governikus.Global 1.0 import Governikus.Style 1.0 Rectangle { + id: baseItem + property alias text: textContent.text height: textContent.height + 2 * Constants.component_spacing @@ -16,6 +18,10 @@ Rectangle { anchors.centerIn: parent color: Constants.white width: parent.width * 0.8 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialStatusBar.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialStatusBar.qml index cf491c14c..dcf700539 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialStatusBar.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialStatusBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialView.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialView.qml index a9d6f7610..3583cd981 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialView.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialView.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import QtQml.Models 2.10 import QtQml 2.10 @@ -25,9 +25,12 @@ SectionPage { titleBarVisible: false automaticSafeAreaMarginHandling: false navigationAction: NavigationAction { - // On iOS we want to go back to the MoreView even when a section is expanded. - state: topLevelPage ? root.state : "back"; - onClicked: state == "back" ? leaveView() : root.state = "" + state: (topLevelPage && root.state === "") + ? "" // this way the user can then exit the app with the back button when the Tutorial is shown on the first run. + : "hidden" // otherwise there would be a useless animation of the Hamburger on Android when leaving the Tutorial + onClicked: root.state !== "" + ? root.state = "" // collapse sections + : leaveView() } //: LABEL ANDROID IOS title: qsTr("Tutorial") + SettingsModel.translationTrigger @@ -125,7 +128,7 @@ SectionPage { collapseAllAnimation.start() navBar.lockedAndHidden = false SettingsModel.showSetupAssistantOnStart = false - if (navBar.state === "more") { + if (navBar.state === "more" || navBar.state === "feedback") { firePop() } else { navBar.state = "identify" @@ -198,6 +201,10 @@ SectionPage { id: whatHeader width: root.width height: ((flickable.height - flickable.topMargin - footer.height) / 13.0 ) * 3.0 + + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() + headerImageSource: "qrc:///images/tutorial/main_menu_what_caret.svg" categoryAbove: false //: LABEL ANDROID IOS @@ -230,12 +237,19 @@ SectionPage { id: whatContent width: root.contentWidth anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() } TutorialHeader { id: whereHeader width: root.width height: ((flickable.height - flickable.topMargin - footer.height) / 13.0 ) * 3.0 + + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() + headerImageSource: "qrc:///images/tutorial/main_menu_where_caret.svg" //: LABEL ANDROID IOS titleText: qsTr("Where?") + SettingsModel.translationTrigger @@ -267,12 +281,19 @@ SectionPage { id: whereContent width: root.contentWidth anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() } TutorialHeader { id: howHeader width: root.width height: ((flickable.height - flickable.topMargin - footer.height) / 13.0 ) * 3.0 + + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() + headerImageSource: "qrc:///images/tutorial/main_menu_how_caret.svg" //: LABEL ANDROID IOS titleText: qsTr("How?") + SettingsModel.translationTrigger @@ -305,6 +326,9 @@ SectionPage { width: root.contentWidth anchors.horizontalCenter: parent.horizontalCenter + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() + onFirePush: { root.firePush(pSectionPage) } @@ -315,6 +339,10 @@ SectionPage { id: importantHeader width: root.width height: ((flickable.height - flickable.topMargin - footer.height) / 13.0 ) * 4.0 + + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() + overlapping: false headerImageSource: "qrc:///images/tutorial/main_menu_important_caret.svg" //: LABEL ANDROID IOS @@ -348,6 +376,9 @@ SectionPage { width: root.contentWidth anchors.horizontalCenter: parent.horizontalCenter + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() + onLetsGoClicked: leaveView() } diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialWhat.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialWhat.qml index c1c6fcdc3..c24576ea0 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialWhat.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialWhat.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -18,6 +18,10 @@ TutorialContent { GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("What is the online ID function?") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -26,6 +30,10 @@ TutorialContent { } GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("You can use it to authenticate yourself in the internet") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -57,12 +65,13 @@ TutorialContent { TutorialImage { id: stylisedEpa - source: "qrc:///images/tutorial/idcard.svg" + source: "qrc:///images/ausweis.svg" z: 2 width: parent.height * 0.6 centerY: 0.5 centerX: 0.8 + rotation: 12 } TutorialImage { @@ -89,6 +98,10 @@ TutorialContent { GText { width: parent.width * 0.9 anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("and also to deal with administrative paperwork and business matters electronically!") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -98,6 +111,10 @@ TutorialContent { TutorialSpacer { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Alright, but is it secure?") + SettingsModel.translationTrigger color: Style.color.tutorial_what @@ -109,6 +126,10 @@ TutorialContent { GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Of course, because we use a so called") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -116,6 +137,10 @@ TutorialContent { } GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Mutual authentication") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -194,8 +219,12 @@ TutorialContent { GText { width: parent.width * 0.9 anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("... it establishes a secure connection between ID document and service provider.") + SettingsModel.translationTrigger + text: qsTr("... it establishes a secure connection between ID card and provider.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary horizontalAlignment: Text.AlignHCenter } @@ -216,6 +245,10 @@ TutorialContent { GText { width: parent.width * 0.35 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("On every authentication you get displayed who wants to access which data") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -263,6 +296,10 @@ TutorialContent { GText { width: parent.width * 0.95 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + anchors.horizontalCenter: parent.horizontalCenter //: LABEL ANDROID IOS text: qsTr("and you consent to the request with your personal PIN.") + SettingsModel.translationTrigger @@ -309,7 +346,11 @@ TutorialContent { } GText { - width: parent.width + width: parent.width - 2 * Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("... is the provider authorized for this?") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -323,6 +364,10 @@ TutorialContent { GText { width: parent.width - 2 * Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The provider needs an authorization of the Federal Office of Administration.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -340,6 +385,10 @@ TutorialContent { GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Certificate") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -422,6 +471,10 @@ TutorialContent { GText { width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + anchors.horizontalCenter: parent.horizontalCenter //: LABEL ANDROID IOS text: qsTr("Everytime both participants authenticate each other...") + SettingsModel.translationTrigger @@ -434,6 +487,10 @@ TutorialContent { TutorialSpacer { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("... and therefore your data is protected and securely transfered.") + SettingsModel.translationTrigger color: Style.color.tutorial_what @@ -446,6 +503,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("You can also watch a video on YouTube on this topic") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary diff --git a/resources/qml/Governikus/TutorialView/+mobile/TutorialWhere.qml b/resources/qml/Governikus/TutorialView/+mobile/TutorialWhere.qml index 8afc46c90..1c819c411 100644 --- a/resources/qml/Governikus/TutorialView/+mobile/TutorialWhere.qml +++ b/resources/qml/Governikus/TutorialView/+mobile/TutorialWhere.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -15,6 +15,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("Where can I use the online ID function?") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -41,8 +45,12 @@ TutorialContent { GText { width: parent.width * 0.9 anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS - text: qsTr("On every website of a service provider where you see this icon:") + SettingsModel.translationTrigger + text: qsTr("On every website of a provider where you see this icon:") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary horizontalAlignment: Text.AlignHCenter } @@ -60,6 +68,10 @@ TutorialContent { GText { width: parent.width * 0.8 anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("By the way, you can find many services directly in the AusweisApp2 provider list.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content @@ -96,6 +108,10 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.9 + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The integrated self-disclosure is a special service to view the data saved on your ID card.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -109,6 +125,10 @@ TutorialContent { GText { width: parent.width * 0.8 anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("You can access the self-disclosure by clicking \"See my personal data\" on the AusweisApp2 start page, followed by \"Proceed to PIN entry\"") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header_secondary @@ -126,6 +146,10 @@ TutorialContent { TutorialSpacer { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("And this is how it works") + SettingsModel.translationTrigger color: Style.color.tutorial_where @@ -134,6 +158,10 @@ TutorialContent { GText { width: parent.width * 0.9 anchors.horizontalCenter: parent.horizontalCenter + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("The AusweisApp2 will always display who wants to access which of your data.") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -164,10 +192,16 @@ TutorialContent { GText { width: parent.width * 0.8 anchors.horizontalCenter: parent.horizontalCenter - //: LABEL ANDROID IOS - text: (Constants.is_layout_ios ? qsTr("Now lay down your ID card and hold the top of your iPhone to the ID card.") - : qsTr("Now lay down your ID card and place your device on the ID card.")) - + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (Constants.is_layout_ios ? + //: LABEL IOS + qsTr("Now lay down your ID card and hold the top of your iPhone to the ID card.") : + //: LABEL ANDROID + qsTr("Now lay down your ID card and place your device on the ID card.") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter } @@ -187,10 +221,17 @@ TutorialContent { GText { width: parent.width * 0.5 - //: LABEL ANDROID IOS - text: (Constants.is_layout_ios ? qsTr("Don't move your iPhone during the procedure!") - : qsTr("Don't move your device during the procedure!")) - + SettingsModel.translationTrigger + rightPadding: Constants.component_spacing + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (Constants.is_layout_ios ? + //: LABEL IOS + qsTr("Don't move your iPhone during the procedure!") : + //: LABEL ANDROID + qsTr("Don't move your device during the procedure!") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_content horizontalAlignment: Text.AlignLeft @@ -209,8 +250,16 @@ TutorialContent { GText { width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("Enter") : qsTr("Now")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("Enter") : + //: LABEL ANDROID IOS + qsTr("Now") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter @@ -230,6 +279,10 @@ TutorialContent { GText { width: parent.width + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + //: LABEL ANDROID IOS text: qsTr("6 digits long PIN") + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header @@ -244,8 +297,16 @@ TutorialContent { GText { anchors.horizontalCenter: parent.horizontalCenter width: parent.width * 0.8 - //: LABEL ANDROID IOS - text: (SettingsModel.language === "en" ? qsTr("now!") : qsTr("enter!")) + SettingsModel.translationTrigger + + Accessible.onScrollDownAction: baseItem.Accessible.scrollDownAction() + Accessible.onScrollUpAction: baseItem.Accessible.scrollUpAction() + + text: (SettingsModel.language === "en" ? + //: LABEL ANDROID IOS + qsTr("now!") : + //: LABEL ANDROID IOS + qsTr("enter!") + ) + SettingsModel.translationTrigger textStyle: Style.text.tutorial_header horizontalAlignment: Text.AlignHCenter diff --git a/resources/qml/Governikus/TutorialView/qmldir b/resources/qml/Governikus/TutorialView/qmldir index 7976d7af8..e3a26d802 100644 --- a/resources/qml/Governikus/TutorialView/qmldir +++ b/resources/qml/Governikus/TutorialView/qmldir @@ -18,9 +18,6 @@ internal TutorialReaderMethodBluetooth TutorialReaderMethodBluetooth.qml internal TutorialReaderMethodFooter TutorialReaderMethodFooter.qml internal TutorialExpandAnimation TutorialExpandAnimation.qml internal TutorialCollapseAnimation TutorialCollapseAnimation.qml -internal SetupAssistantBinaryDecisionView SetupAssistantBinaryDecisionView.qml -internal SetupAssistantCardReaderView SetupAssistantCardReaderView.qml -internal SetupAssistantButton SetupAssistantButton.qml SetupAssistantView 1.0 SetupAssistantView.qml TutorialView 1.0 TutorialView.qml diff --git a/resources/qml/Governikus/UpdateView/+desktop/UpdateView.qml b/resources/qml/Governikus/UpdateView/+desktop/UpdateView.qml new file mode 100644 index 000000000..19584764f --- /dev/null +++ b/resources/qml/Governikus/UpdateView/+desktop/UpdateView.qml @@ -0,0 +1,127 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.ResultView 1.0 +import Governikus.Style 1.0 +import Governikus.TitleBar 1.0 +import Governikus.Type.ApplicationModel 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.View 1.0 + + +SectionPage { + id: root + + signal leaveView() + + Accessible.name: qsTr("Application update view") + SettingsModel.translationTrigger + Accessible.description: qsTr("This is the application update panel of the AusweisApp2.") + SettingsModel.translationTrigger + + titleBarAction: TitleBarAction { + //: LABEL DESKTOP_QML + text: qsTr("Application update") + SettingsModel.translationTrigger + showHelp: false + } + + ResultView { + visible: !SettingsModel.appUpdateData.valid + + buttonType: NavigationButton.Type.Back + resultType: ResultView.Type.IsError + emailButtonVisible: false + //: LABEL DESKTOP_QML Placext if the update information are invalid, might be caused by network issues. + text: qsTr("The update information could not be retrieved. Please check your network connection.") + SettingsModel.translationTrigger + + onNextView: leaveView() + } + + ResultView { + visible: !SettingsModel.appUpdateAvailable && SettingsModel.appUpdateData.valid + + buttonType: NavigationButton.Type.Back + resultType: ResultView.Type.IsSuccess + emailButtonVisible: false + //: LABEL DESKTOP_QML The currently installed version is the most recent one, no action is required. + text: qsTr("Your version %1 of %2 is up to date!").arg(Qt.application.version).arg(Qt.application.name) + SettingsModel.translationTrigger + + onNextView: leaveView() + } + + Pane { + id: pane + + visible: SettingsModel.appUpdateData.valid && SettingsModel.appUpdateData.updateAvailable + anchors.fill: parent + anchors.margins: Constants.pane_padding + + activeFocusOnTab: true + + title: qsTr("An update is available (installed version %1)").arg(Qt.application.version) + SettingsModel.translationTrigger + + ColumnLayout { + width: parent.width + height: pane.availableContentHeight + + UpdateViewInformation { + id: updateInformation + + Layout.fillWidth: true + + releaseDate: SettingsModel.appUpdateData.date + version: SettingsModel.appUpdateData.version + downloadSize: SettingsModel.appUpdateData.size + } + + GSeparator { + Layout.fillWidth: true + Layout.topMargin: Constants.text_spacing + Layout.bottomMargin: Layout.topMargin + } + + UpdateViewReleaseNotes { + id: releaseNotesView + + Layout.fillWidth: true + Layout.fillHeight: true + + releaseNotes: SettingsModel.appUpdateData.notes + } + + GSeparator { + Layout.fillWidth: true + Layout.topMargin: Constants.text_spacing + Layout.bottomMargin: Layout.topMargin + } + + UpdateViewButtonRow { + id: updateButtons + + Layout.fillWidth: true + + downloadTooltip: SettingsModel.appUpdateData.url + + onDownloadUpdate: { + Qt.openUrlExternally(SettingsModel.appUpdateData.url) + root.leaveView() + } + onSkipUpdate: { + SettingsModel.appUpdateData.skipUpdate() + root.leaveView() + } + onRemindLater: root.leaveView() + } + } + } + + Keys.onPressed: { + if (event.key === Qt.Key_PageDown) + releaseNotesView.scrollDown() + else if (event.key === Qt.Key_PageUp) + releaseNotesView.scrollUp() + } +} diff --git a/resources/qml/Governikus/UpdateView/+desktop/UpdateViewButtonRow.qml b/resources/qml/Governikus/UpdateView/+desktop/UpdateViewButtonRow.qml new file mode 100644 index 000000000..647ddf456 --- /dev/null +++ b/resources/qml/Governikus/UpdateView/+desktop/UpdateViewButtonRow.qml @@ -0,0 +1,49 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Type.SettingsModel 1.0 + + +RowLayout { + id: root + + property alias downloadTooltip: downloadButton.enabledTooltipText + + signal skipUpdate() + signal remindLater() + signal downloadUpdate() + + GButton { + //: LABEL DESKTOP_QML User choice to skip this update, the automatic update check will *not* inform about this update again. + text: qsTr("Skip update") + SettingsModel.translationTrigger + + onClicked: root.skipUpdate() + } + + Item { + id: stretchSpacer + + Layout.fillWidth: true + } + + GButton { + //: LABEL DESKTOP_QML The available update is shown again after next automatic update check. + text: qsTr("Remind me later") + SettingsModel.translationTrigger + + onClicked: root.remindLater() + } + + GButton { + id: downloadButton + + //: LABEL DESKTOP_QML Download the update, opens the download link in the user's default browser. + text: qsTr("Download update") + SettingsModel.translationTrigger + + onClicked: root.downloadUpdate() + } +} diff --git a/resources/qml/Governikus/UpdateView/+desktop/UpdateViewInformation.qml b/resources/qml/Governikus/UpdateView/+desktop/UpdateViewInformation.qml new file mode 100644 index 000000000..cf8efda07 --- /dev/null +++ b/resources/qml/Governikus/UpdateView/+desktop/UpdateViewInformation.qml @@ -0,0 +1,154 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Layouts 1.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.Type.SettingsModel 1.0 +import Governikus.View 1.0 + + +ColumnLayout { + id: root + + property date releaseDate + property alias version: textVersion.text + property string downloadUrl + property string checksumUrl + property string notesUrl + property int downloadSize: -1 + + GridLayout { + Layout.fillWidth: true + + columns: 2 + columnSpacing: Constants.pane_spacing + + GText { + activeFocusOnTab: true + + //: LABEL DESKTOP_QML Information about the available, new version number. + text: qsTr("New version:") + SettingsModel.translationTrigger + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + id: textVersion + + activeFocusOnTab: true + + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + activeFocusOnTab: true + + //: LABEL DESKTOP_QML Date when the available update was released. + text: qsTr("Release date:") + SettingsModel.translationTrigger + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + activeFocusOnTab: true + + text: releaseDate.toLocaleDateString(Qt.locale(SettingsModel.language)) + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + activeFocusOnTab: true + + //: LABEL DESKTOP_QML Download size of the available update in megabyte. + text: qsTr("Download size:") + SettingsModel.translationTrigger + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + activeFocusOnTab: true + + text: (downloadSize / 1e6).toFixed(3) + " MB" + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + visible: downloadUrl !== "" + + activeFocusOnTab: true + + //: LABEL DESKTOP_QML Plaintext link to the update download. + text: qsTr("Download link:") + SettingsModel.translationTrigger + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + visible: downloadUrl !== "" + + activeFocusOnTab: true + + text: "%1".arg(downloadUrl) + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + visible: checksumUrl !== "" + + activeFocusOnTab: true + + //: LABEL DESKTOP_QML Link to download checksum to verify the downloaded update file. + text: qsTr("Checksum link:") + SettingsModel.translationTrigger + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + + GText { + visible: checksumUrl !== "" + + activeFocusOnTab: true + + text: "%1".arg(checksumUrl) + textStyle: Style.text.normal + + FocusFrame { + borderColor: Style.color.focus_indicator + } + } + } +} diff --git a/resources/qml/Governikus/UpdateView/+desktop/UpdateViewReleaseNotes.qml b/resources/qml/Governikus/UpdateView/+desktop/UpdateViewReleaseNotes.qml new file mode 100644 index 000000000..091fceaea --- /dev/null +++ b/resources/qml/Governikus/UpdateView/+desktop/UpdateViewReleaseNotes.qml @@ -0,0 +1,69 @@ +/* + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +import QtQuick 2.10 +import QtQuick.Controls 2.3 + +import Governikus.Global 1.0 +import Governikus.Style 1.0 +import Governikus.View 1.0 + + +Item { + id: root + + property alias releaseNotes: textReleaseNotes.text + + function scrollUp(){ scrollBar.decrease() } + function scrollDown(){ scrollBar.increase() } + + implicitHeight: textReleaseNotes.implicitHeight + + Flickable { + id: flickable + + anchors.fill: parent + topMargin: Constants.pane_padding + bottomMargin: topMargin + + activeFocusOnTab: true + + boundsBehavior: Flickable.StopAtBounds + contentHeight: textReleaseNotes.implicitHeight + clip: true + ScrollBar.vertical: ScrollBar { + id: scrollBar + + policy: size === 1.0 ? ScrollBar.AlwaysOff : ScrollBar.AlwaysOn + minimumSize: 0.1 + } + + GText { + id: textReleaseNotes + + width: parent.width - scrollBar.width + + textFormat: Text.RichText + textStyle: Style.text.normal + } + } + + ScrollGradients { + leftMargin: 0 + anchors.fill: parent + color: Style.color.background_pane + } + + FocusFrame { + scope: root + framee: flickable + } + + Keys.onPressed: { + if (event.key === Qt.Key_PageDown) + scrollBar.increase() + else if (event.key === Qt.Key_PageUp) + scrollBar.decrease() + } +} diff --git a/resources/qml/Governikus/UpdateView/qmldir b/resources/qml/Governikus/UpdateView/qmldir new file mode 100644 index 000000000..90a4256b2 --- /dev/null +++ b/resources/qml/Governikus/UpdateView/qmldir @@ -0,0 +1,8 @@ +module UpdateView + +internal UpdateViewButtonRow UpdateViewButtonRow.qml +internal UpdateViewInformation UpdateViewInformation.qml +internal UpdateViewReleaseNotes UpdateViewReleaseNotes.qml + +UpdateView 1.0 UpdateView.qml + diff --git a/resources/qml/Governikus/View/+desktop/Controller.qml b/resources/qml/Governikus/View/+desktop/Controller.qml index 03e77b776..fbc53ea73 100644 --- a/resources/qml/Governikus/View/+desktop/Controller.qml +++ b/resources/qml/Governikus/View/+desktop/Controller.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/View/+desktop/FocusFrame.qml b/resources/qml/Governikus/View/+desktop/FocusFrame.qml index 6f17b3bcc..9bd57aff9 100644 --- a/resources/qml/Governikus/View/+desktop/FocusFrame.qml +++ b/resources/qml/Governikus/View/+desktop/FocusFrame.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -15,7 +15,8 @@ Rectangle { property Item framee: parent property Item scope: parent property real marginFactor: 1 - property bool dynamic: true + property bool dynamic: false + property color borderColor: Style.color.focus_indicator_inverse readonly property real staticSize: Math.max(ApplicationModel.scaleFactor * 4, 1) readonly property real dynamicSize: Math.max(Math.min(framee.width, framee.height) / 32, 1) @@ -25,7 +26,7 @@ Rectangle { anchors.margins: marginFactor * -size * 2 radius: size * 2 border.width: scope.activeFocus ? size : 0; - border.color: Constants.white + border.color: borderColor opacity: 0.5 color: Style.color.transparent } diff --git a/resources/qml/Governikus/View/+desktop/FocusPoint.qml b/resources/qml/Governikus/View/+desktop/FocusPoint.qml index 059440baa..ec6ad12fb 100644 --- a/resources/qml/Governikus/View/+desktop/FocusPoint.qml +++ b/resources/qml/Governikus/View/+desktop/FocusPoint.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -24,6 +24,6 @@ Text { text: "✱" opacity: 0.5 - color: Style.text.hint.textColor - font.pixelSize: Style.text.hint.textSize + color: Style.color.focus_indicator_inverse + font.pixelSize: Style.dimens.hint_font_size } diff --git a/resources/qml/Governikus/View/+desktop/FramedImage.qml b/resources/qml/Governikus/View/+desktop/FramedImage.qml index f45f4e9f9..91522669c 100644 --- a/resources/qml/Governikus/View/+desktop/FramedImage.qml +++ b/resources/qml/Governikus/View/+desktop/FramedImage.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -9,7 +9,9 @@ import Governikus.Style 1.0 Item { - property alias border: frame.border + id: baseItem + + property alias tintColor: image.tintColor property alias source: image.source property bool circularFrame: true @@ -18,18 +20,16 @@ Item { color: Style.color.transparent border.width: height/20 - border.color: Constants.white + border.color: baseItem.tintColor anchors.fill: parent anchors.centerIn: parent radius: circularFrame ? width/2 : 0 } - Image { + TintableIcon { id: image - fillMode: Image.PreserveAspectFit anchors.margins: frame.border.width * 2 - anchors.centerIn: frame anchors.fill: frame sourceSize.height: frame.height sourceSize.width: frame.width diff --git a/resources/qml/Governikus/View/+desktop/SectionPage.qml b/resources/qml/Governikus/View/+desktop/SectionPage.qml index c18ee0cb8..2d68ebddc 100644 --- a/resources/qml/Governikus/View/+desktop/SectionPage.qml +++ b/resources/qml/Governikus/View/+desktop/SectionPage.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -18,15 +18,17 @@ Controller { Identify, ChangePin, Provider, - Information, + MoreView, Settings, History, - SetupAssistant + SetupAssistant, + AppUpdateInfo } property bool isAbstract: false property TitleBarAction titleBarAction: null readonly property bool sectionPageTypeMarker: true + function setActive() { if (visible && !isAbstract) { forceActiveFocus() diff --git a/resources/qml/Governikus/View/+mobile/+android/ContentArea.qml b/resources/qml/Governikus/View/+mobile/+android/ContentArea.qml index db67567c3..2b1d42840 100644 --- a/resources/qml/Governikus/View/+mobile/+android/ContentArea.qml +++ b/resources/qml/Governikus/View/+mobile/+android/ContentArea.qml @@ -1,62 +1,70 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import Governikus.Global 1.0 import Governikus.ChangePinView 1.0 -import Governikus.InformationView 1.0 import Governikus.RemoteServiceView 1.0 import Governikus.TutorialView 1.0 -import Governikus.FeedbackView 1.0 +import Governikus.MoreView 1.0 import Governikus.DeveloperView 1.0 import Governikus.IdentifyView 1.0 import Governikus.ProviderView 1.0 import Governikus.HistoryView 1.0 import Governikus.View 1.0 +import Governikus.SettingsView 1.0 import Governikus.Type.SettingsModel 1.0 Item { id: baseItem + property bool ready: SettingsModel.showSetupAssistantOnStart ? tutorialView.ready : identifyView.ready readonly property var visibleItem: visibleChildren[0] readonly property var currentSectionPage: if (visibleItem) visibleItem.currentSectionPage TabBarView { id: identifyView - anchors.fill: parent + visible: baseItem.state === "identify" + anchors.fill: parent + prefetch: baseItem.ready sourceComponent: IdentifyView {} } TabBarView { - anchors.fill: parent visible: baseItem.state === "provider" + anchors.fill: parent + prefetch: baseItem.ready sourceComponent: ProviderView {} } TabBarView { - anchors.fill: parent visible: baseItem.state === "history" + anchors.fill: parent + prefetch: baseItem.ready sourceComponent: HistoryView {} } TabBarView { id: pinView - anchors.fill: parent + visible: baseItem.state === "pin" + anchors.fill: parent + prefetch: baseItem.ready sourceComponent: ChangePinView {} } TabBarView { - anchors.fill: parent visible: baseItem.state === "remoteservice" + anchors.fill: parent + prefetch: baseItem.ready sourceComponent: RemoteServiceView { width: baseItem.width @@ -66,29 +74,32 @@ Item { TabBarView { id: tutorialView - anchors.fill: parent + visible: baseItem.state === "tutorial" - prefetch: baseItem.ready + anchors.fill: parent + sourceComponent: TutorialView {} } TabBarView { - anchors.fill: parent visible: baseItem.state === "feedback" + anchors.fill: parent + prefetch: baseItem.ready - sourceComponent: Feedback {} + sourceComponent: MoreView {} } TabBarView { anchors.fill: parent - visible: baseItem.state === "information" + visible: baseItem.state === "settings" prefetch: baseItem.ready - sourceComponent: InformationView {} + sourceComponent: SettingsView {} } TabBarView { - anchors.fill: parent visible: baseItem.state === "developeroptions" + anchors.fill: parent + prefetch: baseItem.ready sourceComponent: DeveloperView {} } diff --git a/resources/qml/Governikus/View/+mobile/+ios/ContentArea.qml b/resources/qml/Governikus/View/+mobile/+ios/ContentArea.qml index a9771670f..020505814 100644 --- a/resources/qml/Governikus/View/+mobile/+ios/ContentArea.qml +++ b/resources/qml/Governikus/View/+mobile/+ios/ContentArea.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/View/+mobile/ContentAreaLoader.qml b/resources/qml/Governikus/View/+mobile/ContentAreaLoader.qml index 2b69bb732..9060423d1 100644 --- a/resources/qml/Governikus/View/+mobile/ContentAreaLoader.qml +++ b/resources/qml/Governikus/View/+mobile/ContentAreaLoader.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/View/+mobile/FocusFrame.qml b/resources/qml/Governikus/View/+mobile/FocusFrame.qml index 3206ad7ec..93089919c 100644 --- a/resources/qml/Governikus/View/+mobile/FocusFrame.qml +++ b/resources/qml/Governikus/View/+mobile/FocusFrame.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -9,4 +9,5 @@ Item { property Item scope property real marginFactor property bool dynamic + property color borderColor } diff --git a/resources/qml/Governikus/View/+mobile/SectionPage.qml b/resources/qml/Governikus/View/+mobile/SectionPage.qml index 1c2b0fab3..6613bc0fe 100644 --- a/resources/qml/Governikus/View/+mobile/SectionPage.qml +++ b/resources/qml/Governikus/View/+mobile/SectionPage.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -34,7 +34,7 @@ Item { property bool topLevelPage: false property var navigationAction: null - property string title: null + property string title: "" property var rightTitleBarAction: null property var subTitleBarAction: null @@ -55,6 +55,9 @@ Item { property QtObject header property QtObject content + Accessible.onScrollDownAction: flickable.scrollPageDown() + Accessible.onScrollUpAction: flickable.scrollPageUp() + GFlickable { id: flickable diff --git a/resources/qml/Governikus/View/+mobile/TabBarView.qml b/resources/qml/Governikus/View/+mobile/TabBarView.qml index d15bbb2a6..fb588737e 100644 --- a/resources/qml/Governikus/View/+mobile/TabBarView.qml +++ b/resources/qml/Governikus/View/+mobile/TabBarView.qml @@ -1,10 +1,10 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import QtQuick.Controls 2.3 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.Style 1.0 @@ -170,7 +170,7 @@ Item { preventStealing: true onPressed: { - if (mouse.x < touchStartAreaWidth && currentSectionPage.navigationAction.state === "back") { + if (mouse.x < touchStartAreaWidth && (currentSectionPage.navigationAction.state === "back" || currentSectionPage.navigationAction.state === "hidden")) { mouse.accepted = true startPosX = mouse.x previousPosX = startPosX diff --git a/resources/qml/Governikus/WhiteListClient/+mobile/WhiteListSurveyView.qml b/resources/qml/Governikus/WhiteListClient/+mobile/WhiteListSurveyView.qml index 429b87de1..55dcc0d5d 100644 --- a/resources/qml/Governikus/WhiteListClient/+mobile/WhiteListSurveyView.qml +++ b/resources/qml/Governikus/WhiteListClient/+mobile/WhiteListSurveyView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -48,7 +48,6 @@ SectionPage { anchors.right: parent.right //: INFO ANDROID IOS Request to the user if the device information should be shared for statistics (Whitelist) - Part of content text text: qsTr("Would you like to help us to improve the AusweisApp2?") + SettingsModel.translationTrigger - textStyle: Style.text.normal } GText { @@ -56,7 +55,6 @@ SectionPage { anchors.right: parent.right //: INFO ANDROID IOS Request to the user if the device information should be shared for statistics (Whitelist) - Part of content text text: qsTr("Supplying your device characteristics helps us to gather reliable information about the compatibility of your device.") + SettingsModel.translationTrigger - textStyle: Style.text.normal } GText { @@ -64,7 +62,6 @@ SectionPage { anchors.right: parent.right //: INFO ANDROID IOS Request to the user if the device information should be shared for statistics (Whitelist) - Part of content text text: qsTr("The transmission is anonymous. No personal data is collected or transmitted!") + SettingsModel.translationTrigger - textStyle: Style.text.normal } Column { @@ -152,7 +149,6 @@ SectionPage { rightPadding: Constants.groupbox_spacing text: d.dataHidden ? "\u25BC" : "\u25B2" - textStyle: Style.text.normal horizontalAlignment: Text.AlignRight } @@ -165,7 +161,6 @@ SectionPage { rightPadding: Constants.groupbox_spacing text: qsTr("Collected data") + SettingsModel.translationTrigger - textStyle: Style.text.normal } } @@ -215,7 +210,6 @@ SectionPage { anchors.right: parent.right //: INFO ANDROID IOS Request to the user if the device information should be shared for statistics (Whitelist) - Thank you message text: qsTr("Thank you for your assistance!") + SettingsModel.translationTrigger - textStyle: Style.text.normal } } diff --git a/resources/qml/Governikus/Workflow/+desktop/GeneralWorkflow.qml b/resources/qml/Governikus/Workflow/+desktop/GeneralWorkflow.qml index 8ade5bb68..3de87f538 100644 --- a/resources/qml/Governikus/Workflow/+desktop/GeneralWorkflow.qml +++ b/resources/qml/Governikus/Workflow/+desktop/GeneralWorkflow.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -12,14 +12,17 @@ import Governikus.Type.ApplicationModel 1.0 import Governikus.Type.SettingsModel 1.0 import Governikus.Type.AuthModel 1.0 import Governikus.Type.NumberModel 1.0 -import Governikus.Type.CardReturnCode 1.0 import Governikus.Type.ReaderPlugIn 1.0 +import Governikus.Type.RemoteServiceModel 1.0 SectionPage { + id: root + property int waitingFor: 0 property bool isPinChange: false + signal settingsRequested() Accessible.name: qsTr("General workflow view") + SettingsModel.translationTrigger Accessible.description: qsTr("This is the general workflow view of the AusweisApp2.") + SettingsModel.translationTrigger @@ -30,8 +33,12 @@ SectionPage readonly property bool foundSelectedReader: ApplicationModel.foundSelectedReader readonly property bool foundPCSCReader: ApplicationModel.foundSelectedReader && ApplicationModel.isReaderTypeAvailable(ReaderPlugIn.PCSC) readonly property bool foundRemoteReader: ApplicationModel.foundSelectedReader && ApplicationModel.isReaderTypeAvailable(ReaderPlugIn.REMOTE) - //: LABEL DESKTOP_QML - readonly property string purpose: (isPinChange ? qsTr("Change PIN") : qsTr("Identify")) + SettingsModel.translationTrigger + readonly property string purpose: (isPinChange ? + //: LABEL DESKTOP_QML + qsTr("Change PIN") : + //: LABEL DESKTOP_QML + qsTr("Identify") + ) + SettingsModel.translationTrigger } @@ -40,7 +47,7 @@ SectionPage target: ApplicationModel onFireCertificateRemoved: { //: INFO DESKTOP_QML The paired devices was removed since it did not respond to connection attempts. It needs to be paired again if it should be used as card reader. - ApplicationModel.showFeedback(qsTr("The device %1 was unpaired because it does not react to connection attempts. Retry the pairing process if you want to use this device to authenticate yourself.").arg(pDeviceName)) + ApplicationModel.showFeedback(qsTr("The device %1 was unpaired because it did not react to connection attempts. Pair the device again to use it as a card reader.").arg(pDeviceName)) } } @@ -53,7 +60,6 @@ SectionPage font.bold: true //: LABEL DESKTOP_QML text: qsTr("Attempts") + SettingsModel.translationTrigger - textStyle: Style.text.normal } StatusIcon { @@ -118,7 +124,6 @@ SectionPage anchors.topMargin: Constants.component_spacing activeFocusOnTab: true - Accessible.role: Accessible.Paragraph Accessible.name: mainText.text text: { @@ -131,7 +136,7 @@ SectionPage return qsTr("The used card reader does not meet the technical requirements (Extended Length not supported).") } //: LABEL DESKTOP_QML - return d.foundSelectedReader ? d.purpose : qsTr("Establish connection") + return d.foundSelectedReader ? d.purpose : qsTr("Searching for card reader") case Workflow.WaitingFor.Card: if (NumberModel.pinDeactivated) { //: LABEL DESKTOP_QML @@ -145,7 +150,7 @@ SectionPage return "" } } - textStyle: Style.text.header + textStyle: Style.text.header_inverse horizontalAlignment: Text.AlignHCenter FocusFrame {} @@ -156,15 +161,15 @@ SectionPage readonly property string requestCardText: { if (d.foundPCSCReader && !d.foundRemoteReader) { - //: INFO DESKTOP_QML The AA2 is waiting for an id card to be inserted into the card reader. - return qsTr("Please insert the card into the device") + //: INFO DESKTOP_QML The AA2 is waiting for an ID card to be inserted into the card reader. + return qsTr("Please put the ID card on the card reader.") } else if (!d.foundPCSCReader && d.foundRemoteReader) { //: INFO DESKTOP_QML The AA2 is waiting for the smartphone to be placed on the id. - return qsTr("Please place the smartphone on the card") + return qsTr("Connected to %1. Please place the NFC interface of the smartphone on your ID card.").arg(RemoteServiceModel.connectedServerDeviceNames) } - //: INFO DESKTOP_QML The AA2 is waiting for an id card to be inserted into the card reader (or smartphone for that matter). - return qsTr("Please place the smartphone on the card or insert the card into the device") + //: INFO DESKTOP_QML The AA2 is waiting for an ID card to be inserted into the card reader (or smartphone for that matter). + return qsTr("Please place the smartphone (connected to %1) on your ID card or put the ID card on the card reader.").arg(RemoteServiceModel.connectedServerDeviceNames) } visible: text !== "" && !ApplicationModel.extendedLengthApdusUnsupported @@ -174,7 +179,6 @@ SectionPage anchors.topMargin: Constants.text_spacing activeFocusOnTab: true - Accessible.role: Accessible.Paragraph Accessible.name: subText.text text: { @@ -182,12 +186,12 @@ SectionPage switch (waitingFor) { case Workflow.WaitingFor.Reader: - //: INFO DESKTOP_QML AA2 is waiting for the card reader or the id card. - return d.foundSelectedReader ? requestCardText : qsTr("Searching for card reader") + //: INFO DESKTOP_QML AA2 is waiting for the card reader or the ID card. + return d.foundSelectedReader ? requestCardText : qsTr("No card reader detected. Please make sure that a card reader is connected. Open the %1reader settings%2 to configure reader and get more information about supported readers.").arg("").arg("") case Workflow.WaitingFor.Card: if (NumberModel.pinDeactivated) { //: INFO DESKTOP_QML The online authentication feature of the card is disabled and needs to be activated by the authorities. - return qsTr("The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function.") + return qsTr("The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function.") } return requestCardText case Workflow.WaitingFor.Password: @@ -197,10 +201,12 @@ SectionPage return "" } } - textStyle: Style.text.header_secondary + textStyle: Style.text.header_secondary_inverse horizontalAlignment: Text.AlignHCenter + onLinkActivated: root.settingsRequested() + FocusFrame {} } } diff --git a/resources/qml/Governikus/Workflow/+desktop/ProgressCircle.qml b/resources/qml/Governikus/Workflow/+desktop/ProgressCircle.qml index 0b9f2f09b..7d1317132 100644 --- a/resources/qml/Governikus/Workflow/+desktop/ProgressCircle.qml +++ b/resources/qml/Governikus/Workflow/+desktop/ProgressCircle.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -91,7 +91,7 @@ Item { anchors.centerIn: parent color: Style.color.transparent radius: height / 2 - border.color: Constants.white + border.color: Style.color.primary_text_inverse border.width: ApplicationModel.scaleFactor * 6 } } diff --git a/resources/qml/Governikus/Workflow/+desktop/TextCircle.qml b/resources/qml/Governikus/Workflow/+desktop/TextCircle.qml index 6bc3a4ca5..8b2093022 100644 --- a/resources/qml/Governikus/Workflow/+desktop/TextCircle.qml +++ b/resources/qml/Governikus/Workflow/+desktop/TextCircle.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -16,12 +16,14 @@ Rectangle { width: height enabled: false radius: width * 0.5 - color: enabled ? Style.color.accent : Constants.white + color: enabled ? Style.color.accent : Style.color.background_pane + border.width: Style.dimens.high_contrast_item_border + border.color: Style.color.high_contrast_item_border GText { id: number anchors.centerIn: parent font.bold: true - textStyle: parent.enabled ? Style.text.header : Style.text.header_accent + textStyle: parent.enabled ? Style.text.header_inverse : Style.text.header_accent } } diff --git a/resources/qml/Governikus/Workflow/+mobile/BluetoothWorkflow.qml b/resources/qml/Governikus/Workflow/+mobile/BluetoothWorkflow.qml index c56c98c62..231698bf8 100644 --- a/resources/qml/Governikus/Workflow/+mobile/BluetoothWorkflow.qml +++ b/resources/qml/Governikus/Workflow/+mobile/BluetoothWorkflow.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.1 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.TechnologyInfo 1.0 @@ -35,6 +35,16 @@ Item { } } + onVisibleChanged: if (visible && ApplicationModel.bluetoothAvailable) deprecationWarning.open() + + ConfirmationPopup { + id: deprecationWarning + + style: ConfirmationPopup.PopupStyle.OkButton + title: qsTr("Deprecation warning") + SettingsModel.translationTrigger + text: qsTr("Bluetooth support will be removed in the next version of %1!").arg(Qt.application.name) + SettingsModel.translationTrigger + } + ProgressIndicator { id: progressIndicator anchors.left: parent.left @@ -59,8 +69,12 @@ Item { anchors.bottom: technologySwitch.top enableButtonVisible: ApplicationModel.bluetoothAvailable && (!ApplicationModel.bluetoothEnabled || parent.showLocationPermissionInfo) - //: LABEL ANDROID IOS - enableButtonText: (!ApplicationModel.bluetoothEnabled ? qsTr("Enable Bluetooth") : qsTr("Continue")) + SettingsModel.translationTrigger + enableButtonText: (!ApplicationModel.bluetoothEnabled ? + //: LABEL ANDROID IOS + qsTr("Enable Bluetooth") : + //: LABEL ANDROID IOS + qsTr("Continue") + ) + SettingsModel.translationTrigger onEnableClicked: { if (!ApplicationModel.bluetoothEnabled) { ApplicationModel.bluetoothEnabled = true @@ -69,29 +83,35 @@ Item { } } enableText: (!visible ? "" + : !ApplicationModel.bluetoothAvailable ? + //: INFO ANDROID IOS Bluetooth is not available to AA2, the user is requested to use NFC instead. + qsTr("Bluetooth is not supported by your device.") + "
" + //: INFO ANDROID IOS Bluetooth is not available to AA2, the user is requested to use NFC instead. - : !ApplicationModel.bluetoothAvailable ? qsTr("Bluetooth is not supported by your device.") + "
" + qsTr("Please try NFC.") + qsTr("Please try NFC.") + : !ApplicationModel.bluetoothEnabled ? + //: INFO ANDROID IOS Bluetooth is available but not active. + qsTr("Bluetooth is switched off.") + "
" + //: INFO ANDROID IOS Bluetooth is available but not active. - : !ApplicationModel.bluetoothEnabled ? qsTr("Bluetooth is switched off.") + "
" + qsTr("Please enable Bluetooth.") + qsTr("Please enable Bluetooth.") //: INFO ANDROID IOS Bluetooth is active but the AA2 does not have the location permission which is required to find the bluetooth reader. The user is asked to give the permission to the AA2 after pressing the "ok" button. - : parent.showLocationPermissionInfo ? qsTr("No paired and activated Bluetooth device was detected. The AusweisApp2 needs access to your location in order to discover available devices. You can grant this permission after clicking the continue button.") + : parent.showLocationPermissionInfo ? qsTr("No paired and activated Bluetooth device has been detected. To discover available devices the location permission has to be granted to the AusweisApp2. You can grant this permission after clicking the continue button.") //: INFO ANDROID IOS The connection to the bluetooth reader failed. - : !ApplicationModel.bluetoothResponding ? qsTr("An error occured while connecting to your bluetooth device. Try to pair your device in the system settings and restart the app.") + : !ApplicationModel.bluetoothResponding ? qsTr("An error occured while connecting to your bluetooth card reader. Please pair your card reader in the system settings and restart the app.") : "") + SettingsModel.translationTrigger //: INFO ANDROID IOS Status message while connecting to the bluetooth reader - Header - titleText: ((baseItem.waitingFor === Workflow.WaitingFor.Reader) ? qsTr("Establish connection") - //: INFO ANDROID IOS Status message while the connection to the bluetooth has been established and an id card needs to be inserted - Header - : (baseItem.waitingFor === Workflow.WaitingFor.Card) ? qsTr("Determine card") + titleText: ((baseItem.waitingFor === Workflow.WaitingFor.Reader) ? qsTr("Establishing connection...") + //: INFO ANDROID IOS Status message while the connection to the bluetooth has been established and an ID card needs to be inserted - Header + : (baseItem.waitingFor === Workflow.WaitingFor.Card) ? qsTr("Determining card...") : "") + SettingsModel.translationTrigger //: LABEL ANDROID IOS subTitleText: (!visible ? "" : !!NumberModel.inputError ? NumberModel.inputError //: INFO ANDROID IOS Status message while the connection to the bluetooth reader is being established. - : (baseItem.waitingFor === Workflow.WaitingFor.Reader) ? qsTr("Search card reader...") - //: INFO ANDROID IOS Status message after the connection to the bluetooth reader is established and an id card needs to be inserted. - : (baseItem.waitingFor === Workflow.WaitingFor.Card) ? qsTr("Please insert your ID card.") + : (baseItem.waitingFor === Workflow.WaitingFor.Reader) ? qsTr("Searching for card reader...") + //: INFO ANDROID IOS Status message after the connection to the bluetooth reader is established and an ID card needs to be inserted. + : (baseItem.waitingFor === Workflow.WaitingFor.Card) ? qsTr("Please insert your ID card into your card reader.") : "") + SettingsModel.translationTrigger } diff --git a/resources/qml/Governikus/Workflow/+mobile/BusyImageIndicator.qml b/resources/qml/Governikus/Workflow/+mobile/BusyImageIndicator.qml index aaeb4e770..4d96534b4 100644 --- a/resources/qml/Governikus/Workflow/+mobile/BusyImageIndicator.qml +++ b/resources/qml/Governikus/Workflow/+mobile/BusyImageIndicator.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Workflow/+mobile/CardReader.qml b/resources/qml/Governikus/Workflow/+mobile/CardReader.qml index c77bd86ce..36ec23b45 100644 --- a/resources/qml/Governikus/Workflow/+mobile/CardReader.qml +++ b/resources/qml/Governikus/Workflow/+mobile/CardReader.qml @@ -1,11 +1,12 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 import Governikus.Global 1.0 import Governikus.Style 1.0 +import Governikus.Type.Random 1.0 Item { property bool pinFieldAnimation: true @@ -26,7 +27,7 @@ Item { onTimer.triggeredOnStart = false if (pinFieldAnimation) { - onTimer.index = Utils.getRandomInt(0, 9) + onTimer.index = Random.randomInt(0, 8) repeater.itemAt(onTimer.index).state = "on" } @@ -79,7 +80,7 @@ Item { Rectangle { id: card - color: Style.color.id_card + color: Style.color.accent radius: height * 0.05 anchors.horizontalCenter: parent.horizontalCenter height: baseItem.height * 1.5 / 7 diff --git a/resources/qml/Governikus/Workflow/+mobile/GeneralWorkflow.qml b/resources/qml/Governikus/Workflow/+mobile/GeneralWorkflow.qml index 9dadd5513..5f55e790e 100644 --- a/resources/qml/Governikus/Workflow/+mobile/GeneralWorkflow.qml +++ b/resources/qml/Governikus/Workflow/+mobile/GeneralWorkflow.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -10,47 +10,40 @@ import Governikus.Workflow 1.0 import Governikus.View 1.0 import Governikus.Type.ReaderPlugIn 1.0 -SectionPage -{ - QtObject { - id: d - readonly property int readerPlugInType: workflowModel.readerPlugInType - } - +SectionPage { id: baseItem property var controller property var workflowModel property string workflowTitle - property int waitingFor: 0 navigationAction: NavigationAction { enabled: baseItem.waitingFor !== Workflow.WaitingFor.Password state: enabled ? "cancel" : "hidden" - onClicked: workflowModel.cancelWorkflow() + onClicked: if (enabled) workflowModel.cancelWorkflow() } title: workflowTitle - NfcWorkflow - { + NfcWorkflow { + visible: workflowModel.readerPlugInType == ReaderPlugIn.NFC anchors.fill: parent - visible: d.readerPlugInType === ReaderPlugIn.NFC + onRequestPluginType: workflowModel.readerPlugInType = pReaderPlugInType; } - RemoteWorkflow - { + RemoteWorkflow { + visible: workflowModel.readerPlugInType == ReaderPlugIn.REMOTE || workflowModel.readerPlugInType == ReaderPlugIn.PCSC anchors.fill: parent - visible: d.readerPlugInType === ReaderPlugIn.REMOTE || d.readerPlugInType === ReaderPlugIn.PCSC + onRequestPluginType: workflowModel.readerPlugInType = pReaderPlugInType; } - BluetoothWorkflow - { + BluetoothWorkflow { + visible: workflowModel.readerPlugInType == ReaderPlugIn.BLUETOOTH anchors.fill: parent + waitingFor: baseItem.waitingFor - visible: d.readerPlugInType === ReaderPlugIn.BLUETOOTH onLocationPermissionInfoConfirmedChanged: controller.locationPermissionConfirmed = locationPermissionInfoConfirmed onContinueWorkflow: workflowModel.continueWorkflow() onRequestPluginType: workflowModel.readerPlugInType = pReaderPlugInType; diff --git a/resources/qml/Governikus/Workflow/+mobile/NfcProgressIndicator.qml b/resources/qml/Governikus/Workflow/+mobile/NfcProgressIndicator.qml index 3669ab184..afab56e8e 100644 --- a/resources/qml/Governikus/Workflow/+mobile/NfcProgressIndicator.qml +++ b/resources/qml/Governikus/Workflow/+mobile/NfcProgressIndicator.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -51,7 +51,12 @@ Item { State { name: "on" PropertyChanges { target: grayLevel; visible: false } - PropertyChanges { target: card; x: (baseItem.width + phone.width - card.width)/2; y: baseItem.height / 4; rotation: 0 } + PropertyChanges { + target: card + x: (baseItem.width + (Constants.is_layout_ios ? 0 : phone.width) - card.width) / 2 + y: (Constants.is_layout_ios ? 0 : baseItem.height / 4) + rotation: (Constants.is_layout_ios ? 0 : 62) + } PropertyChanges { target: shaking; running: true } } ] @@ -70,7 +75,7 @@ Item { Image { id: card - source: "qrc:///images/ausweis.png" + source: "qrc:///images/ausweis.svg" height: phone.height width: height fillMode: Image.PreserveAspectFit diff --git a/resources/qml/Governikus/Workflow/+mobile/NfcWorkflow.qml b/resources/qml/Governikus/Workflow/+mobile/NfcWorkflow.qml index fa75274b2..4dad11e3d 100644 --- a/resources/qml/Governikus/Workflow/+mobile/NfcWorkflow.qml +++ b/resources/qml/Governikus/Workflow/+mobile/NfcWorkflow.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.1 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.TechnologyInfo 1.0 @@ -47,26 +47,39 @@ Item { clip: true enableButtonVisible: ApplicationModel.nfcAvailable && (!ApplicationModel.nfcEnabled || !ApplicationModel.nfcRunning) - //: LABEL DESKTOP_QML - enableButtonText: (!ApplicationModel.nfcEnabled ? qsTr("Go to NFC settings") : qsTr("Start NFC scan")) + SettingsModel.translationTrigger + enableButtonText: (!ApplicationModel.nfcEnabled ? + //: LABEL ANDROID IOS + qsTr("Go to NFC settings") : + //: LABEL ANDROID IOS + qsTr("Start NFC scan") + ) + SettingsModel.translationTrigger onEnableClicked: !ApplicationModel.nfcEnabled ? ApplicationModel.showSettings(ApplicationModel.SETTING_NFC) : ApplicationModel.nfcRunning = true enableText: (!visible ? "" : + !ApplicationModel.nfcAvailable ? //: INFO ANDROID IOS AA2 can't use NFC on this device, suggest to use bluetooth instead. - !ApplicationModel.nfcAvailable ? qsTr("NFC is not supported by your device.") + "
" + qsTr("You require an additional 'Bluetooth card reader' or an additional 'smartphone as card reader' to use the online identification function with this device.") : + qsTr("Unfortunately, this functionality is not available on your device.") + "
" + + //: INFO ANDROID IOS AA2 can't use NFC on this device, suggest to use bluetooth instead. + qsTr("However you can use a seperate 'Bluetooth card reader' or a seperate 'smartphone as card reader' to utilize the online identification function.") : + !ApplicationModel.nfcEnabled ? + //: INFO ANDROID IOS NFC is available but needs to be activated in the settings of the smartphone. + qsTr("NFC is switched off.") + "
" + + //: INFO ANDROID IOS NFC is available but needs to be activated in the settings of the smartphone. + qsTr("Please enable NFC in your system settings.") : + !ApplicationModel.nfcRunning ? + //: INFO ANDROID IOS NFC is available but needs to be activated in the settings of the smartphone. + qsTr("NFC scan is not running.") + "
" + //: INFO ANDROID IOS NFC is available but needs to be activated in the settings of the smartphone. - !ApplicationModel.nfcEnabled ? qsTr("NFC is switched off.") + "
" + qsTr("Please enable NFC in your system settings.") : - //: INFO ANDROID IOS NFC is available but needs to be activated in the settings of the smartphone. - !ApplicationModel.nfcRunning ? qsTr("NFC scan is not running.") + "
" + qsTr("Please start the NFC scan.") : "" + qsTr("Please start the NFC scan.") : "" ) + SettingsModel.translationTrigger titleText: qsTr("Establish connection") + SettingsModel.translationTrigger subTitleText: (!visible ? "" : //: INFO ANDROID IOS The NFC interface does not meet the minimum requirements, using a bluetooth reader or a differnt smarthpone is suggested. - ApplicationModel.extendedLengthApdusUnsupported ? qsTr("Your device does not meet the technical requirements (Extended Length not supported). You require an additional 'Bluetooth card reader' or an additional 'smartphone as card reader' to use the online identification function with this device.") : + ApplicationModel.extendedLengthApdusUnsupported ? qsTr("Your device does not meet the technical requirements (Extended Length not supported). However you can use a seperate 'Bluetooth card reader' or a seperate 'smartphone as card reader' to utilize the online identification function.") : //: INFO ANDROID IOS The online authentication feature is disabled and needs to be activated by the authorities. - NumberModel.pinDeactivated ? qsTr("The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function.") : - //: INFO ANDROID IOS The id card may be inserted, the authentication process may be started. + NumberModel.pinDeactivated ? qsTr("The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function.") : + //: INFO ANDROID IOS The ID card may be inserted, the authentication process may be started. qsTr("Please place your device
on your ID card.") ) + SettingsModel.translationTrigger } diff --git a/resources/qml/Governikus/Workflow/+mobile/ProgressCircle.qml b/resources/qml/Governikus/Workflow/+mobile/ProgressCircle.qml index 15071cd64..6392302a2 100644 --- a/resources/qml/Governikus/Workflow/+mobile/ProgressCircle.qml +++ b/resources/qml/Governikus/Workflow/+mobile/ProgressCircle.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Workflow/+mobile/ProgressIndicator.qml b/resources/qml/Governikus/Workflow/+mobile/ProgressIndicator.qml index e80dbd186..aafa70526 100644 --- a/resources/qml/Governikus/Workflow/+mobile/ProgressIndicator.qml +++ b/resources/qml/Governikus/Workflow/+mobile/ProgressIndicator.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/qml/Governikus/Workflow/+mobile/RemoteWorkflow.qml b/resources/qml/Governikus/Workflow/+mobile/RemoteWorkflow.qml index 53d24091d..81188b4f9 100644 --- a/resources/qml/Governikus/Workflow/+mobile/RemoteWorkflow.qml +++ b/resources/qml/Governikus/Workflow/+mobile/RemoteWorkflow.qml @@ -1,9 +1,9 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 -import QtQuick.Layouts 1.1 +import QtQuick.Layouts 1.3 import Governikus.Global 1.0 import Governikus.RemoteServiceView 1.0 @@ -27,7 +27,7 @@ Item { target: ApplicationModel onFireCertificateRemoved: { //: INFO ANDROID IOS The paired smartphone was removed since it did not respond to connection attempts. It needs to be paired again before using it. - ApplicationModel.showFeedback(qsTr("The device %1 was unpaired because it does not react to connection attempts. Retry the pairing process if you want to use this device to authenticate yourself.").arg(pDeviceName)) + ApplicationModel.showFeedback(qsTr("The device %1 was unpaired because it did not react to connection attempts. Pair the device again to use it as a card reader.").arg(pDeviceName)) } } @@ -88,7 +88,7 @@ Item { return qsTr("To use the remote service WiFi has to be activated. Please activate WiFi in your device settings."); } else if (!foundSelectedReader) { //: INFO ANDROID IOS No paired and reachable device was found, hint that the remote device needs to be actually started for this feature. - return qsTr("No paired and activated remote device was detected. Make sure that you have started the remote service on your remote device."); + return qsTr("No paired smartphone as cardreader (SaC) with activated \"remote service\" available."); } else { return ""; } @@ -110,13 +110,13 @@ Item { return NumberModel.inputError; } else if (ApplicationModel.extendedLengthApdusUnsupported) { //: INFO ANDROID IOS The device does not support Extended Length and can not be used as card reader. - qsTr("Your remote device does not meet the technical requirements (Extended Length not supported)."); + qsTr("The connected smartphone as card reader (SaC) unfortunately does not meet the technical requirements (Extended Length not supported)."); } else if (NumberModel.pinDeactivated) { //: INFO ANDROID IOS The online authentication is disabled and needs to be enabled by the authorities. - return qsTr("The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function."); + return qsTr("The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function."); } else { - //: INFO ANDROID IOS The connection to the smartphone was established, the id card may be inserted. - return qsTr("Connected to %1. Please insert your ID card.").arg(RemoteServiceModel.connectedServerDeviceNames); + //: INFO ANDROID IOS The connection to the smartphone was established, the ID card may be inserted. + return qsTr("Connected to %1. Please place the NFC interface of the smartphone on your ID card.").arg(RemoteServiceModel.connectedServerDeviceNames); } } } diff --git a/resources/qml/Governikus/Workflow/+mobile/TextCircle.qml b/resources/qml/Governikus/Workflow/+mobile/TextCircle.qml index 3fc61d6c9..17abb38bb 100644 --- a/resources/qml/Governikus/Workflow/+mobile/TextCircle.qml +++ b/resources/qml/Governikus/Workflow/+mobile/TextCircle.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 @@ -37,7 +37,6 @@ Item { id: t anchors.centerIn: rec font.bold: parent.state === "active" - textStyle: Style.text.normal color: parent.state === "active" ? Constants.white : Style.color.accent } diff --git a/resources/qml/Governikus/Workflow/Workflow.qml b/resources/qml/Governikus/Workflow/Workflow.qml index 2934fd20b..1fee502d3 100644 --- a/resources/qml/Governikus/Workflow/Workflow.qml +++ b/resources/qml/Governikus/Workflow/Workflow.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtQuick 2.10 diff --git a/resources/translations/ausweisapp2_de.ts b/resources/translations/ausweisapp2_de.ts index 5f77e23cc..f1f2ccc5c 100644 --- a/resources/translations/ausweisapp2_de.ts +++ b/resources/translations/ausweisapp2_de.ts @@ -3,14 +3,6 @@ AboutDialog - - Developer mode: - Entwicklermodus: - - - use - verwenden - OK OK @@ -19,6 +11,14 @@ AusweisApp2 is a product of Governikus GmbH & Co. KG - on behalf of the Federal Office for Information Security. Die AusweisApp2 ist ein Produkt der Governikus GmbH & Co. KG - im Auftrag des Bundesamtes für Sicherheit in der Informationstechnik. + + Developer options: + Entwickleroptionen: + + + show in the settings + in den Einstellungen anzeigen + AdditionalResultsItem @@ -180,22 +180,6 @@ EN - - AvailableDevicesListDelegate - - Great quality - LABEL ANDROID IOS - Gute Qualität - - - Bad quality - Schlechte Qualität - - - Device %1 is available for pairing - Gerät %1 kann gekoppelt werden - - BaseConfirmationPopup @@ -225,9 +209,20 @@ BaseProviderView - No match found - LABEL IOS_PHONE ANDROID_PHONE Der in das Suchfeld eingegebene String erzielte kein Ergebnis - Keine Übereinstimmung gefunden + No results matching your search query found + LABEL IOS_PHONE ANDROID_PHONE The text entered into the provider search field results in no matches + Keine Ergebnisse zu Ihrer Suche gefunden + + + + BinaryDecisionView + + Yes + Ja + + + No, later + Nein, später @@ -239,6 +234,7 @@ Continue + LABEL ANDROID IOS Fortsetzen @@ -248,6 +244,7 @@ Please try NFC. + INFO ANDROID IOS Bluetooth is not available to AA2, the user is requested to use NFC instead. Bitte versuchen Sie NFC. @@ -257,37 +254,46 @@ Please enable Bluetooth. + INFO ANDROID IOS Bluetooth is available but not active. Bitte aktivieren Sie Bluetooth. - No paired and activated Bluetooth device was detected. The AusweisApp2 needs access to your location in order to discover available devices. You can grant this permission after clicking the continue button. + No paired and activated Bluetooth device has been detected. To discover available devices the location permission has to be granted to the AusweisApp2. You can grant this permission after clicking the continue button. INFO ANDROID IOS Bluetooth is active but the AA2 does not have the location permission which is required to find the bluetooth reader. The user is asked to give the permission to the AA2 after pressing the "ok" button. - Es konnte kein gekoppelter, eingeschalteter Bluetooth-Kartenleser erkannt werden. Zur Erkennung benötigt die AusweisApp2 Zugriff auf Ihren Standort. Nach Klicken auf den Fortsetzen-Knopf können Sie die benötigte Freigabe erteilen. + Es konnte kein gekoppeltes, eingeschaltetes Bluetooth Kartenlesegerät erkannt werden. Zur Erkennung benötigt die AusweisApp2 das Recht für Standortzugriff. Nach Klicken auf den Fortsetzen-Knopf können Sie die benötigte Freigabe erteilen. - An error occured while connecting to your bluetooth device. Try to pair your device in the system settings and restart the app. + An error occured while connecting to your bluetooth card reader. Please pair your card reader in the system settings and restart the app. INFO ANDROID IOS The connection to the bluetooth reader failed. - Beim Verbindungsaufbau zum Bluetooth-Kartenleser ist ein Fehler aufgetreten. Bitte koppeln Sie das Gerät über die Einstellungen des Systems und starten Sie die App erneut. + Beim Verbindungsaufbau zum Bluetooth-Kartenleser ist ein Fehler aufgetreten. Bitte koppeln Sie den Kartenleser über die Einstellungen des Systems und starten Sie die App erneut. - Establish connection + Establishing connection... INFO ANDROID IOS Status message while connecting to the bluetooth reader - Header - Verbindung wird hergestellt + Verbindung wird hergestellt... - Determine card - INFO ANDROID IOS Status message while the connection to the bluetooth has been established and an id card needs to be inserted - Header - Ermittle Ausweis + Determining card... + INFO ANDROID IOS Status message while the connection to the bluetooth has been established and an ID card needs to be inserted - Header + Ermittle Ausweis... - Search card reader... + Please insert your ID card into your card reader. + INFO ANDROID IOS Status message after the connection to the bluetooth reader is established and an ID card needs to be inserted. + Bitte stecken Sie Ihren Ausweis in den Kartenleser. + + + Searching for card reader... LABEL ANDROID IOS INFO ANDROID IOS Status message while the connection to the bluetooth reader is being established. - Suche Kartenleser... + Suche nach Kartenleser... + + + Deprecation warning + Abkündigungshinweis - Please insert your ID card. - INFO ANDROID IOS Status message after the connection to the bluetooth reader is established and an id card needs to be inserted. - Bitte legen Sie Ihren Ausweis ein. + Bluetooth support will be removed in the next version of %1! + Die Bluetooth-Unterstützung wird in der nächsten Version der %1 entfernt! @@ -351,12 +357,23 @@ Abbrechen + + CardReaderDelegate + + Press space to open the link in your browser + Drücken Sie die Leertaste um den Link im Browser zu öffnen + + CardReaderView After connecting a new card reader it may take a few seconds to recognize the driver. It may be necessary to restart your system after installing the driver. Only supported and connected card reader are shown here. %1 Nachdem ein neuer Kartenleser angeschlossen worden ist, kann es einige Sekunden dauern bis der Treiber erkannt wird. Unter Umständen kann ein Neustart Ihres Betriebssystems notwendig sein. Es werden hier nur unterstützte und angeschlossene Kartenleser angezeigt. %1 + + Connected USB card reader + Verbundene USB-Kartenleser + Category @@ -400,7 +417,7 @@ LABEL ANDROID IOS Schließen - Self-authentication data view + Self-Authentication data view Datenansicht der Selbstauskunft @@ -412,15 +429,21 @@ LABEL ANDROID IOS ChangePinController You may now remove your ID card from the device. - INFO DESKTOP_QML Changing the PIN was successful; hint that the id card may now be removed from the card reader. + INFO DESKTOP_QML Changing the PIN was successful; hint that the ID card may now be removed from the card reader. ---------- -INFO ANDROID IOS Hint that the id card may be removed from the card reader since the PIN was changed successfully. - Sie können nun Ihr Ausweisdokument vom Gerät entfernen. +INFO ANDROID IOS Hint that the ID card may be removed from the card reader since the PIN was changed successfully. + Sie können nun Ihren Ausweis vom Gerät entfernen. - Weak NFC signal + Weak NFC signal. Please +- change the card position +- remove the mobile phone case (if present) +- connect the smartphone with a charging cable INFO IOS The NFC signal is weak or unstable. The scan is stopped with this information in the iOS dialog. - Schwacher NFC-Empfang + Schwacher NFC-Empfang. Bitte +- ändern Sie die Position des Ausweises +- entfernen Sie Handyhüllen o.Ä. +- verbinden Sie das Smartphone mit dem Ladegerät @@ -440,18 +463,18 @@ LABEL ANDROID IOS PIN ändern - Please wait a moment... + Please don't move the ID card... INFO DESKTOP_QML Processing screen text while the card communication is running after the PIN has been entered during PIN change process. ---------- INFO ANDROID IOS Loading screen during PIN change process, data communcation is currently ongoing. Message is usually not visible since the password handling with basic reader is handled by EnterPasswordView. ---------- INFO ANDROID IOS Generic progress message during PIN change process. - Bitte warten Sie einen Moment... + Bitte den Ausweis nicht bewegen... - The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function. + The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function. INFO ANDROID IOS The card communcation was aborted, the online identification functionality is deactivated and needs to be actived by the authorities. - Die Online-Ausweisfunktion Ihres Ausweisdokumentes ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. + Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihren Ausweis ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. Please observe the display of your card reader. @@ -459,19 +482,14 @@ INFO ANDROID IOS Generic progress message during PIN change process.Bitte beachten Sie die Anzeige Ihres Kartenlesers. - You have entered the wrong PIN twice. Prior to a third attempt, you have to enter your six-digit card access number first. You can find your card access number on the front of your ID card. + A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card. INFO ANDROID IOS The wrong PIN was entered twice, the next attempt requires additional verifcation via CAN. - Sie haben Ihre PIN zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher Ihre 6-stellige Zugangsnummer eingeben. Sie finden Ihre Zugangsnummer auf der Vorderseite Ihres Ausweises. + Die PIN Ihres Ausweises wurde zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher die sechsstellige Zugangsnummer (CAN) eingeben. Diese finden Sie auf der Vorderseite Ihres Ausweises. - You have entered a wrong PIN three times. Your PIN is now blocked. You have to enter the PUK now for unblocking. - INFO ANDROID IOS The PIN (including the CAN) was entered wrongfully three times, the PUK is required to unlock the id card. - Sie haben Ihre PIN dreimal falsch eingegeben. Ihre PIN ist jetzt gesperrt. Zum Entsperren geben Sie bitte Ihre PUK ein. - - - Weak NFC signal. Please reposition your card. - INFO ANDROID IOS The NFC signal is weak or unstable, the user is asked to change the card's position to (hopefully) reduce the distance to the NFC chip. - Schwacher NFC-Empfang. Bitte korrigieren Sie die Position Ihres Ausweisdokuments. + A wrong PIN has been entered three times on your ID card. Your PIN is now blocked. To unblock your PIN you have to enter the PUK. + INFO ANDROID IOS The PIN (including the CAN) was entered wrongfully three times, the PUK is required to unlock the ID card. + Die PIN Ihres Ausweises wurde dreimal falsch eingegeben. Ihre PIN ist gesperrt. Zum Entsperren geben Sie bitte Ihre PUK ein. Retry @@ -479,18 +497,24 @@ INFO ANDROID IOS Generic progress message during PIN change process.Erneut versuchen - Weak NFC signal. -Please reposition your card. - INFO DESKTOP_QML The NFC signal is weak or unstable, the user is asked to change the card's position to (hopefully) reduce the distance to the NFC chip. - Schwacher NFC-Empfang. -Bitte korrigieren Sie die Position Ihres Ausweises. + Weak NFC signal. Please +- change the card position +- remove the mobile phone case (if present) +- connect the smartphone with a charging cable + INFO DESKTOP_QML The NFC signal is weak or unstable, the user is asked to change the card's position to (hopefully) reduce the distance to the NFC chip. +---------- +INFO ANDROID IOS The NFC signal is weak or unstable, the user is asked to change the card's position to (hopefully) reduce the distance to the NFC chip. + Schwacher NFC-Empfang. Bitte +- ändern Sie die Position des Ausweises +- entfernen Sie Handyhüllen o.Ä. +- verbinden Sie das Smartphone mit dem Ladegerät Your ID card is unblocked. You now have three more tries to change your PIN INFO DESKTOP_QML The ID card has just been unblocked and the user can now continue with their PIN change. ---------- INFO ANDROID IOS The ID card has just been unblocked and the user can now continue with their PIN change. - Ihr Ausweisdokument wurde entsperrt. Sie haben nun drei weitere Versuche um Ihre PIN zu ändern + Ihr Ausweis wurde entsperrt. Sie haben nun drei weitere Versuche um Ihre PIN zu ändern @@ -503,7 +527,7 @@ INFO ANDROID IOS The ID card has just been unblocked and the user can now contin You have the opportunity to change your transport PIN into a personal PIN. You can also change the PIN at any time or unblock the PIN using the personal unblocking key (PUK). The transport PIN and the PUK can be found in the letter sent to you by your competent authority. LABEL ANDROID IOS - Hier haben Sie die Möglichkeit, Ihre Transport-PIN in eine persönliche PIN zu ändern. Zudem können Sie jederzeit Ihre persönliche PIN ändern oder eine Blockierung mit Hilfe der Entsperrnummer (PUK) aufheben. Sie finden Ihre Transport-PIN und die PUK in dem Schreiben, das Sie nach Beantragung Ihres Ausweisdokuments von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde erhalten haben. + Hier haben Sie die Möglichkeit, Ihre Transport-PIN in eine persönliche PIN zu ändern. Zudem können Sie jederzeit Ihre persönliche PIN ändern oder eine Blockierung mit Hilfe der Entsperrnummer (PUK) aufheben. Sie finden Ihre Transport-PIN und die PUK in dem Schreiben, das Sie nach Beantragung Ihres Ausweises von der für die Ausgabe Ihres Ausweises zuständigen Behörde erhalten haben. Change PIN now @@ -558,11 +582,50 @@ LABEL IOS_TABLET nicht ausgewählt + + DebugSettings + + Create dummy entries + LABEL DESKTOP_QML + Erstelle Scheindaten + + + Logfile + LABEL DESKTOP_QML + Protokolldatei + + + History + LABEL DESKTOP_QML + Verlauf + + + Show beta testing image + LABEL DESKTOP_QML + Zeige Beta-Test-Symbol + + + + DetachedLogView + + Select logfile: + Wähle Protokolldatei aus: + + + Font size: + Schriftgröße: + + + Save logfile + LABEL DESKTOP_QML + Protokolldatei speichern + + DetailDialog - Service provider data - Angaben zum Diensteanbieter + Provider data + Angaben zum Anbieter close dialog @@ -588,9 +651,9 @@ LABEL IOS_TABLET Entwickleroptionen - Test PKI + Testmode for the self-authentication LABEL DESKTOP_QML - Test-PKI + Testmodus für die Selbstauskunft Developer mode @@ -599,7 +662,7 @@ LABEL IOS_TABLET The developer mode is aimed at integrators / developers for new service applications. For this reason, the developer mode works only in the test PKI. By activating the developer mode, some safety tests are deactivated. This means that the authentication process continues although the AusweisApp2 would usually abort the process with an error message when used in normal operation mode. Information on the disregarded error in the developer mode is displayed in the attached window below the AusweisApp2. - LABEL DESKTOP_QML Only visible when the user activates the developer mode in the settings. + LABEL DESKTOP_QML Der Entwicklermodus richtet sich an Integratoren / Entwickler für neue Dienste. Aus diesem Grund funktioniert der Entwicklermodus lediglich in der Test-PKI. Durch Aktivierung des Entwicklermodus werden einige Sicherheitsprüfungen abgestellt. Die Authentisierung wird auch dann weitergeführt, wenn die AusweisApp2 im Normalbetrieb die Authentisierung mit einer Fehlermeldung abbrechen würde. Der übergangene Fehler im Entwicklermodus wird im angehängten Fenster unterhalb der AusweisApp2 angezeigt. @@ -610,8 +673,12 @@ LABEL IOS_TABLET verwenden - Self-authentication test URI: - Test URI für die Selbstauskunft: + Testmode for the self-authentication: + Testmodus für die Selbstauskunft: + + + Developer mode: + Entwicklermodus: @@ -622,18 +689,18 @@ LABEL IOS_TABLET Entwickleroptionen - Test environment - LABEL ALL_PLATFORMS - Testumgebung + Testmode for the self-authentication + LABEL ANDROID IOS + Testmodus für die Selbstauskunft Developer Mode - LABEL ALL_PLATFORMS + LABEL ANDROID IOS Entwicklermodus Use a more tolerant mode - LABEL ALL_PLATFORMS + LABEL ANDROID IOS Benutze einen toleranten Modus @@ -658,12 +725,30 @@ LABEL IOS_TABLET Use the test environment during a self-authentication - LABEL ALL_PLATFORMS + LABEL ANDROID IOS Benutze die Test-Umgebung während der Selbstauskunft - Developer mode - Entwicklermodus + Create dummy entries + LABEL ALL_PLATFORMS + Erstelle Scheindaten + + + Logfile + LABEL ALL_PLATFORMS + Protokolldatei + + + History + LABEL ALL_PLATFORMS + Verlauf + + + + DevicesListDelegate + + Device %1 + Gerät %1 @@ -709,17 +794,15 @@ LABEL IOS_TABLET EditRights - You are about to identify yourself towards the following service provider: - LABEL DESKTOP_QML ----------- -LABEL ANDROID_PHONE + You are about to identify yourself towards the following provider: + LABEL ANDROID_PHONE ---------- LABEL ANDROID_TABLET ---------- LABEL IOS_PHONE ---------- LABEL IOS_TABLET - Sie möchten sich bei folgendem Diensteanbieter ausweisen: + Sie möchten sich bei folgendem Anbieter ausweisen: Purpose for reading out requested data @@ -735,17 +818,15 @@ LABEL IOS_TABLET Zweck des Auslesevorgangs - Service provider - LABEL DESKTOP_QML ----------- -LABEL ANDROID_PHONE + Provider + LABEL ANDROID_PHONE ---------- LABEL ANDROID_TABLET ---------- LABEL IOS_PHONE ---------- LABEL IOS_TABLET - Diensteanbieter + Anbieter more... @@ -753,7 +834,7 @@ LABEL IOS_TABLET mehr... - The following data will be transferred to the service provider when you enter the PIN: + The following data will be transferred to the provider when you enter the PIN: LABEL DESKTOP_QML ---------- LABEL ANDROID_PHONE @@ -763,7 +844,7 @@ LABEL ANDROID_TABLET LABEL IOS_PHONE ---------- LABEL IOS_TABLET - Folgende Daten Ihres Ausweises werden nach Eingabe der PIN ausgelesen und an den Diensteanbieter übermittelt: + Folgende Daten Ihres Ausweises werden nach Eingabe der PIN ausgelesen und an den Anbieter übermittelt: Transactional information @@ -824,29 +905,60 @@ LABEL IOS_TABLET Dies ist die Anzeige zum Ändern der Berechtigungen der AusweisApp2. - Click for more information about the service provider - Klicke hier für mehr Informationen zum Diensteanbieter + Click for more information about the provider + Klicke hier für mehr Informationen zum Anbieter Proceed to %1 entry - LABEL DESKTOP_QML %1 can be CAN or PIN + LABEL DESKTOP_QML %1 can be "card access number (CAN)" or "PIN" ---------- -LABEL ANDROID_PHONE %1 can be CAN or PIN +LABEL ANDROID_PHONE %1 can be "card access number (CAN)" or "PIN" ---------- -LABEL ANDROID_TABLET %1 can be CAN or PIN +LABEL ANDROID_TABLET %1 can be "card access number (CAN)" or "PIN" ---------- -LABEL IOS_PHONE %1 can be CAN or PIN +LABEL IOS_PHONE %1 can be "card access number (CAN)" or "PIN" ---------- -LABEL IOS_TABLET %1 can be CAN or PIN +LABEL IOS_TABLET %1 can be "card access number (CAN)" or "PIN" Weiter zur %1-Eingabe + + You are about to identify yourself towards the following provider + LABEL DESKTOP_QML + Sie möchten sich bei folgendem Anbieter ausweisen + + + Show more information about the service provider + Zeige mehr Informationen über den Anbieter + + + card access number (CAN) + LABEL DESKTOP_QML Inserted into "Proceed to %1 entry" +---------- +LABEL ANDROID_PHONE Inserted into "Proceed to %1 entry" +---------- +LABEL ANDROID_TABLET Inserted into "Proceed to %1 entry" +---------- +LABEL IOS_PHONE Inserted into "Proceed to %1 entry" +---------- +LABEL IOS_TABLET Inserted into "Proceed to %1 entry" + Zugangsnummer (CAN) + + + PIN + LABEL DESKTOP_QML Inserted into "Proceed to %1 entry" +---------- +LABEL ANDROID_PHONE Inserted into "Proceed to %1 entry" +---------- +LABEL ANDROID_TABLET Inserted into "Proceed to %1 entry" +---------- +LABEL IOS_PHONE Inserted into "Proceed to %1 entry" +---------- +LABEL IOS_TABLET Inserted into "Proceed to %1 entry" + PIN + EnterPasswordView - - Enter %1 view. You can start to enter the number. - Anzeige der %1-Eingabe. Sie können nun Ihre Ziffern eingeben. - This is the enter password view of the AusweisApp2. Dies ist die Anzeige der Passworteingabe der AusweisApp2. @@ -862,56 +974,52 @@ LABEL IOS_TABLET %1 can be CAN or PIN Verbleibende Versuche: %1 - %1-Entry - LABEL DESKTOP_QML %1 can be "PIN, CAN, PUK or UNKNOWN" - %1-Eingabe - - - The entered PIN does not match the new PIN. Please correct your input. + The new PIN and the confirmation do not match. Please correct your input. INFO DESKTOP_QML The changed PIN was entered wrongfully during the confirmation process. ---------- INFO ANDROID IOS The changed PIN was entered wrongfully during confirmation. - Die eingegebene PIN stimmt nicht mit Ihrer neuen PIN überein. Bitte korrigieren Sie Ihre PIN-Eingabe. + Die neue PIN und ihre Wiederholung stimmen nicht überein. Bitte korrigieren Sie Ihre Eingabe. Please enter your 6-digit PIN. Use the keyboard or numpad. - INFO DESKTOP_QML The AA2 expects a PIN with 6 digit which can be entered via the physical or onscreen keyboard. - Bitte geben Sie Ihre 6-stellige PIN ein. Benutzen Sie dazu die Tastatur oder den Ziffernblock. + INFO DESKTOP_QML The AA2 expects a PIN with 6 digits which can be entered via the physical or onscreen keyboard. + Bitte geben Sie Ihre sechsstellige PIN ein. Benutzen Sie dazu die Tastatur oder die Bildschirmtastatur. More information + INFO DESKTOP_QML Link text Mehr Informationen - Please enter the 6-digit CAN you can find on the front of your ID card. - INFO DESKTOP_QML The user is required to enter the 6 digit CAN. - Bitte geben Sie Ihre 6-stellige CAN ein. Diese befindet sich auf der Vorderseite Ihres Ausweises. + Please enter the 6-digit card access number (CAN). + INFO DESKTOP_QML The operator is required to enter the 6-digit CAN in CAN-allowed authentication. + Bitte geben Sie Ihre sechsstellige Zugangsnummer (CAN) ein. - You have entered the wrong PIN twice. Prior to a third attempt, you have to enter your six-digit card access number first. You can find your card access number on the front of your ID card. + A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card. INFO DESKTOP_QML The PIN was entered wrongfully twice, this may have happened during an earlier session of the AA2, too. The user needs to enter the CAN for additional verification. ---------- INFO ANDROID IOS The wrong PIN was entered twice, the third attempt requires the CAN for additional verification, hint where the CAN is found. - Sie haben Ihre PIN zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher Ihre 6-stellige Zugangsnummer eingeben. Sie finden Ihre Zugangsnummer auf der Vorderseite Ihres Ausweises. + Die PIN Ihres Ausweises wurde zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher die sechsstellige Zugangsnummer (CAN) eingeben. Diese finden Sie auf der Vorderseite Ihres Ausweises. - The online identification function is blocked. Please use your personal unblocking key (PUK) to unblock your ID card. - INFO DESKTOP_QML The PUK is required to unlock the id card. - Die Online-Ausweisfunktion ist blockiert. Die Blockierung können Sie mit Ihrer Entsperrnummer (PUK) aufheben. + The PIN of your ID card is blocked after three incorrect tries. The block can be lifted by entering your personal unblocking key (PUK). + INFO DESKTOP_QML The PUK is required to unlock the ID card. + Die PIN Ihres Ausweises ist nach dreimaliger Fehleingabe gesperrt. Die Sperrung können Sie mit der Entsperrnummer (PUK) aufheben. - Please enter a new 6-digit PIN of your choice. + Please enter a new 6-digit PIN now. INFO DESKTOP_QML A new 6-digit PIN needs to be supplied. ---------- INFO ANDROID IOS A new 6-digit PIN needs to be supplied. - Geben Sie nun bitte eine neue 6-stellige PIN Ihrer Wahl ein. + Vergeben Sie bitte nun eine neue sechsstellige PIN. - Please enter your new 6-digit PIN again. + Please confirm your new 6-digit PIN. INFO DESKTOP_QML The new PIN needs to be entered again for verification. ---------- INFO ANDROID IOS The new PIN needs to be confirmed. - Wiederholen Sie bitte Ihre neue 6-stellige PIN. + Wiederholen Sie bitte Ihre neue sechsstellige PIN. Unknown password type: @@ -919,124 +1027,85 @@ INFO ANDROID IOS The new PIN needs to be confirmed. Unbekannter Passwort-Typ: - Your PIN has 6 digits? - LABEL DESKTOP_QML Button, mit dem der Benutzer eine TransportPIN-Änderung starten kann. + Does your PIN have 6 digits? + LABEL DESKTOP_QML Button to switch to a 6-digit PIN. ---------- -LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung starten kann. - Ist Ihre PIN 6-stellig? +LABEL ANDROID IOS Button to switch to a 6-digit PIN. + Ist Ihre PIN sechsstellig? - Your PIN has 5 digits? - Ist Ihre PIN 5-stellig? + Does your PIN have 5 digits? + LABEL DESKTOP_QML Button to switch to a transport PIN or start a change of the transport PIN. +---------- +LABEL ANDROID IOS Button to switch to a transport PIN or start a change of the transport PIN. + Ist Ihre PIN fünfstellig? - Please enter the six-digit card access number. You can find the card access number on the front of the ID card. + Please enter the 6-digit card access number (CAN). You can find it on the front of the ID card. INFO ANDROID IOS The CAN needs to be entered in CAN-allowed mode, hint where the CAN can be found. - Bitte geben Sie Ihre 6-stellige Zugangsnummer ein. Sie finden Ihre Zugangsnummer auf der Vorderseite Ihres Ausweises. + Bitte geben Sie die sechsstellige Zugangsnummer (CAN) ein. Diese finden Sie auf der Vorderseite des Ausweises. - You have entered a wrong PIN three times. Your PIN is now blocked. You have to enter the PUK now for unblocking. - INFO ANDROID IOS The PUK is required to unlock the id card since the wrong PIN entered three times. - Sie haben Ihre PIN dreimal falsch eingegeben. Ihre PIN ist jetzt gesperrt. Zum Entsperren geben Sie bitte Ihre PUK ein. + A wrong PIN has been entered three times on your ID card. Your PIN is now blocked. To unblock your PIN you have to enter the PUK. + INFO ANDROID IOS The PUK is required to unlock the ID card since the wrong PIN entered three times. + Die PIN Ihres Ausweises wurde dreimal falsch eingegeben. Ihre PIN ist gesperrt. Zum Entsperren geben Sie bitte Ihre PUK ein. - Please enter your transport PIN. + Please enter the transport PIN from your PIN letter. INFO ANDROID IOS The transport PIN is required by AA2, it needs to be change to an actual PIN. - Geben Sie bitte Ihre Transport-PIN ein. + Geben Sie bitte die Transport-PIN aus dem PIN-Brief ein. - Enter the pairing code shown on your other device to use it as a card reader. + Enter the pairing code shown on the device you want to pair. INFO ANDROID IOS The pairing code for the smartphone is required. - Geben Sie den Kopplungscode, der auf Ihrem anderen Gerät angezeigt wird, ein, um dieses als Kartenleser verwenden zu können. + Geben Sie den Kopplungscode ein, der auf dem zu koppelnden Smartphone angezeigt wird. Please enter your PIN. LABEL ANDROID IOS Geben Sie bitte Ihre PIN ein. - - Please start the remote service in order to use your smartphone as a card reader with AusweisApp2. - Bitte starten sie den Fernzugriff um Ihr Smartphone als Kartenleser in der AusweisApp2 zu nutzen. - Please enter your 5-digit Transport PIN. Use the keyboard or numpad. - INFO DESKTOP_QML The AA2 expects a PIN with 5 digit which can be entered via the physical or onscreen keyboard. - Bitte geben Sie Ihre 5-stellige Transport-PIN ein. Benutzen Sie dazu die Tastatur oder den Ziffernblock. - - - - Feedback - - Rate AusweisApp2 - LABEL ANDROID IOS - Bewerten Sie die AusweisApp2 - - - Help & Feedback - LABEL ANDROID IOS - Hilfe & Feedback - - - FAQ - LABEL ANDROID IOS - FAQ - - - Do you have questions how to use AusweisApp2? - LABEL ANDROID IOS - Haben Sie Fragen zur Nutzung der AusweisApp2? - - - Support - LABEL ANDROID IOS - Support - - - You need further help? - LABEL ANDROID IOS - Benötigen Sie weitere Hilfe? - - - Please rate us in the Google Play Store. - LABEL ANDROID IOS - Bewerten Sie die AusweisApp2. + INFO DESKTOP_QML The AA2 expects a PIN with 5 digits which can be entered via the physical or onscreen keyboard + Bitte geben Sie Ihre fünfstellige Transport-PIN ein. Benutzen Sie dazu die Tastatur oder den Ziffernblock. - Report error - LABEL ANDROID IOS - Melden Sie einen Fehler + %1. You can start to enter the number. + LABEL DESKTOP_QML %1 is the title, e.g. "PIN entry" + %1. Sie können nun Ihre Nummer eingeben. - You found a bug? Please tell us, so we can fix it. - LABEL ANDROID IOS - Sie haben einen Fehler gefunden? Teilen Sie ihn uns mit, damit wir ihn beheben können. + PIN entry + LABEL DESKTOP_QML + PIN-Eingabe - Show log - LABEL ANDROID IOS - Protokoll anzeigen + CAN entry + LABEL DESKTOP_QML + CAN-Eingabe - You can view the logs of the AusweisApp2 here. - LABEL ANDROID IOS - Hier können Sie das Protokoll der AusweisApp2 einsehen. + PUK entry + LABEL DESKTOP_QML + PUK-Eingabe - https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/ - LABEL ANDROID IOS - https://www.ausweisapp.bund.de/fragen-und-antworten/haeufig-gestellte-fragen/ + Pairing code + LABEL DESKTOP_QML + Kopplungscode - https://www.ausweisapp.bund.de/en/qa/support/ - LABEL ANDROID IOS - https://www.ausweisapp.bund.de/fragen-und-antworten/support/ + Start the pairing on your smartphone and enter the shown pairing code in order to use your smartphone as a card reader (SaC). + INFO DESKTOP_QML The pairing code needs to be supplied. + Starten Sie die Kopplung auf Ihrem Smartphone und geben Sie den angezeigten Kopplungscode ein um Ihr Smartphone als Kartenleser (SaK) zu verwenden. - GSwitch + GTextField - Switch - Wechseln + Maximum allowed length reached. + Maximal zulässige Länge erreicht. @@ -1087,6 +1156,20 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start LABEL DESKTOP_QML Nach Authentisierung schließen + + Use internal notifications + LABEL DESKTOP_QML + Interne Benachrichtigungen aktivieren + + + Using the developer mode forces the notifications to be enabled. + LABEL DESKTOP_QML Only visible when the user activates the developer mode in the settings. + Im Entwicklermodus werden die internen Benachrichtigungen erzwungen. + + + Please note that the old UI will be removed in the next version of %1! + Bitte beachten Sie, dass die alte grafische Nutzeroberfläche in der nächsten Version der %1 entfernt wird! + GeneralSettingsWidget @@ -1180,12 +1263,13 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start Identify + LABEL DESKTOP_QML Ausweisen - The device %1 was unpaired because it does not react to connection attempts. Retry the pairing process if you want to use this device to authenticate yourself. + The device %1 was unpaired because it did not react to connection attempts. Pair the device again to use it as a card reader. INFO DESKTOP_QML The paired devices was removed since it did not respond to connection attempts. It needs to be paired again if it should be used as card reader. - Das Gerät %1 wurde entkoppelt, da es nicht auf Verbindungsversuche reagiert hat. Versuchen Sie das Gerät erneut zu koppeln, wenn Sie es zur Authentisierung verwenden möchten. + Das Gerät %1 wurde entkoppelt, da es nicht auf Verbindungsversuche reagiert hat. Koppeln Sie das Gerät erneut, um es wieder als Kartenleser zu verwenden. Attempts @@ -1201,9 +1285,9 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start Schritt %1 von 3 - Establish connection + Searching for card reader LABEL DESKTOP_QML - Verbindung wird hergestellt + Suche nach Kartenleser Information @@ -1211,19 +1295,14 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start Information - Please insert the card into the device - INFO DESKTOP_QML The AA2 is waiting for an id card to be inserted into the card reader. - Bitte legen Sie die Karte auf den Kartenleser - - - Searching for card reader - INFO DESKTOP_QML AA2 is waiting for the card reader or the id card. - Suche nach Kartenleser + No card reader detected. Please make sure that a card reader is connected. Open the %1reader settings%2 to configure reader and get more information about supported readers. + INFO DESKTOP_QML AA2 is waiting for the card reader or the ID card. + Es wurde kein Kartenleser gefunden. Bitte stellen Sie sicher, dass ein Kartenleser angeschlossen ist. Öffnen Sie die %1Einstellungen%2 um Kartenleser zu konfigurieren und mehr Informationen zu unterstützten Kartenlesern zu erhalten. - The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function. + The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function. INFO DESKTOP_QML The online authentication feature of the card is disabled and needs to be activated by the authorities. - Die Online-Ausweisfunktion Ihres Ausweisdokumentes ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. + Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihren Ausweis ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. Please observe the display of your card reader. @@ -1231,20 +1310,25 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start Bitte beachten Sie die Anzeige Ihres Kartenlesers. - Please place the smartphone on the card + Connected to %1. Please place the NFC interface of the smartphone on your ID card. INFO DESKTOP_QML The AA2 is waiting for the smartphone to be placed on the id. - Bitte platzieren Sie das Smartphone auf der Karte + Verbunden mit %1. Bitte platzieren Sie das Smartphone mit der NFC-Schnittstelle auf Ihrem Ausweis. - Please place the smartphone on the card or insert the card into the device - INFO DESKTOP_QML The AA2 is waiting for an id card to be inserted into the card reader (or smartphone for that matter). - Bitte platzieren Sie das Smartphone auf der Karte oder legen Sie die Karte in den Kartenleser ein + Please place the smartphone (connected to %1) on your ID card or put the ID card on the card reader. + INFO DESKTOP_QML The AA2 is waiting for an ID card to be inserted into the card reader (or smartphone for that matter). + Bitte platzieren Sie das Smartphone (verbunden mit %1) auf Ihrem Ausweis oder legen den Ausweis auf den Kartenleser. The used card reader does not meet the technical requirements (Extended Length not supported). ERROR DESKTOP_QML Der verwendete Kartenleser erfüllt leider nicht die technischen Voraussetzungen (Extended Length wird nicht unterstützt). + + Please put the ID card on the card reader. + INFO DESKTOP_QML The AA2 is waiting for an ID card to be inserted into the card reader. + Bitte legen Sie den Ausweis auf das Kartenlesegerät. + Hamburger @@ -1297,6 +1381,11 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start INFO IOS Accessible name for the trash icon of a history entry. Lösche Verlaufseintrag: %1 + + Delete entry + LABEL ANDROID + Lösche Eintrag + HistoryRemovalTimePeriodControl @@ -1338,6 +1427,11 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start LABEL DESKTOP_QML Verlauf + + Search in history + LABEL DESKTOP_QML + Im Verlauf suchen + Currently there are no history entries. INFO DESKTOP_QML No authentication history, placeholder text. @@ -1362,25 +1456,20 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start Verlauf löschen? - Please confirm that you want to delete your history entries. + All history entries will be deleted. INFO DESKTOP_QML Content of the confirmation dialog to clear the entire authentication history. - Bitte bestätigen Sie das Löschen der Verlaufseinträge. + Alle im Verlauf gespeicherten Informationen werden gelöscht. - Removed %1 entries from the history. + Deleted %1 entries from the history. INFO DESKTOP_QML Feedback how many history entries were removed. - Es wurden %1 Einträge aus dem Verlauf entfernt. + Es wurden %1 Einträge aus dem Verlauf gelöscht. Clear history LABEL DESKTOP_QML Lösche Verlauf - - Save to pdf - LABEL DESKTOP_QML - Speichern als PDF - today heute @@ -1397,6 +1486,11 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start dd.MM.yyyy dd.MM.yyyy + + Save as PDF... + LABEL DESKTOP_QML + Als PDF speichern... + HistoryViewConfirmationPopup @@ -1411,9 +1505,9 @@ LABEL ANDROID IOS Button, mit dem der Benutzer eine TransportPIN-Änderung start Löschen - Please confirm that you want to delete your complete history. + All history entries will be deleted. LABEL ANDROID IOS Confirmaton popup to clear all history entries. - Bitte bestätigen Sie, dass der komplette Verlauf gelöscht werden soll. + Alle im Verlauf gespeicherten Informationen werden gelöscht. @@ -1449,11 +1543,11 @@ LABEL ANDROID IOS dd.MM.yyyy - Requested data + Submitted data LABEL DESKTOP_QML ---------- LABEL ANDROID IOS - Angeforderte Daten + Übermittelte Daten Terms of usage @@ -1470,20 +1564,16 @@ LABEL ANDROID IOS HistoryViewTitleBarControls - History enabled - LABEL ANDROID IOS - Verlauf aktiviert - - - History disabled - Verlauf deaktiviert + Delete all entries + LABEL ANDROID + Lösche alle Einträge HistoryWidget - This page displays the history of your successful authentications. Double-click on a service provider for more information. You can delete parts or the entire history. You can also save the history as a PDF file. - Auf dieser Seite sehen Sie den Verlauf Ihrer erfolgreichen Authentisierungen. Mit einem Doppelklick erhalten Sie weitere Informationen zum ausgewählten Diensteanbieter. Es ist darüber hinaus auch möglich, den Verlauf zu speichern. + This page displays the history of your successful authentications. Double-click on a provider for more information. You can delete parts or the entire history. You can also save the history as a PDF file. + Auf dieser Seite sehen Sie den Verlauf Ihrer erfolgreichen Authentisierungen. Mit einem Doppelklick erhalten Sie weitere Informationen zum ausgewählten Anbieter. Es ist darüber hinaus auch möglich, den Verlauf zu speichern. No matching history entries were found. Please modify your search criteria. @@ -1530,15 +1620,26 @@ LABEL ANDROID IOS IdentifyController You may now remove your ID card from the device. - INFO DESKTOP_QML The authentication process is completed, the id card may be removed from the card reader. + INFO DESKTOP_QML The authentication process is completed, the ID card may be removed from the card reader. ---------- -INFO ANDROID IOS The authentication process is completed, the id card may (and should) be removed from the card reader. - Sie können nun Ihr Ausweisdokument vom Gerät entfernen. +INFO ANDROID IOS The authentication process is completed, the ID card may (and should) be removed from the card reader. + Sie können nun Ihren Ausweis vom Gerät entfernen. + + + Process finished successfully. You may now remove your ID card from the device. + INFO DESKTOP_QML The authentication process finished successfully, the ID card may be removed from the card reader. + Der Vorgang war erfolgreich. Sie können nun Ihren Ausweis vom Gerät entfernen. - Weak NFC signal + Weak NFC signal. Please +- change the card position +- remove the mobile phone case (if present) +- connect the smartphone with a charging cable INFO IOS The NFC signal is weak or unstable. The scan is stopped with this information in the iOS dialog. - Schwacher NFC-Empfang + Schwacher NFC-Empfang. Bitte +- ändern Sie die Position des Ausweises +- entfernen Sie Handyhüllen o.Ä. +- verbinden Sie das Smartphone mit dem Ladegerät @@ -1555,59 +1656,51 @@ LABEL ANDROID IOS INFO DESKTOP_QML Header of the progress information during the authentication process. ---------- INFO ANDROID IOS Header of the progress status message during the authentication process. - Authentisierung wird durchgeführt + Ausweisvorgang wird durchgeführt Acquiring provider certificate - INFO ANDROID IOS Header of the progress status message during the authentication process. - Lade Berechtigungszertifikat herunter + INFO DESKTOP_QML Header of the progress information during the authentication process. +---------- +INFO ANDROID IOS Header of the progress status message during the authentication process. + Berechtigungszertifikat wird heruntergeladen Please wait a moment... - INFO DESKTOP_QML Second line text if a basic card reader is used and data is exchanged with the card/server in the background. Is not actually visible since the basic reader password handling is done by EnterPasswordView. + INFO DESKTOP_QML Information message about cancellation process with present network connectivity ---------- -INFO DESKTOP_QML Generic progress status message during authentication. +INFO DESKTOP_QML Generic progress status message while no card communication is active. ---------- -INFO ANDROID IOS Second line text if a basic card reader is used and background communication with the card/server is running. Is not actually visible since the basic reader password handling is done by EnterPasswordView. +INFO DESKTOP_QML Generic progress status message during authentication. ---------- INFO ANDROID IOS Generic status message during the authentication process. Bitte warten Sie einen Moment... - The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function. - INFO DESKTOP_QML The online authentication feature of the id card is deactivated and needs to be activated by the local authorities. + The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function. + INFO DESKTOP_QML The online authentication feature of the ID card is deactivated and needs to be activated by the local authorities. ---------- -INFO ANDROID IOS The online authentication feature of the id card is disabled and needs to be actived the be authorities. - Die Online-Ausweisfunktion Ihres Ausweisdokumentes ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. +INFO ANDROID IOS The online authentication feature of the ID card is disabled and needs to be actived the be authorities. + Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihren Ausweis ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. Please observe the display of your card reader. INFO ANDROID IOS The card reader requests the user's attention. Bitte beachten Sie die Anzeige Ihres Kartenlesers. - - You have entered the wrong PIN twice. Prior to a third attempt, you have to enter your six-digit card access number first. You can find your card access number on the front of your ID card. - INFO ANDROID IOS The PIN was entered wrongfully two times, the third attempts requires additional CAN verification, hint where the CAN is found. - Sie haben Ihre PIN zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher Ihre 6-stellige Zugangsnummer eingeben. Sie finden Ihre Zugangsnummer auf der Vorderseite Ihres Ausweises. - No network connectivity INFO DESKTOP_QML Header of the message that no network connection is present during the authentication procedure. ---------- LABEL ANDROID IOS - Keine Netzwerkverbindung + Keine Verbindung möglich - Please enable the network interface or cancel the workflow. + Please establish an internet connection. INFO DESKTOP_QML Content of the message that no network connection is present during the authentication procedure. ---------- INFO ANDROID IOS No network connection, the user needs to active the network interface or abort the procedure. - Bitte stellen Sie eine Internetverbindung her oder beenden Sie den Vorgang. - - - Weak NFC signal. Please reposition your card. - INFO ANDROID IOS The NFC signal is weak, by repositioning the card the signal might improve. - Schwacher NFC-Empfang. Bitte korrigieren Sie die Position Ihres Ausweises. + Bitte stellen Sie eine Internetverbindung her. Change transport PIN @@ -1629,187 +1722,95 @@ INFO ANDROID IOS No network connection, the user needs to active the network int LABEL ANDROID IOS Beende Ausweisvorgang - - You have to change your transport PIN into a personal PIN to use the online ID function. You are currently leaving the started process and are forwarded to the PIN management. Please restart the desired process after the PIN has been changed. - INFO DESKTOP_QML The user clicked that the current PIN has 5 digits (transport PIN) which needs to be changed to a 6-digit PIN. The current process will be aborted and needs to be restarted *manually* by the user. ----------- -INFO ANDROID IOS The user clicked that the current PIN has 5 digits (transport PIN), it needs to be changed to an ordinary 6 digit PIN. The current process needs to be restarted *manually* by the user. - Sie müssen Ihre fünfstellige Transport-PIN zunächst in eine persönliche PIN ändern. Sie sind dabei den aktuell laufenden Vorgang zu verlassen und zur PIN-Verwaltung weitergeleitet zu werden. Starten Sie den gewünschten Vorgang bitte nach der PIN-Änderung erneut. - Transport PIN LABEL DESKTOP_QML Transport PIN - Weak NFC signal. -Please reposition your card. - INFO DESKTOP_QML A weak NFC signal was detected since the card communication was aborted. The card's position needs to be adjusted to hopefully achieve better signal strength. - Schwacher NFC-Empfang. -Bitte korrigieren Sie die Position Ihres Ausweises. + Weak NFC signal. Please +- change the card position +- remove the mobile phone case (if present) +- connect the smartphone with a charging cable + INFO DESKTOP_QML A weak NFC signal was detected since the card communication was aborted. The card's position needs to be adjusted to hopefully achieve better signal strength. +---------- +INFO ANDROID IOS The NFC signal is weak, by repositioning the card the signal might improve. + Schwacher NFC-Empfang. Bitte +- ändern Sie die Position des Ausweises +- entfernen Sie Handyhüllen o.Ä. +- verbinden Sie das Smartphone mit dem Ladegerät - - - InformationView - Help section - Hilfe - - - This is the help section of the AusweisApp2. - Dies ist die Hilfe der AusweisApp2. + Did you change the transport PIN already? + Haben Sie Ihre Transport-PIN bereits geändert? - Help - LABEL DESKTOP_QML - Hilfe - - - Questions, feedback, and rating - LABEL DESKTOP_QML - Fragen, Rückmeldungen und Bewertungen - - - Questions - LABEL DESKTOP_QML - Fragen - - - https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/ - https://www.ausweisapp.bund.de/fragen-und-antworten/haeufig-gestellte-fragen/ - - - Report error - LABEL DESKTOP_QML - Melden Sie einen Fehler - - - https://www.ausweisapp.bund.de/en/qa/report-an-error/ - https://www.ausweisapp.bund.de/feedback/melden-sie-einen-fehler/ - - - Rate application - LABEL DESKTOP_QML - Anwendung bewerten + Prior to the first use of the online identification function you have to replace the transport PIN by an individual 6-digit PIN. Online identification with transport PIN is not possible. + Vor der ersten Nutzung der Online-Ausweisfunktion müssen Sie die Transport-PIN durch eine persönliche sechsstellige PIN ersetzen. Die Online-Indentifikation ist mit der Transport-PIN nicht möglich. - https://www.ausweisapp.bund.de/en/qa/evaluate-us/ - https://www.ausweisapp.bund.de/feedback/bewerten-sie-uns/ - - - Setup and manual - LABEL DESKTOP_QML - Einrichtung und Handbuch - - - Setup - LABEL DESKTOP_QML - Einrichtung - - - Online help - LABEL DESKTOP_QML - Online-Hilfe - - - Diagnosis and application log - LABEL DESKTOP_QML - Diagnose- und Anwendungsprotokoll - - - Diagnosis - LABEL DESKTOP_QML - Diagnose - - - Application log - LABEL DESKTOP_QML - Anwendungsprotokoll + No, change transport PIN now + Nein, PIN jetzt ändern - Version and license information - LABEL DESKTOP_QML - Version und Lizenzinformationen + A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card. + INFO ANDROID IOS The PIN was entered wrongfully two times, the third attempts requires additional CAN verification, hint where the CAN is found. + Die PIN Ihres Ausweises wurde zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher die sechsstellige Zugangsnummer (CAN) eingeben. Diese finden Sie auf der Vorderseite Ihres Ausweises. - Version information - LABEL DESKTOP_QML + First you have to change your 5-digit transport PIN you received in your in PIN letter into a 6-digit PIN. You are currently leaving the started process and are forwarded to the PIN management. Please restart the desired process after the PIN has been changed. + INFO DESKTOP_QML The user clicked that the current PIN has 5 digits (transport PIN) which needs to be changed to a 6-digit PIN. The current process will be aborted and needs to be restarted *manually* by the user. ---------- -LABEL ANDROID IOS - Versionsinformationen - - - Software licenses - LABEL DESKTOP_QML - Softwarelizenzen - - - https://www.ausweisapp.bund.de/en/download/windows-and-mac/ - LABEL ANDROID IOS - https://www.ausweisapp.bund.de/download/windows-und-mac/ - - - Information - LABEL ANDROID IOS - Information - - - Here you can see detailed information about AusweisApp2. - LABEL ANDROID IOS - Hier finden Sie detaillierte Informationen zur AusweisApp2. - - - Software license - LABEL ANDROID IOS - Softwarelizenz +INFO ANDROID IOS The user clicked that the current PIN has 5 digits (transport PIN), it needs to be changed to an ordinary 6-digit PIN. The current process needs to be restarted *manually* by the user. + Sie müssen die fünfstellige Transport-PIN aus dem PIN-Brief zunächst in eine sechsstellige PIN ändern. Sie verlassen den laufenden Vorgang und werden zur PIN-Verwaltung weitergeleitet. Starten Sie den gewünschten Vorgang bitte nach der PIN-Änderung erneut. - Read the software license text on the application homepage. - LABEL ANDROID IOS - Lesen Sie die Softwarelizenz auf der Internetseite der Anwendung. + Please don't move the ID card... + INFO DESKTOP_QML Second line text if a basic card reader is used and data is exchanged with the card/server in the background. Is not actually visible since the basic reader password handling is done by EnterPasswordView. +---------- +INFO ANDROID IOS Second line text if a basic card reader is used and background communication with the card/server is running. Is not actually visible since the basic reader password handling is done by EnterPasswordView. + Bitte den Ausweis nicht bewegen... - https://www.ausweisapp.bund.de/en/download/android/ - LABEL ANDROID IOS - https://www.ausweisapp.bund.de/download/android/ + Aborting process and informing the service provider + INFO DESKTOP_QML The user aborted the authentication process, according to TR we need to inform the service provider + Der Vorgang wird beendet und der Anbieter informiert - https://www.ausweisapp.bund.de/en/download/ios/ - LABEL ANDROID IOS - https://www.ausweisapp.bund.de/download/ios/ + Network problemes detected, trying to reach server within 30 seconds. + INFO DESKTOP_QML Information message about cancellation process without working network connectivity + Es wurden Netzwerkprobleme erkannt. Die Verbindung wird weiterhin für 30 Sekunden versucht. - KnownDevicesListDelegate + LanguageSelectionPopup - Last connection: + Select language LABEL ANDROID IOS - Letzte Verbindung: + Sprache auswählen - Not available - LABEL ANDROID IOS - Nicht verfügbar + German + Deutsch - Great quality - LABEL ANDROID IOS - Gute Qualität + Set language to german + Verwende deutsche Sprache - Bad quality - Schlechte Qualität + English + Englisch - Device %1 has status %2 - Gerät %1 hat den Status %2 + Set language to english + Verwende englische Sprache LogFilesDialog - Log files - Protokolle + Logfiles + Protokolldateien File: @@ -1880,18 +1881,22 @@ LABEL ANDROID IOS Delete selected logfile + LABEL DESKTOP_QML Lösche ausgewählte Protokolldateien - Please confirm that you want to delete your old logfiles. - INFO DESKTOP_QML The current/all logfile(s) are about to be removed, user confirmation required. + All old logfiles will be deleted. + INFO DESKTOP_QML All logfiles are about to be removed, user confirmation required. ---------- -INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confirmation required. - Bitte bestätigen Sie, dass alle alten Protokolle gelöscht werden sollen. +INFO ANDROID IOS All logfiles are about to be removed, user confirmation required. + Alle alten Protokolle werden gelöscht. - Please confirm that you want to delete the logfile. - Bitte bestätigen Sie, dass das Protokoll gelöscht werden soll. + The logfile will be deleted. + INFO DESKTOP_QML The current logfile is about to be removed, user confirmation required. +---------- +INFO ANDROID IOS The current logfile is about to be removed, user confirmation required. + Das Protokoll wird gelöscht. Log @@ -1912,6 +1917,14 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Select logfile from list. Wähle Protokolldatei aus. + + The current logfile will be automatically deleted at exit. + Die aktuelle Protokolldatei wird beim Schließen automatisch gelöscht. + + + Detach log viewer + Protokoll separat anzeigen + MainView @@ -1934,7 +1947,7 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Verlauf - PIN management + PIN-Management LABEL DESKTOP_QML PIN-Verwaltung @@ -1949,7 +1962,7 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Hilfe - Self-authentication + Self-Authentication LABEL DESKTOP_QML Selbstauskunft @@ -1963,17 +1976,25 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Version information - LABEL ANDROID IOS DESKTOP_QML + LABEL DESKTOP_QML +---------- +LABEL ANDROID +---------- +LABEL ANDROID IOS DESKTOP_QML Versionsinformationen FAQ - LABEL ANDROID IOS DESKTOP_QML + LABEL ANDROID +---------- +LABEL ANDROID IOS DESKTOP_QML FAQ Support - LABEL ANDROID IOS DESKTOP_QML + LABEL ANDROID +---------- +LABEL ANDROID IOS DESKTOP_QML Support @@ -1983,7 +2004,9 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Software license - LABEL ANDROID IOS DESKTOP_QML + LABEL ANDROID +---------- +LABEL ANDROID IOS DESKTOP_QML Softwarelizenz @@ -2013,12 +2036,16 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Show log - LABEL ANDROID IOS DESKTOP_QML + LABEL ANDROID +---------- +LABEL ANDROID IOS DESKTOP_QML Protokoll anzeigen Tutorial - LABEL ANDROID IOS DESKTOP_QML + LABEL ANDROID +---------- +LABEL ANDROID IOS DESKTOP_QML Tutorial @@ -2032,30 +2059,274 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir https://www.ausweisapp.bund.de/fragen-und-antworten/support/ - Set language to german - Verwende deutsche Sprache + Report error + LABEL ANDROID +---------- +LABEL ANDROID IOS DESKTOP_QML + Melden Sie einen Fehler - Set language to english - Verwende englische Sprache + Help section + LABEL DESKTOP_QML + Hilfe - Report error + This is the help section of the AusweisApp2. + LABEL DESKTOP_QML + Dies ist die Hilfe der AusweisApp2. + + + Help + LABEL DESKTOP_QML + Hilfe + + + General + LABEL DESKTOP_QML + Allgemein + + + Diagnosis and log + LABEL DESKTOP_QML + Diagnose und Protokoll + + + Help & Feedback + LABEL ANDROID IOS + Hilfe & Feedback + + + Rate AusweisApp2 + LABEL ANDROID + Bewerten Sie die AusweisApp2 + + + Release notes + LABEL ANDROID +---------- +LABEL ANDROID IOS DESKTOP_QML + Release Notes + + + Settings LABEL ANDROID IOS DESKTOP_QML + Einstellungen + + + Do you want to know how to use %1? + LABEL ANDROID + Möchten Sie wissen, wie die %1 verwendet wird? + + + Do you have further questions about %1? + LABEL ANDROID + Haben Sie weitere Fragen zur %1? + + + Do you need further support? + LABEL ANDROID + Benötigen Sie weitergehende Unterstützung? + + + Do you want to rate us in the Google Play Store? + LABEL ANDROID + Möchten Sie uns im Google Play Store bewerten? + + + Do you want to view the release notes of %1? + LABEL ANDROID + Möchten Sie die Release Note der %1 sehen? + + + Did you find a bug? Please tell us, so we can fix it. + LABEL ANDROID + Haben Sie einen Fehler entdeckt? Bitte melden Sie sich bei uns, damit wir ihn beseitigen können. + + + Do you want to view the logs of %1? + LABEL ANDROID + Möchten Sie die Protokolldatei der %1 einsehen? + + + Do you want to see detailed information about %1? + LABEL ANDROID + Möchten Sie detaillierte Informationen über die %1 ansehen? + + + Do you want to read the software licenses? + LABEL ANDROID + Möchten Sie die Software-Lizenzen lesen? + + + + MoreViewDiagnosis + + Diagnosis + LABEL DESKTOP_QML + Diagnose + + + You can view and save the diagnosis information of the AusweisApp2 and your system here. + LABEL DESKTOP_QML + Sie können die Diagnose-Informationen der AusweisApp2 und Ihres System hier einsehen und speichern. + + + Show diagnosis + LABEL DESKTOP_QML + Zeige Diagnose + + + Application log + LABEL DESKTOP_QML + Anwendungsprotokoll + + + You can view the logs of the AusweisApp2 here. + LABEL DESKTOP_QML + Hier können Sie das Protokoll der AusweisApp2 einsehen. + + + Show logs + LABEL DESKTOP_QML + Zeige Protokoll + + + + MoreViewGeneral + + FAQ + LABEL DESKTOP_QML + FAQ + + + Open website + LABEL DESKTOP_QML + Öffne Webseite + + + https://www.ausweisapp.bund.de/en/qa/frequently-asked-questions/ + LABEL DESKTOP_QML + https://www.ausweisapp.bund.de/fragen-und-antworten/haeufig-gestellte-fragen/ + + + Support + LABEL DESKTOP_QML + Support + + + https://www.ausweisapp.bund.de/en/qa/support/ + LABEL DESKTOP_QML + https://www.ausweisapp.bund.de/fragen-und-antworten/support/ + + + Report error + LABEL DESKTOP_QML Melden Sie einen Fehler + + https://www.ausweisapp.bund.de/en/qa/report-an-error/ + LABEL DESKTOP_QML + https://www.ausweisapp.bund.de/fragen-und-antworten/melden-sie-einen-fehler/ + + + https://www.ausweisapp.bund.de/en/qa/evaluate-us/ + LABEL DESKTOP_QML + https://www.ausweisapp.bund.de/fragen-und-antworten/bewerten-sie-uns/ + + + Online help + LABEL DESKTOP_QML + Online-Hilfe + + + Help + LABEL DESKTOP_QML + Hilfe + + + Software licenses + LABEL DESKTOP_QML + Softwarelizenzen + + + https://www.ausweisapp.bund.de/en/download/windows-and-mac/ + LABEL DESKTOP_QML + https://www.ausweisapp.bund.de/download/windows-und-mac/ + + + Setup assistant + LABEL DESKTOP_QML + Einrichtungsassistent + + + Start setup assistant + LABEL DESKTOP_QML + Starte Einrichtungsassistenten + + + Do you have questions how to use %1? + LABEL DESKTOP_QML + Möchten Sie wissen, wie die %1 verwendet wird? + + + Do you need further help? + LABEL DESKTOP_QML + Benötigen Sie weitergehende Unterstützung? + + + Did you find a bug? Please tell us, so we can fix it. + LABEL DESKTOP_QML + Haben Sie einen Fehler entdeckt? Bitte melden Sie sich bei uns, damit wir ihn beseitigen können. + + + Rate %1 + LABEL DESKTOP_QML + %1 bewerten + + + Do you want to rate the %1? + LABEL DESKTOP_QML + Möchten Sie die %1 bewerten? + + + Do you want to read about the software licenses? + LABEL DESKTOP_QML + Möchten Sie die Softwarelizenzen lesen? + + + Do you want to run the setup assistant again? + LABEL DESKTOP_QML + Möchten Sie den Einrichtungsassistenten erneut durchführen? + + + Release notes + LABEL DESKTOP_QML + Release Notes + + + Do you want to read the release notes? + LABEL DESKTOP_QML + Möchten Sie die Release Notes lesen? + NavigationButton Continue - LABEL DESKTOP_QML Fortsetzen Back Zurück + + Yes + Ja + + + No + Nein + NavigationView @@ -2083,10 +2354,6 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Help & Feedback Hilfe & Feedback - - Information - Information - Smartphone as card reader Smartphone als Kartenleser @@ -2099,33 +2366,26 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir More Mehr - - Tutorial - Tutorial - PIN PIN - Set language to german - Verwende deutsche Sprache - - - Set language to english - Verwende englische Sprache + Settings + Einstellungen NfcWorkflow - NFC is not supported by your device. + Unfortunately, this functionality is not available on your device. INFO ANDROID IOS AA2 can't use NFC on this device, suggest to use bluetooth instead. - Ihr Gerät unterstützt kein NFC. + Diese Funktion steht auf Ihrem Gerät leider nicht zur Verfügung. - You require an additional 'Bluetooth card reader' or an additional 'smartphone as card reader' to use the online identification function with this device. - Sie können die Online-Ausweisfunktion aber mit einem separaten Bluetooth-Leser oder einem anderen Smartphone als Kartenleser nutzen. + However you can use a seperate 'Bluetooth card reader' or a seperate 'smartphone as card reader' to utilize the online identification function. + INFO ANDROID IOS AA2 can't use NFC on this device, suggest to use bluetooth instead. + Sie können die Online-Ausweisfunktion aber mit einen separaten Bluetooth-Leser oder einem anderen Smartphone als Kartenleser nutzen. NFC is switched off. @@ -2134,11 +2394,12 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Go to NFC settings - LABEL DESKTOP_QML + LABEL ANDROID IOS Zu den NFC Einstellungen Please enable NFC in your system settings. + INFO ANDROID IOS NFC is available but needs to be activated in the settings of the smartphone. Bitte aktivieren Sie NFC in Ihren Systemeinstellungen. @@ -2146,22 +2407,23 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Verbindung wird hergestellt - Your device does not meet the technical requirements (Extended Length not supported). You require an additional 'Bluetooth card reader' or an additional 'smartphone as card reader' to use the online identification function with this device. + Your device does not meet the technical requirements (Extended Length not supported). However you can use a seperate 'Bluetooth card reader' or a seperate 'smartphone as card reader' to utilize the online identification function. INFO ANDROID IOS The NFC interface does not meet the minimum requirements, using a bluetooth reader or a differnt smarthpone is suggested. - Ihr Gerät erfüllt leider nicht die technischen Voraussetzungen (Extended Length). Sie können die Online-Ausweisfunktion daher mit diesem Gerät nur über einen separaten Bluetooth-Leser oder mit einem separaten Smartphone als Kartenleser nutzen. + Ihr Gerät erfüllt leider nicht die technischen Voraussetzungen (Extended Length). Sie können die Online-Ausweisfunktion aber mit einen separaten Bluetooth-Leser oder einem anderen Smartphone als Kartenleser nutzen. - The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function. + The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function. INFO ANDROID IOS The online authentication feature is disabled and needs to be activated by the authorities. - Die Online-Ausweisfunktion Ihres Ausweisdokumentes ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. + Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihren Ausweis ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. Please place your device<br/>on your ID card. - INFO ANDROID IOS The id card may be inserted, the authentication process may be started. + INFO ANDROID IOS The ID card may be inserted, the authentication process may be started. Bitte platzieren Sie Ihr Gerät<br/>über Ihrem Personalausweis. Start NFC scan + LABEL ANDROID IOS NFC-Scan starten @@ -2171,15 +2433,40 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Please start the NFC scan. + INFO ANDROID IOS NFC is available but needs to be activated in the settings of the smartphone. Bitte starten Sie den NFC-Scan. - NumberPad + NumberField + + The password is visible. + LABEL DESKTOP_QML Screenreader text for the password field + Das Passwort ist sichtbar. + + + The password is hidden. + LABEL DESKTOP_QML Screenreader text for the password field + Das Passwort ist ausgeblendet. + + + You entered %1 of %2 digits. + LABEL DESKTOP_QML Screenreader text for the password field + Sie haben %1 von %2 Ziffern eingegeben. + + + Press to hide the password + LABEL DESKTOP_QML Screenreader text for the eye icon to change the password visibility + Drücken Sie die Taste um das Passwort auszublenden + - Numberpad to enter the password - Ziffernblock Passworteingabe + Press to show the password + LABEL DESKTOP_QML Screenreader text for the eye icon to change the password visibility + Drücken Sie die Taste um das Passwort einzublenden + + + NumberPad Delete last digit Lösche letzte Ziffer @@ -2189,6 +2476,13 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Absenden + + NumberPadButton + + Disabled + Deaktiviert + + PasswordInfoView @@ -2200,37 +2494,59 @@ INFO ANDROID IOS The current/all logfile(s) are about to be removed, user confir Dies ist die Informationsansicht zu Passwörtern der AusweisApp2. - %1 information - %1 can be "PIN, CAN, PUK or UNKNOWN" - Informationen zur %1 + The personal identification number (PIN) is chosen by you and is required for every use of the online eID function. You can change it anytime and indefinitely if you know your valid PIN. For your 6-digit PIN choose a combination of numbers, that is not easy to guess, neither "123456" nor your birth date, or any other numbers printed on the ID card. If you are no longer aware of your valid PIN, you will need to contact the authority responsible for issuing your identification card to renew your PIN.<br><br>When changing the PIN for the first time, please use your 5-digit transport PIN. You will find the transport PIN in the letter you received from the authority responsible for issuing your identification card (marked in red) after you have applied for your identity card.<br><br>Please note that you can not use the online eID function with your 5-digit transport PIN. A change to a 6-digit PIN is mandatory. + INFO DESKTOP_QML Description text of PIN + Die Geheimnummer (PIN) vergeben Sie selbst und benötigen Sie bei jeder Nutzung der Online-Ausweisfunktion. Sie können diese jederzeit und unbegrenzt oft ändern, solange Ihnen Ihre gültige PIN bekannt ist. Wählen Sie für Ihre sechsstellige PIN eine Zahlenkombination, die nicht leicht zu erraten ist, also weder "123456", noch Ihr Geburtsdatum oder andere Zahlen, die auf dem Ausweis aufgedruckt sind. Sollten Sie Ihre PIN vergessen haben, können Sie in der für die Ausgabe Ihres Ausweises zuständigen Behörde eine neue PIN setzen.<br><br>Zum erstmaligen Setzen Ihrer PIN verwenden Sie bitte die fünfstellige Transport-PIN. Sie finden diese in dem Schreiben, welches Sie nach Beantragung Ihres Ausweises von der zuständigen Behörde erhalten haben (rot markiert).<br><br>Bitte beachten Sie, dass die Online-Ausweisfunktion erst nach Änderung der fünfstelligen Transport-PIN in eine sechsstellige PIN genutzt werden kann. - The card access number (CAN) is only required if you have already entered the PIN incorrectly twice. In order to prevent a third incorrect entry and thus the blocking of the ID card without your consent, the CAN is also requested at this point. The CAN is a six-digit number that can be found on the front of the ID card. It is located at the bottom right next to the validity date (marked in red). - INFO DESKTOP_QML Description text of CAN - Die Zugangsnummer (CAN) wird nur dann verlangt, wenn Sie die PIN bereits zwei Mal falsch eingegeben haben. Um zu verhindern, dass ohne Ihre Zustimmung eine dritte Fehleingabe und somit die Sperrung des Ausweises erfolgen kann, wird an dieser Stelle zusätzlich die CAN abgefragt. Die CAN ist eine sechsstellige Zahl, die auf der Vorderseite des Personalausweises zu finden ist. Sie steht rechts unten neben dem Gültigkeitsdatum (rot markiert). + The card access number (CAN) is required if the PIN has already been entered incorrectly twice. In order to prevent a third incorrect entry and thus the blocking of the PIN without your consent, the CAN is also requested at this point. The CAN is a 6-digit number that can be found on the front of the ID card. It is located at the bottom right next to the validity date (marked in red). + INFO DESKTOP_QML Description text of CAN if required for third PIN attempt + Die Zugangsnummer (CAN) wird verlangt, wenn die PIN bereits zwei Mal falsch eingegeben wurde. Um zu verhindern, dass ohne Ihre Zustimmung eine dritte Fehleingabe und somit die Sperrung der PIN erfolgen kann, wird an dieser Stelle zusätzlich die CAN abgefragt. Die CAN ist eine sechsstellige Zahl, die auf der Vorderseite des Ausweises unten rechts zu finden ist (rot markiert). - The personal unblocking key (PUK) is only required if you entered the the wrong PIN three times. The online eID function is blocked at this time. The PUK is a ten-digit number you received with the letter sent to you by your competent authority (marked in red). Please note that you can only use the PUK to unblock the PIN entry. If you have forgotten your PIN, you can have a new PIN set at your competent authority. + The personal unblocking key (PUK) is required if the PIN has been entered three times. At this point the PIN is blocked. The PUK is a 10-digit number you received with the letter sent to you by your competent authority (marked in red). Please note that you can only use the PUK to unblock the PIN entry. If you have forgotten your PIN, you can have a new PIN set at your competent authority. INFO DESKTOP_QML Description text of PUK - Die Entsperrnummer (PUK) wird nur dann verlangt, wenn Sie die PIN bereits drei Mal falsch eingegeben haben. Zu diesem Zeitpunkt ist die Online-Ausweisfunktion gesperrt. Die PUK ist eine zehnstellige Zahl die Sie mit dem Schreiben bekommen haben, das Sie nach Beantragung Ihres Ausweisdokuments von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde erhalten haben (rot markiert). Bitte beachten Sie, dass Sie mit Ihrer PUK lediglich Ihre PIN-Eingabe entsperren können. Sollten Sie Ihre PIN vergessen haben, können Sie von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde eine neue PIN setzen lassen. + Die Entsperrnummer (PUK) wird verlangt, wenn die PIN drei Mal hintereinander falsch eingegeben wurde. Zu diesem Zeitpunkt ist die PIN gesperrt. Die PUK ist eine zehnstellige Zahl, die Sie mit dem Schreiben bekommen haben, welches Sie nach Beantragung Ihres Ausweises von der zuständigen Behörde erhalten haben (rot markiert). Bitte beachten Sie, dass Sie mit Ihrer PUK lediglich die PIN-Eingabe wieder entsperren können. Sollten Sie Ihre PIN vergessen haben, können Sie in der für die Ausgabe Ihres Ausweises zuständigen Behörde eine neue PIN setzen. - The personal identification number (PIN) is required for every use of the online eID function. You can change it anytime and indefinitely if you know your valid PIN. For your 6-digit PIN choose a combination of numbers, that is not easy to guess, neither "123456" nor your birth date, or any other numbers printed on the ID card. If you are no longer aware of your valid PIN, you will need to contact the authority responsible for issuing your identification document to renew your PIN. - -When changing the PIN for the first time, please use your 5-digit transport PIN. You will find the transport PIN in the letter you received from the authority responsible for issuing your identification document (marked in red) after you have applied for your identity card. - -Please note that you can not use the online eID function with your 5-digit transport PIN. A change to a 6-digit PIN is mandatory. - INFO DESKTOP_QML Description text of PIN - Die Geheimnummer (PIN) benötigen Sie bei jeder Nutzung der Online-Ausweisfunktion. Sie können diese jederzeit und unbegrenzt oft ändern, wenn Ihnen Ihre gültige PIN bekannt ist. Wählen Sie für Ihre 6-stellige PIN eine Zahlenkombination, die nicht leicht zu erraten ist, also weder "123456", noch Ihr Geburtsdatum oder andere Zahlen, die auf dem Ausweisdokument aufgedruckt sind. Soweit Ihnen Ihre gültige PIN nicht mehr bekannt ist, müssen Sie zur Neuvergabe einer persönlichen PIN die für die Ausgabe Ihres Ausweisdokuments zuständige Behörde aufsuchen. - -Bei der erstmaligen PIN-Änderung verwenden Sie bitte Ihre 5-stellige Transport-PIN. Sie finden die Transport-PIN in dem Schreiben, das Sie nach Beantragung Ihres Ausweisdokuments von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde erhalten haben (rot markiert). - -Bitte beachten Sie, dass Sie die Online-Ausweisfunktion mit Ihrer 5-stellige Transport-PIN nicht nutzen können. Eine Änderung in eine 6-stellige PIN ist zwingend erforderlich. + PIN/PUK on different pages + LABEL DESKTOP_QML + PIN/PUK auf unterschiedlichen Seiten + + + PIN/PUK on the same page + LABEL DESKTOP_QML + PIN/PUK auf der selben Seite + + + PIN information + LABEL DESKTOP_QML + PIN-Information + + + CAN information + LABEL DESKTOP_QML + CAN-Information + + + PUK information + LABEL DESKTOP_QML + PUK-Information + + + Smartphone as card reader information + LABEL DESKTOP_QML + Smartphone als Kartenleser-Information + + + The card access number (CAN) allows to access the imprinted data of the ID card. In order to allow on-site reading of the personal data the service provider needs to acquire governmental authorization to do so. On-site reading is usually employed to automatically fill forms and prevent spelling mistakes when transfering the personal data. + INFO DESKTOP_QML Description text of CAN-allowed authentication + Die Kartenzugriffsnummer (CAN) ermöglicht den Zugriff auf die auf dem Ausweis gespeicherten Daten. Um das Vor-Ort-Auslesen der persönlichen Daten zu Nutzen muss ein Diensteanbieter eine Zulassung durch eine staatliche Behörde erhalten. Die Vor-Ort-Auslesefunktion wird typischerweise zum automatischen Füllen von Formularen und insbesondere dem Verhindern von Fehlern beim Übertragen der persönlichen Daten eingesetzt. - You may use your smartphone as a card reader with AusweisApp2. The smartphone needs to feature a supported NFC chipset and both devices, your smartphone and this machine, need to be connected to the same WiFi network.<br><br>Please make sure that the remote service is running on your smartphone. Start the pairing process by clicking the "Start pairing" button and enter the shown 4-digit PIN. + You may use your smartphone as a card reader with AusweisApp2. The smartphone needs to feature a supported NFC chipset and both devices, your smartphone and this machine, need to be connected to the same WiFi network.<br><br>To use your smartphone as a card reader you'll always need to activate the remote service in the AusweisApp2 on the smartphone. For the first time you'll also need to start the pairing mode on your smartphone, select the device from the list of available devices on this machine and then enter the pairing code shown on the phone. INFO DESKTOP_QML Description text of SaC pairing - Sie können Ihr Smartphone als Kartenleser in der AusweisApp2 verwenden. Das Smartphone muss einen unterstützen NFC-Chip verbaut haben und beide Geräte, sowohl das Smartphone als auch dieser Computer, müssen mit dem selben WLAN-Netz verbunden sein.<br><br>Bitte stellen Sie sicher, dass der Fernzugriff in der App des Smartphones aktiviert ist. Starten sie den Kopplungsprozess indem Sie den "Koppeln"-Knopf anklicken und die vom Smartphone dargestellte 4-stellige PIN eingeben. + Es besteht die Möglichkeit Ihr Smartphone als Kartenleser mit der AusweisApp2 zu verwenden. Das Smartphone muss einen unterstützten NFC-Chip verwenden und beide Geräte, sowohl das Smartphone als auch Ihr Rechner, müssen mit dem selben WLAN-Netz verbunden sein.<br><br>Um Ihr Smartphone als Kartenleser zu verwenden muss stets der Fernzugriff in der AusweisApp2 auf Ihrem Smartphone aktiviert sein. Für eine intiale Verbindung der Geräte muss zusätzlich der Kopplungsmodus auf dem Smartphone aktiviert werden, wählen Sie danach das Gerät aus der Liste der verfügbaren Geräte auf Ihrem Rechner und geben Sie den von Ihrem Smartphone dargestellten Kopplungscode ein. @@ -2249,7 +2565,7 @@ Bitte beachten Sie, dass Sie die Online-Ausweisfunktion mit Ihrer 5-stellige Tra If not, you can now remove your ID card form the card reader. Klicken Sie auf "PIN ändern", wenn Sie noch einmal Ihre PIN neu setzen wollen. -Anderenfalls können Sie nun Ihr Ausweisdokument vom Kartenleser entfernen. +Anderenfalls können Sie nun Ihren Ausweis vom Kartenleser entfernen. <html> @@ -2268,8 +2584,8 @@ Anderenfalls können Sie nun Ihr Ausweisdokument vom Kartenleser entfernen. <html> -<h4>Bitte legen Sie Ihr Ausweisdokument auf.</h4> -<p>Haben Sie bereits Ihr Ausweisdokument aufgelegt, aber es wird nicht angezeigt, klicken Sie bitte auf "Diagnose".</p> +<h4>Bitte legen Sie Ihren Ausweis auf.</h4> +<p>Haben Sie bereits Ihren Ausweis aufgelegt, aber er wird nicht angezeigt, klicken Sie bitte auf "Diagnose".</p> </html> @@ -2278,22 +2594,22 @@ Anderenfalls können Sie nun Ihr Ausweisdokument vom Kartenleser entfernen. <html> -<h4>Mehrere Ausweisdokumente erkannt</h4> -<p>Bitte legen Sie nur ein Ausweisdokument auf.</p> +<h4>Mehrere Ausweise erkannt</h4> +<p>Bitte legen Sie nur einen Ausweis auf.</p> </html> Please make sure that only one card reader with an ID card on it is connected to your computer. - Bitte stellen Sie sicher, dass an Ihrem Computer nur ein Kartenleser mit aufliegendem Ausweisdokument angeschlossen ist. + Bitte stellen Sie sicher, dass an Ihrem Computer nur ein Kartenleser mit aufliegendem Ausweis angeschlossen ist. <html> <h4>eID feature deactivated</h4> -<p>The eID function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the eID function.</p> +<p>The eID function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the eID function.</p> </html> <html> <h4>Online-Ausweisfunktion deaktiviert</h4> -<p>Die Online-Ausweisfunktion Ihres Ausweisdokumentes ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren.</p> +<p>Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihren Ausweis ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren.</p> </html> @@ -2302,13 +2618,13 @@ Anderenfalls können Sie nun Ihr Ausweisdokument vom Kartenleser entfernen. - Wählen Sie für Ihre 6-stellige PIN eine Zahlenkombination, die nicht leicht zu erraten ist, also weder "123456", noch Ihr Geburtsdatum oder andere Zahlen, die auf dem Ausweisdokument aufgedruckt sind. + Wählen Sie für Ihre sechsstellige PIN eine Zahlenkombination, die nicht leicht zu erraten ist, also weder "123456", noch Ihr Geburtsdatum oder andere Zahlen, die auf dem Ausweis aufgedruckt sind. -Bei der erstmaligen PIN-Änderung geben Sie bitte in das Feld "Aktuelle PIN / Transport-PIN" Ihre 5-stellige Transport-PIN ein. Sie finden die Transport-PIN in dem Schreiben, das Sie nach Beantragung Ihres Ausweisdokuments von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde erhalten haben. +Bei der erstmaligen PIN-Änderung geben Sie bitte in das Feld "Aktuelle PIN / Transport-PIN" Ihre fünfstellige Transport-PIN ein. Sie finden die Transport-PIN in dem Schreiben, das Sie nach Beantragung Ihres Ausweises von der für die Ausgabe Ihres Ausweises zuständigen Behörde erhalten haben. - You have entered the wrong PIN two times. For a third attempt you first have to enter your six-digit card access number. You can find your card access number on the front side of your ID card next to the date of expiry. On the electronic residence permit the card access number is printed above your signature. - Sie haben Ihre PIN zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie zunächst Ihre 6-stellige Zugangsnummer eingeben. Die Zugangsnummer finden Sie beim Personalausweis auf der Vorderseite rechts neben dem letzten Tag der Gültigkeitsdauer. Beim elektronischen Aufenthaltstitel finden Sie die Zugangsnummer über Ihrer Unterschrift. + A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card. + Die PIN Ihres Ausweises wurde zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher die sechsstellige Zugangsnummer (CAN) eingeben. Diese finden Sie auf der Vorderseite Ihres Ausweises. Current PIN / Transport PIN: @@ -2343,12 +2659,8 @@ Bei der erstmaligen PIN-Änderung geben Sie bitte in das Feld "Aktuelle PIN deactivatedReaderImageLabel - Click on "Change PIN" to enter your card access number and then set a new PIN. You can find your card access number on the front side of your ID card next to the date of expiry. On the electronic residence permit the card access number is printed above your signature. - "Klicken Sie auf "PIN ändern", um zunächst Ihre Zugangsnummer einzugeben und anschließend eine neue PIN zu setzen. Die Zugangsnummer finden Sie beim Personalausweis auf der Vorderseite rechts neben dem letzten Tag der Gültigkeitsdauer. Beim elektronischen Aufenthaltstitel finden Sie die Zugangsnummer über Ihrer Unterschrift. - - - CAN on nPA icon - Zugangsnummer auf nPA Icon + Click on "Change PIN" to enter your card access number (CAN) and then set a new PIN. You can find your card access number (CAN) on the front side of your ID card next to the date of expiry. On the electronic residence permit the card access number (CAN) is printed above your signature. + "Klicken Sie auf "PIN ändern", um zunächst Ihre Zugangsnummer (CAN) einzugeben und anschließend eine neue PIN zu setzen. Die Zugangsnummer (CAN) finden Sie beim Personalausweis auf der Vorderseite rechts neben dem letzten Tag der Gültigkeitsdauer. Beim elektronischen Aufenthaltstitel finden Sie die Zugangsnummer (CAN) über Ihrer Unterschrift. card reader icon @@ -2371,28 +2683,32 @@ Bei der erstmaligen PIN-Änderung geben Sie bitte in das Feld "Aktuelle PIN PIN änderung erfolgreich icon - no id card icon - Kein Ausweisdokument icon - - - You have entered the wrong PIN three times. The online identification function is now blocked. Please use your personal unblocking key (PUK) to unblock your ID card. You received the PUK with the letter sent to you by your competent authority. - -Please note that you can only use the PUK to unblock the eID function. If you have forgotten your PIN, you can have a new PIN set at your competent authority. - Sie haben Ihre PIN dreimal falsch eingegeben. Die Online-Ausweisfunktion wurde blockiert. Benutzen Sie bitte Ihre Entsperrnummer (PUK) um die Blockierung aufzuheben. Sie finden Ihre PUK in dem Schreiben, das Sie nach Beantragung Ihres Ausweisdokuments von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde erhalten haben. - -Bitte beachten Sie, dass Sie mit Ihrer PUK lediglich Ihren Online-Ausweis entsperren können. Sollten Sie Ihre PIN vergessen haben, können Sie von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde eine neue PIN setzen lassen. + no ID card icon + Kein Ausweis icon <html> <h4>Extended Length is not supported.</h4> -<p>Your remote reader does not meet the technical requirements (Extended Length not supported).</p> +<p>Your smartphone as card reader (SaC) does not meet the technical requirements (Extended Length not supported).</p> </html> - Ihr entfernter Kartenleser erfüllt leider nicht die technischen Voraussetzungen (Extended Length wird nicht unterstützt).< + Ihr Smartphone als Kartenleser (SaK) erfüllt leider nicht die technischen Voraussetzungen (Extended Length wird nicht unterstützt).< open on screen keyboard öffne bildschirmtastatur + + A wrong PIN has been entered three times on your ID card. Your PIN is now blocked. To unblock your PIN you have to enter the PUK. You received the PUK with the letter sent to you by your competent authority. + +Please note that you can only use the PUK to unblock the eID function. If you have forgotten your PIN, you can have a new PIN set at your competent authority. + Die PIN Ihres Ausweises wurde dreimal falsch eingegeben. Ihre PIN ist gesperrt. Zum Entsperren geben Sie bitte Ihre PUK ein. Sie finden Ihre PUK in dem Schreiben, das Sie nach Beantragung Ihres Ausweises von der für die Ausgabe Ihres Ausweis zuständigen Behörde erhalten haben. + +Bitte beachten Sie, dass Sie mit Ihrer PUK lediglich Ihren Online-Ausweis entsperren können. Sollten Sie Ihre PIN vergessen haben, können Sie von der für die Ausgabe Ihres Ausweises zuständigen Behörde eine neue PIN setzen lassen. + + + Display of the card access number (CAN) in the lower right corner of the id card + Darstellung der Kartenzugangsnummer (CAN) in der unteren rechten Ecke des Ausweises + ProgressView @@ -2405,8 +2721,8 @@ Bitte beachten Sie, dass Sie mit Ihrer PUK lediglich Ihren Online-Ausweis entspe This ist die Fortschrittsanzeige der AusweisApp2. - Step %1 of %2 - Schritt %1 von %2 + %1 percent done + %1 Prozent abgeschlossen @@ -2442,11 +2758,11 @@ LABEL ANDROID_TABLET IOS_TABLET Provider contact information - Kontaktinformationen des Diensteanbieters + Kontaktinformationen des Anbieters - Contact information of the selected service provider. - Kontaktinformationen des ausgewählten Diensteanbieters. + Contact information of the selected provider. + Kontaktinformationen des ausgewählten Anbieters. @@ -2463,14 +2779,6 @@ LABEL ANDROID_TABLET IOS_TABLET LABEL ANDROID_TABLET IOS_TABLET Online-Anwendung - - Link to service provider - Link zum Diensteanbieter - - - Clicking this link will open the website of the service provider in your web browser. The URL of the provider is - Durch einen Klick auf diesen Link öffnen Sie die Webseite des Diensteanbieters. Die URL des Anbieters lautet - To online application LABEL DESKTOP_QML @@ -2499,24 +2807,26 @@ LABEL ANDROID_TABLET IOS_TABLET List of your past interactions with this provider - Ihre vergangenen Interaktionen mit diesem Diensteanbieter + Ihre vergangenen Interaktionen mit diesem Anbieter - The list is empty, no recorded interaction with this service provider. - Die Liste ist leer, keine Interaktion mit diesem Diensteanbieter aufgezeichnet. + The list is empty, no recorded interaction with this provider. + Die Liste ist leer, keine Interaktion mit diesem Anbieter aufgezeichnet. Currently there are no history entries. - INFO DESKTOP_QML No authentication history, placeholder text. + INFO DESKTOP_QML No authentication history, placeholder text. +---------- +INFO ANDROID_TABLET IOS_TABLET No authentication history, placeholder text. Derzeit gibt es keine Einträge im Verlauf. ProviderDetailHistoryInfo - Service provider + Provider LABEL ANDROID_TABLET IOS_TABLET - Diensteanbieter + Anbieter Purpose for reading out requested data @@ -2526,7 +2836,7 @@ LABEL ANDROID_TABLET IOS_TABLET Read data LABEL ANDROID_TABLET IOS_TABLET - Daten auslesen + Ausgelesene Daten Terms of usage @@ -2592,11 +2902,11 @@ LABEL ANDROID_TABLET IOS_TABLET Provider detail view - Detailansicht des Diensteanbieters + Detailansicht des Anbieters - This view shows a detailed description of a service provider. - Diese Ansicht zeigt eine detaillierte Beschreibung eines Diensteanbieters. + This view shows a detailed description of a provider. + Diese Ansicht zeigt eine detaillierte Beschreibung eines Anbieters. Description @@ -2604,13 +2914,13 @@ LABEL ANDROID_TABLET IOS_TABLET Beschreibung - Description of the service provider. - Beschreibung des Diensteanbieters. + Description of the provider. + Beschreibung des Anbieters. - The service provider did not provide a description. + The provider did not provide a description. LABEL DESKTOP_QML - Der Diensteanbieter hat keine Beschreibung zur Verfügung gestellt. + Der Anbieter hat keine Beschreibung zur Verfügung gestellt. History @@ -2621,7 +2931,7 @@ LABEL ANDROID_TABLET IOS_TABLET ProviderHeader - To service provider + To provider LABEL ANDROID IOS Zum Anbieter @@ -2643,7 +2953,7 @@ LABEL ANDROID_TABLET IOS_TABLET ProviderListItemDelegate Open provider details for - Öffne Details vom Diensteanbieter + Öffne Details vom Anbieter @@ -2683,7 +2993,7 @@ LABEL ANDROID_TABLET IOS_TABLET All provider LABEL DESKTOP_QML - Alle Diensteanbieter + Alle Anbieter Citizen services @@ -2705,6 +3015,11 @@ LABEL ANDROID_TABLET IOS_TABLET LABEL DESKTOP_QML Weitere Dienste + + No results matching your search query found + LABEL DESKTOP_QML The text entered into the provider search field results in no matches + Keine Ergebnisse zu Ihrer Suche gefunden + ProviderSectionDelegate @@ -2720,7 +3035,7 @@ LABEL ANDROID_TABLET IOS_TABLET LABEL DESKTOP_QML ---------- LABEL IOS_TABLET - Diensteanbieter + Anbieter Citizen services @@ -2751,11 +3066,16 @@ LABEL IOS_TABLET Weitere Services - No match found - LABEL ANDROID_TABLET + No results matching your search query found + LABEL ANDROID_TABLET The text entered into the provider search field results in no matches ---------- -LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein Ergebnis - Keine Übereinstimmung gefunden +LABEL IOS_TABLET The text entered into the provider search field results in no matches + Keine Ergebnisse zu Ihrer Suche gefunden + + + Search providers + LABEL DESKTOP_QML + Anbieter suchen @@ -2765,8 +3085,8 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisEs wurden keine Anbieter gefunden. Bitte ändern Sie Ihr Suchkriterium. - This section lists offers of service providers that support online identification. Click on an entry to go to the provider's web site. This section will be continuously updated with further applications for the online identification function. - Diese Dialogseite listet die Angebote von Diensteanbietern auf, die die Online-Ausweisfunktion unterstützen. Klicken Sie auf einen Eintrag, um auf die Webseite des Diensteanbieters zu gelangen. Diese Dialogseite wird kontinuierlich mit weiteren Angeboten zur Online-Ausweisfunktion aktualisiert. + This section lists offers of providers that support online identification. Click on an entry to go to the provider's web site. This section will be continuously updated with further applications for the online identification function. + Diese Dialogseite listet die Angebote von Anbietern auf, die die Online-Ausweisfunktion unterstützen. Klicken Sie auf einen Eintrag, um auf die Webseite des Anbieters zu gelangen. Diese Dialogseite wird kontinuierlich mit weiteren Angeboten zur Online-Ausweisfunktion aktualisiert. Search: @@ -2877,7 +3197,7 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein Ergebnis Enter the 4-digit pairing code shown on your other device. - Geben Sie den 4-stelligen Kopplungscode ein, der auf Ihrem anderen Gerät angezeigt wird. + Geben Sie den vierstelligen Kopplungscode ein, der auf dem anderen Gerät angezeigt wird. @@ -2886,6 +3206,22 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisClick to pair Klicken zum Koppeln + + Smartphone named "%1" + Smartphone namens "%1" + + + Press space to unpair the smartphone "%1". + Drücken Sie die Leertaste um das Smartphone "%1" zu entkoppeln. + + + Press space to pair the smartphone "%1". + Drücken Sie die Leertaste um das Smartphone "%1" zu koppeln. + + + Remove remote device + Entferne das Gerät + RemoteReaderView @@ -2897,84 +3233,95 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisAvailable remote devices Verfügbare Netzwerkgeräte - - No devices with enabled remote service were found on the current WiFi network - Im WLAN-Netz wurden keine Geräte mit aktiviertem Fernzugriff gefunden - Only devices that are already paired or are connected to the same WiFi network and have the remote service enabled are shown here. Nur Geräte die bereits gekoppelt wurden, oder sich mit aktiviertem Fernzugriff im selben WLAN-Netz befinden, werden hier angezeigt. + + More information + LABEL DESKTOP_QML + Mehr Informationen + - RemoteServicePairingPopup + RemoteServiceSettings - Pairing code - INFO ANDROID IOS Header of the pairing dialog when using the smartphone as card reader - Kopplungscode + Configure remote service + LABEL ANDROID IOS + Fernzugriff konfigurieren + + + + RemoteServiceView + + Remote service + LABEL ANDROID IOS + Fernzugriff - Enter this code on your other device to use this device as a card reader - INFO ANDROID IOS Main text of the pairing dialog when using the smartphone as card reader. - Geben Sie diesen Code auf Ihrem anderen Gerät ein, um dieses Gerät als Kartenleser zu verwenden + Pairing failed. Please start a new pairing process on your other device and enter the shown pairing code. + ERROR ANDROID IOS An error occurred while pairing the device. + Die Kopplung ist fehlgeschlagen. Bitte starten Sie eine neue Kopplung an Ihrem anderen Gerät und geben den angezeigten Kopplungscode ein. - Click to close dialog - Schließe hiermit den Dialog + Both of your devices have to be connected to the same WiFi. + INFO ANDROID IOS The remote service is active. Hint that both devices need to be connected to the same network. + Ihre beiden Geräte müssen mit dem selben WLAN-Netz verbunden sein. - - - RemoteServiceSettings - Configure remote service + Enable NFC LABEL ANDROID IOS - Fernzugriff konfigurieren + NFC aktivieren - - - RemoteServiceView - Configure local settings + Stop remote service LABEL ANDROID IOS - Konfiguriere lokale Einstellungen + Fernzugriff stoppen - Pair remote devices + Start remote service LABEL ANDROID IOS - Kopple entfernten Kartenleser + Fernzugriff starten - Remote service + Stop pairing LABEL ANDROID IOS - Fernzugriff + Kopplung stoppen - Pairing failed. Please try again to activate pairing on your other device and enter the shown pairing code. - ERROR ANDROID IOS An error occurred while pairing the device. - Die Kopplung ist fehlgeschlagen. Bitte starten Sie eine neue Kopplung an Ihrem anderen Gerät und geben den angezeigten Kopplungscode ein. + Start pairing + LABEL ANDROID IOS + Kopplung starten - - - RemoteServiceViewLocal - Device name + Pairing code: <b>%1</b> LABEL ANDROID IOS - Gerätename + Kopplungscode: <b>%1</b> - Set device name: + Card access in progress LABEL ANDROID IOS - Wählen Sie einen Gerätenamen: + Kartenzugriff - PIN pad mode - LABEL ANDROID IOS - Tastaturmodus + Waiting for connection from a paired device... + INFO ANDROID IOS + Warte auf eine Verbindung eines gekoppelten Gerätes... - Enter PIN on this device + Start the remote access, in order to make this smartphone visible and to use it as a card reader (SaC) + INFO ANDROID IOS + Starten Sie den Fernzugriff um dieses Smartphone sichtbar und damit als Kartenleser (SaK) nutzbar zu machen + + + Enter this code on your other device to use your smartphone as a card reader (SaC) + INFO ANDROID IOS + Geben Sie diesen Code auf Ihrem anderen Gerät ein um Ihr Smartphone als Kartenleser (SaK) zu verwenden + + + Pairing code: %1 LABEL ANDROID IOS - PIN-Eingabe auf diesem Gerät + Kopplungscode: %1 @@ -2995,12 +3342,12 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisVerfügbare Geräte - No new remote reader was found on your network. Make sure that the remote reader functionality in AusweisApp2 on your other device is activated and that your devices are connected to the same network. - INFO ANDROID IOS No remote reader was found on the network, both devices need to be connected to the same wifi network. - Kein entfernter Kartenleser in Ihrem Netzwerk verfügbar. Bitte stellen Sie sicher, dass die Funktion "Fernzugriff" in der AusweisApp2 auf Ihrem anderen Gerät aktiviert ist. Beide Geräte müssen sich im selben Netzwerk befinden. + No unpaired smartphone as card reader (SaC) available. Please make sure that the smartphone as card reader (SaC) functionality in AusweisApp2 on your other device is activated an that both devices are connected to the same WiFi. + INFO ANDROID IOS No SaC was found on the network, both devices need to be connected to the same wifi network. + Kein ungekoppeltes Smartphone als Kartenleser verfügbar. Bitte stellen Sie sicher, dass die Funktion "Fernzugriff" in der AusweisApp2 auf Ihrem Smartphone aktiviert ist und beide Geräte mit demselben WLAN verbunden sind. - Please start pairing mode first. + Start the pairing mode on your smartphone if you haven't done it already. INFO ANDROID IOS Information dialog that requests the user to start the pairing mode on the smarthpone. Starten Sie den Kopplungsmodus auf Ihrem Smartphone, falls noch nicht geschehen. @@ -3014,38 +3361,30 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisINFO ANDROID IOS Kopplungsmodus - - - RemoteServiceViewStartStop - - Please start the remote service in order to use your smartphone as a card reader with AusweisApp2. Please note: Both your devices have to be connected to the same WiFi. - INFO ANDROID IOS The remote service is active. Hint that both devices need to be connected to the same network. - Bitte starten Sie den Fernzugriff, damit Sie Ihr Smartphone als Kartenleser für die AusweisApp2 nutzen können. Bitte beachten Sie: dies ist nur möglich, wenn beide Geräte mit demselben WLAN verbunden sind. - - Enable NFC - LABEL ANDROID IOS - NFC aktivieren + Remove pairing + INFO ANDROID IOS + Kopplung entfernen - Stop remote service - LABEL ANDROID IOS - Fernzugriff stoppen + Remove + INFO ANDROID IOS + Entfernen - Start remote service + Click to pair LABEL ANDROID IOS - Fernzugriff starten + Klicken zum Koppeln - Start pairing + Click to remove device LABEL ANDROID IOS - Kopplung starten + Klicken um das Gerät zu entfernen - Card access in progress - LABEL ANDROID IOS - Kartenzugriff + Do you want to remove the pairing of the device "%1"? + INFO ANDROID IOS + Wollen Sie die Kopplung mit dem Gerät "%1" aufheben? @@ -3071,19 +3410,19 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisVerbindung wird hergestellt - Your remote device does not meet the technical requirements (Extended Length not supported). + The connected smartphone as card reader (SaC) unfortunately does not meet the technical requirements (Extended Length not supported). INFO ANDROID IOS The device does not support Extended Length and can not be used as card reader. - Ihr entfernter Kartenleser erfüllt leider nicht die technischen Voraussetzungen (Extended Length wird nicht unterstützt). + Das verbundene Smartphone als Kartenleser erfüllt leider nicht die technischen Voraussetzungen (Extended Length wird nicht unterstützt). - The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function. + The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function. INFO ANDROID IOS The online authentication is disabled and needs to be enabled by the authorities. - Die Online-Ausweisfunktion Ihres Ausweisdokumentes ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. + Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihren Ausweis ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. - Connected to %1. Please insert your ID card. - INFO ANDROID IOS The connection to the smartphone was established, the id card may be inserted. - Verbunden mit %1. Bitte legen Sie Ihr Ausweisdokument auf. + Connected to %1. Please place the NFC interface of the smartphone on your ID card. + INFO ANDROID IOS The connection to the smartphone was established, the ID card may be inserted. + Verbunden mit %1. Bitte platzieren Sie das Smartphone mit der NFC-Schnittstelle auf Ihrem Ausweis. Determine card @@ -3091,9 +3430,9 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisErmittle Ausweis - The device %1 was unpaired because it does not react to connection attempts. Retry the pairing process if you want to use this device to authenticate yourself. + The device %1 was unpaired because it did not react to connection attempts. Pair the device again to use it as a card reader. INFO ANDROID IOS The paired smartphone was removed since it did not respond to connection attempts. It needs to be paired again before using it. - Das Gerät %1 wurde entkoppelt, da es nicht auf Verbindungsversuche reagiert hat. Versuchen Sie das Gerät erneut zu koppeln, wenn Sie es zur Authentisierung verwenden möchten. + Das Gerät %1 wurde entkoppelt, da es nicht auf Verbindungsversuche reagiert hat. Koppeln Sie das Gerät erneut, um es wieder als Kartenleser zu verwenden. To use the remote service WiFi has to be activated. Please activate WiFi in your device settings. @@ -3101,9 +3440,9 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisUm den Fernzugriff zu nutzen, muss WLAN aktiviert werden. Bitte aktivieren Sie WLAN in Ihren Einstellungen. - No paired and activated remote device was detected. Make sure that you have started the remote service on your remote device. + No paired smartphone as cardreader (SaC) with activated "remote service" available. INFO ANDROID IOS No paired and reachable device was found, hint that the remote device needs to be actually started for this feature. - Kein gekoppeltes und aktiviertes Gerät gefunden. Stellen Sie sicher, dass der Fernzugriff auf Ihrem Gerät gestartet wurde. + Kein gekoppeltes Smartphone als Kartenleser mit aktiviertem "Fernzugriff" verfügbar. @@ -3122,9 +3461,9 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisDies ist das Ergebnis einer Authentisierung. - Send log file + Send logfile LABEL ANDROID IOS - Sende Protokoll + Protokoll versenden Send email @@ -3138,9 +3477,14 @@ LABEL IOS_TABLET Der in das Suchfeld eingegebene String erzielte kein ErgebnisSearch LABEL DESKTOP_QML ---------- -LABEL IOS +LABEL ANDROID Suchen + + Search providers + LABEL IOS + Anbieter suchen + Cancel LABEL IOS @@ -3158,23 +3502,15 @@ LABEL IOS Clear search string Lösche Sucheingabe - - - SectionSwitch - - Service - LABEL ANDROID IOS - Dienst - - Pairing - LABEL ANDROID IOS - Kopplung + Type provider to search for + LABEL ANDROID + Tippen Sie den Namen des Anbieters ein, nach dem Sie suchen möchten - Settings - LABEL ANDROID IOS - Einstellungen + Search provider list + LABEL ANDROID + Durchsuchen der Anbieterliste @@ -3224,6 +3560,50 @@ LABEL IOS LABEL DESKTOP_QML Jetzt überprüfen + + History is empty + Es gibt keine Einträge im Verlauf + + + Avoid visual feedback in the on screen keypad + LABEL DESKTOP_QML + Deaktiviere die Animation der Tasten auf der Bildschirmtastatur + + + Delete history + LABEL DESKTOP_QML + Verlauf löschen + + + All history entries will be deleted. + INFO DESKTOP_QML The current history is about to be removed, user confirmation required. + Alle im Verlauf gespeicherten Informationen werden gelöscht. + + + Show update + LABEL DESKTOP_QML + Aktualisierung anzeigen + + + An update is available (version %1)! + LABEL DESKTOP_QML An update is available, the new version is supplied to the user. + Eine Aktualisierung ist verfügbar (Version %1)! + + + An update is available but retrieving the information failed. + LABEL DESKTOP_QML The updater found an update but not all required update information are valid, this should be a very rare case. + Eine Aktualisierung ist verfügbar, das Herunterladen der Informationen ist jedoch fehlgeschlagen. + + + Your version %1 of %2 is up to date. + LABEL DESKTOP_QML The current version is up to date, no user action is required. + Ihre Version %1 der %2 ist aktuell. + + + No update information available, please check for update manually. + LABEL DESKTOP_QML The automatic update check is disabled (or no network connection was present during app start), a manual check for update is required. + Keine Aktualisierungsinformationen vorhanden, bitte prüfen Sie manuell auf verfügbare Aktualisierungen. + SelfAuthenticationData @@ -3240,27 +3620,41 @@ LABEL ANDROID IOS OK - Read data + Successfully read data + INFO DESKTOP_QML Status message that the self authentication successfully completed. + Lesevorgang erfolgreich + + + Read data successfully + INFO ANDROID IOS The self authentication was successfully completed. + Daten erfolgreich ausgelesen + + + Save as PDF... LABEL DESKTOP_QML - Daten auslesen + Als PDF speichern... - Self-authentication data view - Anzeige der Selbstauskunft + Information + Information - This is the self-authentication data view of the AusweisApp2. - Dies ist die Anzeige der Selbstauskunft der AusweisApp2. + This is the self-authentication result data view of the AusweisApp2. + Dies ist die Darstellung der Ergebnisse der Selbstauskunft der AusweisApp2. - Successfully read data - INFO DESKTOP_QML Status message that the self authentication successfully completed. - Lesevorgang erfolgreich + Read data + LABEL DESKTOP_QML Title of the self authentication result data view + Ausgelesene Daten - Read data successfully - INFO ANDROID IOS The self authentication was successfully completed. - Daten erfolgreich ausgelesen + Self-Authentication result data view + Darstellung der Ergebnisse der Selbstauskunft + + + Read self-authentication data + LABEL DESKTOP_QML Title of the self authentication result data view + Ausgelesene Daten der Selbstauskunft @@ -3275,26 +3669,30 @@ LABEL ANDROID IOS LABEL DESKTOP_QML ---------- LABEL ANDROID IOS - Überall wo Sie dieses Logo sehen, können Sie Ihr Ausweisdokument einsetzen. + Überall wo Sie dieses Logo sehen, können Sie Ihren Ausweis einsetzen. Use the button 'See my personal data' to display the data stored on your ID card. An Internet connection is required to display the data. LABEL DESKTOP_QML ---------- LABEL ANDROID IOS - Über die Schaltfläche 'Meine Daten einsehen' können Sie sich die im Chip Ihres Ausweisdokuments gespeicherten Daten anzeigen lassen. Um die Daten anzeigen zu können, benötigt diese Anwendung eine Internetverbindung. + Über die Schaltfläche 'Meine Daten einsehen' können Sie sich die im Chip Ihres Ausweises gespeicherten Daten anzeigen lassen. Um die Daten anzeigen zu können, benötigt diese Anwendung eine Internetverbindung. Your personal data is neither saved nor processed in any way. Please see our %1 for details on how your personal data is processed. - LABEL ANDROID IOS + LABEL DESKTOP_QML +---------- +LABEL ANDROID IOS Es erfolgt keine Speicherung oder Weiterverarbeitung Ihrer persönlichen Daten. Näheres dazu erfahren Sie in unserer %1. https://www.ausweisapp.bund.de/en/privacy/ + LABEL DESKTOP_QML https://www.ausweisapp.bund.de/datenschutz/ data privacy statement + LABEL DESKTOP_QML Datenschutzerklärung @@ -3305,16 +3703,19 @@ LABEL ANDROID IOS Meine Daten einsehen - %1 more presses to toggle test PKI. - %1 weitere Klicks um die Test-PKI umzuschalten. + %1 more presses to toggle the testmode for the self-authentication. + INFO ANDROID IOS Used in notifications when the user taps the magnifying glass + %1 weitere Klicks um den Testmodus für die Selbstauskunft umzuschalten. - Test PKI activated. - Test-PKI aktiviert. + Testmode for the self-authentication activated. + INFO ANDROID IOS Used in notifications when the user taps the magnifying glass + Testmodus für die Selbstauskunft aktiviert. - Test PKI deactivated. - Test-PKI deaktiviert. + Testmode for the self-authentication deactivated. + INFO ANDROID IOS Used in notifications when the user taps the magnifying glass + Testmodus für die Selbstauskunft deaktiviert. https://www.ausweisapp.bund.de/datenschutz/ @@ -3324,19 +3725,28 @@ LABEL ANDROID IOS Click to open link to data privacy statement in browser: %1 Öffne den Link der Datenschutzerklärung im Browser: %1 + + This is the self-authentication view of the AusweisApp2. + Dies ist die Darstellung der Selbstauskunft der AusweisApp2. + + + Self-Authentication. + LABEL DESKTOP_QML + Selbstauskunft. + SelfInfoWidget The following data has been read out from your ID card: - Folgende Daten wurden aus Ihrem Ausweisdokument ausgelesen: + Folgende Daten wurden aus Ihrem Ausweis ausgelesen: SelfInformationWidget You can use your ID card anywhere you see this logo. - Überall wo Sie dieses Logo sehen, können Sie Ihr Ausweisdokument einsetzen. + Überall wo Sie dieses Logo sehen, können Sie Ihren Ausweis einsetzen. See my personal data @@ -3363,7 +3773,9 @@ LABEL ANDROID IOS Settings - LABEL DESKTOP_QML + LABEL DESKTOP_QML +---------- +LABEL ANDROID IOS Einstellungen @@ -3373,12 +3785,16 @@ LABEL ANDROID IOS General - LABEL DESKTOP_QML + LABEL DESKTOP_QML +---------- +LABEL ANDROID IOS Allgemein Smartphone as card reader - LABEL DESKTOP_QML + LABEL DESKTOP_QML +---------- +LABEL ANDROID IOS Smartphone als Kartenleser @@ -3388,9 +3804,90 @@ LABEL ANDROID IOS Security and privacy - LABEL DESKTOP_QML + LABEL DESKTOP_QML +---------- +LABEL ANDROID IOS Sicherheit und Datenschutz + + Debug options + LABEL DESKTOP_QML + Debugoptionen + + + Pairing the device ... + LABEL DESKTOP_QML + Das Gerät wird gekoppelt ... + + + The device "%1" has been paired. + Das Gerät "%1" wurde gekoppelt. + + + Pairing to "%1" failed: + ERROR DESKTOP_QML An error occurred while pairing the device. + Die Kopplung mit "%1" ist fehlgeschlagen: + + + Device name + LABEL ANDROID IOS + Gerätename + + + PIN pad mode + LABEL ANDROID IOS + Tastaturmodus + + + Enter PIN on this device + LABEL ANDROID IOS + PIN-Eingabe auf diesem Gerät + + + Shuffle keypad buttons + LABEL ANDROID IOS + Zufällige Anordnung der Ziffern + + + Avoid visual feedback in the on screen keypad + LABEL ANDROID IOS + Deaktiviere die Animation der Tasten auf der Bildschirmtastatur + + + History + LABEL ANDROID IOS + Verlauf + + + Save authentification history + LABEL ANDROID IOS + Verlauf der Ausweisvorgänge speichern + + + Change language + LABEL ANDROID IOS + Sprache wechseln + + + Remote card reader + LABEL ANDROID IOS + Smartphone als Kartenleser + + + Click here to use another smartphone as a card reader + LABEL ANDROID IOS + Klicken Sie hier um ein anderes Smartphone als Kartenleser zu verwenden + + + Randomize the order of the on screen keypad buttons + LABEL ANDROID IOS + Ziffern der Bildschirmtastatur zufällig anordnen + + + Privacy keypad + LABEL ANDROID IOS + Vertrauliche Bildschirmtastatur + SettingsWidget @@ -3420,77 +3917,75 @@ LABEL ANDROID IOS - SetupAssistantBinaryDecisionView + SetupAssistantView - No + Setup Assistant LABEL DESKTOP_QML - Nein + Einrichtungsassistent - Yes - LABEL DESKTOP_QML - Ja + Welcome to the AusweisApp2. Please take a few moments to setup the environment to your needs. Every decision you make can later be changed in the settings menu. + INFO DESKTOP_QML Welcome message when starting the setup assistant. + Willkommen in der AusweisApp2. Bitte nehmen Sie sich einen Moment Zeit, um die App nach Ihren Wünschen anzupassen. Jede Einstellung kann später wieder im Einstellungsmenü geändert werden. - - - SetupAssistantCardReaderView - Advance + History Setting LABEL DESKTOP_QML - Fortfahren + Verlaufseinstellungen - - - SetupAssistantView - Setup Assistant + Do you want to set your PIN now? + INFO DESKTOP_QML Inquiry message if the 5-digit transport PIN should be changed to an ordinary PIN (now). + Möchten Sie jetzt Ihre PIN setzen? + + + If you have not already done so you have to change your 5-digit transport PIN to a 6-digit PIN before you can use the online-ID function. + INFO DESKTOP_QML Hint that this change may be carried out form the main menu as well and that it is required to use the online authentication feature of the ID card. + Falls noch nicht geschehen, müssen Sie vor der erstmaligen Nutzung der Online-Ausweisfunktion die fünfstellige Transport-PIN in eine sechsstellige PIN ändern. + + + Transport PIN LABEL DESKTOP_QML - Einrichtungsassistent + Transport PIN - Welcome to the AusweisApp2. Please take a few moments to setup the environment to your needs. Every decision you make can later be changed in the settings menu. - INFO DESKTOP_QML Welcome message when starting the setup assistant. - Willkommen in der AusweisApp2. Bitte nehmen Sie sich einen Moment Zeit, um die App nach Ihren Wünschen anzupassen. Jede Einstellung kann später wieder im Einstellungsmenü geändert werden. + You have completed the setup of the AusweisApp2 successfully. + INFO DESKTOP_QML Success message after completing the setup assistant. + Sie haben die Einrichtung der AusweisApp2 erfolgreich abgeschlossen. - Do you want to save a history of performed authentications? + Do you want to save a history of performed authentications on your device? INFO DESKTOP_QML Question if the authentication history shall be stored. - Möchten Sie den Verlauf durchgeführter Authentifizierungen speichern? + Möchten Sie einen Verlauf durchgeführter Authentisierungen auf diesem Gerät speichern? - The following data is saved: authentication date, service provider contact data, read data. + The history is only saved locally. You can use it to see on what date you transmitted which data to which party. After enabling the history you can view and delete the entries anytime. INFO DESKTOP_QML Information text which data is stored in the history record. - Folgende Daten werden gespeichert: Authentisierungsdatum, Kontaktdaten des Diensteanbieters, Art der ausgelesenen Daten. + Der Verlauf wird nur lokal angelegt. Dort können Sie jederzeit nachschauen, wann Sie wem welche Daten übermittelt haben. Sie können nach aktivieren der Funktion jederzeit Verlaufseinträge einsehen und löschen. - History Setting - LABEL DESKTOP_QML - Verlaufseinstellungen + Setup assistant view + Ansicht des Einstellungsassistenten - Continue - LABEL DESKTOP_QML - Fortsetzen + This is the setup assistant view which will guide you through the basic setup of %1 + Dieser Einstellungsassistent wird Sie durch die grundlegende Einrichtung der %1 führen - Do you want to change your transport PIN to a personal PIN now? - INFO DESKTOP_QML Inquiry message if the 5 digit transport PIN should be changed to an ordinary PIN (now). - Möchten Sie jetzt Ihre Transport PIN in eine persönliche PIN ändern? + History setup step + Einrichtungsschritt zum Verlauf - This process can always be started from the main menu. The online-ID function is only usable with a personal PIN. - INFO DESKTOP_QML Hint that this change may be carried out form the main menu as well and that it is required to use the online authentication feature of the id card. - Dieser Prozess kann jederzeit aus dem Hauptmenü heraus gestartet werden. Die Online-Ausweisfunktion ist nur mit einer persönlichen PIN nutzbar. + Change transport PIN setup step + Einrichtungsschritt zur Änderung der Transport PIN - Transport PIN - LABEL DESKTOP_QML - Transport PIN + Setup assistant done + Einstellungsassistent beendet - You have completed the setup of the AusweisApp2 successfully. - INFO DESKTOP_QML Success message after completing the setup assistant. - Sie haben die Einrichtung der AusweisApp2 erfolgreich abgeschlossen. + Card reader setup step + Einrichtungsschritt zu Kartenlesern @@ -3500,8 +3995,8 @@ LABEL ANDROID IOS AusweisApp2 - Service provider - Diensteanbieter + Provider + Anbieter Purpose for reading out requested data: @@ -3524,8 +4019,8 @@ LABEL ANDROID IOS Wichtige Transaktionsinformationen - The following data is required by the service provider. You can deselect the non-mandatory data fields if you do not want this data to be transmitted. - Folgende Daten werden von dem Diensteanbieter benötigt. Bei Datenfeldern, die als "abwählbar" gekennzeichnet sind, können Sie entscheiden, ob Sie diese Daten übermitteln möchten. + The following data is required by the provider. You can deselect the non-mandatory data fields if you do not want this data to be transmitted. + Folgende Daten werden von dem Anbieter benötigt. Bei Datenfeldern, die als "abwählbar" gekennzeichnet sind, können Sie entscheiden, ob Sie diese Daten übermitteln möchten. details @@ -3535,14 +4030,9 @@ LABEL ANDROID IOS StoreFeedbackPopup - Would you like to rate this app? + Are you satisfied with AusweisApp2? INFO ANDROID Header of the app rating popup. - Möchten Sie diese App bewerten? - - - Rate - LABEL ANDROID - Bewerten + Zufrieden mit der AusweisApp2? We would be very grateful if you could leave a rating on the Google Play Store! @@ -3550,9 +4040,14 @@ LABEL ANDROID IOS Wir würden uns sehr über eine Bewertung im Google Play Store freuen! - No, thanks + Don't ask again + LABEL ANDROID + Ignorieren + + + Rate app LABEL ANDROID - Nein, danke + App bewerten @@ -3570,11 +4065,6 @@ LABEL ANDROID IOS USB card reader USB Kartenleser - - Please start pairing mode first. - LABEL DESKTOP_QML - Starten Sie den Kopplungsmodus auf Ihrem Smartphone, falls noch nicht geschehen. - TechnologySwitch @@ -3621,6 +4111,18 @@ LABEL ANDROID IOS Notifications Benachrichtungen + + Open settings view of %1 + Öffne die %1 Einstellungen + + + Open the online help of %1 + Öffne die %1 Online-Hilfe + + + Show the in-app notifications of %1 + Zeige den interne Benachrichtigungsdialog der %1 + TitleBarNavigation @@ -3640,17 +4142,6 @@ LABEL ANDROID IOS Zurück - - ToggleableOption - - is enabled - ist aktiviert - - - is disabled - ist deaktiviert - - TutorialFooter @@ -3731,7 +4222,7 @@ LABEL ANDROID IOS ... und zum Lesen des Ausweises das Smartphone als Kartenleser zu nutzen. Alternativ geht natürlich auch ein USB-Lesegerät. - https://www.ausweisapp.bund.de/mobile-geraete/ + https://www.ausweisapp.bund.de/en/compatible-devices/mobile-phones-and-tablets/ LABEL ANDROID IOS https://www.ausweisapp.bund.de/mobile-geraete/ @@ -3740,7 +4231,7 @@ LABEL ANDROID IOS Wie kann ich die AusweisApp2 auf meinem Smartphone nutzen? - The AusweisApp2 offers the following options to access your id card: + The AusweisApp2 offers the following options to access your ID card: LABEL ANDROID IOS Die AusweisApp2 bietet zum Auslesen die folgenden Möglichkeiten: @@ -3750,12 +4241,12 @@ LABEL ANDROID IOS Wie kann ich die AusweisApp2 auf meinem iPhone nutzen? - Many iPhones (iPhone 7 and newer) can access the id card via the built-in NFC interface. + Many iPhones (iPhone 7 and newer) can access the ID card via the built-in NFC interface. INFO ANDROID IOS Viele iPhones (iPhone 7 und neuer) können direkt über die im Gerät verbaute NFC-Schnittstelle auf die Online-Ausweisfunktion des Ausweises zugreifen. - Many Android devices can access the id card via the built-in NFC interface. + Many Android devices can access the ID card via the built-in NFC interface. Viele Android-Geräte können direkt über die im Gerät verbaute NFC-Schnittstelle auf die Online-Ausweisfunktion des Ausweises zugreifen. @@ -3768,6 +4259,26 @@ LABEL ANDROID IOS LABEL ANDROID IOS Smartphone <b>mit</b> NFC-Chip als Kartenleser + + Direct connection via NFC chip tutorial + LABEL ANDROID IOS + Tutorial zum direkten Auslesen über NFC + + + Smartphone as card reader tutorial + LABEL ANDROID IOS + Tutorial zum Smartphone als Kartenleser + + + Smartphone as card reader mobile tutorial + LABEL ANDROID IOS + Mobilgeräte-Tutorial zum Smartphone als Kartenleser + + + Using a bluetooth card reader tutorial + LABEL ANDROID IOS + Tutorial zur Verwendung eines Bluetooth-Lesers + TutorialImportant @@ -3778,12 +4289,13 @@ LABEL ANDROID IOS Before you use the online ID function please change the + LABEL ANDROID IOS Vor der erstmaligen Nutzung der Online-Ausweisfunktion bitte die 5 digits long LABEL ANDROID IOS - 5-stellige + fünfstellige transport PIN @@ -3798,7 +4310,7 @@ LABEL ANDROID IOS 6 digits long PIN LABEL ANDROID IOS - 6-stellige PIN + sechsstellige PIN before you use the online ID function! @@ -3807,6 +4319,7 @@ LABEL ANDROID IOS change! + LABEL ANDROID IOS ersetzen! @@ -3836,10 +4349,12 @@ LABEL ANDROID IOS or + LABEL ANDROID IOS oder www.personalausweisportal.de + LABEL ANDROID IOS www.personalausweisportal.de @@ -3859,6 +4374,7 @@ LABEL ANDROID IOS https://www.youtube.com/watch?v=wZglRda5Y60&index=4&list=PLLB5ERhVkn25qQXgMHQr-1KgyZsJKoSAm + LABEL ANDROID IOS https://www.youtube.com/watch?v=wZglRda5Y60&index=4&list=PLLB5ERhVkn25qQXgMHQr-1KgyZsJKoSAm @@ -3867,8 +4383,9 @@ LABEL ANDROID IOS Sie können mehr dazu im YouTube-Video erfahren - You can always access this tutorial again from the side bar. - Sie können dieses Tutorial jederzeit wieder von der Seitenleiste aus aufrufen. + You can always access this tutorial again from the "Help & Feedback" section in the side bar. + LABEL ANDROID + Sie können dieses Tutorial jederzeit wieder über den Bereich "Hilfe & Feedback" aufrufen. The transport PIN is sent to you by the Bundesdruckerei via mail. @@ -3882,8 +4399,18 @@ LABEL ANDROID IOS You can always access this tutorial again from the "More" section in the menu bar. + LABEL IOS + Sie können dieses Tutorial jederzeit wieder über den Bereich "Mehr" aufrufen. + + + Please note: The transport PIN can only be used for your first PIN change. If you have already set your personal PIN (e.g. while picking up your ID card) only the set PIN is valid. + LABEL ANDROID IOS + Hinweis: Die Transport-PIN kann nur für die erstmalige PIN-Änderung verwendet werden. Sollten Sie (z.B. bei der Abholung Ihres Ausweises) bereits eine persönliche PIN gesetzt haben, ist nur noch diese gültig. + + + You can always set a new PIN at the issuing authority if the (transport) PIN is not known. LABEL ANDROID IOS - Sie können dieses Tutorial jederzeit wieder über den Bereich "Mehr" aus aufrufen. + Ist Ihnen die (Transport-)PIN nicht bekannt, können Sie in der zuständigen Behörde jederzeit eine neue PIN setzen. @@ -3924,9 +4451,9 @@ LABEL ANDROID IOS ...und mit dem Gerät koppeln. - Click the link on the website of the service provider. + Click the link on the website of the provider. LABEL ANDROID IOS - Link auf Webseite des Diensteanbieters + Link auf Webseite des Anbieters klicken. @@ -3975,12 +4502,13 @@ klicken. Now + LABEL ANDROID IOS Jetzt 6 digits long PIN LABEL ANDROID IOS - 6-stellige PIN + sechsstellige PIN now on the card reader! @@ -3989,12 +4517,13 @@ klicken. enter on the card reader! + LABEL ANDROID IOS am Kartenleser eingeben! This is only possible if you have exchanged the 5 digits long transport PIN with a 6 digits long personal PIN beforehand. LABEL ANDROID IOS - Funktioniert nur, wenn Sie Ihre 5-stellige Transport-PIN bereits in Ihre persönliche 6-stellige PIN geändert haben. + Funktioniert nur, wenn Sie Ihre fünfstellige Transport-PIN bereits in Ihre persönliche sechsstellige PIN geändert haben. qrc:///images/tutorial/screenshot_choose_reader_%1_en.png @@ -4023,12 +4552,13 @@ klicken. App on Android smartphone <b>with</b> NFC chip as card reader + LABEL ANDROID App auf Android-Telefon <b>mit</b> NFC-Chip als Kartenleser - Click link on the website of the service provider. + Click link on the website of the provider. LABEL ANDROID IOS - Link auf Webseite des Diensteanbieters klicken. + Link auf Webseite des Anbieters klicken. qrc:///images/tutorial/generated/reader_nfc_userdata_example_en.svg @@ -4055,11 +4585,12 @@ klicken. Weiter zur PIN-Eingabe - ... and place the id card flat onto the NFC interface. + ... and place the ID card flat onto the NFC interface. + LABEL ANDROID ...und platzieren Sie den Ausweis flach an der NFC-Schnittstelle. - Do not move device or id card! + Do not move device or ID card! LABEL ANDROID IOS Gerät und Ausweis nicht bewegen! @@ -4069,12 +4600,13 @@ klicken. Die genaue Position hängt von Ihrem Gerät ab... - https://www.ausweisapp.bund.de/mobile-geraete/ + https://www.ausweisapp.bund.de/en/compatible-devices/mobile-phones-and-tablets/ LABEL ANDROID IOS https://www.ausweisapp.bund.de/mobile-geraete/ To mobile devices + LABEL ANDROID IOS Zu den mobilen Geräten @@ -4084,12 +4616,13 @@ klicken. Now + LABEL ANDROID IOS Jetzt 6 digits long PIN LABEL ANDROID IOS - 6-stellige PIN + sechsstellige PIN now! @@ -4098,23 +4631,29 @@ klicken. enter! + LABEL ANDROID IOS eingeben! This is only possible if you have exchanged the 5 digits long transport PIN with a 6 digits long personal PIN beforehand. LABEL ANDROID IOS - Funktioniert nur, wenn Sie Ihre 5-stellige Transport-PIN bereits in Ihre persönliche 6-stellige PIN geändert haben. + Funktioniert nur, wenn Sie Ihre fünfstellige Transport-PIN bereits in Ihre persönliche sechsstellige PIN geändert haben. App on iPhone <b>with</b> NFC chip as card reader - LABEL ANDROID IOS + LABEL IOS App auf iPhone <b>mit</b> NFC-Chip als Kartenleser - ... and place the top of the iPhone onto the id card. - LABEL ANDROID IOS + ... and place the top of the iPhone onto the ID card. + LABEL IOS ...und platzieren Sie die Oberkante des iPhones auf dem Ausweis. + + You can also watch this YouTube video explaining the process. + LABEL ANDROID IOS + Sie können sich auch dieses YouTube-Video ansehen das den Prozess erläutert. + TutorialReaderMethodSacDesktop @@ -4174,9 +4713,9 @@ klicken. Öffnen Sie nun die App auf dem Computer und gehen auf Einstellungen. - Select the <b>Card Readers</b> tab. + Select the <b>Smartphone as card reader</b> tab. LABEL ANDROID IOS - Den Reiter <b>Kartenleser</b> auswählen. + Den Reiter <b>Smartphone als Kartenleser</b> auswählen. qrc:///images/tutorial/screenshot_pairing_en.png @@ -4184,9 +4723,9 @@ klicken. qrc:///images/tutorial/screenshot_pairing_de.png - Select smartphone from list and click "pair" + Select smartphone from list LABEL ANDROID IOS - Smartphone in der Liste wählen und auf „koppeln“ klicken + Smartphone in der Liste auswählen Enter pairing code next. @@ -4194,9 +4733,9 @@ klicken. Dann Kopplungscode eingeben. - Click link on the website of the service provider. + Click link on the website of the provider. LABEL ANDROID IOS - Link auf Webseite des Diensteanbieters klicken. + Link auf Webseite des Anbieters klicken. qrc:///images/tutorial/generated/reader_nfc_userdata_example_en.svg @@ -4229,7 +4768,7 @@ klicken. qrc:///images/tutorial/generated/where_lay_down_id.svg - Do not move device or id card! + Do not move device or ID card! LABEL ANDROID IOS Gerät und Ausweis nicht bewegen! @@ -4239,12 +4778,13 @@ klicken. Die genaue Position hängt von Ihrem Gerät ab... - https://www.ausweisapp.bund.de/mobile-geraete/ + https://www.ausweisapp.bund.de/en/compatible-devices/mobile-phones-and-tablets/ LABEL ANDROID IOS https://www.ausweisapp.bund.de/mobile-geraete/ To mobile devices + LABEL ANDROID IOS Zu den mobilen Geräten @@ -4255,7 +4795,7 @@ klicken. 6 digits long PIN LABEL ANDROID IOS - 6-stellige PIN + sechsstellige PIN now! @@ -4264,12 +4804,13 @@ klicken. enter! + LABEL ANDROID IOS eingeben! This is only possible if you have exchanged the 5 digits long transport PIN with a 6 digits long personal PIN beforehand. LABEL ANDROID IOS - Funktioniert nur, wenn Sie Ihre 5-stellige Transport-PIN bereits in Ihre persönliche 6-stellige PIN geändert haben. + Funktioniert nur, wenn Sie Ihre fünfstellige Transport-PIN bereits in Ihre persönliche sechsstellige PIN geändert haben. qrc:///images/tutorial/generated/reader_sac_menu_%1_en.svg @@ -4288,18 +4829,24 @@ klicken. Now choose "Remote" in the AusweisApp2 on your smartphone... - LABEL ANDROID IOS + LABEL IOS Öffnen Sie nun in der AusweisApp2 auf dem Smartphone die Ansicht "Fernzugriff"... Now choose "Smartphone as card reader" in the AusweisApp2 on your smartphone... + LABEL ANDROID Öffnen Sie nun in der AusweisApp2 auf dem Smartphone den Bereich "Smartphone als Kartenleser"... - ... and place the id card onto the NFC interface. + ... and place the ID card onto the NFC interface. LABEL ANDROID IOS ...und platzieren Sie den Ausweis auf die NFC-Schnittstelle. + + You can also watch this YouTube video explaining the process. + LABEL ANDROID IOS + Sie können sich auch dieses YouTube-Video ansehen das den Prozess erläutert. + TutorialReaderMethodSacMobile @@ -4350,6 +4897,7 @@ klicken. Now open the AusweisApp2 on your device <b>without</b> NFC and select <b>Smartphone as card reader</b>. + LABEL ANDROID Öffnen Sie nun die AusweisApp2 auf dem Gerät <b>ohne</b> NFC und wählen <b>Smartphone als Kartenleser</b> aus. @@ -4368,9 +4916,9 @@ klicken. Dann Kopplungscode eingeben. - Click link on the website of the service provider on the device <b>without</b> NFC. + Click link on the website of the provider on the device <b>without</b> NFC. LABEL ANDROID IOS - Auf dem Gerät <b>ohne</b> NFC Link auf Webseite des Diensteanbieters klicken. + Auf dem Gerät <b>ohne</b> NFC Link auf Webseite des Anbieters klicken. qrc:///images/tutorial/generated/reader_nfc_userdata_example_en.svg @@ -4408,7 +4956,7 @@ klicken. qrc:///images/tutorial/generated/where_lay_down_id.svg - Do not move device or id card! + Do not move device or ID card! LABEL ANDROID IOS Gerät und Ausweis nicht bewegen! @@ -4418,12 +4966,13 @@ klicken. Die genaue Position hängt von Ihrem Gerät ab... - https://www.ausweisapp.bund.de/mobile-geraete/ + https://www.ausweisapp.bund.de/en/compatible-devices/mobile-phones-and-tablets/ LABEL ANDROID IOS https://www.ausweisapp.bund.de/mobile-geraete/ To mobile devices + LABEL ANDROID IOS Zu den mobilen Geräten @@ -4434,7 +4983,7 @@ klicken. 6 digits long PIN LABEL ANDROID IOS - 6-stellige PIN + sechsstellige PIN now! @@ -4443,12 +4992,13 @@ klicken. enter! + LABEL ANDROID IOS eingeben! This is only possible if you have exchanged the 5 digits long transport PIN with a 6 digits long personal PIN beforehand. LABEL ANDROID IOS - Funktioniert nur, wenn Sie Ihre 5-stellige Transport-PIN bereits in Ihre persönliche 6-stellige PIN geändert haben. + Funktioniert nur, wenn Sie Ihre fünfstellige Transport-PIN bereits in Ihre persönliche sechsstellige PIN geändert haben. qrc:///images/tutorial/generated/reader_sac_menu_%1_en.svg @@ -4457,7 +5007,7 @@ klicken. Now open the AusweisApp2 on your device <b>without</b> NFC and select <b>Configure remote service</b>. - LABEL ANDROID IOS + LABEL IOS Öffnen Sie nun die AusweisApp2 auf dem Gerät <b>ohne</b> NFC und wählen Sie <b>Fernzugriff konfigurieren</b> aus. @@ -4477,15 +5027,16 @@ klicken. Now choose "Remote" in the AusweisApp2 on your smartphone... - LABEL ANDROID IOS + LABEL IOS Öffnen Sie nun in der AusweisApp2 auf dem Smartphone den Bereich "Fernzugriff"... Now choose "Smartphone as card reader" in the AusweisApp2 on your smartphone... + LABEL ANDROID Öffnen Sie nun in der AusweisApp2 auf dem Smartphone den Bereich "Smartphone als Kartenleser"... - ... and place the id card onto the NFC interface. + ... and place the ID card onto the NFC interface. LABEL ANDROID IOS ...und platzieren Sie den Ausweis auf die NFC-Schnittstelle. @@ -4541,9 +5092,9 @@ klicken. gegenseitige Authentifizierung - ... it establishes a secure connection between ID document and service provider. + ... it establishes a secure connection between ID card and provider. LABEL ANDROID IOS - ...sie stellt eine sichere Verbindung zwischen Ausweisdokument und Diensteanbieter her. + ...sie stellt eine sichere Verbindung zwischen Ausweis und Anbieter her. On every authentication you get displayed <b>who</b> wants to access <b>which</b> data @@ -4609,7 +5160,7 @@ klicken. TutorialWhere - On every website of a service provider where you see this icon: + On every website of a provider where you see this icon: LABEL ANDROID IOS Überall, wo Sie auf der Webseite eines Online-Dienstes folgendes Logo sehen: @@ -4640,10 +5191,12 @@ klicken. Now lay down your ID card and place your device on the ID card. + LABEL ANDROID Bitte legen Sie nun Ihren Ausweis hin und Ihr Gerät auf Ihren Ausweis. Don't move your device during the procedure! + LABEL ANDROID Gerät während des gesamten Vorgangs nicht bewegen! @@ -4653,12 +5206,13 @@ klicken. Now + LABEL ANDROID IOS Jetzt 6 digits long PIN LABEL ANDROID IOS - 6-stellige PIN + sechsstellige PIN now! @@ -4667,6 +5221,7 @@ klicken. enter! + LABEL ANDROID IOS eingeben! @@ -4696,15 +5251,91 @@ klicken. Now lay down your ID card and hold the top of your iPhone to the ID card. - LABEL ANDROID IOS + LABEL IOS Legen Sie nun Ihren Ausweis vor sich hin und halten Sie die Oberkante des iPhones an den Ausweis. Don't move your iPhone during the procedure! - LABEL ANDROID IOS + LABEL IOS iPhone während des gesamten Vorgangs nicht bewegen! + + UpdateView + + Application update view + Ansicht der Anwendungsaktualisierung + + + This is the application update panel of the AusweisApp2. + Dies ist die Ansicht zu Aktualisierungen der AusweisApp2. + + + Application update + LABEL DESKTOP_QML + Anwendungsaktualisierung + + + The update information could not be retrieved. Please check your network connection. + LABEL DESKTOP_QML Placext if the update information are invalid, might be caused by network issues. + Die Aktualisierungeninformationen konnten nicht heruntergeladen werden. Bitte überprüfen Sie die Netzwerkverbindung. + + + Your version %1 of %2 is up to date! + LABEL DESKTOP_QML The currently installed version is the most recent one, no action is required. + Ihre Version %1 der %2 ist auf dem aktuellen Stand! + + + An update is available (installed version %1) + Eine Aktualisierung ist verfügbar (installierte Version %1) + + + + UpdateViewButtonRow + + Skip update + LABEL DESKTOP_QML User choice to skip this update, the automatic update check will *not* inform about this update again. + Aktualisierung überspringen + + + Remind me later + LABEL DESKTOP_QML The available update is shown again after next automatic update check. + Später erinnern + + + Download update + LABEL DESKTOP_QML Download the update, opens the download link in the user's default browser. + Aktualisierung herunterladen + + + + UpdateViewInformation + + New version: + LABEL DESKTOP_QML Information about the available, new version number. + Neue Version: + + + Release date: + LABEL DESKTOP_QML Date when the available update was released. + Erscheinungsdatum: + + + Download size: + LABEL DESKTOP_QML Download size of the available update in megabyte. + Größe der Aktualisierung: + + + Download link: + LABEL DESKTOP_QML Plaintext link to the update download. + Link zum Download: + + + Checksum link: + LABEL DESKTOP_QML Link to download checksum to verify the downloaded update file. + Link zur Prüfsumme: + + UpdateWindow @@ -4720,8 +5351,8 @@ klicken. Die Aktualisierungsdatei finden Sie hier: - Release Notes: - Aktualisierungshinweise: + Release notes: + Release Notes: Download this update and close current "AusweisApp2". Install the update and start "AusweisApp2" again. @@ -4733,7 +5364,7 @@ klicken. Skip update - Aktualisierung auslassen + Aktualisierung überspringen Remind me later @@ -4752,13 +5383,14 @@ klicken. Versionsinformationen - Version information + Developer options activated. LABEL DESKTOP_QML - Versionsinformationen + Entwickleroptionen aktiviert. - This is the version information section of the AusweisApp2. - Dies ist die Anzeige der Versionsinformationen der AusweisApp2.. + Developer options deactivated. + LABEL DESKTOP_QML + Entwickleroptionen deaktiviert. @@ -4820,39 +5452,15 @@ klicken. The current release notes can be found %1 here.%2 - Die aktuellen Release-Notes finden Sie %1 hier.%2 + Die aktuellen Release Notes finden Sie %1 hier.%2 About %1 - %2 Über %1 - %2 - - The developer mode is aimed at integrators / developers for new service applications. For this reason, the developer mode works only in the test PKI. By activating the developer mode, some safety tests are deactivated. This means that the authentication process continues although the AusweisApp2 would usually abort the process with an error message when used in normal operation mode. Information on the disregarded error in the developer mode is displayed in the attached window below the AusweisApp2. - Der Entwicklermodus richtet sich an Integratoren / Entwickler für neue Dienste. Aus diesem Grund funktioniert der Entwicklermodus lediglich in der Test-PKI. Durch Aktivierung des Entwicklermodus werden einige Sicherheitsprüfungen abgestellt. Die Authentisierung wird auch dann weitergeführt, wenn die AusweisApp2 im Normalbetrieb die Authentisierung mit einer Fehlermeldung abbrechen würde. Der übergangene Fehler im Entwicklermodus wird im angehängten Fenster unterhalb der AusweisApp2 angezeigt. - governikus::AccessRoleAndRightsUtil - - WRITE_DG17 - LABEL ALL_PLATFORMS - WRITE_DG17 - - - WRITE_DG18 - LABEL ALL_PLATFORMS - WRITE_DG18 - - - WRITE_DG19 - LABEL ALL_PLATFORMS - WRITE_DG19 - - - WRITE_DG20 - LABEL ALL_PLATFORMS - WRITE_DG20 - WRITE_DG21 LABEL ALL_PLATFORMS @@ -4998,6 +5606,26 @@ klicken. LABEL ALL_PLATFORMS Unbekannt + + Write residence permit II + LABEL ALL_PLATFORMS + Schreibrecht Wohnort II + + + Write residence permit I + LABEL ALL_PLATFORMS + Schreibrecht Wohnort I + + + Write community-ID + LABEL ALL_PLATFORMS + Schreibrecht Gemeinde-ID + + + Write address + LABEL ALL_PLATFORMS + Schreibrecht Adresse + governikus::AppQtGui @@ -5055,15 +5683,7 @@ klicken. Did you change the transport PIN already?<br><br>Prior to the first use of the online identification function you have to replace the transport PIN by an individual 6-digit PIN. Online identification with transport PIN is not possible. - Haben Sie Ihre Transport-PIN schon geändert? <br><br>Bevor Sie das erste Mal die Online-Ausweisfunktion nutzen können, müssen Sie Ihre Transport-PIN durch eine persönliche, 6-stellige PIN ersetzen. Die Benutzung der Online-Ausweisfunktion ist mit der Transport-PIN nicht möglich. - - - Switch UI - Grafische Oberfläche wechseln - - - Do you want to switch to the new beta UI? You can switch back to the old UI in "Settings". - Möchten Sie die neue grafische Oberfläche ausprobieren? Sie können in den Einstellungen zur alten Oberfläche zurückwechseln. + Haben Sie Ihre Transport-PIN schon geändert? <br><br>Bevor Sie das erste Mal die Online-Ausweisfunktion nutzen können, müssen Sie Ihre Transport-PIN durch eine persönliche, sechsstellige PIN ersetzen. Die Benutzung der Online-Ausweisfunktion ist mit der Transport-PIN nicht möglich. @@ -5104,8 +5724,8 @@ klicken. ID card (PA/eAT) - ERROR ALL_PLATFORMS An id card is present/inserted. The text is only used in DiagnosisView. - Ausweisdokument (PA/eAT) + ERROR ALL_PLATFORMS An ID card is present/inserted. The text is only used in DiagnosisView. + Ausweis (PA/eAT) Passport @@ -5116,9 +5736,9 @@ klicken. governikus::CertificateDescriptionModel - Service provider + Provider LABEL ALL_PLATFORMS - Diensteanbieter + Anbieter Certificate issuer @@ -5126,9 +5746,9 @@ klicken. Aussteller des Berechtigungszertifikats - Name, address and mail address of the service provider + Name, address and mail address of the provider LABEL ALL_PLATFORMS - Name, Adresse und E-Mail vom Diensteanbieter + Name, Adresse und E-Mail vom Anbieter Purpose @@ -5136,14 +5756,14 @@ klicken. Zweck - Indication of the bodies responsible for the service provider, that verify the compliance with data security regulations + Indication of the bodies responsible for the provider, that verify the compliance with data security regulations LABEL ALL_PLATFORMS - Angabe der für den Diensteanbieter zuständigen Datenschutzaufsicht + Angabe der für den Anbieter zuständigen Datenschutzaufsicht - Service provider information + Provider information LABEL ALL_PLATFORMS - Diensteanbieterinformationen + Anbieterinformationen Validity @@ -5192,15 +5812,22 @@ klicken. governikus::DetailDialog - Service provider data - Angaben zum Diensteanbieter + Provider data + Angaben zum Anbieter governikus::DetailWidget - Service provider details dialog - Dialog mit Details des Diensteanbieters + Provider details dialog + Dialog mit Details des Anbieters + + + + governikus::DeveloperSettingsWidget + + The developer mode is aimed at integrators / developers for new service applications. For this reason, the developer mode works only in the test PKI. By activating the developer mode, some safety tests are deactivated. This means that the authentication process continues although the AusweisApp2 would usually abort the process with an error message when used in normal operation mode. Information on the disregarded error in the developer mode is displayed in the attached window below the AusweisApp2. + Der Entwicklermodus richtet sich an Integratoren / Entwickler für neue Dienste. Aus diesem Grund funktioniert der Entwicklermodus lediglich in der Test-PKI. Durch Aktivierung des Entwicklermodus werden einige Sicherheitsprüfungen abgestellt. Die Authentisierung wird auch dann weitergeführt, wenn die AusweisApp2 im Normalbetrieb die Authentisierung mit einer Fehlermeldung abbrechen würde. Der übergangene Fehler im Entwicklermodus wird im angehängten Fenster unterhalb der AusweisApp2 angezeigt. @@ -5257,7 +5884,7 @@ klicken. No Firewall information available on this platform. - Auf dieser Platform sind keine Firewallinformationen verfügbar. + Auf dieser Plattform sind keine Firewall-Informationen verfügbar. Vendor: %1 @@ -5313,7 +5940,7 @@ klicken. No Antivirus information available on this platform. - Keine Antivirus-Informationen auf dieser Platform verfügbar. + Auf dieser Plattform sind keine Antivirus-Informationen verfügbar. dd.MM.yyyy, hh:mm:ss @@ -5377,7 +6004,7 @@ klicken. No third party firewalls detected - Keine Drittanbieterfirewall erkannt + Keine Drittanbieter-Firewall erkannt Firewalls from third party vendors @@ -5393,7 +6020,7 @@ klicken. Windows firewall rules - Windows-Firewallregeln + Windows-Firewall-Regeln Outgoing AusweisApp2 rule @@ -5407,10 +6034,6 @@ klicken. Incoming AusweisApp2 rule Eingehende AusweisApp2-Regel - - Certificate fingerprint: %1 - Zertifikats-Fingerabdruck: %1 - Last connection: %1 Zuletzt verbunden: %1 @@ -5425,11 +6048,11 @@ klicken. Warning: The current firewall status can be obscured by additional Group Policies on your system, often set by system administrators. - Warnung: Der aktuelle Firewallstatus kann durch zusätzliche Gruppenregeln, die oftmals von Administratoren gesetzt werden, auf Ihrem System verschleiert sein. + Warnung: Der aktuelle Firewall-Status kann durch zusätzliche Gruppenregeln, die oftmals von Administratoren gesetzt werden, auf Ihrem System verschleiert sein. An error occurred while trying to gather firewall information. Please check the log for more information. - Beim Sammeln von Firewallinformationen ist ein Fehler aufgetreten. Bitte konsultieren Sie das Protokoll für weitere Informationen. + Beim Sammeln von Firewall-Informationen ist ein Fehler aufgetreten. Bitte konsultieren Sie das Protokoll für weitere Informationen. No Antivirus software detected. @@ -5443,13 +6066,9 @@ klicken. PC/SC information PC/SC Informationen - - Paired remote devices - Gekoppelte Netzwerkgeräte - Antivirus information - Antivirusinformationen + Antivirus-Informationen Firewall information @@ -5471,10 +6090,6 @@ klicken. Unknown address: %1 Unbekannte Adresse: %1 - - Interface: "%1" - Schnittstelle: %1 - No proxy found Kein Proxy erkannt @@ -5511,6 +6126,18 @@ klicken. Antivirus and firewall Antivirus und Firewall + + PC/SC driver information + PC/SC Treiber-Informationen + + + Paired smartphones + Gekoppelte Smartphones + + + Version + Version + governikus::DiagnosisTreeModel @@ -5560,11 +6187,11 @@ klicken. No Antivirus information available on this platform. - Keine Antivirus-Informationen auf dieser Platform verfügbar. + Auf dieser Plattform sind keine Antivirus-Informationen verfügbar. No Firewall information available on this platform. - Auf dieser Platform sind keine Firewallinformationen verfügbar. + Auf dieser Plattform sind keine Firewall-Informationen verfügbar. Vendor: %1 @@ -5728,7 +6355,7 @@ klicken. No third party firewalls detected - Keine Drittanbieterfirewall erkannt + Keine Drittanbieter-Firewall erkannt Firewalls from third party vendors @@ -5744,7 +6371,7 @@ klicken. Windows firewall rules - Windows-Firewallregeln + Windows-Firewall-Regeln Outgoing AusweisApp2 rule @@ -5764,11 +6391,11 @@ klicken. Warning: The current firewall status can be obscured by additional Group Policies on your system, often set by system administrators. - Warnung: Der aktuelle Firewallstatus kann durch zusätzliche Gruppenregeln, die oftmals von Administratoren gesetzt werden, auf Ihrem System verschleiert sein. + Warnung: Der aktuelle Firewall-Status kann durch zusätzliche Gruppenregeln, die oftmals von Administratoren gesetzt werden, auf Ihrem System verschleiert sein. An error occurred while trying to gather firewall information. Please check the log for more information. - Beim Sammeln von Firewallinformationen ist ein Fehler aufgetreten. Bitte konsultieren Sie das Protokoll für weitere Informationen. + Beim Sammeln von Firewall-Informationen ist ein Fehler aufgetreten. Bitte konsultieren Sie das Protokoll für weitere Informationen. @@ -5864,9 +6491,9 @@ klicken. Die Erzeugung eines Schlüssels für das Signaturzertifikat war nicht möglich. - The process was cancelled by the user. + The process has been cancelled. LABEL ALL_PLATFORMS - Der Benutzer hat den Vorgang abgebrochen. + Der Vorgang wurde abgebrochen. One or more certificate checks failed. The operation will be aborted due to security reasons. @@ -5874,14 +6501,14 @@ klicken. Eine oder mehrere Zertifikatsprüfungen schlugen fehl. Der Vorgang wird aus Sicherheitsgründen abgebrochen. - This action cannot be performed. The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function. + This action cannot be performed. The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function. LABEL ALL_PLATFORMS - Diese Aktion kann leider nicht durchgeführt werden. Die Online-Ausweisfunktion Ihres Ausweisdokuments ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. + Diese Aktion kann leider nicht durchgeführt werden. Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihren Ausweis ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. The authenticity of your ID card could not be verified. Please make sure that you are using a genuine ID card. Please note that test applications require the use of a test ID card. LABEL ALL_PLATFORMS - Die Echtheit Ihres Ausweisdokuments konnte nicht überprüft werden. Bitte stellen Sie sicher, dass Sie ein echtes Ausweisdokument verwenden. Bitte beachten Sie, dass Sie bei Testanwendungen einen Testausweis verwenden müssen. + Die Echtheit Ihres Ausweises konnte nicht überprüft werden. Bitte stellen Sie sicher, dass Sie einen echten Ausweis verwenden. Bitte beachten Sie, dass Sie bei Testanwendungen einen Testausweis verwenden müssen. The age verification failed. @@ -5896,7 +6523,7 @@ klicken. The ID card is invalid or disabled. LABEL ALL_PLATFORMS - Das Ausweisdokument ist ungültig oder gesperrt. + Der Ausweis ist ungültig oder gesperrt. @@ -5914,12 +6541,12 @@ klicken. The connection to the ID card has been lost. The process was aborted. ERROR ALL_PLATFORMS The card was removed after the PACE channel was established. - Die Verbindung zum Ausweisdokument wurde unterbrochen. Der Vorgang wird abgebrochen. + Die Verbindung zum Ausweis wurde unterbrochen. Der Vorgang wird abgebrochen. The authenticity of your ID card could not be confirmed. ERROR ALL_PLATFORMS The certificates supplied by the card did not pass the authenticity check, further operation is not allowed. - Die Echtheit Ihres Ausweisdokuments konnte nicht bestätigt werden. + Die Echtheit Ihres Ausweises konnte nicht bestätigt werden. The program received an unknown message from the server. @@ -5948,7 +6575,7 @@ klicken. Authentication failed. - ERROR ALL_PLATFORMS DidAuthenticateEAC2, AA2 or the id card declined the certificates. + ERROR ALL_PLATFORMS DidAuthenticateEAC2, AA2 or the ID card declined the certificates. Die Authentisierung ist fehlgeschlagen. @@ -5977,19 +6604,14 @@ klicken. Die Anwendung hat einen Fehler vom Server erhalten. - Received no data. + The TCToken contained no data. ERROR_MASKED ALL_PLATFORMS Received an empty TC token. - Keine Daten erhalten. + Das TCToken enthielt keine Daten. - Cannot start authentication. An operation is already in progress. + Cannot start authentication. An operation is already active. ERROR ALL_PLATFORMS An ActivationHandler is requested even though an operation is currently still running. - Die Authentisierung kann nicht gestartet werden. Es läuft bereits eine Operation. - - - After three wrong entries your PIN is blocked. Please use the PIN management in this app to unblock it with the help of your PUK. - ERROR ALL_PLATFORMS The id card was blocked after three wrongfully entered PINs, the PUK is required to unlock the card. Hint to do so in the PIN management section of the app. - Ihre PIN ist nach dreimaliger Fehleingabe gesperrt. Verwenden Sie die PIN-Verwaltung dieser App, um diese mit Ihrer PUK zu entsperren. + Der Ausweisvorgang kann nicht gestartet werden. Ein anderer Vorgang ist bereits aktiv. Using the developer mode is only allowed in a test environment. @@ -6027,9 +6649,9 @@ klicken. Die Anwendung wurde mit den falschen Parametern aufgerufen. - An unknown network error occurred. - ERROR_MASKED ALL_PLATFORMS Other critial network error by Qt. - Ein unbekannter Netzwerkfehler ist aufgetreten. + An unknown network error occurred. Check your network connection and try to restart the app. + ERROR ALL_PLATFORMS Other critial network error by Qt. + Ein unbekannter Netzwerkfehler ist aufgetreten. Überprüfen Sie Ihre Netwerkverbindung und versuchen Sie die App neu zu starten. The selected card reader cannot be accessed anymore. @@ -6042,9 +6664,9 @@ klicken. Der Server lieferte keine oder nur unvollständige Informationen. Ihre persönlichen Daten konnten nicht ausgelesen werden. - Error while connecting to the service provider. The SSL connection uses an unsupported key algorithm or length. + Error while connecting to the provider. The TLS connection uses an unsupported key algorithm or length. ERROR_MASKED ALL_PLATFORMS - Fehler bei der Verbindung mit dem Diensteanbieter. Der Verschlüsselungsalgorithmus oder die Länge des Schlüssels der SSL-Verbindung wird nicht unterstützt. + Fehler bei der Verbindung mit dem Anbieter. Der Verschlüsselungsalgorithmus oder die Länge des Schlüssels der TLS-Verbindung wird nicht unterstützt. Empty redirect URL @@ -6067,9 +6689,9 @@ klicken. Nicht wohlgeformte Redirect-URL: %1 - The process was cancelled by the user. + The process has been cancelled. ERROR ALL_PLATFORMS The user cancelled the authentication in either the UI or the card reader. - Der Benutzer hat den Vorgang abgebrochen. + Der Vorgang wurde abgebrochen. The maximum time was exceeded during input process. @@ -6078,52 +6700,52 @@ klicken. Card does not exist - ERROR ALL_PLATFORMS Internal error, either PCSC, SaK or card reader could not find the id card. + ERROR ALL_PLATFORMS Internal error, either PCSC, SaK or card reader could not find the ID card. Karte nicht vorhanden An error occurred while communicating with the ID card. Please make sure that your ID card is placed correctly on the card reader and try again. ERROR ALL_PLATFORMS Communication with the card failed due to the specification of the TR (Technische Richtlinie), - Bei der Kommunikation mit dem Ausweisdokument ist ein Fehler aufgetreten. Bitte überprüfen Sie, dass das Ausweisdokument korrekt aufgelegt ist und versuchen Sie es erneut. + Bei der Kommunikation mit dem Ausweis ist ein Fehler aufgetreten. Bitte überprüfen Sie, dass der Ausweis korrekt aufgelegt ist und versuchen Sie es erneut. A protocol error occurred. Please make sure that your ID card is placed correctly on the card reader and try again. If the problem occurs again, please contact our support at ERROR ALL_PLATFORMS Communication with the card failed due to the specification of the TR (Technische Richtlinie). The protocol was faulty or invalid values were requested/received, - Ein Protokollfehler ist aufgetreten. Bitte überprüfen Sie, dass das Ausweisdokument korrekt aufgelegt ist und versuchen Sie es erneut. Wenn das Problem wieder auftritt kontaktieren Sie bitte unseren Support unter + Ein Protokollfehler ist aufgetreten. Bitte überprüfen Sie, dass der Ausweis korrekt aufgelegt ist und versuchen Sie es erneut. Wenn das Problem wieder auftritt kontaktieren Sie bitte unseren Support unter AusweisApp2 Support AusweisApp2 Support - The given PIN is invalid. - ERROR ALL_PLATFORMS The id card declined the PIN. - Die eingegebene PIN ist ungültig. + The given PIN is not correct. + ERROR ALL_PLATFORMS The ID card declined the PIN. + Die eingegebene PIN ist nicht korrekt. - The given card access number (CAN) is invalid. - ERROR ALL_PLATFORMS The id card declined the CAN. - Die eingegebene Zugangsnummer (CAN) ist ungültig. + The given card access number (CAN) is not correct. + ERROR ALL_PLATFORMS The ID card declined the CAN. + Die eingegebene Zugangsnummer (CAN) ist nicht korrekt. - The given PUK is invalid. - ERROR ALL_PLATFORMS The id card declined the PUK. - Die eingegebene PUK ist ungültig. + The given PUK is not correct. + ERROR ALL_PLATFORMS The ID card declined the PUK. + Die eingegebene PUK ist nicht korrekt. The PIN was blocked after too many unsuccessful attempts. - ERROR ALL_PLATFORMS The id card refused the PIN since the PIN feature is blocked after too many wrong attemps. + ERROR ALL_PLATFORMS The ID card refused the PIN since the PIN feature is blocked after too many wrong attemps. Die PIN ist nach zu vielen Fehlversuchen gesperrt. The PIN is not blocked. - ERROR ALL_PLATFORMS It was attempted to unlock the id card via PUK even though it was not locked in the first place. This scenario is avoided in the UI by hiding the respective UI elements. + ERROR ALL_PLATFORMS It was attempted to unlock the ID card via PUK even though it was not locked in the first place. This scenario is avoided in the UI by hiding the respective UI elements. Die PIN ist nicht gesperrt. - The PUK was used ten times and is set inoperative. Please contact the competent authority that issued your ID document to unlock the PIN. - ERROR ALL_PLATFORMS The card declined the PUK since it was entered wrongfully 10 times, the local authorities have to be contacted to unlock the id card. - Die eingegebene PUK wurde zehn Mal verwendet und ist außer Betrieb. Bitte kontaktieren Sie die für die Ausgabe Ihres Ausweisdokuments zuständige Behörde um Ihre PIN zu entsperren. + The PUK was used ten times and can not be used anymore to unblock the PIN. Please contact the competent authority that issued your ID card to unblock the PIN. + ERROR ALL_PLATFORMS The card declined the PUK since it was entered wrongfully 10 times, the local authorities have to be contacted to unlock the ID card. + Die eingegebene PUK wurde zehn Mal verwendet und kann nicht mehr verwendet werden, um die PIN zu entsperren. Bitte kontaktieren Sie die für die Ausgabe Ihres Ausweises zuständige Behörde um Ihre PIN zu entsperren. The new PIN and the confirmation do not match. @@ -6136,44 +6758,44 @@ klicken. Die neue PIN hat eine ungültige Länge. - An error occurred while connecting to a reader device. + An error occurred while connecting to a bluetooth card reader. ERROR ALL_PLATFORMS Error while connecting to a bluetooth card reader. - Es ist ein Fehler während des Verbindungsaufbaus zu einem Kartenleser aufgetreten. + Es ist ein Fehler während des Verbindungsaufbaus zu einem Bluetooth-Kartenleser aufgetreten. - An error occurred while scanning for reader devices. + An error occurred while scanning for a bluetooth card reader. ERROR ALL_PLATFORMS Error while searching for bluetooth card reader. - Es ist ein Fehler während der Suche nach einem Kartenleser aufgetreten. + Es ist ein Fehler während der Suche nach einem Bluetooth-Kartenleser aufgetreten. - The remote card reader connection was not closed properly. + The smartphone as card reader (SaC) connection was aborted. ERROR ALL_PLATFORMS The connection to the smartphone card reader (SaK) was lost. - Die Verbindung zum Remote-Lesegerät wurde abgebrochen. + Die Verbindung zum Smartphone als Kartenleser wurde abgebrochen. - Remote reader connection request contains invalid parameters. + Smartphone as card reader (SaC) connection request was invalid. ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) was invalid (missing device ID). - Die Verbindungsanforderung zum entfernten Kartenleser enthält einen ungültigen Parameter. + Die Verbindungsanforderung zum Smartphone als Kartenleser (SaK) war fehlerhaft. - Your remote reader version is incompatible with the local version. Please install the latest AusweisApp2 version on both your smartphone and your computer. + Your smartphone as card reader (SaC) version is incompatible with the local version. Please install the latest AusweisApp2 version on both your smartphone and your computer. ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) was invalid (API mismatch). - Die Version Ihres Smartphones als Kartenleser ist inkompatibel. Bitte aktualisieren Sie Ihre Installation. + Die Version Ihres Smartphones als Kartenleser (SaK) ist inkompatibel. Bitte aktualisieren Sie Ihre Installation. - A timeout occurred while trying to establish a connection to a remote reader. + A timeout occurred while trying to establish a connection to the smartphone as card reader (SaC). ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) timed out. - Bei der Verbindung zum entfernten Kartenleser kam es zu einer Zeitüberschreitung. + Bei der Verbindung zum Smartphone als Kartenleser (SaK) kam es zu einer Zeitüberschreitung. - An error occurred while trying to establish a connection to a remote reader. + An error occurred while trying to establish a connection to the smartphone as card reader (SaC). ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) failed due to network errors (Host not found, OS error, ...) - Bei der Verbindung zum entfernten Kartenleser ist ein Fehler aufgetreten. + Bei der Verbindung zum Smartphone als Kartenleser (SaK) ist ein Fehler aufgetreten. - Remote device has rejected the connection. Please check the pairing code. + The smartphone to be paired has rejected the connection. Please check the pairing code. If no pairing code is shown activate the pairing mode. ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) was rejected by the device. - Das zu koppelnde Gerät hat die Verbindung verweigert. Überprüfen Sie bitte den Kopplungscode. + Das zu koppelnde Smartphone hat die Verbindung verweigert. Überprüfen Sie bitte den Kopplungscode. Sollte kein Kopplungscode angezeigt werden aktivierten Sie bitte den Kopplungsmodus. File not found. @@ -6191,24 +6813,24 @@ klicken. Die empfangenen Daten waren beschädigt. - Hash of certificate not in certificate description (issuer: %1). This indicates a misconfiguration or manipulation of the certificate. Please check that your antivirus-software and firewalls are not interfering with SSL traffic. + Hash of TLS certificate not in certificate description (issuer: %1). This indicates a misconfiguration or manipulation of the certificate. Please check that your antivirus-software and firewalls are not interfering with TLS traffic. ERROR ALL_PLATFORMS The TLS certificate was not folded with the Authorization Certificate, thus violating the security requirements. Might also be caused by a firewall and/or the antivirus software. - Der Hashwert des Zertifikats ist nicht in der Zertifikatsbeschreibung vorhanden (Aussteller: %1). Dies deutet auf eine Fehlkonfiguration oder Manipulation des Zertifikats hin. Bitte überprüfen Sie, dass weder eine Antivirus-Software noch eine Firewall in den SSL-Verkehr eingreifen. + Der Hashwert des TLS-Zertifikats ist nicht in der Zertifikatsbeschreibung vorhanden (Aussteller: %1). Dies deutet auf eine Fehlkonfiguration oder Manipulation des Zertifikats hin. Bitte überprüfen Sie, dass weder eine Antivirus-Software noch eine Firewall in den TLS-Verkehr eingreifen. - Error while connecting to the server. The SSL certificate uses an unsupported key algorithm or length. Certificate issuer: %1 + Error while connecting to the server. The TLS certificate uses an unsupported key algorithm or length. Certificate issuer: %1 ERROR ALL_PLATFORMS Received a TLS certificate that uses an invalid algorithm or key length. - Fehler bei der Verbindung zum Server. Der Verschlüsselungsalgorithmus oder die Länge des Schlüssels im SSL-Zertifikat des Servers wird nicht unterstützt. Zertifikatsaussteller: %1 + Fehler bei der Verbindung zum Server. Der Verschlüsselungsalgorithmus oder die Länge des Schlüssels im TLS-Zertifikat des Servers wird nicht unterstützt. Zertifikatsaussteller: %1 - An error occurred. Please contact our %1support%2. + A secure connection to the provider could not be established. Please contact our %1support%2. ERROR ANDROID IOS Error message which is used for "masked" errors. Generic message with link to support section of the homepage. - Ein Fehler ist aufgetreten. Bitte kontaktieren Sie unseren %1Support%2. + Eine sichere Verbindung zum Anbieter konnte nicht aufgebaut werden. Bitte kontaktieren Sie unseren %1Support%2. - An error occurred. Please contact our %1support%2 or feel free to send us an email. + A secure connection to the provider could not be established. Please contact our %1support%2 or feel free to send us an email. ERROR DESKTOP Error message which is used for "masked" errors. Generic message with link to support section of the homepage. - Ein Fehler ist aufgetreten. Bitte kontaktieren Sie unseren %1Support%2 oder senden Sie uns eine E-Mail. + Eine sichere Verbindung zum Anbieter konnte nicht aufgebaut werden. Bitte kontaktieren Sie unseren %1Support%2 oder senden Sie uns eine E-Mail. https://www.ausweisapp.bund.de/en/qa/support/ @@ -6244,7 +6866,7 @@ klicken. You have correctly entered the PUK ten times and have thus reached the maximum count. The PUK is now inoperative and can no longer be used for unblocking the PIN. Please address your competent authority that has issued your ID card for unblocking your PIN. - Sie haben die PUK zehn Mal korrekt eingegeben und damit die maximale Anzahl erreicht. Die PUK ist daher außer Betrieb und kann nicht mehr zum Entsperren der PIN verwendet werden. Bitte wenden Sie sich zum Entsperren der PIN an die zuständige Behörde, die Ihr Ausweisdokument ausgegeben hat. + Sie haben die PUK zehn Mal korrekt eingegeben und damit die maximale Anzahl erreicht. Die PUK ist daher außer Betrieb und kann nicht mehr zum Entsperren der PIN verwendet werden. Bitte wenden Sie sich zum Entsperren der PIN an die zuständige Behörde, die Ihren Ausweis ausgegeben hat. Wrong PIN @@ -6264,19 +6886,19 @@ klicken. After three wrong entries your PIN is blocked. Using the online identification function is no longer possible. <br/>You can unblock the PIN as follows:<ol><li> Select the "Settings" function.</li><li>Select the "PIN Management" tab. </li><li>Follow the instructions on the screen.</li></ol>Note: You will find the PUK in the letter you received during the application for the ID card in the "Unblocking key PUK" section. Further information is available on the site <a href="http://www.personalausweisportal.de">http://www.personalausweisportal.de</a>.<br>Do you want to unblock the PIN now? - Sie haben Ihre PIN dreimal falsch eingegeben. Die Online-Ausweisfunktion ist jetzt blockiert. Die Blockierung können Sie mit Ihrer Entsperrnummer (PUK) aufheben. Sie finden Ihre PUK in dem Schreiben, das Sie nach Beantragung Ihres Ausweisdokuments von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde erhalten haben. Bitte beachten Sie: Sie können mit Ihrer PUK lediglich Ihren Online-Ausweis entsperren. Sollten Sie Ihre PIN vergessen haben, können Sie von der für die Ausgabe Ihres Ausweisdokuments zuständigen Behörde eine neue PIN setzen lassen.<br>Wollen Sie die Blockierung nun aufheben? + Sie haben Ihre PIN dreimal falsch eingegeben. Die Online-Ausweisfunktion ist jetzt blockiert. Die Blockierung können Sie mit Ihrer Entsperrnummer (PUK) aufheben. Sie finden Ihre PUK in dem Schreiben, das Sie nach Beantragung Ihres Ausweises von der für die Ausgabe Ihres Ausweises zuständigen Behörde erhalten haben. Bitte beachten Sie: Sie können mit Ihrer PUK lediglich Ihren Online-Ausweis entsperren. Sollten Sie Ihre PIN vergessen haben, können Sie von der für die Ausgabe Ihres Ausweises zuständigen Behörde eine neue PIN setzen lassen.<br>Wollen Sie die Blockierung nun aufheben? The given PIN is not correct. You have 2 remaining tries to enter the correct PIN. Die eingegebene PIN ist nicht korrekt. Sie haben noch 2 weitere Versuche die korrekte PIN einzugeben. - PIN successfully unblocked - PIN erfolgreich entsperrt + You have successfully unblocked your PIN + Sie haben Ihre PIN erfolgreich entsperrt Your ID card is unblocked. You now have three more tries to change your PIN - Ihr Ausweisdokument wurde entsperrt. Sie haben nun drei weitere Versuche um Ihre PIN zu ändern + Ihr Ausweis wurde entsperrt. Sie haben nun drei weitere Versuche um Ihre PIN zu ändern @@ -6306,7 +6928,7 @@ klicken. Provider - Diensteanbieter + Anbieter Purpose @@ -6339,19 +6961,19 @@ klicken. The connection to the ID card has been lost. The process was aborted. ERROR IOS The card was removed during the communication. - Die Verbindung zum Ausweisdokument wurde unterbrochen. Der Vorgang wird abgebrochen. + Die Verbindung zum Ausweis wurde unterbrochen. Der Vorgang wird abgebrochen. The connection could not be established. The process was aborted. ERROR IOS The connection to the card could not be established. - Die Verbindung zum Ausweisdokument konnte nicht hergestellt werden. Der Vorgang wird abgebrochen. + Die Verbindung zum Ausweis konnte nicht hergestellt werden. Der Vorgang wird abgebrochen. governikus::IosReaderDelegate Please place your device on your ID card. - INFO IOS The id card may be inserted, the authentication process may be started. + INFO IOS The ID card may be inserted, the authentication process may be started. Bitte platzieren Sie Ihr Gerät über Ihrem Personalausweis. @@ -6393,12 +7015,12 @@ klicken. Die Datei ist größer als 3MB und kann nicht angezeigt werden: - Delete log files - Protokolle löschen + Delete logfiles + Prokolldateien löschen - Do you really want to delete all old log files? - Wolle Sie wirklich alle alten Protokolle löschen? + Do you really want to delete all old logfiles? + Wollen Sie wirklich alle alten Protokolle löschen? @@ -6439,7 +7061,7 @@ klicken. <Bitte beschreiben Sie den Fehler> - Mobile log file + Mobile logfile Mobile Protokolldatei @@ -6462,24 +7084,24 @@ klicken. Die eingegebene PIN ist nicht korrekt. Sie haben noch 2 weitere Versuche die korrekte PIN einzugeben. - You have entered the wrong PIN twice. Prior to a third attempt, you have to enter your six-digit card access number first. You can find your card access number on the front of your ID card. + A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card. INFO ALL_PLATFORMS The wrong PIN was entered twice, the next attempt requires the CAN for additional verification. - Sie haben Ihre PIN zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher Ihre 6-stellige Zugangsnummer eingeben. Sie finden Ihre Zugangsnummer auf der Vorderseite Ihres Ausweises. + Die PIN Ihres Ausweises wurde zweimal falsch eingegeben. Für einen dritten Versuch müssen Sie vorher die sechsstellige Zugangsnummer (CAN) eingeben. Diese finden Sie auf der Vorderseite Ihres Ausweises. - You have entered a wrong PIN three times. Your PIN is now blocked. You have to enter the PUK now for unblocking. - INFO ALL_PLATFORMS The PIN was entered wrongfully three times, the id card needs to be unlocked using the PUK. - Sie haben Ihre PIN dreimal falsch eingegeben. Ihre PIN ist jetzt gesperrt. Zum Entsperren geben Sie bitte Ihre PUK ein. + A wrong PIN has been entered three times on your ID card. Your PIN is now blocked. To unblock your PIN you have to enter the PUK. + INFO ALL_PLATFORMS The PIN was entered wrongfully three times, the ID card needs to be unlocked using the PUK. + Die PIN Ihres Ausweises wurde dreimal falsch eingegeben. Ihre PIN ist gesperrt. Zum Entsperren geben Sie bitte Ihre PUK ein. - You have entered a wrong CAN, please try again. + The entered card access number (CAN) is incorrect. Please try again. INFO ALL_PLATFORMS The CAN was entered wrongfully and needs to be supplied again. - Sie haben eine falsche CAN eingegeben. Bitte versuchen Sie es erneut. + Die eingegebene Zugangsnummer (CAN) ist nicht korrekt. Bitte versuchen Sie es erneut. - You have entered a wrong PUK. Please try again. + The entered PUK is incorrect. Please try again. INFO ALL_PLATFORMS The PUK entered wrongfully and needs to be supplied again. - Sie haben eine falsche PUK eingegeben. Bitte versuchen Sie es erneut. + Die eingegebene PUK ist nicht korrekt. Bitte versuchen Sie es erneut. @@ -6515,7 +7137,7 @@ klicken. Provider: LABEL ALL_PLATFORMS - Diensteanbieter: + Anbieter: Purpose: @@ -6560,7 +7182,7 @@ klicken. At %1 %2 the following data has been read out of your ID card: LABEL ALL_PLATFORMS - Die folgenden Daten wurden hier %1 %2 aus Ihrem Ausweisdokument ausgelesen: + Die folgenden Daten wurden hier %1 %2 aus Ihrem Ausweis ausgelesen: Information @@ -6676,7 +7298,7 @@ klicken. Wählen Sie einen Kartenleser aus, um mehr Informationen zu erhalten - Please start pairing mode first. + Start the pairing mode on your smartphone if you haven't done it already. Starten Sie den Kopplungsmodus auf Ihrem Smartphone, falls noch nicht geschehen. @@ -6793,9 +7415,9 @@ klicken. Online-Hilfe - No smartphone with enabled remote service found. See %1 for details of use. + No smartphone as card reader (Sac) available. Please make sure to activate the "remote service" on your smartphone and to connect both devices to the same WiFi. See %1 for details of use. INFO ALL_PLATFORMS No smartphone with enabled remote service was found on the same network. - Kein Smartphone mit aktiviertem Fernzugriff gefunden. Informationen zur Verwendung befinden sich unter %1. + Kein Smartphone als Kartenleser verfügbar. Bitte stellen Sie sicher, dass die die Funktion "Fernzugriff" in der AusweisApp2 auf Ihrem Smartphone aktiviert ist und beide Geräte mit demselben WLAN verbunden sind. Informationen zur Verwendung befinden sich unter %1. @@ -6835,9 +7457,9 @@ klicken. governikus::RemoteServiceSettings - Remote Reader + Smartphone as card reader (SaC) LABEL ALL_PLATFORMS - Entfernter Kartenleser + Smartphone als Kartenleser (SaK) @@ -6919,8 +7541,8 @@ klicken. Als PDF speichern... - save id card data as pdf - Daten des Ausweisdokuments als PDF speichern + save ID card data as pdf + Daten des Ausweises als PDF speichern AusweisApp2.Information.%1.pdf @@ -6939,7 +7561,7 @@ klicken. governikus::SelfInformationWidget Use the button 'See my personal data now...' to display the data stored on your ID card. An Internet connection is required to display the data. - Über die Schaltfläche 'Meine Daten einsehen' können Sie sich die im Chip Ihres Ausweisdokuments gespeicherten Daten anzeigen lassen. Um die Daten anzeigen zu können, benötigt diese Anwendung eine Internetverbindung. + Über die Schaltfläche 'Meine Daten einsehen' können Sie sich die im Chip Ihres Ausweises gespeicherten Daten anzeigen lassen. Um die Daten anzeigen zu können, benötigt diese Anwendung eine Internetverbindung. https://www.ausweisapp.bund.de/datenschutz/ @@ -6964,10 +7586,6 @@ klicken. Apply Übernehmen - - Developer Settings - Entwicklereinstellungen - Apply settings? Einstellungen übernehmen? @@ -6980,6 +7598,10 @@ klicken. OK OK + + Developer options + Entwickleroptionen + governikus::SetupAssistantWizard @@ -7027,18 +7649,18 @@ klicken. Almost done! Fast fertig! - - Personal 6 - digit PIN - Persönliche 6-stellige PIN - Prior to the first use of the online identification function, you have to replace the transport PIN by an individual 6-digit PIN. The transport PIN was sent to you by postal mail. - Vor der ersten Nutzung der Online-Ausweisfunktion müssen Sie die Transport-PIN durch eine persönliche 6-stellige PIN ersetzen. Sie finden Ihre Transport-PIN in dem PIN-Brief, welcher Ihnen postalisch zugesandt wurde. + Vor der ersten Nutzung der Online-Ausweisfunktion müssen Sie die Transport-PIN durch eine persönliche sechsstellige PIN ersetzen. Sie finden Ihre Transport-PIN in dem PIN-Brief, welcher Ihnen postalisch zugesandt wurde. AusweisApp2 is now ready for use. For more information on the software or the online identification function, visit the %1online help%2. Sie können die AusweisApp2 nun verwenden. Weitere Informationen zur Software und der Online-Ausweisfunktion erhalten Sie in der %1Online-Hilfe%2. + + Personal 6-digit PIN + Persönliche sechsstellige PIN + governikus::StateChangePin @@ -7051,24 +7673,24 @@ klicken. governikus::StateCheckRefreshAddress - Sending data to service provider + Sending data to provider INFO ALL_PLATFORMS Status message after the communication between card and server is completed, the result is being forwarded to the provider. - Sende Daten an den Diensteanbieter + Daten werden an den Anbieter gesendet governikus::StateConnectCard - The online identification function is disabled. - Die Online-Ausweisfunktion ist deaktiviert. + The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function. + Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihren Ausweis ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. governikus::StateDidAuthenticateEac1 - Service provider is being verified + Provider is being verified INFO ALL_PLATFORMS Status message after the PIN was entered, Terminal Authentication. - Diensteanbieter wird geprüft + Anbieter wird geprüft @@ -7099,7 +7721,7 @@ klicken. Preparing results INFO ALL_PLATFORMS Status message after the authentication was completed, the results are prepared for the user, mainly relevant for the self authentication since it takes some more time. - Bereite Ergebnisse auf + Ergebnisse werden vorbereitet @@ -7110,7 +7732,7 @@ klicken. You may now remove your ID card from the card reader. - Sie können nun Ihr Ausweisdokument vom Kartenleser entfernen. + Sie können nun Ihren Ausweis vom Kartenleser entfernen. @@ -7148,10 +7770,6 @@ klicken. please enter your pin bitte geben sie ihre pin ein - - CAN: - CAN: - Identify Ausweisen @@ -7160,10 +7778,6 @@ klicken. Identification successful Ausweisen erfolgreich - - The process was cancelled by the user - Der Benutzer hat den Vorgang abgebrochen - Result Ergebnis @@ -7173,32 +7787,20 @@ klicken. Bitte beachten Sie die Anzeige auf Ihrem Kartenleser. - Please enter the six-digit card access number (CAN) for identification. - Bitte geben Sie Ihre 6-stellige Zugangsnummer (CAN) ein. - - - Please enter your six-digit card access number (CAN) and your PIN for identification. - Bitte geben Sie Ihre 6-stellige Zugangsnummer (CAN) und Ihre PIN ein, um sich auszuweisen. - - - Please enter your six digit PIN for identification - Bitte geben Sie Ihre 6-stellige PIN ein, um sich auszuweisen - - - Service provider: - Diensteanbieter: + Provider: + Anbieter: Certificate issuer: Aussteller des Berechtigungszertifikats: - Information on the service provider who wants to read out data from your ID card is given here. For further information press the button "more...". - Hier erhalten Sie Informationen über den Diensteanbieter, der die Daten aus Ihrem Personalausweis auslesen möchte. Für weitere Informationen drücken Sie bitte die Schaltfläche "mehr...". + Information on the provider who wants to read out data from your ID card is given here. For further information press the button "more...". + Hier erhalten Sie Informationen über den Anbieter, der die Daten aus Ihrem Personalausweis auslesen möchte. Für weitere Informationen drücken Sie bitte die Schaltfläche "mehr...". - Here you can select or deselect data fields to be read out. Mandatory data fields required by the service provider cannot be deselected. - Hier können Sie die Datenfelder an/abwählen, die ausgelesen werden sollen. Felder, die Sie nicht abwählen können, sind durch den Diensteanbieter als Pflichtfelder festgelegt worden. Diese Felder sind daher nicht abwählbar. + Here you can select or deselect data fields to be read out. Mandatory data fields required by the provider cannot be deselected. + Hier können Sie die Datenfelder an/abwählen, die ausgelesen werden sollen. Felder, die Sie nicht abwählen können, sind durch den Anbieter als Pflichtfelder festgelegt worden. Diese Felder sind daher nicht abwählbar. Close @@ -7220,6 +7822,22 @@ klicken. Identify now Jetzt ausweisen + + Please enter the 6-digit card access number (CAN) for identification. + Bitte geben Sie Ihre sechsstellige Zugangsnummer (CAN) ein. + + + Please enter your 6-digit card access number (CAN) and your PIN for identification. + Bitte geben Sie Ihre sechstellige Zugangsnummer (CAN) und Ihre PIN ein, um sich auszuweisen. + + + Please enter your 6-digit PIN for identification + Bitte geben Sie Ihre sechsstellige PIN ein, um sich auszuweisen + + + The process has been cancelled + Der Vorgang wurde abgebrochen + governikus::StepChooseCardGui @@ -7252,40 +7870,40 @@ klicken. Extended Length wird nicht überstützt. - Your remote reader does not meet the technical requirements (Extended Length not supported). - Ihr entfernter Kartenleser erfüllt leider nicht die technischen Voraussetzungen (Extended Length wird nicht unterstützt). + Your smartphone as card reader (SaC) does not meet the technical requirements (Extended Length not supported). + Ihr Smartphone als Kartenleser (SaK) erfüllt leider nicht die technischen Voraussetzungen (Extended Length wird nicht unterstützt). At least one of your card readers does not meet the technical requirements (Extended Length not supported). Please place the ID card on a different card reader. Mindestens einer Ihrer Kartenleser erfüllt leider nicht die technischen Voraussetzungen (Extended Length wird nicht unterstützt). Bitte platzieren Sie Ihren Ausweis auf einem anderen Kartenleser. - Connected to following remote readers: %1. - Verbunden mit den folgenden entfernten Lesegeräten: %1. + Connected to the following smartphones as card readers (SaCs): %1. + Verbunden mit den folgenden Smartphones als Kartenlesegeräten (SaKs): %1. Please place an ID card on the card reader. - Bitte legen Sie ein Ausweisdokument auf. + Bitte legen Sie einen Ausweis auf. If you have already placed an ID card on your card reader, you can consult the %1online help%2 for futher information. - Sollten Sie bereits Ihr Ausweisdokument aufgelegt haben, können Sie für weitere Informationen die %1Online-Hilfe%2 öffnen. + Sollten Sie bereits Ihren Ausweis aufgelegt haben, können Sie für weitere Informationen die %1Online-Hilfe%2 öffnen. Please place only one ID card on the card reader. - Bitte legen Sie nur ein Ausweisdokument auf. + Bitte legen Sie nur einen Ausweis auf. Please make sure that only one card reader with an ID card on it is connected to your computer. If you have already placed an ID card on your card reader, you can consult the %1online help%2 for futher information. - Bitte stellen Sie sicher, dass an Ihrem Computer nur ein Kartenleser mit aufliegendem Ausweisdokument angeschlossen ist. Sollten Sie bereits ein Ausweisdokument aufgelegt haben, können Sie für weitere Informationen die %1Online-Hilfe%2 öffnen. + Bitte stellen Sie sicher, dass an Ihrem Computer nur ein Kartenleser mit aufliegendem Ausweis angeschlossen ist. Sollten Sie bereits einen Ausweis aufgelegt haben, können Sie für weitere Informationen die %1Online-Hilfe%2 öffnen. Online identification function is disabled. Die Online-Ausweisfunktion ist deaktiviert. - This action cannot be performed. The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function. - Diese Aktion kann leider nicht durchgeführt werden. Die Online-Ausweisfunktion Ihres Ausweisdokuments ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. + This action cannot be performed. The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function. + Diese Aktion kann leider nicht durchgeführt werden. Die Online-Ausweisfunktion Ihres Ausweises ist nicht aktiviert. Bitte wenden Sie sich an die Behörde, die Ihr Ausweisdokument ausgegeben hat, um die Online-Ausweisfunktion zu aktivieren. Retry connection @@ -7296,8 +7914,14 @@ klicken. Erneut versuchen? - Weak NFC signal. Please reposition your card. - Schwacher NFC-Empfang. Bitte korrigieren Sie die Position Ihres Ausweises. + Weak NFC signal. Please +- change the card position +- remove the mobile phone case (if present) +- connect the smartphone with a charging cable + Schwacher NFC-Empfang. Bitte +- ändern Sie die Position des Ausweises +- entfernen Sie Handyhüllen o.Ä. +- verbinden Sie das Smartphone mit dem Ladegerät @@ -7379,9 +8003,16 @@ klicken. AusweisApp2 beenden - AusweisApp2 was started. + Application was started. LABEL DESKTOP - AusweisApp2 wurde gestartet. + Die Anwendung wurde gestartet. + + + + governikus::UIPlugInQml + + Information + Information @@ -7392,7 +8023,7 @@ klicken. <h4>Download of release notes failed</h4> - <h4>Herunterladen der Versionshinweise schlug fehl</h4> + <h4>Herunterladen der Release Notes schlug fehl</h4> AusweisApp2 %1 is now available - you have %2. Would you like to download it now? @@ -7409,7 +8040,7 @@ klicken. Cannot start authentication ERROR ALL_PLATFORMS A new authentication request was received while the previous one was still running. Part of an HTML error page. - Authentisierungsvorgang kann nicht gestartet werden + Ausweisvorgang kann nicht gestartet werden An operation is already in progress. @@ -7480,9 +8111,9 @@ klicken. Eine unbekannte Anwendung verwendet den benötigten Port (%1) bereits. Bitte beenden Sie zuerst die andere Anwendung und versuchen Sie es anschließend erneut! - Another program (%1) uses the required port (%2). Please exit this other program and try again! + The program (%1) uses the required port (%2). Please close %1 and try again! ERROR ALL_PLATFORMS A known programme is using the local port on which the AA2 listens. - Eine andere Anwendung (%1) verwendet den benötigten Port (%2) bereits. Bitte beenden Sie zuerst die andere Anwendung und versuchen Sie es anschließend erneut! + Die Anwendung "%1" verwendet den benötigten Port (%2) bereits. Bitte beenden Sie "%1" und versuchen Sie es anschließend erneut! 404 Not found @@ -7520,14 +8151,14 @@ klicken. Jetzt melden - You tried to start a newer version (%1) of currently running application. Please stop the current version (%2) and start again! + You tried to start a newer version (%1) of currently running AusweisApp2. Please stop the current version (%2) and start again! ERROR ALL_PLATFORMS The external request to show the UI requested a newer version than the one currently installed. - Sie versuchen eine neuere Version (%1) der aktuell laufenden Anwendung zu starten. Bitte beenden Sie zuerst die andere Version (%2) und versuchen Sie es anschließend erneut! + Sie versuchen eine neuere Version (%1) der aktuell laufenden AusweisApp2 zu starten. Bitte beenden Sie zuerst die andere Version (%2) und versuchen Sie es anschließend erneut! - You tried to start an older version (%1) of currently running application. Please open the currently running version (%2)! + You tried to start an older version (%1) of currently running AusweisApp2. Please open the currently running version (%2)! ERROR ALL_PLATFORMS The external request to show the UI requested an older version than the one currently installed. - Sie versuchen eine ältere Version (%1) der aktuell laufenden Anwendung zu starten. Bitte öffnen Sie die aktuell laufende Version (%2)! + Sie versuchen eine ältere Version (%1) der aktuell laufenden AusweisApp2 zu starten. Bitte öffnen Sie die aktuell laufende Version (%2)! https://www.ausweisapp.bund.de/en/qa/report-an-error/ @@ -7550,8 +8181,8 @@ klicken. <b>Wollen Sie wirklich abbrechen?</b> - You can as well identity later by calling the service provider's Internet page again. - Sie können sich auch später ausweisen, indem Sie erneut auf die Internetseite des Diensteanbieters gehen. + You can as well identity later by calling the provider's Internet page again. + Sie können sich auch später ausweisen, indem Sie erneut auf die Internetseite des Anbieters gehen. @@ -7613,39 +8244,44 @@ klicken. Diesen Hinweis nicht mehr anzeigen. - Unsupported version of %1. + Developer Mode: Enabled! + LABEL DESKTOP_QML + Entwicklermodus: Aktiviert! + + + Disable + LABEL DESKTOP_QML Global button to disable developer mode. + Deaktivieren + + + Failed to retrieve update information. INFO DESKTOP_QML Message that the update data is invalid and can't be used. - Nicht unterstützte Version von %1. + Das Herunterladen der Aktualisierungsinformationen ist fehlgeschlagen. - An update is available (Version: %1). + An update is available (version %1). INFO DESKTOP_QML An update was found which matches the current platform, the new version number is shown in the message. - Eine Aktualisierung ist verfügbar (Version: %1). + Eine Aktualisierung ist verfügbar (Version %1). - Download - INFO DESKTOP_QML An update was found. This is the caption of the download button, clicking it opens the link in the browser. - Download + New user interface released! + Neue grafische Benutzeroberfläche veröffentlicht! - Release notes - INFO DESKTOP_QML An update was found. This is the caption of the release note button, clicking it opens the note in the browser. - Aktualisierungshinweise + This release features a new and modern user interface. For this version of %1 (and this version only!) you may decide to switch back to the previous user interface. To do so click the Button "%2". It is highly recommend to use the new user interface as the old one will be removed with the next release of %3. + Diese Veröffentlichung beinhaltet eine neue und moderne grafische Benutzeroberfläche. In dieser Version der %1 (und nur in dieser!) können Sie sich dazu entscheiden, die vorherige Nutzeroberfläche weiterhin zu verwenden. Hierfür klicken Sie den Button "%2". Es wird jedoch ausdrücklich empfohlen, die neue Benutzeroberfläche zu aktivieren, da die vorherige bei der nächsten Veröffentlichung der %3 entfernt wird. - Current version %1 is up to date. - INFO DESKTOP_QML The AA2 is up-to-date, this message is only shown if the update check is started by the user and not via the auto-update functionality. - Version %1 ist aktuell. + Stick with new interface + Neue Oberfläche beibehalten - Developer Mode: Enabled! - LABEL DESKTOP_QML - Entwicklermodus: Aktiviert! + Use old interface + Alte Oberfläche verwenden - Disable - LABEL DESKTOP_QML Global button to disable developer mode. - Deaktivieren + %1 - Detached log viewer + %1 - Protokolldateianzeige diff --git a/resources/travis/setup.sh b/resources/travis/setup.sh index 80a19013e..43b324c99 100644 --- a/resources/travis/setup.sh +++ b/resources/travis/setup.sh @@ -5,8 +5,8 @@ set -eu readonly CLONE_DIR="${CLONE_DIR:-$(pwd)}" -MINIROOTFS_VERSION="3.10.0" -MINIROOTFS_SHA="ec3da7fb5f709a1ce912e6e31fccc5588420c5f1dcecc362c72c989532c1917a" +MINIROOTFS_VERSION="3.11.2" +MINIROOTFS_SHA="e9d9ea8c59fc4e836f733d51bea78a30cf41e6a2a774ca2406427a29249684ab" MINIROOTFS="alpine-minirootfs-${MINIROOTFS_VERSION}-x86_64.tar.gz" MINIROOTFS_URI="http://dl-cdn.alpinelinux.org/alpine/v${MINIROOTFS_VERSION%.*}/releases/x86_64/$MINIROOTFS" @@ -34,7 +34,7 @@ for arg in "$CHECK" do case "$arg" in format) PACKAGES="$PACKAGES uncrustify";; - docs) PACKAGES="$PACKAGES py2-sphinx py2-setuptools";; + docs) PACKAGES="$PACKAGES py3-sphinx py3-setuptools";; build) PACKAGES="$PACKAGES clang g++ ccache binutils-gold eudev-dev pcsc-lite-dev http-parser-dev openssl-dev qt5-qtsvg-dev qt5-qtquickcontrols2-dev qt5-qtwebsockets-dev qt5-qtconnectivity-dev qt5-qtbase-dev qt5-qttools-dev";; *) echo "Unknown command: $1" && exit 1 esac diff --git a/resources/updatable-files/reader/img_PersoSim.png b/resources/updatable-files/reader/img_PersoSim.png new file mode 100644 index 000000000..93d37c8ea Binary files /dev/null and b/resources/updatable-files/reader/img_PersoSim.png differ diff --git a/resources/updatable-files/reader/img_PersoSim_mit_ausweis.png b/resources/updatable-files/reader/img_PersoSim_mit_ausweis.png new file mode 100644 index 000000000..a3be8fae5 Binary files /dev/null and b/resources/updatable-files/reader/img_PersoSim_mit_ausweis.png differ diff --git a/resources/updatable-files/reader/img_RemoteReader.png b/resources/updatable-files/reader/img_RemoteReader.png index dcbed1658..faa961ccf 100644 Binary files a/resources/updatable-files/reader/img_RemoteReader.png and b/resources/updatable-files/reader/img_RemoteReader.png differ diff --git a/resources/updatable-files/reader/img_RemoteReader_mit_ausweis.png b/resources/updatable-files/reader/img_RemoteReader_mit_ausweis.png index 830027200..3d891115a 100644 Binary files a/resources/updatable-files/reader/img_RemoteReader_mit_ausweis.png and b/resources/updatable-files/reader/img_RemoteReader_mit_ausweis.png differ diff --git a/resources/updatable-files/supported-providers.json b/resources/updatable-files/supported-providers.json index bc967da7b..536e63244 100644 --- a/resources/updatable-files/supported-providers.json +++ b/resources/updatable-files/supported-providers.json @@ -125,19 +125,6 @@ "category": "citizen", "subjectUrls": ["https://www.bstu-formulare.de/lip"] }, - { - "exclude": ["ios"], - "shortName": {"" : "Allianz Maklerportal"}, - "address": "https://makler.allianz.de", - "homepage": "https://makler.allianz.de", - "phone": "+49 800/22 23 557 ", - "email": "zviss.makler@allianz.de", - "postalAddress": "Königinstraße 28
80802 München", - "category": "insurance", - "tcTokenUrl": "https://npa.allianz.de/azsecurity-npa-service/NpaEIDService/nparef/-wnfwSFGamtJotxe6_BKiLj", - "tcTokenUrlInfo" : "TcToken URL contains dynamic request id but is accepted anyway.", - "subjectUrls": ["https://npa.allianz.de"] - }, { "shortName": {"": "eID-Mahnantrag"}, "longName": {"": "Anträge im Mahnverfahren"}, @@ -199,7 +186,6 @@ "subjectUrls": ["https://www.bafoeg-hessen.de"] }, { - "exclude": ["ios"], "shortName": {"" : "BAföG Online"}, "address": "https://www.bafoegonline.bva.bund.de/", "homepage": "https://www.bva.bund.de/DE/Themen/Bildung/BAfoeG/bafoeg_node.html", @@ -437,6 +423,22 @@ "tcTokenUrlInfo" : "TcToken URL requires valid dynamic request id.", "subjectUrls": ["https://www.buergerserviceportal.nrw"] }, + { + "shortName": {"" : "Service-Portal Kreis Soest"}, + "longName": {"" : "Onlinedienste der Kreisverwaltung Soest"}, + "shortDescription": {"": "Anträge an die Kreisverwaltung Soest online erfassen."}, + "longDescription": {"": "In unserem Service-Portal können Sie Anträge an die Kreisverwaltung Soest online erfassen und direkt zur weiteren Bearbeitung an die zuständigen Stellen übermitteln."}, + "address": "https://serviceportal.kreis-soest.de", + "homepage": "https://www.kreis-soest.de/start", + "phone": "+49 2921 30-0", + "email": "service-portal@kreis-soest.de", + "postalAddress": "Kreisverwaltung Soest
Hoher Weg 1-3
59494 Soest", + "image": "KreisSoest_image.png", + "icon": "KreisSoest_icon.png", + "category": "citizen", + "tcTokenUrlInfo" : "TcToken URL requires valid dynamic request id.", + "subjectUrls": [] + }, { "exclude": ["ios"], "shortName": {"" : "Bürgerservice-Portal Stadt Lage"}, @@ -493,21 +495,6 @@ "tcTokenUrlInfo" : "TcToken URL requires valid dynamic request id.", "subjectUrls": ["https://www.buergerserviceportal.de"] }, - { - "exclude": ["ios"], - "shortName": {"" : "CosmosDirekt Kundenportal meinCosmosDirekt"}, - "longDescription": {"": "Mit der Online-Ausweisfunktion des Personalausweises können Sie sich einfach und sicher am Kundenportal ,mein Cosmos-Direkt' registrieren und anmelden. Im Portal haben Sie die Möglichkeit Ihre Versicherungen zu verwalten. Sie können online einen Antrag für ein Tagesgeldkonto stellen oder auch schnell und einfach Ihre persönlichen Daten, z.B. Ihre Adresse, ändern."}, - "address": "https://www.cosmosdirekt.de/meincosmosdirekt-registrierung/", - "homepage": "https://www.cosmosdirekt.de/", - "phone": "+49 681-9 66 68 00", - "email": "info@cosmosdirekt.de", - "postalAddress": "CosmosDirekt
66101 Saarbrücken", - "image": "CosmosDirekt_image.jpg", - "icon": "CosmosDirekt_icon.png", - "category": "insurance", - "tcTokenUrl" : "https://www.cosmosdirekt.de/nPa/IdentifizierenNPA?back_url=https://www.cosmosdirekt.de/meincosmosdirekt-registrierung/*ident=1", - "subjectUrls": ["https://www.cosmosdirekt.de"] - }, { "exclude": ["ios"], "shortName": {"" : "d.velop – foxdox.de: Dokumente sicher ablegen"}, @@ -522,9 +509,8 @@ "subjectUrls": ["https://mein.foxdox.de"] }, { - "exclude": ["ios"], "shortName": {"" : "Datev - Arbeitnehmer online / Lohn- und Gehaltsabrechnung"}, - "longDescription": {"": "Nach einmaliger Freischaltung durch den Arbeitgeber erhalten Sie Ihren persönlichen Aktivierungscode per Post. Mit dem Aktivierungscode registrieren Sie sich an dem Portal „DATEV Arbeitnehmer online“, dazu können Sie u.a. die Online-Ausweisfunktion nutzen. Danach können Sie jederzeit Ihre Brutto/Netto-Abrechnungen, Sozialversicherungsnachweise und Lohnsteuerbescheinigungen online abrufen. Sie haben dadurch jederzeit und überall einen schnellen Überblick über Ihre gesamten Lohn- und Gehaltsdokumente. "}, + "longDescription": {"": "Nach einmaliger Freischaltung durch den Arbeitgeber erhalten Sie Ihren persönlichen Aktivierungscode per Post. Mit dem Aktivierungscode registrieren Sie sich an dem Portal \"DATEV Arbeitnehmer online\", dazu können Sie u.a. die Online-Ausweisfunktion nutzen. Danach können Sie jederzeit Ihre Brutto/Netto-Abrechnungen, Sozialversicherungsnachweise und Lohnsteuerbescheinigungen online abrufen. Sie haben dadurch jederzeit und überall einen schnellen Überblick über Ihre gesamten Lohn- und Gehaltsdokumente. "}, "address": "https://www.datev.de/ano/", "homepage": "https://www.datev.de", "phone": "+49 800 3283825", @@ -625,7 +611,6 @@ "subjectUrls": [] }, { - "exclude": ["ios"], "shortName": {"" : "Hamburg Service Online-Bürgerdienste"}, "longName": {"" : "Hamburg Service Online-Bürgerdienste"}, "shortDescription": {"": "Digitales Dienstleistungsangebot der Freien und Hansestadt Hamburg (FHH)"}, @@ -641,7 +626,6 @@ "icon": "hamburg_serviceportal_icon.png" }, { - "exclude": ["ios"], "shortName": {"" : "Identitätsprüfungen nach der eIDAS und dem Geldwäschegesetz"}, "longDescription": {"": "Die identity Trust Management AG bietet Unternehmen die Möglichkeit, ihre Kunden schnell und sicher mit der Online-Ausweisfunktion zu identifizieren.
Kunden der Kooperationspartner der identity Trust Management AG können die Identitätsprüfung nach dem Signaturgesetz und dem Geldwäschegesetz auch direkt über die Internetseite der identity Trust Management AG vornehmen."}, "address": "https://www.identity.tm", @@ -667,11 +651,10 @@ "subjectUrls": ["https://www.sixform.com"] }, { - "exclude": ["ios"], "shortName": {"" : "Online-Registerauskunft"}, "longName": {"" : "Auskunft aus den Zentralen Registern des Kraftfahrt-Bundesamtes"}, - "shortDescription": {"": "Mit der Anwendung können Privatpersonen eine Auskunft aus dem Fahreignungsregister -(Punkteauskunft) und aus dem Zentralen Fahrzeugregister (Fahrzeugzulassungen) des Kraftfahrt-Bundesamtes erhalten. Diese umfasst ausgewählte Daten, die zu der jeweiligen Person gespeichert sind."}, - "longDescription": {"": "Die Online-Auskunft aus dem Zentralen Fahrzeugregister umfasst Informationen zur Fahrzeugbeschreibung, den Halterdaten, der Haftpflichtversicherung, der Fahrzeughistorie und den zulassungsrechtlich relevanten Ereignissen. Daten von vormaligen Haltern und interne Verwaltungsdaten sind von der Auskunft ausgenommen.
Die Online-Auskunft aus dem Fahreignungsregister umfasst Informationen zu den eingetragenen Verkehrsverstößen, deren Punktbewertung und Löschungsdatum."}, + "shortDescription": {"": "Mit der Anwendung können Privatpersonen eine Auskunft aus dem Fahreignungsregister (Punkteauskunft), aus dem Zentralen Fahrzeugregister (Fahrzeugzulassungen) sowie aus dem Zentralen Fahrerlaubnisregister (Führerschein) des Kraftfahrt-Bundesamtes erhalten. Diese umfasst ausgewählte Daten, die zu der jeweiligen Person gespeichert sind."}, + "longDescription": {"": "Die Online-Auskunft aus dem Zentralen Fahrzeugregister umfasst Informationen zur Fahrzeugbeschreibung, den Halterdaten, der Haftpflichtversicherung, der letzten Haupt- bzw. Sicherheitsüberprüfung, der Fahrzeughistorie und den zulassungsrechtlich relevanten Ereignissen. Daten von vormaligen Haltern und interne Verwaltungsdaten sind von der Auskunft ausgenommen.
Die Online-Auskunft aus dem Fahreignungsregister umfasst Informationen zu den eingetragenen Verkehrsverstößen, deren Punktbewertung und Löschungsdatum.
Die Online-Auskunft aus dem Zentralen Fahrerlaubnisregister umfasst Informationen zu Fahrerlaubnissen, die seit dem 01.01.1999 erteilt, erweitert oder umgeschrieben wurden. Über die anderen vor dem 01.01.1999 ausgestellten Führerscheine führt nur die jeweils ausstellende Fahrerlaubnisbehörde eine Kartei/Datei."}, "address": "https://www.kba-online.de/registerauskunft/app/registeranfrage.html", "homepage": "https://www.kba.de", "phone": "+49 461 316-1717", @@ -701,7 +684,19 @@ "subjectUrls": [] }, { - "exclude": ["ios"], + "shortName": {"" : "Kreis Lippe Portal"}, + "longName": {"" :"Kreis Lippe Portal"}, + "longDescription": {"": "Mit der Online-Ausweisfunktion können Sie sich am Bürgerportal des Kreises Lippe registrieren, anmelden und den Online-Service 'Elternbeiträge' nutzen. Als Eltern können Sie nach der einmaligen Registrierung

- Ihre Selbsteinschätzung für den Elternbeitrag online einreichen,
- den Bearbeitungsstand nachverfolgen,
- Bescheide elektronisch im Dokumentenbereich empfangen."}, + "address": "https://portal.kreis-lippe.de", + "homepage": "https://portal.kreis-lippe.de", + "phone": "+49 5231 - 62-0", + "email": "", + "postalAddress": "Kreis Lippe
Felix-Fechenbach-Str. 5
32756 Detmold", + "category": "citizen", + "tcTokenUrlInfo" : "", + "subjectUrls": [] + }, + { "shortName": {"" : "Login Meine VBL"}, "longDescription": {"": "Bei der VBL können Sie sich mit dem Personalausweis am Kundenportal ,Meine VBL' anmelden. Im Kundenkonto können Sie Ihre Vertragsdaten und Ihre persönlichen Daten einsehen und weitere Online-Dienste nutzen, z. B.
- Rentenantrag stellen,
- Beitragserstattung beantragen,
- Kontaktdaten ändern,
- persönliche Mitteilungen von der VBL erhalten."}, "address": "https://www.vbl.de/de/meine_vbl", @@ -714,7 +709,6 @@ "subjectUrls": ["https://www.vbl.de"] }, { - "exclude": ["ios"], "shortName": {"" : "LVM Versicherung - Kundenportal Meine LVM"}, "longDescription": {"": "Mit der Online-Ausweisfunktion im Personalausweis können Sie sich nach der Registrierung durch Ihre LVM-Agentur sicher am Kundenportal ,Meine LVM' anmelden. Ihre Versicherung können Sie nun selbst verwalten und beispielsweise sämtliche Vertragsdaten online einsehen. Darüber hinaus ist es möglich über das Portal Versicherungsbescheinigungen anzufordern sowie schnell und einfach Ihre persönlichen Daten wie Adresse oder Bankverbindung zu ändern."}, "address": "https://www.lvm.de/personalausweis", @@ -755,8 +749,21 @@ "subjectUrls": ["https://pgp.governikus-eid.de"] }, { - "shortName": {"" : "Selbstauskunft - „Meine Daten einsehen“"}, - "longDescription": {"": "Die AusweisApp2 verfügt über die Funktion \"Meine Daten einsehen\". Mit dieser Funktion können die auf dem Personalausweis bzw. dem elektronischen Aufenthaltstitel gespeicherten Daten ausgelesen und angezeigt werden. Hierbei sprechen wir auch von einer sogenannten Selbstauskunft.

Sobald Sie die AusweisApp2 gestartet und ein geeigneter Kartenleser installiert bzw. ein Android-Smartphone verbunden haben, können Sie diese Funktion unter dem Menüpunkt \"Ausweisen\" aufrufen. (Auf Mobilgeräten finden Sie die Ausweis-Auskunft übrigens auch direkt auf der Startseite sowie im Menüeintrag „Ausweisen“.)

Nach Ihrer PIN-Eingabe und erfolgreicher Datenübertragung werden die Daten in der AusweisApp2 dargestellt.

Bei der Selbstauskunft handelt es sich um einen reinen Demonstrationsdienst. Die ausgelesenen Daten werden lediglich zur Anzeige gebracht und nicht weitergegeben.

Bitte beachten Sie, dass Sie auch für diesen Vorgang eine Internetverbindung benötigen. Dies hat folgenden Hintergrund: Der Zugriff auf die Daten des Personalausweises bzw. des elektronischen Aufenthaltstitels ist nur möglich, wenn derjenige, der auf die Daten zugreifen möchte sich selbst zunächst eindeutig identifiziert. Dies geschieht über das sog. Berechtigungszertifikat. Es wird Ihnen immer angezeigt, wer auf Ihre Daten zugreifen möchte. Die Erlaubnis, ein Berechtigungszertifikat zu erhalten, wird einen Diensteanbieter auf Antrag und nach Prüfung bei der Vergabestelle für Berechtigungszertifikate beim Bundesverwaltungsamt erteilt. Um das technische Berechtigungszertifikat anzuzeigen und darüber hinaus eine Gültigkeitsprüfung des Ausweisdokuments durchführen zu können, ist eine Internetverbindung zwingend erforderlich. Aus diesem Grund spricht man auch von der Online-Ausweisfunktion."}, + "shortName": {"" : "Rhein-Neckar-Kreis - Kfz-Online"}, + "longName": {"" :"Rhein-Neckar-Kreis - Kfz-Online"}, + "longDescription": {"": "Beim Landratsamt Rhein-Neckar-Kreis können Sie sich mit der Online-Ausweisfunktion identifizieren und verschiedene Kfz-Dienstleistungen nutzen:

- ein Neufahrzeug zulassen,
- ein Fahrzeug wiederzulassen oder ummelden,
- ein Fahrzeug abmelden,
- Halterdaten ändern,
- eine Ersatzzulassungsbescheinigung Teil 1 beantragen"}, + "address": "https://www.rhein-neckar-kreis.de/,Lde/start/service/neuzulassung.html", + "homepage": "https://www.rhein-neckar-kreis.de/start.html", + "phone": "+49 6221 522-0", + "email": "post@rhein-neckar-kreis.de", + "postalAddress": "Landratsamt Rhein-Neckar-Kreis
Kurfürsten-Anlage 38 - 40
69115 Heidelberg", + "category": "citizen", + "tcTokenUrlInfo" : "", + "subjectUrls": [] + }, + { + "shortName": {"" : "Selbstauskunft - \"Meine Daten einsehen\""}, + "longDescription": {"": "Die AusweisApp2 verfügt über die Funktion \"Meine Daten einsehen\". Mit dieser Funktion können die auf dem Personalausweis bzw. dem elektronischen Aufenthaltstitel gespeicherten Daten ausgelesen und angezeigt werden. Hierbei sprechen wir auch von einer sogenannten Selbstauskunft.

Sobald Sie die AusweisApp2 gestartet und ein geeigneter Kartenleser installiert bzw. ein Android-Smartphone verbunden haben, können Sie diese Funktion unter dem Menüpunkt \"Ausweisen\" aufrufen. (Auf Mobilgeräten finden Sie die Ausweis-Auskunft übrigens auch direkt auf der Startseite sowie im Menüeintrag \"Ausweisen\".)

Nach Ihrer PIN-Eingabe und erfolgreicher Datenübertragung werden die Daten in der AusweisApp2 dargestellt.

Bei der Selbstauskunft handelt es sich um einen reinen Demonstrationsdienst. Die ausgelesenen Daten werden lediglich zur Anzeige gebracht und nicht weitergegeben.

Bitte beachten Sie, dass Sie auch für diesen Vorgang eine Internetverbindung benötigen. Dies hat folgenden Hintergrund: Der Zugriff auf die Daten des Personalausweises bzw. des elektronischen Aufenthaltstitels ist nur möglich, wenn derjenige, der auf die Daten zugreifen möchte sich selbst zunächst eindeutig identifiziert. Dies geschieht über das sog. Berechtigungszertifikat. Es wird Ihnen immer angezeigt, wer auf Ihre Daten zugreifen möchte. Die Erlaubnis, ein Berechtigungszertifikat zu erhalten, wird einen Anbieter auf Antrag und nach Prüfung bei der Vergabestelle für Berechtigungszertifikate beim Bundesverwaltungsamt erteilt. Um das technische Berechtigungszertifikat anzuzeigen und darüber hinaus eine Gültigkeitsprüfung des Ausweisdokuments durchführen zu können, ist eine Internetverbindung zwingend erforderlich. Aus diesem Grund spricht man auch von der Online-Ausweisfunktion."}, "address": "https://www.ausweisapp.bund.de/online-ausweisen/meine-daten-auslesen/", "homepage": "https://www.ausweisapp.bund.de/", "phone": "+49 421 - 204 95 995", @@ -768,6 +775,19 @@ "tcTokenUrlInfo" : "https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml", "subjectUrls": ["https://www.autentapp.de"] }, + { + "shortName": {"" : "Servicekonto Nordrhein-Westfalen"}, + "longName": {"" :"Servicekonto Nordrhein-Westfalen"}, + "longDescription": {"": "Einmal online registrieren und dann die gespeicherten Daten vielfach nutzen: Dies ist die Idee des Servicekonto.NRW.
Als Bürgerinnen und Bürger können Sie Ihre einmal erfassten Daten in allen angeschlossenen Portalen und Online-Angeboten in Nordrhein-Westfalen nutzen: Dazu gehören Online-Angebote von Städten, Gemeinden und Kreisen genauso wie die von Ministerien und Behörden der Landesverwaltung NRW.
Um das Servicekonto.NRW zu nutzen, müssen Sie sich einmal registrieren und Ihre Daten erfassen.
Mit der Online-Ausweisfunktion können Sie Ihre Daten einfach elektronisch in das Servicekonto.NRW übertragen und sofort alle Funktionen nutzen. Bei manueller Eingabe der Daten stehen Ihnen unter Umständen nicht alle Funktionen zur Verfügung."}, + "address": "https://servicekonto.nrw/serviceaccount/", + "homepage": "https://servicekonto.nrw/serviceaccount/", + "phone": "", + "email": "servicekonto@kdn.de", + "postalAddress": "KDN – Dachverband kommunaler IT-Dienstleister
Enggasse 2
D-50668 Köln", + "category": "citizen", + "tcTokenUrlInfo" : "", + "subjectUrls": [] + }, { "exclude": ["ios"], "shortName": {"" : "Service-Portal \"Auto\" Kreis Lippe"}, @@ -785,10 +805,23 @@ "tcTokenUrlInfo" : "TcToken URL requires valid dynamic request id.", "subjectUrls": ["https://www.buergerserviceportal.nrw"] }, + { + "shortName": {"" : "Serviceportal des Ennepe-Ruhr-Kreises"}, + "longName": {"" : "Serviceportal des Ennepe-Ruhr-Kreises"}, + "longDescription": {"": "Herzlich willkommen auf der Startseite des Service-Portals des Ennepe-Ruhr-Kreises.
Über dieses Serviceportal haben Sie rund um die Uhr online Zugriff auf Dienstleistungen des Kreises, des Landes und der Bundesbehörden. Ihr Vorteil: Das Angebot ist immer und überall abrufbar."}, + "address": "https://portal.enkreis.de/", + "homepage": "https://www.en-kreis.de", + "phone": "+49 2336 930", + "email": "serviceportal@en-kreis.de", + "postalAddress": "Ennepe-Ruhr-Kreis
Hauptstr. 92
58332 Schwelm", + "category": "citizen", + "icon": "ennepe_icon.png", + "subjectUrls": [] + }, { "shortName": {"" : "SkIDentity Service"}, "longName": {"" : "SkIDentity Service"}, - "longDescription": {"": "SkIDentity unterstützt die Umsetzung der Cyber-Sicherheitsstrategie der Bundesregierung und macht den elektronischen Personalausweis im Internet sehr leicht und mobil nutzbar. Der SkIDentity-Dienst bietet „Mobile eID as a Service“ und leitet bei Bedarf aus elektronischen Ausweisdokumenten kryptographisch geschützte „Cloud Identitäten“ ab, die auf beliebige Smartphones übertragen und dort sicher mobil genutzt werden können. Darüber hinaus kann auch die bislang aufwändige eID-Integration in einem komfortablen Portal erfolgen und die vertrauenswürdigen Identitäten kommen nun selbst aus einer vom Bundesamt für Sicherheit in der Informationstechnik (BSI) zertifizierten „Secure Cloud Infrastructure“."}, + "longDescription": {"": "SkIDentity unterstützt die Umsetzung der Cyber-Sicherheitsstrategie der Bundesregierung und macht den elektronischen Personalausweis im Internet sehr leicht und mobil nutzbar. Der SkIDentity-Dienst bietet \"Mobile eID as a Service\" und leitet bei Bedarf aus elektronischen Ausweisdokumenten kryptographisch geschützte \"Cloud Identitäten\" ab, die auf beliebige Smartphones übertragen und dort sicher mobil genutzt werden können. Darüber hinaus kann auch die bislang aufwändige eID-Integration in einem komfortablen Portal erfolgen und die vertrauenswürdigen Identitäten kommen nun selbst aus einer vom Bundesamt für Sicherheit in der Informationstechnik (BSI) zertifizierten \"Secure Cloud Infrastructure\"."}, "address": "https://skidentity.de/service", "homepage": "https://www.skidentity.de", "phone": "+49 9571 604 8014", @@ -873,6 +906,21 @@ "category": "citizen", "tcTokenUrlInfo" : "Registration required.", "subjectUrls": ["https://www.vollstreckungsportal.de"] + }, + { + "shortName": {"" : "Service-Portal Hochsauerlandkreis"}, + "longName": {"": "Antragstellung an die Kreisverwaltung im Hochsauerlandkreis"}, + "shortDescription": {"": "Übersicht über die verschiedenen Online-Anträge"}, + "longDescription": {"": "Stellen Sie hier Ihre Anträge an die Kreisverwaltung. Das Angebot wird laufend erweitert."}, + "address": "https://portal.citkomm.de/hsk/services", + "homepage": "https://portal.citkomm.de/hsk/services", + "phone": "+49 291 / 94-0", + "email": "post@hochsauerlandkreis.de", + "postalAddress": "Steinstraße 27
59872 Meschede", + "image": "HSK_image.jpg", + "icon": "HSK_icon.png", + "category": "citizen", + "subjectUrls": [] } ] } diff --git a/resources/updatable-files/supported-readers.json b/resources/updatable-files/supported-readers.json index a8688d380..57edb609f 100644 --- a/resources/updatable-files/supported-readers.json +++ b/resources/updatable-files/supported-readers.json @@ -19,8 +19,24 @@ [ { "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], - "DE": "Erfordert ein Android-Gerät mit aktiviertem Fernzugriff.", - "EN": "Requires an Android device with enabled remote access." + "DE": "Erfordert ein Smartphone mit aktiviertem Fernzugriff.", + "EN": "Requires a smartphone with enabled remote access." + } + ] + }, + + { + "VendorId": "0x0000", + "ProductId": "0x0001", + "Name": "PersoSim", + "Pattern": "^PersoSim.*", + "Icon": "img_PersoSim.png", + "IconWithNPA": "img_PersoSim_mit_ausweis.png", + "Drivers": + [ + { + "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], + "URL": "https://persosim.secunet.com" } ] }, @@ -103,7 +119,7 @@ "URL": "https://www.reiner-sct.com/support/support-anfrage/?os=Windows&productGroup=77304735&product=77304856&q=driver#choice5" }, { - "Platforms": [{"os": "mac"}], + "Platforms": [{"os": "mac", "max": "10.14"}], "URL": "https://www.reiner-sct.com/support/support-anfrage/?os=MacOS&productGroup=77304735&product=77304856&q=driver#choice5" }, { @@ -164,15 +180,7 @@ [ { "Platforms": [{"os": "win"}], - "URL": "https://www.kobil.com/de/support_de/#drivers_de" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "https://www.kobil.com/de/support_de/#drivers_de" - }, - { - "Platforms": [{"os": "unknown"}], - "URL": "https://www.kobil.com/de/support_de/#drivers_de" + "URL": "https://security.kobil.de/idtoken/" } ] }, @@ -191,7 +199,7 @@ "URL": "http://www.scm-pc-card.de/index.php?page=download&function=show_downloads&lang=de&product_id=738" }, { - "Platforms": [{"os": "mac", "min":"10.13"}, {"os": "unknown"}], + "Platforms": [{"os": "mac", "min":"10.13", "max":"10.14"}, {"os": "unknown"}], "URL": "https://support.identiv.com/sdi010-011/" } ], @@ -259,15 +267,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "https://support.identiv.com/3700f/" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "https://support.identiv.com/3700f/" - }, - { - "Platforms": [{"os": "unknown"}], + "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], "URL": "https://support.identiv.com/3700f/" } ] @@ -283,15 +283,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "https://support.identiv.com/scl3711/" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "https://support.identiv.com/scl3711/" - }, - { - "Platforms": [{"os": "unknown"}], + "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], "URL": "https://support.identiv.com/scl3711/" } ], @@ -315,15 +307,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "http://www.scm-pc-card.de/index.php?lang=en&page=download&function=show_downloads&product_id=832" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "http://www.scm-pc-card.de/index.php?lang=en&page=download&function=show_downloads&product_id=832" - }, - { - "Platforms": [{"os": "unknown"}], + "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], "URL": "http://www.scm-pc-card.de/index.php?lang=en&page=download&function=show_downloads&product_id=832" } ], @@ -347,15 +331,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "http://www.scm-pc-card.de/index.php?page=download&function=show_downloads&lang=de&product_id=921" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "http://www.scm-pc-card.de/index.php?page=download&function=show_downloads&lang=de&product_id=921" - }, - { - "Platforms": [{"os": "unknown"}], + "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], "URL": "http://www.scm-pc-card.de/index.php?page=download&function=show_downloads&lang=de&product_id=921" } ], @@ -379,11 +355,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "http://www.acs.com.hk/en/driver/151/acr1281u-npa-contactless-reader/" - }, - { - "Platforms": [{"os": "mac"}], + "Platforms": [{"os": "win"}, {"os": "mac"}], "URL": "http://www.acs.com.hk/en/driver/151/acr1281u-npa-contactless-reader/" } ], @@ -412,11 +384,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "http://www.acs.com.hk/en/products/342/acr1252u-usb-nfc-reader-iii-nfc-forum-certified-reader/#tab_downloads" - }, - { - "Platforms": [{"os": "mac"}], + "Platforms": [{"os": "win"}, {"os": "mac"}], "URL": "http://www.acs.com.hk/en/products/342/acr1252u-usb-nfc-reader-iii-nfc-forum-certified-reader/#tab_downloads" } ], @@ -446,15 +414,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "https://www.hidglobal.de/drivers" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "https://www.hidglobal.de/drivers" - }, - { - "Platforms": [{"os": "unknown"}], + "Platforms": [{"os": "win"}, {"os": "unknown"}], "URL": "https://www.hidglobal.de/drivers" } ], @@ -464,11 +424,6 @@ "Platforms":[{"os": "win"}], "DE": "Es ist notwendig, die Treiber vom Hersteller zu installieren. Beachten Sie bei der Auswahl, dass nur der \"X-CHIP WINDOWS BU & RU driver\" funktioniert.", "EN": "It is necessary to install the drivers from the manufacturer. Please note that only the driver named \"X-CHIP WINDOWS BU & RU driver\" works with this card reader." - }, - { - "Platforms":[{"os": "mac"}], - "DE": "Es ist notwendig, die Treiber vom Hersteller zu installieren. Dazu folgen Sie bitte dem jeweiligen Link für Ihr Betriebssystem zur Herstellerseite.", - "EN": "It is necessary to install the drivers from the manufacturer. Please follow the relevant link for your operating system." } ] }, @@ -483,11 +438,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "https://www.hidglobal.de/drivers" - }, - { - "Platforms": [{"os": "mac", "min": "10.12"}], + "Platforms": [{"os": "win"}, {"os": "mac", "min": "10.12"}], "URL": "https://www.hidglobal.de/drivers" } ], @@ -518,16 +469,12 @@ { "Platforms": [{"os": "win"}], "URL": "https://www.hidglobal.de/drivers" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "https://www.hidglobal.de/drivers" } ], "Information": [ { - "Platforms":[{"os": "win"}, {"os": "mac"}], + "Platforms":[{"os": "win"}], "DE": "Es ist notwendig, die Treiber vom Hersteller zu installieren. Dazu folgen Sie bitte dem jeweiligen Link für Ihr Betriebssystem zur Herstellerseite.", "EN": "It is necessary to install the drivers from the manufacturer. Please follow the relevant link for your operating system." } @@ -544,15 +491,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], - "URL": "https://www.hidglobal.com/drivers" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "https://www.hidglobal.com/drivers" - }, - { - "Platforms": [{"os": "unknown"}], + "Platforms": [{"os": "win"}, {"os": "unknown"}], "URL": "https://www.hidglobal.com/drivers" } ], @@ -562,11 +501,6 @@ "Platforms":[{"os": "win"}], "DE": "Es ist notwendig, die Treiber vom Hersteller zu installieren. Dazu folgen Sie bitte dem jeweiligen Link für Ihr Betriebssystem zur Herstellerseite. Beachten Sie bei der Auswahl, dass nur der \"X-CHIP WINDOWS BU & RU driver\" funktioniert.", "EN": "It is necessary to install the drivers from the manufacturer. Please follow the relevant link for your operating system. Please note that only the driver named \"X-CHIP WINDOWS BU & RU driver\" works with this card reader." - }, - { - "Platforms":[{"os": "mac"}], - "DE": "Es ist notwendig, die Treiber vom Hersteller zu installieren. Dazu folgen Sie bitte dem jeweiligen Link für Ihr Betriebssystem zur Herstellerseite.", - "EN": "It is necessary to install the drivers from the manufacturer. Please follow the relevant link for your operating system." } ] }, @@ -581,7 +515,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}, {"os":"mac", "min": "10.13"}], + "Platforms": [{"os": "win"}], "URL": "https://www.hidglobal.com/drivers" } ], @@ -591,11 +525,6 @@ "Platforms": [{"os": "win"}], "DE": "Der Kartenleser funktioniert mit dem systemseitig installierten Treiber. Falls Sie jedoch den Treiber von der Webseite des Herstellers installieren möchten, ist anschließend ein Neustart erforderlich.", "EN": "The card reader operates with the driver automatically installed by the system. In case you prefer to install the driver from the manufacturer's webseite, a reboot is required." - }, - { - "Platforms": [{"os": "mac"}, {"max": "10.12"}], - "DE": "Der Kartenleser funktioniert nicht mit dem systemseitig installierten Treiber. Es existiert kein Treiber vom Hersteller", - "EN": "The card reader not operates with the driver automatically installed by the system. There is no driver from the manufacturer" } ] }, @@ -639,16 +568,8 @@ "Drivers": [ { - "Platforms": [{"os": "win"}], + "Platforms": [{"os": "win"}, {"os": "mac"},{"os": "unknown"}], "URL": "https://supportportal.gemalto.com/csm/?id=kb_article_view&sysparm_article=KB0016422" - }, - { - "Platforms": [{"os": "mac"}], - "URL": "https://supportportal.gemalto.com/csm/?id=kb_article_view&sysparm_article=KB0016424" - }, - { - "Platforms": [{"os": "unknown"}], - "URL": "https://supportportal.gemalto.com/csm/?id=kb_article_view&sysparm_article=KB0016423" } ], "Information": @@ -703,7 +624,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], + "Platforms": [{"os": "win"}, {"os": "mac", "max":"10.13"}, {"os": "unknown"}], "URL": "https://cherry.de/download/de/download.php" } ], @@ -715,7 +636,7 @@ "EN": "It is necessary to install the drivers from the manufacturer. Please follow the relevant link for your operating system." }, { - "Platforms": [{"os": "mac"}], + "Platforms": [{"os": "mac", "max":"10.13"}], "DE": "Der Kartenleser funktioniert mit dem systemseitig installierten Treiber. Falls Sie jedoch den Treiber von der Webseite des Herstellers installieren möchten, ist anschließend ein Neustart erforderlich.", "EN": "The card reader operates with the driver automatically installed by the system. In case you prefer to install the driver from the manufacturer's webseite, a reboot is required." } @@ -732,7 +653,7 @@ "Drivers": [ { - "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], + "Platforms": [{"os": "win"}, {"os": "mac", "max":"10.13"}, {"os": "unknown"}], "URL": "https://cherry.de/download/de/download.php" } ], @@ -744,7 +665,7 @@ "EN": "It is necessary to install the drivers from the manufacturer. Please follow the relevant link for your operating system." }, { - "Platforms": [{"os": "mac"}], + "Platforms": [{"os": "mac", "max": "10.14"}], "DE": "Der Kartenleser funktioniert mit dem systemseitig installierten Treiber. Falls Sie jedoch den Treiber von der Webseite des Herstellers installieren möchten, ist anschließend ein Neustart erforderlich.", "EN": "The card reader operates with the driver automatically installed by the system. In case you prefer to install the driver from the manufacturer's webseite, a reboot is required." } @@ -791,12 +712,8 @@ "Drivers": [ { - "Platforms": [{"os": "win"}, {"os": "mac"}], - "URL": "https://www.signotec.com/download/treiber/" - }, - { - "Platforms": [{"os": "unknown"}], - "URL": "https://www.signotec.com/download/treiber/" + "Platforms": [{"os": "win"}, {"os": "mac"}, {"os": "unknown"}], + "URL": "https://www.signotec.com/software/tools-und-treiber/treiber/" } ], "Information": diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 67d23777b..dd4ba981a 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -23,27 +23,10 @@ ADD_SUBDIRECTORY(ui) ADD_SUBDIRECTORY(activation) ADD_SUBDIRECTORY(remote_device) ADD_SUBDIRECTORY(core) +ADD_SUBDIRECTORY(init) ADD_SUBDIRECTORY(whitelist_client) -FUNCTION(CONFIGURE_CONFIG_H) - IF(VENDOR_GOVERNIKUS) - SET(VENDOR_DOMAIN governikus.com) - ELSE() - SET(VENDOR_DOMAIN) - ENDIF() - - IF(VERSION_DVCS) - SET(VERSION ${VERSION_DVCS}) - ELSE() - SET(VERSION ${PROJECT_VERSION}) - ENDIF() - - SET(PRODUCT ${PROJECT_NAME}) - - CONFIGURE_FILE(config.h.in config.h @ONLY) -ENDFUNCTION() - FILE(GLOB TRANSLATION_FILES ${RESOURCES_DIR}/translations/*.ts) FOREACH(filepath ${TRANSLATION_FILES}) @@ -103,23 +86,21 @@ IF(IOS) SET_SOURCE_FILES_PROPERTIES(${RCC} PROPERTIES GENERATED TRUE) ENDIF() -FILE(GLOB MAIN_FILES *.cpp) -IF(ANDROID) - ADD_LIBRARY(AusweisApp SHARED ${MAIN_FILES} ${QM_FILES}) +SET(MAIN_FILE main.cpp) +IF(ANDROID OR INTEGRATED_SDK) + ADD_LIBRARY(AusweisApp SHARED ${MAIN_FILE} ${QM_FILES}) ELSEIF(IOS) - ADD_EXECUTABLE(AusweisApp MACOSX_BUNDLE ${MAIN_FILES} ${IOS_RESOURCES} ${QM_FILES}) + ADD_EXECUTABLE(AusweisApp MACOSX_BUNDLE ${MAIN_FILE} ${IOS_RESOURCES} ${QM_FILES}) ELSE() - ADD_EXECUTABLE(AusweisApp WIN32 ${MAIN_FILES} windows.rc ${QM_FILES}) + ADD_EXECUTABLE(AusweisApp WIN32 ${MAIN_FILE} windows.rc ${QM_FILES}) ENDIF() ADD_DEPENDENCIES(AusweisApp AusweisAppRcc) -CONFIGURE_CONFIG_H() - -TARGET_LINK_LIBRARIES(AusweisApp AusweisAppGlobal AusweisAppCore) +TARGET_LINK_LIBRARIES(AusweisApp AusweisAppInit) SET_TARGET_PROPERTIES(AusweisApp PROPERTIES OUTPUT_NAME "${PROJECT_NAME}") SET_TARGET_PROPERTIES(AusweisApp PROPERTIES MACOSX_BUNDLE_BUNDLE_NAME ${PROJECT_NAME}) -SET_TARGET_PROPERTIES(AusweisApp PROPERTIES MACOSX_BUNDLE_GUI_IDENTIFIER com.governikus.ausweisapp2) +SET_TARGET_PROPERTIES(AusweisApp PROPERTIES MACOSX_BUNDLE_GUI_IDENTIFIER "${BUNDLE_IDENTIFIER}") SET_TARGET_PROPERTIES(AusweisApp PROPERTIES MACOSX_BUNDLE_COPYRIGHT "${COPYRIGHT_TEXT}") @@ -133,7 +114,7 @@ IF(IOS) TARGET_LINK_LIBRARIES(AusweisApp -lqtpcre2 -lqtlibpng -lQt5GraphicsSupport -lQt5FontDatabaseSupport -lQt5ClipboardSupport -lqios -lqsvg -lqjpeg -lqtfreetype) TARGET_LINK_LIBRARIES(AusweisApp "-lc++ -lz -lm") - TARGET_LINK_LIBRARIES(AusweisApp ${IOS_ASSETSLIBRARY} ${IOS_UIKIT} ${IOS_COREBLUETOOTH} ${IOS_COREFOUNDATION} ${IOS_OPENGLES} ${IOS_FOUNDATION} ${IOS_QUARTZCORE} ${IOS_CORETEXT} ${IOS_COREGRAPHICS} ${IOS_SECURITY} ${IOS_SYSTEMCONFIGURATION} ${IOS_MOBILECORESERVICES} ${IOS_AUDIOTOOLBOX} ${IOS_IMAGEIO} ${IOS_CORENFC} ${IOS_MESSAGEUI} ${IOS_STOREKIT}) + TARGET_LINK_LIBRARIES(AusweisApp ${IOS_ASSETSLIBRARY} ${IOS_UIKIT} ${IOS_COREBLUETOOTH} ${IOS_COREFOUNDATION} ${IOS_OPENGLES} ${IOS_FOUNDATION} ${IOS_QUARTZCORE} ${IOS_CORETEXT} ${IOS_COREGRAPHICS} ${IOS_SECURITY} ${IOS_MOBILECORESERVICES} ${IOS_AUDIOTOOLBOX} ${IOS_IMAGEIO} ${IOS_CORENFC} ${IOS_MESSAGEUI} ${IOS_STOREKIT}) TARGET_LINK_LIBRARIES(AusweisApp -Wl,-e,_qt_main_wrapper) @@ -156,21 +137,28 @@ IF(IOS) TARGET_LINK_LIBRARIES(AusweisApp -L${QT_HOST_PREFIX}/qml/QtQuick.2 -lqtquick2plugin) SET_TARGET_PROPERTIES(AusweisApp PROPERTIES RESOURCE "${IOS_RESOURCES}") + SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_INSTALL_PATH "$(LOCAL_APPS_DIR)") + SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_SKIP_INSTALL "NO") SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_ASSETCATALOG_COMPILER_APPICON_NAME "AppIcon") SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_TARGETED_DEVICE_FAMILY "1,2") SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS "${PACKAGING_DIR}/ios/AusweisApp2.entitlements") IF(USE_DISTRIBUTION_PROFILE) - SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER "iOS Release (Distribution)") + SET(PROVISIONING_PROFILE_SPECIFIER "iOS Release (Distribution)") + SET(EXPORT_METHOD app-store) SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY "iPhone Distribution: Governikus GmbH & Co. KG (G7EQCJU4BR)") ELSE() - SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER "iOS Development") + SET(PROVISIONING_PROFILE_SPECIFIER "iOS Development") + SET(EXPORT_METHOD development) SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY "iPhone Developer: Marco von der Puetten (46ZK7WV8QR)") ENDIF() + SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_PROVISIONING_PROFILE_SPECIFIER ${PROVISIONING_PROFILE_SPECIFIER}) # prevent xcode to convert multiple png files to tiff SET_TARGET_PROPERTIES(AusweisApp PROPERTIES XCODE_ATTRIBUTE_COMBINE_HIDPI_IMAGES "NO") TARGET_LINK_LIBRARIES(AusweisApp AusweisAppActivationCustomScheme) + + CONFIGURE_FILE(${PACKAGING_DIR}/ios/exportOptions.plist.in ${CMAKE_BINARY_DIR}/exportOptions.plist @ONLY) ENDIF() IF(MAC) @@ -181,14 +169,14 @@ IF(MAC) SET(HELPER_SOURCES autostart_helper/main.mm) ADD_EXECUTABLE(${FULL_HELPER_NAME} MACOSX_BUNDLE ${HELPER_SOURCES}) TARGET_LINK_LIBRARIES(${FULL_HELPER_NAME} ${OSX_APPKIT}) - CONFIGURE_FILE(${RESOURCES_DIR}/packaging/macos/autostart_helper/Info.plist ${CMAKE_CURRENT_BINARY_DIR}/AutostartHelperInfo.plist @ONLY) + CONFIGURE_FILE(${PACKAGING_DIR}/macos/autostart_helper/Info.plist.in ${CMAKE_CURRENT_BINARY_DIR}/AutostartHelperInfo.plist @ONLY) SET_TARGET_PROPERTIES(${FULL_HELPER_NAME} PROPERTIES MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_BINARY_DIR}/AutostartHelperInfo.plist) ENDIF() IF(ANDROID) TARGET_LINK_LIBRARIES(AusweisApp Qt5::AndroidExtras) TARGET_LINK_LIBRARIES(AusweisApp AusweisAppCardNfc) - IF(NOT ANDROID_BUILD_AAR) + IF(NOT INTEGRATED_SDK) TARGET_LINK_LIBRARIES(AusweisApp AusweisAppActivationIntent) ENDIF() ENDIF() @@ -197,7 +185,7 @@ IF(IOS) TARGET_LINK_LIBRARIES(AusweisApp AusweisAppCardIos) ENDIF() -IF((ANDROID AND NOT ANDROID_BUILD_AAR) OR IOS) +IF((ANDROID AND NOT INTEGRATED_SDK) OR IOS) TARGET_LINK_LIBRARIES(AusweisApp AusweisAppCardBluetooth) ELSEIF(LINUX) TARGET_LINK_LIBRARIES(AusweisApp debug AusweisAppCardBluetooth) @@ -211,7 +199,7 @@ IF(TARGET Qt5::Qml) TARGET_LINK_LIBRARIES(AusweisApp AusweisAppUiQml) ENDIF() -IF(IOS OR ANDROID OR WINDOWS_STORE) +IF(ANDROID) TARGET_LINK_LIBRARIES(AusweisApp AusweisAppUiAidl) ELSE() TARGET_LINK_LIBRARIES(AusweisApp debug AusweisAppUiAidl) @@ -219,10 +207,15 @@ ENDIF() IF(DESKTOP) TARGET_LINK_LIBRARIES(AusweisApp AusweisAppCardPcsc AusweisAppCardDrivers AusweisAppActivationWebservice) - TARGET_LINK_LIBRARIES(AusweisApp AusweisAppUiWidget) + IF(NOT INTEGRATED_SDK) + TARGET_LINK_LIBRARIES(AusweisApp AusweisAppUiWidget) + ENDIF() +ENDIF() + +IF(NOT ANDROID AND NOT IOS AND NOT INTEGRATED_SDK) + TARGET_LINK_LIBRARIES(AusweisApp AusweisAppUiWebsocket) ENDIF() -TARGET_LINK_LIBRARIES(AusweisApp AusweisAppUiWebsocket) INCLUDE(Install) INCLUDE(FeatureSummary) diff --git a/src/activation/base/ActivationContext.cpp b/src/activation/base/ActivationContext.cpp index 7351037ab..da42027bb 100644 --- a/src/activation/base/ActivationContext.cpp +++ b/src/activation/base/ActivationContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ActivationContext.h" diff --git a/src/activation/base/ActivationContext.h b/src/activation/base/ActivationContext.h index ad66aa28f..b2dc81e23 100644 --- a/src/activation/base/ActivationContext.h +++ b/src/activation/base/ActivationContext.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/base/ActivationHandler.cpp b/src/activation/base/ActivationHandler.cpp index 76901531b..e79dbe166 100644 --- a/src/activation/base/ActivationHandler.cpp +++ b/src/activation/base/ActivationHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ActivationHandler.h" diff --git a/src/activation/base/ActivationHandler.h b/src/activation/base/ActivationHandler.h index e5a066635..cba3dd1b8 100644 --- a/src/activation/base/ActivationHandler.h +++ b/src/activation/base/ActivationHandler.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/customscheme/CustomSchemeActivationContext.cpp b/src/activation/customscheme/CustomSchemeActivationContext.cpp index dbf9d514b..78eece202 100644 --- a/src/activation/customscheme/CustomSchemeActivationContext.cpp +++ b/src/activation/customscheme/CustomSchemeActivationContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CustomSchemeActivationContext.h" diff --git a/src/activation/customscheme/CustomSchemeActivationContext.h b/src/activation/customscheme/CustomSchemeActivationContext.h index 299129c22..b68d4d24d 100644 --- a/src/activation/customscheme/CustomSchemeActivationContext.h +++ b/src/activation/customscheme/CustomSchemeActivationContext.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/customscheme/CustomSchemeActivationHandler.cpp b/src/activation/customscheme/CustomSchemeActivationHandler.cpp index 0fcc050d5..1bdcccfe1 100644 --- a/src/activation/customscheme/CustomSchemeActivationHandler.cpp +++ b/src/activation/customscheme/CustomSchemeActivationHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CustomSchemeActivationHandler.h" diff --git a/src/activation/customscheme/CustomSchemeActivationHandler.h b/src/activation/customscheme/CustomSchemeActivationHandler.h index 451e97e9b..3e9e02d3a 100644 --- a/src/activation/customscheme/CustomSchemeActivationHandler.h +++ b/src/activation/customscheme/CustomSchemeActivationHandler.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/intent/AusweisApp2Service.java b/src/activation/intent/AusweisApp2Service.java index 2fbe39653..360f9c1e3 100644 --- a/src/activation/intent/AusweisApp2Service.java +++ b/src/activation/intent/AusweisApp2Service.java @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ package com.governikus.ausweisapp2; diff --git a/src/activation/intent/IntentActivationContext.cpp b/src/activation/intent/IntentActivationContext.cpp index 75935a5c8..e4eba48cd 100644 --- a/src/activation/intent/IntentActivationContext.cpp +++ b/src/activation/intent/IntentActivationContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "IntentActivationContext.h" diff --git a/src/activation/intent/IntentActivationContext.h b/src/activation/intent/IntentActivationContext.h index 5faf2ed7b..1d21f4a9f 100644 --- a/src/activation/intent/IntentActivationContext.h +++ b/src/activation/intent/IntentActivationContext.h @@ -2,7 +2,7 @@ * \brief Implementation of ActivationContext for Intent * based activation on Android systems. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/intent/IntentActivationHandler.cpp b/src/activation/intent/IntentActivationHandler.cpp index d587a8cd2..7ca2ec00d 100644 --- a/src/activation/intent/IntentActivationHandler.cpp +++ b/src/activation/intent/IntentActivationHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "IntentActivationHandler.h" diff --git a/src/activation/intent/IntentActivationHandler.h b/src/activation/intent/IntentActivationHandler.h index 1691eac38..7f663fe1c 100644 --- a/src/activation/intent/IntentActivationHandler.h +++ b/src/activation/intent/IntentActivationHandler.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/intent/MainActivity.java b/src/activation/intent/MainActivity.java index b58232f09..8a2288004 100644 --- a/src/activation/intent/MainActivity.java +++ b/src/activation/intent/MainActivity.java @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ package com.governikus.ausweisapp2; @@ -20,8 +20,13 @@ import android.os.Bundle; import android.util.Log; import android.view.accessibility.AccessibilityManager; +import android.view.View; +import android.view.ViewGroup.MarginLayoutParams; import android.view.Window; import android.view.WindowManager; +import androidx.core.view.OnApplyWindowInsetsListener; +import androidx.core.view.ViewCompat; +import androidx.core.view.WindowInsetsCompat; import java.util.List; import org.qtproject.qt5.android.bindings.QtActivity; @@ -34,6 +39,8 @@ public class MainActivity extends QtActivity private static Uri cReferrer; private static boolean cStartedByAuth; + private final MarginLayoutParams windowInsets = new MarginLayoutParams(0, 0); + private NfcForegroundDispatcher mNfcForegroundDispatcher; private static class NfcForegroundDispatcher { @@ -115,6 +122,15 @@ public static String fetchStoredReferrer() } + public MainActivity() + { + QT_ANDROID_THEMES = new String[] { + "AppTheme" + }; + QT_ANDROID_DEFAULT_THEME = "AppTheme"; + } + + public static boolean isStartedByAuth() { return cStartedByAuth; @@ -127,12 +143,6 @@ public void onCreate(Bundle savedInstanceState) Log.d(LOG_TAG, "onCreate: " + getIntent()); super.onCreate(savedInstanceState); - // Make statusbar transparent - Window window = getWindow(); - window.setFlags(WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS, WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS); - window.setFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS, WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS); - window.setStatusBarColor(Color.TRANSPARENT); - onNewIntent(getIntent()); if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP_MR1) // API 22 { @@ -145,6 +155,29 @@ public void onCreate(Bundle savedInstanceState) mNfcForegroundDispatcher = new NfcForegroundDispatcher(this); setRequestedOrientation(isTablet() ? ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE : ActivityInfo.SCREEN_ORIENTATION_PORTRAIT); + + // Set statusBar/navigationBar color and handle systemWindowInsets + Window window = getWindow(); + View rootView = window.getDecorView().findViewById(android.R.id.content); + if (Build.VERSION.SDK_INT >= 29) // Android 10 + { + rootView.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_STABLE | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION | View.SYSTEM_UI_FLAG_LIGHT_NAVIGATION_BAR); + window.setNavigationBarColor(Color.TRANSPARENT); + } + else + { + rootView.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_STABLE | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION); + } + window.setStatusBarColor(Color.TRANSPARENT); + ViewCompat.setOnApplyWindowInsetsListener(rootView, new OnApplyWindowInsetsListener() { + public WindowInsetsCompat onApplyWindowInsets(View v, WindowInsetsCompat insets){ + windowInsets.topMargin = insets.getSystemWindowInsetTop(); + windowInsets.leftMargin = insets.getSystemWindowInsetLeft(); + windowInsets.rightMargin = insets.getSystemWindowInsetRight(); + windowInsets.bottomMargin = insets.getSystemWindowInsetBottom(); + return insets; + } + }); } @@ -221,27 +254,9 @@ public boolean isScreenReaderRunning() } - public int getStatusBarHeight() - { - return getDimension("status_bar_height"); - } - - - public int getNavigationBarHeight() + public MarginLayoutParams getWindowInsets() { - return getDimension("navigation_bar_height"); - } - - - private int getDimension(String dimensionName) - { - int result = 0; - int resourceId = getResources().getIdentifier(dimensionName, "dimen", "android"); - if (resourceId > 0) - { - result = getResources().getDimensionPixelSize(resourceId); - } - return result; + return windowInsets; } diff --git a/src/activation/intent/UpdateReceiver.java b/src/activation/intent/UpdateReceiver.java index 375213032..a71b8306b 100644 --- a/src/activation/intent/UpdateReceiver.java +++ b/src/activation/intent/UpdateReceiver.java @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ package com.governikus.ausweisapp2; diff --git a/src/activation/internal/InternalActivationContext.cpp b/src/activation/internal/InternalActivationContext.cpp index 77b274fff..c9950a9d9 100644 --- a/src/activation/internal/InternalActivationContext.cpp +++ b/src/activation/internal/InternalActivationContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "InternalActivationContext.h" diff --git a/src/activation/internal/InternalActivationContext.h b/src/activation/internal/InternalActivationContext.h index b0c7bb956..ae5501783 100644 --- a/src/activation/internal/InternalActivationContext.h +++ b/src/activation/internal/InternalActivationContext.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/internal/InternalActivationHandler.cpp b/src/activation/internal/InternalActivationHandler.cpp index 7eefd0d8d..66671f24a 100644 --- a/src/activation/internal/InternalActivationHandler.cpp +++ b/src/activation/internal/InternalActivationHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "InternalActivationHandler.h" diff --git a/src/activation/internal/InternalActivationHandler.h b/src/activation/internal/InternalActivationHandler.h index 072b87dd2..66a9043a8 100644 --- a/src/activation/internal/InternalActivationHandler.h +++ b/src/activation/internal/InternalActivationHandler.h @@ -1,7 +1,7 @@ /*! * \brief ActivationHandler for Internal usage like JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/webservice/Template.cpp b/src/activation/webservice/Template.cpp index 0138d53c8..06d9e3a8e 100644 --- a/src/activation/webservice/Template.cpp +++ b/src/activation/webservice/Template.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "Template.h" diff --git a/src/activation/webservice/Template.h b/src/activation/webservice/Template.h index 59013909f..ae0b13018 100644 --- a/src/activation/webservice/Template.h +++ b/src/activation/webservice/Template.h @@ -1,7 +1,7 @@ /*! * A simple template renderer. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/webservice/WebserviceActivationContext.cpp b/src/activation/webservice/WebserviceActivationContext.cpp index 2571c26b7..f8afda8a0 100644 --- a/src/activation/webservice/WebserviceActivationContext.cpp +++ b/src/activation/webservice/WebserviceActivationContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "WebserviceActivationContext.h" diff --git a/src/activation/webservice/WebserviceActivationContext.h b/src/activation/webservice/WebserviceActivationContext.h index 168e31588..e6b777517 100644 --- a/src/activation/webservice/WebserviceActivationContext.h +++ b/src/activation/webservice/WebserviceActivationContext.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/activation/webservice/WebserviceActivationHandler.cpp b/src/activation/webservice/WebserviceActivationHandler.cpp index cc2a73091..e00f633a2 100644 --- a/src/activation/webservice/WebserviceActivationHandler.cpp +++ b/src/activation/webservice/WebserviceActivationHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "WebserviceActivationHandler.h" @@ -69,7 +69,7 @@ bool WebserviceActivationHandler::start() if (!serverAppName.isEmpty()) { //: ERROR ALL_PLATFORMS A known programme is using the local port on which the AA2 listens. - msg = tr("Another program (%1) uses the required port (%2). Please exit this other program and try again!").arg(serverAppName).arg(port); + msg = tr("The program (%1) uses the required port (%2). Please close %1 and try again!").arg(serverAppName).arg(port); } Q_EMIT fireShowUserInformation(msg); } @@ -160,14 +160,14 @@ void WebserviceActivationHandler::handleShowUiRequest(UiModule pUiModule, const { qCWarning(activation) << "Current version is lower than caller version"; //: ERROR ALL_PLATFORMS The external request to show the UI requested a newer version than the one currently installed. - Q_EMIT fireShowUserInformation(tr("You tried to start a newer version (%1) of currently running application. Please stop the current version (%2) and start again!").arg(version, QCoreApplication::applicationVersion())); + Q_EMIT fireShowUserInformation(tr("You tried to start a newer version (%1) of currently running AusweisApp2. Please stop the current version (%2) and start again!").arg(version, QCoreApplication::applicationVersion())); return; } else if (callerVersion < VersionNumber::getApplicationVersion()) { qCWarning(activation) << "Current version is higher than caller version"; //: ERROR ALL_PLATFORMS The external request to show the UI requested an older version than the one currently installed. - Q_EMIT fireShowUserInformation(tr("You tried to start an older version (%1) of currently running application. Please open the currently running version (%2)!").arg(version, QCoreApplication::applicationVersion())); + Q_EMIT fireShowUserInformation(tr("You tried to start an older version (%1) of currently running AusweisApp2. Please open the currently running version (%2)!").arg(version, QCoreApplication::applicationVersion())); return; } } diff --git a/src/activation/webservice/WebserviceActivationHandler.h b/src/activation/webservice/WebserviceActivationHandler.h index ff1910eea..2f46a6e18 100644 --- a/src/activation/webservice/WebserviceActivationHandler.h +++ b/src/activation/webservice/WebserviceActivationHandler.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/autostart_helper/main.mm b/src/autostart_helper/main.mm index b42cca663..9a9a6f3bd 100644 --- a/src/autostart_helper/main.mm +++ b/src/autostart_helper/main.mm @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/src/card/base/Apdu.cpp b/src/card/base/Apdu.cpp index fa45ed476..b2a577b68 100644 --- a/src/card/base/Apdu.cpp +++ b/src/card/base/Apdu.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "Apdu.h" diff --git a/src/card/base/Apdu.h b/src/card/base/Apdu.h index 60dad0137..f7d128d1b 100644 --- a/src/card/base/Apdu.h +++ b/src/card/base/Apdu.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/Card.cpp b/src/card/base/Card.cpp index 97b21a883..63beb16d4 100644 --- a/src/card/base/Card.cpp +++ b/src/card/base/Card.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "Card.h" @@ -40,11 +40,10 @@ CardReturnCode Card::destroyPaceChannel() } -CardReturnCode Card::setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) +ResponseApduResult Card::setEidPin(quint8 pTimeoutSeconds) { Q_UNUSED(pTimeoutSeconds) - Q_UNUSED(pResponseApdu) qCWarning(card) << "Setting eID PIN is not supported"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } diff --git a/src/card/base/Card.h b/src/card/base/Card.h index 2d6675e1b..95b2a8a89 100644 --- a/src/card/base/Card.h +++ b/src/card/base/Card.h @@ -1,7 +1,7 @@ /*! * \brief Class representing a smart card * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -54,7 +54,7 @@ class Card * The command APDU buffer is transmitted to the card. * The response APDU buffer is filled with the data returned from the card. */ - virtual CardReturnCode transmit(const CommandApdu& pCmd, ResponseApdu& pRes) = 0; + virtual ResponseApduResult transmit(const CommandApdu& pCmd) = 0; /*! * Establishes a PACE channel, i.e. the corresponding reader is no basic reader. @@ -69,7 +69,7 @@ class Card /*! * Sets a new eID PIN, i.e. the corresponding reader is no basic reader. */ - virtual CardReturnCode setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu); + virtual ResponseApduResult setEidPin(quint8 pTimeoutSeconds); }; diff --git a/src/card/base/CardConnection.cpp b/src/card/base/CardConnection.cpp index 253ed1cea..b71db79fa 100644 --- a/src/card/base/CardConnection.cpp +++ b/src/card/base/CardConnection.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnection.h" diff --git a/src/card/base/CardConnection.h b/src/card/base/CardConnection.h index 6eebc9e51..26323f8db 100644 --- a/src/card/base/CardConnection.h +++ b/src/card/base/CardConnection.h @@ -1,7 +1,7 @@ /*! * \brief Contains a card connection object * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/CardConnectionWorker.cpp b/src/card/base/CardConnectionWorker.cpp index 09f09a2a7..68f5bbdd8 100644 --- a/src/card/base/CardConnectionWorker.cpp +++ b/src/card/base/CardConnectionWorker.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnectionWorker.h" @@ -70,41 +70,35 @@ void CardConnectionWorker::onReaderInfoChanged(const QString& pReaderName) } -CardReturnCode CardConnectionWorker::transmit(const CommandApdu& pCommandApdu, ResponseApdu& pResponseApdu) +ResponseApduResult CardConnectionWorker::transmit(const CommandApdu& pCommandApdu) { const auto card = mReader ? mReader->getCard() : nullptr; if (!card) { - return CardReturnCode::CARD_NOT_FOUND; + return {CardReturnCode::CARD_NOT_FOUND}; } - CardReturnCode returnCode; - if (mSecureMessaging) { const CommandApdu securedCommandApdu = mSecureMessaging->encrypt(pCommandApdu); if (securedCommandApdu.getBuffer().isEmpty()) { - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - ResponseApdu securedResponseApdu; - returnCode = card->transmit(securedCommandApdu, securedResponseApdu); - pResponseApdu = mSecureMessaging->decrypt(securedResponseApdu); - if (pResponseApdu.isEmpty()) + ResponseApduResult result = card->transmit(securedCommandApdu); + result.mResponseApdu = mSecureMessaging->decrypt(result.mResponseApdu); + if (result.mResponseApdu.isEmpty()) { qCDebug(::card) << "Stopping Secure Messaging since it failed. The channel therefore must no be re-used."; stopSecureMessaging(); - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - } - else - { - returnCode = card->transmit(pCommandApdu, pResponseApdu); + return result; } - return returnCode; + return card->transmit(pCommandApdu); } @@ -115,19 +109,17 @@ CardReturnCode CardConnectionWorker::readFile(const FileRef& pFileRef, QByteArra return CardReturnCode::CARD_NOT_FOUND; } - ResponseApdu selectRes; CommandApdu select = SelectBuilder(pFileRef).build(); - CardReturnCode returnCode = transmit(select, selectRes); - if (returnCode != CardReturnCode::OK || selectRes.getReturnCode() != StatusCode::SUCCESS) + auto [selectReturnCode, selectRes] = transmit(select); + if (selectReturnCode != CardReturnCode::OK || selectRes.getReturnCode() != StatusCode::SUCCESS) { return CardReturnCode::COMMAND_FAILED; } while (true) { - ResponseApdu res; ReadBinaryBuilder rb(static_cast(pFileContent.count()), 0xff); - returnCode = transmit(rb.build(), res); + auto [returnCode, res] = transmit(rb.build()); if (returnCode != CardReturnCode::OK) { break; @@ -233,12 +225,10 @@ CardReturnCode CardConnectionWorker::destroyPaceChannel() qCInfo(support) << "Destroying PACE channel"; if (mReader->getReaderInfo().isBasicReader()) { + qCDebug(::card) << "Destroying PACE channel with invalid command causing 6700 as return code"; stopSecureMessaging(); MSEBuilder builder(MSEBuilder::P1::ERASE, MSEBuilder::P2::DEFAULT_CHANNEL); - ResponseApdu response; - CardReturnCode cardReturnCode = card->transmit(builder.build(), response); - qCDebug(::card) << "Destroying PACE channel with invalid command causing 6700 as return code"; - return cardReturnCode; + return card->transmit(builder.build()).mReturnCode; } else { @@ -247,29 +237,30 @@ CardReturnCode CardConnectionWorker::destroyPaceChannel() } -CardReturnCode CardConnectionWorker::setEidPin(const QString& pNewPin, quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) +ResponseApduResult CardConnectionWorker::setEidPin(const QString& pNewPin, quint8 pTimeoutSeconds) { const auto card = mReader ? mReader->getCard() : nullptr; if (!card) { - return CardReturnCode::CARD_NOT_FOUND; + return {CardReturnCode::CARD_NOT_FOUND}; } if (mReader->getReaderInfo().isBasicReader()) { Q_ASSERT(!pNewPin.isEmpty()); ResetRetryCounterBuilder commandBuilder(pNewPin.toUtf8()); - if (transmit(commandBuilder.build(), pResponseApdu) != CardReturnCode::OK || pResponseApdu.getReturnCode() != StatusCode::SUCCESS) + auto [returnCode, response] = transmit(commandBuilder.build()); + if (returnCode != CardReturnCode::OK || response.getReturnCode() != StatusCode::SUCCESS) { qCWarning(::card) << "Modify PIN failed"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - return CardReturnCode::OK; + return {CardReturnCode::OK, response}; } else { Q_ASSERT(pNewPin.isEmpty()); - return card->setEidPin(pTimeoutSeconds, pResponseApdu); + return card->setEidPin(pTimeoutSeconds); } } diff --git a/src/card/base/CardConnectionWorker.h b/src/card/base/CardConnectionWorker.h index 945d26942..59d501f63 100644 --- a/src/card/base/CardConnectionWorker.h +++ b/src/card/base/CardConnectionWorker.h @@ -1,7 +1,7 @@ /*! * \brief Worker for \ref CardConnection that will do the job in \ref ReaderManagerWorker * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -69,7 +69,7 @@ class CardConnectionWorker virtual CardReturnCode readFile(const FileRef& pFileRef, QByteArray& pFileContent); - virtual CardReturnCode transmit(const CommandApdu& pCommandApdu, ResponseApdu& pResponseApdu); + virtual ResponseApduResult transmit(const CommandApdu& pCommandApdu); /*! * Performs PACE and establishes a PACE channel. @@ -105,7 +105,7 @@ class CardConnectionWorker */ Q_INVOKABLE virtual bool stopSecureMessaging(); - virtual CardReturnCode setEidPin(const QString& pNewPin, quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu); + virtual ResponseApduResult setEidPin(const QString& pNewPin, quint8 pTimeoutSeconds); Q_SIGNALS: void fireReaderInfoChanged(const ReaderInfo& pReaderInfo); diff --git a/src/card/base/CardInfo.cpp b/src/card/base/CardInfo.cpp index 4a13cb413..459d46877 100644 --- a/src/card/base/CardInfo.cpp +++ b/src/card/base/CardInfo.cpp @@ -1,7 +1,7 @@ /*! * \brief CardInfo holds smart card information, such as the type and some contained data structure (currently only the EF.CardAccess). * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CardInfo.h" @@ -52,7 +52,7 @@ QString CardInfo::getCardTypeString() const return tr("Passport"); case CardType::EID_CARD: - //: ERROR ALL_PLATFORMS An id card is present/inserted. The text is only used in DiagnosisView. + //: ERROR ALL_PLATFORMS An ID card is present/inserted. The text is only used in DiagnosisView. return tr("ID card (PA/eAT)"); } @@ -145,20 +145,19 @@ CardType CardInfoFactory::detectCard(const QSharedPointer& // This is actually not specified in the CIF, but we do it to make the PersoSim work // 0. Select the master file CommandApdu command = SelectBuilder(FileRef::masterFile()).build(); - ResponseApdu response; - CardReturnCode returnCode = pCardConnectionWorker->transmit(command, response); - if (returnCode != CardReturnCode::OK || response.getReturnCode() != StatusCode::SUCCESS) + auto [masterReturnCode, masterResponse] = pCardConnectionWorker->transmit(command); + if (masterReturnCode != CardReturnCode::OK || masterResponse.getReturnCode() != StatusCode::SUCCESS) { qCWarning(card) << "Cannot select MF"; - if (returnCode != CardReturnCode::OK) + if (masterReturnCode != CardReturnCode::OK) { - qCDebug(card) << "CardConnectionWorker return code" << returnCode; + qCDebug(card) << "CardConnectionWorker return code" << masterReturnCode; } - if (response.getReturnCode() != StatusCode::SUCCESS) + if (masterResponse.getReturnCode() != StatusCode::SUCCESS) { - qCDebug(card) << "ResponseApdu return code" << response.getReturnCode(); + qCDebug(card) << "ResponseApdu return code" << masterResponse.getReturnCode(); } return CardType::UNKNOWN; @@ -166,15 +165,15 @@ CardType CardInfoFactory::detectCard(const QSharedPointer& // 1. CL=00, INS=A4=SELECT, P1= 02, P2=0C, Lc=02, Data=2F00 (FI of EF.DIR), Le=absent command = SelectBuilder(FileRef::efDir()).build(); - returnCode = pCardConnectionWorker->transmit(command, response); - if (returnCode != CardReturnCode::OK || response.getReturnCode() != StatusCode::SUCCESS) + auto [efDirReturnCode, efDirResponse] = pCardConnectionWorker->transmit(command); + if (efDirReturnCode != CardReturnCode::OK || efDirResponse.getReturnCode() != StatusCode::SUCCESS) { qCWarning(card) << "Cannot select EF.DIR"; qCInfo(card) << "Check for passport..."; command = SelectBuilder(FileRef::appPassport()).build(); - returnCode = pCardConnectionWorker->transmit(command, response); - if (returnCode != CardReturnCode::OK || response.getReturnCode() != StatusCode::SUCCESS) + auto [passportReturnCode, passportResponse] = pCardConnectionWorker->transmit(command); + if (passportReturnCode != CardReturnCode::OK || passportResponse.getReturnCode() != StatusCode::SUCCESS) { qCWarning(card) << "Cannot select application identifier"; return CardType::UNKNOWN; @@ -185,8 +184,8 @@ CardType CardInfoFactory::detectCard(const QSharedPointer& // 2. CL=00, INS=B0=Read Binary, P1=00, P2=00 (no offset), Lc=00, Le=5A command = CommandApdu(QByteArray::fromHex("00B000005A")); - returnCode = pCardConnectionWorker->transmit(command, response); - if (returnCode != CardReturnCode::OK || response.getReturnCode() != StatusCode::SUCCESS) + auto [readReturnCode, readResponse] = pCardConnectionWorker->transmit(command); + if (readReturnCode != CardReturnCode::OK || readResponse.getReturnCode() != StatusCode::SUCCESS) { qCWarning(card) << "Cannot read EF.DIR"; return CardType::UNKNOWN; @@ -194,11 +193,11 @@ CardType CardInfoFactory::detectCard(const QSharedPointer& // matching value from CIF static const QByteArray matchingValue = QByteArray::fromHex("61324F0FE828BD080FA000000167455349474E500F434941207A752044462E655369676E5100730C4F0AA000000167455349474E61094F07A0000002471001610B4F09E80704007F00070302610C4F0AA000000167455349474E"); - bool efDirMatches = response.getData().startsWith(matchingValue); + bool efDirMatches = readResponse.getData().startsWith(matchingValue); if (!efDirMatches) { qCWarning(card) << "expected EF.DIR(00,5A): " << matchingValue.toHex(); - qCWarning(card) << "actual EF.DIR(00,5A): " << response.getData().left(90).toHex(); + qCWarning(card) << "actual EF.DIR(00,5A): " << readResponse.getData().left(90).toHex(); return CardType::UNKNOWN; } diff --git a/src/card/base/CardInfo.h b/src/card/base/CardInfo.h index d5d5ed0f1..9be27f607 100644 --- a/src/card/base/CardInfo.h +++ b/src/card/base/CardInfo.h @@ -1,7 +1,7 @@ /*! * \brief Contains the CardInfo and the CardInfoFactory * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/CommandApdu.cpp b/src/card/base/CommandApdu.cpp index 6d4342c31..5d38106d8 100644 --- a/src/card/base/CommandApdu.cpp +++ b/src/card/base/CommandApdu.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CommandApdu.h" diff --git a/src/card/base/CommandApdu.h b/src/card/base/CommandApdu.h index a4cd5e8ae..8e87a9d9a 100644 --- a/src/card/base/CommandApdu.h +++ b/src/card/base/CommandApdu.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/CommandApduBuilder.cpp b/src/card/base/CommandApduBuilder.cpp index 4718be86d..697677e23 100644 --- a/src/card/base/CommandApduBuilder.cpp +++ b/src/card/base/CommandApduBuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CommandApduBuilder.h" diff --git a/src/card/base/CommandApduBuilder.h b/src/card/base/CommandApduBuilder.h index bdbbb7974..d31e8aae2 100644 --- a/src/card/base/CommandApduBuilder.h +++ b/src/card/base/CommandApduBuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/DestroyPaceChannel.cpp b/src/card/base/DestroyPaceChannel.cpp index df00cda60..7644d7a1b 100644 --- a/src/card/base/DestroyPaceChannel.cpp +++ b/src/card/base/DestroyPaceChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "DestroyPaceChannel.h" diff --git a/src/card/base/DestroyPaceChannel.h b/src/card/base/DestroyPaceChannel.h index 4bea18cb1..38b93b99d 100644 --- a/src/card/base/DestroyPaceChannel.h +++ b/src/card/base/DestroyPaceChannel.h @@ -1,7 +1,7 @@ /*! * \brief Data object for creation of card command DestroyPACEChannel * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/EABuilder.cpp b/src/card/base/EABuilder.cpp index 34c53eeac..928839fa5 100644 --- a/src/card/base/EABuilder.cpp +++ b/src/card/base/EABuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "EABuilder.h" diff --git a/src/card/base/EABuilder.h b/src/card/base/EABuilder.h index d48b181d0..58d72e71f 100644 --- a/src/card/base/EABuilder.h +++ b/src/card/base/EABuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/EstablishPaceChannel.cpp b/src/card/base/EstablishPaceChannel.cpp index b9e7276f8..da112f5ec 100644 --- a/src/card/base/EstablishPaceChannel.cpp +++ b/src/card/base/EstablishPaceChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "EstablishPaceChannel.h" diff --git a/src/card/base/EstablishPaceChannel.h b/src/card/base/EstablishPaceChannel.h index 528940f8f..c29ef6597 100644 --- a/src/card/base/EstablishPaceChannel.h +++ b/src/card/base/EstablishPaceChannel.h @@ -1,7 +1,7 @@ /*! * \brief Data object for output of card command EstablishPaceChannel * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/EstablishPaceChannelOutput.cpp b/src/card/base/EstablishPaceChannelOutput.cpp index 279a84473..190517b16 100644 --- a/src/card/base/EstablishPaceChannelOutput.cpp +++ b/src/card/base/EstablishPaceChannelOutput.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "EstablishPaceChannelOutput.h" @@ -343,18 +343,18 @@ CardReturnCode EstablishPaceChannelOutput::parseReturnCode(quint32 pPaceReturnCo // Error codes wrapping error codes from the card. The format is 0xXXXXYYZZ, where XXXX identifies // the command/step, and YY and ZZ encode the SW1 and SW2 from the response APDU from the card. - switch (pPaceReturnCode & 0xffff0000) + switch (pPaceReturnCode & 0xffff0000U) { - case 0xf0000000: // Select EF.CardAccess - case 0xf0010000: // Read Binary EF.CardAccess - case 0xf0020000: // MSE: Set AT + case 0xf0000000U: // Select EF.CardAccess + case 0xf0010000U: // Read Binary EF.CardAccess + case 0xf0020000U: // MSE: Set AT break; - case 0xf0030000: // General Authenticate Step 1 - case 0xf0040000: // General Authenticate Step 2 - case 0xf0050000: // General Authenticate Step 3 - case 0xf0060000: // General Authenticate Step 4 - if ((pPaceReturnCode & 0xff00) == 0x6300) + case 0xf0030000U: // General Authenticate Step 1 + case 0xf0040000U: // General Authenticate Step 2 + case 0xf0050000U: // General Authenticate Step 3 + case 0xf0060000U: // General Authenticate Step 4 + if ((pPaceReturnCode & 0xff00U) == 0x6300U) { // SW1 == 0x63 is a warning, which includes incorrectly entered CAN/PIN. For the PIN // we get SW2 == 0xcX, with X being the number of remaining retries. diff --git a/src/card/base/EstablishPaceChannelOutput.h b/src/card/base/EstablishPaceChannelOutput.h index ddfcc3f20..5542cf9f8 100644 --- a/src/card/base/EstablishPaceChannelOutput.h +++ b/src/card/base/EstablishPaceChannelOutput.h @@ -1,7 +1,7 @@ /*! * \brief Data object for output of card command EstablishPaceChannel * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/EstablishPaceChannelParser.cpp b/src/card/base/EstablishPaceChannelParser.cpp index a702d901f..c0f8b24e8 100644 --- a/src/card/base/EstablishPaceChannelParser.cpp +++ b/src/card/base/EstablishPaceChannelParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "EstablishPaceChannelParser.h" diff --git a/src/card/base/EstablishPaceChannelParser.h b/src/card/base/EstablishPaceChannelParser.h index ef1d461fb..ce8de0483 100644 --- a/src/card/base/EstablishPaceChannelParser.h +++ b/src/card/base/EstablishPaceChannelParser.h @@ -1,7 +1,7 @@ /*! * \brief Parser to decapsulation EstablishPACEChannel * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/FileRef.cpp b/src/card/base/FileRef.cpp index bbabcb448..8b80762f9 100644 --- a/src/card/base/FileRef.cpp +++ b/src/card/base/FileRef.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "FileRef.h" diff --git a/src/card/base/FileRef.h b/src/card/base/FileRef.h index f9b2eb582..fdb1b517b 100644 --- a/src/card/base/FileRef.h +++ b/src/card/base/FileRef.h @@ -1,7 +1,7 @@ /*! * \brief Reference information for files on smart cards. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/GABuilder.cpp b/src/card/base/GABuilder.cpp index 8b24bc29a..7f4d79aa7 100644 --- a/src/card/base/GABuilder.cpp +++ b/src/card/base/GABuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "GABuilder.h" diff --git a/src/card/base/GABuilder.h b/src/card/base/GABuilder.h index 55f22e482..273cafdc9 100644 --- a/src/card/base/GABuilder.h +++ b/src/card/base/GABuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/GeneralAuthenticateResponse.cpp b/src/card/base/GeneralAuthenticateResponse.cpp index 5e82d948a..14512a3df 100644 --- a/src/card/base/GeneralAuthenticateResponse.cpp +++ b/src/card/base/GeneralAuthenticateResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/src/card/base/GeneralAuthenticateResponse.h b/src/card/base/GeneralAuthenticateResponse.h index 80c548199..eb0cf6da3 100644 --- a/src/card/base/GeneralAuthenticateResponse.h +++ b/src/card/base/GeneralAuthenticateResponse.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of GeneralAuthenticate response APDUs. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/GetChallengeBuilder.cpp b/src/card/base/GetChallengeBuilder.cpp index 573043015..4ddc7f22c 100644 --- a/src/card/base/GetChallengeBuilder.cpp +++ b/src/card/base/GetChallengeBuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "GetChallengeBuilder.h" diff --git a/src/card/base/GetChallengeBuilder.h b/src/card/base/GetChallengeBuilder.h index 97db22be0..a78027f8e 100644 --- a/src/card/base/GetChallengeBuilder.h +++ b/src/card/base/GetChallengeBuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/InputAPDUInfo.cpp b/src/card/base/InputAPDUInfo.cpp index 35120e1b0..64bc76ae8 100644 --- a/src/card/base/InputAPDUInfo.cpp +++ b/src/card/base/InputAPDUInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "InputAPDUInfo.h" diff --git a/src/card/base/InputAPDUInfo.h b/src/card/base/InputAPDUInfo.h index ee2e1d70f..964eff154 100644 --- a/src/card/base/InputAPDUInfo.h +++ b/src/card/base/InputAPDUInfo.h @@ -1,7 +1,7 @@ /*! * \brief Holds the data of an InputAPDUInfo element. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/MSEBuilder.cpp b/src/card/base/MSEBuilder.cpp index 9c834dd61..5cec84f97 100644 --- a/src/card/base/MSEBuilder.cpp +++ b/src/card/base/MSEBuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "MSEBuilder.h" diff --git a/src/card/base/MSEBuilder.h b/src/card/base/MSEBuilder.h index 7eedcf7a8..a2af963a8 100644 --- a/src/card/base/MSEBuilder.h +++ b/src/card/base/MSEBuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/PSOBuilder.cpp b/src/card/base/PSOBuilder.cpp index b6d6db560..f8128c9d6 100644 --- a/src/card/base/PSOBuilder.cpp +++ b/src/card/base/PSOBuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PSOBuilder.h" diff --git a/src/card/base/PSOBuilder.h b/src/card/base/PSOBuilder.h index fc628fa3b..5993d41c1 100644 --- a/src/card/base/PSOBuilder.h +++ b/src/card/base/PSOBuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/PersoSimWorkaround.h b/src/card/base/PersoSimWorkaround.h index ad626fc91..97c16800f 100644 --- a/src/card/base/PersoSimWorkaround.h +++ b/src/card/base/PersoSimWorkaround.h @@ -1,7 +1,7 @@ /*! * \brief This class is only to mark it as a workaround for working with the PersoSim. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -32,8 +32,7 @@ class PersoSimWorkaround */ static CardReturnCode sendingMseSetAt(const QSharedPointer& pCardConnectionWorker) { - ResponseApdu response; - const CardReturnCode returnCode = pCardConnectionWorker->transmit(SelectBuilder(FileRef::efCardAccess()).build(), response); + auto [returnCode, response] = pCardConnectionWorker->transmit(SelectBuilder(FileRef::efCardAccess()).build()); if (response.getReturnCode() == StatusCode::EMPTY) { diff --git a/src/card/base/PinModify.cpp b/src/card/base/PinModify.cpp index 9d751f2a2..84e00cd2d 100644 --- a/src/card/base/PinModify.cpp +++ b/src/card/base/PinModify.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PinModify.h" diff --git a/src/card/base/PinModify.h b/src/card/base/PinModify.h index 3eb9e9a02..2215a7898 100644 --- a/src/card/base/PinModify.h +++ b/src/card/base/PinModify.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/PinModifyOutput.cpp b/src/card/base/PinModifyOutput.cpp index 459076b1c..7dd4148d0 100644 --- a/src/card/base/PinModifyOutput.cpp +++ b/src/card/base/PinModifyOutput.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PinModifyOutput.h" diff --git a/src/card/base/PinModifyOutput.h b/src/card/base/PinModifyOutput.h index d83b1046b..cee9d02c6 100644 --- a/src/card/base/PinModifyOutput.h +++ b/src/card/base/PinModifyOutput.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ReadBinaryBuilder.cpp b/src/card/base/ReadBinaryBuilder.cpp index 606568592..b3c7df144 100644 --- a/src/card/base/ReadBinaryBuilder.cpp +++ b/src/card/base/ReadBinaryBuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ReadBinaryBuilder.h" diff --git a/src/card/base/ReadBinaryBuilder.h b/src/card/base/ReadBinaryBuilder.h index b3a4a1a43..2b1cb720b 100644 --- a/src/card/base/ReadBinaryBuilder.h +++ b/src/card/base/ReadBinaryBuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/Reader.cpp b/src/card/base/Reader.cpp index aa8730365..f9f7c907b 100644 --- a/src/card/base/Reader.cpp +++ b/src/card/base/Reader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "Reader.h" @@ -113,8 +113,7 @@ Reader::RetryCounterResult Reader::getRetryCounter(QSharedPointertransmit(mseBuilder.build(), mseSetAtResponse); + auto [returnCode, mseSetAtResponse] = pCardConnectionWorker->transmit(mseBuilder.build()); if (returnCode != CardReturnCode::OK) { return {returnCode}; diff --git a/src/card/base/Reader.h b/src/card/base/Reader.h index 76fcbf494..62795b09a 100644 --- a/src/card/base/Reader.h +++ b/src/card/base/Reader.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ReaderFilter.cpp b/src/card/base/ReaderFilter.cpp index 21f02faa5..86e8b5425 100644 --- a/src/card/base/ReaderFilter.cpp +++ b/src/card/base/ReaderFilter.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderFilter.h" diff --git a/src/card/base/ReaderFilter.h b/src/card/base/ReaderFilter.h index 39d3bb434..a7bbb1c5e 100644 --- a/src/card/base/ReaderFilter.h +++ b/src/card/base/ReaderFilter.h @@ -1,7 +1,7 @@ /*! * \brief A configured filter used to retrieve readers * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ReaderInfo.cpp b/src/card/base/ReaderInfo.cpp index 7766765c6..4685684c3 100644 --- a/src/card/base/ReaderInfo.cpp +++ b/src/card/base/ReaderInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderInfo.h" diff --git a/src/card/base/ReaderInfo.h b/src/card/base/ReaderInfo.h index 756d01201..cbd74eaef 100644 --- a/src/card/base/ReaderInfo.h +++ b/src/card/base/ReaderInfo.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ReaderManager.cpp b/src/card/base/ReaderManager.cpp index 9f17320ea..cfd1bd101 100644 --- a/src/card/base/ReaderManager.cpp +++ b/src/card/base/ReaderManager.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderManager.h" diff --git a/src/card/base/ReaderManager.h b/src/card/base/ReaderManager.h index 3a64e282e..fc774db34 100644 --- a/src/card/base/ReaderManager.h +++ b/src/card/base/ReaderManager.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ReaderManagerPlugIn.cpp b/src/card/base/ReaderManagerPlugIn.cpp index c493e9936..eb9bd30d8 100644 --- a/src/card/base/ReaderManagerPlugIn.cpp +++ b/src/card/base/ReaderManagerPlugIn.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderManagerPlugIn.h" diff --git a/src/card/base/ReaderManagerPlugIn.h b/src/card/base/ReaderManagerPlugIn.h index 659d1f106..1222dffdc 100644 --- a/src/card/base/ReaderManagerPlugIn.h +++ b/src/card/base/ReaderManagerPlugIn.h @@ -2,7 +2,7 @@ * \brief PlugIn to control different kinds of reader managers that will be used in \ref ReaderManager. * If you implement a class of this PlugIn you need to register it in \ref ReaderManager, otherwise it won't be used. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ReaderManagerPlugInInfo.cpp b/src/card/base/ReaderManagerPlugInInfo.cpp index 416f283c1..fd8575c09 100644 --- a/src/card/base/ReaderManagerPlugInInfo.cpp +++ b/src/card/base/ReaderManagerPlugInInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderManagerPlugInInfo.h" diff --git a/src/card/base/ReaderManagerPlugInInfo.h b/src/card/base/ReaderManagerPlugInInfo.h index 199c3d737..dd66ab160 100644 --- a/src/card/base/ReaderManagerPlugInInfo.h +++ b/src/card/base/ReaderManagerPlugInInfo.h @@ -1,7 +1,7 @@ /*! * \brief Data object providing information about a reader manager plug-in. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ReaderManagerWorker.cpp b/src/card/base/ReaderManagerWorker.cpp index 37184f40d..34766e840 100644 --- a/src/card/base/ReaderManagerWorker.cpp +++ b/src/card/base/ReaderManagerWorker.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderManagerWorker.h" diff --git a/src/card/base/ReaderManagerWorker.h b/src/card/base/ReaderManagerWorker.h index 458d4ac41..7d9cb3d91 100644 --- a/src/card/base/ReaderManagerWorker.h +++ b/src/card/base/ReaderManagerWorker.h @@ -1,7 +1,7 @@ /*! * \brief Worker implementation of ReaderManger thread * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ResetRetryCounterBuilder.cpp b/src/card/base/ResetRetryCounterBuilder.cpp index e477f4ca8..f8ad35060 100644 --- a/src/card/base/ResetRetryCounterBuilder.cpp +++ b/src/card/base/ResetRetryCounterBuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ResetRetryCounterBuilder.h" diff --git a/src/card/base/ResetRetryCounterBuilder.h b/src/card/base/ResetRetryCounterBuilder.h index a7e9059c3..6bddeca2d 100644 --- a/src/card/base/ResetRetryCounterBuilder.h +++ b/src/card/base/ResetRetryCounterBuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/ResponseApdu.cpp b/src/card/base/ResponseApdu.cpp index d2f12fe23..ada602ba4 100644 --- a/src/card/base/ResponseApdu.cpp +++ b/src/card/base/ResponseApdu.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ResponseApdu.h" diff --git a/src/card/base/ResponseApdu.h b/src/card/base/ResponseApdu.h index d13f80e03..e918216ab 100644 --- a/src/card/base/ResponseApdu.h +++ b/src/card/base/ResponseApdu.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -85,12 +85,14 @@ class ResponseApdu private: static const int RETURN_CODE_LENGTH = 2; + protected: + virtual void setBuffer(const QByteArray& pBuffer); + public: explicit ResponseApdu(StatusCode pStatusCode); explicit ResponseApdu(const QByteArray& pBuffer = QByteArray()); virtual ~ResponseApdu() = default; - virtual void setBuffer(const QByteArray& pBuffer); QByteArray getData() const; int getDataLength() const; StatusCode getReturnCode() const; @@ -101,4 +103,19 @@ class ResponseApdu CardReturnCode getCardReturnCode() const; }; +struct ResponseApduResult +{ + CardReturnCode mReturnCode = CardReturnCode::UNDEFINED; + ResponseApdu mResponseApdu = ResponseApdu(); +}; + +#ifndef QT_NO_DEBUG +inline bool operator ==(const ResponseApduResult& pLeft, const ResponseApduResult& pRight) +{ + return pLeft.mReturnCode == pRight.mReturnCode && pLeft.mResponseApdu.getBuffer() == pRight.mResponseApdu.getBuffer(); +} + + +#endif + } // namespace governikus diff --git a/src/card/base/SecureMessagingResponse.cpp b/src/card/base/SecureMessagingResponse.cpp index 32a643603..7bb470b39 100644 --- a/src/card/base/SecureMessagingResponse.cpp +++ b/src/card/base/SecureMessagingResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "SecureMessagingResponse.h" diff --git a/src/card/base/SecureMessagingResponse.h b/src/card/base/SecureMessagingResponse.h index 667bc08b7..f4fdc7516 100644 --- a/src/card/base/SecureMessagingResponse.h +++ b/src/card/base/SecureMessagingResponse.h @@ -1,7 +1,7 @@ /*! * \brief Response APDU for SecureMessaging * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/SelectBuilder.cpp b/src/card/base/SelectBuilder.cpp index f268c6955..6165eeda3 100644 --- a/src/card/base/SelectBuilder.cpp +++ b/src/card/base/SelectBuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SelectBuilder.h" diff --git a/src/card/base/SelectBuilder.h b/src/card/base/SelectBuilder.h index 01a2e27f2..f0f69a00c 100644 --- a/src/card/base/SelectBuilder.h +++ b/src/card/base/SelectBuilder.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/SmartCardDefinitions.cpp b/src/card/base/SmartCardDefinitions.cpp index 90052d9a3..b839903d2 100644 --- a/src/card/base/SmartCardDefinitions.cpp +++ b/src/card/base/SmartCardDefinitions.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SmartCardDefinitions.h" diff --git a/src/card/base/SmartCardDefinitions.h b/src/card/base/SmartCardDefinitions.h index 98121d94e..9665b47f7 100644 --- a/src/card/base/SmartCardDefinitions.h +++ b/src/card/base/SmartCardDefinitions.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/ASN1TemplateUtil.cpp b/src/card/base/asn1/ASN1TemplateUtil.cpp index 105cac032..27af8457c 100644 --- a/src/card/base/asn1/ASN1TemplateUtil.cpp +++ b/src/card/base/asn1/ASN1TemplateUtil.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "ASN1TemplateUtil.h" diff --git a/src/card/base/asn1/ASN1TemplateUtil.h b/src/card/base/asn1/ASN1TemplateUtil.h index 4eee63798..b35d76e12 100644 --- a/src/card/base/asn1/ASN1TemplateUtil.h +++ b/src/card/base/asn1/ASN1TemplateUtil.h @@ -1,7 +1,7 @@ /*! * \brief Utility template functions for encoding and decoding of ASN.1 types * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/ASN1Util.cpp b/src/card/base/asn1/ASN1Util.cpp index bac4c3069..c56e892d8 100644 --- a/src/card/base/asn1/ASN1Util.cpp +++ b/src/card/base/asn1/ASN1Util.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" @@ -45,7 +45,7 @@ QByteArray Asn1ObjectUtil::convertTo(const ASN1_OBJECT* pAsn1Object) QByteArray Asn1ObjectUtil::getValue(const ASN1_OBJECT* pAsn1Object) { #if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER) - return QByteArray(reinterpret_cast(pAsn1Object->data), pAsn1Object->length); + return QByteArray(reinterpret_cast(pAsn1Object->data), pAsn1Object->length); #else const size_t len = OBJ_length(pAsn1Object); diff --git a/src/card/base/asn1/ASN1Util.h b/src/card/base/asn1/ASN1Util.h index b8df4acf7..9755543a5 100644 --- a/src/card/base/asn1/ASN1Util.h +++ b/src/card/base/asn1/ASN1Util.h @@ -1,7 +1,7 @@ /*! * \brief Utility functions, templates and other ASN.1 related helper stuff * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/AccessRoleAndRight.cpp b/src/card/base/asn1/AccessRoleAndRight.cpp index 4bd9787d4..f415a9293 100644 --- a/src/card/base/asn1/AccessRoleAndRight.cpp +++ b/src/card/base/asn1/AccessRoleAndRight.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "AccessRoleAndRight.h" @@ -39,6 +39,10 @@ const QList& AccessRoleAndRightsUtil::allDisplayedOrderedRights() mAllDisplayedOrderedRights += AccessRight::READ_DG19; mAllDisplayedOrderedRights += AccessRight::INSTALL_QUAL_CERT; mAllDisplayedOrderedRights += AccessRight::INSTALL_CERT; + mAllDisplayedOrderedRights += AccessRight::WRITE_DG17; + mAllDisplayedOrderedRights += AccessRight::WRITE_DG18; + mAllDisplayedOrderedRights += AccessRight::WRITE_DG19; + mAllDisplayedOrderedRights += AccessRight::WRITE_DG20; } return mAllDisplayedOrderedRights; } @@ -96,27 +100,28 @@ const QList& AccessRoleAndRightsUtil::allRights() } -// TR-03127, Annex C -QString AccessRoleAndRightsUtil::toDisplayText(AccessRight pRight) +bool AccessRoleAndRightsUtil::isWriteAccessRight(AccessRight pRight) { switch (pRight) { case AccessRight::WRITE_DG17: - //: LABEL ALL_PLATFORMS - return tr("WRITE_DG17"); - case AccessRight::WRITE_DG18: - //: LABEL ALL_PLATFORMS - return tr("WRITE_DG18"); - case AccessRight::WRITE_DG19: - //: LABEL ALL_PLATFORMS - return tr("WRITE_DG19"); - case AccessRight::WRITE_DG20: - //: LABEL ALL_PLATFORMS - return tr("WRITE_DG20"); + case AccessRight::WRITE_DG21: + return true; + + default: + return false; + } +} + +// TR-03127, Annex C +QString AccessRoleAndRightsUtil::toDisplayText(AccessRight pRight) +{ + switch (pRight) + { case AccessRight::WRITE_DG21: //: LABEL ALL_PLATFORMS return tr("WRITE_DG21"); @@ -130,19 +135,35 @@ QString AccessRoleAndRightsUtil::toDisplayText(AccessRight pRight) //: LABEL ALL_PLATFORMS return tr("Residence permit II"); + case AccessRight::WRITE_DG20: + //: LABEL ALL_PLATFORMS + return tr("Write residence permit II"); + case AccessRight::READ_DG19: // "Auxiliary conditions" are replaced with "Residence permit I" in agreement with the BMI //: LABEL ALL_PLATFORMS return tr("Residence permit I"); + case AccessRight::WRITE_DG19: + //: LABEL ALL_PLATFORMS + return tr("Write residence permit I"); + case AccessRight::READ_DG18: //: LABEL ALL_PLATFORMS return tr("Community-ID"); + case AccessRight::WRITE_DG18: + //: LABEL ALL_PLATFORMS + return tr("Write community-ID"); + case AccessRight::READ_DG17: //: LABEL ALL_PLATFORMS return tr("Address"); + case AccessRight::WRITE_DG17: + //: LABEL ALL_PLATFORMS + return tr("Write address"); + case AccessRight::READ_DG16: //: LABEL ALL_PLATFORMS return tr("RFU"); diff --git a/src/card/base/asn1/AccessRoleAndRight.h b/src/card/base/asn1/AccessRoleAndRight.h index dbf9ab1cc..5c8f29718 100644 --- a/src/card/base/asn1/AccessRoleAndRight.h +++ b/src/card/base/asn1/AccessRoleAndRight.h @@ -6,7 +6,7 @@ * or otherwise they complain about the qHash() function for AccessRight not being * found. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -65,6 +65,7 @@ defineTypedEnumType(AccessRight, uint, ) // do NOT change any key/value as this is used as an unique identifier! +// if you add entries you need to modify the SDK documentation. #define TYPE(x) static_cast::type>(x) defineTypedEnumType(AccessRightNames, std::underlying_type::type, ResidencePermitII = TYPE(AccessRight::READ_DG20), @@ -84,7 +85,11 @@ defineTypedEnumType(AccessRightNames, std::underlying_type::type, DocumentType = TYPE(AccessRight::READ_DG01), Pseudonym = TYPE(AccessRight::RESTRICTED_IDENTIFICATION), AddressVerification = TYPE(AccessRight::COMMUNITY_ID_VERIFICATION), - AgeVerification = TYPE(AccessRight::AGE_VERIFICATION) + AgeVerification = TYPE(AccessRight::AGE_VERIFICATION), + WriteAddress = TYPE(AccessRight::WRITE_DG17), + WriteCommunityID = TYPE(AccessRight::WRITE_DG18), + WriteResidencePermitI = TYPE(AccessRight::WRITE_DG19), + WriteResidencePermitII = TYPE(AccessRight::WRITE_DG20) ) #undef TYPE @@ -113,6 +118,7 @@ class AccessRoleAndRightsUtil public: static const QList& allDisplayedOrderedRights(); static const QList& allRights(); + static bool isWriteAccessRight(AccessRight pRight); static QString toDisplayText(AccessRight pRight); static QLatin1String toTechnicalName(AccessRight pRight); static bool fromTechnicalName(const QString& pStr, const std::function& pFunc); diff --git a/src/card/base/asn1/AuthenticatedAuxiliaryData.cpp b/src/card/base/asn1/AuthenticatedAuxiliaryData.cpp index 25ae8bec3..2d48cec51 100644 --- a/src/card/base/asn1/AuthenticatedAuxiliaryData.cpp +++ b/src/card/base/asn1/AuthenticatedAuxiliaryData.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AuthenticatedAuxiliaryData.h" diff --git a/src/card/base/asn1/AuthenticatedAuxiliaryData.h b/src/card/base/asn1/AuthenticatedAuxiliaryData.h index da0e5286f..a4f47383d 100644 --- a/src/card/base/asn1/AuthenticatedAuxiliaryData.h +++ b/src/card/base/asn1/AuthenticatedAuxiliaryData.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of AuthenticatedAuxiliaryData. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -60,6 +60,7 @@ class AuthenticatedAuxiliaryData { friend class ::test_AuxiliaryAuthenticatedData; friend class QSharedPointer; + QSharedPointer mData; explicit AuthenticatedAuxiliaryData(const QSharedPointer& pData); diff --git a/src/card/base/asn1/CVCertificate.cpp b/src/card/base/asn1/CVCertificate.cpp index 6ee600272..1ce07f50d 100644 --- a/src/card/base/asn1/CVCertificate.cpp +++ b/src/card/base/asn1/CVCertificate.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CVCertificate.h" diff --git a/src/card/base/asn1/CVCertificate.h b/src/card/base/asn1/CVCertificate.h index 049728dfb..fce70c159 100644 --- a/src/card/base/asn1/CVCertificate.h +++ b/src/card/base/asn1/CVCertificate.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of Card Verifiable Certificate, CVC. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/CVCertificateBody.cpp b/src/card/base/asn1/CVCertificateBody.cpp index d0e88dd6a..3abd7a560 100644 --- a/src/card/base/asn1/CVCertificateBody.cpp +++ b/src/card/base/asn1/CVCertificateBody.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CVCertificateBody.h" diff --git a/src/card/base/asn1/CVCertificateBody.h b/src/card/base/asn1/CVCertificateBody.h index 87ca4cf75..58b62de5c 100644 --- a/src/card/base/asn1/CVCertificateBody.h +++ b/src/card/base/asn1/CVCertificateBody.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/CVCertificateChain.cpp b/src/card/base/asn1/CVCertificateChain.cpp index 7eef8e494..6951f71c3 100644 --- a/src/card/base/asn1/CVCertificateChain.cpp +++ b/src/card/base/asn1/CVCertificateChain.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CVCertificateChain.h" diff --git a/src/card/base/asn1/CVCertificateChain.h b/src/card/base/asn1/CVCertificateChain.h index 444cd0e2f..d544e455a 100644 --- a/src/card/base/asn1/CVCertificateChain.h +++ b/src/card/base/asn1/CVCertificateChain.h @@ -5,7 +5,7 @@ * (The holder is equivalent to the Subject-DN, the authority reference * is equivalent to the Issuer-DN.) * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/CVCertificateChainBuilder.cpp b/src/card/base/asn1/CVCertificateChainBuilder.cpp index 7d4e04575..ec9aff6a8 100644 --- a/src/card/base/asn1/CVCertificateChainBuilder.cpp +++ b/src/card/base/asn1/CVCertificateChainBuilder.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CVCertificateChainBuilder.h" diff --git a/src/card/base/asn1/CVCertificateChainBuilder.h b/src/card/base/asn1/CVCertificateChainBuilder.h index 3bb95467f..dc62870a1 100644 --- a/src/card/base/asn1/CVCertificateChainBuilder.h +++ b/src/card/base/asn1/CVCertificateChainBuilder.h @@ -1,7 +1,7 @@ /*! * \brief Builder for CVC chains. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/CertificateDescription.cpp b/src/card/base/asn1/CertificateDescription.cpp index cc22299da..2a2a16733 100644 --- a/src/card/base/asn1/CertificateDescription.cpp +++ b/src/card/base/asn1/CertificateDescription.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CertificateDescription.h" diff --git a/src/card/base/asn1/CertificateDescription.h b/src/card/base/asn1/CertificateDescription.h index cb65bf50f..f2aa35af4 100644 --- a/src/card/base/asn1/CertificateDescription.h +++ b/src/card/base/asn1/CertificateDescription.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of ASN.1 type CertificateDescription with OpenSSL * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -81,7 +81,7 @@ struct CertificateDescription QSet getCommCertificates() const; /*! - * \brief Returns the address of service provider. + * \brief Returns the address of provider. * * \return The address. */ diff --git a/src/card/base/asn1/ChainBuilder.h b/src/card/base/asn1/ChainBuilder.h index dcc2bfbb5..d718af270 100644 --- a/src/card/base/asn1/ChainBuilder.h +++ b/src/card/base/asn1/ChainBuilder.h @@ -5,7 +5,7 @@ * * All found chains are returned by the function /ref ChainBuilder::getChains(). * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/Chat.cpp b/src/card/base/asn1/Chat.cpp index 41e4a52bc..1b6d35106 100644 --- a/src/card/base/asn1/Chat.cpp +++ b/src/card/base/asn1/Chat.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ASN1TemplateUtil.h" diff --git a/src/card/base/asn1/Chat.h b/src/card/base/asn1/Chat.h index 70cab5a1a..b2ea4dca5 100644 --- a/src/card/base/asn1/Chat.h +++ b/src/card/base/asn1/Chat.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of Certificate Holder Authorization Template, CHAT. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/ChipAuthenticationInfo.cpp b/src/card/base/asn1/ChipAuthenticationInfo.cpp index ef19e03e3..1bef4da70 100644 --- a/src/card/base/asn1/ChipAuthenticationInfo.cpp +++ b/src/card/base/asn1/ChipAuthenticationInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ASN1TemplateUtil.h" diff --git a/src/card/base/asn1/ChipAuthenticationInfo.h b/src/card/base/asn1/ChipAuthenticationInfo.h index 4d773f379..fc558b8cf 100644 --- a/src/card/base/asn1/ChipAuthenticationInfo.h +++ b/src/card/base/asn1/ChipAuthenticationInfo.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of ChipAuthenticationInfo * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -40,6 +40,7 @@ class ChipAuthenticationInfo : public SecurityInfo { friend class QSharedPointer; + const QSharedPointer mDelegate; ChipAuthenticationInfo(const QSharedPointer& pDelegate); diff --git a/src/card/base/asn1/EFCardSecurity.cpp b/src/card/base/asn1/EFCardSecurity.cpp index 2ec254a51..228b8edf8 100644 --- a/src/card/base/asn1/EFCardSecurity.cpp +++ b/src/card/base/asn1/EFCardSecurity.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ASN1TemplateUtil.h" diff --git a/src/card/base/asn1/EFCardSecurity.h b/src/card/base/asn1/EFCardSecurity.h index 1be62ad49..61541f2e3 100644 --- a/src/card/base/asn1/EFCardSecurity.h +++ b/src/card/base/asn1/EFCardSecurity.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of EFCardSecurity * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ @@ -87,6 +87,7 @@ namespace governikus class EFCardSecurity { friend class QSharedPointer; + const QSharedPointer mSecurityInfos; explicit EFCardSecurity(const QSharedPointer& pSecurityInfos); diff --git a/src/card/base/asn1/EcdsaPublicKey.cpp b/src/card/base/asn1/EcdsaPublicKey.cpp index b413002d9..73df37a8d 100644 --- a/src/card/base/asn1/EcdsaPublicKey.cpp +++ b/src/card/base/asn1/EcdsaPublicKey.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ASN1TemplateUtil.h" diff --git a/src/card/base/asn1/EcdsaPublicKey.h b/src/card/base/asn1/EcdsaPublicKey.h index 5c7b464a1..66488bc4d 100644 --- a/src/card/base/asn1/EcdsaPublicKey.h +++ b/src/card/base/asn1/EcdsaPublicKey.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/KnownOIDs.cpp b/src/card/base/asn1/KnownOIDs.cpp index efeaeba79..2d0ce4400 100644 --- a/src/card/base/asn1/KnownOIDs.cpp +++ b/src/card/base/asn1/KnownOIDs.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "KnownOIDs.h" diff --git a/src/card/base/asn1/KnownOIDs.h b/src/card/base/asn1/KnownOIDs.h index e09385f11..78550a3d9 100644 --- a/src/card/base/asn1/KnownOIDs.h +++ b/src/card/base/asn1/KnownOIDs.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/PaceInfo.cpp b/src/card/base/asn1/PaceInfo.cpp index 27d09ce08..6650663b8 100644 --- a/src/card/base/asn1/PaceInfo.cpp +++ b/src/card/base/asn1/PaceInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/card/base/asn1/PaceInfo.h b/src/card/base/asn1/PaceInfo.h index 496bfdf06..c18d51ffb 100644 --- a/src/card/base/asn1/PaceInfo.h +++ b/src/card/base/asn1/PaceInfo.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of PACEInfo * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -61,6 +61,7 @@ class PaceInfo : public SecurityInfo { friend class QSharedPointer; + const QSharedPointer mDelegate; explicit PaceInfo(const QSharedPointer& pDelegate); diff --git a/src/card/base/asn1/SecurityInfo.cpp b/src/card/base/asn1/SecurityInfo.cpp index a14f7ec26..ed4044c7a 100644 --- a/src/card/base/asn1/SecurityInfo.cpp +++ b/src/card/base/asn1/SecurityInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ASN1TemplateUtil.h" diff --git a/src/card/base/asn1/SecurityInfo.h b/src/card/base/asn1/SecurityInfo.h index 2b5230ad1..5514c1fdd 100644 --- a/src/card/base/asn1/SecurityInfo.h +++ b/src/card/base/asn1/SecurityInfo.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of SecurityInfo * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -46,6 +46,7 @@ class SecurityInfo { Q_DISABLE_COPY(SecurityInfo) friend class QSharedPointer; + const QSharedPointer mDelegate; explicit SecurityInfo(const QSharedPointer& pDelegate); diff --git a/src/card/base/asn1/SecurityInfos.cpp b/src/card/base/asn1/SecurityInfos.cpp index 60667de1b..4e2ab2eab 100644 --- a/src/card/base/asn1/SecurityInfos.cpp +++ b/src/card/base/asn1/SecurityInfos.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ASN1TemplateUtil.h" diff --git a/src/card/base/asn1/SecurityInfos.h b/src/card/base/asn1/SecurityInfos.h index 93531c0d9..ca2f8d819 100644 --- a/src/card/base/asn1/SecurityInfos.h +++ b/src/card/base/asn1/SecurityInfos.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of SecurityInfos * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/asn1/SignatureChecker.cpp b/src/card/base/asn1/SignatureChecker.cpp index d70d39923..f33a22760 100644 --- a/src/card/base/asn1/SignatureChecker.cpp +++ b/src/card/base/asn1/SignatureChecker.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/SignatureChecker.h" diff --git a/src/card/base/asn1/SignatureChecker.h b/src/card/base/asn1/SignatureChecker.h index 3e6b35b92..90794fe90 100644 --- a/src/card/base/asn1/SignatureChecker.h +++ b/src/card/base/asn1/SignatureChecker.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/BaseCardCommand.cpp b/src/card/base/command/BaseCardCommand.cpp index 8b89df433..eb0f24279 100644 --- a/src/card/base/command/BaseCardCommand.cpp +++ b/src/card/base/command/BaseCardCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "BaseCardCommand.h" diff --git a/src/card/base/command/BaseCardCommand.h b/src/card/base/command/BaseCardCommand.h index c76ec1434..523c84052 100644 --- a/src/card/base/command/BaseCardCommand.h +++ b/src/card/base/command/BaseCardCommand.h @@ -1,7 +1,7 @@ /*! * \brief Holds some basic card control commands * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/CreateCardConnectionCommand.cpp b/src/card/base/command/CreateCardConnectionCommand.cpp index 0de85b1ea..2b9387ce4 100644 --- a/src/card/base/command/CreateCardConnectionCommand.cpp +++ b/src/card/base/command/CreateCardConnectionCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "CreateCardConnectionCommand.h" diff --git a/src/card/base/command/CreateCardConnectionCommand.h b/src/card/base/command/CreateCardConnectionCommand.h index 6f6bca06d..2eacb8577 100644 --- a/src/card/base/command/CreateCardConnectionCommand.h +++ b/src/card/base/command/CreateCardConnectionCommand.h @@ -1,7 +1,7 @@ /*! * \brief Command implementation for asynchronous CardConnection creation * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/DestroyPaceChannelCommand.cpp b/src/card/base/command/DestroyPaceChannelCommand.cpp index 2302c65f8..c639d77da 100644 --- a/src/card/base/command/DestroyPaceChannelCommand.cpp +++ b/src/card/base/command/DestroyPaceChannelCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnection.h" diff --git a/src/card/base/command/DestroyPaceChannelCommand.h b/src/card/base/command/DestroyPaceChannelCommand.h index b3610c8ad..1db1f8bc3 100644 --- a/src/card/base/command/DestroyPaceChannelCommand.h +++ b/src/card/base/command/DestroyPaceChannelCommand.h @@ -1,7 +1,7 @@ /*! * \brief Command to destroy a Pace channel. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/DidAuthenticateEAC1Command.cpp b/src/card/base/command/DidAuthenticateEAC1Command.cpp index d8c6879d8..e700d5152 100644 --- a/src/card/base/command/DidAuthenticateEAC1Command.cpp +++ b/src/card/base/command/DidAuthenticateEAC1Command.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DidAuthenticateEAC1Command.h" @@ -26,8 +26,8 @@ DidAuthenticateEAC1Command::DidAuthenticateEAC1Command(QSharedPointertransmit(GetChallengeBuilder().build(), response); + auto [returnCode, response] = mCardConnectionWorker->transmit(GetChallengeBuilder().build()); + mReturnCode = returnCode; if (mReturnCode != CardReturnCode::OK || response.getReturnCode() != StatusCode::SUCCESS) { qCWarning(card) << "GetChallenge failed"; diff --git a/src/card/base/command/DidAuthenticateEAC1Command.h b/src/card/base/command/DidAuthenticateEAC1Command.h index 1062a496a..3ccfb1ec7 100644 --- a/src/card/base/command/DidAuthenticateEAC1Command.h +++ b/src/card/base/command/DidAuthenticateEAC1Command.h @@ -1,7 +1,7 @@ /*! * \brief Command to perform the DID Authenticate EAC1 process. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/DidAuthenticateEAC2Command.cpp b/src/card/base/command/DidAuthenticateEAC2Command.cpp index ab30c38c5..a804619e0 100644 --- a/src/card/base/command/DidAuthenticateEAC2Command.cpp +++ b/src/card/base/command/DidAuthenticateEAC2Command.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DidAuthenticateEAC2Command.h" @@ -102,7 +102,7 @@ void DidAuthenticateEAC2Command::internalExecute() const auto& chipAuthenticationInfo = chipAuthenticationInfoList.at(0); qCDebug(card) << "Chose ChipAuthenticationInfo(0): protocol" << chipAuthenticationInfo->getProtocol() << ", keyId" << chipAuthenticationInfo->getKeyId().toHex(); - mReturnCode = performChipAuthentication(chipAuthenticationInfo, ephemeralPublicKey, mNonceAsHex, mAuthTokenAsHex); + mReturnCode = performChipAuthentication(chipAuthenticationInfo, ephemeralPublicKey); if (CardReturnCode::OK == mReturnCode) { mCardConnectionWorker->stopSecureMessaging(); @@ -118,14 +118,13 @@ CardReturnCode DidAuthenticateEAC2Command::putCertificateChain(const CVCertifica MSEBuilder mseBuilder(MSEBuilder::P1::SET_DST, MSEBuilder::P2::COMPUTE_DIGITAL_SIGNATURE); mseBuilder.setPublicKey(car); - ResponseApdu mseResult; qCDebug(card) << "Performing TA MSE:Set DST"; qCDebug(card) << "Sending CAR" << car; - CardReturnCode returnCode = mCardConnectionWorker->transmit(mseBuilder.build(), mseResult); - if (returnCode != CardReturnCode::OK) + auto [mseReturnCode, mseResult] = mCardConnectionWorker->transmit(mseBuilder.build()); + if (mseReturnCode != CardReturnCode::OK) { qCWarning(card) << "TA MSE:Set DST failed."; - return returnCode; + return mseReturnCode; } if (mseResult.getReturnCode() != StatusCode::SUCCESS) @@ -140,11 +139,10 @@ CardReturnCode DidAuthenticateEAC2Command::putCertificateChain(const CVCertifica qCDebug(card) << "Performing TA PSO:Verify Certificate"; qCDebug(card) << "Sending certificate" << *cvCertificate; - ResponseApdu psoResult; - returnCode = mCardConnectionWorker->transmit(psoBuilder.build(), psoResult); - if (returnCode != CardReturnCode::OK) + auto [psoReturnCode, psoResult] = mCardConnectionWorker->transmit(psoBuilder.build()); + if (psoReturnCode != CardReturnCode::OK) { - return returnCode; + return psoReturnCode; } if (psoResult.getReturnCode() != StatusCode::SUCCESS) @@ -171,30 +169,30 @@ CardReturnCode DidAuthenticateEAC2Command::performTerminalAuthentication(const Q mseBuilder.setAuxiliaryData(auxiliaryData); mseBuilder.setEphemeralPublicKey(compressedEphemeralPublicKey); - ResponseApdu mseResult; qCDebug(card) << "Performing TA MSE:Set AT"; - CardReturnCode returnCode = mCardConnectionWorker->transmit(mseBuilder.build(), mseResult); - if (returnCode != CardReturnCode::OK) + auto[mseReturnCode, mseResult] = mCardConnectionWorker->transmit(mseBuilder.build()); + if (mseReturnCode != CardReturnCode::OK) { - qCWarning(card) << "TA MSE:Set AT failed:" << CardReturnCodeUtil::toGlobalStatus(returnCode); - return returnCode; + qCWarning(card) << "TA MSE:Set AT failed:" << CardReturnCodeUtil::toGlobalStatus(mseReturnCode); + return mseReturnCode; } + if (mseResult.getReturnCode() != StatusCode::SUCCESS) { qCWarning(card) << "TA MSE:Set AT failed:" << mseResult.getReturnCode(); return CardReturnCode::PROTOCOL_ERROR; } - ResponseApdu eaResult; EABuilder eaBuilder; eaBuilder.setSignature(signature); qCDebug(card) << "Performing TA External Authenticate"; - returnCode = mCardConnectionWorker->transmit(eaBuilder.build(), eaResult); - if (returnCode != CardReturnCode::OK) + auto [eaReturnCode, eaResult] = mCardConnectionWorker->transmit(eaBuilder.build()); + if (eaReturnCode != CardReturnCode::OK) { - qCWarning(card) << "TA External Authenticate failed:" << CardReturnCodeUtil::toGlobalStatus(returnCode); - return returnCode; + qCWarning(card) << "TA External Authenticate failed:" << CardReturnCodeUtil::toGlobalStatus(eaReturnCode); + return eaReturnCode; } + if (eaResult.getReturnCode() != StatusCode::SUCCESS) { qCWarning(card) << "TA External Authenticate failed:" << eaResult.getReturnCode(); @@ -206,21 +204,19 @@ CardReturnCode DidAuthenticateEAC2Command::performTerminalAuthentication(const Q CardReturnCode DidAuthenticateEAC2Command::performChipAuthentication(QSharedPointer pChipAuthInfo, - const QByteArray& ephemeralPublicKey, - QByteArray& pNonceAsHex, - QByteArray& pAuthTokenAsHex) + const QByteArray& ephemeralPublicKey) { - ResponseApdu mseResult; MSEBuilder mseBuilder(MSEBuilder::P1::COMPUTE_DIGITAL_SIGNATURE, MSEBuilder::P2::SET_AT); mseBuilder.setOid(pChipAuthInfo->getProtocolValueBytes()); mseBuilder.setPrivateKey(pChipAuthInfo->getKeyId()); qCDebug(card) << "Performing CA MSE:Set AT"; - CardReturnCode returnCode = mCardConnectionWorker->transmit(mseBuilder.build(), mseResult); - if (returnCode != CardReturnCode::OK) + auto [mseReturnCode, mseResult] = mCardConnectionWorker->transmit(mseBuilder.build()); + if (mseReturnCode != CardReturnCode::OK) { - return returnCode; + return mseReturnCode; } + if (mseResult.getReturnCode() != StatusCode::SUCCESS) { qCWarning(card) << "CA MSE:Set AT failed:" << mseResult.getReturnCode(); @@ -231,22 +227,21 @@ CardReturnCode DidAuthenticateEAC2Command::performChipAuthentication(QSharedPoin gaBuilder.setCaEphemeralPublicKey(ephemeralPublicKey); qCDebug(card) << "Performing CA General Authenticate"; - ResponseApdu responseApdu; - returnCode = mCardConnectionWorker->transmit(gaBuilder.build(), responseApdu); - if (returnCode != CardReturnCode::OK) + auto [gaReturnCode, gaGenericResponse] = mCardConnectionWorker->transmit(gaBuilder.build()); + if (gaReturnCode != CardReturnCode::OK) { - return returnCode; + return gaReturnCode; } - if (responseApdu.getReturnCode() != StatusCode::SUCCESS) + if (gaGenericResponse.getReturnCode() != StatusCode::SUCCESS) { - qCWarning(card) << "CA General Authenticate failed:" << responseApdu.getReturnCode(); + qCWarning(card) << "CA General Authenticate failed:" << gaGenericResponse.getReturnCode(); return CardReturnCode::PROTOCOL_ERROR; } - GAChipAuthenticationResponse gaResponse(responseApdu); - pNonceAsHex += gaResponse.getNonce().toHex(); - pAuthTokenAsHex += gaResponse.getAuthenticationToken().toHex(); + const GAChipAuthenticationResponse gaResponse(gaGenericResponse); + mNonceAsHex += gaResponse.getNonce().toHex(); + mAuthTokenAsHex += gaResponse.getAuthenticationToken().toHex(); return CardReturnCode::OK; } diff --git a/src/card/base/command/DidAuthenticateEAC2Command.h b/src/card/base/command/DidAuthenticateEAC2Command.h index 1a81ca25a..d040063bf 100644 --- a/src/card/base/command/DidAuthenticateEAC2Command.h +++ b/src/card/base/command/DidAuthenticateEAC2Command.h @@ -1,7 +1,7 @@ /*! * \brief Command to perform the DID Authenticate EAC2 process. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -38,9 +38,7 @@ class DidAuthenticateEAC2Command const QByteArray& compressedEphemeralPublicKey, const QByteArray& signature); CardReturnCode performChipAuthentication(QSharedPointer pChipAuthInfo, - const QByteArray& ephemeralPublicKey, - QByteArray& pNonceAsHex, - QByteArray& pAuthTokenAsHex); + const QByteArray& ephemeralPublicKey); protected: virtual void internalExecute() override; diff --git a/src/card/base/command/EstablishPaceChannelCommand.cpp b/src/card/base/command/EstablishPaceChannelCommand.cpp index 2cbe97578..f52caf79c 100644 --- a/src/card/base/command/EstablishPaceChannelCommand.cpp +++ b/src/card/base/command/EstablishPaceChannelCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "EstablishPaceChannelCommand.h" diff --git a/src/card/base/command/EstablishPaceChannelCommand.h b/src/card/base/command/EstablishPaceChannelCommand.h index cfccb58b1..86972d7cd 100644 --- a/src/card/base/command/EstablishPaceChannelCommand.h +++ b/src/card/base/command/EstablishPaceChannelCommand.h @@ -1,7 +1,7 @@ /*! * \brief Command to change the PIN of a card. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/SetEidPinCommand.cpp b/src/card/base/command/SetEidPinCommand.cpp index 5b22f4a34..3a902cc13 100644 --- a/src/card/base/command/SetEidPinCommand.cpp +++ b/src/card/base/command/SetEidPinCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "SetEidPinCommand.h" @@ -19,7 +19,9 @@ SetEidPinCommand::SetEidPinCommand(QSharedPointer pCardCon void SetEidPinCommand::internalExecute() { - mReturnCode = mCardConnectionWorker->setEidPin(mNewPin, mTimeoutSeconds, mResponseApdu); + auto [returnCode, responseApdu] = mCardConnectionWorker->setEidPin(mNewPin, mTimeoutSeconds); + mReturnCode = returnCode; + mResponseApdu = responseApdu; } diff --git a/src/card/base/command/SetEidPinCommand.h b/src/card/base/command/SetEidPinCommand.h index 85745a7e8..a399a8701 100644 --- a/src/card/base/command/SetEidPinCommand.h +++ b/src/card/base/command/SetEidPinCommand.h @@ -1,7 +1,7 @@ /*! * \brief Command to set the Eid PIN of a card. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/TransmitCommand.cpp b/src/card/base/command/TransmitCommand.cpp index e8047679c..02ebe7006 100644 --- a/src/card/base/command/TransmitCommand.cpp +++ b/src/card/base/command/TransmitCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "TransmitCommand.h" @@ -54,8 +54,8 @@ void TransmitCommand::internalExecute() for (const auto& inputApduInfo : mInputApduInfos) { - ResponseApdu response; - mReturnCode = mCardConnectionWorker->transmit(inputApduInfo.getInputApdu(), response); + auto [returnCode, response] = mCardConnectionWorker->transmit(inputApduInfo.getInputApdu()); + mReturnCode = returnCode; if (mReturnCode != CardReturnCode::OK) { qCWarning(card) << "Transmit unsuccessful. Return code:" << CardReturnCodeUtil::toGlobalStatus(mReturnCode); diff --git a/src/card/base/command/TransmitCommand.h b/src/card/base/command/TransmitCommand.h index 9b572de20..f98801dad 100644 --- a/src/card/base/command/TransmitCommand.h +++ b/src/card/base/command/TransmitCommand.h @@ -1,7 +1,7 @@ /*! * \brief Command to transmit data to/from the card. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/UnblockPinCommand.cpp b/src/card/base/command/UnblockPinCommand.cpp index 4f60bdd78..d69864d73 100644 --- a/src/card/base/command/UnblockPinCommand.cpp +++ b/src/card/base/command/UnblockPinCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "UnblockPinCommand.h" @@ -38,8 +38,8 @@ void UnblockPinCommand::internalExecute() } // unblock PIN (reset retry counter) - ResponseApdu response; - mReturnCode = mCardConnectionWorker->transmit(ResetRetryCounterBuilder().build(), response); + auto [returnCode, response] = mCardConnectionWorker->transmit(ResetRetryCounterBuilder().build()); + mReturnCode = returnCode; if (mReturnCode == CardReturnCode::OK && response.getSW1() == SW1::ERROR_COMMAND_NOT_ALLOWED) { mCardConnectionWorker->setPukInoperative(); diff --git a/src/card/base/command/UnblockPinCommand.h b/src/card/base/command/UnblockPinCommand.h index 264f565d6..2bcca8f8b 100644 --- a/src/card/base/command/UnblockPinCommand.h +++ b/src/card/base/command/UnblockPinCommand.h @@ -1,7 +1,7 @@ /*! * \brief Command to unblock the PIN of a card. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/command/UpdateRetryCounterCommand.cpp b/src/card/base/command/UpdateRetryCounterCommand.cpp index b3d8d7df2..2e937ce0b 100644 --- a/src/card/base/command/UpdateRetryCounterCommand.cpp +++ b/src/card/base/command/UpdateRetryCounterCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "UpdateRetryCounterCommand.h" diff --git a/src/card/base/command/UpdateRetryCounterCommand.h b/src/card/base/command/UpdateRetryCounterCommand.h index b331309f5..ad8110986 100644 --- a/src/card/base/command/UpdateRetryCounterCommand.h +++ b/src/card/base/command/UpdateRetryCounterCommand.h @@ -1,7 +1,7 @@ /*! * \brief Command to update the retry counter of a card. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/CipherMac.cpp b/src/card/base/pace/CipherMac.cpp index 7172ba4a8..8d468aee2 100644 --- a/src/card/base/pace/CipherMac.cpp +++ b/src/card/base/pace/CipherMac.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/CipherMac.h" diff --git a/src/card/base/pace/CipherMac.h b/src/card/base/pace/CipherMac.h index 1738f3a57..d677a1cd0 100644 --- a/src/card/base/pace/CipherMac.h +++ b/src/card/base/pace/CipherMac.h @@ -1,7 +1,7 @@ /*! * \brief CMAC implementation to be used in PACE protocol. See TR 03110. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/DomainParameterMapping.h b/src/card/base/pace/DomainParameterMapping.h index a713c7011..8d39209db 100644 --- a/src/card/base/pace/DomainParameterMapping.h +++ b/src/card/base/pace/DomainParameterMapping.h @@ -1,7 +1,7 @@ /*! * \brief Mapping protocol for PACE domain parameters. For details see TR 03110. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/EstablishPaceChannelCode.h b/src/card/base/pace/EstablishPaceChannelCode.h index 4ea69770b..4c35a4237 100644 --- a/src/card/base/pace/EstablishPaceChannelCode.h +++ b/src/card/base/pace/EstablishPaceChannelCode.h @@ -1,7 +1,7 @@ /*! * \brief EstablishPaceChannel error code definitions * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/KeyAgreement.cpp b/src/card/base/pace/KeyAgreement.cpp index 55d0c4b59..f2cf05bba 100644 --- a/src/card/base/pace/KeyAgreement.cpp +++ b/src/card/base/pace/KeyAgreement.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ @@ -185,11 +185,10 @@ KeyAgreementStatus KeyAgreement::performMutualAuthenticate() KeyAgreement::CardResult KeyAgreement::transmitGAEncryptedNonce() { - GABuilder builder(CommandApdu::CLA_COMMAND_CHAINING); - ResponseApdu responseApdu; + GABuilder commandBuilder(CommandApdu::CLA_COMMAND_CHAINING); - const CardReturnCode returnCode = mCardConnectionWorker->transmit(builder.build(), responseApdu); - GAEncryptedNonceResponse response(responseApdu); + auto [returnCode, responseApdu] = mCardConnectionWorker->transmit(commandBuilder.build()); + const GAEncryptedNonceResponse response(responseApdu); return createTransmitResult(returnCode, response.getReturnCode(), response.getEncryptedNonce(), "Error on GA (Encrypted Nonce):"); } @@ -198,9 +197,8 @@ KeyAgreement::CardResult KeyAgreement::transmitGAEphemeralPublicKey(const QByteA { GABuilder commandBuilder(CommandApdu::CLA_COMMAND_CHAINING); commandBuilder.setPaceEphemeralPublicKey(pEphemeralPublicKey); - ResponseApdu responseApdu; - const CardReturnCode returnCode = mCardConnectionWorker->transmit(commandBuilder.build(), responseApdu); + auto [returnCode, responseApdu] = mCardConnectionWorker->transmit(commandBuilder.build()); const GAPerformKeyAgreementResponse response(responseApdu); return createTransmitResult(returnCode, response.getReturnCode(), response.getEphemeralPublicKey(), "Error on GA(Perform Key Agreement):"); } @@ -211,9 +209,8 @@ KeyAgreement::CardResult KeyAgreement::transmitGAMappingData(const QByteArray& p // sende den PublicKey (D.3.4.) GABuilder commandBuilder(CommandApdu::CLA_COMMAND_CHAINING); commandBuilder.setPaceMappingData(pMappingData); - ResponseApdu responseApdu; - const CardReturnCode returnCode = mCardConnectionWorker->transmit(commandBuilder.build(), responseApdu); + auto [returnCode, responseApdu] = mCardConnectionWorker->transmit(commandBuilder.build()); const GAMapNonceResponse response(responseApdu); return createTransmitResult(returnCode, response.getReturnCode(), response.getMappingData(), "Error on GA(Mapping Data):"); } @@ -223,14 +220,13 @@ GAMutualAuthenticationResponse KeyAgreement::transmitGAMutualAuthentication(cons { GABuilder commandBuilder(CommandApdu::CLA); commandBuilder.setPaceAuthenticationToken(pMutualAuthenticationData); - ResponseApdu response; - const CardReturnCode returnCode = mCardConnectionWorker->transmit(commandBuilder.build(), response); - if (returnCode != CardReturnCode::OK || response.getReturnCode() != StatusCode::SUCCESS) + auto [returnCode, responseApdu] = mCardConnectionWorker->transmit(commandBuilder.build()); + if (returnCode != CardReturnCode::OK || responseApdu.getReturnCode() != StatusCode::SUCCESS) { - qCCritical(card) << "Error on GA(Mutual Authentication):" << getResponseErrorString(returnCode, response.getReturnCode()); + qCCritical(card) << "Error on GA(Mutual Authentication):" << getResponseErrorString(returnCode, responseApdu.getReturnCode()); } - return GAMutualAuthenticationResponse(response); + return GAMutualAuthenticationResponse(responseApdu); } diff --git a/src/card/base/pace/KeyAgreement.h b/src/card/base/pace/KeyAgreement.h index 3ff1a4560..a878c378d 100644 --- a/src/card/base/pace/KeyAgreement.h +++ b/src/card/base/pace/KeyAgreement.h @@ -1,7 +1,7 @@ /*! * \brief the key agreement protocol use in PACE. For details see TR 03110. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/KeyDerivationFunction.cpp b/src/card/base/pace/KeyDerivationFunction.cpp index 3d2aa93d8..8f7fad93d 100644 --- a/src/card/base/pace/KeyDerivationFunction.cpp +++ b/src/card/base/pace/KeyDerivationFunction.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/KeyDerivationFunction.h" diff --git a/src/card/base/pace/KeyDerivationFunction.h b/src/card/base/pace/KeyDerivationFunction.h index 6e6045659..f19a4757e 100644 --- a/src/card/base/pace/KeyDerivationFunction.h +++ b/src/card/base/pace/KeyDerivationFunction.h @@ -1,7 +1,7 @@ /*! * \brief Creates key according to TR 03110 Part 3 chapters A.2.3 ff. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/PaceHandler.cpp b/src/card/base/pace/PaceHandler.cpp index 1cccf6b6b..09a4c16f4 100644 --- a/src/card/base/pace/PaceHandler.cpp +++ b/src/card/base/pace/PaceHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/PaceHandler.h" @@ -166,11 +166,11 @@ bool PaceHandler::isSupportedProtocol(const QSharedPointer& pPac CardReturnCode PaceHandler::transmitMSESetAT(PacePasswordId pPasswordId) { - CardReturnCode cardReturnCode = PersoSimWorkaround::sendingMseSetAt(mCardConnectionWorker); - if (cardReturnCode != CardReturnCode::OK) + CardReturnCode simCardReturnCode = PersoSimWorkaround::sendingMseSetAt(mCardConnectionWorker); + if (simCardReturnCode != CardReturnCode::OK) { - qCCritical(card) << "Error on MSE:Set AT |" << cardReturnCode; - return cardReturnCode; + qCCritical(card) << "Error on MSE:Set AT |" << simCardReturnCode; + return simCardReturnCode; } MSEBuilder mseBuilder(MSEBuilder::P1::PERFORM_SECURITY_OPERATION, MSEBuilder::P2::SET_AT); @@ -182,8 +182,7 @@ CardReturnCode PaceHandler::transmitMSESetAT(PacePasswordId pPasswordId) mseBuilder.setChat(mChat); } - ResponseApdu response; - cardReturnCode = mCardConnectionWorker->transmit(mseBuilder.build(), response); + auto [cardReturnCode, response] = mCardConnectionWorker->transmit(mseBuilder.build()); mStatusMseSetAt = response.getBuffer().left(2); const StatusCode responseReturnCode = response.getReturnCode(); diff --git a/src/card/base/pace/PaceHandler.h b/src/card/base/pace/PaceHandler.h index 64f5ea255..7152df083 100644 --- a/src/card/base/pace/PaceHandler.h +++ b/src/card/base/pace/PaceHandler.h @@ -1,7 +1,7 @@ /*! * \brief Handler for the PACE protocol. See TR-03110. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/SecureMessaging.cpp b/src/card/base/pace/SecureMessaging.cpp index 544dc5daf..0c3cc79d6 100644 --- a/src/card/base/pace/SecureMessaging.cpp +++ b/src/card/base/pace/SecureMessaging.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/src/card/base/pace/SecureMessaging.h b/src/card/base/pace/SecureMessaging.h index affc28bac..8311ae183 100644 --- a/src/card/base/pace/SecureMessaging.h +++ b/src/card/base/pace/SecureMessaging.h @@ -1,7 +1,7 @@ /*! * \brief Implements TR-03110 v2 part3 --> Secure Messaging. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/SymmetricCipher.cpp b/src/card/base/pace/SymmetricCipher.cpp index f3bfeae15..f099d1e67 100644 --- a/src/card/base/pace/SymmetricCipher.cpp +++ b/src/card/base/pace/SymmetricCipher.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/SymmetricCipher.h" diff --git a/src/card/base/pace/SymmetricCipher.h b/src/card/base/pace/SymmetricCipher.h index 1df7de5c9..9c9543e22 100644 --- a/src/card/base/pace/SymmetricCipher.h +++ b/src/card/base/pace/SymmetricCipher.h @@ -1,7 +1,7 @@ /*! * \brief Symmetric decryption method used for PACE. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/ec/EcUtil.h b/src/card/base/pace/ec/EcUtil.h index 8c25f5fb4..8b1ff1822 100644 --- a/src/card/base/pace/ec/EcUtil.h +++ b/src/card/base/pace/ec/EcUtil.h @@ -1,7 +1,7 @@ /*! * \brief Elliptic curve utility. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/ec/EcdhGenericMapping.cpp b/src/card/base/pace/ec/EcdhGenericMapping.cpp index 441422fdc..c041c5206 100644 --- a/src/card/base/pace/ec/EcdhGenericMapping.cpp +++ b/src/card/base/pace/ec/EcdhGenericMapping.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/src/card/base/pace/ec/EcdhGenericMapping.h b/src/card/base/pace/ec/EcdhGenericMapping.h index bff92add8..fc71d6dc7 100644 --- a/src/card/base/pace/ec/EcdhGenericMapping.h +++ b/src/card/base/pace/ec/EcdhGenericMapping.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/base/pace/ec/EcdhKeyAgreement.cpp b/src/card/base/pace/ec/EcdhKeyAgreement.cpp index 943c111c2..5bd5595dc 100644 --- a/src/card/base/pace/ec/EcdhKeyAgreement.cpp +++ b/src/card/base/pace/ec/EcdhKeyAgreement.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/ec/EcdhKeyAgreement.h" diff --git a/src/card/base/pace/ec/EcdhKeyAgreement.h b/src/card/base/pace/ec/EcdhKeyAgreement.h index 23d289cdf..0a5f52639 100644 --- a/src/card/base/pace/ec/EcdhKeyAgreement.h +++ b/src/card/base/pace/ec/EcdhKeyAgreement.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -27,7 +27,7 @@ class EcdhKeyAgreement QSharedPointer > mMapping; QSharedPointer mEphemeralCurve; QSharedPointer mTerminalPublicKey; - QSharedPointer mCardPublicKey; + QSharedPointer mCardPublicKey; QPair > determineEphemeralDomainParameters(const QByteArray& pNonce); QPair > performKeyExchange(const QSharedPointer& pCurve); diff --git a/src/card/base/pace/ec/EllipticCurveFactory.cpp b/src/card/base/pace/ec/EllipticCurveFactory.cpp index cb8e37270..8ce0df48f 100644 --- a/src/card/base/pace/ec/EllipticCurveFactory.cpp +++ b/src/card/base/pace/ec/EllipticCurveFactory.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/src/card/base/pace/ec/EllipticCurveFactory.h b/src/card/base/pace/ec/EllipticCurveFactory.h index 3f0f44cce..c2006724a 100644 --- a/src/card/base/pace/ec/EllipticCurveFactory.h +++ b/src/card/base/pace/ec/EllipticCurveFactory.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/AndroidBluetoothAdapter.cpp b/src/card/bluetooth/AndroidBluetoothAdapter.cpp index bf1b84aca..7dd368d6d 100644 --- a/src/card/bluetooth/AndroidBluetoothAdapter.cpp +++ b/src/card/bluetooth/AndroidBluetoothAdapter.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "AndroidBluetoothAdapter.h" diff --git a/src/card/bluetooth/AndroidBluetoothAdapter.h b/src/card/bluetooth/AndroidBluetoothAdapter.h index 18c23b33e..da1bc1213 100644 --- a/src/card/bluetooth/AndroidBluetoothAdapter.h +++ b/src/card/bluetooth/AndroidBluetoothAdapter.h @@ -1,7 +1,7 @@ /*! * \brief This class accesses the java class android.bluetooth.BluetoothAdapter * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/AndroidBluetoothReceiver.java b/src/card/bluetooth/AndroidBluetoothReceiver.java index 09afb71b8..442cdd0f9 100644 --- a/src/card/bluetooth/AndroidBluetoothReceiver.java +++ b/src/card/bluetooth/AndroidBluetoothReceiver.java @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ package com.governikus.ausweisapp2; diff --git a/src/card/bluetooth/BluetoothCard.cpp b/src/card/bluetooth/BluetoothCard.cpp index 0adf99f9c..808b2e84e 100644 --- a/src/card/bluetooth/BluetoothCard.cpp +++ b/src/card/bluetooth/BluetoothCard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothCard.h" @@ -86,18 +86,18 @@ bool BluetoothCard::isConnected() } -CardReturnCode BluetoothCard::transmit(const CommandApdu& pCmd, ResponseApdu& pRes) +ResponseApduResult BluetoothCard::transmit(const CommandApdu& pCmd) { - return transmit(pCmd, pRes, 30); + return transmit(pCmd, 30); } -CardReturnCode BluetoothCard::transmit(const CommandApdu& pCmd, ResponseApdu& pRes, quint8 pTimeoutSeconds) +ResponseApduResult BluetoothCard::transmit(const CommandApdu& pCmd, quint8 pTimeoutSeconds) { if (!isConnected()) { qCCritical(bluetooth) << "Card is not connected, abort transmit"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } qCDebug(bluetooth) << "Transmit command APDU:" << pCmd.getBuffer().toHex(); @@ -106,18 +106,19 @@ CardReturnCode BluetoothCard::transmit(const CommandApdu& pCmd, ResponseApdu& pR if (response.isNull()) { qCCritical(bluetooth) << "Response is empty"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } auto apduResponse = response.staticCast(); if (apduResponse->getResultCode() != BluetoothResultCode::Ok) { qCCritical(bluetooth) << "TransferApduResponse failed:" << apduResponse->getResultCode(); - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - pRes.setBuffer(apduResponse->getResponseAPDU()); - qCDebug(bluetooth) << "Transmit response APDU:" << pRes.getBuffer().toHex(); - return CardReturnCode::OK; + + const ResponseApdu resp(apduResponse->getResponseAPDU()); + qCDebug(bluetooth) << "Transmit response APDU:" << resp.getBuffer().toHex(); + return {CardReturnCode::OK, resp}; } @@ -131,9 +132,7 @@ EstablishPaceChannelOutput BluetoothCard::establishPaceChannel(PacePasswordId pP builder.setChat(pChat); builder.setCertificateDescription(pCertificateDescription); - ResponseApdu response; - - CardReturnCode returnCode = transmit(builder.createCommandDataCcid(), response, pTimeoutSeconds); + auto [returnCode, response] = transmit(builder.createCommandDataCcid(), pTimeoutSeconds); if (returnCode != CardReturnCode::OK) { return returnCode; @@ -148,22 +147,21 @@ EstablishPaceChannelOutput BluetoothCard::establishPaceChannel(PacePasswordId pP CardReturnCode BluetoothCard::destroyPaceChannel() { DestroyPaceChannelBuilder builder; - ResponseApdu response; - return transmit(builder.createCommandDataCcid(), response); + return transmit(builder.createCommandDataCcid()).mReturnCode; } -CardReturnCode BluetoothCard::setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) +ResponseApduResult BluetoothCard::setEidPin(quint8 pTimeoutSeconds) { PinModify pinModify(pTimeoutSeconds); CommandApdu command = pinModify.createCcidForBluetooth(); - CardReturnCode returnCode = transmit(command, pResponseApdu, pTimeoutSeconds); + auto [returnCode, response] = transmit(command, pTimeoutSeconds); if (returnCode != CardReturnCode::OK) { - return returnCode; + return {returnCode, response}; } - PinModifyOutput output(pResponseApdu); - return output.getReturnCode(); + const PinModifyOutput output(response); + return {output.getReturnCode(), response}; } diff --git a/src/card/bluetooth/BluetoothCard.h b/src/card/bluetooth/BluetoothCard.h index 1107c1c89..2ef7e136a 100644 --- a/src/card/bluetooth/BluetoothCard.h +++ b/src/card/bluetooth/BluetoothCard.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of Card object for Bluetooth * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -23,7 +23,7 @@ class BluetoothCard bool mConnected; QSharedPointer mDevice; - CardReturnCode transmit(const CommandApdu& pCmd, ResponseApdu& pRes, quint8 pTimeoutSeconds); + ResponseApduResult transmit(const CommandApdu& pCmd, quint8 pTimeoutSeconds); public: explicit BluetoothCard(QSharedPointer pDevice); @@ -32,13 +32,13 @@ class BluetoothCard CardReturnCode disconnect() override; bool isConnected() override; - CardReturnCode transmit(const CommandApdu& pCmd, ResponseApdu& pRes) override; + ResponseApduResult transmit(const CommandApdu& pCmd) override; EstablishPaceChannelOutput establishPaceChannel(PacePasswordId pPasswordId, const QByteArray& pChat, const QByteArray& pCertificateDescription, quint8 pTimeoutSeconds) override; CardReturnCode destroyPaceChannel() override; - CardReturnCode setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) override; + ResponseApduResult setEidPin(quint8 pTimeoutSeconds) override; }; } // namespace governikus diff --git a/src/card/bluetooth/BluetoothDebug.cpp b/src/card/bluetooth/BluetoothDebug.cpp index 3e37d8f85..6e3ca3879 100644 --- a/src/card/bluetooth/BluetoothDebug.cpp +++ b/src/card/bluetooth/BluetoothDebug.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothDebug.h" diff --git a/src/card/bluetooth/BluetoothDebug.h b/src/card/bluetooth/BluetoothDebug.h index e8589bb93..4d4db7b71 100644 --- a/src/card/bluetooth/BluetoothDebug.h +++ b/src/card/bluetooth/BluetoothDebug.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of debug output for various Qt Bluetooth classes. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/BluetoothDeviceUtil.h b/src/card/bluetooth/BluetoothDeviceUtil.h index 30cf51bf4..f2e59bc5c 100644 --- a/src/card/bluetooth/BluetoothDeviceUtil.h +++ b/src/card/bluetooth/BluetoothDeviceUtil.h @@ -1,7 +1,7 @@ /*! * \brief Utility function for determination of unique Bluetooth device ids. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/BluetoothReader.cpp b/src/card/bluetooth/BluetoothReader.cpp index 445d33156..2ce1b129b 100644 --- a/src/card/bluetooth/BluetoothReader.cpp +++ b/src/card/bluetooth/BluetoothReader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothCard.h" @@ -13,7 +13,6 @@ #include #include -#include Q_DECLARE_LOGGING_CATEGORY(bluetooth) diff --git a/src/card/bluetooth/BluetoothReader.h b/src/card/bluetooth/BluetoothReader.h index a6c34d603..27c91246e 100644 --- a/src/card/bluetooth/BluetoothReader.h +++ b/src/card/bluetooth/BluetoothReader.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of Reader object for Bluetooth based card reader. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/BluetoothReaderManagerPlugIn.cpp b/src/card/bluetooth/BluetoothReaderManagerPlugIn.cpp index cbee29a20..1c5a51436 100644 --- a/src/card/bluetooth/BluetoothReaderManagerPlugIn.cpp +++ b/src/card/bluetooth/BluetoothReaderManagerPlugIn.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothReaderManagerPlugIn.h" diff --git a/src/card/bluetooth/BluetoothReaderManagerPlugIn.h b/src/card/bluetooth/BluetoothReaderManagerPlugIn.h index d643cc315..6fed40131 100644 --- a/src/card/bluetooth/BluetoothReaderManagerPlugIn.h +++ b/src/card/bluetooth/BluetoothReaderManagerPlugIn.h @@ -1,7 +1,7 @@ /*! * \brief Implements the ReaderManagerPlugIn with Qt'S Bluetooth API. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/BluetoothReaderManagerPlugIn_p.h b/src/card/bluetooth/BluetoothReaderManagerPlugIn_p.h index 94252a824..7e8985ca7 100644 --- a/src/card/bluetooth/BluetoothReaderManagerPlugIn_p.h +++ b/src/card/bluetooth/BluetoothReaderManagerPlugIn_p.h @@ -1,7 +1,7 @@ /*! * \brief Private implementation part of the ReaderManagerPlugIn with Qt'S Bluetooth API. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_android.cpp b/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_android.cpp index f41b3be50..dc65235d9 100644 --- a/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_android.cpp +++ b/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_android.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "AndroidBluetoothAdapter.h" diff --git a/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_generic.cpp b/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_generic.cpp index dd0df4f26..a9ce9754d 100644 --- a/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_generic.cpp +++ b/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_generic.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothReaderManagerPlugIn_p.h" diff --git a/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_ios.mm b/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_ios.mm index 1cd83d6d0..919deb7b5 100644 --- a/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_ios.mm +++ b/src/card/bluetooth/BluetoothReaderManagerPlugIn_p_ios.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothReaderManagerPlugIn_p.h" diff --git a/src/card/bluetooth/CyberJackWaveDevice.cpp b/src/card/bluetooth/CyberJackWaveDevice.cpp index adcfe9e0e..085604e68 100644 --- a/src/card/bluetooth/CyberJackWaveDevice.cpp +++ b/src/card/bluetooth/CyberJackWaveDevice.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothDebug.h" diff --git a/src/card/bluetooth/CyberJackWaveDevice.h b/src/card/bluetooth/CyberJackWaveDevice.h index cab17e071..29e035f4e 100644 --- a/src/card/bluetooth/CyberJackWaveDevice.h +++ b/src/card/bluetooth/CyberJackWaveDevice.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of a Reiner SCT cyberJack wave device. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/NotificationEnabler.cpp b/src/card/bluetooth/NotificationEnabler.cpp index c87a17a5d..cab278c74 100644 --- a/src/card/bluetooth/NotificationEnabler.cpp +++ b/src/card/bluetooth/NotificationEnabler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "NotificationEnabler.h" diff --git a/src/card/bluetooth/NotificationEnabler.h b/src/card/bluetooth/NotificationEnabler.h index 7c01517be..b88b83d47 100644 --- a/src/card/bluetooth/NotificationEnabler.h +++ b/src/card/bluetooth/NotificationEnabler.h @@ -6,7 +6,7 @@ * * For details see the Qt documentation on QLowEnergyService and topic "Service Interaction". * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/SynchronousBtCall.cpp b/src/card/bluetooth/SynchronousBtCall.cpp index 0a03d5351..0049d7865 100644 --- a/src/card/bluetooth/SynchronousBtCall.cpp +++ b/src/card/bluetooth/SynchronousBtCall.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "SynchronousBtCall.h" diff --git a/src/card/bluetooth/SynchronousBtCall.h b/src/card/bluetooth/SynchronousBtCall.h index 5d25f52ed..3798709a4 100644 --- a/src/card/bluetooth/SynchronousBtCall.h +++ b/src/card/bluetooth/SynchronousBtCall.h @@ -2,7 +2,7 @@ * \brief Helper class to make a synchronous call to a Bluetooth device, i.e. * send the request data and wait for the response data to arrive. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothIDs.cpp b/src/card/bluetooth/messages/BluetoothIDs.cpp index 2de5a9357..cea1b6f46 100644 --- a/src/card/bluetooth/messages/BluetoothIDs.cpp +++ b/src/card/bluetooth/messages/BluetoothIDs.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothIDs.h" diff --git a/src/card/bluetooth/messages/BluetoothIDs.h b/src/card/bluetooth/messages/BluetoothIDs.h index e0b5aff0d..dfbd17d17 100644 --- a/src/card/bluetooth/messages/BluetoothIDs.h +++ b/src/card/bluetooth/messages/BluetoothIDs.h @@ -1,7 +1,7 @@ /*! * \brief Add message and parameter types of bluetooth SIM ACCESS spec * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessage.cpp b/src/card/bluetooth/messages/BluetoothMessage.cpp index 7cb73d31e..7a9268d4b 100644 --- a/src/card/bluetooth/messages/BluetoothMessage.cpp +++ b/src/card/bluetooth/messages/BluetoothMessage.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessage.h" diff --git a/src/card/bluetooth/messages/BluetoothMessage.h b/src/card/bluetooth/messages/BluetoothMessage.h index a910bdd62..3b458d85c 100644 --- a/src/card/bluetooth/messages/BluetoothMessage.h +++ b/src/card/bluetooth/messages/BluetoothMessage.h @@ -1,7 +1,7 @@ /*! * \brief Implements a message of SIM ACCESS profile. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageConnectResponse.cpp b/src/card/bluetooth/messages/BluetoothMessageConnectResponse.cpp index ad60e0c3b..6c6c1976e 100644 --- a/src/card/bluetooth/messages/BluetoothMessageConnectResponse.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageConnectResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/BluetoothMessageConnectResponse.h" diff --git a/src/card/bluetooth/messages/BluetoothMessageConnectResponse.h b/src/card/bluetooth/messages/BluetoothMessageConnectResponse.h index 0d759342c..6d21f5261 100644 --- a/src/card/bluetooth/messages/BluetoothMessageConnectResponse.h +++ b/src/card/bluetooth/messages/BluetoothMessageConnectResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageCreator.cpp b/src/card/bluetooth/messages/BluetoothMessageCreator.cpp index ff3962a71..e109cc4d7 100644 --- a/src/card/bluetooth/messages/BluetoothMessageCreator.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageCreator.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/card/bluetooth/messages/BluetoothMessageCreator.h b/src/card/bluetooth/messages/BluetoothMessageCreator.h index e9bfb3799..10e399f44 100644 --- a/src/card/bluetooth/messages/BluetoothMessageCreator.h +++ b/src/card/bluetooth/messages/BluetoothMessageCreator.h @@ -1,7 +1,7 @@ /*! * \brief Provides an easy to use API to create requests. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageDisconnectResponse.cpp b/src/card/bluetooth/messages/BluetoothMessageDisconnectResponse.cpp index 4cae6fa17..8738b17e9 100644 --- a/src/card/bluetooth/messages/BluetoothMessageDisconnectResponse.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageDisconnectResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/BluetoothMessageDisconnectResponse.h" diff --git a/src/card/bluetooth/messages/BluetoothMessageDisconnectResponse.h b/src/card/bluetooth/messages/BluetoothMessageDisconnectResponse.h index d28c12188..ac6ca43fd 100644 --- a/src/card/bluetooth/messages/BluetoothMessageDisconnectResponse.h +++ b/src/card/bluetooth/messages/BluetoothMessageDisconnectResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageParser.cpp b/src/card/bluetooth/messages/BluetoothMessageParser.cpp index 15283fe4c..a748157d6 100644 --- a/src/card/bluetooth/messages/BluetoothMessageParser.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageConnectResponse.h" diff --git a/src/card/bluetooth/messages/BluetoothMessageParser.h b/src/card/bluetooth/messages/BluetoothMessageParser.h index ba3ac6fa2..678f4bc03 100644 --- a/src/card/bluetooth/messages/BluetoothMessageParser.h +++ b/src/card/bluetooth/messages/BluetoothMessageParser.h @@ -1,7 +1,7 @@ /*! * \brief Parses messages of bluetooth SIM ACCESS protocol. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessagePowerSimOffResponse.cpp b/src/card/bluetooth/messages/BluetoothMessagePowerSimOffResponse.cpp index ff84419af..e883b3f0f 100644 --- a/src/card/bluetooth/messages/BluetoothMessagePowerSimOffResponse.cpp +++ b/src/card/bluetooth/messages/BluetoothMessagePowerSimOffResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/BluetoothMessagePowerSimOffResponse.h" diff --git a/src/card/bluetooth/messages/BluetoothMessagePowerSimOffResponse.h b/src/card/bluetooth/messages/BluetoothMessagePowerSimOffResponse.h index 56ae7076a..fdd0f77b5 100644 --- a/src/card/bluetooth/messages/BluetoothMessagePowerSimOffResponse.h +++ b/src/card/bluetooth/messages/BluetoothMessagePowerSimOffResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessagePowerSimOnResponse.cpp b/src/card/bluetooth/messages/BluetoothMessagePowerSimOnResponse.cpp index 8e4e9cbd6..e51534406 100644 --- a/src/card/bluetooth/messages/BluetoothMessagePowerSimOnResponse.cpp +++ b/src/card/bluetooth/messages/BluetoothMessagePowerSimOnResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothIDs.h" diff --git a/src/card/bluetooth/messages/BluetoothMessagePowerSimOnResponse.h b/src/card/bluetooth/messages/BluetoothMessagePowerSimOnResponse.h index 8e52eb3f1..f6e123570 100644 --- a/src/card/bluetooth/messages/BluetoothMessagePowerSimOnResponse.h +++ b/src/card/bluetooth/messages/BluetoothMessagePowerSimOnResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageResetSimResponse.cpp b/src/card/bluetooth/messages/BluetoothMessageResetSimResponse.cpp index 39ca39dfb..b637fb4c6 100644 --- a/src/card/bluetooth/messages/BluetoothMessageResetSimResponse.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageResetSimResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/BluetoothMessageResetSimResponse.h" diff --git a/src/card/bluetooth/messages/BluetoothMessageResetSimResponse.h b/src/card/bluetooth/messages/BluetoothMessageResetSimResponse.h index 016fbea2e..3237d7b69 100644 --- a/src/card/bluetooth/messages/BluetoothMessageResetSimResponse.h +++ b/src/card/bluetooth/messages/BluetoothMessageResetSimResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageSetTransportProtocolResponse.cpp b/src/card/bluetooth/messages/BluetoothMessageSetTransportProtocolResponse.cpp index 19f1cc67a..9b942b802 100644 --- a/src/card/bluetooth/messages/BluetoothMessageSetTransportProtocolResponse.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageSetTransportProtocolResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageSetTransportProtocolResponse.h" diff --git a/src/card/bluetooth/messages/BluetoothMessageSetTransportProtocolResponse.h b/src/card/bluetooth/messages/BluetoothMessageSetTransportProtocolResponse.h index 8e0807e25..9650ee6e3 100644 --- a/src/card/bluetooth/messages/BluetoothMessageSetTransportProtocolResponse.h +++ b/src/card/bluetooth/messages/BluetoothMessageSetTransportProtocolResponse.h @@ -1,7 +1,7 @@ /*! * \brief Store information of SetTransportProtocolResponse. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageStatusInd.cpp b/src/card/bluetooth/messages/BluetoothMessageStatusInd.cpp index c34252e43..570620cf5 100644 --- a/src/card/bluetooth/messages/BluetoothMessageStatusInd.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageStatusInd.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageStatusInd.h" diff --git a/src/card/bluetooth/messages/BluetoothMessageStatusInd.h b/src/card/bluetooth/messages/BluetoothMessageStatusInd.h index ce7d2d503..ec9566931 100644 --- a/src/card/bluetooth/messages/BluetoothMessageStatusInd.h +++ b/src/card/bluetooth/messages/BluetoothMessageStatusInd.h @@ -1,7 +1,7 @@ /*! * \brief Implements special BluetoothMessage for StatusInd. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageTransferApduResponse.cpp b/src/card/bluetooth/messages/BluetoothMessageTransferApduResponse.cpp index ea9439b90..df7676a6a 100644 --- a/src/card/bluetooth/messages/BluetoothMessageTransferApduResponse.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageTransferApduResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/BluetoothMessageTransferApduResponse.h" diff --git a/src/card/bluetooth/messages/BluetoothMessageTransferApduResponse.h b/src/card/bluetooth/messages/BluetoothMessageTransferApduResponse.h index d54c2be0f..d07dedb9e 100644 --- a/src/card/bluetooth/messages/BluetoothMessageTransferApduResponse.h +++ b/src/card/bluetooth/messages/BluetoothMessageTransferApduResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothMessageTransferCardReaderStatusResponse.cpp b/src/card/bluetooth/messages/BluetoothMessageTransferCardReaderStatusResponse.cpp index 5bbfa7ceb..062d13731 100644 --- a/src/card/bluetooth/messages/BluetoothMessageTransferCardReaderStatusResponse.cpp +++ b/src/card/bluetooth/messages/BluetoothMessageTransferCardReaderStatusResponse.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageTransferCardReaderStatusResponse.h" diff --git a/src/card/bluetooth/messages/BluetoothMessageTransferCardReaderStatusResponse.h b/src/card/bluetooth/messages/BluetoothMessageTransferCardReaderStatusResponse.h index ea820947e..8829ef233 100644 --- a/src/card/bluetooth/messages/BluetoothMessageTransferCardReaderStatusResponse.h +++ b/src/card/bluetooth/messages/BluetoothMessageTransferCardReaderStatusResponse.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/BluetoothUtils.cpp b/src/card/bluetooth/messages/BluetoothUtils.cpp index 104f7263e..dd5b0b6b6 100644 --- a/src/card/bluetooth/messages/BluetoothUtils.cpp +++ b/src/card/bluetooth/messages/BluetoothUtils.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothUtils.h" diff --git a/src/card/bluetooth/messages/BluetoothUtils.h b/src/card/bluetooth/messages/BluetoothUtils.h index 919f975a7..1ce4017bc 100644 --- a/src/card/bluetooth/messages/BluetoothUtils.h +++ b/src/card/bluetooth/messages/BluetoothUtils.h @@ -1,7 +1,7 @@ /*! * \brief Some helper utils for bluetooth messages. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameter.cpp b/src/card/bluetooth/messages/parameter/BluetoothMessageParameter.cpp index 26a142a3e..ad7a84674 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameter.cpp +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameter.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageParameter.h" diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameter.h b/src/card/bluetooth/messages/parameter/BluetoothMessageParameter.h index cdf48d32f..600a271af 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameter.h +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameter.h @@ -1,7 +1,7 @@ /*! * \brief Implements message parameter of SIM ACCESS spec. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterApduResponse.cpp b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterApduResponse.cpp index d7d33380c..d5580dd93 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterApduResponse.cpp +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterApduResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageParameterApduResponse.h" diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterApduResponse.h b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterApduResponse.h index 5d0323579..fef444c47 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterApduResponse.h +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterApduResponse.h @@ -1,7 +1,7 @@ /*! * \brief Implements special BluetoothMessageParameter for TransferApduResponse. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterCardReaderStatus.cpp b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterCardReaderStatus.cpp index 5c79fa115..20e91f046 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterCardReaderStatus.cpp +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterCardReaderStatus.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/parameter/BluetoothMessageParameterCardReaderStatus.h" diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterCardReaderStatus.h b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterCardReaderStatus.h index f7b02a4c8..a98b943c8 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterCardReaderStatus.h +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterCardReaderStatus.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterConnectionStatus.cpp b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterConnectionStatus.cpp index 9e2410ab5..c2f469119 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterConnectionStatus.cpp +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterConnectionStatus.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageParameterConnectionStatus.h" diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterConnectionStatus.h b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterConnectionStatus.h index a44c1842a..18950e5de 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterConnectionStatus.h +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterConnectionStatus.h @@ -1,7 +1,7 @@ /*! * \brief Implements special BluetoothMessageParameter for ConnectionStatus. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterMaxMsgSize.cpp b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterMaxMsgSize.cpp index b155ff73a..e77b684ad 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterMaxMsgSize.cpp +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterMaxMsgSize.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageParameterMaxMsgSize.h" diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterMaxMsgSize.h b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterMaxMsgSize.h index ccfa08496..0c2059a77 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterMaxMsgSize.h +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterMaxMsgSize.h @@ -1,7 +1,7 @@ /*! * \brief Implements special BluetoothMessageParameter for MaxMsgSize. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterResultCode.cpp b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterResultCode.cpp index 8728a1ff1..35e8b4f40 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterResultCode.cpp +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterResultCode.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageParameterResultCode.h" diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterResultCode.h b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterResultCode.h index 4e725be02..b44190e16 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterResultCode.h +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterResultCode.h @@ -1,7 +1,7 @@ /*! * \brief Implements special BluetoothMessageParameter for ResultCode. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterStatusChange.cpp b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterStatusChange.cpp index 598943dfc..f2cb55431 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterStatusChange.cpp +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterStatusChange.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "BluetoothMessageParameterStatusChange.h" diff --git a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterStatusChange.h b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterStatusChange.h index d0ccb24a3..42b6dada6 100644 --- a/src/card/bluetooth/messages/parameter/BluetoothMessageParameterStatusChange.h +++ b/src/card/bluetooth/messages/parameter/BluetoothMessageParameterStatusChange.h @@ -1,7 +1,7 @@ /*! * \brief Implements special BluetoothMessageParameter for StatusChange. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/drivers/ReaderDetector.cpp b/src/card/drivers/ReaderDetector.cpp index 857f19360..737bf60e6 100644 --- a/src/card/drivers/ReaderDetector.cpp +++ b/src/card/drivers/ReaderDetector.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDetector.h" @@ -61,7 +61,7 @@ QVector ReaderDetector::getAttachedSupportedDevices() c ReaderConfigurationInfo ReaderDetector::getReaderConfigurationInfo(const QString& pReaderName) { QVector attachedSupportedDevices = getAttachedSupportedDevices(); - attachedSupportedDevices += Env::getSingleton()->getRemoteReaderConfigurationInfo(); + attachedSupportedDevices += Env::getSingleton()->getVirtualReaderConfigurationInfos(); for (const auto& info : qAsConst(attachedSupportedDevices)) { diff --git a/src/card/drivers/ReaderDetector.h b/src/card/drivers/ReaderDetector.h index c91de2369..09bf425a4 100644 --- a/src/card/drivers/ReaderDetector.h +++ b/src/card/drivers/ReaderDetector.h @@ -2,7 +2,7 @@ * \brief Interface specifying classes that can detect the attached card reader * devices on a specific platform. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/drivers/ReaderDetector_generic.cpp b/src/card/drivers/ReaderDetector_generic.cpp index ad5d74315..b70d07e41 100644 --- a/src/card/drivers/ReaderDetector_generic.cpp +++ b/src/card/drivers/ReaderDetector_generic.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDetector.h" diff --git a/src/card/drivers/ReaderDetector_linux.cpp b/src/card/drivers/ReaderDetector_linux.cpp index 94363787b..2386eb556 100644 --- a/src/card/drivers/ReaderDetector_linux.cpp +++ b/src/card/drivers/ReaderDetector_linux.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDetector.h" diff --git a/src/card/drivers/ReaderDetector_osx.cpp b/src/card/drivers/ReaderDetector_osx.cpp index 213c16f60..d8225fa25 100644 --- a/src/card/drivers/ReaderDetector_osx.cpp +++ b/src/card/drivers/ReaderDetector_osx.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDetector.h" diff --git a/src/card/drivers/ReaderDetector_win.cpp b/src/card/drivers/ReaderDetector_win.cpp index a2577c36e..6cf3f0481 100644 --- a/src/card/drivers/ReaderDetector_win.cpp +++ b/src/card/drivers/ReaderDetector_win.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDetector.h" diff --git a/src/card/ios/IosCard.h b/src/card/ios/IosCard.h index 739003032..f07599b5a 100644 --- a/src/card/ios/IosCard.h +++ b/src/card/ios/IosCard.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref Card for iOS. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -39,7 +39,7 @@ class IosCard virtual bool isConnected() override; virtual void setProgressMessage(const QString& pMessage) override; - virtual CardReturnCode transmit(const CommandApdu& pCmd, ResponseApdu& pRes) override; + virtual ResponseApduResult transmit(const CommandApdu& pCmd) override; Q_SIGNALS: void fireConnectFailed(); diff --git a/src/card/ios/IosCard.mm b/src/card/ios/IosCard.mm index bae283c20..fcd85c937 100644 --- a/src/card/ios/IosCard.mm +++ b/src/card/ios/IosCard.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "IosCard.h" @@ -42,7 +42,7 @@ bool IosCard::isValid() const { - return mCard->mNfcTag && (!mConnected || [mCard->mNfcTag isAvailable]); + return mCard->mNfcTag && (!mConnected || mCard->mNfcTag.available); } @@ -73,7 +73,7 @@ return CardReturnCode::OK; } - NFCTagReaderSession* session = [mCard->mNfcTag session]; + NFCTagReaderSession* session = mCard->mNfcTag.session; [session connectToTag: mCard->mNfcTag completionHandler: ^(NSError* error){ if (error != nil) { @@ -125,17 +125,17 @@ void IosCard::setProgressMessage(const QString& pMessage) { - NFCTagReaderSession* session = [mCard->mNfcTag session]; - [session setAlertMessage: pMessage.toNSString()]; + NFCTagReaderSession* session = mCard->mNfcTag.session; + session.alertMessage = pMessage.toNSString(); } -CardReturnCode IosCard::transmit(const CommandApdu& pCmd, ResponseApdu& pRes) +ResponseApduResult IosCard::transmit(const CommandApdu& pCmd) { if (!isValid()) { qCWarning(card_nfc) << "NearFieldTarget is no longer valid"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } qCDebug(card_nfc) << "Transmit command APDU:" << pCmd.getBuffer().toHex(); @@ -174,9 +174,8 @@ if (resultBuffer->isEmpty()) { Q_EMIT fireTransmitFailed(); - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - pRes.setBuffer(std::move(*resultBuffer)); - return CardReturnCode::OK; + return {CardReturnCode::OK, ResponseApdu(*resultBuffer)}; } diff --git a/src/card/ios/IosCardPointer.h b/src/card/ios/IosCardPointer.h index 98c4ebea0..5d82a4f75 100644 --- a/src/card/ios/IosCardPointer.h +++ b/src/card/ios/IosCardPointer.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #import diff --git a/src/card/ios/IosReader.h b/src/card/ios/IosReader.h index 9d9091d36..cb1ab7572 100644 --- a/src/card/ios/IosReader.h +++ b/src/card/ios/IosReader.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref Reader for iOS. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -31,7 +31,7 @@ class IosReader virtual CardEvent updateCard() override; void removeCard(); - void stopSession(const QString& pError = QString()); + void stopSession(const QString& pError); public: IosReader(); diff --git a/src/card/ios/IosReader.mm b/src/card/ios/IosReader.mm index a99a97d2f..d5b1c4f99 100644 --- a/src/card/ios/IosReader.mm +++ b/src/card/ios/IosReader.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnectionWorker.h" @@ -7,7 +7,6 @@ #include #include -#include #include @@ -151,16 +150,12 @@ void IosReader::onConnectFailed() { //: ERROR IOS The connection to the card could not be established. - stopSession(tr("The connection could not be established. The process was aborted.")); - mConnected = false; - Q_EMIT fireReaderDisconnected(); + onDidInvalidateWithError(tr("The connection could not be established. The process was aborted."), true); } void IosReader::onTransmitFailed() { //: ERROR IOS The card was removed during the communication. - stopSession(tr("The connection to the ID card has been lost. The process was aborted.")); - mConnected = false; - Q_EMIT fireReaderDisconnected(); + onDidInvalidateWithError(tr("The connection to the ID card has been lost. The process was aborted."), true); } diff --git a/src/card/ios/IosReaderDelegate.h b/src/card/ios/IosReaderDelegate.h index fef272239..8a4ca3260 100644 --- a/src/card/ios/IosReaderDelegate.h +++ b/src/card/ios/IosReaderDelegate.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref IosReaderDelegate for iOS. * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/ios/IosReaderDelegate.mm b/src/card/ios/IosReaderDelegate.mm index 5267e2f9d..e76df4855 100644 --- a/src/card/ios/IosReaderDelegate.mm +++ b/src/card/ios/IosReaderDelegate.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "IosReaderDelegate.h" @@ -39,7 +39,7 @@ void IosReaderDelegate::startSession() { - //: INFO IOS The id card may be inserted, the authentication process may be started. + //: INFO IOS The ID card may be inserted, the authentication process may be started. [mPrivate->mIosReaderDelegateImpl startSession: tr("Please place your device on your ID card.")]; } diff --git a/src/card/ios/IosReaderDelegateImpl.h b/src/card/ios/IosReaderDelegateImpl.h index cb97aa874..1574c9404 100644 --- a/src/card/ios/IosReaderDelegateImpl.h +++ b/src/card/ios/IosReaderDelegateImpl.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref IosReaderDelegateImpl for iOS. * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/ios/IosReaderDelegateImpl.mm b/src/card/ios/IosReaderDelegateImpl.mm index 5f6b01dfe..57fdf1dcd 100644 --- a/src/card/ios/IosReaderDelegateImpl.mm +++ b/src/card/ios/IosReaderDelegateImpl.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "IosReaderDelegateImpl.h" @@ -25,7 +25,7 @@ + (IosReaderDelegateImpl*) initWithDelegate:(governikus::IosReaderDelegate*)pDel } -- (id) init { +- (instancetype) init { self = [super init]; return self; } @@ -43,7 +43,7 @@ - (void) startSession: (QString)pMessage { self.mSession = [[NFCTagReaderSession alloc] initWithPollingOption: NFCPollingISO14443 delegate: self queue: nil]; if (self.mSession) { - [self.mSession setAlertMessage: pMessage.toNSString()]; + self.mSession.alertMessage = pMessage.toNSString(); [self.mSession beginSession]; } } @@ -61,7 +61,7 @@ - (void) stopSession: (QString)pMessage isError:(bool) pIsError { } else { - [self.mSession setAlertMessage: pMessage.toNSString()]; + self.mSession.alertMessage = pMessage.toNSString(); [self.mSession invalidateSession]; } self.mSession = nil; diff --git a/src/card/ios/IosReaderManagerPlugIn.h b/src/card/ios/IosReaderManagerPlugIn.h index c91602747..0636b10c7 100644 --- a/src/card/ios/IosReaderManagerPlugIn.h +++ b/src/card/ios/IosReaderManagerPlugIn.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref ReaderManagerPlugIn for NFC on iOS. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/ios/IosReaderManagerPlugIn.mm b/src/card/ios/IosReaderManagerPlugIn.mm index 25aef7604..475d8180e 100644 --- a/src/card/ios/IosReaderManagerPlugIn.mm +++ b/src/card/ios/IosReaderManagerPlugIn.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "IosReader.h" diff --git a/src/card/nfc/NfcCard.cpp b/src/card/nfc/NfcCard.cpp index 06ab1e022..0b7585e78 100644 --- a/src/card/nfc/NfcCard.cpp +++ b/src/card/nfc/NfcCard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "NfcCard.h" @@ -99,12 +99,12 @@ bool NfcCard::isConnected() } -CardReturnCode NfcCard::transmit(const CommandApdu& pCmd, ResponseApdu& pRes) +ResponseApduResult NfcCard::transmit(const CommandApdu& pCmd) { if (!mIsValid || mNearFieldTarget == nullptr) { qCWarning(card_nfc) << "NearFieldTarget is no longer valid"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } qCDebug(card_nfc) << "Transmit command APDU:" << pCmd.getBuffer().toHex(); @@ -112,31 +112,30 @@ CardReturnCode NfcCard::transmit(const CommandApdu& pCmd, ResponseApdu& pRes) if (!mNearFieldTarget->accessMethods().testFlag(QNearFieldTarget::AccessMethod::TagTypeSpecificAccess)) { qCWarning(card_nfc) << "No TagTypeSpecificAccess supported"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } QNearFieldTarget::RequestId id = mNearFieldTarget->sendCommand(pCmd.getBuffer()); if (!id.isValid()) { qCWarning(card_nfc) << "Cannot write messages"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } if (!mNearFieldTarget->waitForRequestCompleted(id, 1500)) { qCWarning(card_nfc) << "Transmit timeout reached"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } QVariant response = mNearFieldTarget->requestResponse(id); if (!response.isValid()) { qCWarning(card_nfc) << "Invalid response received"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - QByteArray recvBuffer = response.toByteArray(); + const QByteArray recvBuffer = response.toByteArray(); qCDebug(card_nfc) << "Transmit response APDU:" << recvBuffer.toHex(); - pRes.setBuffer(recvBuffer); - return CardReturnCode::OK; + return {CardReturnCode::OK, ResponseApdu(recvBuffer)}; } diff --git a/src/card/nfc/NfcCard.h b/src/card/nfc/NfcCard.h index f14d3cd47..3c08cf798 100644 --- a/src/card/nfc/NfcCard.h +++ b/src/card/nfc/NfcCard.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref Card for NFC. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -37,7 +37,7 @@ class NfcCard virtual CardReturnCode disconnect() override; virtual bool isConnected() override; - virtual CardReturnCode transmit(const CommandApdu& pCmd, ResponseApdu& pRes) override; + virtual ResponseApduResult transmit(const CommandApdu& pCmd) override; }; } // namespace governikus diff --git a/src/card/nfc/NfcReader.cpp b/src/card/nfc/NfcReader.cpp index cf0d2b166..970c3de89 100644 --- a/src/card/nfc/NfcReader.cpp +++ b/src/card/nfc/NfcReader.cpp @@ -1,12 +1,11 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnectionWorker.h" #include "NfcReader.h" #include -#include using namespace governikus; diff --git a/src/card/nfc/NfcReader.h b/src/card/nfc/NfcReader.h index 8e160be2c..e9f4d6e47 100644 --- a/src/card/nfc/NfcReader.h +++ b/src/card/nfc/NfcReader.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref Reader for NFC. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/nfc/NfcReaderManagerPlugIn.cpp b/src/card/nfc/NfcReaderManagerPlugIn.cpp index 4d7eaddb1..c4ea87fc7 100644 --- a/src/card/nfc/NfcReaderManagerPlugIn.cpp +++ b/src/card/nfc/NfcReaderManagerPlugIn.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "NfcReader.h" diff --git a/src/card/nfc/NfcReaderManagerPlugIn.h b/src/card/nfc/NfcReaderManagerPlugIn.h index df2c51cda..eb1bb9bfc 100644 --- a/src/card/nfc/NfcReaderManagerPlugIn.h +++ b/src/card/nfc/NfcReaderManagerPlugIn.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref ReaderManagerPlugIn for NFC on Android. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/pcsc/PcscCard.cpp b/src/card/pcsc/PcscCard.cpp index cd0ab01e6..9430ebffb 100644 --- a/src/card/pcsc/PcscCard.cpp +++ b/src/card/pcsc/PcscCard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscCard.h" @@ -160,58 +160,54 @@ bool PcscCard::isConnected() } -CardReturnCode PcscCard::transmit(const CommandApdu& pCmd, ResponseApdu& pRes) +ResponseApduResult PcscCard::transmit(const CommandApdu& pCmd) { if (!isConnected()) { qCCritical(card_pcsc) << "Card is not connected, abort transmit"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - QByteArray receiveBuffer; - PCSC_RETURNCODE returnCode = transmit(pCmd.getBuffer(), receiveBuffer); - if (returnCode != PcscUtils::Scard_S_Success) + CardResult data = transmit(pCmd.getBuffer()); + if (data.mReturnCode != PcscUtils::Scard_S_Success) { - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - ResponseApdu tempResponse; - tempResponse.setBuffer(receiveBuffer); + ResponseApdu tempResponse(data.mResponse); if (tempResponse.getSW1() == SW1::WRONG_LE_FIELD) { qCDebug(card_pcsc) << "got SW1 == 0x6c, retransmitting with new Le:" << tempResponse.getSW2(); CommandApdu retransmitCommand(pCmd.getCLA(), pCmd.getINS(), pCmd.getP1(), pCmd.getP2(), pCmd.getData(), tempResponse.getSW2()); - returnCode = transmit(retransmitCommand.getBuffer(), receiveBuffer); - if (returnCode != PcscUtils::Scard_S_Success) + data = transmit(retransmitCommand.getBuffer()); + if (data.mReturnCode != PcscUtils::Scard_S_Success) { - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } } while (tempResponse.getSW1() == SW1::MORE_DATA_AVAILABLE) { - QByteArray tempReceiveBuffer; qCDebug(card_pcsc) << "got SW1 == 0x61, getting response with Le:" << tempResponse.getSW2(); CommandApdu getResponseCommand(0, char(0xC0), 0, 0, QByteArray(), tempResponse.getSW2()); - returnCode = transmit(getResponseCommand.getBuffer(), tempReceiveBuffer); - if (returnCode != PcscUtils::Scard_S_Success) + CardResult tmpData = transmit(getResponseCommand.getBuffer()); + if (data.mReturnCode != PcscUtils::Scard_S_Success) { - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - tempResponse.setBuffer(tempReceiveBuffer); + tempResponse = ResponseApdu(tmpData.mResponse); // cut off sw1 and sw2 - receiveBuffer.resize(receiveBuffer.size() - 2); - receiveBuffer += tempReceiveBuffer; + data.mResponse.resize(data.mResponse.size() - 2); + data.mResponse += tmpData.mResponse; } - pRes.setBuffer(receiveBuffer); - return CardReturnCode::OK; + return {CardReturnCode::OK, ResponseApdu(data.mResponse)}; } -PCSC_RETURNCODE PcscCard::transmit(const QByteArray& pSendBuffer, QByteArray& pReceiveBuffer) +PcscCard::CardResult PcscCard::transmit(const QByteArray& pSendBuffer) { const SCARD_IO_REQUEST* sendPci; switch (mProtocol) @@ -230,11 +226,10 @@ PCSC_RETURNCODE PcscCard::transmit(const QByteArray& pSendBuffer, QByteArray& pR default: qCDebug(card_pcsc) << "unsupported protocol"; - return PcscUtils::Scard_E_Proto_Mismatch; + return {PcscUtils::Scard_E_Proto_Mismatch}; } auto [returnCode, buffer] = transmit(pSendBuffer, sendPci); - pReceiveBuffer = buffer; /* * Reconnecting makes only sense, when no secure messaging channel is active. @@ -245,20 +240,17 @@ PCSC_RETURNCODE PcscCard::transmit(const QByteArray& pSendBuffer, QByteArray& pR returnCode = SCardReconnect(mCardHandle, SCARD_SHARE_SHARED, mProtocol, SCARD_RESET_CARD, nullptr); qCDebug(card_pcsc) << "Reconnect to Card"; - if (returnCode != PcscUtils::Scard_S_Success) + if (returnCode == PcscUtils::Scard_S_Success) { - qCCritical(card_pcsc) << "SCardReconnect failed:" << PcscUtils::toString(returnCode); - return returnCode; + returnCode = SCardBeginTransaction(mCardHandle); + qCDebug(card_pcsc) << "SCardBeginTransaction:" << PcscUtils::toString(returnCode); + return transmit(pSendBuffer, sendPci); } - returnCode = SCardBeginTransaction(mCardHandle); - qCDebug(card_pcsc) << "SCardBeginTransaction:" << PcscUtils::toString(returnCode); - auto [retryReturnCode, retryBuffer] = transmit(pSendBuffer, sendPci); - returnCode = retryReturnCode; - pReceiveBuffer = retryBuffer; + qCCritical(card_pcsc) << "SCardReconnect failed:" << PcscUtils::toString(returnCode); } - return returnCode; + return {returnCode, buffer}; } @@ -383,11 +375,11 @@ PcscCard::CardResult PcscCard::control(PCSC_INT pCntrCode, const QByteArray& pCn } -CardReturnCode PcscCard::setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) +ResponseApduResult PcscCard::setEidPin(quint8 pTimeoutSeconds) { if (!mReader->hasFeature(FeatureID::MODIFY_PIN_DIRECT)) { - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } PCSC_INT cmdID = mReader->getFeatureValue(FeatureID::MODIFY_PIN_DIRECT); @@ -396,9 +388,9 @@ CardReturnCode PcscCard::setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pRespon if (returnCode != PcscUtils::Scard_S_Success) { qCWarning(card_pcsc) << "Modify PIN failed"; - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - pResponseApdu.setBuffer(controlRes); - return pResponseApdu.getCardReturnCode(); + const ResponseApdu response(controlRes); + return {response.getCardReturnCode(), response}; } diff --git a/src/card/pcsc/PcscCard.h b/src/card/pcsc/PcscCard.h index c6ed3fed0..f361c0218 100644 --- a/src/card/pcsc/PcscCard.h +++ b/src/card/pcsc/PcscCard.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of card object for PC/SC * * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -37,10 +37,8 @@ class PcscCard SCARDHANDLE mCardHandle; QTimer mTimer; - PCSC_RETURNCODE transmit(const QByteArray& pSendBuffer, QByteArray& pReceiveBuffer); - + CardResult transmit(const QByteArray& pSendBuffer); CardResult transmit(const QByteArray& pSendBuffer, const SCARD_IO_REQUEST* pSendPci); - CardResult control(PCSC_INT pCntrCode, const QByteArray& pCntrInput); private Q_SLOTS: @@ -54,13 +52,13 @@ class PcscCard virtual CardReturnCode disconnect() override; virtual bool isConnected() override; - virtual CardReturnCode transmit(const CommandApdu& pCmd, ResponseApdu& pRes) override; + virtual ResponseApduResult transmit(const CommandApdu& pCmd) override; virtual EstablishPaceChannelOutput establishPaceChannel(PacePasswordId pPasswordId, const QByteArray& pChat, const QByteArray& pCertificateDescription, quint8 pTimeoutSeconds) override; virtual CardReturnCode destroyPaceChannel() override; - virtual CardReturnCode setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) override; + virtual ResponseApduResult setEidPin(quint8 pTimeoutSeconds) override; }; } // namespace governikus diff --git a/src/card/pcsc/PcscReader.cpp b/src/card/pcsc/PcscReader.cpp index da2aeff3c..19ebc98d9 100644 --- a/src/card/pcsc/PcscReader.cpp +++ b/src/card/pcsc/PcscReader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscCard.h" @@ -91,7 +91,7 @@ PCSC_INT PcscReader::getFeatureValue(FeatureID pFeatureID) static QString SCARD_STATE_toString(DWORD i) { - QStringList sb(QString().sprintf("(%#lx)", static_cast(i))); + QStringList sb(QStringLiteral("(%1)").arg(static_cast(i))); if (i == SCARD_STATE_UNAWARE) { diff --git a/src/card/pcsc/PcscReader.h b/src/card/pcsc/PcscReader.h index e4e7c8ffd..b7221e9a0 100644 --- a/src/card/pcsc/PcscReader.h +++ b/src/card/pcsc/PcscReader.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref Reader for PCSC. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/pcsc/PcscReaderFeature.cpp b/src/card/pcsc/PcscReaderFeature.cpp index 700259499..5ff0bbc0c 100644 --- a/src/card/pcsc/PcscReaderFeature.cpp +++ b/src/card/pcsc/PcscReaderFeature.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscReaderFeature.h" @@ -23,9 +23,8 @@ PcscReaderFeature::PcscReaderFeature(const char* const pFeaturesTLV, PCSC_INT pL return; } - const auto* runner = reinterpret_cast(pFeaturesTLV); const auto* const end = reinterpret_cast(pFeaturesTLV + pLength); - for (; runner + 6 <= end;) + for (const auto* runner = reinterpret_cast(pFeaturesTLV); runner + 6 <= end;) { if (!Enum::isValue(*runner)) { diff --git a/src/card/pcsc/PcscReaderFeature.h b/src/card/pcsc/PcscReaderFeature.h index be4b0cc40..c09d71a1b 100644 --- a/src/card/pcsc/PcscReaderFeature.h +++ b/src/card/pcsc/PcscReaderFeature.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/pcsc/PcscReaderManagerPlugIn.cpp b/src/card/pcsc/PcscReaderManagerPlugIn.cpp index e31d30d73..fdf57b2dd 100644 --- a/src/card/pcsc/PcscReaderManagerPlugIn.cpp +++ b/src/card/pcsc/PcscReaderManagerPlugIn.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscReaderManagerPlugIn.h" diff --git a/src/card/pcsc/PcscReaderManagerPlugIn.h b/src/card/pcsc/PcscReaderManagerPlugIn.h index 4b683f782..856b65be8 100644 --- a/src/card/pcsc/PcscReaderManagerPlugIn.h +++ b/src/card/pcsc/PcscReaderManagerPlugIn.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of \ref ReaderManagerPlugIn for PCSC. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/pcsc/PcscReaderPaceCapability.cpp b/src/card/pcsc/PcscReaderPaceCapability.cpp index 589c69db6..dd48a745f 100644 --- a/src/card/pcsc/PcscReaderPaceCapability.cpp +++ b/src/card/pcsc/PcscReaderPaceCapability.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscReaderPaceCapability.h" diff --git a/src/card/pcsc/PcscReaderPaceCapability.h b/src/card/pcsc/PcscReaderPaceCapability.h index a1df537b6..f2d5dd741 100644 --- a/src/card/pcsc/PcscReaderPaceCapability.h +++ b/src/card/pcsc/PcscReaderPaceCapability.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/card/pcsc/PcscUtils.cpp b/src/card/pcsc/PcscUtils.cpp index 55e78166d..abf91e23e 100644 --- a/src/card/pcsc/PcscUtils.cpp +++ b/src/card/pcsc/PcscUtils.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscUtils.h" diff --git a/src/card/pcsc/PcscUtils.h b/src/card/pcsc/PcscUtils.h index 2e4c4a099..6fd6923fb 100644 --- a/src/card/pcsc/PcscUtils.h +++ b/src/card/pcsc/PcscUtils.h @@ -2,7 +2,7 @@ * \brief toString method for PCSC_RETURNCODE and platform dependent * typedefs for PCSC types. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -26,7 +26,7 @@ using PCSC_RETURNCODE = LONG; using PCSC_INT = DWORD; using PCSC_CHAR = TCHAR; -using PCSC_CHAR_PTR = TCHAR *; +using PCSC_CHAR_PTR = TCHAR*; using PCSC_UCHAR_PTR = LPBYTE; using PCSC_CUCHAR_PTR = LPCBYTE; #elif defined Q_OS_MACOS @@ -34,15 +34,15 @@ using PCSC_RETURNCODE = int32_t; using PCSC_INT = uint32_t; using PCSC_CHAR = char; using PCSC_CHAR_PTR = char*; -using PCSC_UCHAR_PTR = uchar *; -using PCSC_CUCHAR_PTR = const uchar *; +using PCSC_UCHAR_PTR = uchar*; +using PCSC_CUCHAR_PTR = const uchar*; #elif defined Q_OS_UNIX using PCSC_RETURNCODE = LONG; using PCSC_INT = DWORD; using PCSC_CHAR = char; using PCSC_CHAR_PTR = char*; -using PCSC_UCHAR_PTR = uchar *; -using PCSC_CUCHAR_PTR = const uchar *; +using PCSC_UCHAR_PTR = uchar*; +using PCSC_CUCHAR_PTR = const uchar*; #endif diff --git a/src/configuration/CallCost.cpp b/src/configuration/CallCost.cpp index 0ba21886f..28add40be 100644 --- a/src/configuration/CallCost.cpp +++ b/src/configuration/CallCost.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "CallCost.h" diff --git a/src/configuration/CallCost.h b/src/configuration/CallCost.h index e37f8c093..26309680d 100644 --- a/src/configuration/CallCost.h +++ b/src/configuration/CallCost.h @@ -1,7 +1,7 @@ /*! * \brief Phone call cost representation * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/configuration/LanguageString.cpp b/src/configuration/LanguageString.cpp index da0207cfe..ed340a42c 100644 --- a/src/configuration/LanguageString.cpp +++ b/src/configuration/LanguageString.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "LanguageString.h" diff --git a/src/configuration/LanguageString.h b/src/configuration/LanguageString.h index 40cff3af7..9e7d629e1 100644 --- a/src/configuration/LanguageString.h +++ b/src/configuration/LanguageString.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/configuration/ProviderConfiguration.cpp b/src/configuration/ProviderConfiguration.cpp index 310d34779..0fe210adb 100644 --- a/src/configuration/ProviderConfiguration.cpp +++ b/src/configuration/ProviderConfiguration.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderConfiguration.h" diff --git a/src/configuration/ProviderConfiguration.h b/src/configuration/ProviderConfiguration.h index 0e7e5aaca..d2f0faafa 100644 --- a/src/configuration/ProviderConfiguration.h +++ b/src/configuration/ProviderConfiguration.h @@ -1,7 +1,7 @@ /*! * \brief Provides information of provider json. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/configuration/ProviderConfigurationInfo.cpp b/src/configuration/ProviderConfigurationInfo.cpp index e2f7b8f55..8d777422a 100644 --- a/src/configuration/ProviderConfigurationInfo.cpp +++ b/src/configuration/ProviderConfigurationInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderConfigurationInfo.h" diff --git a/src/configuration/ProviderConfigurationInfo.h b/src/configuration/ProviderConfigurationInfo.h index f8f5ab8be..8cb411427 100644 --- a/src/configuration/ProviderConfigurationInfo.h +++ b/src/configuration/ProviderConfigurationInfo.h @@ -1,7 +1,7 @@ /*! * \brief Class to provide information about providers. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/configuration/ProviderConfigurationParser.cpp b/src/configuration/ProviderConfigurationParser.cpp index 2830271ca..dff047001 100644 --- a/src/configuration/ProviderConfigurationParser.cpp +++ b/src/configuration/ProviderConfigurationParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderConfigurationParser.h" diff --git a/src/configuration/ProviderConfigurationParser.h b/src/configuration/ProviderConfigurationParser.h index f95b78d1e..3876c0181 100644 --- a/src/configuration/ProviderConfigurationParser.h +++ b/src/configuration/ProviderConfigurationParser.h @@ -1,7 +1,7 @@ /*! * \brief Parser for provider configuration files * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/configuration/ReaderConfiguration.cpp b/src/configuration/ReaderConfiguration.cpp index b8f6684c1..239323922 100644 --- a/src/configuration/ReaderConfiguration.cpp +++ b/src/configuration/ReaderConfiguration.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderConfiguration.h" @@ -98,22 +98,24 @@ void ReaderConfiguration::update() } -const ReaderConfigurationInfo ReaderConfiguration::getRemoteReaderConfigurationInfo() const +const QVector& ReaderConfiguration::getReaderConfigurationInfos() const { - return getReaderConfigurationInfoById(UsbId()); + return mReaderConfigurationInfos; } -const QVector& ReaderConfiguration::getReaderConfigurationInfos() const +QVector ReaderConfiguration::getSupportedReaderConfigurationInfos() const { - return mReaderConfigurationInfos; + return filter([](const ReaderConfigurationInfo& i){ + return !i.getUrl().isEmpty(); + }, qAsConst(mReaderConfigurationInfos)); } -const QVector ReaderConfiguration::getSupportedReaderConfigurationInfos() const +QVector ReaderConfiguration::getVirtualReaderConfigurationInfos() const { return filter([](const ReaderConfigurationInfo& i){ - return !i.getUrl().isEmpty(); + return i.getVendorId() == 0x0; }, qAsConst(mReaderConfigurationInfos)); } diff --git a/src/configuration/ReaderConfiguration.h b/src/configuration/ReaderConfiguration.h index d681edba8..64cdfeb56 100644 --- a/src/configuration/ReaderConfiguration.h +++ b/src/configuration/ReaderConfiguration.h @@ -1,7 +1,7 @@ /*! * \brief Class to store configuration data about available card readers. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -49,9 +49,9 @@ class ReaderConfiguration static QString getMultipleReaderIconPath(); void update(); - const ReaderConfigurationInfo getRemoteReaderConfigurationInfo() const; const QVector& getReaderConfigurationInfos() const; - const QVector getSupportedReaderConfigurationInfos() const; + QVector getSupportedReaderConfigurationInfos() const; + QVector getVirtualReaderConfigurationInfos() const; ReaderConfigurationInfo getReaderConfigurationInfoById(const UsbId& pId) const; diff --git a/src/configuration/ReaderConfigurationInfo.cpp b/src/configuration/ReaderConfigurationInfo.cpp index 2eaf6c82f..1958192ef 100644 --- a/src/configuration/ReaderConfigurationInfo.cpp +++ b/src/configuration/ReaderConfigurationInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderConfigurationInfo.h" diff --git a/src/configuration/ReaderConfigurationInfo.h b/src/configuration/ReaderConfigurationInfo.h index e385c3af9..800b4ff1a 100644 --- a/src/configuration/ReaderConfigurationInfo.h +++ b/src/configuration/ReaderConfigurationInfo.h @@ -1,7 +1,7 @@ /*! * \brief Class to provide information about available card readers. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/configuration/ReaderConfigurationParser.cpp b/src/configuration/ReaderConfigurationParser.cpp index 426d15e62..7bca19367 100644 --- a/src/configuration/ReaderConfigurationParser.cpp +++ b/src/configuration/ReaderConfigurationParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderConfigurationParser.h" diff --git a/src/configuration/ReaderConfigurationParser.h b/src/configuration/ReaderConfigurationParser.h index 42b5dc91e..e2614ac26 100644 --- a/src/configuration/ReaderConfigurationParser.h +++ b/src/configuration/ReaderConfigurationParser.h @@ -1,7 +1,7 @@ /*! * \brief Parser for reader configuration files * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/CertificateChecker.cpp b/src/core/CertificateChecker.cpp index 8bc252af8..2da25ad67 100644 --- a/src/core/CertificateChecker.cpp +++ b/src/core/CertificateChecker.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CertificateChecker.h" diff --git a/src/core/CertificateChecker.h b/src/core/CertificateChecker.h index 2a888118e..b123ae29f 100644 --- a/src/core/CertificateChecker.h +++ b/src/core/CertificateChecker.h @@ -1,7 +1,7 @@ /*! * \brief Contains the definition of the CertificateChecker class. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/DiagnosisAntivirusDetection.cpp b/src/core/DiagnosisAntivirusDetection.cpp index bfe96ff81..a31523c11 100644 --- a/src/core/DiagnosisAntivirusDetection.cpp +++ b/src/core/DiagnosisAntivirusDetection.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisAntivirusDetection.h" diff --git a/src/core/DiagnosisAntivirusDetection.h b/src/core/DiagnosisAntivirusDetection.h index c702813b4..5c35394a1 100644 --- a/src/core/DiagnosisAntivirusDetection.h +++ b/src/core/DiagnosisAntivirusDetection.h @@ -1,7 +1,7 @@ /*! * \brief Class for retrieving informations about installed antivirus software on windows. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/DiagnosisConnectionTest.cpp b/src/core/DiagnosisConnectionTest.cpp index 825af91c8..3648bdde6 100644 --- a/src/core/DiagnosisConnectionTest.cpp +++ b/src/core/DiagnosisConnectionTest.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisConnectionTest.h" diff --git a/src/core/DiagnosisConnectionTest.h b/src/core/DiagnosisConnectionTest.h index a2c89a070..455f29b20 100644 --- a/src/core/DiagnosisConnectionTest.h +++ b/src/core/DiagnosisConnectionTest.h @@ -3,7 +3,7 @@ * to establish a connection to a test server with and without the proxy and providing the * results to the DiagnosisModel. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/DiagnosisFirewallDetection.cpp b/src/core/DiagnosisFirewallDetection.cpp index b3b9844bc..1707825eb 100644 --- a/src/core/DiagnosisFirewallDetection.cpp +++ b/src/core/DiagnosisFirewallDetection.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisFirewallDetection.h" diff --git a/src/core/DiagnosisFirewallDetection.h b/src/core/DiagnosisFirewallDetection.h index ecc0aea58..c2936c4f2 100644 --- a/src/core/DiagnosisFirewallDetection.h +++ b/src/core/DiagnosisFirewallDetection.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/DiagnosisItem.cpp b/src/core/DiagnosisItem.cpp index c1f77e50a..47171a050 100644 --- a/src/core/DiagnosisItem.cpp +++ b/src/core/DiagnosisItem.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisItem.h" diff --git a/src/core/DiagnosisItem.h b/src/core/DiagnosisItem.h index 24dabbee1..cf28fd45e 100644 --- a/src/core/DiagnosisItem.h +++ b/src/core/DiagnosisItem.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/DiagnosisModel.cpp b/src/core/DiagnosisModel.cpp index ede4eb21f..832b8ad85 100644 --- a/src/core/DiagnosisModel.cpp +++ b/src/core/DiagnosisModel.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisModel.h" @@ -57,13 +57,13 @@ void DiagnosisModel::createCardReaderSection() { mCombinedReaderSection = QSharedPointer::create(); mPcscSection = QSharedPointer::create(); - mPcscSection->addTitleWithoutContent(tr("PC/SC information")); + mPcscSection->addTitleWithoutContent(tr("PC/SC driver information")); mPcscSection->addItemWithoutTitle(tr("Diagnosis is running...")); mCardReaderSection = QSharedPointer::create(); mCardReaderSection->addTitleWithoutContent(tr("Card reader")); mCardReaderSection->addItemWithoutTitle(tr("Diagnosis is running...")); mRemoteDeviceSection = QSharedPointer::create(); - mRemoteDeviceSection->addTitleWithoutContent(tr("Paired remote devices")); + mRemoteDeviceSection->addTitleWithoutContent(tr("Paired smartphones")); mRemoteDeviceSection->addItemWithoutTitle(tr("Diagnosis is running...")); } @@ -207,7 +207,7 @@ QString DiagnosisModel::getAsPlaintext() const for (const auto& sectionPair : qAsConst(mSections)) { modelPlaintext << sectionPair.first; - modelPlaintext << sectionPair.second->getAsPlaintext(QStringLiteral("\t")); + modelPlaintext << sectionPair.second->getAsPlaintext(); modelPlaintext << endl; } @@ -274,7 +274,7 @@ void DiagnosisModel::onNetworkInfoChanged() } } - mNetworkInterfaceSection->addItem(tr("Interface: \"%1\"").arg(iface.humanReadableName()), interfaceInfos.join(QStringLiteral("\n"))); + mNetworkInterfaceSection->addItem(iface.humanReadableName(), interfaceInfos.join(QStringLiteral("\n"))); } mCombinedNetworkSection->replaceWithSections({mNetworkConnectionSection, mNetworkInterfaceSection}); @@ -448,7 +448,7 @@ void DiagnosisModel::onPcscInfoChanged() mPcscSection->removeAllItems(); mPcscSection->addTitleWithoutContent(tr("PC/SC information")); - mPcscSection->addItemWithoutTitle(tr("Version: %1").arg(mContext->getPcscVersion())); + mPcscSection->addItem(tr("Version"), mContext->getPcscVersion()); QStringList pcscInfo; for (const auto& info : mContext->getPcscComponents()) @@ -476,7 +476,7 @@ void DiagnosisModel::onPcscInfoChanged() mPcscSection->addItem(tr("Driver"), pcscInfo.join(QStringLiteral("\n"))); } - mCombinedReaderSection->replaceWithSections({mCardReaderSection, mRemoteDeviceSection, mPcscSection}); + mCombinedReaderSection->replaceWithSections({mRemoteDeviceSection, mCardReaderSection, mPcscSection}); } @@ -487,7 +487,7 @@ void DiagnosisModel::onRemoteInfosChanged() const RemoteServiceSettings& settings = Env::getSingleton()->getRemoteServiceSettings(); const auto& trustedCertificates = settings.getTrustedCertificates(); - mRemoteDeviceSection->addTitleWithoutContent(tr("Paired remote devices")); + mRemoteDeviceSection->addTitleWithoutContent(tr("Paired smartphones")); if (trustedCertificates.isEmpty()) { @@ -501,11 +501,8 @@ void DiagnosisModel::onRemoteInfosChanged() if (!info.getFingerprint().isEmpty()) { - certInfo << tr("Certificate fingerprint: %1").arg(info.getFingerprint()); const QString& timestamp = LanguageLoader::getInstance().getUsedLocale().toString(info.getLastConnected(), tr("dd.MM.yyyy, hh:mm:ss")); - certInfo << tr("Last connection: %1").arg(timestamp); - - mRemoteDeviceSection->addItem(info.getName(), certInfo.join(QStringLiteral("\n"))); + mRemoteDeviceSection->addItem(info.getName(), tr("Last connection: %1").arg(timestamp)); } else { @@ -513,7 +510,7 @@ void DiagnosisModel::onRemoteInfosChanged() } } - mCombinedReaderSection->replaceWithSections({mCardReaderSection, mRemoteDeviceSection, mPcscSection}); + mCombinedReaderSection->replaceWithSections({mRemoteDeviceSection, mCardReaderSection, mPcscSection}); } @@ -545,7 +542,7 @@ void DiagnosisModel::onReaderInfosChanged() mCardReaderSection->addItem(info.getName(), infoList.join(QStringLiteral("\n"))); } - mCombinedReaderSection->replaceWithSections({mCardReaderSection, mRemoteDeviceSection, mPcscSection}); + mCombinedReaderSection->replaceWithSections({mRemoteDeviceSection, mCardReaderSection, mPcscSection}); } @@ -559,7 +556,7 @@ void DiagnosisModel::reloadContent() mSections.append(qMakePair(QCoreApplication::applicationName(), createAusweisApp2Section())); createCardReaderSection(); - mCombinedReaderSection->replaceWithSections({mCardReaderSection, mRemoteDeviceSection, mPcscSection}); + mCombinedReaderSection->replaceWithSections({mRemoteDeviceSection, mCardReaderSection, mPcscSection}); mSections.append(qMakePair(tr("Card reader"), mCombinedReaderSection)); createNetworkSection(); diff --git a/src/core/DiagnosisModel.h b/src/core/DiagnosisModel.h index 33b086801..87915fb38 100644 --- a/src/core/DiagnosisModel.h +++ b/src/core/DiagnosisModel.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/DiagnosisTreeModel.cpp b/src/core/DiagnosisTreeModel.cpp index 9e2982dd0..804602784 100644 --- a/src/core/DiagnosisTreeModel.cpp +++ b/src/core/DiagnosisTreeModel.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisTreeModel.h" diff --git a/src/core/DiagnosisTreeModel.h b/src/core/DiagnosisTreeModel.h index 5ed311b86..5a4bc3805 100644 --- a/src/core/DiagnosisTreeModel.h +++ b/src/core/DiagnosisTreeModel.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/SelfAuthenticationData.cpp b/src/core/SelfAuthenticationData.cpp index 1669b9975..7bd53f5f9 100644 --- a/src/core/SelfAuthenticationData.cpp +++ b/src/core/SelfAuthenticationData.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SelfAuthenticationData.h" diff --git a/src/core/SelfAuthenticationData.h b/src/core/SelfAuthenticationData.h index 10a8b6e82..38f4b157c 100644 --- a/src/core/SelfAuthenticationData.h +++ b/src/core/SelfAuthenticationData.h @@ -1,7 +1,7 @@ /*! * \brief Parses self authentication data from JSON data and provides its content. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/TcToken.cpp b/src/core/TcToken.cpp index 5b508a814..629a93da3 100644 --- a/src/core/TcToken.cpp +++ b/src/core/TcToken.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/core/TcToken.h b/src/core/TcToken.h index 3336817a2..f284b730f 100644 --- a/src/core/TcToken.h +++ b/src/core/TcToken.h @@ -1,7 +1,7 @@ /*! * \brief Parses TCTokens from XML data and provides its content. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/context/AuthContext.cpp b/src/core/context/AuthContext.cpp index d3fa695c6..37af88dc4 100644 --- a/src/core/context/AuthContext.cpp +++ b/src/core/context/AuthContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AuthContext.h" @@ -130,7 +130,14 @@ bool AuthContext::removeForbiddenAccessRights(QSet& pAccessRights) } const auto& allowedCvcAccessRights = mTerminalCvc->getBody().getCHAT().getAccessRights(); - const auto& allDisplayedOrderedRights = AccessRoleAndRightsUtil::allDisplayedOrderedRights().toSet(); + + const auto rights = AccessRoleAndRightsUtil::allDisplayedOrderedRights(); +#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)) + const auto& allDisplayedOrderedRights = QSet(rights.constBegin(), rights.constEnd()); +#else + const auto& allDisplayedOrderedRights = rights.toSet(); +#endif + const auto& allowedAccessRights = allowedCvcAccessRights & allDisplayedOrderedRights; const auto rightsToCheck = pAccessRights; @@ -272,7 +279,8 @@ QByteArray AuthContext::encodeEffectiveChat() effectiveChat.setAccessRight(AccessRight::CAN_ALLOWED); } - qDebug() << "Using effective CHAT:" << effectiveChat.encode().toHex(); + qDebug() << "Using effective CHAT:" << effectiveChat.encode().toHex() << "with access rights:" << effectiveChat.getAccessRights(); + return effectiveChat.encode(); } diff --git a/src/core/context/AuthContext.h b/src/core/context/AuthContext.h index d06631e01..0445724c4 100644 --- a/src/core/context/AuthContext.h +++ b/src/core/context/AuthContext.h @@ -1,7 +1,7 @@ /*! * \brief Authentication context. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/context/ChangePinContext.cpp b/src/core/context/ChangePinContext.cpp index 9a32bc33e..9453cdc58 100644 --- a/src/core/context/ChangePinContext.cpp +++ b/src/core/context/ChangePinContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ChangePinContext.h" diff --git a/src/core/context/ChangePinContext.h b/src/core/context/ChangePinContext.h index 405a225e1..caadd5b75 100644 --- a/src/core/context/ChangePinContext.h +++ b/src/core/context/ChangePinContext.h @@ -1,7 +1,7 @@ /*! * \brief Context for changing the Pin. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/context/DiagnosisContext.cpp b/src/core/context/DiagnosisContext.cpp index 22d8be7c4..00cfa6ecf 100644 --- a/src/core/context/DiagnosisContext.cpp +++ b/src/core/context/DiagnosisContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisContext.h" diff --git a/src/core/context/DiagnosisContext.h b/src/core/context/DiagnosisContext.h index 5e3010dff..25bc2a36e 100644 --- a/src/core/context/DiagnosisContext.h +++ b/src/core/context/DiagnosisContext.h @@ -1,7 +1,7 @@ /*! * \brief Contains information collected by the diagnosis functionality. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/context/RemoteServiceContext.cpp b/src/core/context/RemoteServiceContext.cpp index 27b2bf4a8..ce8a0a3b1 100644 --- a/src/core/context/RemoteServiceContext.cpp +++ b/src/core/context/RemoteServiceContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteServiceContext.h" @@ -13,6 +13,7 @@ using namespace governikus; void RemoteServiceContext::onMessageHandlerAdded(QSharedPointer pHandler) { connect(pHandler.data(), &ServerMessageHandler::fireCardConnectionEstablished, this, &RemoteServiceContext::fireCardConnectionEstablished); + connect(getRemoteServer().data(), &RemoteServer::fireConnectedChanged, this, &RemoteServiceContext::onResetMessageHandler); } diff --git a/src/core/context/RemoteServiceContext.h b/src/core/context/RemoteServiceContext.h index 22e7d3d66..525b155f8 100644 --- a/src/core/context/RemoteServiceContext.h +++ b/src/core/context/RemoteServiceContext.h @@ -1,7 +1,7 @@ /*! * \brief Remote service context. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/context/SelfAuthContext.cpp b/src/core/context/SelfAuthContext.cpp index 3af5d4318..cad252b19 100644 --- a/src/core/context/SelfAuthContext.cpp +++ b/src/core/context/SelfAuthContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "SelfAuthContext.h" diff --git a/src/core/context/SelfAuthContext.h b/src/core/context/SelfAuthContext.h index 8374bb86c..892d910a0 100644 --- a/src/core/context/SelfAuthContext.h +++ b/src/core/context/SelfAuthContext.h @@ -1,7 +1,7 @@ /*! * \brief Self authentication context. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/context/WorkflowContext.cpp b/src/core/context/WorkflowContext.cpp index 2a00700dc..66c27d2b7 100644 --- a/src/core/context/WorkflowContext.cpp +++ b/src/core/context/WorkflowContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "WorkflowContext.h" diff --git a/src/core/context/WorkflowContext.h b/src/core/context/WorkflowContext.h index 3cee4b581..992c69aa1 100644 --- a/src/core/context/WorkflowContext.h +++ b/src/core/context/WorkflowContext.h @@ -1,7 +1,7 @@ /*! * \brief Workflow context. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/controller/AppController.cpp b/src/core/controller/AppController.cpp index 76d4c3909..7fc4e2288 100644 --- a/src/core/controller/AppController.cpp +++ b/src/core/controller/AppController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AppController.h" @@ -22,6 +22,7 @@ #include "ReaderManager.h" #include "RemoteClient.h" #include "ResourceLoader.h" +#include "SecureStorage.h" #include "UILoader.h" #include "UIPlugIn.h" @@ -152,14 +153,15 @@ bool AppController::eventFilter(QObject* pObj, QEvent* pEvent) bool AppController::start() { + if (!Env::getSingleton()->isLoaded()) + { + qCritical() << "SecureStorage not loaded"; + return false; + } + // Force construction of RemoteClient in the MainThread Env::getSingleton(); - const auto readerManager = Env::getSingleton(); - readerManager->init(); - connect(this, &AppController::fireShutdown, readerManager, &ReaderManager::shutdown, Qt::QueuedConnection); - connect(readerManager, &ReaderManager::fireInitialized, this, &AppController::fireStarted, Qt::QueuedConnection); - connect(&UILoader::getInstance(), &UILoader::fireLoadedPlugin, this, &AppController::onUiPlugin); if (!UILoader::getInstance().load()) { @@ -183,6 +185,13 @@ bool AppController::start() qDebug() << "Successfully started activation handler:" << handler; } + // Start the ReaderManager *after* initializing the ActivationHandlers. Otherwise the TrayIcon + // will be created even when we're just showing an error message and shutdown after that. + const auto readerManager = Env::getSingleton(); + readerManager->init(); + connect(this, &AppController::fireShutdown, readerManager, &ReaderManager::shutdown, Qt::QueuedConnection); + connect(readerManager, &ReaderManager::fireInitialized, this, &AppController::fireStarted, Qt::QueuedConnection); + connect(this, &AppController::fireStarted, this, [this] { if (cShowUi) { diff --git a/src/core/controller/AppController.h b/src/core/controller/AppController.h index 484ce6178..42f7aa151 100644 --- a/src/core/controller/AppController.h +++ b/src/core/controller/AppController.h @@ -1,7 +1,7 @@ /*! * \brief Controller of the whole program. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/controller/AuthController.cpp b/src/core/controller/AuthController.cpp index a63a928a4..d6dbba17c 100644 --- a/src/core/controller/AuthController.cpp +++ b/src/core/controller/AuthController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "controller/AuthController.h" diff --git a/src/core/controller/AuthController.h b/src/core/controller/AuthController.h index fb2025da6..900e85e7c 100644 --- a/src/core/controller/AuthController.h +++ b/src/core/controller/AuthController.h @@ -1,7 +1,7 @@ /*! * \brief Controller for the authentication process. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/controller/ChangePinController.cpp b/src/core/controller/ChangePinController.cpp index 49a84fb7c..9978c57c9 100644 --- a/src/core/controller/ChangePinController.cpp +++ b/src/core/controller/ChangePinController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ChangePinController.h" @@ -39,7 +39,6 @@ ChangePinController::ChangePinController(QSharedPointer pConte mStateMachine.setInitialState(sStatePace); sStatePace->addTransition(sStatePace, &CompositeStatePace::firePaceChannelEstablished, sPrepareChangePin); - sStatePace->addTransition(sStatePace, &CompositeStatePace::firePacePukEstablished, sStatePace); sStatePace->addTransition(sStatePace, &CompositeStatePace::fireAbort, sClearPacePasswords); sPrepareChangePin->addTransition(sPrepareChangePin, &StatePrepareChangePin::fireContinue, sChangePin); diff --git a/src/core/controller/ChangePinController.h b/src/core/controller/ChangePinController.h index d0950b150..0c95952a4 100644 --- a/src/core/controller/ChangePinController.h +++ b/src/core/controller/ChangePinController.h @@ -1,7 +1,7 @@ /*! * \brief Controller for the PIN changing process. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/controller/DiagnosisController.cpp b/src/core/controller/DiagnosisController.cpp index e74cbb572..02093eab0 100644 --- a/src/core/controller/DiagnosisController.cpp +++ b/src/core/controller/DiagnosisController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisController.h" diff --git a/src/core/controller/DiagnosisController.h b/src/core/controller/DiagnosisController.h index 80c056fc2..70031527b 100644 --- a/src/core/controller/DiagnosisController.h +++ b/src/core/controller/DiagnosisController.h @@ -1,7 +1,7 @@ /*! * \brief Controller for retrieving and presenting diagnosis info. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/controller/DiagnosisController_generic.cpp b/src/core/controller/DiagnosisController_generic.cpp index 14ae37154..e3772b2e6 100644 --- a/src/core/controller/DiagnosisController_generic.cpp +++ b/src/core/controller/DiagnosisController_generic.cpp @@ -1,7 +1,7 @@ /*! * \brief Generic implementation of the controller for retrieving and presenting diagnosis info. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/core/controller/DiagnosisController_osx.cpp b/src/core/controller/DiagnosisController_osx.mm similarity index 98% rename from src/core/controller/DiagnosisController_osx.cpp rename to src/core/controller/DiagnosisController_osx.mm index c88c133e8..f4e04ede4 100644 --- a/src/core/controller/DiagnosisController_osx.cpp +++ b/src/core/controller/DiagnosisController_osx.mm @@ -1,7 +1,7 @@ /*! * \brief Mac OS X specific implementation of the controller for retrieving and presenting diagnosis info. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/core/controller/DiagnosisController_win.cpp b/src/core/controller/DiagnosisController_win.cpp index d7023615f..69e7b37ba 100644 --- a/src/core/controller/DiagnosisController_win.cpp +++ b/src/core/controller/DiagnosisController_win.cpp @@ -1,7 +1,7 @@ /*! * \brief Windows specific implementation of the controller for retrieving and presenting diagnosis info. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ @@ -51,7 +51,10 @@ static QString toAbsoluteWindowsDirectoryPath(const QString& pPath) static QString getWindowsFileVersionString(QByteArray& pVersionData, const char* const pInfoName, int pLanguage, int pCodePage) { - QString key = QString().sprintf("\\StringFileInfo\\%04x%04x\\%s", pLanguage, pCodePage, pInfoName); + const auto key = QStringLiteral("\\StringFileInfo\\%1%2\\%3") + .arg(pLanguage, 4, 16, QLatin1Char('0')) + .arg(pCodePage, 4, 16, QLatin1Char('0')) + .arg(QString::fromLatin1(pInfoName)); LPVOID version; UINT versionLength; diff --git a/src/core/controller/RemoteServiceController.cpp b/src/core/controller/RemoteServiceController.cpp index f9a866ee5..a53584358 100644 --- a/src/core/controller/RemoteServiceController.cpp +++ b/src/core/controller/RemoteServiceController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "controller/RemoteServiceController.h" diff --git a/src/core/controller/RemoteServiceController.h b/src/core/controller/RemoteServiceController.h index 8560626db..97c637253 100644 --- a/src/core/controller/RemoteServiceController.h +++ b/src/core/controller/RemoteServiceController.h @@ -1,7 +1,7 @@ /*! * \brief Controller for the remote service process. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/controller/SelfAuthController.cpp b/src/core/controller/SelfAuthController.cpp index 5131fdce6..9d93eefad 100644 --- a/src/core/controller/SelfAuthController.cpp +++ b/src/core/controller/SelfAuthController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "controller/SelfAuthController.h" diff --git a/src/core/controller/SelfAuthController.h b/src/core/controller/SelfAuthController.h index 69429383e..c924b8a15 100644 --- a/src/core/controller/SelfAuthController.h +++ b/src/core/controller/SelfAuthController.h @@ -1,7 +1,7 @@ /*! * \brief Controller for the self authentication process. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/controller/WorkflowController.cpp b/src/core/controller/WorkflowController.cpp index 3867c2c7d..8255eee42 100644 --- a/src/core/controller/WorkflowController.cpp +++ b/src/core/controller/WorkflowController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "controller/WorkflowController.h" diff --git a/src/core/controller/WorkflowController.h b/src/core/controller/WorkflowController.h index 559a75e99..fbc4066ce 100644 --- a/src/core/controller/WorkflowController.h +++ b/src/core/controller/WorkflowController.h @@ -1,7 +1,7 @@ /*! * \brief Base class for controllers controlling a workflow (using a state machine). * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/ElementDetector.cpp b/src/core/paos/ElementDetector.cpp index 795d1f8d6..3880ecf61 100644 --- a/src/core/paos/ElementDetector.cpp +++ b/src/core/paos/ElementDetector.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ElementDetector.h" diff --git a/src/core/paos/ElementDetector.h b/src/core/paos/ElementDetector.h index 43247072f..2a500a99c 100644 --- a/src/core/paos/ElementDetector.h +++ b/src/core/paos/ElementDetector.h @@ -1,7 +1,7 @@ /** * \brief Example class * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/PaosHandler.cpp b/src/core/paos/PaosHandler.cpp index 82ce51613..a22a61d6d 100644 --- a/src/core/paos/PaosHandler.cpp +++ b/src/core/paos/PaosHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/DidList.h" diff --git a/src/core/paos/PaosHandler.h b/src/core/paos/PaosHandler.h index 32abf736c..a92d854cb 100644 --- a/src/core/paos/PaosHandler.h +++ b/src/core/paos/PaosHandler.h @@ -1,7 +1,7 @@ /*! * \brief Generic Handler to detect and parse paos types. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/PaosMessage.cpp b/src/core/paos/PaosMessage.cpp index 9394bafcf..67f04791c 100644 --- a/src/core/paos/PaosMessage.cpp +++ b/src/core/paos/PaosMessage.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PaosMessage.h" diff --git a/src/core/paos/PaosMessage.h b/src/core/paos/PaosMessage.h index 98e8e18b9..7c5405fd4 100644 --- a/src/core/paos/PaosMessage.h +++ b/src/core/paos/PaosMessage.h @@ -1,7 +1,7 @@ /*! * \brief object represents one paos type * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/PaosType.cpp b/src/core/paos/PaosType.cpp index 01af523cf..47d76a89a 100644 --- a/src/core/paos/PaosType.cpp +++ b/src/core/paos/PaosType.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PaosType.h" diff --git a/src/core/paos/PaosType.h b/src/core/paos/PaosType.h index e319f1525..cfbb51eaa 100644 --- a/src/core/paos/PaosType.h +++ b/src/core/paos/PaosType.h @@ -1,7 +1,7 @@ /*! * \brief All possible paos types * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/RequestType.cpp b/src/core/paos/RequestType.cpp index 1e64662c8..2c3bcccd4 100644 --- a/src/core/paos/RequestType.cpp +++ b/src/core/paos/RequestType.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "RequestType.h" diff --git a/src/core/paos/RequestType.h b/src/core/paos/RequestType.h index 65c54f2ea..44d6d5035 100644 --- a/src/core/paos/RequestType.h +++ b/src/core/paos/RequestType.h @@ -1,7 +1,7 @@ /*! * \brief Represents a PAOS request type according to ISOCommon.xsd * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/ResponseType.cpp b/src/core/paos/ResponseType.cpp index b229f6b5b..e3708a394 100644 --- a/src/core/paos/ResponseType.cpp +++ b/src/core/paos/ResponseType.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ResponseType.h" diff --git a/src/core/paos/ResponseType.h b/src/core/paos/ResponseType.h index 6ae37fd30..3524c2844 100644 --- a/src/core/paos/ResponseType.h +++ b/src/core/paos/ResponseType.h @@ -1,7 +1,7 @@ /*! * \brief Represents a PAOS response type according to ISOCommon.xsd * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/core/paos/element/ConnectionHandle.cpp b/src/core/paos/element/ConnectionHandle.cpp index a93282c95..b62e75f8d 100644 --- a/src/core/paos/element/ConnectionHandle.cpp +++ b/src/core/paos/element/ConnectionHandle.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ConnectionHandle.h" diff --git a/src/core/paos/element/ConnectionHandle.h b/src/core/paos/element/ConnectionHandle.h index b03bcaf0c..d54160ae2 100644 --- a/src/core/paos/element/ConnectionHandle.h +++ b/src/core/paos/element/ConnectionHandle.h @@ -1,7 +1,7 @@ /*! * \brief Object hold the paos connection handle. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/element/ConnectionHandleParser.cpp b/src/core/paos/element/ConnectionHandleParser.cpp index b97ce02b3..e252b2355 100644 --- a/src/core/paos/element/ConnectionHandleParser.cpp +++ b/src/core/paos/element/ConnectionHandleParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ConnectionHandleParser.h" diff --git a/src/core/paos/element/ConnectionHandleParser.h b/src/core/paos/element/ConnectionHandleParser.h index f0c995573..f5ff2a1bf 100644 --- a/src/core/paos/element/ConnectionHandleParser.h +++ b/src/core/paos/element/ConnectionHandleParser.h @@ -1,7 +1,7 @@ /*! * \brief Parse an XML connection handle from given stream. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/element/Eac1InputType.cpp b/src/core/paos/element/Eac1InputType.cpp index c8779ceeb..1bb68bf91 100644 --- a/src/core/paos/element/Eac1InputType.cpp +++ b/src/core/paos/element/Eac1InputType.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "Eac1InputType.h" diff --git a/src/core/paos/element/Eac1InputType.h b/src/core/paos/element/Eac1InputType.h index 5c7c48185..c0569b3b7 100644 --- a/src/core/paos/element/Eac1InputType.h +++ b/src/core/paos/element/Eac1InputType.h @@ -1,7 +1,7 @@ /*! * \brief Store information of Eac1InputType. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/element/Eac2InputType.cpp b/src/core/paos/element/Eac2InputType.cpp index 22f38996f..7ec722321 100644 --- a/src/core/paos/element/Eac2InputType.cpp +++ b/src/core/paos/element/Eac2InputType.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "Eac2InputType.h" diff --git a/src/core/paos/element/Eac2InputType.h b/src/core/paos/element/Eac2InputType.h index 5c4f6a97d..4e83bc547 100644 --- a/src/core/paos/element/Eac2InputType.h +++ b/src/core/paos/element/Eac2InputType.h @@ -1,7 +1,7 @@ /*! * \brief Store information of Eac2InputType. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/element/ElementParser.cpp b/src/core/paos/element/ElementParser.cpp index 8dcc3cf9d..b00905e7f 100644 --- a/src/core/paos/element/ElementParser.cpp +++ b/src/core/paos/element/ElementParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ElementParser.h" diff --git a/src/core/paos/element/ElementParser.h b/src/core/paos/element/ElementParser.h index 2aac62259..2b81eaf6c 100644 --- a/src/core/paos/element/ElementParser.h +++ b/src/core/paos/element/ElementParser.h @@ -1,7 +1,7 @@ /*! * \brief Base class for all XML element parser. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/element/SupportedApi.cpp b/src/core/paos/element/SupportedApi.cpp index 2f46319e9..22536340e 100644 --- a/src/core/paos/element/SupportedApi.cpp +++ b/src/core/paos/element/SupportedApi.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SupportedApi.h" diff --git a/src/core/paos/element/SupportedApi.h b/src/core/paos/element/SupportedApi.h index c3a28f289..ed5c0f218 100644 --- a/src/core/paos/element/SupportedApi.h +++ b/src/core/paos/element/SupportedApi.h @@ -1,7 +1,7 @@ /*! * \brief XML element for "SupportedAPI". See TR-03112-7. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/element/UserAgent.cpp b/src/core/paos/element/UserAgent.cpp index 0dcffaadf..6fdb83816 100644 --- a/src/core/paos/element/UserAgent.cpp +++ b/src/core/paos/element/UserAgent.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "UserAgent.h" diff --git a/src/core/paos/element/UserAgent.h b/src/core/paos/element/UserAgent.h index de52eade3..b30fb7e87 100644 --- a/src/core/paos/element/UserAgent.h +++ b/src/core/paos/element/UserAgent.h @@ -1,7 +1,7 @@ /* * \brief Provides UserAgent information for PAOS elements. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/invoke/DidAuthenticateResponseEac1.cpp b/src/core/paos/invoke/DidAuthenticateResponseEac1.cpp index c354946e6..d6a157fff 100644 --- a/src/core/paos/invoke/DidAuthenticateResponseEac1.cpp +++ b/src/core/paos/invoke/DidAuthenticateResponseEac1.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DidAuthenticateResponseEac1.h" diff --git a/src/core/paos/invoke/DidAuthenticateResponseEac1.h b/src/core/paos/invoke/DidAuthenticateResponseEac1.h index 5863d0fe8..dec806ee7 100644 --- a/src/core/paos/invoke/DidAuthenticateResponseEac1.h +++ b/src/core/paos/invoke/DidAuthenticateResponseEac1.h @@ -1,7 +1,7 @@ /*! * \brief Generate information for DIDAuthenticateResponseEAC1. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/invoke/DidAuthenticateResponseEac2.cpp b/src/core/paos/invoke/DidAuthenticateResponseEac2.cpp index ba18d106e..131cc34ad 100644 --- a/src/core/paos/invoke/DidAuthenticateResponseEac2.cpp +++ b/src/core/paos/invoke/DidAuthenticateResponseEac2.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DidAuthenticateResponseEac2.h" diff --git a/src/core/paos/invoke/DidAuthenticateResponseEac2.h b/src/core/paos/invoke/DidAuthenticateResponseEac2.h index 9529c0561..332ed7ce4 100644 --- a/src/core/paos/invoke/DidAuthenticateResponseEac2.h +++ b/src/core/paos/invoke/DidAuthenticateResponseEac2.h @@ -1,7 +1,7 @@ /*! * \brief Generate information for DIDAuthenticateResponseEAC2. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/invoke/DidListResponse.cpp b/src/core/paos/invoke/DidListResponse.cpp index 5f6ec00c3..6f8755bdb 100644 --- a/src/core/paos/invoke/DidListResponse.cpp +++ b/src/core/paos/invoke/DidListResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DidListResponse.h" diff --git a/src/core/paos/invoke/DidListResponse.h b/src/core/paos/invoke/DidListResponse.h index 8c5ae51c1..161eaefe4 100644 --- a/src/core/paos/invoke/DidListResponse.h +++ b/src/core/paos/invoke/DidListResponse.h @@ -1,7 +1,7 @@ /*! * \brief Generate information for DIDListResponse. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/invoke/DisconnectResponse.cpp b/src/core/paos/invoke/DisconnectResponse.cpp index c4d5ff758..3e30f9473 100644 --- a/src/core/paos/invoke/DisconnectResponse.cpp +++ b/src/core/paos/invoke/DisconnectResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DisconnectResponse.h" diff --git a/src/core/paos/invoke/DisconnectResponse.h b/src/core/paos/invoke/DisconnectResponse.h index e944374e8..c556d8a81 100644 --- a/src/core/paos/invoke/DisconnectResponse.h +++ b/src/core/paos/invoke/DisconnectResponse.h @@ -1,7 +1,7 @@ /*! * \brief Generate information for DisconnectResponse. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/invoke/InitializeFrameworkResponse.cpp b/src/core/paos/invoke/InitializeFrameworkResponse.cpp index 92107e727..2fbbb6e16 100644 --- a/src/core/paos/invoke/InitializeFrameworkResponse.cpp +++ b/src/core/paos/invoke/InitializeFrameworkResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "InitializeFrameworkResponse.h" diff --git a/src/core/paos/invoke/InitializeFrameworkResponse.h b/src/core/paos/invoke/InitializeFrameworkResponse.h index 368786031..1c24e172f 100644 --- a/src/core/paos/invoke/InitializeFrameworkResponse.h +++ b/src/core/paos/invoke/InitializeFrameworkResponse.h @@ -1,7 +1,7 @@ /*! * \brief Generate information for InitializeFrameworkResponse. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/invoke/PaosCreator.cpp b/src/core/paos/invoke/PaosCreator.cpp index f111886c9..c9ad6f99d 100644 --- a/src/core/paos/invoke/PaosCreator.cpp +++ b/src/core/paos/invoke/PaosCreator.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PaosCreator.h" diff --git a/src/core/paos/invoke/PaosCreator.h b/src/core/paos/invoke/PaosCreator.h index 882ad61a7..482f87a13 100644 --- a/src/core/paos/invoke/PaosCreator.h +++ b/src/core/paos/invoke/PaosCreator.h @@ -1,7 +1,7 @@ /*! * \brief Base class to create a PaosMessage. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/invoke/StartPaos.cpp b/src/core/paos/invoke/StartPaos.cpp index fd81ed768..38a06b222 100644 --- a/src/core/paos/invoke/StartPaos.cpp +++ b/src/core/paos/invoke/StartPaos.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StartPaos.h" diff --git a/src/core/paos/invoke/StartPaos.h b/src/core/paos/invoke/StartPaos.h index 819d0ab3c..58cee4738 100644 --- a/src/core/paos/invoke/StartPaos.h +++ b/src/core/paos/invoke/StartPaos.h @@ -1,7 +1,7 @@ /*! * \brief Generate information for StartPaos. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/invoke/TransmitResponse.cpp b/src/core/paos/invoke/TransmitResponse.cpp index 03d08c548..f20140179 100644 --- a/src/core/paos/invoke/TransmitResponse.cpp +++ b/src/core/paos/invoke/TransmitResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "TransmitResponse.h" diff --git a/src/core/paos/invoke/TransmitResponse.h b/src/core/paos/invoke/TransmitResponse.h index bea2bbaf3..6cfd1f8dc 100644 --- a/src/core/paos/invoke/TransmitResponse.h +++ b/src/core/paos/invoke/TransmitResponse.h @@ -1,7 +1,7 @@ /*! * \brief Generate information for TransmitResponse. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/DidAuthenticateEac1.cpp b/src/core/paos/retrieve/DidAuthenticateEac1.cpp index f77dc0265..adad3fc88 100644 --- a/src/core/paos/retrieve/DidAuthenticateEac1.cpp +++ b/src/core/paos/retrieve/DidAuthenticateEac1.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/src/core/paos/retrieve/DidAuthenticateEac1.h b/src/core/paos/retrieve/DidAuthenticateEac1.h index 465f9c0ac..692c615c6 100644 --- a/src/core/paos/retrieve/DidAuthenticateEac1.h +++ b/src/core/paos/retrieve/DidAuthenticateEac1.h @@ -1,7 +1,7 @@ /*! * \brief Class represents the retrieved PAOS EAC1InputType. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/core/paos/retrieve/DidAuthenticateEac1Parser.cpp b/src/core/paos/retrieve/DidAuthenticateEac1Parser.cpp index e77af5db2..a3943af4c 100644 --- a/src/core/paos/retrieve/DidAuthenticateEac1Parser.cpp +++ b/src/core/paos/retrieve/DidAuthenticateEac1Parser.cpp @@ -1,7 +1,7 @@ /*! * \brief Parser for the PAOS DidAuthenticateEac1 element. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" @@ -101,6 +101,10 @@ Eac1InputType DidAuthenticateEac1Parser::parseEac1InputType() qCCritical(paos) << "Cannot parse required CHAT"; mParseError = true; } + else + { + qCDebug(paos) << "Access rights:" << eac1.getRequiredChat()->getAccessRights(); + } } } else if (mXmlReader->name() == QLatin1String("OptionalCHAT")) @@ -113,6 +117,10 @@ Eac1InputType DidAuthenticateEac1Parser::parseEac1InputType() qCCritical(paos) << "Cannot parse optional CHAT"; mParseError = true; } + else + { + qCDebug(paos) << "Access rights:" << eac1.getOptionalChat()->getAccessRights(); + } } } else if (mXmlReader->name() == QLatin1String("AuthenticatedAuxiliaryData")) @@ -140,6 +148,8 @@ Eac1InputType DidAuthenticateEac1Parser::parseEac1InputType() { if (auto cvc = CVCertificate::fromHex(readElementText().toLatin1())) { + qCDebug(paos) << "Linked Certificate (Authority):" << cvc->getBody().getCertificationAuthorityReference(); + qCDebug(paos) << "Certificate Name (Holder):" << cvc->getBody().getCertificateHolderReference(); eac1.appendCvcerts(cvc); } else diff --git a/src/core/paos/retrieve/DidAuthenticateEac1Parser.h b/src/core/paos/retrieve/DidAuthenticateEac1Parser.h index 218ee034c..411fb09c6 100644 --- a/src/core/paos/retrieve/DidAuthenticateEac1Parser.h +++ b/src/core/paos/retrieve/DidAuthenticateEac1Parser.h @@ -1,7 +1,7 @@ /*! * \brief Parser for the PAOS DidAuthenticateEac1 element. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/DidAuthenticateEac2.cpp b/src/core/paos/retrieve/DidAuthenticateEac2.cpp index 1247e0ad9..c02ee825e 100644 --- a/src/core/paos/retrieve/DidAuthenticateEac2.cpp +++ b/src/core/paos/retrieve/DidAuthenticateEac2.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/DidAuthenticateEac2.h" diff --git a/src/core/paos/retrieve/DidAuthenticateEac2.h b/src/core/paos/retrieve/DidAuthenticateEac2.h index 04e5dd497..16981139c 100644 --- a/src/core/paos/retrieve/DidAuthenticateEac2.h +++ b/src/core/paos/retrieve/DidAuthenticateEac2.h @@ -1,7 +1,7 @@ /*! * \brief Class represents the retrieved PAOS EAC2InputType. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/DidAuthenticateEac2Parser.cpp b/src/core/paos/retrieve/DidAuthenticateEac2Parser.cpp index bcf073e2b..891c718a0 100644 --- a/src/core/paos/retrieve/DidAuthenticateEac2Parser.cpp +++ b/src/core/paos/retrieve/DidAuthenticateEac2Parser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/DidAuthenticateEac2Parser.h" diff --git a/src/core/paos/retrieve/DidAuthenticateEac2Parser.h b/src/core/paos/retrieve/DidAuthenticateEac2Parser.h index e8617e4ef..d3d2afd3b 100644 --- a/src/core/paos/retrieve/DidAuthenticateEac2Parser.h +++ b/src/core/paos/retrieve/DidAuthenticateEac2Parser.h @@ -1,7 +1,7 @@ /*! * \brief Parse information for DidAuthenticateEac2. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/DidAuthenticateEacAdditional.cpp b/src/core/paos/retrieve/DidAuthenticateEacAdditional.cpp index 1077939b6..b0283ae45 100644 --- a/src/core/paos/retrieve/DidAuthenticateEacAdditional.cpp +++ b/src/core/paos/retrieve/DidAuthenticateEacAdditional.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DidAuthenticateEacAdditional.h" diff --git a/src/core/paos/retrieve/DidAuthenticateEacAdditional.h b/src/core/paos/retrieve/DidAuthenticateEacAdditional.h index be1e8f718..bc558bf8f 100644 --- a/src/core/paos/retrieve/DidAuthenticateEacAdditional.h +++ b/src/core/paos/retrieve/DidAuthenticateEacAdditional.h @@ -1,7 +1,7 @@ /*! * \brief Class to hold information of DIDAuthenticateEACAdditional. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/DidAuthenticateEacAdditionalParser.cpp b/src/core/paos/retrieve/DidAuthenticateEacAdditionalParser.cpp index bf8cf0463..3d7dc187b 100644 --- a/src/core/paos/retrieve/DidAuthenticateEacAdditionalParser.cpp +++ b/src/core/paos/retrieve/DidAuthenticateEacAdditionalParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/DidAuthenticateEacAdditionalParser.h" diff --git a/src/core/paos/retrieve/DidAuthenticateEacAdditionalParser.h b/src/core/paos/retrieve/DidAuthenticateEacAdditionalParser.h index 090c9a788..d138b3ab1 100644 --- a/src/core/paos/retrieve/DidAuthenticateEacAdditionalParser.h +++ b/src/core/paos/retrieve/DidAuthenticateEacAdditionalParser.h @@ -1,7 +1,7 @@ /*! * \brief Parse information for DidAuthenticateEacAdditional. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/DidList.cpp b/src/core/paos/retrieve/DidList.cpp index 92707dff9..56b994c80 100644 --- a/src/core/paos/retrieve/DidList.cpp +++ b/src/core/paos/retrieve/DidList.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DidList.h" diff --git a/src/core/paos/retrieve/DidList.h b/src/core/paos/retrieve/DidList.h index d7d3eac45..cdb97d313 100644 --- a/src/core/paos/retrieve/DidList.h +++ b/src/core/paos/retrieve/DidList.h @@ -1,7 +1,7 @@ /*! * \brief Class represents the retrieved PAOS DIDList. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/Disconnect.cpp b/src/core/paos/retrieve/Disconnect.cpp index 3b26c83b2..9abf84095 100644 --- a/src/core/paos/retrieve/Disconnect.cpp +++ b/src/core/paos/retrieve/Disconnect.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "Disconnect.h" diff --git a/src/core/paos/retrieve/Disconnect.h b/src/core/paos/retrieve/Disconnect.h index bd1fa92ae..bb1a9dd89 100644 --- a/src/core/paos/retrieve/Disconnect.h +++ b/src/core/paos/retrieve/Disconnect.h @@ -1,7 +1,7 @@ /*! * \brief Class represents the retrieved PAOS Disconnect. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/InitializeFramework.cpp b/src/core/paos/retrieve/InitializeFramework.cpp index a257d2f27..05dd9498a 100644 --- a/src/core/paos/retrieve/InitializeFramework.cpp +++ b/src/core/paos/retrieve/InitializeFramework.cpp @@ -1,7 +1,7 @@ /*! * \brief Class represents the retrieved PAOS InitializeFramework * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/PaosType.h" diff --git a/src/core/paos/retrieve/InitializeFramework.h b/src/core/paos/retrieve/InitializeFramework.h index 3707b68c8..f3d0dfbf2 100644 --- a/src/core/paos/retrieve/InitializeFramework.h +++ b/src/core/paos/retrieve/InitializeFramework.h @@ -1,7 +1,7 @@ /*! * \brief Class to parse InitializeFramework from server. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/PaosParser.cpp b/src/core/paos/retrieve/PaosParser.cpp index cfa7e0351..7733968a3 100644 --- a/src/core/paos/retrieve/PaosParser.cpp +++ b/src/core/paos/retrieve/PaosParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PaosParser.h" diff --git a/src/core/paos/retrieve/PaosParser.h b/src/core/paos/retrieve/PaosParser.h index 895300a09..54eb3e667 100644 --- a/src/core/paos/retrieve/PaosParser.h +++ b/src/core/paos/retrieve/PaosParser.h @@ -1,7 +1,7 @@ /*! * \brief Base class for PAOS message parsers. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/StartPaosResponse.cpp b/src/core/paos/retrieve/StartPaosResponse.cpp index 0c021fb44..134639f38 100644 --- a/src/core/paos/retrieve/StartPaosResponse.cpp +++ b/src/core/paos/retrieve/StartPaosResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StartPaosResponse.h" diff --git a/src/core/paos/retrieve/StartPaosResponse.h b/src/core/paos/retrieve/StartPaosResponse.h index db9785d10..fa5fe0fa0 100644 --- a/src/core/paos/retrieve/StartPaosResponse.h +++ b/src/core/paos/retrieve/StartPaosResponse.h @@ -1,7 +1,7 @@ /*! * \brief Class represents the retrieved PAOS StartPaosResponse * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/Transmit.cpp b/src/core/paos/retrieve/Transmit.cpp index 23e5a1757..7259f6fc0 100644 --- a/src/core/paos/retrieve/Transmit.cpp +++ b/src/core/paos/retrieve/Transmit.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "Transmit.h" diff --git a/src/core/paos/retrieve/Transmit.h b/src/core/paos/retrieve/Transmit.h index dff61d31e..c5fa28d9b 100644 --- a/src/core/paos/retrieve/Transmit.h +++ b/src/core/paos/retrieve/Transmit.h @@ -1,7 +1,7 @@ /*! * \brief Transmit objects hold a transmit request and provide access to the transmitted data via member functions. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/paos/retrieve/TransmitParser.cpp b/src/core/paos/retrieve/TransmitParser.cpp index 5c9cf066b..dc5d52e02 100644 --- a/src/core/paos/retrieve/TransmitParser.cpp +++ b/src/core/paos/retrieve/TransmitParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "TransmitParser.h" diff --git a/src/core/paos/retrieve/TransmitParser.h b/src/core/paos/retrieve/TransmitParser.h index cd3aa3895..9c6c34618 100644 --- a/src/core/paos/retrieve/TransmitParser.h +++ b/src/core/paos/retrieve/TransmitParser.h @@ -1,7 +1,7 @@ /*! * \brief Parser for the PAOS Transmit element. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/AbstractState.cpp b/src/core/states/AbstractState.cpp index 169fa8473..16862070b 100644 --- a/src/core/states/AbstractState.cpp +++ b/src/core/states/AbstractState.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AbstractState.h" diff --git a/src/core/states/AbstractState.h b/src/core/states/AbstractState.h index 784864dce..ffb0aa87c 100644 --- a/src/core/states/AbstractState.h +++ b/src/core/states/AbstractState.h @@ -1,7 +1,7 @@ /*! * \brief Base class for all states taken by the state machine. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/CompositeStatePace.cpp b/src/core/states/CompositeStatePace.cpp index e0c0ae1b9..c009ef54c 100644 --- a/src/core/states/CompositeStatePace.cpp +++ b/src/core/states/CompositeStatePace.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "CompositeStatePace.h" @@ -85,7 +85,7 @@ CompositeStatePace::CompositeStatePace(const QSharedPointer& pC sEstablishPaceChannel->addTransition(sEstablishPaceChannel, &AbstractState::fireContinue, sMaintainCardConnection); connect(sEstablishPaceChannel, &StateEstablishPaceChannel::firePaceChannelEstablished, this, &CompositeStatePace::firePaceChannelEstablished); - sEstablishPaceChannel->addTransition(sEstablishPaceChannel, &StateEstablishPaceChannel::firePacePukEstablished, sClearPacePasswordsBeforeDestroy); + sEstablishPaceChannel->addTransition(sEstablishPaceChannel, &StateEstablishPaceChannel::firePaceChannelInoperative, sClearPacePasswordsBeforeDestroy); sEstablishPaceChannel->addTransition(sEstablishPaceChannel, &StateEstablishPaceChannel::fireAbortAndUnfortunateCardPosition, sUnfortunateCardPosition); sEstablishPaceChannel->addTransition(sEstablishPaceChannel, &AbstractState::fireAbort, sMaintainCardConnection); @@ -95,6 +95,6 @@ CompositeStatePace::CompositeStatePace(const QSharedPointer& pC sClearPacePasswordsBeforeDestroy->addTransition(sClearPacePasswordsBeforeDestroy, &AbstractState::fireContinue, sDestroyPace); sClearPacePasswordsBeforeDestroy->addTransition(sClearPacePasswordsBeforeDestroy, &AbstractState::fireAbort, sDestroyPace); - connect(sDestroyPace, &AbstractState::fireContinue, this, &CompositeStatePace::firePacePukEstablished); + sDestroyPace->addTransition(sDestroyPace, &AbstractState::fireContinue, sMaintainCardConnection); connect(sDestroyPace, &AbstractState::fireAbort, this, &CompositeStatePace::fireAbort); } diff --git a/src/core/states/CompositeStatePace.h b/src/core/states/CompositeStatePace.h index fbd7fd65a..f966d9d5e 100644 --- a/src/core/states/CompositeStatePace.h +++ b/src/core/states/CompositeStatePace.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -26,7 +26,6 @@ class CompositeStatePace Q_SIGNALS: void firePaceChannelEstablished(); - void firePacePukEstablished(); void fireAbort(); }; diff --git a/src/core/states/CompositeStateProcessCvcsAndSetRights.cpp b/src/core/states/CompositeStateProcessCvcsAndSetRights.cpp index 42576078d..f1fe7f2b5 100644 --- a/src/core/states/CompositeStateProcessCvcsAndSetRights.cpp +++ b/src/core/states/CompositeStateProcessCvcsAndSetRights.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "CompositeStateProcessCvcsAndSetRights.h" diff --git a/src/core/states/CompositeStateProcessCvcsAndSetRights.h b/src/core/states/CompositeStateProcessCvcsAndSetRights.h index ea1faa9e2..a306b5abb 100644 --- a/src/core/states/CompositeStateProcessCvcsAndSetRights.h +++ b/src/core/states/CompositeStateProcessCvcsAndSetRights.h @@ -1,7 +1,7 @@ /*! * \brief Composite state for selecting a card. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/CompositeStateTrustedChannel.cpp b/src/core/states/CompositeStateTrustedChannel.cpp index c5d57fbbc..bb2fa67dc 100644 --- a/src/core/states/CompositeStateTrustedChannel.cpp +++ b/src/core/states/CompositeStateTrustedChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CompositeStateTrustedChannel.h" @@ -112,7 +112,6 @@ CompositeStateTrustedChannel::CompositeStateTrustedChannel(const QSharedPointer< sProcessCvcsAndSetRights->addTransition(sProcessCvcsAndSetRights, &CompositeStateProcessCvcsAndSetRights::fireAbort, sSendDidAuthenticateResponseEac1); sStatePace->addTransition(sStatePace, &CompositeStatePace::firePaceChannelEstablished, sClearPacePasswords); - sStatePace->addTransition(sStatePace, &CompositeStatePace::firePacePukEstablished, sStatePace); sStatePace->addTransition(sStatePace, &CompositeStatePace::fireAbort, sSendDidAuthenticateResponseEac1); sClearPacePasswords->addTransition(sClearPacePasswords, &AbstractState::fireContinue, sDidAuthenticateEac1); diff --git a/src/core/states/CompositeStateTrustedChannel.h b/src/core/states/CompositeStateTrustedChannel.h index 78cde15c4..72f2dfd6f 100644 --- a/src/core/states/CompositeStateTrustedChannel.h +++ b/src/core/states/CompositeStateTrustedChannel.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/FinalState.cpp b/src/core/states/FinalState.cpp index a46475d6a..97d1625ba 100644 --- a/src/core/states/FinalState.cpp +++ b/src/core/states/FinalState.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "states/FinalState.h" diff --git a/src/core/states/FinalState.h b/src/core/states/FinalState.h index 57c7546a0..51448073b 100644 --- a/src/core/states/FinalState.h +++ b/src/core/states/FinalState.h @@ -1,7 +1,7 @@ /*! * \brief A final state which blocks the state machine before termination. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/GenericContextContainer.h b/src/core/states/GenericContextContainer.h index ac5e2bf7b..32066c8c0 100644 --- a/src/core/states/GenericContextContainer.h +++ b/src/core/states/GenericContextContainer.h @@ -4,7 +4,7 @@ * We cannot parameterize the super class AbstractState because Qt does not * support template classes. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateActivateStoreFeedbackDialog.cpp b/src/core/states/StateActivateStoreFeedbackDialog.cpp index 78d6e867f..b58d2e8c1 100644 --- a/src/core/states/StateActivateStoreFeedbackDialog.cpp +++ b/src/core/states/StateActivateStoreFeedbackDialog.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "StateActivateStoreFeedbackDialog.h" diff --git a/src/core/states/StateActivateStoreFeedbackDialog.h b/src/core/states/StateActivateStoreFeedbackDialog.h index aefc11714..d82148625 100644 --- a/src/core/states/StateActivateStoreFeedbackDialog.h +++ b/src/core/states/StateActivateStoreFeedbackDialog.h @@ -2,7 +2,7 @@ * \brief Activates store the feedback dialog after a successful * authentication. * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateBuilder.h b/src/core/states/StateBuilder.h index fcc588123..6b8b4511d 100644 --- a/src/core/states/StateBuilder.h +++ b/src/core/states/StateBuilder.h @@ -1,7 +1,7 @@ /*! * \brief Builder for states. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateCertificateDescriptionCheck.cpp b/src/core/states/StateCertificateDescriptionCheck.cpp index 1f185e2e7..34c7972a5 100644 --- a/src/core/states/StateCertificateDescriptionCheck.cpp +++ b/src/core/states/StateCertificateDescriptionCheck.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateCertificateDescriptionCheck.h" diff --git a/src/core/states/StateCertificateDescriptionCheck.h b/src/core/states/StateCertificateDescriptionCheck.h index 9bb39b531..63f4611f6 100644 --- a/src/core/states/StateCertificateDescriptionCheck.h +++ b/src/core/states/StateCertificateDescriptionCheck.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateChangePin.cpp b/src/core/states/StateChangePin.cpp index eb30b9bd2..38793cf88 100644 --- a/src/core/states/StateChangePin.cpp +++ b/src/core/states/StateChangePin.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderManager.h" diff --git a/src/core/states/StateChangePin.h b/src/core/states/StateChangePin.h index 6defed412..ad630b17d 100644 --- a/src/core/states/StateChangePin.h +++ b/src/core/states/StateChangePin.h @@ -1,7 +1,7 @@ /*! * \brief Controller for the state changing the PIN. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateCheckCertificates.cpp b/src/core/states/StateCheckCertificates.cpp index 5b093b3ce..12280d1d1 100644 --- a/src/core/states/StateCheckCertificates.cpp +++ b/src/core/states/StateCheckCertificates.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateCheckCertificates.h" diff --git a/src/core/states/StateCheckCertificates.h b/src/core/states/StateCheckCertificates.h index 66a4da963..4a83866f6 100644 --- a/src/core/states/StateCheckCertificates.h +++ b/src/core/states/StateCheckCertificates.h @@ -3,7 +3,7 @@ * (i.e. those stored in the AuthContext) are in the CertificateDescription * extension of the eService certificate. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateCheckError.cpp b/src/core/states/StateCheckError.cpp index 94c8ab78d..1ac60bf74 100644 --- a/src/core/states/StateCheckError.cpp +++ b/src/core/states/StateCheckError.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateCheckError.h" diff --git a/src/core/states/StateCheckError.h b/src/core/states/StateCheckError.h index f91777d60..372ebad4b 100644 --- a/src/core/states/StateCheckError.h +++ b/src/core/states/StateCheckError.h @@ -2,7 +2,7 @@ * \brief Helper state to decide whether an error has been occurred that should * be reported to the user. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateCheckRefreshAddress.cpp b/src/core/states/StateCheckRefreshAddress.cpp index df5eb694a..2ce90404a 100644 --- a/src/core/states/StateCheckRefreshAddress.cpp +++ b/src/core/states/StateCheckRefreshAddress.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateCheckRefreshAddress.h" @@ -414,6 +414,6 @@ void StateCheckRefreshAddress::onNetworkErrorFetchingServerCertificate(QNetworkR void StateCheckRefreshAddress::onEntry(QEvent* pEvent) { //: INFO ALL_PLATFORMS Status message after the communication between card and server is completed, the result is being forwarded to the provider. - getContext()->setProgress(80, tr("Sending data to service provider")); + getContext()->setProgress(80, tr("Sending data to provider")); AbstractState::onEntry(pEvent); } diff --git a/src/core/states/StateCheckRefreshAddress.h b/src/core/states/StateCheckRefreshAddress.h index 755853762..ad3e9f7e0 100644 --- a/src/core/states/StateCheckRefreshAddress.h +++ b/src/core/states/StateCheckRefreshAddress.h @@ -2,7 +2,7 @@ * \brief Calls the RefreshAddress of TcToken and checks the certificates. * After that it will set RedirectAddress in WorkflowContext. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateCleanUpReaderManager.cpp b/src/core/states/StateCleanUpReaderManager.cpp index f7a6ad9ab..999c4ce83 100644 --- a/src/core/states/StateCleanUpReaderManager.cpp +++ b/src/core/states/StateCleanUpReaderManager.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "StateCleanUpReaderManager.h" @@ -27,13 +27,10 @@ void StateCleanUpReaderManager::run() const auto readerManager = Env::getSingleton(); readerManager->stopScanAll(); - // On a desktop AusweisApp2, restart scanning when a change pin workflow is completed. -#if defined(Q_OS_WIN) || (defined(Q_OS_BSD4) && !defined(Q_OS_IOS)) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) - const bool changePinOnDesktop = context.objectCast(); -#else - const bool changePinOnDesktop = false; -#endif - if (changePinOnDesktop || Env::getSingleton()->isUsedAsSDK()) + const auto& generalSettings = Env::getSingleton()->getGeneralSettings(); + const bool isWidgetUi = generalSettings.getSelectedUi() == QLatin1String("widgets"); + const bool changePinOnWidgets = isWidgetUi && context.objectCast(); + if (changePinOnWidgets || Env::getSingleton()->isUsedAsSDK()) { readerManager->startScanAll(); } diff --git a/src/core/states/StateCleanUpReaderManager.h b/src/core/states/StateCleanUpReaderManager.h index 10b773acf..01ce96d71 100644 --- a/src/core/states/StateCleanUpReaderManager.h +++ b/src/core/states/StateCleanUpReaderManager.h @@ -2,7 +2,7 @@ * \brief Performs clean up of the ReaderManager, * e.g. disconnects all readers, clears the card connection, ... * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateClearPacePasswords.cpp b/src/core/states/StateClearPacePasswords.cpp index c22437b09..498e8f512 100644 --- a/src/core/states/StateClearPacePasswords.cpp +++ b/src/core/states/StateClearPacePasswords.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateClearPacePasswords.h" diff --git a/src/core/states/StateClearPacePasswords.h b/src/core/states/StateClearPacePasswords.h index 01b98ab78..bd43176f9 100644 --- a/src/core/states/StateClearPacePasswords.h +++ b/src/core/states/StateClearPacePasswords.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateConnectCard.cpp b/src/core/states/StateConnectCard.cpp index ecfa53a62..ab0105364 100644 --- a/src/core/states/StateConnectCard.cpp +++ b/src/core/states/StateConnectCard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnection.h" @@ -67,7 +67,7 @@ void StateConnectCard::onCommandDone(QSharedPointer } else if (readerInfo.isPinDeactivated() && !getContext()->isCanAllowedMode()) { - getContext()->getCardConnection()->setProgressMessage(tr("The online identification function is disabled.")); + getContext()->getCardConnection()->setProgressMessage(tr("The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function.")); } } diff --git a/src/core/states/StateConnectCard.h b/src/core/states/StateConnectCard.h index 740730b7f..2856d30d8 100644 --- a/src/core/states/StateConnectCard.h +++ b/src/core/states/StateConnectCard.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateDestroyPace.cpp b/src/core/states/StateDestroyPace.cpp index b5eb38a63..efbd86ce7 100644 --- a/src/core/states/StateDestroyPace.cpp +++ b/src/core/states/StateDestroyPace.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ @@ -24,7 +24,7 @@ void StateDestroyPace::run() } -void StateDestroyPace::onDestroyPaceDone(QSharedPointer ) +void StateDestroyPace::onDestroyPaceDone(QSharedPointer) { Q_EMIT fireContinue(); } diff --git a/src/core/states/StateDestroyPace.h b/src/core/states/StateDestroyPace.h index 1bd97bde8..074b6e0de 100644 --- a/src/core/states/StateDestroyPace.h +++ b/src/core/states/StateDestroyPace.h @@ -1,7 +1,7 @@ /*! * \brief Controller for the step that tries to destroy an existing PACE connection. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateDidAuthenticateEac1.cpp b/src/core/states/StateDidAuthenticateEac1.cpp index 4d92b2569..26f8595b0 100644 --- a/src/core/states/StateDidAuthenticateEac1.cpp +++ b/src/core/states/StateDidAuthenticateEac1.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/CVCertificateChainBuilder.h" @@ -28,7 +28,6 @@ void StateDidAuthenticateEac1::run() Q_ASSERT(!getContext()->getDidAuthenticateEac1().isNull()); Q_ASSERT(getContext()->getPaceOutputData() != nullptr); Q_ASSERT(getContext()->getCardConnection()); - Q_ASSERT(!getContext()->encodeEffectiveChat().isEmpty()); auto cardConnection = getContext()->getCardConnection(); Q_ASSERT(cardConnection); @@ -69,6 +68,6 @@ void StateDidAuthenticateEac1::onCardCommandDone(QSharedPointer void StateDidAuthenticateEac1::onEntry(QEvent* pEvent) { //: INFO ALL_PLATFORMS Status message after the PIN was entered, Terminal Authentication. - getContext()->setProgress(20, tr("Service provider is being verified")); + getContext()->setProgress(20, tr("Provider is being verified")); AbstractState::onEntry(pEvent); } diff --git a/src/core/states/StateDidAuthenticateEac1.h b/src/core/states/StateDidAuthenticateEac1.h index 024942c78..2ebd6cc9d 100644 --- a/src/core/states/StateDidAuthenticateEac1.h +++ b/src/core/states/StateDidAuthenticateEac1.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateDidAuthenticateEac2.cpp b/src/core/states/StateDidAuthenticateEac2.cpp index 5f1000f6c..49e30cb6f 100644 --- a/src/core/states/StateDidAuthenticateEac2.cpp +++ b/src/core/states/StateDidAuthenticateEac2.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/CVCertificate.h" diff --git a/src/core/states/StateDidAuthenticateEac2.h b/src/core/states/StateDidAuthenticateEac2.h index 61ed0a67e..da564a3ae 100644 --- a/src/core/states/StateDidAuthenticateEac2.h +++ b/src/core/states/StateDidAuthenticateEac2.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateDidList.cpp b/src/core/states/StateDidList.cpp index 0cecb9c9f..16b8305d6 100644 --- a/src/core/states/StateDidList.cpp +++ b/src/core/states/StateDidList.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/invoke/DidListResponse.h" diff --git a/src/core/states/StateDidList.h b/src/core/states/StateDidList.h index 29099cb89..eb9d4261e 100644 --- a/src/core/states/StateDidList.h +++ b/src/core/states/StateDidList.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateEACAdditionalInputType.cpp b/src/core/states/StateEACAdditionalInputType.cpp index 6a8f756d8..30df40c7b 100644 --- a/src/core/states/StateEACAdditionalInputType.cpp +++ b/src/core/states/StateEACAdditionalInputType.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateEACAdditionalInputType.h" diff --git a/src/core/states/StateEACAdditionalInputType.h b/src/core/states/StateEACAdditionalInputType.h index bc5478a33..ce3d4ec3e 100644 --- a/src/core/states/StateEACAdditionalInputType.h +++ b/src/core/states/StateEACAdditionalInputType.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateEditAccessRights.cpp b/src/core/states/StateEditAccessRights.cpp index 52320200f..3798ee75e 100644 --- a/src/core/states/StateEditAccessRights.cpp +++ b/src/core/states/StateEditAccessRights.cpp @@ -1,11 +1,9 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "StateEditAccessRights.h" -Q_DECLARE_LOGGING_CATEGORY(statemachine) - using namespace governikus; StateEditAccessRights::StateEditAccessRights(const QSharedPointer& pContext) @@ -17,34 +15,5 @@ StateEditAccessRights::StateEditAccessRights(const QSharedPointergetEffectiveAccessRights(); - qCDebug(statemachine) << effectiveRights; - - const auto& requiredRights = getContext()->getRequiredAccessRights(); - printRights(QStringLiteral("Required rights"), requiredRights); - - const auto& optionalRights = getContext()->getOptionalAccessRights(); - printRights(QStringLiteral("Optional selected rights"), effectiveRights & optionalRights); - - printRights(QStringLiteral("Optional not selected rights"), optionalRights - effectiveRights); - Q_EMIT fireContinue(); } - - -void StateEditAccessRights::printRights(const QString& pTitle, const QSet& pRights) const -{ - QStringList accessRightsToDisplay; - if (pRights.isEmpty()) - { - accessRightsToDisplay += QStringLiteral("None"); - } - else - { - for (const auto& accessRight : pRights) - { - accessRightsToDisplay += AccessRoleAndRightsUtil::toDisplayText(accessRight); - } - } - qCDebug(statemachine) << pTitle << ":" << accessRightsToDisplay.join(QLatin1String(", ")); -} diff --git a/src/core/states/StateEditAccessRights.h b/src/core/states/StateEditAccessRights.h index 4869d18f1..a3350bc4e 100644 --- a/src/core/states/StateEditAccessRights.h +++ b/src/core/states/StateEditAccessRights.h @@ -2,7 +2,7 @@ * * \brief This state waits for editing of the effective CHAT * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -23,8 +23,6 @@ class StateEditAccessRights explicit StateEditAccessRights(const QSharedPointer& pContext); virtual void run() override; - - void printRights(const QString& pTitle, const QSet& pRights) const; }; } // namespace governikus diff --git a/src/core/states/StateEnterNewPacePin.cpp b/src/core/states/StateEnterNewPacePin.cpp index ec2ece2b7..b28529f89 100644 --- a/src/core/states/StateEnterNewPacePin.cpp +++ b/src/core/states/StateEnterNewPacePin.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateEnterNewPacePin.h" diff --git a/src/core/states/StateEnterNewPacePin.h b/src/core/states/StateEnterNewPacePin.h index 383906857..f4bbab1ea 100644 --- a/src/core/states/StateEnterNewPacePin.h +++ b/src/core/states/StateEnterNewPacePin.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateEnterPacePassword.cpp b/src/core/states/StateEnterPacePassword.cpp index 1629a1f8f..aa2a91396 100644 --- a/src/core/states/StateEnterPacePassword.cpp +++ b/src/core/states/StateEnterPacePassword.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateEnterPacePassword.h" @@ -17,5 +17,12 @@ StateEnterPacePassword::StateEnterPacePassword(const QSharedPointergetStatus().isError()) + { + Q_EMIT fireAbort(); + } + else + { + Q_EMIT fireContinue(); + } } diff --git a/src/core/states/StateEnterPacePassword.h b/src/core/states/StateEnterPacePassword.h index 397092a2f..893dcdcbe 100644 --- a/src/core/states/StateEnterPacePassword.h +++ b/src/core/states/StateEnterPacePassword.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -8,6 +8,8 @@ #include "context/WorkflowContext.h" #include "GenericContextContainer.h" +class test_StateEnterPacePassword; + namespace governikus { @@ -17,6 +19,7 @@ class StateEnterPacePassword { Q_OBJECT friend class StateBuilder; + friend class ::test_StateEnterPacePassword; explicit StateEnterPacePassword(const QSharedPointer& pContext); virtual void run() override; diff --git a/src/core/states/StateEstablishPaceChannel.cpp b/src/core/states/StateEstablishPaceChannel.cpp index 9e6dddb53..9a844e3f4 100644 --- a/src/core/states/StateEstablishPaceChannel.cpp +++ b/src/core/states/StateEstablishPaceChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ @@ -22,6 +22,12 @@ StateEstablishPaceChannel::StateEstablishPaceChannel(const QSharedPointergetStatus().isError()) + { + Q_EMIT fireAbort(); + return; + } + auto cardConnection = getContext()->getCardConnection(); if (!cardConnection) { @@ -45,9 +51,9 @@ void StateEstablishPaceChannel::run() // in other scenarios, e.g. for changing the PIN, the data // is not needed Q_ASSERT(authContext->getDidAuthenticateEac1()); - Q_ASSERT(!authContext->encodeEffectiveChat().isEmpty()); certificateDescription = authContext->getDidAuthenticateEac1()->getCertificateDescriptionAsBinary(); effectiveChat = authContext->encodeEffectiveChat(); + Q_ASSERT(!effectiveChat.isEmpty()); } } @@ -77,7 +83,7 @@ void StateEstablishPaceChannel::run() qCCritical(statemachine) << "We hit an invalid state! PACE password is empty for basic reader."; Q_ASSERT(false); - qCDebug(statemachine) << "Reseting all PACE passwords."; + qCDebug(statemachine) << "Resetting all PACE passwords."; getContext()->resetPacePasswords(); abort(); @@ -147,12 +153,12 @@ void StateEstablishPaceChannel::onEstablishConnectionDone(QSharedPointersetExpectedRetryCounter(3); } else if (mPasswordId == PacePasswordId::PACE_PUK && returnCode == CardReturnCode::OK) { - qCDebug(statemachine) << "PACE PUK succeeded. Resetting PACE passwords and setting expected retry counter to:" << -1; + qCDebug(statemachine) << "PACE_PUK succeeded. Resetting PACE passwords and setting expected retry counter to:" << -1; getContext()->resetPacePasswords(); getContext()->setExpectedRetryCounter(-1); } @@ -170,7 +176,7 @@ void StateEstablishPaceChannel::onEstablishConnectionDone(QSharedPointersetLastPaceResult(CardReturnCode::OK_PUK); - Q_EMIT firePacePukEstablished(); + Q_EMIT firePaceChannelInoperative(); return; } @@ -202,7 +208,7 @@ void StateEstablishPaceChannel::onEstablishConnectionDone(QSharedPointersetLastPaceResult(paceResult); - Q_EMIT fireAbort(); + Q_EMIT firePaceChannelInoperative(); return; } diff --git a/src/core/states/StateEstablishPaceChannel.h b/src/core/states/StateEstablishPaceChannel.h index d0ce422f8..65c2ed7e5 100644 --- a/src/core/states/StateEstablishPaceChannel.h +++ b/src/core/states/StateEstablishPaceChannel.h @@ -2,7 +2,7 @@ * \brief Controller for the step that tries to establish a PACE * connection using the card's Pin. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -40,7 +40,7 @@ class StateEstablishPaceChannel Q_SIGNALS: void firePaceChannelEstablished(); - void firePacePukEstablished(); + void firePaceChannelInoperative(); void fireAbortAndUnfortunateCardPosition(); }; diff --git a/src/core/states/StateExtractCvcsFromEac1InputType.cpp b/src/core/states/StateExtractCvcsFromEac1InputType.cpp index a046b19b8..93ae6c9b1 100644 --- a/src/core/states/StateExtractCvcsFromEac1InputType.cpp +++ b/src/core/states/StateExtractCvcsFromEac1InputType.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateExtractCvcsFromEac1InputType.h" diff --git a/src/core/states/StateExtractCvcsFromEac1InputType.h b/src/core/states/StateExtractCvcsFromEac1InputType.h index dd28dfeed..ff6ef8851 100644 --- a/src/core/states/StateExtractCvcsFromEac1InputType.h +++ b/src/core/states/StateExtractCvcsFromEac1InputType.h @@ -1,7 +1,7 @@ /*! * \brief State to process InputType of EAC1. Extract certificates and set it to context. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateGenericSendReceive.cpp b/src/core/states/StateGenericSendReceive.cpp index 08813d6a1..73bd465d9 100644 --- a/src/core/states/StateGenericSendReceive.cpp +++ b/src/core/states/StateGenericSendReceive.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateGenericSendReceive.h" @@ -294,6 +294,14 @@ void StateGenericSendReceive::onReplyFinished() return; } + if (statusCode >= 400) + { + qCCritical(network) << GlobalStatus(GlobalStatus::Code::Workflow_Unexpected_Message_From_EidServer); + updateStatus(GlobalStatus::Code::Workflow_Unexpected_Message_From_EidServer); + Q_EMIT fireAbort(); + return; + } + QByteArray message = reply->readAll(); qCDebug(network).noquote() << "Received raw data:\n" << message; PaosHandler paosHandler(message); diff --git a/src/core/states/StateGenericSendReceive.h b/src/core/states/StateGenericSendReceive.h index c1a0defa7..2771c6c2b 100644 --- a/src/core/states/StateGenericSendReceive.h +++ b/src/core/states/StateGenericSendReceive.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateGetSelfAuthenticationData.cpp b/src/core/states/StateGetSelfAuthenticationData.cpp index 418b4b067..ab2fbd31b 100644 --- a/src/core/states/StateGetSelfAuthenticationData.cpp +++ b/src/core/states/StateGetSelfAuthenticationData.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateGetSelfAuthenticationData.h" diff --git a/src/core/states/StateGetSelfAuthenticationData.h b/src/core/states/StateGetSelfAuthenticationData.h index 947e0cded..e6de3a5ab 100644 --- a/src/core/states/StateGetSelfAuthenticationData.h +++ b/src/core/states/StateGetSelfAuthenticationData.h @@ -1,7 +1,7 @@ /*! * \brief get the xml data from the given url * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateGetTcToken.cpp b/src/core/states/StateGetTcToken.cpp index c7d3cf8da..7eb605982 100644 --- a/src/core/states/StateGetTcToken.cpp +++ b/src/core/states/StateGetTcToken.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateGetTcToken.h" @@ -60,7 +60,7 @@ bool StateGetTcToken::isValidRedirectUrl(const QUrl& pUrl) { if (pUrl.isEmpty()) { - qCritical() << "Error while connecting to the service provider. The server returns an invalid or empty redirect URL."; + qCritical() << "Error while connecting to the provider. The server returns an invalid or empty redirect URL."; updateStatus(GlobalStatus::Code::Workflow_TrustedChannel_Server_Format_Error); return false; } @@ -68,7 +68,7 @@ bool StateGetTcToken::isValidRedirectUrl(const QUrl& pUrl) { // according to TR-03124-1 in case of a non-HTTPS URL a createTrustedChannelEstablishmentError error must be sent // in contrast a HTTP error 404 must be sent, if the TCToken could not be determined - const auto httpsError1 = QStringLiteral("Error while connecting to the service provider. A secure connection could not be established."); + const auto httpsError1 = QStringLiteral("Error while connecting to the provider. A secure connection could not be established."); const auto httpsError2 = QStringLiteral(" The used URL is not of type HTTPS: %1").arg(pUrl.toString()); if (Env::getSingleton()->getGeneralSettings().isDeveloperMode()) { @@ -118,7 +118,7 @@ void StateGetTcToken::onSslHandshakeDone() if (!TlsChecker::hasValidCertificateKeyLength(cfg.peerCertificate())) { mReply->abort(); - qCritical() << "Error while connecting to the service provider. The server's SSL certificate uses an unsupported key algorithm or length."; + qCritical() << "Error while connecting to the provider. The server's SSL certificate uses an unsupported key algorithm or length."; updateStatus(GlobalStatus::Code::Workflow_TrustedChannel_Establishment_Error); Q_EMIT fireAbort(); return; @@ -127,7 +127,7 @@ void StateGetTcToken::onSslHandshakeDone() if (!TlsChecker::hasValidEphemeralKeyLength(cfg.ephemeralServerKey())) { mReply->abort(); - qCritical() << "Error while connecting to the service provider. The SSL connection uses an unsupported key algorithm or length."; + qCritical() << "Error while connecting to the provider. The SSL connection uses an unsupported key algorithm or length."; updateStatus(GlobalStatus::Code::Workflow_TrustedChannel_Establishment_Error); Q_EMIT fireAbort(); return; @@ -166,7 +166,7 @@ void StateGetTcToken::onNetworkReply() if (statusCode != HTTP_STATUS_SEE_OTHER && statusCode != HTTP_STATUS_FOUND && statusCode != HTTP_STATUS_TEMPORARY_REDIRECT) { - qCritical() << "Error while connecting to the service provider. The server returns an unexpected status code:" << statusCode; + qCritical() << "Error while connecting to the provider. The server returns an unexpected status code:" << statusCode; updateStatus(GlobalStatus::Code::Workflow_TrustedChannel_Server_Format_Error); Q_EMIT fireAbort(); return; diff --git a/src/core/states/StateGetTcToken.h b/src/core/states/StateGetTcToken.h index 6f6b2e4e3..0ad8f7fb6 100644 --- a/src/core/states/StateGetTcToken.h +++ b/src/core/states/StateGetTcToken.h @@ -1,7 +1,7 @@ /*! * \brief State machine state: Get TCToken. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateInitializeFramework.cpp b/src/core/states/StateInitializeFramework.cpp index 0becde24d..b28affe11 100644 --- a/src/core/states/StateInitializeFramework.cpp +++ b/src/core/states/StateInitializeFramework.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/invoke/InitializeFrameworkResponse.h" diff --git a/src/core/states/StateInitializeFramework.h b/src/core/states/StateInitializeFramework.h index 956d5cda4..db70c3a04 100644 --- a/src/core/states/StateInitializeFramework.h +++ b/src/core/states/StateInitializeFramework.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateLoadTcTokenUrl.cpp b/src/core/states/StateLoadTcTokenUrl.cpp index 6f548ed81..8279ae94f 100644 --- a/src/core/states/StateLoadTcTokenUrl.cpp +++ b/src/core/states/StateLoadTcTokenUrl.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/core/states/StateLoadTcTokenUrl.h b/src/core/states/StateLoadTcTokenUrl.h index 58edff5dc..d59ac0143 100644 --- a/src/core/states/StateLoadTcTokenUrl.h +++ b/src/core/states/StateLoadTcTokenUrl.h @@ -1,7 +1,7 @@ /*! * \brief Loads the tcTokenUrl for triggering the self authentication from secure storage * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateMaintainCardConnection.cpp b/src/core/states/StateMaintainCardConnection.cpp index 155104dc5..18cfd23bc 100644 --- a/src/core/states/StateMaintainCardConnection.cpp +++ b/src/core/states/StateMaintainCardConnection.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateMaintainCardConnection.h" @@ -62,7 +62,7 @@ void StateMaintainCardConnection::run() { Q_ASSERT(CardReturnCodeUtil::equalsWrongPacePassword(lastPaceResult)); - qCDebug(statemachine) << "Reseting all PACE passwords."; + qCDebug(statemachine) << "Resetting all PACE passwords."; context->resetPacePasswords(); if (context->getCardConnection()) diff --git a/src/core/states/StateMaintainCardConnection.h b/src/core/states/StateMaintainCardConnection.h index c65e99b8d..e1f1ce174 100644 --- a/src/core/states/StateMaintainCardConnection.h +++ b/src/core/states/StateMaintainCardConnection.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateParseTcTokenUrl.cpp b/src/core/states/StateParseTcTokenUrl.cpp index 825d5162e..1a37bac03 100644 --- a/src/core/states/StateParseTcTokenUrl.cpp +++ b/src/core/states/StateParseTcTokenUrl.cpp @@ -1,7 +1,7 @@ /*! * \brief Parse tcTokenURL from GET query. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateParseTcTokenUrl.h" diff --git a/src/core/states/StateParseTcTokenUrl.h b/src/core/states/StateParseTcTokenUrl.h index bc610776c..568e88786 100644 --- a/src/core/states/StateParseTcTokenUrl.h +++ b/src/core/states/StateParseTcTokenUrl.h @@ -1,7 +1,7 @@ /*! * \brief Implements the parsing of TcTokenUrl in header of browser request. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StatePreVerification.cpp b/src/core/states/StatePreVerification.cpp index 871a5bc38..a6640cd27 100644 --- a/src/core/states/StatePreVerification.cpp +++ b/src/core/states/StatePreVerification.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StatePreVerification.h" diff --git a/src/core/states/StatePreVerification.h b/src/core/states/StatePreVerification.h index 547888959..b0782602d 100644 --- a/src/core/states/StatePreVerification.h +++ b/src/core/states/StatePreVerification.h @@ -1,7 +1,7 @@ /* * \brief Performs the pre-verification of cvcs. If the pre-verification succeeds the cvc chain is set to the authentication model. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StatePrepareChangePin.cpp b/src/core/states/StatePrepareChangePin.cpp index 81e84015c..314b65098 100644 --- a/src/core/states/StatePrepareChangePin.cpp +++ b/src/core/states/StatePrepareChangePin.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StatePrepareChangePin.h" diff --git a/src/core/states/StatePrepareChangePin.h b/src/core/states/StatePrepareChangePin.h index 4ffe45af7..d1b940859 100644 --- a/src/core/states/StatePrepareChangePin.h +++ b/src/core/states/StatePrepareChangePin.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StatePreparePace.cpp b/src/core/states/StatePreparePace.cpp index f2fe0307e..584986fda 100644 --- a/src/core/states/StatePreparePace.cpp +++ b/src/core/states/StatePreparePace.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StatePreparePace.h" @@ -33,7 +33,7 @@ void StatePreparePace::run() qCDebug(statemachine) << "CAN allowed required"; if (!requestPaceCanIfStillRequired()) { - Q_ASSERT(false && "This state must not be invoked any more if PACE CAN was successful in CAN allowed mode."); + Q_ASSERT(false && "This state must not be invoked any more if PACE_CAN was successful in CAN allowed mode."); Q_EMIT fireContinue(); } return; @@ -74,7 +74,7 @@ void StatePreparePace::run() getContext()->setEstablishPaceChannelType(PacePasswordId::PACE_PIN); const bool pacePinDone = cardConnection->getPacePinSuccessful(); - qCDebug(statemachine) << "PACE PIN done:" << pacePinDone; + qCDebug(statemachine) << "PACE_PIN done:" << pacePinDone; if (!pacePinDone) { if (getContext()->getPin().isEmpty()) @@ -102,7 +102,7 @@ bool StatePreparePace::requestPaceCanIfStillRequired() const QSharedPointer& cardConnection = getContext()->getCardConnection(); const bool paceCanDone = cardConnection->getPaceCanSuccessful(); - qCDebug(statemachine) << "PACE CAN done:" << paceCanDone; + qCDebug(statemachine) << "PACE_CAN done:" << paceCanDone; if (!paceCanDone) { if (getContext()->getCan().isEmpty()) diff --git a/src/core/states/StatePreparePace.h b/src/core/states/StatePreparePace.h index ec2b3bf8e..eda7567c8 100644 --- a/src/core/states/StatePreparePace.h +++ b/src/core/states/StatePreparePace.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateProcessCertificatesFromEac2.cpp b/src/core/states/StateProcessCertificatesFromEac2.cpp index 513f6a326..2020aecfe 100644 --- a/src/core/states/StateProcessCertificatesFromEac2.cpp +++ b/src/core/states/StateProcessCertificatesFromEac2.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateProcessCertificatesFromEac2.h" diff --git a/src/core/states/StateProcessCertificatesFromEac2.h b/src/core/states/StateProcessCertificatesFromEac2.h index 443a42df5..3ef883c05 100644 --- a/src/core/states/StateProcessCertificatesFromEac2.h +++ b/src/core/states/StateProcessCertificatesFromEac2.h @@ -1,7 +1,7 @@ /*! * \brief State to process certificates from EAC2. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateProcessing.cpp b/src/core/states/StateProcessing.cpp index 93c2b82e0..9a0266f24 100644 --- a/src/core/states/StateProcessing.cpp +++ b/src/core/states/StateProcessing.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateProcessing.h" diff --git a/src/core/states/StateProcessing.h b/src/core/states/StateProcessing.h index cdbcb55c7..a52c98f46 100644 --- a/src/core/states/StateProcessing.h +++ b/src/core/states/StateProcessing.h @@ -1,7 +1,7 @@ /*! * \brief Sends a HTTP-Processing to the browser. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateRedirectBrowser.cpp b/src/core/states/StateRedirectBrowser.cpp index ba98b7df4..b46f90bff 100644 --- a/src/core/states/StateRedirectBrowser.cpp +++ b/src/core/states/StateRedirectBrowser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateRedirectBrowser.h" diff --git a/src/core/states/StateRedirectBrowser.h b/src/core/states/StateRedirectBrowser.h index 07a291cac..26336baa3 100644 --- a/src/core/states/StateRedirectBrowser.h +++ b/src/core/states/StateRedirectBrowser.h @@ -1,7 +1,7 @@ /*! * \brief Send a redirect to the browser. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateSelectPasswordId.cpp b/src/core/states/StateSelectPasswordId.cpp index 4a97ab1fb..cda5e94c4 100644 --- a/src/core/states/StateSelectPasswordId.cpp +++ b/src/core/states/StateSelectPasswordId.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateSelectPasswordId.h" diff --git a/src/core/states/StateSelectPasswordId.h b/src/core/states/StateSelectPasswordId.h index 397158162..26273acb3 100644 --- a/src/core/states/StateSelectPasswordId.h +++ b/src/core/states/StateSelectPasswordId.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateSelectReader.cpp b/src/core/states/StateSelectReader.cpp index a80bcd4fd..2c0047edc 100644 --- a/src/core/states/StateSelectReader.cpp +++ b/src/core/states/StateSelectReader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "StateSelectReader.h" diff --git a/src/core/states/StateSelectReader.h b/src/core/states/StateSelectReader.h index 7d336bc43..f1ee6733f 100644 --- a/src/core/states/StateSelectReader.h +++ b/src/core/states/StateSelectReader.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateSendWhitelistSurvey.cpp b/src/core/states/StateSendWhitelistSurvey.cpp index ac1db7616..7561b4253 100644 --- a/src/core/states/StateSendWhitelistSurvey.cpp +++ b/src/core/states/StateSendWhitelistSurvey.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateSendWhitelistSurvey.h" diff --git a/src/core/states/StateSendWhitelistSurvey.h b/src/core/states/StateSendWhitelistSurvey.h index b2824d204..a57797bfe 100644 --- a/src/core/states/StateSendWhitelistSurvey.h +++ b/src/core/states/StateSendWhitelistSurvey.h @@ -2,7 +2,7 @@ * \brief Allows the user to send a survey after a successful authentication * on Android. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateShowSelfInfo.cpp b/src/core/states/StateShowSelfInfo.cpp index b292c7124..75af3665d 100644 --- a/src/core/states/StateShowSelfInfo.cpp +++ b/src/core/states/StateShowSelfInfo.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateShowSelfInfo.h" diff --git a/src/core/states/StateShowSelfInfo.h b/src/core/states/StateShowSelfInfo.h index 261a861d3..0e89d1d84 100644 --- a/src/core/states/StateShowSelfInfo.h +++ b/src/core/states/StateShowSelfInfo.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateStartPaos.cpp b/src/core/states/StateStartPaos.cpp index 114da07d2..5ca4c4f6e 100644 --- a/src/core/states/StateStartPaos.cpp +++ b/src/core/states/StateStartPaos.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnection.h" diff --git a/src/core/states/StateStartPaos.h b/src/core/states/StateStartPaos.h index 837db5d76..cff68ee84 100644 --- a/src/core/states/StateStartPaos.h +++ b/src/core/states/StateStartPaos.h @@ -1,7 +1,7 @@ /*! * \brief State machine state: Start PAOS. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateStartPaosResponse.cpp b/src/core/states/StateStartPaosResponse.cpp index c848af8c0..01e3a49f0 100644 --- a/src/core/states/StateStartPaosResponse.cpp +++ b/src/core/states/StateStartPaosResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateStartPaosResponse.h" diff --git a/src/core/states/StateStartPaosResponse.h b/src/core/states/StateStartPaosResponse.h index 0a8020228..36e9e0965 100644 --- a/src/core/states/StateStartPaosResponse.h +++ b/src/core/states/StateStartPaosResponse.h @@ -1,7 +1,7 @@ /*! * \brief State to process StartPaosResponse from Server. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateTransmit.cpp b/src/core/states/StateTransmit.cpp index 283de8958..63bbebad0 100644 --- a/src/core/states/StateTransmit.cpp +++ b/src/core/states/StateTransmit.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnection.h" diff --git a/src/core/states/StateTransmit.h b/src/core/states/StateTransmit.h index a61d3f4f3..15be4bbf5 100644 --- a/src/core/states/StateTransmit.h +++ b/src/core/states/StateTransmit.h @@ -1,7 +1,7 @@ /*! * \brief Process received transmits. Send it to the card and create a response. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateUnfortunateCardPosition.cpp b/src/core/states/StateUnfortunateCardPosition.cpp index d9558593f..18804a1b6 100644 --- a/src/core/states/StateUnfortunateCardPosition.cpp +++ b/src/core/states/StateUnfortunateCardPosition.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "AbstractState.h" diff --git a/src/core/states/StateUnfortunateCardPosition.h b/src/core/states/StateUnfortunateCardPosition.h index 62770a92e..4fe178dae 100644 --- a/src/core/states/StateUnfortunateCardPosition.h +++ b/src/core/states/StateUnfortunateCardPosition.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateUpdateRetryCounter.cpp b/src/core/states/StateUpdateRetryCounter.cpp index a73d64bcf..50f710a92 100644 --- a/src/core/states/StateUpdateRetryCounter.cpp +++ b/src/core/states/StateUpdateRetryCounter.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateUpdateRetryCounter.h" diff --git a/src/core/states/StateUpdateRetryCounter.h b/src/core/states/StateUpdateRetryCounter.h index 6ed975571..c441b8ad4 100644 --- a/src/core/states/StateUpdateRetryCounter.h +++ b/src/core/states/StateUpdateRetryCounter.h @@ -2,7 +2,7 @@ * \brief Controller for the step that updates the retry * counter of a card. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateVerifyRetryCounter.cpp b/src/core/states/StateVerifyRetryCounter.cpp index d6bef0bae..b11fc8d01 100644 --- a/src/core/states/StateVerifyRetryCounter.cpp +++ b/src/core/states/StateVerifyRetryCounter.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateVerifyRetryCounter.h" diff --git a/src/core/states/StateVerifyRetryCounter.h b/src/core/states/StateVerifyRetryCounter.h index fc83eba86..d795f82a4 100644 --- a/src/core/states/StateVerifyRetryCounter.h +++ b/src/core/states/StateVerifyRetryCounter.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/StateWriteHistory.cpp b/src/core/states/StateWriteHistory.cpp index 2f93db21a..4c69b0b5f 100644 --- a/src/core/states/StateWriteHistory.cpp +++ b/src/core/states/StateWriteHistory.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StateWriteHistory.h" @@ -39,7 +39,7 @@ void StateWriteHistory::run() if (auto certDesc = getContext()->getDidAuthenticateEac1()->getCertificateDescription()) { auto subjectName = certDesc->getSubjectName(); - auto termOfUsage = certDesc->getTermsOfUsage(); + auto termsOfUsage = certDesc->getTermsOfUsage(); auto subjectUrl = certDesc->getSubjectUrl(); CVCertificateBody body = getContext()->getDidAuthenticateEac1()->getCvCertificates().at(0)->getBody(); @@ -49,7 +49,7 @@ void StateWriteHistory::run() QString validity = tr("Validity:\n%1 - %2").arg(effectiveDate, expirationDate); QStringList requestedData; - QList rights = getContext()->getEffectiveAccessRights().toList(); + QList rights = getContext()->getEffectiveAccessRights().values(); std::sort(rights.begin(), rights.end()); for (const auto& entry : qAsConst(rights)) { @@ -60,9 +60,10 @@ void StateWriteHistory::run() } } - if (!subjectName.isNull() && !termOfUsage.isNull()) + if (!subjectName.isNull()) { - HistoryInfo info(subjectName, subjectUrl, certDesc->getPurpose(), QDateTime::currentDateTime(), termOfUsage + QStringLiteral("\n\n") + validity, requestedData); + termsOfUsage = termsOfUsage.isEmpty() ? validity : termsOfUsage + QStringLiteral("\n\n") + validity; + HistoryInfo info(subjectName, subjectUrl, certDesc->getPurpose(), QDateTime::currentDateTime(), termsOfUsage, requestedData); Env::getSingleton()->getHistorySettings().addHistoryInfo(info); Env::getSingleton()->getHistorySettings().save(); } @@ -75,7 +76,7 @@ void StateWriteHistory::run() void StateWriteHistory::onEntry(QEvent* pEvent) { //: INFO ALL_PLATFORMS Status message after the authentication was completed, the results are prepared for the user, mainly relevant for the self authentication since it takes some more time. - const auto text = getContext()->getStatus().isNoError() ? tr("Preparing results") : QString(); // The empty string is set to not confuse users when they get redirected to the service provider + const auto text = getContext()->getStatus().isNoError() ? tr("Preparing results") : QString(); // The empty string is set to not confuse users when they get redirected to the provider getContext()->setProgress(100, text); AbstractState::onEntry(pEvent); } diff --git a/src/core/states/StateWriteHistory.h b/src/core/states/StateWriteHistory.h index 0cf8317b9..af4345386 100644 --- a/src/core/states/StateWriteHistory.h +++ b/src/core/states/StateWriteHistory.h @@ -2,7 +2,7 @@ * * \brief Writes the history entry . * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateChangePinRemote.cpp b/src/core/states/remote_service/StateChangePinRemote.cpp index 0d153229f..9fcf61627 100644 --- a/src/core/states/remote_service/StateChangePinRemote.cpp +++ b/src/core/states/remote_service/StateChangePinRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "StateChangePinRemote.h" diff --git a/src/core/states/remote_service/StateChangePinRemote.h b/src/core/states/remote_service/StateChangePinRemote.h index c483faf23..36ee4328b 100644 --- a/src/core/states/remote_service/StateChangePinRemote.h +++ b/src/core/states/remote_service/StateChangePinRemote.h @@ -1,7 +1,7 @@ /*! * \brief This state executes the remote message IfdModifyPin. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateChangePinResponse.cpp b/src/core/states/remote_service/StateChangePinResponse.cpp index 65a7a3e27..3680625b3 100644 --- a/src/core/states/remote_service/StateChangePinResponse.cpp +++ b/src/core/states/remote_service/StateChangePinResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "StateChangePinResponse.h" diff --git a/src/core/states/remote_service/StateChangePinResponse.h b/src/core/states/remote_service/StateChangePinResponse.h index 9df62d418..ac9ba7782 100644 --- a/src/core/states/remote_service/StateChangePinResponse.h +++ b/src/core/states/remote_service/StateChangePinResponse.h @@ -1,7 +1,7 @@ /*! * \brief This state executes the remote message IfdModifyPin. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateEnterNewPacePinRemote.cpp b/src/core/states/remote_service/StateEnterNewPacePinRemote.cpp index b6bbfab4c..efd9ddba9 100644 --- a/src/core/states/remote_service/StateEnterNewPacePinRemote.cpp +++ b/src/core/states/remote_service/StateEnterNewPacePinRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateEnterNewPacePinRemote.h" diff --git a/src/core/states/remote_service/StateEnterNewPacePinRemote.h b/src/core/states/remote_service/StateEnterNewPacePinRemote.h index a6fd06a53..f8541e469 100644 --- a/src/core/states/remote_service/StateEnterNewPacePinRemote.h +++ b/src/core/states/remote_service/StateEnterNewPacePinRemote.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateEnterPacePasswordRemote.cpp b/src/core/states/remote_service/StateEnterPacePasswordRemote.cpp index 459914411..d72174b0a 100644 --- a/src/core/states/remote_service/StateEnterPacePasswordRemote.cpp +++ b/src/core/states/remote_service/StateEnterPacePasswordRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StateEnterPacePasswordRemote.h" diff --git a/src/core/states/remote_service/StateEnterPacePasswordRemote.h b/src/core/states/remote_service/StateEnterPacePasswordRemote.h index b1a155d6a..5a8a94704 100644 --- a/src/core/states/remote_service/StateEnterPacePasswordRemote.h +++ b/src/core/states/remote_service/StateEnterPacePasswordRemote.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateEstablishPaceChannelRemote.cpp b/src/core/states/remote_service/StateEstablishPaceChannelRemote.cpp index 8d4e7e1fe..e4dc47cfe 100644 --- a/src/core/states/remote_service/StateEstablishPaceChannelRemote.cpp +++ b/src/core/states/remote_service/StateEstablishPaceChannelRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "StateEstablishPaceChannelRemote.h" @@ -123,7 +123,7 @@ void StateEstablishPaceChannelRemote::onEstablishConnectionDone(QSharedPointergetReturnCode(); - qCDebug(statemachine) << "PACE PUK finished with:" << returnCode; + qCDebug(statemachine) << "PACE_PUK finished with:" << returnCode; if (returnCode == CardReturnCode::OK || CardReturnCodeUtil::equalsWrongPacePassword(returnCode)) { diff --git a/src/core/states/remote_service/StateEstablishPaceChannelRemote.h b/src/core/states/remote_service/StateEstablishPaceChannelRemote.h index 09b3ad582..89e03ba25 100644 --- a/src/core/states/remote_service/StateEstablishPaceChannelRemote.h +++ b/src/core/states/remote_service/StateEstablishPaceChannelRemote.h @@ -1,7 +1,7 @@ /*! * \brief This state executes the remote message PACE channel establish. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateEstablishPaceChannelResponse.cpp b/src/core/states/remote_service/StateEstablishPaceChannelResponse.cpp index 824ac6b5f..dd6bf12d4 100644 --- a/src/core/states/remote_service/StateEstablishPaceChannelResponse.cpp +++ b/src/core/states/remote_service/StateEstablishPaceChannelResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "StateEstablishPaceChannelResponse.h" diff --git a/src/core/states/remote_service/StateEstablishPaceChannelResponse.h b/src/core/states/remote_service/StateEstablishPaceChannelResponse.h index e29ee1d53..46551a868 100644 --- a/src/core/states/remote_service/StateEstablishPaceChannelResponse.h +++ b/src/core/states/remote_service/StateEstablishPaceChannelResponse.h @@ -1,7 +1,7 @@ /*! * \brief This state executes the remote message PACE channel establish. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StatePrepareChangePinRemote.cpp b/src/core/states/remote_service/StatePrepareChangePinRemote.cpp index 9e4066d01..d75fe2b79 100644 --- a/src/core/states/remote_service/StatePrepareChangePinRemote.cpp +++ b/src/core/states/remote_service/StatePrepareChangePinRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StatePrepareChangePinRemote.h" diff --git a/src/core/states/remote_service/StatePrepareChangePinRemote.h b/src/core/states/remote_service/StatePrepareChangePinRemote.h index 42aeed7e2..4f6ca9d17 100644 --- a/src/core/states/remote_service/StatePrepareChangePinRemote.h +++ b/src/core/states/remote_service/StatePrepareChangePinRemote.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StatePreparePaceRemote.cpp b/src/core/states/remote_service/StatePreparePaceRemote.cpp index fd2abb314..a37da4b01 100644 --- a/src/core/states/remote_service/StatePreparePaceRemote.cpp +++ b/src/core/states/remote_service/StatePreparePaceRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "StatePreparePaceRemote.h" diff --git a/src/core/states/remote_service/StatePreparePaceRemote.h b/src/core/states/remote_service/StatePreparePaceRemote.h index c0ec5e060..4a5acfaf4 100644 --- a/src/core/states/remote_service/StatePreparePaceRemote.h +++ b/src/core/states/remote_service/StatePreparePaceRemote.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateProcessRemoteMessages.cpp b/src/core/states/remote_service/StateProcessRemoteMessages.cpp index 30ca318ef..79b2ce857 100644 --- a/src/core/states/remote_service/StateProcessRemoteMessages.cpp +++ b/src/core/states/remote_service/StateProcessRemoteMessages.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "StateProcessRemoteMessages.h" @@ -70,7 +70,7 @@ void StateProcessRemoteMessages::onClosed() disconnect(connection); } - qCDebug(statemachine) << "Reseting all PACE passwords and further relevant context information."; + qCDebug(statemachine) << "Resetting all PACE passwords and further relevant context information."; getContext()->onResetMessageHandler(); } diff --git a/src/core/states/remote_service/StateProcessRemoteMessages.h b/src/core/states/remote_service/StateProcessRemoteMessages.h index 20468403e..f25e2bf0e 100644 --- a/src/core/states/remote_service/StateProcessRemoteMessages.h +++ b/src/core/states/remote_service/StateProcessRemoteMessages.h @@ -2,7 +2,7 @@ * \brief This state allows the processing of ordenary remote messages in the * background and handles special PACE messages. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateStartRemoteService.cpp b/src/core/states/remote_service/StateStartRemoteService.cpp index 23029755f..22a21e7ba 100644 --- a/src/core/states/remote_service/StateStartRemoteService.cpp +++ b/src/core/states/remote_service/StateStartRemoteService.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "StateStartRemoteService.h" diff --git a/src/core/states/remote_service/StateStartRemoteService.h b/src/core/states/remote_service/StateStartRemoteService.h index e2f138536..d4b481c90 100644 --- a/src/core/states/remote_service/StateStartRemoteService.h +++ b/src/core/states/remote_service/StateStartRemoteService.h @@ -1,7 +1,7 @@ /*! * \brief Start the remote service. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/states/remote_service/StateStopRemoteService.cpp b/src/core/states/remote_service/StateStopRemoteService.cpp index fcd5ca07e..84d64f1d8 100644 --- a/src/core/states/remote_service/StateStopRemoteService.cpp +++ b/src/core/states/remote_service/StateStopRemoteService.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "StateStopRemoteService.h" diff --git a/src/core/states/remote_service/StateStopRemoteService.h b/src/core/states/remote_service/StateStopRemoteService.h index d018c1af5..5d13e9742 100644 --- a/src/core/states/remote_service/StateStopRemoteService.h +++ b/src/core/states/remote_service/StateStopRemoteService.h @@ -1,7 +1,7 @@ /*! * \brief Stop the remote service. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/export/PdfCreator.cpp b/src/export/PdfCreator.cpp index 010b1cc3d..6b39ef73c 100644 --- a/src/export/PdfCreator.cpp +++ b/src/export/PdfCreator.cpp @@ -1,9 +1,10 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "PdfCreator.h" +#include #include #include #include @@ -82,6 +83,26 @@ void PdfCreator::createFooter() } +// inspired by void QTextDocument::drawContents(QPainter *p, const QRectF &rect) +void drawContents(QTextDocument& pTextDocument, QPainter& pPainter, const QRectF& pClipRect = QRectF()) +{ + QAbstractTextDocumentLayout::PaintContext paintContext; + paintContext.palette.setColor(QPalette::Text, Qt::black); + + pPainter.save(); + + if (pClipRect.isValid()) + { + pPainter.setClipRect(pClipRect); + paintContext.clip = pClipRect; + } + + pTextDocument.documentLayout()->draw(&pPainter, paintContext); + + pPainter.restore(); +} + + int qt_defaultDpi(); bool PdfCreator::save() { @@ -107,16 +128,16 @@ bool PdfCreator::save() { painter.resetTransform(); - mHeader.drawContents(&painter); + drawContents(mHeader, painter); painter.translate(0, headerHeight); painter.save(); painter.translate(0, -currentRect.y()); - mContent.drawContents(&painter, currentRect); + drawContents(mContent, painter, currentRect); painter.restore(); painter.translate(0, currentRect.height()); - mFooter.drawContents(&painter); + drawContents(mFooter, painter); currentRect.translate(0, currentRect.height()); if (currentRect.intersects(contentRect)) diff --git a/src/export/PdfCreator.h b/src/export/PdfCreator.h index 6d402edf9..27f46a5e6 100644 --- a/src/export/PdfCreator.h +++ b/src/export/PdfCreator.h @@ -1,7 +1,7 @@ /*! * \brief Tool to create PDF-Documents. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/export/PdfExporter.cpp b/src/export/PdfExporter.cpp index 3525fef53..5749d4079 100644 --- a/src/export/PdfExporter.cpp +++ b/src/export/PdfExporter.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "PdfExporter.h" diff --git a/src/export/PdfExporter.h b/src/export/PdfExporter.h index 8b3228308..a41c3c8db 100644 --- a/src/export/PdfExporter.h +++ b/src/export/PdfExporter.h @@ -1,7 +1,7 @@ /*! * \brief Tool to export data of history or selfauthentication result. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/external/CMakeLists.txt b/src/external/CMakeLists.txt index 633965bc2..361090ff7 100644 --- a/src/external/CMakeLists.txt +++ b/src/external/CMakeLists.txt @@ -51,6 +51,10 @@ ELSE() ADD_LIBRARY(AusweisAppExternalHttpParser ${EXTERNAL_HTTP_PARSER_FILES}) TARGET_INCLUDE_DIRECTORIES(AusweisAppExternalHttpParser INTERFACE "$") + IF(IOS) + SET_TARGET_PROPERTIES(AusweisAppExternalHttpParser PROPERTIES ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}) + ENDIF() + IF(MSVC) SET_PROPERTY(TARGET AusweisAppExternalHttpParser APPEND_STRING PROPERTY COMPILE_FLAGS " /w") ELSE() diff --git a/src/file_provider/Downloader.cpp b/src/file_provider/Downloader.cpp index 247a594dd..b9e6ac947 100644 --- a/src/file_provider/Downloader.cpp +++ b/src/file_provider/Downloader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "Downloader.h" diff --git a/src/file_provider/Downloader.h b/src/file_provider/Downloader.h index a364dd22c..a1b435651 100644 --- a/src/file_provider/Downloader.h +++ b/src/file_provider/Downloader.h @@ -2,7 +2,7 @@ * \brief Generic class that allows to download files from a server to the * local application cache. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/file_provider/FileProvider.cpp b/src/file_provider/FileProvider.cpp index 6e884321e..3f6ae1774 100644 --- a/src/file_provider/FileProvider.cpp +++ b/src/file_provider/FileProvider.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "FileProvider.h" diff --git a/src/file_provider/FileProvider.h b/src/file_provider/FileProvider.h index ae8ecd32c..a98947fea 100644 --- a/src/file_provider/FileProvider.h +++ b/src/file_provider/FileProvider.h @@ -1,7 +1,7 @@ /*! * \brief Class that holds a table of the UpdatableFile instances currently in use. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/file_provider/UpdatableFile.cpp b/src/file_provider/UpdatableFile.cpp index 740c2224b..5827fd7db 100644 --- a/src/file_provider/UpdatableFile.cpp +++ b/src/file_provider/UpdatableFile.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "UpdatableFile.h" diff --git a/src/file_provider/UpdatableFile.h b/src/file_provider/UpdatableFile.h index e638769ce..fd1fcd1dd 100644 --- a/src/file_provider/UpdatableFile.h +++ b/src/file_provider/UpdatableFile.h @@ -4,7 +4,7 @@ * This class also handles the synchronization of the local cache with the content * provided by a server. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/BreakPropertyBindingDiagnosticLogFilter.cpp b/src/global/BreakPropertyBindingDiagnosticLogFilter.cpp index e158b7404..bc5db2b92 100644 --- a/src/global/BreakPropertyBindingDiagnosticLogFilter.cpp +++ b/src/global/BreakPropertyBindingDiagnosticLogFilter.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "BreakPropertyBindingDiagnosticLogFilter.h" diff --git a/src/global/BreakPropertyBindingDiagnosticLogFilter.h b/src/global/BreakPropertyBindingDiagnosticLogFilter.h index e7d8287f4..7ea5bdeed 100644 --- a/src/global/BreakPropertyBindingDiagnosticLogFilter.h +++ b/src/global/BreakPropertyBindingDiagnosticLogFilter.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/BuildHelper.cpp b/src/global/BuildHelper.cpp index 4cc678c0a..178f30741 100644 --- a/src/global/BuildHelper.cpp +++ b/src/global/BuildHelper.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "BuildHelper.h" diff --git a/src/global/BuildHelper.h b/src/global/BuildHelper.h index 8b7e41abb..7e7898f2c 100644 --- a/src/global/BuildHelper.h +++ b/src/global/BuildHelper.h @@ -1,7 +1,7 @@ /* * \brief Helper to get build date and time. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/CardReturnCode.cpp b/src/global/CardReturnCode.cpp index eb33ee5cb..d93a43258 100644 --- a/src/global/CardReturnCode.cpp +++ b/src/global/CardReturnCode.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CardReturnCode.h" diff --git a/src/global/CardReturnCode.h b/src/global/CardReturnCode.h index 0fdaaae4f..17c13b52a 100644 --- a/src/global/CardReturnCode.h +++ b/src/global/CardReturnCode.h @@ -1,7 +1,7 @@ /*! * \brief Global error code definitions * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/DeviceInfo.cpp b/src/global/DeviceInfo.cpp index b41ed2093..e51a72f96 100644 --- a/src/global/DeviceInfo.cpp +++ b/src/global/DeviceInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "DeviceInfo.h" @@ -44,6 +44,7 @@ QString DeviceInfo::getPrettyInfo() } +#ifndef Q_OS_IOS QString DeviceInfo::getName() { #ifdef Q_OS_ANDROID @@ -56,6 +57,9 @@ QString DeviceInfo::getName() } +#endif + + QString DeviceInfo::getFingerprint() { #ifdef Q_OS_ANDROID diff --git a/src/global/DeviceInfo.h b/src/global/DeviceInfo.h index d2fe7ac16..1dd28378a 100644 --- a/src/global/DeviceInfo.h +++ b/src/global/DeviceInfo.h @@ -2,7 +2,7 @@ * \brief Implements a wrapper for different APIs to get * device information like android device name. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/DeviceInfo_ios.mm b/src/global/DeviceInfo_ios.mm new file mode 100644 index 000000000..15ee61b01 --- /dev/null +++ b/src/global/DeviceInfo_ios.mm @@ -0,0 +1,17 @@ +/*! + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +#include "DeviceInfo.h" + +#import +#import + +using namespace governikus; + +QString DeviceInfo::getName() +{ + struct utsname systemInfo; + uname(&systemInfo); + return QString::fromNSString([NSString stringWithCString:systemInfo.machine encoding:NSUTF8StringEncoding]); +} diff --git a/src/global/ECardApiResult.cpp b/src/global/ECardApiResult.cpp index bd5b6a6b0..bd26c1cad 100644 --- a/src/global/ECardApiResult.cpp +++ b/src/global/ECardApiResult.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ECardApiResult.h" @@ -173,7 +173,6 @@ void ECardApiResult::initConversionMaps() addConversionElement(GlobalStatus::Code::Workflow_Cannot_Confirm_IdCard_Authenticity, Minor::AL_Internal_Error); addConversionElement(GlobalStatus::Code::Workflow_Unknown_Paos_From_EidServer, Minor::AL_Internal_Error); addConversionElement(GlobalStatus::Code::Workflow_Unexpected_Message_From_EidServer, Minor::AL_Internal_Error); - addConversionElement(GlobalStatus::Code::Workflow_Pin_Blocked_And_Puk_Objectionable, Minor::AL_Internal_Error); addConversionElement(GlobalStatus::Code::Card_Protocol_Error, Minor::AL_Internal_Error); addConversionElement(GlobalStatus::Code::Paos_Generic_Server_Error, Minor::AL_Unkown_API_Function); @@ -367,9 +366,6 @@ QString ECardApiResult::getMessage(Minor pMinor) return tr("The framework or layer has not been initialized."); case Minor::AL_Warning_Connection_Disconnected: - //: LABEL ALL_PLATFORMS - return tr("The active session has been terminated."); - case Minor::AL_Session_Terminated_Warning: //: LABEL ALL_PLATFORMS return tr("The active session has been terminated."); @@ -432,7 +428,7 @@ QString ECardApiResult::getMessage(Minor pMinor) case Minor::SAL_Cancellation_by_User: //: LABEL ALL_PLATFORMS - return tr("The process was cancelled by the user."); + return tr("The process has been cancelled."); case Minor::IL_Signature_InvalidCertificatePath: //: LABEL ALL_PLATFORMS @@ -440,7 +436,7 @@ QString ECardApiResult::getMessage(Minor pMinor) case Minor::SAL_Invalid_Key: //: LABEL ALL_PLATFORMS - return tr("This action cannot be performed. The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function."); + return tr("This action cannot be performed. The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function."); case Minor::SAL_SecurityConditionNotSatisfied: //: LABEL ALL_PLATFORMS diff --git a/src/global/ECardApiResult.h b/src/global/ECardApiResult.h index e3d05ae26..9d1bc769a 100644 --- a/src/global/ECardApiResult.h +++ b/src/global/ECardApiResult.h @@ -1,7 +1,7 @@ /*! * \brief Status representation according to TR-03112-6 "eCard-API-Framework" * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/EnumHelper.h b/src/global/EnumHelper.h index 9ce095dc7..dcb808091 100644 --- a/src/global/EnumHelper.h +++ b/src/global/EnumHelper.h @@ -1,7 +1,7 @@ /*! * \brief Helper class to provide a QMetaObject handler for enumerations. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/Env.cpp b/src/global/Env.cpp index a3802a10e..3dcb1683a 100644 --- a/src/global/Env.cpp +++ b/src/global/Env.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "Env.h" @@ -69,7 +69,7 @@ void Env::set(const QMetaObject& pMetaObject, void* pObject) } -void Env::setShared(const QMetaObject& pMetaObject, QSharedPointer pObject) +void Env::setShared(const QMetaObject& pMetaObject, const QSharedPointer& pObject) { const Identifier className = pMetaObject.className(); auto& holder = getInstance(); diff --git a/src/global/Env.h b/src/global/Env.h index de0479601..cb66bd576 100644 --- a/src/global/Env.h +++ b/src/global/Env.h @@ -1,7 +1,7 @@ /* * \brief Runtime environment to create (mockable) objects. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -319,7 +319,7 @@ class Env } - static void setShared(const QMetaObject& pMetaObject, QSharedPointer pObject = QSharedPointer()); + static void setShared(const QMetaObject& pMetaObject, const QSharedPointer& pObject); #endif }; diff --git a/src/global/FileDestination.h b/src/global/FileDestination.h index 88be7099a..edd96d95d 100644 --- a/src/global/FileDestination.h +++ b/src/global/FileDestination.h @@ -1,12 +1,14 @@ /* * \brief Little helper that will abstract pathes of underlying systems * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once #include +#include +#include #include namespace governikus @@ -35,8 +37,28 @@ class FileDestination public: - static QString getPath(const QString& pFilename) + static QString getPath(const QString& pFilename, + QStandardPaths::LocateOption pOption = QStandardPaths::LocateFile, + QStandardPaths::StandardLocation pStandard = QStandardPaths::AppDataLocation) { + #if defined(Q_OS_LINUX) || (defined(Q_OS_BSD4) && !defined(Q_OS_MACOS) && !defined(Q_OS_IOS)) + const auto match = QStandardPaths::locate(pStandard, pFilename, pOption); + if (!match.isNull()) + { + return match; + } + + qDebug() << pFilename << "not found in following destinations |" << pOption; + const auto defaultLocations = QStandardPaths::standardLocations(pStandard); + for (const auto& location : defaultLocations) + { + qDebug() << location; + } + #else + Q_UNUSED(pOption) + Q_UNUSED(pStandard) + #endif + return getPath() % QLatin1Char('/') % pFilename; } diff --git a/src/global/FuncUtils.h b/src/global/FuncUtils.h index 69305c70c..0e547402d 100644 --- a/src/global/FuncUtils.h +++ b/src/global/FuncUtils.h @@ -1,7 +1,7 @@ /*! * \brief Template functions that allow to map and filter over QVectors. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/GlobalStatus.cpp b/src/global/GlobalStatus.cpp index 4a1205982..b4767517c 100644 --- a/src/global/GlobalStatus.cpp +++ b/src/global/GlobalStatus.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "GlobalStatus.h" @@ -48,8 +48,6 @@ bool GlobalStatus::isMessageMasked() const case Code::Workflow_TrustedChannel_Server_Format_Error: case Code::Network_Ssl_Establishment_Error: case Code::Workflow_Wrong_Parameter_Invocation: - case Code::Network_Other_Error: - case Code::Workflow_TrustedChannel_Other_Network_Error: case Code::Workflow_Network_Ssl_Connection_Unsupported_Algorithm_Or_Length: case Code::Workflow_Network_Empty_Redirect_Url: case Code::Workflow_Network_Expected_Redirect: @@ -98,10 +96,10 @@ QString GlobalStatus::toErrorDescription(const bool pSimplifiedVersion) const #if defined(Q_OS_ANDROID) || defined(Q_OS_IOS) //: ERROR ANDROID IOS Error message which is used for "masked" errors. Generic message with link to support section of the homepage. - QString message = tr("An error occurred. Please contact our %1support%2.").arg(hyperlink, QStringLiteral("")); + QString message = tr("A secure connection to the provider could not be established. Please contact our %1support%2.").arg(hyperlink, QStringLiteral("")); #else //: ERROR DESKTOP Error message which is used for "masked" errors. Generic message with link to support section of the homepage. - QString message = tr("An error occurred. Please contact our %1support%2 or feel free to send us an email.").arg(hyperlink, QStringLiteral("")); + QString message = tr("A secure connection to the provider could not be established. Please contact our %1support%2 or feel free to send us an email.").arg(hyperlink, QStringLiteral("")); #endif return message; } @@ -126,7 +124,7 @@ QString GlobalStatus::toErrorDescriptionInternal() const case Code::Workflow_AlreadyInProgress_Error: //: ERROR ALL_PLATFORMS An ActivationHandler is requested even though an operation is currently still running. - return tr("Cannot start authentication. An operation is already in progress."); + return tr("Cannot start authentication. An operation is already active."); case Code::Workflow_Card_Removed: //: ERROR ALL_PLATFORMS The card was removed after the PACE channel was established. @@ -144,10 +142,6 @@ QString GlobalStatus::toErrorDescriptionInternal() const //: ERROR_MASKED ALL_PLATFORMS The server sent a valid PAOS message but its type was unexpected. return tr("The program received an unexpected message from the server."); - case Code::Workflow_Pin_Blocked_And_Puk_Objectionable: - //: ERROR ALL_PLATFORMS The id card was blocked after three wrongfully entered PINs, the PUK is required to unlock the card. Hint to do so in the PIN management section of the app. - return tr("After three wrong entries your PIN is blocked. Please use the PIN management in this app to unblock it with the help of your PUK."); - case Code::Workflow_Preverification_Developermode_Error: //: ERROR ALL_PLATFORMS The developer mode is enabled but a productive environment was detected. return tr("Using the developer mode is only allowed in a test environment."); @@ -165,7 +159,7 @@ QString GlobalStatus::toErrorDescriptionInternal() const return tr("No unique DV CVC"); case Code::Workflow_No_Permission_Error: - //: ERROR ALL_PLATFORMS DidAuthenticateEAC2, AA2 or the id card declined the certificates. + //: ERROR ALL_PLATFORMS DidAuthenticateEAC2, AA2 or the ID card declined the certificates. return tr("Authentication failed."); case Code::Workflow_Certificate_No_Description: @@ -196,11 +190,11 @@ QString GlobalStatus::toErrorDescriptionInternal() const case Code::Workflow_TrustedChannel_Hash_Not_In_Description: case Code::Workflow_Network_Ssl_Hash_Not_In_Certificate_Description: //: ERROR ALL_PLATFORMS The TLS certificate was not folded with the Authorization Certificate, thus violating the security requirements. Might also be caused by a firewall and/or the antivirus software. - return tr("Hash of certificate not in certificate description (issuer: %1). This indicates a misconfiguration or manipulation of the certificate. Please check that your antivirus-software and firewalls are not interfering with SSL traffic.").arg(getExternalInfo()); + return tr("Hash of TLS certificate not in certificate description (issuer: %1). This indicates a misconfiguration or manipulation of the certificate. Please check that your antivirus-software and firewalls are not interfering with TLS traffic.").arg(getExternalInfo()); case Code::Workflow_TrustedChannel_No_Data_Received: //: ERROR_MASKED ALL_PLATFORMS Received an empty TC token. - return tr("Received no data."); + return tr("The TCToken contained no data."); case Code::Workflow_TrustedChannel_ServiceUnavailable: case Code::Network_ServiceUnavailable: @@ -232,8 +226,8 @@ QString GlobalStatus::toErrorDescriptionInternal() const case Code::Network_Other_Error: case Code::Workflow_TrustedChannel_Other_Network_Error: - //: ERROR_MASKED ALL_PLATFORMS Other critial network error by Qt. - return tr("An unknown network error occurred."); + //: ERROR ALL_PLATFORMS Other critial network error by Qt. + return tr("An unknown network error occurred. Check your network connection and try to restart the app."); case Code::Workflow_Reader_Became_Inaccessible: //: ERROR ALL_PLATFORMS The card reader was removed after the PACE channel was established. @@ -245,12 +239,12 @@ QString GlobalStatus::toErrorDescriptionInternal() const case Code::Workflow_Network_Ssl_Connection_Unsupported_Algorithm_Or_Length: //: ERROR_MASKED ALL_PLATFORMS - return tr("Error while connecting to the service provider. The SSL connection uses an unsupported key algorithm or length."); + return tr("Error while connecting to the provider. The TLS connection uses an unsupported key algorithm or length."); case Code::Workflow_TrustedChannel_Ssl_Certificate_Unsupported_Algorithm_Or_Length: case Code::Workflow_Network_Ssl_Certificate_Unsupported_Algorithm_Or_Length: //: ERROR ALL_PLATFORMS Received a TLS certificate that uses an invalid algorithm or key length. - return tr("Error while connecting to the server. The SSL certificate uses an unsupported key algorithm or length. Certificate issuer: %1").arg(getExternalInfo()); + return tr("Error while connecting to the server. The TLS certificate uses an unsupported key algorithm or length. Certificate issuer: %1").arg(getExternalInfo()); case Code::Workflow_Network_Empty_Redirect_Url: //: ERROR_MASKED ALL_PLATFORMS The redirect URL could not be determined because the server sent an empty response. @@ -271,7 +265,7 @@ QString GlobalStatus::toErrorDescriptionInternal() const case Code::Workflow_Cancellation_By_User: case Code::Card_Cancellation_By_User: //: ERROR ALL_PLATFORMS The user cancelled the authentication in either the UI or the card reader. - return tr("The process was cancelled by the user."); + return tr("The process has been cancelled."); case Code::Paos_Generic_Server_Error: case Code::Paos_Unexpected_Warning: @@ -288,7 +282,7 @@ QString GlobalStatus::toErrorDescriptionInternal() const return tr("The maximum time was exceeded during input process."); case Code::Card_Not_Found: - //: ERROR ALL_PLATFORMS Internal error, either PCSC, SaK or card reader could not find the id card. + //: ERROR ALL_PLATFORMS Internal error, either PCSC, SaK or card reader could not find the ID card. return tr("Card does not exist"); case Code::Card_Communication_Error: @@ -304,28 +298,28 @@ QString GlobalStatus::toErrorDescriptionInternal() const tr("AusweisApp2 Support")); case Code::Card_Invalid_Pin: - //: ERROR ALL_PLATFORMS The id card declined the PIN. - return tr("The given PIN is invalid."); + //: ERROR ALL_PLATFORMS The ID card declined the PIN. + return tr("The given PIN is not correct."); case Code::Card_Invalid_Can: - //: ERROR ALL_PLATFORMS The id card declined the CAN. - return tr("The given card access number (CAN) is invalid."); + //: ERROR ALL_PLATFORMS The ID card declined the CAN. + return tr("The given card access number (CAN) is not correct."); case Code::Card_Invalid_Puk: - //: ERROR ALL_PLATFORMS The id card declined the PUK. - return tr("The given PUK is invalid."); + //: ERROR ALL_PLATFORMS The ID card declined the PUK. + return tr("The given PUK is not correct."); case Code::Card_Pin_Blocked: - //: ERROR ALL_PLATFORMS The id card refused the PIN since the PIN feature is blocked after too many wrong attemps. + //: ERROR ALL_PLATFORMS The ID card refused the PIN since the PIN feature is blocked after too many wrong attemps. return tr("The PIN was blocked after too many unsuccessful attempts."); case Code::Card_Pin_Not_Blocked: - //: ERROR ALL_PLATFORMS It was attempted to unlock the id card via PUK even though it was not locked in the first place. This scenario is avoided in the UI by hiding the respective UI elements. + //: ERROR ALL_PLATFORMS It was attempted to unlock the ID card via PUK even though it was not locked in the first place. This scenario is avoided in the UI by hiding the respective UI elements. return tr("The PIN is not blocked."); case Code::Card_Puk_Blocked: - //: ERROR ALL_PLATFORMS The card declined the PUK since it was entered wrongfully 10 times, the local authorities have to be contacted to unlock the id card. - return tr("The PUK was used ten times and is set inoperative. Please contact the competent authority that issued your ID document to unlock the PIN."); + //: ERROR ALL_PLATFORMS The card declined the PUK since it was entered wrongfully 10 times, the local authorities have to be contacted to unlock the ID card. + return tr("The PUK was used ten times and can not be used anymore to unblock the PIN. Please contact the competent authority that issued your ID card to unblock the PIN."); case Code::Card_NewPin_Mismatch: //: ERROR ALL_PLATFORMS The card reader signalled that the new PIN was not confirmed correctly. @@ -337,35 +331,35 @@ QString GlobalStatus::toErrorDescriptionInternal() const case Code::Workflow_Bluetooth_Reader_Connection_Error: //: ERROR ALL_PLATFORMS Error while connecting to a bluetooth card reader. - return tr("An error occurred while connecting to a reader device."); + return tr("An error occurred while connecting to a bluetooth card reader."); case Code::Workflow_Reader_Device_Scan_Error: //: ERROR ALL_PLATFORMS Error while searching for bluetooth card reader. - return tr("An error occurred while scanning for reader devices."); + return tr("An error occurred while scanning for a bluetooth card reader."); case Code::RemoteReader_CloseCode_AbnormalClose: //: ERROR ALL_PLATFORMS The connection to the smartphone card reader (SaK) was lost. - return tr("The remote card reader connection was not closed properly."); + return tr("The smartphone as card reader (SaC) connection was aborted."); case Code::RemoteConnector_InvalidRequest: //: ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) was invalid (missing device ID). - return tr("Remote reader connection request contains invalid parameters."); + return tr("Smartphone as card reader (SaC) connection request was invalid."); case Code::RemoteConnector_NoSupportedApiLevel: //: ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) was invalid (API mismatch). - return tr("Your remote reader version is incompatible with the local version. Please install the latest AusweisApp2 version on both your smartphone and your computer."); + return tr("Your smartphone as card reader (SaC) version is incompatible with the local version. Please install the latest AusweisApp2 version on both your smartphone and your computer."); case Code::RemoteConnector_ConnectionTimeout: //: ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) timed out. - return tr("A timeout occurred while trying to establish a connection to a remote reader."); + return tr("A timeout occurred while trying to establish a connection to the smartphone as card reader (SaC)."); case Code::RemoteConnector_ConnectionError: //: ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) failed due to network errors (Host not found, OS error, ...) - return tr("An error occurred while trying to establish a connection to a remote reader."); + return tr("An error occurred while trying to establish a connection to the smartphone as card reader (SaC)."); case Code::RemoteConnector_RemoteHostRefusedConnection: //: ERROR ALL_PLATFORMS The requested connection to the smartphone card reader (SaK) was rejected by the device. - return tr("Remote device has rejected the connection. Please check the pairing code."); + return tr("The smartphone to be paired has rejected the connection. Please check the pairing code. If no pairing code is shown activate the pairing mode."); case Code::Downloader_File_Not_Found: //: ERROR ALL_PLATFORMS Download of the file failed with HTTP error code 404. diff --git a/src/global/GlobalStatus.h b/src/global/GlobalStatus.h index 943a318ac..e05d422ee 100644 --- a/src/global/GlobalStatus.h +++ b/src/global/GlobalStatus.h @@ -1,7 +1,7 @@ /*! * \brief A global mapping for errors * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -42,7 +42,6 @@ class GlobalStatus Workflow_Cannot_Confirm_IdCard_Authenticity, Workflow_Unknown_Paos_From_EidServer, Workflow_Unexpected_Message_From_EidServer, - Workflow_Pin_Blocked_And_Puk_Objectionable, Workflow_Preverification_Developermode_Error, Workflow_Preverification_Error, Workflow_No_Unique_AtCvc, diff --git a/src/global/Initializer.cpp b/src/global/Initializer.cpp index 8089d68a5..af94cdbff 100644 --- a/src/global/Initializer.cpp +++ b/src/global/Initializer.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "Initializer.h" diff --git a/src/global/Initializer.h b/src/global/Initializer.h index 7b14f19e4..97a710d65 100644 --- a/src/global/Initializer.h +++ b/src/global/Initializer.h @@ -1,7 +1,7 @@ /* * \brief Initializer to register a lambda that will be executed if QCoreApplication is ready. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/LanguageLoader.cpp b/src/global/LanguageLoader.cpp index 62131ad78..d81455658 100644 --- a/src/global/LanguageLoader.cpp +++ b/src/global/LanguageLoader.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "LanguageLoader.h" @@ -23,7 +23,7 @@ const QLocale::Language LanguageLoader::mFallbackLanguage = QLocale::Language::E QLocale LanguageLoader::mDefaultLanguage = QLocale::system(); LanguageLoader::LanguageLoader() - : mPath(FileDestination::getPath(QStringLiteral("translations"))) + : mPath(FileDestination::getPath(QStringLiteral("translations"), QStandardPaths::LocateDirectory)) , mTranslatorList() , mComponentList( { diff --git a/src/global/LanguageLoader.h b/src/global/LanguageLoader.h index 43a96004f..f13c8cee4 100644 --- a/src/global/LanguageLoader.h +++ b/src/global/LanguageLoader.h @@ -1,7 +1,7 @@ /* * \brief Loads translation files for different languages. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/LogCategories.cpp b/src/global/LogCategories.cpp index 9555845c0..5ad395e15 100644 --- a/src/global/LogCategories.cpp +++ b/src/global/LogCategories.cpp @@ -2,7 +2,7 @@ * \brief Definition of all logging categories. * * \see Q_LOGGING_CATEGORY - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/src/global/LogHandler.cpp b/src/global/LogHandler.cpp index e69a04ba7..1b226dc67 100644 --- a/src/global/LogHandler.cpp +++ b/src/global/LogHandler.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "LogHandler.h" @@ -41,7 +41,7 @@ LogHandler::LogHandler() , mCriticalLog(false) , mCriticalLogWindow(10) , mCriticalLogIgnore({LOGCAT(fileprovider), LOGCAT(securestorage), LOGCAT(configuration)}) - , mMessagePattern(QStringLiteral("%{category} %{time yyyy.MM.dd hh:mm:ss.zzz} %{threadid} %{if-debug} %{endif}%{if-info}I%{endif}%{if-warning}W%{endif}%{if-critical}C%{endif}%{if-fatal}F%{endif} %{function}(%{file}:%{line}) %{message}")) + , mMessagePattern(QStringLiteral("%{category} %{time yyyy.MM.dd hh:mm:ss.zzz} %{threadid} %{if-debug} %{endif}%{if-info}I%{endif}%{if-warning}W%{endif}%{if-critical}C%{endif}%{if-fatal}F%{endif} %{function}(%{file}:%{line}) %{message}")) , mDefaultMessagePattern(QStringLiteral("%{if-category}%{category}: %{endif}%{message}")) // as defined in qlogging.cpp , mLogFile(getLogFileTemplate()) , mHandler(nullptr) @@ -250,6 +250,11 @@ QByteArray LogHandler::formatFunction(const char* const pFunction, const QByteAr const auto end = function.indexOf(')'); function = function.left(start) + function.mid(end + 1); + if (function.endsWith(" const")) + { + function = function.left(function.size() - 6); + } + // Remove the return type (if any) if (function.indexOf(' ') != -1) { @@ -400,7 +405,7 @@ void LogHandler::removeOldLogfiles() if (entry.fileTime(QFileDevice::FileModificationTime) < threshold) { const auto result = QFile::remove(entry.absoluteFilePath()); - qDebug() << "Auto-remove old log file:" << entry.absoluteFilePath() << '|' << result; + qDebug() << "Auto-remove old logfile:" << entry.absoluteFilePath() << '|' << result; } } } @@ -412,7 +417,7 @@ bool LogHandler::removeOtherLogfiles() for (const auto& entry : otherLogFiles) { const auto result = QFile::remove(entry.absoluteFilePath()); - qDebug() << "Remove old log file:" << entry.absoluteFilePath() << '|' << result; + qDebug() << "Remove old logfile:" << entry.absoluteFilePath() << '|' << result; } return !otherLogFiles.isEmpty(); diff --git a/src/global/LogHandler.h b/src/global/LogHandler.h index d73bb74f9..9cdcf153c 100644 --- a/src/global/LogHandler.h +++ b/src/global/LogHandler.h @@ -1,7 +1,7 @@ /* * \brief Logging handler of QtMessageHandler * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/Randomizer.cpp b/src/global/Randomizer.cpp index ed78961f6..f87641181 100644 --- a/src/global/Randomizer.cpp +++ b/src/global/Randomizer.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "Randomizer.h" diff --git a/src/global/Randomizer.h b/src/global/Randomizer.h index ecd28d795..966f1f862 100644 --- a/src/global/Randomizer.h +++ b/src/global/Randomizer.h @@ -1,7 +1,7 @@ /*! * \brief Helper to get a Randomizer. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/ResourceLoader.cpp b/src/global/ResourceLoader.cpp index 76b71c248..3c9395feb 100644 --- a/src/global/ResourceLoader.cpp +++ b/src/global/ResourceLoader.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ResourceLoader.h" diff --git a/src/global/ResourceLoader.h b/src/global/ResourceLoader.h index 8548370af..ce4e6cf23 100644 --- a/src/global/ResourceLoader.h +++ b/src/global/ResourceLoader.h @@ -1,7 +1,7 @@ /* * \brief Handler to load and manage resources and resource files. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/ScopeGuard.cpp b/src/global/ScopeGuard.cpp index ca3c031f6..c682f014f 100644 --- a/src/global/ScopeGuard.cpp +++ b/src/global/ScopeGuard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ScopeGuard.h" diff --git a/src/global/ScopeGuard.h b/src/global/ScopeGuard.h index 957c5ee2a..d298542cc 100644 --- a/src/global/ScopeGuard.h +++ b/src/global/ScopeGuard.h @@ -1,7 +1,7 @@ /*! * \brief Calls a lambda once the object is destroyed * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -21,12 +21,12 @@ class [[deprecated ("Use qScopeGuard")]] ScopeGuard { private: friend class ::test_ScopeGuard; - friend ScopeGuard qScopeGuard(const std::function &pFunc); + friend ScopeGuard qScopeGuard(const std::function& pFunc); const std::function mFunction; bool mEnabled; - ScopeGuard(const std::function &pFunc, bool pEnabled = true); + ScopeGuard(const std::function& pFunc, bool pEnabled = true); bool isEnabled() const; void setEnabled(bool pEnabled = true); diff --git a/src/global/SingletonHelper.h b/src/global/SingletonHelper.h index b8223f338..643b32609 100644 --- a/src/global/SingletonHelper.h +++ b/src/global/SingletonHelper.h @@ -2,7 +2,7 @@ * \brief Helper to introduce a Singleton. * Be aware to use this helper in .cpp file only! * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/UsbId.cpp b/src/global/UsbId.cpp index fcb7c71ad..c200ca1f3 100644 --- a/src/global/UsbId.cpp +++ b/src/global/UsbId.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "UsbId.h" diff --git a/src/global/UsbId.h b/src/global/UsbId.h index 4efb841bc..956f4cd0a 100644 --- a/src/global/UsbId.h +++ b/src/global/UsbId.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/VersionInfo.cpp b/src/global/VersionInfo.cpp index 6aa06e255..6a34621b0 100644 --- a/src/global/VersionInfo.cpp +++ b/src/global/VersionInfo.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "VersionInfo.h" diff --git a/src/global/VersionInfo.h b/src/global/VersionInfo.h index 46e139f24..823698c18 100644 --- a/src/global/VersionInfo.h +++ b/src/global/VersionInfo.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/global/VersionNumber.cpp b/src/global/VersionNumber.cpp index 1edd5d57f..9cb67f557 100644 --- a/src/global/VersionNumber.cpp +++ b/src/global/VersionNumber.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "VersionNumber.h" diff --git a/src/global/VersionNumber.h b/src/global/VersionNumber.h index b8f50bc08..6b37782c5 100644 --- a/src/global/VersionNumber.h +++ b/src/global/VersionNumber.h @@ -1,7 +1,7 @@ /*! * \brief Extension to QVersionNumber. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/init/Bootstrap.cpp b/src/init/Bootstrap.cpp new file mode 100644 index 000000000..afb28d8ca --- /dev/null +++ b/src/init/Bootstrap.cpp @@ -0,0 +1,175 @@ +/* + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany + */ + +#include "Bootstrap.h" + +#include "BuildHelper.h" +#include "controller/AppController.h" +#include "CommandLineParser.h" +#include "LogHandler.h" +#include "SignalHandler.h" + +#include + +#include +#include +#include +#include +#include + +#include "config.h" + +using namespace governikus; + +Q_DECLARE_LOGGING_CATEGORY(init) + + +#if defined(INTEGRATED_SDK) + #ifdef Q_OS_ANDROID + #include +using QAPP = QAndroidService; + + #else + #include +using QAPP = QCoreApplication; + #endif + +#elif defined(Q_OS_ANDROID) || defined(Q_OS_IOS) || defined(Q_OS_WINRT) + #ifdef Q_OS_ANDROID + #include + #include + #endif + + #include +using QAPP = QGuiApplication; +#else + #include +using QAPP = QApplication; +#endif + + +static inline void printInfo() +{ + qCDebug(init) << "Logging to" << *Env::getSingleton(); + + qCInfo(init) << "##################################################"; + const auto& info = BuildHelper::getInformationHeader(); + for (const auto& entry : info) + { + qCInfo(init).noquote().nospace() << "### " << entry.first << ": " << entry.second; + } + qCInfo(init) << "##################################################"; + + #if OPENSSL_VERSION_NUMBER < 0x10100000L + #define OpenSSL_version SSLeay_version + #define OPENSSL_VERSION SSLEAY_VERSION + #endif + + if (QSslSocket::sslLibraryVersionString() != QLatin1String(OpenSSL_version(OPENSSL_VERSION))) + { + qCWarning(init) << "Linked OpenSSL Version differs:" << OpenSSL_version(OPENSSL_VERSION); + } + + const auto libPathes = QCoreApplication::libraryPaths(); + for (const auto& path : libPathes) + { + qCDebug(init) << "Library path:" << path; + } +} + + +static inline QCoreApplication* initQt(int& argc, char** argv) +{ +#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) + QCoreApplication::setAttribute(Qt::AA_DisableWindowContextHelpButton); +#endif +#if defined(Q_OS_ANDROID) || defined(Q_OS_IOS) + QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling); +#endif + + QCoreApplication::setOrganizationName(QStringLiteral(VENDOR)); + QCoreApplication::setOrganizationDomain(QStringLiteral(VENDOR_DOMAIN)); + QCoreApplication::setApplicationName(QStringLiteral(PRODUCT)); + QCoreApplication::setApplicationVersion(QStringLiteral(VERSION)); + +#ifndef INTEGRATED_SDK + QGuiApplication::setQuitOnLastWindowClosed(false); +#endif + +#if defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID) && !defined(INTEGRATED_SDK) + QGuiApplication::setDesktopSettingsAware(false); +#endif + +#if defined(Q_OS_ANDROID) && !defined(INTEGRATED_SDK) + if (QtAndroid::androidService().isValid()) + { + return new QAndroidService(argc, argv); + } +#endif + + return new QAPP(argc, argv); +} + + +#if defined(Q_OS_WIN) || defined(Q_OS_MACOS) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) +static void restartApp(const QString& pApplicationFilePath, QStringList pArgumentList, int pArgc) +{ + if (pArgumentList.size() == pArgc) + { + pArgumentList.removeFirst(); + } + + pArgumentList << QStringLiteral("--show"); + + qCInfo(init) << "Attempting to start new process:" << pApplicationFilePath << ", args:" << pArgumentList; + qint64 pid = -1; + const bool restartSuccessful = QProcess::startDetached(pApplicationFilePath, pArgumentList, QString(), &pid); + + if (restartSuccessful) + { + qCInfo(init) << "New process successfully launched, PID:" << pid; + } + else + { + qCCritical(init) << "Could not launch new process."; + } +} + + +#endif + +int governikus::initApp(int& argc, char** argv) +{ + const QScopedPointer app(initQt(argc, argv)); + QThread::currentThread()->setObjectName(QStringLiteral("MainThread")); + + CommandLineParser::getInstance().parse(); + Env::getSingleton()->init(); + SignalHandler::getInstance().init(); + printInfo(); + + AppController controller; + if (!controller.start()) + { + qCCritical(init) << "Cannot start application controller, exit application"; + return EXIT_FAILURE; + } + + SignalHandler::getInstance().setController(controller); + if (SignalHandler::getInstance().shouldQuit()) + { + return EXIT_SUCCESS; + } + + const int returnCode = app->exec(); + +#if defined(Q_OS_WIN) || defined(Q_OS_MACOS) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) + if (controller.shouldApplicationRestart()) + { + restartApp(app->applicationFilePath(), app->arguments(), argc); + } +#endif + + return returnCode; +} diff --git a/src/init/Bootstrap.h b/src/init/Bootstrap.h new file mode 100644 index 000000000..6d9edab60 --- /dev/null +++ b/src/init/Bootstrap.h @@ -0,0 +1,12 @@ +/*! + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +#pragma once + +namespace governikus +{ + +int initApp(int& argc, char** argv); + +} // namespace governikus diff --git a/src/init/CMakeLists.txt b/src/init/CMakeLists.txt new file mode 100644 index 000000000..922aeb17e --- /dev/null +++ b/src/init/CMakeLists.txt @@ -0,0 +1,35 @@ +##################################################################### +# The module init is responsible to bootstrap the appplication. +##################################################################### + +ADD_PLATFORM_LIBRARY(AusweisAppInit) + +TARGET_LINK_LIBRARIES(AusweisAppInit Qt5::Core OpenSSL::Crypto AusweisAppGlobal AusweisAppCore) + +IF(NOT INTEGRATED_SDK) + TARGET_LINK_LIBRARIES(AusweisAppInit Qt5::Gui) # QGuiApplication + IF(DESKTOP) + TARGET_LINK_LIBRARIES(AusweisAppInit Qt5::Widgets) # QApplication + ENDIF() +ENDIF() + + +FUNCTION(CONFIGURE_CONFIG_H) + IF(VENDOR_GOVERNIKUS) + SET(VENDOR_DOMAIN governikus.com) + ELSE() + SET(VENDOR_DOMAIN) + ENDIF() + + IF(VERSION_DVCS) + SET(VERSION ${VERSION_DVCS}) + ELSE() + SET(VERSION ${PROJECT_VERSION}) + ENDIF() + + SET(PRODUCT ${PROJECT_NAME}) + + CONFIGURE_FILE(config.h.in config.h @ONLY) +ENDFUNCTION() + +CONFIGURE_CONFIG_H() diff --git a/src/CommandLineParser.cpp b/src/init/CommandLineParser.cpp similarity index 96% rename from src/CommandLineParser.cpp rename to src/init/CommandLineParser.cpp index fa7a4b36c..31c861f1a 100644 --- a/src/CommandLineParser.cpp +++ b/src/init/CommandLineParser.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CommandLineParser.h" @@ -27,8 +27,8 @@ defineSingleton(CommandLineParser) CommandLineParser::CommandLineParser() : mParser() - , mOptionKeepLog(QStringLiteral("keep"), QStringLiteral("Keep log file.")) - , mOptionNoLogFile(QStringLiteral("no-logfile"), QStringLiteral("Disable log file.")) + , mOptionKeepLog(QStringLiteral("keep"), QStringLiteral("Keep logfile.")) + , mOptionNoLogFile(QStringLiteral("no-logfile"), QStringLiteral("Disable logfile.")) , mOptionNoLogHandler(QStringLiteral("no-loghandler"), QStringLiteral("Disable default log handler.")) , mOptionShowWindow(QStringLiteral("show"), QStringLiteral("Show window on startup.")) , mOptionProxy(QStringLiteral("no-proxy"), QStringLiteral("Disable system proxy.")) diff --git a/src/CommandLineParser.h b/src/init/CommandLineParser.h similarity index 92% rename from src/CommandLineParser.h rename to src/init/CommandLineParser.h index de2a0c945..c76f9302d 100644 --- a/src/CommandLineParser.h +++ b/src/init/CommandLineParser.h @@ -1,7 +1,7 @@ /* * \brief Provides and parses command line options. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/core/SignalHandler.cpp b/src/init/SignalHandler.cpp similarity index 95% rename from src/core/SignalHandler.cpp rename to src/init/SignalHandler.cpp index a2949211c..95b5c7485 100644 --- a/src/core/SignalHandler.cpp +++ b/src/init/SignalHandler.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SignalHandler.h" diff --git a/src/core/SignalHandler.h b/src/init/SignalHandler.h similarity index 93% rename from src/core/SignalHandler.h rename to src/init/SignalHandler.h index 8cfa18bb9..02efff09a 100644 --- a/src/core/SignalHandler.h +++ b/src/init/SignalHandler.h @@ -1,7 +1,7 @@ /* * \brief Implements signal handler for unix and windows. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -11,8 +11,8 @@ #include #if defined(Q_OS_UNIX) && !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) +#include #include -#include #elif defined(Q_OS_WIN) #include #endif diff --git a/src/core/SignalHandler_bsd_linux_osx.cpp b/src/init/SignalHandler_bsd_linux_osx.cpp similarity index 96% rename from src/core/SignalHandler_bsd_linux_osx.cpp rename to src/init/SignalHandler_bsd_linux_osx.cpp index 819315b1e..8206c4817 100644 --- a/src/core/SignalHandler_bsd_linux_osx.cpp +++ b/src/init/SignalHandler_bsd_linux_osx.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "SignalHandler.h" diff --git a/src/core/SignalHandler_win.cpp b/src/init/SignalHandler_win.cpp similarity index 86% rename from src/core/SignalHandler_win.cpp rename to src/init/SignalHandler_win.cpp index 64ad3cc67..fb482c0c1 100644 --- a/src/core/SignalHandler_win.cpp +++ b/src/init/SignalHandler_win.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "SignalHandler.h" diff --git a/src/config.h.in b/src/init/config.h.in similarity index 72% rename from src/config.h.in rename to src/init/config.h.in index b420c0e28..90ac9c45b 100644 --- a/src/config.h.in +++ b/src/init/config.h.in @@ -1,10 +1,11 @@ /* DO NOT TOUCH THIS MANUALLY */ -#cmakedefine ANDROID_BUILD_AAR +#cmakedefine INTEGRATED_SDK #define PRODUCT "@PRODUCT@" #define VENDOR "@VENDOR@" #define VENDOR_DOMAIN "@VENDOR_DOMAIN@" +#define COPYRIGHT_TEXT "@COPYRIGHT_TEXT@" #define VERSION "@VERSION@" #define VERSION_MAJOR @PROJECT_VERSION_MAJOR@ @@ -36,7 +37,13 @@ constexpr const char* stripPath(const char* pPath) } -static_assert(std::string_view(stripPath(__BASE_FILE__)) == "main.cpp", "config.h include is allowed in main.cpp only!"); +constexpr std::string_view currentFile() +{ + return std::string_view(stripPath(__BASE_FILE__)); +} + + +static_assert(currentFile() == "Bootstrap.cpp" || currentFile() == "main.cpp", "config.h include is allowed in Bootstrap.cpp and main.cpp only!"); #endif #endif // RC_INVOKED diff --git a/src/main.cpp b/src/main.cpp index 54c9c789f..077c558a7 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1,43 +1,14 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ -#include "controller/AppController.h" -#include "CommandLineParser.h" -#include "global/BuildHelper.h" -#include "global/LogHandler.h" -#include "SignalHandler.h" +#include "Bootstrap.h" -#include // version API +#include "init/config.h" -#include -#include -#include -#include #include -#include -#include "config.h" // use in main only! - -#ifdef ANDROID_BUILD_AAR - #include - #define QAPP QAndroidService - -#elif defined(Q_OS_ANDROID) || defined(Q_OS_IOS) || defined(Q_OS_WINRT) - #ifdef Q_OS_ANDROID - #include - #include - #endif - - #include - #define QAPP QGuiApplication -#else - #include - #define QAPP QApplication -#endif - - -#if !defined(Q_OS_WINRT) && !defined(ANDROID_BUILD_AAR) +#if !defined(Q_OS_WINRT) && !defined(INTEGRATED_SDK) Q_IMPORT_PLUGIN(RemoteReaderManagerPlugIn) #endif @@ -46,12 +17,10 @@ Q_IMPORT_PLUGIN(PcscReaderManagerPlugIn) Q_IMPORT_PLUGIN(WebserviceActivationHandler) #endif -Q_IMPORT_PLUGIN(InternalActivationHandler) - #if defined(Q_OS_ANDROID) Q_IMPORT_PLUGIN(NfcReaderManagerPlugIn) -#ifndef ANDROID_BUILD_AAR +#ifndef INTEGRATED_SDK Q_IMPORT_PLUGIN(IntentActivationHandler) #endif @@ -84,7 +53,7 @@ Q_IMPORT_PLUGIN(QtQuick2WindowPlugin) Q_IMPORT_PLUGIN(QtQuick2Plugin) #endif -#if (defined(Q_OS_ANDROID) && !defined(ANDROID_BUILD_AAR)) || defined(Q_OS_IOS) || (defined(Q_OS_LINUX) && !defined(QT_NO_DEBUG) && !defined(ANDROID_BUILD_AAR)) +#if (defined(Q_OS_ANDROID) && !defined(INTEGRATED_SDK)) || defined(Q_OS_IOS) || (defined(Q_OS_LINUX) && !defined(QT_NO_DEBUG) && !defined(INTEGRATED_SDK)) Q_IMPORT_PLUGIN(BluetoothReaderManagerPlugIn) #endif @@ -93,142 +62,24 @@ Q_IMPORT_PLUGIN(BluetoothReaderManagerPlugIn) Q_IMPORT_PLUGIN(UIPlugInWidgets) #endif -#if defined(Q_OS_ANDROID) || defined(Q_OS_IOS) || !defined(QT_NO_DEBUG) +#if defined(Q_OS_ANDROID) || !defined(QT_NO_DEBUG) Q_IMPORT_PLUGIN(UIPlugInAidl) #endif -#ifndef ANDROID_BUILD_AAR +#ifndef INTEGRATED_SDK Q_IMPORT_PLUGIN(UIPlugInQml) #endif -Q_IMPORT_PLUGIN(UIPlugInJson) +#if !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) && !defined(INTEGRATED_SDK) Q_IMPORT_PLUGIN(UIPlugInWebSocket) - - -using namespace governikus; - -Q_DECLARE_LOGGING_CATEGORY(init) - - -static inline void printInfo() -{ - qCDebug(init) << "Logging to" << *Env::getSingleton(); - - qCInfo(init) << "##################################################"; - const auto& info = BuildHelper::getInformationHeader(); - for (const auto& entry : info) - { - qCInfo(init).noquote().nospace() << "### " << entry.first << ": " << entry.second; - } - qCInfo(init) << "##################################################"; - - #if OPENSSL_VERSION_NUMBER < 0x10100000L - #define OpenSSL_version SSLeay_version - #define OPENSSL_VERSION SSLEAY_VERSION - #endif - - if (QSslSocket::sslLibraryVersionString() != QLatin1String(OpenSSL_version(OPENSSL_VERSION))) - { - qCWarning(init) << "Linked OpenSSL Version differs:" << OpenSSL_version(OPENSSL_VERSION); - } - - const auto libPathes = QCoreApplication::libraryPaths(); - for (const auto& path : libPathes) - { - qCDebug(init) << "Library path:" << path; - } -} - - -static inline QCoreApplication* initQt(int& argc, char** argv) -{ -#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) - QCoreApplication::setAttribute(Qt::AA_DisableWindowContextHelpButton); #endif -#if defined(Q_OS_ANDROID) || defined(Q_OS_IOS) - QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling); -#endif - - QCoreApplication::setOrganizationName(QStringLiteral(VENDOR)); - QCoreApplication::setOrganizationDomain(QStringLiteral(VENDOR_DOMAIN)); - QCoreApplication::setApplicationName(QStringLiteral(PRODUCT)); - QCoreApplication::setApplicationVersion(QStringLiteral(VERSION)); - -#ifndef ANDROID_BUILD_AAR - QGuiApplication::setQuitOnLastWindowClosed(false); -#endif - -#if defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID) - QGuiApplication::setDesktopSettingsAware(false); -#endif - -#if defined(Q_OS_ANDROID) && !defined(ANDROID_BUILD_AAR) - if (QtAndroid::androidService().isValid()) - { - return new QAndroidService(argc, argv); - } -#endif - - return new QAPP(argc, argv); -} - - -#if defined(Q_OS_WIN) || defined(Q_OS_MACOS) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) -void restartApp(const QString& pApplicationFilePath, QStringList pArgumentList, int pArgc) -{ - if (pArgumentList.size() == pArgc) - { - pArgumentList.removeFirst(); - } - - qCInfo(init) << "Attempting to start new process:" << pApplicationFilePath << ", args:" << pArgumentList; - qint64 pid = -1; - const bool restartSuccessful = QProcess::startDetached(pApplicationFilePath, pArgumentList, QString(), &pid); - - if (restartSuccessful) - { - qCInfo(init) << "New process successfully launched, PID:" << pid; - } - else - { - qCCritical(init) << "Could not launch new process."; - } -} - +#if !defined(Q_OS_IOS) || defined(INTEGRATED_SDK) +Q_IMPORT_PLUGIN(InternalActivationHandler) +Q_IMPORT_PLUGIN(UIPlugInJson) #endif Q_DECL_EXPORT int main(int argc, char** argv) { - const QScopedPointer app(initQt(argc, argv)); - QThread::currentThread()->setObjectName(QStringLiteral("MainThread")); - - CommandLineParser::getInstance().parse(); - Env::getSingleton()->init(); - SignalHandler::getInstance().init(); - printInfo(); - - AppController controller; - if (!controller.start()) - { - qCCritical(init) << "Cannot start application controller, exit application"; - return EXIT_FAILURE; - } - - SignalHandler::getInstance().setController(controller); - if (SignalHandler::getInstance().shouldQuit()) - { - return EXIT_SUCCESS; - } - - const int returnCode = app->exec(); - -#if defined(Q_OS_WIN) || defined(Q_OS_MACOS) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) - if (controller.shouldApplicationRestart()) - { - restartApp(app->applicationFilePath(), app->arguments(), argc); - } -#endif - - return returnCode; + return governikus::initApp(argc, argv); } diff --git a/src/network/DatagramHandler.cpp b/src/network/DatagramHandler.cpp index 0dada3f14..daa9df788 100644 --- a/src/network/DatagramHandler.cpp +++ b/src/network/DatagramHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "DatagramHandler.h" diff --git a/src/network/DatagramHandler.h b/src/network/DatagramHandler.h index d427f11a2..d346dcf8c 100644 --- a/src/network/DatagramHandler.h +++ b/src/network/DatagramHandler.h @@ -1,7 +1,7 @@ /*! * \brief Provides an interface to send and receive datagrams over UDP. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/DatagramHandlerImpl.cpp b/src/network/DatagramHandlerImpl.cpp index cb220ac9b..e592170ee 100644 --- a/src/network/DatagramHandlerImpl.cpp +++ b/src/network/DatagramHandlerImpl.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "DatagramHandlerImpl.h" @@ -107,6 +107,15 @@ bool DatagramHandlerImpl::sendToAllAddressEntries(const QByteArray& pData, quint { bool skipFurtherIPv6AddressesOnThisInterface = false; +#ifdef Q_OS_MACOS + // Excluding not documented interface of the T2 Coprocessor on macOS, which does not accept broadcasts. + // https://duo.com/labs/research/apple-t2-xpc + if (interface.hardwareAddress().toLower() == QLatin1String("ac:de:48:00:11:22")) + { + continue; + } +#endif + const auto& entries = interface.addressEntries(); for (const QNetworkAddressEntry& addressEntry : entries) { @@ -162,16 +171,17 @@ bool DatagramHandlerImpl::sendToAllAddressEntries(const QByteArray& pData, quint return false; } + bool broadcastedSuccessfully = true; for (const QHostAddress& broadcastAddr : qAsConst(broadcastAddresses)) { if (!sendToAddress(pData, broadcastAddr, pPort)) { qCDebug(network) << "Broadcasting to" << broadcastAddr << "failed"; - return false; + broadcastedSuccessfully = false; } } - return true; + return broadcastedSuccessfully; } diff --git a/src/network/DatagramHandlerImpl.h b/src/network/DatagramHandlerImpl.h index dbed4f0a1..085a04ba7 100644 --- a/src/network/DatagramHandlerImpl.h +++ b/src/network/DatagramHandlerImpl.h @@ -1,7 +1,7 @@ /*! * \brief Provides an UDP socket to send and receive datagrams. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/HttpRequest.cpp b/src/network/HttpRequest.cpp index e0fb2920d..96dc067f5 100644 --- a/src/network/HttpRequest.cpp +++ b/src/network/HttpRequest.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "HttpRequest.h" diff --git a/src/network/HttpRequest.h b/src/network/HttpRequest.h index 7556ed5e0..f8ad757be 100644 --- a/src/network/HttpRequest.h +++ b/src/network/HttpRequest.h @@ -1,7 +1,7 @@ /*! * \brief Class to parse http request. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/HttpResponse.cpp b/src/network/HttpResponse.cpp index 85e6eb6b9..be8d47132 100644 --- a/src/network/HttpResponse.cpp +++ b/src/network/HttpResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "HttpResponse.h" diff --git a/src/network/HttpResponse.h b/src/network/HttpResponse.h index 7ed9e45fc..6bfb2d7df 100644 --- a/src/network/HttpResponse.h +++ b/src/network/HttpResponse.h @@ -1,7 +1,7 @@ /*! * \brief Class to create http response. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/HttpServer.cpp b/src/network/HttpServer.cpp index c88d25760..0b7926e0a 100644 --- a/src/network/HttpServer.cpp +++ b/src/network/HttpServer.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "HttpServer.h" diff --git a/src/network/HttpServer.h b/src/network/HttpServer.h index a362f004c..c57528842 100644 --- a/src/network/HttpServer.h +++ b/src/network/HttpServer.h @@ -1,7 +1,7 @@ /*! * \brief Provide a HTTP server. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/HttpServerRequestor.cpp b/src/network/HttpServerRequestor.cpp index ed4a24ca7..08dda19cb 100644 --- a/src/network/HttpServerRequestor.cpp +++ b/src/network/HttpServerRequestor.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "HttpServerRequestor.h" diff --git a/src/network/HttpServerRequestor.h b/src/network/HttpServerRequestor.h index a9caefe13..5f6df1ad4 100644 --- a/src/network/HttpServerRequestor.h +++ b/src/network/HttpServerRequestor.h @@ -1,7 +1,7 @@ /* * \brief Sends one time GET requests to server. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/HttpServerStatusParser.cpp b/src/network/HttpServerStatusParser.cpp index aa9814b31..d8da8319d 100644 --- a/src/network/HttpServerStatusParser.cpp +++ b/src/network/HttpServerStatusParser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "HttpServerStatusParser.h" diff --git a/src/network/HttpServerStatusParser.h b/src/network/HttpServerStatusParser.h index dabf4eff5..9690c72b3 100644 --- a/src/network/HttpServerStatusParser.h +++ b/src/network/HttpServerStatusParser.h @@ -1,7 +1,7 @@ /*! * \brief Sends a status request to given url:port and tries to detect details and server header. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/MulticastLock.cpp b/src/network/MulticastLock.cpp index 765dfee17..3bea0525e 100644 --- a/src/network/MulticastLock.cpp +++ b/src/network/MulticastLock.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "MulticastLock.h" diff --git a/src/network/MulticastLock.h b/src/network/MulticastLock.h index 92cc984e8..60e67ee77 100644 --- a/src/network/MulticastLock.h +++ b/src/network/MulticastLock.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/MulticastLockJniBridgeUtil.java b/src/network/MulticastLockJniBridgeUtil.java index 808f1205a..62fbf8e22 100644 --- a/src/network/MulticastLockJniBridgeUtil.java +++ b/src/network/MulticastLockJniBridgeUtil.java @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ package com.governikus.ausweisapp2; @@ -25,7 +25,7 @@ public static synchronized void acquire(Context pContext) { if (cLock == null) { - WifiManager wifi = (WifiManager) pContext.getSystemService(Context.WIFI_SERVICE); + WifiManager wifi = (WifiManager) pContext.getApplicationContext().getSystemService(Context.WIFI_SERVICE); cLock = wifi.createMulticastLock("AusweisApp2"); cLock.setReferenceCounted(true); } diff --git a/src/network/NetworkManager.cpp b/src/network/NetworkManager.cpp index decc0f507..758550eed 100644 --- a/src/network/NetworkManager.cpp +++ b/src/network/NetworkManager.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "NetworkManager.h" diff --git a/src/network/NetworkManager.h b/src/network/NetworkManager.h index 17b863143..c980017cd 100644 --- a/src/network/NetworkManager.h +++ b/src/network/NetworkManager.h @@ -1,7 +1,7 @@ /* * \brief Wrapper around QNetworkAccessManager * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/NetworkReplyError.cpp b/src/network/NetworkReplyError.cpp index 508315035..d77d29e92 100644 --- a/src/network/NetworkReplyError.cpp +++ b/src/network/NetworkReplyError.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "NetworkReplyError.h" diff --git a/src/network/NetworkReplyError.h b/src/network/NetworkReplyError.h index 6df94bf90..7d24774e5 100644 --- a/src/network/NetworkReplyError.h +++ b/src/network/NetworkReplyError.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/NetworkReplyTimeout.cpp b/src/network/NetworkReplyTimeout.cpp index 8c32a9375..f70fdfd1a 100644 --- a/src/network/NetworkReplyTimeout.cpp +++ b/src/network/NetworkReplyTimeout.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "NetworkReplyTimeout.h" diff --git a/src/network/NetworkReplyTimeout.h b/src/network/NetworkReplyTimeout.h index 2fd447cd5..dc7432bba 100644 --- a/src/network/NetworkReplyTimeout.h +++ b/src/network/NetworkReplyTimeout.h @@ -1,7 +1,7 @@ /*! * \brief Utility class to set a timeout on a QNetworkReply * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/PortFile.cpp b/src/network/PortFile.cpp index 0398560f9..888640069 100644 --- a/src/network/PortFile.cpp +++ b/src/network/PortFile.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "PortFile.h" diff --git a/src/network/PortFile.h b/src/network/PortFile.h index 91abb3b61..dd6d0e270 100644 --- a/src/network/PortFile.h +++ b/src/network/PortFile.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/TlsChecker.cpp b/src/network/TlsChecker.cpp index 9e28308f6..2f96d49e0 100644 --- a/src/network/TlsChecker.cpp +++ b/src/network/TlsChecker.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "TlsChecker.h" diff --git a/src/network/TlsChecker.h b/src/network/TlsChecker.h index daf07de16..4da4a9d9c 100644 --- a/src/network/TlsChecker.h +++ b/src/network/TlsChecker.h @@ -1,7 +1,7 @@ /*! * \brief Helper to check certificates and other security stuff of TLS/SSL. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/UrlUtil.cpp b/src/network/UrlUtil.cpp index 2796e7fd8..792f621e9 100644 --- a/src/network/UrlUtil.cpp +++ b/src/network/UrlUtil.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/network/UrlUtil.h b/src/network/UrlUtil.h index 35a0c23cd..8947a76fe 100644 --- a/src/network/UrlUtil.h +++ b/src/network/UrlUtil.h @@ -1,6 +1,6 @@ /*! * \brief Helper to convert \ref Result to Redirect-Result-String and some other URL stuff. - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/network/WifiInfo.cpp b/src/network/WifiInfo.cpp index d6173a551..e0b6dc429 100644 --- a/src/network/WifiInfo.cpp +++ b/src/network/WifiInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "WifiInfo.h" @@ -16,7 +16,8 @@ bool WifiInfo::isPrivateIp(const QHostAddress& pAddress) ( pAddress.isInSubnet(QHostAddress::parseSubnet(QStringLiteral("10.0.0.0/8"))) || pAddress.isInSubnet(QHostAddress::parseSubnet(QStringLiteral("172.16.0.0/12"))) || - pAddress.isInSubnet(QHostAddress::parseSubnet(QStringLiteral("192.168.0.0/16"))) + pAddress.isInSubnet(QHostAddress::parseSubnet(QStringLiteral("192.168.0.0/16"))) || + pAddress.isInSubnet(QHostAddress::parseSubnet(QStringLiteral("fd00::/8"))) ); } diff --git a/src/network/WifiInfo.h b/src/network/WifiInfo.h index 4e3b6cc89..5bd748ec6 100644 --- a/src/network/WifiInfo.h +++ b/src/network/WifiInfo.h @@ -1,7 +1,7 @@ /*! * \brief Provides information about the Wifi status * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ @@ -24,13 +24,11 @@ class WifiInfo friend class ::test_WifiInfo; bool mWifiEnabled; int mWifiCheckTimerId; - int mWifiEnableWaitCounter; static bool isPrivateIp(const QHostAddress& pAddress); static bool hasPrivateIpAddress(); bool getCurrentWifiEnabled(); - bool shouldWifiEnabledBeCalled(); protected: void timerEvent(QTimerEvent* pEvent) override; @@ -40,11 +38,9 @@ class WifiInfo virtual ~WifiInfo() override = default; bool isWifiEnabled(); - void enableWifi(); Q_SIGNALS: void fireWifiEnabledChanged(bool pEnabled); - }; diff --git a/src/network/WifiInfo.java b/src/network/WifiInfo.java index 0cdc55eb6..b7ae9b5c0 100644 --- a/src/network/WifiInfo.java +++ b/src/network/WifiInfo.java @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ package com.governikus.ausweisapp2; @@ -17,7 +17,7 @@ private WifiInfo() public static boolean wifiEnabled(Context pContext) { WifiManager wifi; - wifi = (WifiManager) pContext.getSystemService(Context.WIFI_SERVICE); + wifi = (WifiManager) pContext.getApplicationContext().getSystemService(Context.WIFI_SERVICE); switch (wifi.getWifiState()) { @@ -31,14 +31,4 @@ public static boolean wifiEnabled(Context pContext) } - public static boolean enableWifi(Context pContext) - { - WifiManager wifi; - wifi = (WifiManager) pContext.getSystemService(Context.WIFI_SERVICE); - - wifi.setWifiEnabled(true); - return true; - } - - } diff --git a/src/network/WifiInfo_android.cpp b/src/network/WifiInfo_android.cpp index 32a45598b..d81b1272e 100644 --- a/src/network/WifiInfo_android.cpp +++ b/src/network/WifiInfo_android.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "WifiInfo.h" @@ -19,7 +19,6 @@ using namespace governikus; WifiInfo::WifiInfo() : QObject() , mWifiEnabled(getCurrentWifiEnabled()) - , mWifiEnableWaitCounter(0) { const int timeoutMs = 1000; mWifiCheckTimerId = startTimer(timeoutMs); @@ -53,57 +52,15 @@ bool WifiInfo::getCurrentWifiEnabled() } -void WifiInfo::enableWifi() -{ - if (mWifiEnabled) - { - return; - } - - QAndroidJniEnvironment env; - const QAndroidJniObject context(QtAndroid::androidContext()); - if (!context.isValid()) - { - qCCritical(qml) << "Cannot determine android context."; - return; - } - - const jboolean jSuccess = QAndroidJniObject::callStaticMethod("com/governikus/ausweisapp2/WifiInfo", - "enableWifi", - "(Landroid/content/Context;)Z", - context.object()); - - qCDebug(qml) << "enableWifi() returned:" << (jSuccess == JNI_TRUE); - - if (env->ExceptionCheck()) - { - qCCritical(qml) << "Cannot call WifiInfo.enableWifi()"; - env->ExceptionDescribe(); - env->ExceptionClear(); - return; - } - - if (jSuccess == JNI_TRUE) - { - mWifiEnabled = true; - mWifiEnableWaitCounter = 3; - Q_EMIT fireWifiEnabledChanged(true); - } -} - - void WifiInfo::timerEvent(QTimerEvent* pEvent) { if (pEvent->timerId() == mWifiCheckTimerId) { - if (shouldWifiEnabledBeCalled()) + const bool currentEnabled = getCurrentWifiEnabled() || hasPrivateIpAddress(); + if (mWifiEnabled != currentEnabled) { - const bool currentEnabled = getCurrentWifiEnabled() || hasPrivateIpAddress(); - if (mWifiEnabled != currentEnabled) - { - mWifiEnabled = currentEnabled; - Q_EMIT fireWifiEnabledChanged(mWifiEnabled); - } + mWifiEnabled = currentEnabled; + Q_EMIT fireWifiEnabledChanged(mWifiEnabled); } } @@ -111,18 +68,6 @@ void WifiInfo::timerEvent(QTimerEvent* pEvent) } -bool WifiInfo::shouldWifiEnabledBeCalled() -{ - if (mWifiEnableWaitCounter <= 0) - { - return true; - } - - --mWifiEnableWaitCounter; - return false; -} - - bool WifiInfo::isWifiEnabled() { return mWifiEnabled; diff --git a/src/network/WifiInfo_generic.cpp b/src/network/WifiInfo_generic.cpp index c11b28644..3800bc5b4 100644 --- a/src/network/WifiInfo_generic.cpp +++ b/src/network/WifiInfo_generic.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "WifiInfo.h" @@ -18,7 +18,6 @@ WifiInfo::WifiInfo() : QObject() , mWifiEnabled(getCurrentWifiEnabled()) , mWifiCheckTimerId(0) - , mWifiEnableWaitCounter(0) { } @@ -29,18 +28,6 @@ bool WifiInfo::getCurrentWifiEnabled() } -void WifiInfo::enableWifi() -{ -#ifndef QT_NO_DEBUG - if (!QCoreApplication::applicationName().startsWith(QLatin1String("QmlTest"))) - -#endif - { - qCWarning(qml) << "NOT IMPLEMENTED"; - } -} - - void WifiInfo::timerEvent(QTimerEvent* pEvent) { QObject::timerEvent(pEvent); diff --git a/src/network/WifiInfo_ios.mm b/src/network/WifiInfo_ios.mm index d911d77da..f06cbb3d1 100644 --- a/src/network/WifiInfo_ios.mm +++ b/src/network/WifiInfo_ios.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "WifiInfo.h" @@ -8,7 +8,8 @@ #include #import -#import +#import +#import #import Q_DECLARE_LOGGING_CATEGORY(qml) @@ -20,7 +21,6 @@ WifiInfo::WifiInfo() : QObject() , mWifiEnabled(getCurrentWifiEnabled()) - , mWifiEnableWaitCounter(0) { const int timeoutMs = 1000; mWifiCheckTimerId = startTimer(timeoutMs); @@ -29,26 +29,44 @@ bool WifiInfo::getCurrentWifiEnabled() { - // https://stackoverflow.com/a/25963050 - Boolean networkInterfaceAvailable = false; - NSArray* interfaces = CFBridgingRelease(CNCopySupportedInterfaces()); - for (NSString* interface in interfaces) + struct ifaddrs* interfaces; + if (!getifaddrs(&interfaces)) { - NSDictionary* networkInfo = CFBridgingRelease(CNCopyCurrentNetworkInfo(reinterpret_cast(interface))); - if (networkInfo != nullptr) + + int en0Count = 0; + int awdl0Count = 0; + + for (struct ifaddrs* interface = interfaces; interface != nullptr; interface = interface->ifa_next) { - networkInterfaceAvailable = true; - break; + if (!(interface->ifa_flags & IFF_UP)) + { + continue; + } + + if (std::strcmp(interface->ifa_name, "en0") == 0) + { + ++en0Count; + } + else if (std::strcmp(interface->ifa_name, "awdl0") == 0) + { + ++awdl0Count; + } } - } - return networkInterfaceAvailable; -} + freeifaddrs(interfaces); -void WifiInfo::enableWifi() -{ - // While it is possible to do this programmatically using private APIs, Apple will reject apps that do this. - qCWarning(qml) << "NOT IMPLEMENTED"; + // iOS doesn't provide an api to determine if wifi is enabled/connected + // On iOS 13 and hopefully later, we can, however, use the network interfaces to + // infer this in an undocumented hacky way: + // If there is more than one interface with the name "awdl0" it means wifi is enabled. + // If there is more than one interface with the name "en0" it means wifi is connected. + if (awdl0Count > 1 || en0Count > 1) // Enabled or connected + { + return true; + } + } + + return false; } diff --git a/src/remote_device/DataChannel.cpp b/src/remote_device/DataChannel.cpp index 2f9a90d94..cf47569ae 100644 --- a/src/remote_device/DataChannel.cpp +++ b/src/remote_device/DataChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "DataChannel.h" diff --git a/src/remote_device/DataChannel.h b/src/remote_device/DataChannel.h index dc08f234b..30de901b8 100644 --- a/src/remote_device/DataChannel.h +++ b/src/remote_device/DataChannel.h @@ -2,7 +2,7 @@ * \brief Interface modelling a component that can send and receive data blocks in the form * of QByteArray objects. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteClient.cpp b/src/remote_device/RemoteClient.cpp index 4aef4559d..db2d05170 100644 --- a/src/remote_device/RemoteClient.cpp +++ b/src/remote_device/RemoteClient.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteClient.h" diff --git a/src/remote_device/RemoteClient.h b/src/remote_device/RemoteClient.h index 53ff617be..4d44e9ba9 100644 --- a/src/remote_device/RemoteClient.h +++ b/src/remote_device/RemoteClient.h @@ -2,7 +2,7 @@ * \brief An interface for RemoteClientImpl, meant to omit the * dependency between card_base and remote_device. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteClientImpl.cpp b/src/remote_device/RemoteClientImpl.cpp index 5b14b3e1b..c36b738f2 100644 --- a/src/remote_device/RemoteClientImpl.cpp +++ b/src/remote_device/RemoteClientImpl.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteClientImpl.h" diff --git a/src/remote_device/RemoteClientImpl.h b/src/remote_device/RemoteClientImpl.h index fa4c152d4..59cf2c6a7 100644 --- a/src/remote_device/RemoteClientImpl.h +++ b/src/remote_device/RemoteClientImpl.h @@ -1,7 +1,7 @@ /*! * \brief Send RemoteReaderDiscoverCmds and maintain a list of responsive peers. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteConnector.cpp b/src/remote_device/RemoteConnector.cpp index 57d631bbf..7772387b6 100644 --- a/src/remote_device/RemoteConnector.cpp +++ b/src/remote_device/RemoteConnector.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteConnector.h" diff --git a/src/remote_device/RemoteConnector.h b/src/remote_device/RemoteConnector.h index 5cddc4084..df01a7753 100644 --- a/src/remote_device/RemoteConnector.h +++ b/src/remote_device/RemoteConnector.h @@ -1,7 +1,7 @@ /*! * \brief Module that creates and manages connections from a remote client to a remote server. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteConnectorImpl.cpp b/src/remote_device/RemoteConnectorImpl.cpp index f74b8707e..a2e87ba10 100644 --- a/src/remote_device/RemoteConnectorImpl.cpp +++ b/src/remote_device/RemoteConnectorImpl.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteConnectorImpl.h" diff --git a/src/remote_device/RemoteConnectorImpl.h b/src/remote_device/RemoteConnectorImpl.h index 6d9978b2c..9332a2ece 100644 --- a/src/remote_device/RemoteConnectorImpl.h +++ b/src/remote_device/RemoteConnectorImpl.h @@ -1,7 +1,7 @@ /*! * \brief Module that creates and manages connections from a remote client to a remote server. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteDeviceDescriptor.cpp b/src/remote_device/RemoteDeviceDescriptor.cpp index 1632ae829..4696065cc 100644 --- a/src/remote_device/RemoteDeviceDescriptor.cpp +++ b/src/remote_device/RemoteDeviceDescriptor.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDeviceDescriptor.h" diff --git a/src/remote_device/RemoteDeviceDescriptor.h b/src/remote_device/RemoteDeviceDescriptor.h index 0419bcdcd..799826233 100644 --- a/src/remote_device/RemoteDeviceDescriptor.h +++ b/src/remote_device/RemoteDeviceDescriptor.h @@ -2,7 +2,7 @@ * \brief Information needed to display a remote device in the GUI and to open * a websocket connection to it. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteDeviceList.cpp b/src/remote_device/RemoteDeviceList.cpp index d0cfbf40b..49f6da457 100644 --- a/src/remote_device/RemoteDeviceList.cpp +++ b/src/remote_device/RemoteDeviceList.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDeviceList.h" diff --git a/src/remote_device/RemoteDeviceList.h b/src/remote_device/RemoteDeviceList.h index 80b8c62a3..2abfd9f0b 100644 --- a/src/remote_device/RemoteDeviceList.h +++ b/src/remote_device/RemoteDeviceList.h @@ -1,7 +1,7 @@ /*! * \brief Interface for RemoteDeviceList * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteDispatcher.cpp b/src/remote_device/RemoteDispatcher.cpp index b7114cb63..6f954a71f 100644 --- a/src/remote_device/RemoteDispatcher.cpp +++ b/src/remote_device/RemoteDispatcher.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDispatcher.h" diff --git a/src/remote_device/RemoteDispatcher.h b/src/remote_device/RemoteDispatcher.h index 646165eed..84b52f28f 100644 --- a/src/remote_device/RemoteDispatcher.h +++ b/src/remote_device/RemoteDispatcher.h @@ -3,7 +3,7 @@ * \brief An interface for RemoteHandleImpl, meant to omit the * dependency between card_base and remote_device. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteDispatcherClient.cpp b/src/remote_device/RemoteDispatcherClient.cpp index 265275b2a..04b7f707e 100644 --- a/src/remote_device/RemoteDispatcherClient.cpp +++ b/src/remote_device/RemoteDispatcherClient.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDispatcherClient.h" diff --git a/src/remote_device/RemoteDispatcherClient.h b/src/remote_device/RemoteDispatcherClient.h index 86f90db08..d4e1bf5ac 100644 --- a/src/remote_device/RemoteDispatcherClient.h +++ b/src/remote_device/RemoteDispatcherClient.h @@ -1,7 +1,7 @@ /*! * \brief Class that dispatches incoming and outgoing remote messages. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteDispatcherServer.cpp b/src/remote_device/RemoteDispatcherServer.cpp index 88d10ddac..d9d7c9b72 100644 --- a/src/remote_device/RemoteDispatcherServer.cpp +++ b/src/remote_device/RemoteDispatcherServer.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDispatcherServer.h" diff --git a/src/remote_device/RemoteDispatcherServer.h b/src/remote_device/RemoteDispatcherServer.h index 4cb42f4eb..89d838162 100644 --- a/src/remote_device/RemoteDispatcherServer.h +++ b/src/remote_device/RemoteDispatcherServer.h @@ -1,7 +1,7 @@ /*! * \brief Class that dispatches incoming and outgoing remote messages. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteReaderAdvertiser.cpp b/src/remote_device/RemoteReaderAdvertiser.cpp index 6da8167dd..bed200f9e 100644 --- a/src/remote_device/RemoteReaderAdvertiser.cpp +++ b/src/remote_device/RemoteReaderAdvertiser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteReaderAdvertiser.h" diff --git a/src/remote_device/RemoteReaderAdvertiser.h b/src/remote_device/RemoteReaderAdvertiser.h index ff86e8653..83796d32c 100644 --- a/src/remote_device/RemoteReaderAdvertiser.h +++ b/src/remote_device/RemoteReaderAdvertiser.h @@ -1,9 +1,9 @@ /*! - * \brief Component advertising the remote reader functionality - * on the server side. According to the concept this is done by - * sending the message REMOTE_READER_OFFER as a UDP broadcast. + * \brief Component advertising the smartphone as card reader (SaC) + * functionality on the server side. According to the concept this + * is done by sending the message REMOTE_READER_OFFER as a UDP broadcast. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteServer.cpp b/src/remote_device/RemoteServer.cpp index ac2af3eec..03f8ab35d 100644 --- a/src/remote_device/RemoteServer.cpp +++ b/src/remote_device/RemoteServer.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteServer.h" diff --git a/src/remote_device/RemoteServer.h b/src/remote_device/RemoteServer.h index 1e0775d6b..a3ae93ee6 100644 --- a/src/remote_device/RemoteServer.h +++ b/src/remote_device/RemoteServer.h @@ -1,8 +1,8 @@ /*! - * \brief Remote server service to offer remote readers. + * \brief Remote server service to offer smartphones as card readers (SaCs). * This class controls the advertising over UDP as well as the Websocket connection management. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -34,6 +34,7 @@ class RemoteServer virtual void stop() = 0; virtual void setPairing(bool pEnable = true) = 0; virtual bool isConnected() const = 0; + virtual bool isPairingConnection() const = 0; virtual QSslCertificate getCurrentCertificate() const = 0; virtual const QSharedPointer& getMessageHandler() const = 0; diff --git a/src/remote_device/RemoteServerImpl.cpp b/src/remote_device/RemoteServerImpl.cpp index ff1639d41..ab0fb4c1f 100644 --- a/src/remote_device/RemoteServerImpl.cpp +++ b/src/remote_device/RemoteServerImpl.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteServerImpl.h" @@ -89,6 +89,12 @@ bool RemoteServerImpl::isConnected() const } +bool RemoteServerImpl::isPairingConnection() const +{ + return mWebSocketServer->isPairingConnection(); +} + + QSslCertificate RemoteServerImpl::getCurrentCertificate() const { return mWebSocketServer->getCurrentCertificate(); diff --git a/src/remote_device/RemoteServerImpl.h b/src/remote_device/RemoteServerImpl.h index 609d22dcc..e907def58 100644 --- a/src/remote_device/RemoteServerImpl.h +++ b/src/remote_device/RemoteServerImpl.h @@ -1,8 +1,8 @@ /*! - * \brief Remote server service to offer remote readers. + * \brief Remote server service to offer smartphones as card readers (SaCs). * This class controls the advertising over UDP as well as the Websocket connection management. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -33,6 +33,7 @@ class RemoteServerImpl virtual void stop() override; virtual void setPairing(bool pEnable = true) override; virtual bool isConnected() const override; + virtual bool isPairingConnection() const override; virtual QSslCertificate getCurrentCertificate() const override; virtual const QSharedPointer& getMessageHandler() const override; }; diff --git a/src/remote_device/RemoteTlsServer.cpp b/src/remote_device/RemoteTlsServer.cpp index 3b54abdf3..f48f5728d 100644 --- a/src/remote_device/RemoteTlsServer.cpp +++ b/src/remote_device/RemoteTlsServer.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteTlsServer.h" diff --git a/src/remote_device/RemoteTlsServer.h b/src/remote_device/RemoteTlsServer.h index 6305c2cac..4892043ea 100644 --- a/src/remote_device/RemoteTlsServer.h +++ b/src/remote_device/RemoteTlsServer.h @@ -1,7 +1,7 @@ /*! * \brief QTcpServer with necessary TLS handling of remote device configuration. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/RemoteWebSocketServer.cpp b/src/remote_device/RemoteWebSocketServer.cpp index 0926f0cab..56e6401cd 100644 --- a/src/remote_device/RemoteWebSocketServer.cpp +++ b/src/remote_device/RemoteWebSocketServer.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteWebSocketServer.h" @@ -50,6 +50,10 @@ void RemoteWebSocketServerImpl::onWebsocketConnection() return; } + const auto& cfg = connection->sslConfiguration(); + const auto& pairingCiphers = Env::getSingleton()->getTlsConfigRemote(SecureStorage::TlsSuite::PSK).getCiphers(); + mPairingConnection = pairingCiphers.contains(cfg.sessionCipher()); + QSharedPointer channel(new WebSocketChannel(connection), &QObject::deleteLater); mServerMessageHandler.reset(Env::create(channel)); connect(mServerMessageHandler.data(), &ServerMessageHandler::fireClosed, this, &RemoteWebSocketServerImpl::onConnectionClosed); @@ -75,6 +79,7 @@ RemoteWebSocketServerImpl::RemoteWebSocketServerImpl() : mTlsServer(new RemoteTlsServer) , mServer(QString(), QWebSocketServer::NonSecureMode) , mServerMessageHandler() + , mPairingConnection(false) { connect(mTlsServer.data(), &RemoteTlsServer::newConnection, &mServer, &QWebSocketServer::handleConnection); connect(mTlsServer.data(), &RemoteTlsServer::firePskChanged, this, &RemoteWebSocketServer::firePskChanged); @@ -104,6 +109,12 @@ bool RemoteWebSocketServerImpl::isConnected() const } +bool RemoteWebSocketServerImpl::isPairingConnection() const +{ + return mPairingConnection; +} + + bool RemoteWebSocketServerImpl::listen(const QString& pServerName) { mServer.setServerName(pServerName); diff --git a/src/remote_device/RemoteWebSocketServer.h b/src/remote_device/RemoteWebSocketServer.h index aa125ee15..46cdce967 100644 --- a/src/remote_device/RemoteWebSocketServer.h +++ b/src/remote_device/RemoteWebSocketServer.h @@ -1,7 +1,7 @@ /*! - * \brief WebSocketServer on the server side of a remote reader scenario. + * \brief WebSocketServer on the server side of a smartphone as card reader (SaC) scenario. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -34,6 +34,7 @@ class RemoteWebSocketServer virtual bool isListening() const = 0; virtual bool isConnected() const = 0; + virtual bool isPairingConnection() const = 0; virtual bool listen(const QString& pServerName) = 0; virtual void close() = 0; virtual QString getServerName() const = 0; @@ -57,6 +58,7 @@ class RemoteWebSocketServerImpl QScopedPointer mTlsServer; QWebSocketServer mServer; QSharedPointer mServerMessageHandler; + bool mPairingConnection; private Q_SLOTS: void onWebsocketConnection(); @@ -69,6 +71,7 @@ class RemoteWebSocketServerImpl virtual bool isListening() const override; virtual bool isConnected() const override; + virtual bool isPairingConnection() const override; virtual bool listen(const QString& pServerName) override; virtual void close() override; virtual QString getServerName() const override; diff --git a/src/remote_device/ServerMessageHandler.cpp b/src/remote_device/ServerMessageHandler.cpp index 91ca40b2c..ca25f4f14 100644 --- a/src/remote_device/ServerMessageHandler.cpp +++ b/src/remote_device/ServerMessageHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ServerMessageHandler.h" diff --git a/src/remote_device/ServerMessageHandler.h b/src/remote_device/ServerMessageHandler.h index 788145b35..4def1cda2 100644 --- a/src/remote_device/ServerMessageHandler.h +++ b/src/remote_device/ServerMessageHandler.h @@ -1,7 +1,7 @@ /*! - * \brief Handler for messages on the server side of a remote reader scenario. + * \brief Handler for messages on the server side of a smartphone as card reader (SaC) scenario. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/WebSocketChannel.cpp b/src/remote_device/WebSocketChannel.cpp index bcf213de6..800c9a1bb 100644 --- a/src/remote_device/WebSocketChannel.cpp +++ b/src/remote_device/WebSocketChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "WebSocketChannel.h" diff --git a/src/remote_device/WebSocketChannel.h b/src/remote_device/WebSocketChannel.h index a0d8e8e0c..db8d9b9a6 100644 --- a/src/remote_device/WebSocketChannel.h +++ b/src/remote_device/WebSocketChannel.h @@ -1,7 +1,7 @@ /*! * \brief Implementation of DataChannel base on web sockets. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/Discovery.cpp b/src/remote_device/messages/Discovery.cpp index 785dd744f..e268e2a5e 100644 --- a/src/remote_device/messages/Discovery.cpp +++ b/src/remote_device/messages/Discovery.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/Discovery.h b/src/remote_device/messages/Discovery.h index 5e98a0754..a3e7f27f2 100644 --- a/src/remote_device/messages/Discovery.h +++ b/src/remote_device/messages/Discovery.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdConnect.cpp b/src/remote_device/messages/IfdConnect.cpp index b72243798..ca076d79c 100644 --- a/src/remote_device/messages/IfdConnect.cpp +++ b/src/remote_device/messages/IfdConnect.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdConnect.h b/src/remote_device/messages/IfdConnect.h index cef8f791f..4c33a809f 100644 --- a/src/remote_device/messages/IfdConnect.h +++ b/src/remote_device/messages/IfdConnect.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdConnectResponse.cpp b/src/remote_device/messages/IfdConnectResponse.cpp index a62528bd0..62fa13db2 100644 --- a/src/remote_device/messages/IfdConnectResponse.cpp +++ b/src/remote_device/messages/IfdConnectResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdConnectResponse.h b/src/remote_device/messages/IfdConnectResponse.h index e5d694341..e669bdd49 100644 --- a/src/remote_device/messages/IfdConnectResponse.h +++ b/src/remote_device/messages/IfdConnectResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdDisconnect.cpp b/src/remote_device/messages/IfdDisconnect.cpp index 965b52211..caf1b9990 100644 --- a/src/remote_device/messages/IfdDisconnect.cpp +++ b/src/remote_device/messages/IfdDisconnect.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdDisconnect.h b/src/remote_device/messages/IfdDisconnect.h index eacc5d357..0b0b5a4a9 100644 --- a/src/remote_device/messages/IfdDisconnect.h +++ b/src/remote_device/messages/IfdDisconnect.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdDisconnectResponse.cpp b/src/remote_device/messages/IfdDisconnectResponse.cpp index 62925a9eb..ac1a1d570 100644 --- a/src/remote_device/messages/IfdDisconnectResponse.cpp +++ b/src/remote_device/messages/IfdDisconnectResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdDisconnectResponse.h b/src/remote_device/messages/IfdDisconnectResponse.h index 042312e36..58740e185 100644 --- a/src/remote_device/messages/IfdDisconnectResponse.h +++ b/src/remote_device/messages/IfdDisconnectResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdError.cpp b/src/remote_device/messages/IfdError.cpp index 405c0b557..ebe958ea5 100644 --- a/src/remote_device/messages/IfdError.cpp +++ b/src/remote_device/messages/IfdError.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdError.h b/src/remote_device/messages/IfdError.h index 81ba9eed7..d36110e92 100644 --- a/src/remote_device/messages/IfdError.h +++ b/src/remote_device/messages/IfdError.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdEstablishContext.cpp b/src/remote_device/messages/IfdEstablishContext.cpp index d8f89d45a..1f24bb55c 100644 --- a/src/remote_device/messages/IfdEstablishContext.cpp +++ b/src/remote_device/messages/IfdEstablishContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdEstablishContext.h b/src/remote_device/messages/IfdEstablishContext.h index 2edcc1680..022b2890f 100644 --- a/src/remote_device/messages/IfdEstablishContext.h +++ b/src/remote_device/messages/IfdEstablishContext.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdEstablishContextResponse.cpp b/src/remote_device/messages/IfdEstablishContextResponse.cpp index da2e9a20d..6def7353c 100644 --- a/src/remote_device/messages/IfdEstablishContextResponse.cpp +++ b/src/remote_device/messages/IfdEstablishContextResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdEstablishContextResponse.h b/src/remote_device/messages/IfdEstablishContextResponse.h index 3a1f3cc6b..89ce02368 100644 --- a/src/remote_device/messages/IfdEstablishContextResponse.h +++ b/src/remote_device/messages/IfdEstablishContextResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdEstablishPaceChannel.cpp b/src/remote_device/messages/IfdEstablishPaceChannel.cpp index 62530c849..313de75a0 100644 --- a/src/remote_device/messages/IfdEstablishPaceChannel.cpp +++ b/src/remote_device/messages/IfdEstablishPaceChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "IfdEstablishPaceChannel.h" diff --git a/src/remote_device/messages/IfdEstablishPaceChannel.h b/src/remote_device/messages/IfdEstablishPaceChannel.h index 63d1a140e..409fca887 100644 --- a/src/remote_device/messages/IfdEstablishPaceChannel.h +++ b/src/remote_device/messages/IfdEstablishPaceChannel.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdEstablishPaceChannelResponse.cpp b/src/remote_device/messages/IfdEstablishPaceChannelResponse.cpp index 9803fda73..74a3d81e2 100644 --- a/src/remote_device/messages/IfdEstablishPaceChannelResponse.cpp +++ b/src/remote_device/messages/IfdEstablishPaceChannelResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "IfdEstablishPaceChannelResponse.h" diff --git a/src/remote_device/messages/IfdEstablishPaceChannelResponse.h b/src/remote_device/messages/IfdEstablishPaceChannelResponse.h index 745281971..9b808b721 100644 --- a/src/remote_device/messages/IfdEstablishPaceChannelResponse.h +++ b/src/remote_device/messages/IfdEstablishPaceChannelResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdGetStatus.cpp b/src/remote_device/messages/IfdGetStatus.cpp index f7daebcfe..0e4da7033 100644 --- a/src/remote_device/messages/IfdGetStatus.cpp +++ b/src/remote_device/messages/IfdGetStatus.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdGetStatus.h b/src/remote_device/messages/IfdGetStatus.h index 25f0c0a5b..ae8d3f56b 100644 --- a/src/remote_device/messages/IfdGetStatus.h +++ b/src/remote_device/messages/IfdGetStatus.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdModifyPin.cpp b/src/remote_device/messages/IfdModifyPin.cpp index d4421f3c2..6f6a9232d 100644 --- a/src/remote_device/messages/IfdModifyPin.cpp +++ b/src/remote_device/messages/IfdModifyPin.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "IfdModifyPin.h" diff --git a/src/remote_device/messages/IfdModifyPin.h b/src/remote_device/messages/IfdModifyPin.h index 97f09b67e..f50b15b3e 100644 --- a/src/remote_device/messages/IfdModifyPin.h +++ b/src/remote_device/messages/IfdModifyPin.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdModifyPinResponse.cpp b/src/remote_device/messages/IfdModifyPinResponse.cpp index 241dbcda9..544b7c45f 100644 --- a/src/remote_device/messages/IfdModifyPinResponse.cpp +++ b/src/remote_device/messages/IfdModifyPinResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "IfdModifyPinResponse.h" diff --git a/src/remote_device/messages/IfdModifyPinResponse.h b/src/remote_device/messages/IfdModifyPinResponse.h index 7463c36c7..7f0b34ac7 100644 --- a/src/remote_device/messages/IfdModifyPinResponse.h +++ b/src/remote_device/messages/IfdModifyPinResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdStatus.cpp b/src/remote_device/messages/IfdStatus.cpp index a9fdcb9fe..bb2256b36 100644 --- a/src/remote_device/messages/IfdStatus.cpp +++ b/src/remote_device/messages/IfdStatus.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdStatus.h b/src/remote_device/messages/IfdStatus.h index a0669128d..cd8b880e5 100644 --- a/src/remote_device/messages/IfdStatus.h +++ b/src/remote_device/messages/IfdStatus.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdTransmit.cpp b/src/remote_device/messages/IfdTransmit.cpp index 74b743ac6..40a44707d 100644 --- a/src/remote_device/messages/IfdTransmit.cpp +++ b/src/remote_device/messages/IfdTransmit.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdTransmit.h b/src/remote_device/messages/IfdTransmit.h index e6192c632..4c71b4040 100644 --- a/src/remote_device/messages/IfdTransmit.h +++ b/src/remote_device/messages/IfdTransmit.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdTransmitResponse.cpp b/src/remote_device/messages/IfdTransmitResponse.cpp index ac9411ceb..c00a53eae 100644 --- a/src/remote_device/messages/IfdTransmitResponse.cpp +++ b/src/remote_device/messages/IfdTransmitResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdTransmitResponse.h b/src/remote_device/messages/IfdTransmitResponse.h index 2ff0792d4..1e835ee4b 100644 --- a/src/remote_device/messages/IfdTransmitResponse.h +++ b/src/remote_device/messages/IfdTransmitResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/IfdVersion.cpp b/src/remote_device/messages/IfdVersion.cpp index 7f9dd7518..1978a41ad 100644 --- a/src/remote_device/messages/IfdVersion.cpp +++ b/src/remote_device/messages/IfdVersion.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/IfdVersion.h b/src/remote_device/messages/IfdVersion.h index e12801584..2a5d875cf 100644 --- a/src/remote_device/messages/IfdVersion.h +++ b/src/remote_device/messages/IfdVersion.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/RemoteMessage.cpp b/src/remote_device/messages/RemoteMessage.cpp index 0d70b56c5..c2966189f 100644 --- a/src/remote_device/messages/RemoteMessage.cpp +++ b/src/remote_device/messages/RemoteMessage.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/RemoteMessage.h b/src/remote_device/messages/RemoteMessage.h index 033e478ef..87b593c66 100644 --- a/src/remote_device/messages/RemoteMessage.h +++ b/src/remote_device/messages/RemoteMessage.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/messages/RemoteMessageResponse.cpp b/src/remote_device/messages/RemoteMessageResponse.cpp index 9c0d1bb27..ba8b061f2 100644 --- a/src/remote_device/messages/RemoteMessageResponse.cpp +++ b/src/remote_device/messages/RemoteMessageResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/remote_device/messages/RemoteMessageResponse.h b/src/remote_device/messages/RemoteMessageResponse.h index 520a0a2ad..90bfbd83a 100644 --- a/src/remote_device/messages/RemoteMessageResponse.h +++ b/src/remote_device/messages/RemoteMessageResponse.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/plugin/RemoteCard.cpp b/src/remote_device/plugin/RemoteCard.cpp index b7ecf6e1b..c88a45d25 100644 --- a/src/remote_device/plugin/RemoteCard.cpp +++ b/src/remote_device/plugin/RemoteCard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteCard.h" @@ -172,7 +172,7 @@ bool RemoteCard::isConnected() } -CardReturnCode RemoteCard::transmit(const CommandApdu& pCommand, ResponseApdu& pResponse) +ResponseApduResult RemoteCard::transmit(const CommandApdu& pCommand) { const QSharedPointer& transmitCmd = QSharedPointer::create(mSlotHandle, pCommand.getBuffer()); if (sendMessage(transmitCmd, RemoteCardMessageType::IFDTransmitResponse, 5000)) @@ -182,16 +182,15 @@ CardReturnCode RemoteCard::transmit(const CommandApdu& pCommand, ResponseApdu& p { if (!response.resultHasError()) { - pResponse.setBuffer(response.getResponseApdu()); - return CardReturnCode::OK; + return {CardReturnCode::OK, ResponseApdu(response.getResponseApdu())}; } qCWarning(card_remote) << response.getResultMinor(); } - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - return CardReturnCode::INPUT_TIME_OUT; + return {CardReturnCode::INPUT_TIME_OUT}; } @@ -230,7 +229,7 @@ EstablishPaceChannelOutput RemoteCard::establishPaceChannel(PacePasswordId pPass } -CardReturnCode RemoteCard::setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) +ResponseApduResult RemoteCard::setEidPin(quint8 pTimeoutSeconds) { PinModify pinModify(pTimeoutSeconds); const QByteArray inputData = pinModify.createCcidForRemote(); @@ -241,21 +240,20 @@ CardReturnCode RemoteCard::setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResp const IfdModifyPinResponse response(mResponse); if (response.resultHasError()) { - return response.getReturnCode(); + return {response.getReturnCode()}; } if (!response.isIncomplete()) { - PinModifyOutput output(ResponseApdu(response.getOutputData())); - pResponseApdu.setBuffer(output.getResponseApdu().getBuffer()); + const PinModifyOutput output(ResponseApdu(response.getOutputData())); if (!response.resultHasError()) { - return output.getReturnCode(); + return {output.getReturnCode(), output.getResponseApdu()}; } } - return CardReturnCode::COMMAND_FAILED; + return {CardReturnCode::COMMAND_FAILED}; } - return CardReturnCode::INPUT_TIME_OUT; + return {CardReturnCode::INPUT_TIME_OUT}; } diff --git a/src/remote_device/plugin/RemoteCard.h b/src/remote_device/plugin/RemoteCard.h index b65f33a20..69ab24585 100644 --- a/src/remote_device/plugin/RemoteCard.h +++ b/src/remote_device/plugin/RemoteCard.h @@ -1,7 +1,7 @@ /*! - * \brief Implementation of \ref Card for remote reader. + * \brief Implementation of \ref Card for smartphone as card reader (SaC). * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -53,11 +53,11 @@ class RemoteCard virtual CardReturnCode disconnect() override; virtual bool isConnected() override; - virtual CardReturnCode transmit(const CommandApdu& pCmd, ResponseApdu& pRes) override; + virtual ResponseApduResult transmit(const CommandApdu& pCmd) override; virtual EstablishPaceChannelOutput establishPaceChannel(PacePasswordId pPasswordId, const QByteArray& pChat, const QByteArray& pCertificateDescription, quint8 pTimeoutSeconds = 60) override; - virtual CardReturnCode setEidPin(quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) override; + virtual ResponseApduResult setEidPin(quint8 pTimeoutSeconds) override; }; } // namespace governikus diff --git a/src/remote_device/plugin/RemoteReader.cpp b/src/remote_device/plugin/RemoteReader.cpp index 4c31e9bb3..70ee662a9 100644 --- a/src/remote_device/plugin/RemoteReader.cpp +++ b/src/remote_device/plugin/RemoteReader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteReader.h" @@ -7,7 +7,6 @@ #include "CardConnectionWorker.h" #include -#include using namespace governikus; diff --git a/src/remote_device/plugin/RemoteReader.h b/src/remote_device/plugin/RemoteReader.h index 729c9d84e..7f0713207 100644 --- a/src/remote_device/plugin/RemoteReader.h +++ b/src/remote_device/plugin/RemoteReader.h @@ -1,7 +1,7 @@ /*! - * \brief Implementation of \ref Reader for remote reader. + * \brief Implementation of \ref Reader for smartphone as card reader (SaC). * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/remote_device/plugin/RemoteReaderManagerPlugIn.cpp b/src/remote_device/plugin/RemoteReaderManagerPlugIn.cpp index d6aec31c9..ca23795a6 100644 --- a/src/remote_device/plugin/RemoteReaderManagerPlugIn.cpp +++ b/src/remote_device/plugin/RemoteReaderManagerPlugIn.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteReaderManagerPlugIn.h" diff --git a/src/remote_device/plugin/RemoteReaderManagerPlugIn.h b/src/remote_device/plugin/RemoteReaderManagerPlugIn.h index cecbd31a3..21978296b 100644 --- a/src/remote_device/plugin/RemoteReaderManagerPlugIn.h +++ b/src/remote_device/plugin/RemoteReaderManagerPlugIn.h @@ -1,7 +1,7 @@ /*! - * \brief Implementation of \ref ReaderManagerPlugIn for remote reader. + * \brief Implementation of \ref ReaderManagerPlugIn for smartphone as card reader (SaC). * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/secure_storage/SecureStorage.cpp b/src/secure_storage/SecureStorage.cpp index 67a58238e..92c7ed5bd 100644 --- a/src/secure_storage/SecureStorage.cpp +++ b/src/secure_storage/SecureStorage.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ @@ -61,7 +61,7 @@ defineSingleton(SecureStorage) SecureStorage::SecureStorage() - : mLoadedTime() + : mLoaded(false) , mCvcas() , mCvcasTest() , mUpdateCertificates() @@ -93,23 +93,24 @@ SecureStorage& SecureStorage::getInstance() } +bool SecureStorage::isLoaded() const +{ + return mLoaded; +} + + void SecureStorage::load() { const auto& path = FileDestination::getPath(QStringLiteral("config.json")); + qCDebug(securestorage) << "Load SecureStorage:" << path; - if (!QFile::exists(path)) + QFile configFile(path); + if (!configFile.exists()) { qCCritical(securestorage) << "SecureStorage not found"; return; } - const auto& lastModified = QFileInfo(path).lastModified(); - if (lastModified.isValid() && lastModified <= mLoadedTime) - { - return; - } - - QFile configFile(path); if (!configFile.open(QIODevice::ReadOnly | QIODevice::Text)) { qCCritical(securestorage) << "Wasn't able to open SecureStorage"; @@ -182,7 +183,7 @@ void SecureStorage::load() mAppcastUpdateUrl = readGroup(config, CONFIGURATION_GROUP_NAME_UPDATES(), CONFIGURATION_NAME_APPCAST_UPDATE_URL()); mAppcastBetaUpdateUrl = readGroup(config, CONFIGURATION_GROUP_NAME_UPDATES(), CONFIGURATION_NAME_APPCAST_BETA_UPDATE_URL()); - mLoadedTime = lastModified; + mLoaded = true; qCInfo(securestorage) << "SecureStorage successfully loaded"; } diff --git a/src/secure_storage/SecureStorage.h b/src/secure_storage/SecureStorage.h index 120aa2d08..877cd5887 100644 --- a/src/secure_storage/SecureStorage.h +++ b/src/secure_storage/SecureStorage.h @@ -2,7 +2,7 @@ * \brief Utility class that provides access to the "secure storage" of the application, which contains * the certificates for preverification and update checks. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -37,7 +37,7 @@ class SecureStorage friend class ::MockSecureStorage; private: - QDateTime mLoadedTime; + bool mLoaded; QByteArrayList mCvcas; QByteArrayList mCvcasTest; QVector mUpdateCertificates; @@ -84,6 +84,7 @@ class SecureStorage const TlsConfiguration& getTlsConfigRemote(TlsSuite pTlsSuite = TlsSuite::DEFAULT) const; int getMinimumStaticKeySize(QSsl::KeyAlgorithm pKeyAlgorithm) const; int getMinimumEphemeralKeySize(QSsl::KeyAlgorithm pKeyAlgorithm) const; + bool isLoaded() const; }; diff --git a/src/secure_storage/TlsConfiguration.cpp b/src/secure_storage/TlsConfiguration.cpp index 6493f97ee..38673228f 100644 --- a/src/secure_storage/TlsConfiguration.cpp +++ b/src/secure_storage/TlsConfiguration.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "TlsConfiguration.h" diff --git a/src/secure_storage/TlsConfiguration.h b/src/secure_storage/TlsConfiguration.h index ac8821087..bc1b421b8 100644 --- a/src/secure_storage/TlsConfiguration.h +++ b/src/secure_storage/TlsConfiguration.h @@ -1,7 +1,7 @@ /*! * \brief Configuration options for TLS channels * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/services/AppUpdateData.cpp b/src/services/AppUpdateData.cpp index ae527e19b..e251b5998 100644 --- a/src/services/AppUpdateData.cpp +++ b/src/services/AppUpdateData.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "AppUpdateData.h" @@ -56,7 +56,7 @@ void AppUpdateData::setDate(const QDateTime& pDate) } -const QDateTime AppUpdateData::getDate() const +const QDateTime& AppUpdateData::getDate() const { return mDate; } diff --git a/src/services/AppUpdateData.h b/src/services/AppUpdateData.h index c1254e628..3bd8e2105 100644 --- a/src/services/AppUpdateData.h +++ b/src/services/AppUpdateData.h @@ -1,7 +1,7 @@ /*! * \brief Update data implementation for application version. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -37,7 +37,7 @@ class AppUpdateData bool isValid() const; - const QDateTime getDate() const; + const QDateTime& getDate() const; void setDate(const QDateTime& pDate); const QString& getVersion() const; diff --git a/src/services/AppUpdater.cpp b/src/services/AppUpdater.cpp index b570c2167..571874bb6 100644 --- a/src/services/AppUpdater.cpp +++ b/src/services/AppUpdater.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "AppUpdater.h" @@ -126,7 +126,7 @@ void AppUpdater::onUpdateDownloadFailed(const QUrl& pUpdateUrl, GlobalStatus::Co } if (mAppUpdateData.isValid() && pUpdateUrl == mAppUpdateData.getNotesUrl()) { - qCDebug(appupdate) << "Release Notes Download failed:" << GlobalStatus(pErrorCode).toErrorDescription(); + qCDebug(appupdate) << "Release notes download failed:" << GlobalStatus(pErrorCode).toErrorDescription(); Q_EMIT fireAppUpdateCheckFinished(true, GlobalStatus::Code::No_Error); clearDownloaderConnection(); } diff --git a/src/services/AppUpdater.h b/src/services/AppUpdater.h index e5e7f7b96..da1e62ccb 100644 --- a/src/services/AppUpdater.h +++ b/src/services/AppUpdater.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/services/Service.cpp b/src/services/Service.cpp index 40afbbb41..5b03f66e9 100644 --- a/src/services/Service.cpp +++ b/src/services/Service.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "Service.h" diff --git a/src/services/Service.h b/src/services/Service.h index 10fd1180c..1e45ae32e 100644 --- a/src/services/Service.h +++ b/src/services/Service.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -38,7 +38,7 @@ class Service void updateConfigurations(); void updateApp(bool pIgnoreNextVersionskip = false); bool isUpdateScheduled(); - void runUpdateIfNeeded(); + Q_INVOKABLE void runUpdateIfNeeded(); const AppUpdateData& getUpdateData() const; Q_SIGNALS: diff --git a/src/settings/AbstractSettings.cpp b/src/settings/AbstractSettings.cpp index af2fb5a88..4e4996b65 100644 --- a/src/settings/AbstractSettings.cpp +++ b/src/settings/AbstractSettings.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/settings/AbstractSettings.h b/src/settings/AbstractSettings.h index e51cf55e8..fa1e8577d 100644 --- a/src/settings/AbstractSettings.h +++ b/src/settings/AbstractSettings.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/settings/AppSettings.cpp b/src/settings/AppSettings.cpp index 4a9077faf..ebd196c5f 100644 --- a/src/settings/AppSettings.cpp +++ b/src/settings/AppSettings.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AppSettings.h" diff --git a/src/settings/AppSettings.h b/src/settings/AppSettings.h index 79c4fa114..b182f8b2d 100644 --- a/src/settings/AppSettings.h +++ b/src/settings/AppSettings.h @@ -1,7 +1,7 @@ /*! * \brief Contains the definition of the AppSettings class. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/settings/AutoStart.h b/src/settings/AutoStart.h index 12383214f..9ff2d4932 100644 --- a/src/settings/AutoStart.h +++ b/src/settings/AutoStart.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/settings/AutoStart_generic.cpp b/src/settings/AutoStart_generic.cpp index 0e2e596ec..13918c2d0 100644 --- a/src/settings/AutoStart_generic.cpp +++ b/src/settings/AutoStart_generic.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AutoStart.h" diff --git a/src/settings/AutoStart_osx.cpp b/src/settings/AutoStart_osx.mm similarity index 98% rename from src/settings/AutoStart_osx.cpp rename to src/settings/AutoStart_osx.mm index a922e7d62..b3a67e0b3 100644 --- a/src/settings/AutoStart_osx.cpp +++ b/src/settings/AutoStart_osx.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AutoStart.h" @@ -8,8 +8,8 @@ #include #include -#import #import +#import using namespace governikus; diff --git a/src/settings/AutoStart_win.cpp b/src/settings/AutoStart_win.cpp index 881da42b7..ba773acd9 100644 --- a/src/settings/AutoStart_win.cpp +++ b/src/settings/AutoStart_win.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AutoStart.h" diff --git a/src/settings/GeneralSettings.cpp b/src/settings/GeneralSettings.cpp index d22943d1a..9dd8b50d0 100644 --- a/src/settings/GeneralSettings.cpp +++ b/src/settings/GeneralSettings.cpp @@ -1,7 +1,7 @@ /*! * \brief Contains the method definitions of the GeneralSettings class. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "GeneralSettings.h" @@ -26,8 +26,10 @@ SETTINGS_NAME(SETTINGS_NAME_PERSISTENT_SETTINGS_VERSION, "persistentSettingsVers SETTINGS_NAME(SETTINGS_NAME_SKIP_VERSION, "skipVersion") SETTINGS_NAME(SETTINGS_NAME_AUTO_CLOSE_WINDOW, "autoCloseWindow") SETTINGS_NAME(SETTINGS_NAME_SHOW_SETUP_ASSISTANT, "showSetupAssistant") +SETTINGS_NAME(SETTINGS_NAME_SHOW_NEW_UI_HINT, "showNewUiHint") SETTINGS_NAME(SETTINGS_NAME_REMIND_USER_TO_CLOSE, "remindToClose") SETTINGS_NAME(SETTINGS_NAME_TRANSPORT_PIN_REMINDER, "transportPinReminder") +SETTINGS_NAME(SETTINGS_NAME_DEVELOPER_OPTIONS, "developerOptions") SETTINGS_NAME(SETTINGS_NAME_DEVELOPER_MODE, "developerMode") SETTINGS_NAME(SETTINGS_NAME_USE_SELF_AUTH_TEST_URI, "selfauthTestUri") SETTINGS_NAME(SETTINGS_NAME_LANGUAGE, "language") @@ -39,6 +41,7 @@ SETTINGS_NAME(SETTINGS_NAME_REQUEST_STORE_FEEDBACK, "requestStoreFeedback") SETTINGS_NAME(SETTINGS_GROUP_NAME_COMMON, "common") SETTINGS_NAME(SETTINGS_NAME_AUTO, "autoUpdateCheck") SETTINGS_NAME(SETTINGS_NAME_KEYLESS_PASSWORD, "keylessPassword") +SETTINGS_NAME(SETTINGS_NAME_VISUAL_PRIVACY, "visualPrivacy") SETTINGS_NAME(SETTINGS_NAME_SHUFFLE_SCREEN_KEYBOARD, "shuffleScreenKeyboard") } // namespace @@ -76,6 +79,7 @@ GeneralSettings::GeneralSettings() mStoreGeneral->setValue(SETTINGS_NAME_PERSISTENT_SETTINGS_VERSION(), QCoreApplication::applicationVersion()); setAutoStart(GENERAL_SETTINGS_DEFAULT_AUTOSTART); mStoreGeneral->sync(); + setShowNewUiHint(false); } #if defined(QT_NO_DEBUG) && (defined(Q_OS_ANDROID) || defined(Q_OS_IOS)) @@ -96,6 +100,21 @@ GeneralSettings::~GeneralSettings() } +bool GeneralSettings::isShowNotificationsOsDefault() const +{ +#if defined(Q_OS_WIN) + return QOperatingSystemVersion::current() < QOperatingSystemVersion::Windows10; + +#elif defined(Q_OS_MACOS) + return false; + +#else + return true; + +#endif +} + + void GeneralSettings::save() { mStoreGeneral->setValue(SETTINGS_NAME_PERSISTENT_SETTINGS_VERSION(), QCoreApplication::applicationVersion()); @@ -105,6 +124,19 @@ void GeneralSettings::save() } +bool GeneralSettings::isAutoStartAvailable() const +{ +#if defined(Q_OS_WIN) || defined(Q_OS_MACOS) + return true; + +#else + // Linux: maybe XDG_CONFIG_HOME/autostart or XDG_CONFIG_DIRS/autostart can be added + return false; + +#endif +} + + bool GeneralSettings::isAutoStart() const { return mAutoStart; @@ -183,6 +215,22 @@ void GeneralSettings::setShowSetupAssistant(bool pShowSetupAssistant) } +bool GeneralSettings::isShowNewUiHint() const +{ + return mStoreGeneral->value(SETTINGS_NAME_SHOW_NEW_UI_HINT(), true).toBool(); +} + + +void GeneralSettings::setShowNewUiHint(bool pShowNewUiHint) +{ + if (pShowNewUiHint != isShowNewUiHint()) + { + mStoreGeneral->setValue(SETTINGS_NAME_SHOW_NEW_UI_HINT(), pShowNewUiHint); + Q_EMIT fireSettingsChanged(); + } +} + + bool GeneralSettings::isRemindUserToClose() const { return mStoreGeneral->value(SETTINGS_NAME_REMIND_USER_TO_CLOSE(), true).toBool(); @@ -215,6 +263,22 @@ void GeneralSettings::setTransportPinReminder(bool pTransportPinReminder) } +bool GeneralSettings::isDeveloperOptions() const +{ + return mStoreGeneral->value(SETTINGS_NAME_DEVELOPER_OPTIONS(), false).toBool(); +} + + +void GeneralSettings::setDeveloperOptions(bool pEnabled) +{ + if (pEnabled != isDeveloperOptions()) + { + mStoreGeneral->setValue(SETTINGS_NAME_DEVELOPER_OPTIONS(), pEnabled); + Q_EMIT fireDeveloperOptionsChanged(); + } +} + + bool GeneralSettings::isDeveloperMode() const { const bool developerMode = mStoreGeneral->value(SETTINGS_NAME_DEVELOPER_MODE(), false).toBool(); @@ -224,6 +288,13 @@ bool GeneralSettings::isDeveloperMode() const return false; } +#if !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) + if (!isDeveloperOptions()) + { + return false; + } +#endif + return developerMode; } @@ -233,13 +304,21 @@ void GeneralSettings::setDeveloperMode(bool pEnabled) if (pEnabled != isDeveloperMode()) { mStoreGeneral->setValue(SETTINGS_NAME_DEVELOPER_MODE(), pEnabled); - Q_EMIT fireSettingsChanged(); + Q_EMIT fireDeveloperOptionsChanged(); + Q_EMIT fireShowInAppNotificationsChanged(); } } bool GeneralSettings::useSelfAuthTestUri() const { +#if !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) + if (!isDeveloperOptions()) + { + return false; + } +#endif + return mStoreGeneral->value(SETTINGS_NAME_USE_SELF_AUTH_TEST_URI(), false).toBool(); } @@ -249,7 +328,7 @@ void GeneralSettings::setUseSelfauthenticationTestUri(bool pUse) if (pUse != useSelfAuthTestUri()) { mStoreGeneral->setValue(SETTINGS_NAME_USE_SELF_AUTH_TEST_URI(), pUse); - Q_EMIT fireSettingsChanged(); + Q_EMIT fireDeveloperOptionsChanged(); } } @@ -279,7 +358,7 @@ void GeneralSettings::setLanguage(const QLocale::Language pLanguage) QString GeneralSettings::getSelectedUi() const { - return mStoreGeneral->value(SETTINGS_NAME_SELECTED_UI(), QStringLiteral(DEFAULT_UI)).toString(); + return mStoreGeneral->value(SETTINGS_NAME_SELECTED_UI(), QStringLiteral("qml")).toString(); } @@ -353,6 +432,18 @@ void GeneralSettings::setLastReaderPluginType(const QString& pLastReaderPluginTy } +bool GeneralSettings::isAutoUpdateAvailable() const +{ +#if !defined(QT_NO_DEBUG) || defined(Q_OS_WIN) || defined(Q_OS_MACOS) + return true; + +#else + return false; + +#endif +} + + bool GeneralSettings::isAutoUpdateCheck() const { if (autoUpdateCheckIsSetByAdmin()) @@ -362,11 +453,11 @@ bool GeneralSettings::isAutoUpdateCheck() const mStoreGeneral->remove(SETTINGS_NAME_AUTO()); } -#if defined(Q_OS_ANDROID) || defined(Q_OS_IOS) - return mStoreCommon->value(SETTINGS_NAME_AUTO(), false).toBool(); +#if defined(Q_OS_WIN) || defined(Q_OS_MACOS) + return mStoreCommon->value(SETTINGS_NAME_AUTO(), true).toBool(); #else - return mStoreCommon->value(SETTINGS_NAME_AUTO(), true).toBool(); + return mStoreCommon->value(SETTINGS_NAME_AUTO(), false).toBool(); #endif } @@ -419,6 +510,22 @@ void GeneralSettings::setUseScreenKeyboard(bool pUseScreenKeyboard) } +bool GeneralSettings::isVisualPrivacy() const +{ + return mStoreGeneral->value(SETTINGS_NAME_VISUAL_PRIVACY(), false).toBool(); +} + + +void GeneralSettings::setVisualPrivacy(bool pVisualPrivacy) +{ + if (pVisualPrivacy != isVisualPrivacy()) + { + mStoreGeneral->setValue(SETTINGS_NAME_VISUAL_PRIVACY(), pVisualPrivacy); + Q_EMIT fireSettingsChanged(); + } +} + + bool GeneralSettings::isShuffleScreenKeyboard() const { return mStoreCommon->value(SETTINGS_NAME_SHUFFLE_SCREEN_KEYBOARD(), false).toBool(); @@ -437,16 +544,12 @@ void GeneralSettings::setShuffleScreenKeyboard(bool pShuffleScreenKeyboard) bool GeneralSettings::isShowInAppNotifications() const { -#if defined(Q_OS_WIN) - return QOperatingSystemVersion::current() < QOperatingSystemVersion::Windows10; - -#elif defined(Q_OS_MACOS) - return false; - -#else - return mStoreGeneral->value(SETTINGS_NAME_IN_APP_NOTIFICATIONS(), true).toBool(); + if (isDeveloperMode()) + { + return true; + } -#endif + return mStoreGeneral->value(SETTINGS_NAME_IN_APP_NOTIFICATIONS(), isShowNotificationsOsDefault()).toBool(); } @@ -455,6 +558,6 @@ void GeneralSettings::setShowInAppNotifications(bool pShowInAppNotifications) if (pShowInAppNotifications != isShowInAppNotifications()) { mStoreGeneral->setValue(SETTINGS_NAME_IN_APP_NOTIFICATIONS(), pShowInAppNotifications); - Q_EMIT fireSettingsChanged(); + Q_EMIT fireShowInAppNotificationsChanged(); } } diff --git a/src/settings/GeneralSettings.h b/src/settings/GeneralSettings.h index bcbef86eb..290c37f40 100644 --- a/src/settings/GeneralSettings.h +++ b/src/settings/GeneralSettings.h @@ -1,7 +1,7 @@ /*! * \brief Contains the definition of the GeneralSettings class. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -23,12 +23,6 @@ namespace governikus #define GENERAL_SETTINGS_DEFAULT_AUTOSTART false #endif -#if defined(Q_OS_ANDROID) || defined(Q_OS_IOS) - #define DEFAULT_UI "qml" -#else - #define DEFAULT_UI "widgets" -#endif - class GeneralSettings : public AbstractSettings @@ -44,11 +38,13 @@ class GeneralSettings QSharedPointer mStoreCommon; GeneralSettings(); + bool isShowNotificationsOsDefault() const; public: virtual ~GeneralSettings() override; virtual void save() override; + bool isAutoStartAvailable() const; bool isAutoStart() const; bool autoStartIsSetByAdmin() const; void setAutoStart(bool pAutoStart); @@ -64,12 +60,18 @@ class GeneralSettings bool isShowSetupAssistant() const; void setShowSetupAssistant(bool pShowSetupAssistant); + bool isShowNewUiHint() const; + void setShowNewUiHint(bool pShowNewUiHint); + bool isRemindUserToClose() const; void setRemindUserToClose(bool pRemindUser); bool isTransportPinReminder() const; void setTransportPinReminder(bool pTransportPinReminder); + bool isDeveloperOptions() const; + void setDeveloperOptions(bool pEnabled); + bool isDeveloperMode() const; void setDeveloperMode(bool pEnabled); @@ -93,6 +95,7 @@ class GeneralSettings QString getLastReaderPluginType() const; void setLastReaderPluginType(const QString& pLastReaderPluginType); + bool isAutoUpdateAvailable() const; bool isAutoUpdateCheck() const; bool autoUpdateCheckIsSetByAdmin() const; void setAutoUpdateCheck(bool pAutoUpdateCheck); @@ -100,6 +103,9 @@ class GeneralSettings bool isUseScreenKeyboard() const; void setUseScreenKeyboard(bool pUseScreenKeyboard); + bool isVisualPrivacy() const; + void setVisualPrivacy(bool pVisualPrivacy); + bool isShuffleScreenKeyboard() const; void setShuffleScreenKeyboard(bool pShuffleScreenKeyboard); @@ -108,6 +114,8 @@ class GeneralSettings Q_SIGNALS: void fireLanguageChanged(); + void fireDeveloperOptionsChanged(); + void fireShowInAppNotificationsChanged(); }; diff --git a/src/settings/HistoryInfo.cpp b/src/settings/HistoryInfo.cpp index d6acef6c4..0b8474e6d 100644 --- a/src/settings/HistoryInfo.cpp +++ b/src/settings/HistoryInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "HistoryInfo.h" diff --git a/src/settings/HistoryInfo.h b/src/settings/HistoryInfo.h index 71129e88c..02793be10 100644 --- a/src/settings/HistoryInfo.h +++ b/src/settings/HistoryInfo.h @@ -1,7 +1,7 @@ /*! * \brief Represents history settings. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/settings/HistorySettings.cpp b/src/settings/HistorySettings.cpp index 2b0ff8a4c..1e22ae210 100644 --- a/src/settings/HistorySettings.cpp +++ b/src/settings/HistorySettings.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "HistorySettings.h" diff --git a/src/settings/HistorySettings.h b/src/settings/HistorySettings.h index 5e9f4ba96..46227b3b6 100644 --- a/src/settings/HistorySettings.h +++ b/src/settings/HistorySettings.h @@ -1,7 +1,7 @@ /*! * \brief Represents history settings. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/settings/KeyPair.cpp b/src/settings/KeyPair.cpp index 6d5f695c3..bc34b111b 100644 --- a/src/settings/KeyPair.cpp +++ b/src/settings/KeyPair.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/settings/KeyPair.h b/src/settings/KeyPair.h index 7d57b38e8..5a5cf6493 100644 --- a/src/settings/KeyPair.h +++ b/src/settings/KeyPair.h @@ -1,7 +1,7 @@ /* * \brief Generates a new private/public key with an X509 certificate. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/settings/PreVerificationSettings.cpp b/src/settings/PreVerificationSettings.cpp index 17ed462fc..bf002cd8d 100644 --- a/src/settings/PreVerificationSettings.cpp +++ b/src/settings/PreVerificationSettings.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PreVerificationSettings.h" diff --git a/src/settings/PreVerificationSettings.h b/src/settings/PreVerificationSettings.h index 977b29a50..a514004ad 100644 --- a/src/settings/PreVerificationSettings.h +++ b/src/settings/PreVerificationSettings.h @@ -1,7 +1,7 @@ /*! * \brief Settings to handle PreVerification and the corresponding linked certificates. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/settings/RemoteServiceSettings.cpp b/src/settings/RemoteServiceSettings.cpp index 7d11e67d0..f81fe0e62 100644 --- a/src/settings/RemoteServiceSettings.cpp +++ b/src/settings/RemoteServiceSettings.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteServiceSettings.h" @@ -67,7 +67,7 @@ QString RemoteServiceSettings::getDefaultServerName() if (name.isEmpty()) { //: LABEL ALL_PLATFORMS - return tr("Remote Reader"); + return tr("Smartphone as card reader (SaC)"); } return name; @@ -82,13 +82,14 @@ QString RemoteServiceSettings::getServerName() const void RemoteServiceSettings::setServerName(const QString& pName) { - if (pName.isEmpty()) + const QString serverName = pName.trimmed(); + if (serverName.isEmpty()) { mStore->setValue(SETTINGS_NAME_DEVICE_NAME(), getDefaultServerName()); return; } - mStore->setValue(SETTINGS_NAME_DEVICE_NAME(), pName); + mStore->setValue(SETTINGS_NAME_DEVICE_NAME(), serverName); } @@ -144,7 +145,14 @@ void RemoteServiceSettings::setUniqueTrustedCertificates(const QSet& pCertificates) { - setUniqueTrustedCertificates(pCertificates.toSet()); // remove duplicates + // remove duplicates +#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)) + const auto set = QSet(pCertificates.constBegin(), pCertificates.constEnd()); +#else + const auto set = pCertificates.toSet(); +#endif + + setUniqueTrustedCertificates(set); } @@ -260,11 +268,7 @@ QVector RemoteServiceSettings::getRemoteInfos const auto& array = QJsonDocument::fromJson(data).array(); for (const auto& item : array) { - const auto& obj = item.toObject(); - auto fingerprint = obj[QLatin1String("fingerprint")].toString(); - auto name = obj[QLatin1String("name")].toString(); - auto lastConnected = QDateTime::fromString(obj[QLatin1String("lastConnected")].toString(), Qt::ISODateWithMs); - infos << RemoteInfo(fingerprint, lastConnected, name); + infos << RemoteInfo::fromJson(item.toObject()); } return infos; @@ -276,11 +280,7 @@ void RemoteServiceSettings::setRemoteInfos(const QVector& pInfos) QJsonArray array; for (const auto& item : pInfos) { - QJsonObject obj; - obj[QLatin1String("fingerprint")] = item.getFingerprint(); - obj[QLatin1String("name")] = item.getName(); - obj[QLatin1String("lastConnected")] = item.getLastConnected().toString(Qt::ISODateWithMs); - array << obj; + array << item.toJson(); } mStore->setValue(SETTINGS_NAME_TRUSTED_REMOTE_INFO(), QJsonDocument(array).toJson(QJsonDocument::Compact)); @@ -353,6 +353,26 @@ RemoteServiceSettings::RemoteInfo::RemoteInfo(const QString& pFingerprint, } +RemoteServiceSettings::RemoteInfo RemoteServiceSettings::RemoteInfo::fromJson(const QJsonObject& obj) +{ + RemoteInfo remoteInfo( + obj[QLatin1String("fingerprint")].toString(), + QDateTime::fromString(obj[QLatin1String("lastConnected")].toString(), Qt::ISODateWithMs)); + remoteInfo.mName = obj[QLatin1String("name")].toString(); + return remoteInfo; +} + + +QJsonObject RemoteServiceSettings::RemoteInfo::toJson() const +{ + QJsonObject obj; + obj[QLatin1String("fingerprint")] = mFingerprint; + obj[QLatin1String("name")] = mName; + obj[QLatin1String("lastConnected")] = mLastConnected.toString(Qt::ISODateWithMs); + return obj; +} + + const QString& RemoteServiceSettings::RemoteInfo::getFingerprint() const { return mFingerprint; diff --git a/src/settings/RemoteServiceSettings.h b/src/settings/RemoteServiceSettings.h index 93fe8c27c..8004c293a 100644 --- a/src/settings/RemoteServiceSettings.h +++ b/src/settings/RemoteServiceSettings.h @@ -1,7 +1,7 @@ /*! * \brief RemoteService settings * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -53,6 +53,9 @@ class RemoteServiceSettings public: RemoteInfo() = default; + static RemoteInfo fromJson(const QJsonObject&); + QJsonObject toJson() const; + const QString& getFingerprint() const; const QString& getName() const; diff --git a/src/ui/aidl/AidlBinder.java b/src/ui/aidl/AidlBinder.java index 9982ddf93..75becb7bb 100644 --- a/src/ui/aidl/AidlBinder.java +++ b/src/ui/aidl/AidlBinder.java @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ package com.governikus.ausweisapp2; diff --git a/src/ui/aidl/PskManager.cpp b/src/ui/aidl/PskManager.cpp index e895645cc..81365dd48 100644 --- a/src/ui/aidl/PskManager.cpp +++ b/src/ui/aidl/PskManager.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "PskManager.h" diff --git a/src/ui/aidl/PskManager.h b/src/ui/aidl/PskManager.h index 8e2bb51f8..f0b641aa1 100644 --- a/src/ui/aidl/PskManager.h +++ b/src/ui/aidl/PskManager.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/aidl/UIPlugInAidl.cpp b/src/ui/aidl/UIPlugInAidl.cpp index def477c68..df5489672 100644 --- a/src/ui/aidl/UIPlugInAidl.cpp +++ b/src/ui/aidl/UIPlugInAidl.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugInAidl.h" @@ -13,7 +13,6 @@ #include #include #include -#include #include #ifdef Q_OS_ANDROID @@ -66,13 +65,23 @@ UIPlugInAidl* UIPlugInAidl::getInstance(bool pBlock) // Hence we delay access to the UIPlugInAidl. if (pBlock) { +#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)) + while (instance.loadRelaxed() == nullptr) +#else while (instance.load() == nullptr) +#endif { QThread::msleep(100); } } +#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)) + return instance.loadRelaxed(); + +#else return instance.load(); + +#endif } diff --git a/src/ui/aidl/UIPlugInAidl.h b/src/ui/aidl/UIPlugInAidl.h index 77d3d63e3..3958be7b7 100644 --- a/src/ui/aidl/UIPlugInAidl.h +++ b/src/ui/aidl/UIPlugInAidl.h @@ -1,7 +1,7 @@ /*! * \brief UIPlugIn implementation of the AIDL UI. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/base/UILoader.cpp b/src/ui/base/UILoader.cpp index 6e1a391ba..ee2e6a7ec 100644 --- a/src/ui/base/UILoader.cpp +++ b/src/ui/base/UILoader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "UILoader.h" diff --git a/src/ui/base/UILoader.h b/src/ui/base/UILoader.h index 2adf62151..a67127f09 100644 --- a/src/ui/base/UILoader.h +++ b/src/ui/base/UILoader.h @@ -1,7 +1,7 @@ /*! * \brief Loader to initialize UIPlugIns. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/base/UIPlugIn.cpp b/src/ui/base/UIPlugIn.cpp index cb630d394..bcf5f5716 100644 --- a/src/ui/base/UIPlugIn.cpp +++ b/src/ui/base/UIPlugIn.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugIn.h" diff --git a/src/ui/base/UIPlugIn.h b/src/ui/base/UIPlugIn.h index b0809be41..98dd6f3e8 100644 --- a/src/ui/base/UIPlugIn.h +++ b/src/ui/base/UIPlugIn.h @@ -1,7 +1,7 @@ /*! * \brief Abstract layer to UI implementations. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -24,7 +24,8 @@ defineEnumType(UiModule, DEFAULT, IDENTIFY, SETTINGS, - PINMANAGEMENT + PINMANAGEMENT, + UPDATEINFORMATION ) class UIPlugIn diff --git a/src/ui/common/Email.cpp b/src/ui/common/Email.cpp index 429486ec8..e7d984df5 100644 --- a/src/ui/common/Email.cpp +++ b/src/ui/common/Email.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "Email.h" diff --git a/src/ui/common/Email.h b/src/ui/common/Email.h index 63beb2ccb..60a3ea076 100644 --- a/src/ui/common/Email.h +++ b/src/ui/common/Email.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/common/HelpAction.cpp b/src/ui/common/HelpAction.cpp index 270337ccb..88750084e 100644 --- a/src/ui/common/HelpAction.cpp +++ b/src/ui/common/HelpAction.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "HelpAction.h" @@ -24,10 +24,10 @@ defineSingleton(HelpAction) Q_DECLARE_LOGGING_CATEGORY(gui) //Mapping object name to help file, \see AppQtMainWidget::onContentActionClicked() -const QMap HelpAction::mHelpMapping = { +const QMap HelpAction::mWidgetHelpMapping = { {QStringLiteral("setupAssistant"), QStringLiteral("wizard-info.html")}, {QStringLiteral("setupAssistantSetupCompleted"), QString()}, - {QStringLiteral("ausweisenPage"), QStringLiteral("identify.html")}, + {QStringLiteral("identifyPage"), QStringLiteral("identify.html")}, {QStringLiteral("providerPage"), QStringLiteral("provider.html")}, {QStringLiteral("historyPage"), QStringLiteral("history.html")}, {QStringLiteral("generalTab"), QStringLiteral("settings-general.html")}, @@ -37,6 +37,28 @@ const QMap HelpAction::mHelpMapping = { {QStringLiteral("index"), QStringLiteral("index.html")} }; +const QMap HelpAction::mQmlHelpMapping = { + {QStringLiteral("applicationOverview"), QStringLiteral("index.html")}, + {QStringLiteral("index"), QStringLiteral("index.html")}, + {QStringLiteral("selfauthentication"), QStringLiteral("selfauthentication.html")}, + {QStringLiteral("authentication"), QStringLiteral("provider-identify.html")}, + {QStringLiteral("provider"), QStringLiteral("provider.html")}, + {QStringLiteral("providerDetails"), QStringLiteral("provider-list.html#provider-details")}, + {QStringLiteral("history"), QStringLiteral("history.html")}, + {QStringLiteral("settings"), QStringLiteral("settings.html")}, + {QStringLiteral("settingsRemoteReader"), QStringLiteral("settings-remote-reader.html")}, + {QStringLiteral("settingsPcscReader"), QStringLiteral("settings-pcsc-reader.html")}, + {QStringLiteral("settingsSecurityPrivacy"), QStringLiteral("settings-security-privacy.html")}, + {QStringLiteral("settingsDeveloper"), QStringLiteral("settings-developer.html")}, + {QStringLiteral("pinManagement"), QStringLiteral("pin-management.html")}, + {QStringLiteral("helpSection"), QStringLiteral("help-section.html")}, + {QStringLiteral("diagnosis"), QStringLiteral("help-section-diagnosis.html")}, + {QStringLiteral("applicationLog"), QStringLiteral("help-section-application-log.html")}, + {QStringLiteral("helpVersioninformation"), QStringLiteral("help-section-versioninformation.html")}, + {QStringLiteral("setupAssistant"), QStringLiteral("setup-assistant.html")} +}; + +const QString HelpAction::mBaseUrl = QStringLiteral("https://www.ausweisapp.bund.de/ausweisapp2/"); HelpAction& HelpAction::getInstance() { @@ -75,11 +97,12 @@ QLocale::Language HelpAction::getExistingHelpLanguage() const } -QString HelpAction::getContextMapping(const QString& pObjectName) const +QString HelpAction::getContextMapping(const QString& pObjectName, bool pWidgetUiHelp) const { - if (mHelpMapping.contains(pObjectName)) + const auto& mapping = pWidgetUiHelp ? mWidgetHelpMapping : mQmlHelpMapping; + if (mapping.contains(pObjectName)) { - return mHelpMapping.value(pObjectName); + return mapping.value(pObjectName); } else { @@ -90,19 +113,19 @@ QString HelpAction::getContextMapping(const QString& pObjectName) const } -QString HelpAction::getHelpUrl(const QString& pObjectName) const +QString HelpAction::getHelpUrl(const QString& pObjectName, bool pWidgetUiHelp) const { QLocale::Language lang = getExistingHelpLanguage(); if (lang == QLocale::AnyLanguage) { - return getOnlineUrl(); + return getOnlineUrl(QString(), pWidgetUiHelp); } - return QUrl::fromLocalFile(getHelpPath(lang)).toString() + getContextMapping(pObjectName); + return QUrl::fromLocalFile(getHelpPath(lang)).toString() + getContextMapping(pObjectName, pWidgetUiHelp); } -QString HelpAction::getOnlineUrl(const QString& pObjectName) +QString HelpAction::getOnlineUrl(const QString& pObjectName, bool pWidgetUiHelp) { #ifdef Q_OS_MACOS const QLatin1String osPath("macOS"); @@ -111,16 +134,17 @@ QString HelpAction::getOnlineUrl(const QString& pObjectName) #endif const auto& appVersion = VersionNumber::getApplicationVersion().getVersionNumber(); - const QString ver = QString::number(appVersion.majorVersion()) % QLatin1Char('.') % QString::number(appVersion.minorVersion()); + const QString ver = pWidgetUiHelp ? QStringLiteral("1.16") : QString::number(appVersion.majorVersion()) % QLatin1Char('.') % QString::number(appVersion.minorVersion()); const QString locale = QLocale(LanguageLoader::getInstance().getUsedLocale().language()).bcp47Name().mid(0, 2); - const QString mapping = getInstance().getContextMapping(pObjectName); - return QStringLiteral("https://www.ausweisapp.bund.de/ausweisapp2/handbuch/") % ver % QLatin1Char('/') % locale % QLatin1Char('/') % osPath % QLatin1Char('/') % mapping; + const QString mapping = getInstance().getContextMapping(pObjectName, pWidgetUiHelp); + const QString directory = pWidgetUiHelp ? QStringLiteral("handbuch") : QStringLiteral("help"); + return mBaseUrl % directory % QLatin1Char('/') % ver % QLatin1Char('/') % locale % QLatin1Char('/') % osPath % QLatin1Char('/') % mapping; } -void HelpAction::openContextHelp(const QString& pObjectName) +void HelpAction::openContextHelp(const QString& pObjectName, bool pWidgetUiHelp) { - const auto& url = QUrl(getOnlineUrl(pObjectName)); + const auto& url = QUrl(getOnlineUrl(pObjectName, pWidgetUiHelp)); qCDebug(gui) << "Open online help:" << pObjectName << '|' << url; QDesktopServices::openUrl(url); } diff --git a/src/ui/common/HelpAction.h b/src/ui/common/HelpAction.h index c66e65e30..b89644e63 100644 --- a/src/ui/common/HelpAction.h +++ b/src/ui/common/HelpAction.h @@ -2,7 +2,7 @@ * \brief Helper class for mapping object name from f1 widget to help file. * \see AppQtMainWidget::onContentActionClicked() * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -21,14 +21,16 @@ class HelpAction private: friend class ::test_HelpAction; - static const QMap mHelpMapping; + static const QMap mWidgetHelpMapping; + static const QMap mQmlHelpMapping; + static const QString mBaseUrl; Q_DISABLE_COPY(HelpAction) QLocale::Language getExistingHelpLanguage() const; - QString getContextMapping(const QString& pObjectName) const; + QString getContextMapping(const QString& pObjectName, bool pWidgetUiHelp = true) const; QString getHelpPath(QLocale::Language pLang) const; - QString getHelpUrl(const QString& pObjectName) const; + QString getHelpUrl(const QString& pObjectName, bool pWidgetUiHelp = true) const; protected: static HelpAction& getInstance(); @@ -36,8 +38,8 @@ class HelpAction ~HelpAction() = default; public: - static QString getOnlineUrl(const QString& pObjectName = QString()); - static void openContextHelp(const QString& pObjectName = QStringLiteral("applicationPage")); + static QString getOnlineUrl(const QString& pObjectName = QString(), bool pWidgetUiHelp = true); + static void openContextHelp(const QString& pObjectName = QStringLiteral("applicationPage"), bool pWidgetUiHelp = true); }; } // namespace governikus diff --git a/src/ui/common/PlatformTools.h b/src/ui/common/PlatformTools.h index 33c991436..279269d92 100644 --- a/src/ui/common/PlatformTools.h +++ b/src/ui/common/PlatformTools.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/common/PlatformTools_generic.cpp b/src/ui/common/PlatformTools_generic.cpp index 20756cb6e..9d31d1d78 100644 --- a/src/ui/common/PlatformTools_generic.cpp +++ b/src/ui/common/PlatformTools_generic.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "PlatformTools.h" diff --git a/src/ui/common/PlatformTools_osx.cpp b/src/ui/common/PlatformTools_osx.mm similarity index 88% rename from src/ui/common/PlatformTools_osx.cpp rename to src/ui/common/PlatformTools_osx.mm index 8e4a8316e..d98cf9275 100644 --- a/src/ui/common/PlatformTools_osx.cpp +++ b/src/ui/common/PlatformTools_osx.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "PlatformTools.h" diff --git a/src/ui/common/ReaderDriverModel.cpp b/src/ui/common/ReaderDriverModel.cpp index b2c7a47b0..da227b0c5 100644 --- a/src/ui/common/ReaderDriverModel.cpp +++ b/src/ui/common/ReaderDriverModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDriverModel.h" diff --git a/src/ui/common/ReaderDriverModel.h b/src/ui/common/ReaderDriverModel.h index 67cd23b10..2a92b9d0f 100644 --- a/src/ui/common/ReaderDriverModel.h +++ b/src/ui/common/ReaderDriverModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the reader driver table * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/common/RemoteDeviceModel.cpp b/src/ui/common/RemoteDeviceModel.cpp index 901fa0bd1..49dc15bf9 100644 --- a/src/ui/common/RemoteDeviceModel.cpp +++ b/src/ui/common/RemoteDeviceModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDeviceModel.h" @@ -21,6 +21,7 @@ RemoteDeviceModelEntry::RemoteDeviceModelEntry(const QString& pDeviceName, const , mId(pId) , mPaired(false) , mNetworkVisible(false) + , mConnected(false) , mSupported(pRemoteDeviceListEntry->getRemoteDeviceDescriptor().isSupported()) , mLastConnected() , mRemoteDeviceListEntry(pRemoteDeviceListEntry) @@ -28,11 +29,12 @@ RemoteDeviceModelEntry::RemoteDeviceModelEntry(const QString& pDeviceName, const } -RemoteDeviceModelEntry::RemoteDeviceModelEntry(const QString& pDeviceName, const QString& pId, bool pPaired, bool pNetworkVisible, bool pSupported, const QDateTime& pLastConnected, QSharedPointer& pRemoteDeviceListEntry) +RemoteDeviceModelEntry::RemoteDeviceModelEntry(const QString& pDeviceName, const QString& pId, bool pNetworkVisible, bool pConnected, bool pSupported, const QDateTime& pLastConnected, QSharedPointer& pRemoteDeviceListEntry) : mDeviceName(pDeviceName) , mId(pId) - , mPaired(pPaired) + , mPaired(true) , mNetworkVisible(pNetworkVisible) + , mConnected(pConnected) , mSupported(pSupported) , mLastConnected(pLastConnected) , mRemoteDeviceListEntry(pRemoteDeviceListEntry) @@ -45,6 +47,7 @@ RemoteDeviceModelEntry::RemoteDeviceModelEntry(const QString& pDeviceName) , mId() , mPaired(false) , mNetworkVisible(false) + , mConnected(false) , mSupported(false) , mLastConnected() , mRemoteDeviceListEntry(nullptr) @@ -96,10 +99,16 @@ bool RemoteDeviceModelEntry::isNetworkVisible() const int RemoteDeviceModelEntry::getLinkQuality() const { + if (mConnected) + { + return 100; + } + if (mRemoteDeviceListEntry.isNull()) { return 0; } + return mRemoteDeviceListEntry->getPercentSeen(); } @@ -128,6 +137,12 @@ void RemoteDeviceModelEntry::setLastConnected(const QDateTime& pLastConnected) } +bool RemoteDeviceModelEntry::operator==(const RemoteDeviceModelEntry& pOther) const +{ + return getId() == pOther.getId(); +} + + RemoteDeviceModel::RemoteDeviceModel(QObject* pParent, bool pShowPairedReaders, bool pShowUnpairedReaders) : QAbstractTableModel(pParent) , mPairedReaders() @@ -147,9 +162,10 @@ RemoteDeviceModel::RemoteDeviceModel(QObject* pParent, bool pShowPairedReaders, onKnownRemoteReadersChanged(); const auto& remoteClient = Env::getSingleton(); - connect(remoteClient, &RemoteClient::fireDeviceAppeared, this, &RemoteDeviceModel::onConstructReaderList); - connect(remoteClient, &RemoteClient::fireDeviceUpdated, this, &RemoteDeviceModel::onConstructReaderList); - connect(remoteClient, &RemoteClient::fireDeviceVanished, this, &RemoteDeviceModel::onConstructReaderList); + connect(remoteClient, &RemoteClient::fireDeviceAppeared, this, &RemoteDeviceModel::onUpdateReaderList); + connect(remoteClient, &RemoteClient::fireDeviceUpdated, this, &RemoteDeviceModel::onUpdateReaderList); + connect(remoteClient, &RemoteClient::fireDeviceVanished, this, &RemoteDeviceModel::onUpdateReaderList); + connect(remoteClient, &RemoteClient::fireDispatcherDestroyed, this, &RemoteDeviceModel::onUpdateReaderList); } @@ -221,6 +237,123 @@ QString RemoteDeviceModel::getStatus(const RemoteDeviceModelEntry& pRemoteDevice } +void RemoteDeviceModel::updatePairedReaders() +{ + const auto& availableReaders = presentReaders(); + const auto& connectedDeviceIDs = Env::getSingleton()->getConnectedDeviceIDs(); + + for (const auto& pairedReader : qAsConst(mPairedReaders)) + { + bool visible = false; + bool connected = false; + bool supported = true; + QSharedPointer deviceListEntry; + for (const auto& availableReader : availableReaders) + { + if (pairedReader.getFingerprint() == availableReader.getId()) + { + visible = true; + connected = connectedDeviceIDs.contains(availableReader.getId()); + supported = availableReader.isSupported(); + deviceListEntry = availableReader.getRemoteDeviceListEntry(); + break; + } + } + + if (!visible && connectedDeviceIDs.contains(pairedReader.getFingerprint())) + { + visible = true; + connected = true; + supported = true; + } + auto modelEntry = RemoteDeviceModelEntry( + pairedReader.getName(), + pairedReader.getFingerprint(), + visible, + connected, + supported, + pairedReader.getLastConnected(), + deviceListEntry); + addOrUpdateReader(modelEntry); + } +} + + +void RemoteDeviceModel::updateUnpairedReaders() +{ + const auto availableReaders = presentReaders(); + for (auto modelEntry : availableReaders) + { + if (mPairedReaders.contains(modelEntry.getId())) + { + continue; + } + + addOrUpdateReader(modelEntry); + } +} + + +void RemoteDeviceModel::removeVanishedReaders() +{ + const auto availableReaders = presentReaders(); + for (int i = mAllRemoteReaders.size() - 1; i >= 0; --i) + { + const auto& reader = mAllRemoteReaders[i]; + const bool readerIsPaired = mPairedReaders.contains(reader.getId()); + if (mShowPairedReaders && readerIsPaired) + { + continue; + } + + const bool readerIsAvailable = availableReaders.contains(reader); + const bool showOnlyPairedReader = mShowPairedReaders && !mShowUnpairedReaders; + const bool showOnlyUnpairedReader = mShowUnpairedReaders && !mShowPairedReaders; + if (!readerIsAvailable || (showOnlyPairedReader && !readerIsPaired) || (showOnlyUnpairedReader && readerIsPaired)) + { + beginRemoveRows(QModelIndex(), i, i); + mAllRemoteReaders.remove(i); + endRemoveRows(); + } + } +} + + +QVector RemoteDeviceModel::presentReaders() const +{ + const auto& announcingRemoteDevices = Env::getSingleton()->getAnnouncingRemoteDevices(); + QVector presentReaders; + + for (auto deviceListEntry : announcingRemoteDevices) + { + const auto& deviceDescriptor = deviceListEntry->getRemoteDeviceDescriptor(); + auto modelEntry = RemoteDeviceModelEntry(deviceDescriptor.getIfdName(), deviceDescriptor.getIfdId(), deviceListEntry); + presentReaders.append(modelEntry); + } + + return presentReaders; +} + + +bool RemoteDeviceModel::addOrUpdateReader(const RemoteDeviceModelEntry& pModelEntry) +{ + if (!mAllRemoteReaders.contains(pModelEntry)) + { + const int readerCount = mAllRemoteReaders.size(); + beginInsertRows(index(readerCount, 0), readerCount, readerCount); + mAllRemoteReaders.append(pModelEntry); + endInsertRows(); + return true; + } + + const int readerIndex = mAllRemoteReaders.indexOf(pModelEntry); + mAllRemoteReaders[readerIndex] = pModelEntry; + const auto modelIndex = index(readerIndex, 0); + dataChanged(modelIndex, modelIndex); + return false; +} + + QVariant RemoteDeviceModel::headerData(int pSection, Qt::Orientation pOrientation, int pRole) const { if (pRole == Qt::DisplayRole && pOrientation == Qt::Horizontal) @@ -364,7 +497,7 @@ void RemoteDeviceModel::onUiShown() qDebug() << "Starting Remote Device Detection"; Env::getSingleton()->startDetection(); - onConstructReaderList(); + onUpdateReaderList(); } @@ -377,7 +510,7 @@ void RemoteDeviceModel::onUiHidden() qDebug() << "Stopping Remote Device Detection"; Env::getSingleton()->stopDetection(); - onConstructReaderList(); + onUpdateReaderList(); } @@ -392,84 +525,24 @@ void RemoteDeviceModel::onKnownRemoteReadersChanged() mPairedReaders[reader.getFingerprint()] = reader; } - onConstructReaderList(); + onUpdateReaderList(); } -void RemoteDeviceModel::onConstructReaderList() +void RemoteDeviceModel::onUpdateReaderList() { - beginResetModel(); - mAllRemoteReaders.clear(); - - auto* const remoteClient = Env::getSingleton(); - if (mShowPairedReaders) { - const QVector >& announcingDevices = remoteClient->getAnnouncingRemoteDevices(); - - for (const auto& pairedReader : qAsConst(mPairedReaders)) - { - bool networkVisible = false; - bool supported = true; - QSharedPointer deviceListEntry; - - for (const auto& announcingDevice : announcingDevices) - { - if (announcingDevice && announcingDevice->getRemoteDeviceDescriptor().getIfdId() == pairedReader.getFingerprint()) - { - networkVisible = true; - supported = announcingDevice->getRemoteDeviceDescriptor().isSupported(); - deviceListEntry = announcingDevice; - - break; - } - } - - if (!networkVisible) - { - const QStringList& connectedDeviceIDs = remoteClient->getConnectedDeviceIDs(); - for (const auto& id : connectedDeviceIDs) - { - if (id == pairedReader.getFingerprint()) - { - networkVisible = true; - supported = true; - - break; - } - } - } - - auto newEntry = RemoteDeviceModelEntry(pairedReader.getName() - , pairedReader.getFingerprint() - , true - , networkVisible - , supported - , pairedReader.getLastConnected() - , deviceListEntry); - mAllRemoteReaders.append(newEntry); - } + updatePairedReaders(); } if (mShowUnpairedReaders) { - const QVector >& announcingRemoteDevices = remoteClient->getAnnouncingRemoteDevices(); - - for (auto deviceListEntry : announcingRemoteDevices) - { - if (!mPairedReaders.contains(deviceListEntry->getRemoteDeviceDescriptor().getIfdId())) - { - const RemoteDeviceDescriptor& descriptor = deviceListEntry->getRemoteDeviceDescriptor(); - mAllRemoteReaders.append(RemoteDeviceModelEntry(descriptor.getIfdName(), descriptor.getIfdId(), deviceListEntry)); - } - } + updateUnpairedReaders(); } - std::sort(mAllRemoteReaders.begin(), mAllRemoteReaders.end(), [](const RemoteDeviceModelEntry& pFirst, const RemoteDeviceModelEntry& pSecond){ - return pFirst.getDeviceName() < pSecond.getDeviceName(); - }); + removeVanishedReaders(); - endResetModel(); Q_EMIT fireModelChanged(); } @@ -492,6 +565,7 @@ void RemoteDeviceModel::forgetDevice(const QString& pDeviceId) { RemoteServiceSettings& settings = Env::getSingleton()->getRemoteServiceSettings(); settings.removeTrustedCertificate(pDeviceId); + onKnownRemoteReadersChanged(); } @@ -501,7 +575,7 @@ QString RemoteDeviceModel::getEmptyListDescriptionString() const //: Is embedded in a sentence. const QString& hyperlink = QStringLiteral("%2").arg(url, tr("online help")); //: INFO ALL_PLATFORMS No smartphone with enabled remote service was found on the same network. - return tr("No smartphone with enabled remote service found. See %1 for details of use.").arg(hyperlink); + return tr("No smartphone as card reader (Sac) available. Please make sure to activate the \"remote service\" on your smartphone and to connect both devices to the same WiFi. See %1 for details of use.").arg(hyperlink); } @@ -509,5 +583,5 @@ void RemoteDeviceModel::onDeviceDisconnected(GlobalStatus::Code pCloseCode, cons { Q_UNUSED(pCloseCode) Q_UNUSED(pId) - onConstructReaderList(); + onUpdateReaderList(); } diff --git a/src/ui/common/RemoteDeviceModel.h b/src/ui/common/RemoteDeviceModel.h index e958118a2..79eec14d4 100644 --- a/src/ui/common/RemoteDeviceModel.h +++ b/src/ui/common/RemoteDeviceModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the remote device table * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -31,13 +31,14 @@ class RemoteDeviceModelEntry QString mId; bool mPaired; bool mNetworkVisible; + bool mConnected; bool mSupported; QDateTime mLastConnected; QSharedPointer mRemoteDeviceListEntry; public: RemoteDeviceModelEntry(const QString& pDeviceName, const QString& mId, QSharedPointer& pRemoteDeviceListEntry); - RemoteDeviceModelEntry(const QString& pDeviceName, const QString& mId, bool pPaired, bool pNetworkVisible, bool pSupported, const QDateTime& pLastConnected, QSharedPointer& pRemoteDeviceListEntry); + RemoteDeviceModelEntry(const QString& pDeviceName, const QString& mId, bool pNetworkVisible, bool pConnected, bool pSupported, const QDateTime& pLastConnected, QSharedPointer& pRemoteDeviceListEntry); RemoteDeviceModelEntry(const QString& pDeviceName = QStringLiteral("UnknownReader")); bool isPaired() const; @@ -50,6 +51,7 @@ class RemoteDeviceModelEntry void setNetworkVisible(bool pNetworkVisible); const QDateTime& getLastConnected() const; void setLastConnected(const QDateTime& pLastConnected); + bool operator==(const RemoteDeviceModelEntry& pOther) const; const QSharedPointer getRemoteDeviceListEntry() const; QString getDeviceName() const; @@ -75,11 +77,15 @@ class RemoteDeviceModel QTimer mTimer; bool indexIsValid(const QModelIndex& pIndex) const; - QString getStatus(const RemoteDeviceModelEntry& pRemoteDeviceModelEntry) const; + void updatePairedReaders(); + void updateUnpairedReaders(); + void removeVanishedReaders(); + QVector presentReaders() const; + bool addOrUpdateReader(const RemoteDeviceModelEntry& pModelEntry); private Q_SLOTS: - void onConstructReaderList(); + void onUpdateReaderList(); public: enum SettingsRemoteRoles diff --git a/src/ui/common/TrayIcon.cpp b/src/ui/common/TrayIcon.cpp index 46c0d5bfa..cf554d7bc 100644 --- a/src/ui/common/TrayIcon.cpp +++ b/src/ui/common/TrayIcon.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "TrayIcon.h" @@ -43,20 +43,7 @@ TrayIcon::TrayIcon() TrayIcon::~TrayIcon() { -#if !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) - if (mTrayIcon != nullptr) - { - QMenu* menu = mTrayIcon->contextMenu(); - if (menu != nullptr) - { - qDeleteAll(menu->actions()); - delete menu; - } - - delete mTrayIcon; - mTrayIcon = nullptr; - } -#endif + shutdown(); } @@ -98,7 +85,26 @@ void TrayIcon::create() mTrayIcon->show(); //: LABEL DESKTOP - showMessage(QString(), tr("AusweisApp2 was started.")); + showMessage(QCoreApplication::applicationName(), tr("Application was started.")); +#endif +} + + +void TrayIcon::shutdown() +{ +#if !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) + if (mTrayIcon != nullptr) + { + QMenu* menu = mTrayIcon->contextMenu(); + if (menu != nullptr) + { + qDeleteAll(menu->actions()); + delete menu; + } + + delete mTrayIcon; + mTrayIcon = nullptr; + } #endif } @@ -117,7 +123,10 @@ void TrayIcon::hide() void TrayIcon::showMessage(const QString& pTitle, const QString& pMessage) { #if !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) - mTrayIcon->showMessage(pTitle, pMessage, mIcon, 3000); + if (mTrayIcon) + { + mTrayIcon->showMessage(pTitle, pMessage, mIcon, 3000); + } #else Q_UNUSED(pTitle); Q_UNUSED(pMessage); diff --git a/src/ui/common/TrayIcon.h b/src/ui/common/TrayIcon.h index c67611d2e..b8f096cbf 100644 --- a/src/ui/common/TrayIcon.h +++ b/src/ui/common/TrayIcon.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -36,6 +36,7 @@ class TrayIcon const QIcon& getIcon() const; void create(); + void shutdown(); void hide(); void showMessage(const QString& pTitle, const QString& pMessage); diff --git a/src/ui/json/MessageDispatcher.cpp b/src/ui/json/MessageDispatcher.cpp index 71d469461..ea8e2d7b1 100644 --- a/src/ui/json/MessageDispatcher.cpp +++ b/src/ui/json/MessageDispatcher.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MessageDispatcher.h" diff --git a/src/ui/json/MessageDispatcher.h b/src/ui/json/MessageDispatcher.h index bb25cbd21..4f3857012 100644 --- a/src/ui/json/MessageDispatcher.h +++ b/src/ui/json/MessageDispatcher.h @@ -1,7 +1,7 @@ /*! * \brief Dispatch Messages of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/UIPlugInJson.cpp b/src/ui/json/UIPlugInJson.cpp index 3c87720de..4cfc84577 100644 --- a/src/ui/json/UIPlugInJson.cpp +++ b/src/ui/json/UIPlugInJson.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugInJson.h" @@ -79,7 +79,7 @@ void UIPlugInJson::onWorkflowStarted(QSharedPointer pContext) } -void UIPlugInJson::onWorkflowFinished(QSharedPointer ) +void UIPlugInJson::onWorkflowFinished(QSharedPointer) { if (!mEnabled) { diff --git a/src/ui/json/UIPlugInJson.h b/src/ui/json/UIPlugInJson.h index de8bb1c85..70b3ad5aa 100644 --- a/src/ui/json/UIPlugInJson.h +++ b/src/ui/json/UIPlugInJson.h @@ -1,7 +1,7 @@ /*! * \brief UIPlugIn implementation of the Json API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgContext.cpp b/src/ui/json/messages/MsgContext.cpp index 908cf0cdd..32834820b 100644 --- a/src/ui/json/messages/MsgContext.cpp +++ b/src/ui/json/messages/MsgContext.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgContext.h" diff --git a/src/ui/json/messages/MsgContext.h b/src/ui/json/messages/MsgContext.h index 03eafc252..0ebe74f92 100644 --- a/src/ui/json/messages/MsgContext.h +++ b/src/ui/json/messages/MsgContext.h @@ -1,7 +1,7 @@ /*! * \brief Context of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandler.cpp b/src/ui/json/messages/MsgHandler.cpp index 4dd753f10..ee5bbc54c 100644 --- a/src/ui/json/messages/MsgHandler.cpp +++ b/src/ui/json/messages/MsgHandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandler.h" diff --git a/src/ui/json/messages/MsgHandler.h b/src/ui/json/messages/MsgHandler.h index bf879a2aa..d8d75d6e1 100644 --- a/src/ui/json/messages/MsgHandler.h +++ b/src/ui/json/messages/MsgHandler.h @@ -1,7 +1,7 @@ /*! * \brief Base of all messages of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerAccessRights.cpp b/src/ui/json/messages/MsgHandlerAccessRights.cpp index df721d0f9..fb8811f48 100644 --- a/src/ui/json/messages/MsgHandlerAccessRights.cpp +++ b/src/ui/json/messages/MsgHandlerAccessRights.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerAccessRights.h" @@ -90,7 +90,7 @@ QJsonArray MsgHandlerAccessRights::getAccessRights(const QSet& pRig { QJsonArray array; - QList accessRights = pRights.toList(); + QList accessRights = pRights.values(); std::sort(accessRights.rbegin(), accessRights.rend()); for (auto entry : qAsConst(accessRights)) { diff --git a/src/ui/json/messages/MsgHandlerAccessRights.h b/src/ui/json/messages/MsgHandlerAccessRights.h index b1c50fce0..819cbb756 100644 --- a/src/ui/json/messages/MsgHandlerAccessRights.h +++ b/src/ui/json/messages/MsgHandlerAccessRights.h @@ -1,7 +1,7 @@ /*! * \brief Message MsgHandlerAccessRights of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerApiLevel.cpp b/src/ui/json/messages/MsgHandlerApiLevel.cpp index d12294674..952b9e161 100644 --- a/src/ui/json/messages/MsgHandlerApiLevel.cpp +++ b/src/ui/json/messages/MsgHandlerApiLevel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerApiLevel.h" diff --git a/src/ui/json/messages/MsgHandlerApiLevel.h b/src/ui/json/messages/MsgHandlerApiLevel.h index 523420e9e..95e5041b2 100644 --- a/src/ui/json/messages/MsgHandlerApiLevel.h +++ b/src/ui/json/messages/MsgHandlerApiLevel.h @@ -1,7 +1,7 @@ /*! * \brief Message API_LEVEL of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerAuth.cpp b/src/ui/json/messages/MsgHandlerAuth.cpp index bc5e59ea0..67d51e74f 100644 --- a/src/ui/json/messages/MsgHandlerAuth.cpp +++ b/src/ui/json/messages/MsgHandlerAuth.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerAuth.h" diff --git a/src/ui/json/messages/MsgHandlerAuth.h b/src/ui/json/messages/MsgHandlerAuth.h index 8724ca284..8ce053bfd 100644 --- a/src/ui/json/messages/MsgHandlerAuth.h +++ b/src/ui/json/messages/MsgHandlerAuth.h @@ -1,7 +1,7 @@ /*! * \brief Message Auth of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerBadState.cpp b/src/ui/json/messages/MsgHandlerBadState.cpp index 57e2832fd..d01776b2c 100644 --- a/src/ui/json/messages/MsgHandlerBadState.cpp +++ b/src/ui/json/messages/MsgHandlerBadState.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerBadState.h" diff --git a/src/ui/json/messages/MsgHandlerBadState.h b/src/ui/json/messages/MsgHandlerBadState.h index 446a787f7..db933fbba 100644 --- a/src/ui/json/messages/MsgHandlerBadState.h +++ b/src/ui/json/messages/MsgHandlerBadState.h @@ -1,7 +1,7 @@ /*! * \brief Message BadState of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerCertificate.cpp b/src/ui/json/messages/MsgHandlerCertificate.cpp index 31e714ba9..0756a9cd0 100644 --- a/src/ui/json/messages/MsgHandlerCertificate.cpp +++ b/src/ui/json/messages/MsgHandlerCertificate.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerCertificate.h" diff --git a/src/ui/json/messages/MsgHandlerCertificate.h b/src/ui/json/messages/MsgHandlerCertificate.h index a59b2ec59..aafe40ac4 100644 --- a/src/ui/json/messages/MsgHandlerCertificate.h +++ b/src/ui/json/messages/MsgHandlerCertificate.h @@ -1,7 +1,7 @@ /*! * \brief Message handler for GET_CERTIFICATE of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerEnterCan.cpp b/src/ui/json/messages/MsgHandlerEnterCan.cpp index c4b2dff7f..4d08cb2c1 100644 --- a/src/ui/json/messages/MsgHandlerEnterCan.cpp +++ b/src/ui/json/messages/MsgHandlerEnterCan.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerEnterCan.h" diff --git a/src/ui/json/messages/MsgHandlerEnterCan.h b/src/ui/json/messages/MsgHandlerEnterCan.h index 1cac03da1..1e6457d27 100644 --- a/src/ui/json/messages/MsgHandlerEnterCan.h +++ b/src/ui/json/messages/MsgHandlerEnterCan.h @@ -1,7 +1,7 @@ /*! * \brief Message EnterCan of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerEnterNumber.cpp b/src/ui/json/messages/MsgHandlerEnterNumber.cpp index 0c150497f..30ed82e63 100644 --- a/src/ui/json/messages/MsgHandlerEnterNumber.cpp +++ b/src/ui/json/messages/MsgHandlerEnterNumber.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerEnterNumber.h" diff --git a/src/ui/json/messages/MsgHandlerEnterNumber.h b/src/ui/json/messages/MsgHandlerEnterNumber.h index 54d6e94a4..34b99c8f3 100644 --- a/src/ui/json/messages/MsgHandlerEnterNumber.h +++ b/src/ui/json/messages/MsgHandlerEnterNumber.h @@ -1,7 +1,7 @@ /*! * \brief Helper handler for EnterCan, EnterPin and EnterPuk of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerEnterPin.cpp b/src/ui/json/messages/MsgHandlerEnterPin.cpp index e01ecec09..d30a3c56a 100644 --- a/src/ui/json/messages/MsgHandlerEnterPin.cpp +++ b/src/ui/json/messages/MsgHandlerEnterPin.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerEnterPin.h" diff --git a/src/ui/json/messages/MsgHandlerEnterPin.h b/src/ui/json/messages/MsgHandlerEnterPin.h index c1fe819f9..a618f81f2 100644 --- a/src/ui/json/messages/MsgHandlerEnterPin.h +++ b/src/ui/json/messages/MsgHandlerEnterPin.h @@ -1,7 +1,7 @@ /*! * \brief Message EnterPin of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerEnterPuk.cpp b/src/ui/json/messages/MsgHandlerEnterPuk.cpp index 5cd7f8538..bcb38f1c8 100644 --- a/src/ui/json/messages/MsgHandlerEnterPuk.cpp +++ b/src/ui/json/messages/MsgHandlerEnterPuk.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerEnterPuk.h" diff --git a/src/ui/json/messages/MsgHandlerEnterPuk.h b/src/ui/json/messages/MsgHandlerEnterPuk.h index ce89f2431..f24318620 100644 --- a/src/ui/json/messages/MsgHandlerEnterPuk.h +++ b/src/ui/json/messages/MsgHandlerEnterPuk.h @@ -1,7 +1,7 @@ /*! * \brief Message EnterPuk of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerInfo.cpp b/src/ui/json/messages/MsgHandlerInfo.cpp index 1c6ffd247..f02d628be 100644 --- a/src/ui/json/messages/MsgHandlerInfo.cpp +++ b/src/ui/json/messages/MsgHandlerInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerInfo.h" diff --git a/src/ui/json/messages/MsgHandlerInfo.h b/src/ui/json/messages/MsgHandlerInfo.h index 68e84c62a..1b513aace 100644 --- a/src/ui/json/messages/MsgHandlerInfo.h +++ b/src/ui/json/messages/MsgHandlerInfo.h @@ -1,7 +1,7 @@ /*! * \brief Message Info of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerInsertCard.cpp b/src/ui/json/messages/MsgHandlerInsertCard.cpp index 46509b0e2..192d6957b 100644 --- a/src/ui/json/messages/MsgHandlerInsertCard.cpp +++ b/src/ui/json/messages/MsgHandlerInsertCard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerInsertCard.h" diff --git a/src/ui/json/messages/MsgHandlerInsertCard.h b/src/ui/json/messages/MsgHandlerInsertCard.h index 1afd72512..33aa6739c 100644 --- a/src/ui/json/messages/MsgHandlerInsertCard.h +++ b/src/ui/json/messages/MsgHandlerInsertCard.h @@ -1,7 +1,7 @@ /*! * \brief Message InsertCard of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerInternalError.cpp b/src/ui/json/messages/MsgHandlerInternalError.cpp index 8c76b1d3e..d1ec30659 100644 --- a/src/ui/json/messages/MsgHandlerInternalError.cpp +++ b/src/ui/json/messages/MsgHandlerInternalError.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerInternalError.h" diff --git a/src/ui/json/messages/MsgHandlerInternalError.h b/src/ui/json/messages/MsgHandlerInternalError.h index 396442a42..729fb9762 100644 --- a/src/ui/json/messages/MsgHandlerInternalError.h +++ b/src/ui/json/messages/MsgHandlerInternalError.h @@ -1,7 +1,7 @@ /*! * \brief Message INTERNAL_ERROR of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerInvalid.cpp b/src/ui/json/messages/MsgHandlerInvalid.cpp index 76d320243..f999bfeca 100644 --- a/src/ui/json/messages/MsgHandlerInvalid.cpp +++ b/src/ui/json/messages/MsgHandlerInvalid.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerInvalid.h" diff --git a/src/ui/json/messages/MsgHandlerInvalid.h b/src/ui/json/messages/MsgHandlerInvalid.h index 3fb022f16..ac13924eb 100644 --- a/src/ui/json/messages/MsgHandlerInvalid.h +++ b/src/ui/json/messages/MsgHandlerInvalid.h @@ -1,7 +1,7 @@ /*! * \brief Message Invalid of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerLog.cpp b/src/ui/json/messages/MsgHandlerLog.cpp index d0f9f40a2..da780b310 100644 --- a/src/ui/json/messages/MsgHandlerLog.cpp +++ b/src/ui/json/messages/MsgHandlerLog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerLog.h" diff --git a/src/ui/json/messages/MsgHandlerLog.h b/src/ui/json/messages/MsgHandlerLog.h index ac6142c8d..3e46ae80c 100644 --- a/src/ui/json/messages/MsgHandlerLog.h +++ b/src/ui/json/messages/MsgHandlerLog.h @@ -1,7 +1,7 @@ /*! * \brief Message Log of JSON API. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerReader.cpp b/src/ui/json/messages/MsgHandlerReader.cpp index 0307cd7db..fa8502580 100644 --- a/src/ui/json/messages/MsgHandlerReader.cpp +++ b/src/ui/json/messages/MsgHandlerReader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerReader.h" diff --git a/src/ui/json/messages/MsgHandlerReader.h b/src/ui/json/messages/MsgHandlerReader.h index 4919b2eb9..210ba2b71 100644 --- a/src/ui/json/messages/MsgHandlerReader.h +++ b/src/ui/json/messages/MsgHandlerReader.h @@ -1,7 +1,7 @@ /*! * \brief Message Reader of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerReaderList.cpp b/src/ui/json/messages/MsgHandlerReaderList.cpp index 477221600..57f16a0c4 100644 --- a/src/ui/json/messages/MsgHandlerReaderList.cpp +++ b/src/ui/json/messages/MsgHandlerReaderList.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerReaderList.h" diff --git a/src/ui/json/messages/MsgHandlerReaderList.h b/src/ui/json/messages/MsgHandlerReaderList.h index 51617a9b0..350fc51f5 100644 --- a/src/ui/json/messages/MsgHandlerReaderList.h +++ b/src/ui/json/messages/MsgHandlerReaderList.h @@ -1,7 +1,7 @@ /*! * \brief Message ReaderList of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgHandlerUnknownCommand.cpp b/src/ui/json/messages/MsgHandlerUnknownCommand.cpp index e0349185d..df3a7d399 100644 --- a/src/ui/json/messages/MsgHandlerUnknownCommand.cpp +++ b/src/ui/json/messages/MsgHandlerUnknownCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerUnknownCommand.h" diff --git a/src/ui/json/messages/MsgHandlerUnknownCommand.h b/src/ui/json/messages/MsgHandlerUnknownCommand.h index ab783750c..1df9a2962 100644 --- a/src/ui/json/messages/MsgHandlerUnknownCommand.h +++ b/src/ui/json/messages/MsgHandlerUnknownCommand.h @@ -1,7 +1,7 @@ /*! * \brief MsgHandlerUnknownCommand of JSON API. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/json/messages/MsgTypes.cpp b/src/ui/json/messages/MsgTypes.cpp index 013ac6a7d..c33b43941 100644 --- a/src/ui/json/messages/MsgTypes.cpp +++ b/src/ui/json/messages/MsgTypes.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgTypes.h" diff --git a/src/ui/json/messages/MsgTypes.h b/src/ui/json/messages/MsgTypes.h index 0b3a04ec0..944400ee6 100644 --- a/src/ui/json/messages/MsgTypes.h +++ b/src/ui/json/messages/MsgTypes.h @@ -1,7 +1,7 @@ /*! * \brief Enumerations of message types and additional stuff. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/AppUpdateDataModel.cpp b/src/ui/qml/AppUpdateDataModel.cpp index 365dca4f4..ec8f26816 100644 --- a/src/ui/qml/AppUpdateDataModel.cpp +++ b/src/ui/qml/AppUpdateDataModel.cpp @@ -1,11 +1,11 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "AppUpdateDataModel.h" +#include "AppUpdater.h" #include "Env.h" -#include "Service.h" #include "SingletonHelper.h" using namespace governikus; @@ -14,8 +14,9 @@ defineSingleton(AppUpdateDataModel) AppUpdateDataModel::AppUpdateDataModel() : QObject() - , mAppUpdateData(Env::getSingleton()->getUpdateData()) + , mUpdateAvailable(false) { + connect(Env::getSingleton(), &AppUpdater::fireAppUpdateCheckFinished, this, &AppUpdateDataModel::onAppUpdateCheckFinished); } @@ -25,55 +26,72 @@ AppUpdateDataModel& AppUpdateDataModel::getInstance() } +void AppUpdateDataModel::onAppUpdateCheckFinished(bool pUpdateAvailable, const GlobalStatus& pStatus) +{ + Q_UNUSED(pStatus) + mUpdateAvailable = pUpdateAvailable; + Q_EMIT fireAppUpdateDataChanged(); +} + + +bool AppUpdateDataModel::isUpdateAvailable() const +{ + return mUpdateAvailable; +} + + bool AppUpdateDataModel::isValid() const { - return mAppUpdateData.isValid(); + return Env::getSingleton()->getUpdateData().isValid(); } -const QDateTime AppUpdateDataModel::getDate() const +const QDateTime& AppUpdateDataModel::getDate() const { - return mAppUpdateData.getDate(); + return Env::getSingleton()->getUpdateData().getDate(); } const QString& AppUpdateDataModel::getVersion() const { - return mAppUpdateData.getVersion(); + return Env::getSingleton()->getUpdateData().getVersion(); } const QUrl& AppUpdateDataModel::getUrl() const { - return mAppUpdateData.getUrl(); + return Env::getSingleton()->getUpdateData().getUrl(); } int AppUpdateDataModel::getSize() const { - return mAppUpdateData.getSize(); + return Env::getSingleton()->getUpdateData().getSize(); } const QUrl& AppUpdateDataModel::getChecksumUrl() const { - return mAppUpdateData.getChecksumUrl(); + return Env::getSingleton()->getUpdateData().getChecksumUrl(); } const QUrl& AppUpdateDataModel::getNotesUrl() const { - return mAppUpdateData.getNotesUrl(); + return Env::getSingleton()->getUpdateData().getNotesUrl(); } const QString& AppUpdateDataModel::getNotes() const { - return mAppUpdateData.getNotes(); + return Env::getSingleton()->getUpdateData().getNotes(); } -void AppUpdateDataModel::onAppUpdateFinished(bool, const GlobalStatus&) +void AppUpdateDataModel::skipUpdate() const { - mAppUpdateData = Env::getSingleton()->getUpdateData(); + if (isValid()) + { + Env::getSingleton()->skipVersion(getVersion()); + } } diff --git a/src/ui/qml/AppUpdateDataModel.h b/src/ui/qml/AppUpdateDataModel.h index f98320a02..58aaa5024 100644 --- a/src/ui/qml/AppUpdateDataModel.h +++ b/src/ui/qml/AppUpdateDataModel.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -17,6 +17,7 @@ class AppUpdateDataModel Q_OBJECT friend class Env; + Q_PROPERTY(bool updateAvailable READ isUpdateAvailable NOTIFY fireAppUpdateDataChanged) Q_PROPERTY(bool valid READ isValid NOTIFY fireAppUpdateDataChanged) Q_PROPERTY(QDateTime date READ getDate NOTIFY fireAppUpdateDataChanged) Q_PROPERTY(QString version READ getVersion NOTIFY fireAppUpdateDataChanged) @@ -26,25 +27,26 @@ class AppUpdateDataModel Q_PROPERTY(QUrl notesUrl READ getNotesUrl() NOTIFY fireAppUpdateDataChanged) Q_PROPERTY(QString notes READ getNotes() NOTIFY fireAppUpdateDataChanged) - private: - AppUpdateData mAppUpdateData; - protected: AppUpdateDataModel(); static AppUpdateDataModel& getInstance(); + bool mUpdateAvailable; + + private Q_SLOTS: + void onAppUpdateCheckFinished(bool pUpdateAvailable, const GlobalStatus& pStatus); + public: + bool isUpdateAvailable() const; bool isValid() const; - const QDateTime getDate() const; + const QDateTime& getDate() const; const QString& getVersion() const; const QUrl& getUrl() const; int getSize() const; const QUrl& getChecksumUrl() const; const QUrl& getNotesUrl() const; const QString& getNotes() const; - - public Q_SLOTS: - void onAppUpdateFinished(bool, const GlobalStatus&); + Q_INVOKABLE void skipUpdate() const; Q_SIGNALS: void fireAppUpdateDataChanged(); diff --git a/src/ui/qml/ApplicationModel.cpp b/src/ui/qml/ApplicationModel.cpp index 69dcb2274..31b420fb5 100644 --- a/src/ui/qml/ApplicationModel.cpp +++ b/src/ui/qml/ApplicationModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ApplicationModel.h" @@ -16,7 +16,9 @@ #include "ReaderInfo.h" #include "ReaderManager.h" #include "RemoteClient.h" +#include "SecureStorage.h" #include "SingletonHelper.h" +#include "VersionNumber.h" #if !defined(Q_OS_WINRT) && !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) #include "PdfExporter.h" @@ -123,6 +125,14 @@ QString ApplicationModel::getPackageName() const } +QUrl ApplicationModel::getReleaseNotesUrl() const +{ + const auto storage = Env::getSingleton(); + const auto& url = VersionNumber::getApplicationVersion().isDeveloperVersion() ? storage->getAppcastBetaUpdateUrl() : storage->getAppcastUpdateUrl(); + return url.adjusted(QUrl::RemoveFilename).toString() + QStringLiteral("ReleaseNotes.html"); +} + + ReaderManagerPlugInInfo ApplicationModel::getFirstPlugInInfo(ReaderManagerPlugInType pType) const { const auto pluginInfos = Env::getSingleton()->getPlugInInfos(); @@ -339,6 +349,17 @@ void ApplicationModel::showSettings(const ApplicationModel::Settings& pAction) switch (pAction) { + case Settings::SETTING_WIFI: + if (QOperatingSystemVersion::current() >= androidQ) + { + showSettings(QStringLiteral("android.settings.panel.action.WIFI")); + } + else + { + showSettings(QStringLiteral("android.settings.WIRELESS_SETTINGS")); + } + break; + case Settings::SETTING_NETWORK: if (QOperatingSystemVersion::current() >= androidQ) { @@ -516,7 +537,7 @@ void ApplicationModel::openOnlineHelp(const QString& pHelpSectionName) #if defined(Q_OS_ANDROID) || defined(Q_OS_IOS) qCWarning(qml) << "NOT IMPLEMENTED:" << pHelpSectionName; #else - HelpAction::openContextHelp(pHelpSectionName); + HelpAction::openContextHelp(pHelpSectionName, false); #endif } @@ -532,8 +553,8 @@ void ApplicationModel::enableWifi() { #ifdef Q_OS_IOS showFeedback(tr("Please enable Wi-Fi in your system settings.")); -#else - mWifiInfo.enableWifi(); +#elif defined(Q_OS_ANDROID) + showSettings(Settings::SETTING_WIFI); #endif } diff --git a/src/ui/qml/ApplicationModel.h b/src/ui/qml/ApplicationModel.h index e1e138296..e712850fe 100644 --- a/src/ui/qml/ApplicationModel.h +++ b/src/ui/qml/ApplicationModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the application. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -32,6 +32,7 @@ class ApplicationModel friend class Env; Q_PROPERTY(QString packageName READ getPackageName CONSTANT) + Q_PROPERTY(QUrl releaseNotesUrl READ getReleaseNotesUrl CONSTANT) Q_PROPERTY(bool nfcEnabled READ isNfcEnabled NOTIFY fireNfcEnabledChanged) Q_PROPERTY(bool nfcAvailable READ isNfcAvailable CONSTANT) @@ -87,6 +88,7 @@ class ApplicationModel public: enum class Settings { + SETTING_WIFI, SETTING_NETWORK, SETTING_NFC, SETTING_BLUETOOTH @@ -96,6 +98,7 @@ class ApplicationModel void resetContext(const QSharedPointer& pContext = QSharedPointer()); QString getPackageName() const; + QUrl getReleaseNotesUrl() const; bool isNfcAvailable() const; bool isNfcEnabled() const; diff --git a/src/ui/qml/ApplicationModel_ios.mm b/src/ui/qml/ApplicationModel_ios.mm index 59da1d1ba..249c57a38 100644 --- a/src/ui/qml/ApplicationModel_ios.mm +++ b/src/ui/qml/ApplicationModel_ios.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "ApplicationModel.h" diff --git a/src/ui/qml/AuthModel.cpp b/src/ui/qml/AuthModel.cpp index bd1530f53..426765b7f 100644 --- a/src/ui/qml/AuthModel.cpp +++ b/src/ui/qml/AuthModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "AuthModel.h" diff --git a/src/ui/qml/AuthModel.h b/src/ui/qml/AuthModel.h index c218c439f..71bfc1ade 100644 --- a/src/ui/qml/AuthModel.h +++ b/src/ui/qml/AuthModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the authentication action. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/CMakeLists.txt b/src/ui/qml/CMakeLists.txt index 98087cb3b..6c4035d69 100644 --- a/src/ui/qml/CMakeLists.txt +++ b/src/ui/qml/CMakeLists.txt @@ -18,10 +18,3 @@ IF(TARGET Qt5::Bluetooth) ENDIF() TARGET_COMPILE_DEFINITIONS(AusweisAppUiQml PRIVATE QT_STATICPLUGIN) - -STRING(REPLACE "\\" "/" RES_DIR ${RESOURCES_DIR}) -IF(CMAKE_GENERATOR STREQUAL Xcode OR CMAKE_VERSION VERSION_LESS "3.8") - TARGET_COMPILE_DEFINITIONS(AusweisAppUiQml PRIVATE $<$:RES_DIR="\\"${RES_DIR}\\"">) -ELSE() - SET_PROPERTY(SOURCE "UIPlugInQml.cpp" APPEND PROPERTY COMPILE_FLAGS $<$:-DRES_DIR="\\"${RES_DIR}\\"">) -ENDIF() diff --git a/src/ui/qml/CertificateDescriptionModel.cpp b/src/ui/qml/CertificateDescriptionModel.cpp index 8784bffa9..a3f1ae6c5 100644 --- a/src/ui/qml/CertificateDescriptionModel.cpp +++ b/src/ui/qml/CertificateDescriptionModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "CertificateDescriptionModel.h" @@ -45,23 +45,23 @@ void CertificateDescriptionModel::initModelData(const QSharedPointer(tr("Service provider"), getSubjectName() + QLatin1Char('\n') + getSubjectUrl()); + mData += QPair(tr("Provider"), getSubjectName() + QLatin1Char('\n') + getSubjectUrl()); //: LABEL ALL_PLATFORMS mData += QPair(tr("Certificate issuer"), pCertDescription->getIssuerName() + QLatin1Char('\n') + pCertDescription->getIssuerUrl()); if (showDetailedProviderInfo) { //: LABEL ALL_PLATFORMS - mData += QPair(tr("Name, address and mail address of the service provider"), serviceProviderAddress); + mData += QPair(tr("Name, address and mail address of the provider"), serviceProviderAddress); //: LABEL ALL_PLATFORMS mData += QPair(tr("Purpose"), purpose); //: LABEL ALL_PLATFORMS - mData += QPair(tr("Indication of the bodies responsible for the service provider, " + mData += QPair(tr("Indication of the bodies responsible for the provider, " "that verify the compliance with data security regulations"), dataSecurityOfficer); } else if (!termsOfUsage.isEmpty()) { //: LABEL ALL_PLATFORMS - mData += QPair(tr("Service provider information"), termsOfUsage); + mData += QPair(tr("Provider information"), termsOfUsage); } if (!getValidity().isEmpty()) { diff --git a/src/ui/qml/CertificateDescriptionModel.h b/src/ui/qml/CertificateDescriptionModel.h index 8c66b761d..cb7010988 100644 --- a/src/ui/qml/CertificateDescriptionModel.h +++ b/src/ui/qml/CertificateDescriptionModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the CV certificate description. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/ChangePinModel.cpp b/src/ui/qml/ChangePinModel.cpp index 0600af13a..aa721b744 100644 --- a/src/ui/qml/ChangePinModel.cpp +++ b/src/ui/qml/ChangePinModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ChangePinModel.h" diff --git a/src/ui/qml/ChangePinModel.h b/src/ui/qml/ChangePinModel.h index ad828ceb0..30734f275 100644 --- a/src/ui/qml/ChangePinModel.h +++ b/src/ui/qml/ChangePinModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the PIN action. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/ChatModel.cpp b/src/ui/qml/ChatModel.cpp index f2f5b50b5..36fc8d1ef 100644 --- a/src/ui/qml/ChatModel.cpp +++ b/src/ui/qml/ChatModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the chat. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ChatModel.h" @@ -87,7 +87,12 @@ void ChatModel::resetContext(const QSharedPointer& pContext) mAllRights += AccessRight::READ_DG19; mOptionalRights.clear(); + +#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)) + mSelectedRights = QSet(mAllRights.constBegin(), mAllRights.constEnd()); +#else mSelectedRights = mAllRights.toSet(); +#endif endResetModel(); } @@ -159,6 +164,10 @@ QVariant ChatModel::data(const QModelIndex& pIndex, int pRole) const { return mSelectedRights.contains(right); } + if (pRole == WRITE_RIGHT) + { + return AccessRoleAndRightsUtil::isWriteAccessRight(right); + } } return QVariant(); } @@ -170,6 +179,7 @@ QHash ChatModel::roleNames() const roles.insert(NAME_ROLE, "name"); roles.insert(OPTIONAL_ROLE, "optional"); roles.insert(SELECTED_ROLE, "selected"); + roles.insert(WRITE_RIGHT, "writeRight"); return roles; } diff --git a/src/ui/qml/ChatModel.h b/src/ui/qml/ChatModel.h index 829e71638..91e923c2a 100644 --- a/src/ui/qml/ChatModel.h +++ b/src/ui/qml/ChatModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the chat. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -38,7 +38,8 @@ class ChatModel { NAME_ROLE = Qt::UserRole + 1, OPTIONAL_ROLE, - SELECTED_ROLE + SELECTED_ROLE, + WRITE_RIGHT, }; private: diff --git a/src/ui/qml/ConnectivityManager.cpp b/src/ui/qml/ConnectivityManager.cpp index 041b63f7c..16050c5a2 100644 --- a/src/ui/qml/ConnectivityManager.cpp +++ b/src/ui/qml/ConnectivityManager.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ConnectivityManager.h" diff --git a/src/ui/qml/ConnectivityManager.h b/src/ui/qml/ConnectivityManager.h index 3662e2139..d380efaa8 100644 --- a/src/ui/qml/ConnectivityManager.h +++ b/src/ui/qml/ConnectivityManager.h @@ -1,7 +1,7 @@ /*! * \brief Utility class providing information about network connectivity status. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/DpiCalculator.cpp b/src/ui/qml/DpiCalculator.cpp index 61707f6f1..dbd24283b 100644 --- a/src/ui/qml/DpiCalculator.cpp +++ b/src/ui/qml/DpiCalculator.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "DpiCalculator.h" diff --git a/src/ui/qml/DpiCalculator.h b/src/ui/qml/DpiCalculator.h index 52e8db185..94f1c9d16 100644 --- a/src/ui/qml/DpiCalculator.h +++ b/src/ui/qml/DpiCalculator.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/HistoryModel.cpp b/src/ui/qml/HistoryModel.cpp index 196d2fef3..4cd0929d5 100644 --- a/src/ui/qml/HistoryModel.cpp +++ b/src/ui/qml/HistoryModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the history entries. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "HistoryModel.h" @@ -83,6 +83,7 @@ void HistoryModel::onHistoryEntriesChanged() beginResetModel(); updateConnections(); endResetModel(); + Q_EMIT fireEmptyChanged(isEmpty()); } @@ -257,6 +258,13 @@ void HistoryModel::setEnabled(bool pEnabled) } +bool HistoryModel::isEmpty() const +{ + const auto& historyEntries = getHistorySettings().getHistoryInfos(); + return historyEntries.isEmpty(); +} + + QHash HistoryModel::roleNames() const { QHash roles = QAbstractListModel::roleNames(); @@ -286,7 +294,7 @@ QHash HistoryModel::roleNames() const bool HistoryModel::removeRows(int pRow, int pCount, const QModelIndex& pParent) { - if (pCount <= 0) + if (pCount <= 0 || pRow < 0) { return false; } @@ -331,3 +339,16 @@ void HistoryModel::exportHistory(const QUrl& pFilename) const PdfExporter exporter(pFilename.toLocalFile()); exporter.exportHistory(); } + + +#ifndef QT_NO_DEBUG +void HistoryModel::createDummyEntry() +{ + getHistorySettings().addHistoryInfo(HistoryInfo( + QStringLiteral("Dummy Subject"), QStringLiteral("Dummy Subject URL"), QStringLiteral("Dummy Usage"), + QDateTime::currentDateTime(), QStringLiteral("Dummy Term Of Usage"), + {QStringLiteral("Dummy Data 1"), QStringLiteral("Dummy Data 2")})); +} + + +#endif diff --git a/src/ui/qml/HistoryModel.h b/src/ui/qml/HistoryModel.h index ddf1b3923..8b99edd62 100644 --- a/src/ui/qml/HistoryModel.h +++ b/src/ui/qml/HistoryModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the history entries. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -28,6 +28,7 @@ class HistoryModel Q_PROPERTY(ProviderNameFilterModel * nameFilter READ getNameFilterModel CONSTANT) Q_PROPERTY(HistoryModelSearchFilter * searchFilter READ getHistoryModelSearchFilter CONSTANT) Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled NOTIFY fireEnabledChanged) + Q_PROPERTY(bool empty READ isEmpty NOTIFY fireEmptyChanged) HistoryProxyModel mFilterModel; ProviderNameFilterModel mNameFilterModel; @@ -42,6 +43,7 @@ class HistoryModel bool isEnabled() const; void setEnabled(bool pEnabled); + bool isEmpty() const; void updateConnections(); private Q_SLOTS: @@ -50,6 +52,7 @@ class HistoryModel Q_SIGNALS: void fireEnabledChanged(bool pValue); + void fireEmptyChanged(bool pValue); public: explicit HistoryModel(QObject* pParent = nullptr); @@ -89,6 +92,10 @@ class HistoryModel HistoryModelSearchFilter* getHistoryModelSearchFilter(); Q_INVOKABLE void exportHistory(const QUrl& pFilename) const; + +#ifndef QT_NO_DEBUG + Q_INVOKABLE void createDummyEntry(); +#endif }; } // namespace governikus diff --git a/src/ui/qml/HistoryModelSearchFilter.cpp b/src/ui/qml/HistoryModelSearchFilter.cpp index 487659d6b..bed7445ba 100644 --- a/src/ui/qml/HistoryModelSearchFilter.cpp +++ b/src/ui/qml/HistoryModelSearchFilter.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "HistoryModelSearchFilter.h" diff --git a/src/ui/qml/HistoryModelSearchFilter.h b/src/ui/qml/HistoryModelSearchFilter.h index 2200a50c1..79a7ece33 100644 --- a/src/ui/qml/HistoryModelSearchFilter.h +++ b/src/ui/qml/HistoryModelSearchFilter.h @@ -1,7 +1,7 @@ /*! * \brief A filter to search the history model * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/HistoryProxyModel.cpp b/src/ui/qml/HistoryProxyModel.cpp index 796066fdd..79316d325 100644 --- a/src/ui/qml/HistoryProxyModel.cpp +++ b/src/ui/qml/HistoryProxyModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "HistoryProxyModel.h" diff --git a/src/ui/qml/HistoryProxyModel.h b/src/ui/qml/HistoryProxyModel.h index 91427150c..1a0498daa 100644 --- a/src/ui/qml/HistoryProxyModel.h +++ b/src/ui/qml/HistoryProxyModel.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/LogModel.cpp b/src/ui/qml/LogModel.cpp index b92d4365b..b5357dba9 100644 --- a/src/ui/qml/LogModel.cpp +++ b/src/ui/qml/LogModel.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "LogModel.h" @@ -7,9 +7,11 @@ #include "LanguageLoader.h" #include "LogHandler.h" #include "PlatformHelper.h" +#include "Randomizer.h" #include "SettingsModel.h" #include "SingletonHelper.h" +#include #include #include @@ -20,19 +22,9 @@ using namespace governikus; defineSingleton(LogModel) -void LogModel::addLogEntry(const QString& mEntry) +void LogModel::addLogEntry(const QString& pEntry) { - const int cutIndex = mEntry.indexOf(QLatin1String(" : ")); - if (cutIndex >= 0) - { - mLogEntries += mEntry.mid(0, cutIndex).trimmed(); - mLogEntries += mEntry.mid(cutIndex + 3).trimmed(); - } - else - { - mLogEntries += mEntry; - mLogEntries += QString(); - } + mLogEntries.append(pEntry); } @@ -66,9 +58,10 @@ void LogModel::onNewLogMsg(const QString& pMsg) LogModel::LogModel() : QAbstractListModel() , mLogFiles() - , mSelectedLogFile(0) + , mSelectedLogFile(-1) , mLogEntries() { + setLogfile(0); connect(Env::getSingleton(), &SettingsModel::fireLanguageChanged, this, &LogModel::fireLogFilesChanged); // needed to translate the "Current log" entry on language change } @@ -129,6 +122,11 @@ void LogModel::removeCurrentLogfile() void LogModel::setLogfile(int pIndex) { + if (pIndex == mSelectedLogFile) + { + return; + } + mSelectedLogFile = pIndex; const auto& logHandler = Env::getSingleton(); @@ -169,6 +167,19 @@ void LogModel::saveCurrentLogfile(const QUrl& pFilename) const } +#ifndef QT_NO_DEBUG +void LogModel::saveDummyLogfile() const +{ + auto& generator = Randomizer::getInstance().getGenerator(); + std::uniform_int_distribution dist; + const auto logHandler = Env::getSingleton(); + logHandler->copy(QDir::temp().filePath(QStringLiteral("%1.%2.log").arg(QCoreApplication::applicationName()).arg(dist(generator)))); +} + + +#endif + + int LogModel::rowCount(const QModelIndex& pIndex) const { Q_UNUSED(pIndex) @@ -176,10 +187,43 @@ int LogModel::rowCount(const QModelIndex& pIndex) const } +QHash LogModel::roleNames() const +{ + QHash roles; + roles.insert(Qt::DisplayRole, QByteArrayLiteral("display")); + roles.insert(OriginRole, QByteArrayLiteral("origin")); + roles.insert(MessageRole, QByteArrayLiteral("message")); + return roles; +} + + QVariant LogModel::data(const QModelIndex& pIndex, int pRole) const { - Q_UNUSED(pRole) - return mLogEntries.at(pIndex.row()); + static const auto splitToken = QLatin1String(" : "); + + if (!pIndex.isValid()) + { + return QVariant(); + } + + const auto& logMessage = mLogEntries.at(pIndex.row()); + + switch (pRole) + { + case Qt::DisplayRole: + return logMessage; + + case OriginRole: + return logMessage.section(splitToken, 0, 0).trimmed(); + + case MessageRole: + return logMessage.section(splitToken, 1, -1).trimmed(); + + default: + return QVariant(); + } + + Q_UNREACHABLE(); } diff --git a/src/ui/qml/LogModel.h b/src/ui/qml/LogModel.h index eb0f6577e..b5a498256 100644 --- a/src/ui/qml/LogModel.h +++ b/src/ui/qml/LogModel.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -26,6 +26,12 @@ class LogModel Q_OBJECT friend class Env; + enum LogModelRoles + { + OriginRole = Qt::UserRole + 1, + MessageRole + }; + Q_PROPERTY(QStringList logFiles READ getLogfiles NOTIFY fireLogFilesChanged) private: @@ -34,7 +40,7 @@ class LogModel int mSelectedLogFile; QStringList mLogEntries; - void addLogEntry(const QString& mEntry); + void addLogEntry(const QString& pEntry); void setLogEntries(QTextStream& pTextStream); private Q_SLOTS: @@ -51,17 +57,21 @@ class LogModel Q_INVOKABLE void removeCurrentLogfile(); Q_INVOKABLE void setLogfile(int pIndex); Q_INVOKABLE void saveCurrentLogfile(const QUrl& pFilename) const; +#ifndef QT_NO_DEBUG + Q_INVOKABLE void saveDummyLogfile() const; +#endif Q_INVOKABLE void mailLog(const QString& pEmail = tr("support.ausweisapp2@governikus.de"), - const QString& pSubject = tr("Mobile log file"), + const QString& pSubject = tr("Mobile logfile"), const QString& pMsg = tr("")); /// \a popupPosition will be used on an iPad as the origin of the share bubble Q_INVOKABLE void shareLog(QPoint popupPosition); int rowCount(const QModelIndex& pIndex = QModelIndex()) const override; + QHash roleNames() const override; QVariant data(const QModelIndex& pIndex, int pRole = Qt::DisplayRole) const override; - static QString createLogFileName(const QDateTime& pDateTime = QDateTime::currentDateTime()); + Q_INVOKABLE static QString createLogFileName(const QDateTime& pDateTime = QDateTime::currentDateTime()); Q_SIGNALS: void fireLogFilesChanged(); diff --git a/src/ui/qml/LogModel_android.cpp b/src/ui/qml/LogModel_android.cpp index c6408d6a7..315a50ef9 100644 --- a/src/ui/qml/LogModel_android.cpp +++ b/src/ui/qml/LogModel_android.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "LogModel.h" @@ -87,10 +87,10 @@ void LogModel::mailLog(const QString& pEmail, const QString& pSubject, const QSt const auto& publicLogFile = getPublicLogFileName(env, javaActivity, external); const auto& jPublicLogFile = QAndroidJniObject::fromString(publicLogFile); - qCDebug(qml) << "Copy log file to" << publicLogFile; + qCDebug(qml) << "Copy logfile to" << publicLogFile; if (!Env::getSingleton()->copy(publicLogFile)) { - qCCritical(qml) << "Cannot copy log file to" << publicLogFile; + qCCritical(qml) << "Cannot copy logfile to" << publicLogFile; return; } @@ -130,7 +130,7 @@ void LogModel::shareLog(const QPoint /*popupPosition*/) publicLogFile = getPublicLogFileName(env, javaActivity, false); if (!logHandler->copy(publicLogFile)) { - qCCritical(qml) << "Cannot copy log file to" << publicLogFile; + qCCritical(qml) << "Cannot copy logfile to" << publicLogFile; return; } } @@ -145,7 +145,7 @@ void LogModel::shareLog(const QPoint /*popupPosition*/) } if (!QFile::copy(source, publicLogFile)) { - qCCritical(qml) << "Cannot copy log file to" << publicLogFile; + qCCritical(qml) << "Cannot copy logfile to" << publicLogFile; return; } } diff --git a/src/ui/qml/LogModel_generic.cpp b/src/ui/qml/LogModel_generic.cpp index b5b6a1da9..ad4286dd7 100644 --- a/src/ui/qml/LogModel_generic.cpp +++ b/src/ui/qml/LogModel_generic.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "LogModel.h" diff --git a/src/ui/qml/LogModel_ios.mm b/src/ui/qml/LogModel_ios.mm index b44b5b63b..4c299b3d9 100644 --- a/src/ui/qml/LogModel_ios.mm +++ b/src/ui/qml/LogModel_ios.mm @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "LogModel.h" @@ -65,7 +65,7 @@ - (void)mailComposeController:(MFMailComposeViewController*)controller didFinish { if (!QFile::copy(pSourceFile.value(), destinationFilePath)) { - qCCritical(qml) << "Cannot copy log file to" << destinationFilePath; + qCCritical(qml) << "Cannot copy logfile to" << destinationFilePath; return std::nullopt; } } @@ -96,7 +96,7 @@ - (void)mailComposeController:(MFMailComposeViewController*)controller didFinish NSData* fileContent = [NSData dataWithContentsOfFile: logFile.value().toNSString()]; - UIViewController* rootController = [[UIApplication sharedApplication].windows[0] rootViewController]; + UIViewController* rootController = [UIApplication sharedApplication].windows[0].rootViewController; auto* mailComposeController = [[MailComposeController alloc] init]; mailComposeController.mailComposeDelegate = mailComposeController; @@ -132,7 +132,7 @@ - (void)mailComposeController:(MFMailComposeViewController*)controller didFinish UIActivityViewController* shareController = [[UIActivityViewController alloc]initWithActivityItems: shareItems applicationActivities:nil]; - UIViewController* rootController = [[UIApplication sharedApplication].windows[0] rootViewController]; + UIViewController* rootController = [UIApplication sharedApplication].windows[0].rootViewController; shareController.popoverPresentationController.sourceView = rootController.view; shareController.popoverPresentationController.sourceRect = CGRectMake(popupPosition.x(), popupPosition.y(), 0, 0); diff --git a/src/ui/qml/NotificationModel.cpp b/src/ui/qml/NotificationModel.cpp index b73e81799..5a95ae14c 100644 --- a/src/ui/qml/NotificationModel.cpp +++ b/src/ui/qml/NotificationModel.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "NotificationModel.h" diff --git a/src/ui/qml/NotificationModel.h b/src/ui/qml/NotificationModel.h index 0ee43c2dd..8f0cbea68 100644 --- a/src/ui/qml/NotificationModel.h +++ b/src/ui/qml/NotificationModel.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/NumberModel.cpp b/src/ui/qml/NumberModel.cpp index ad8ba6309..59885c308 100644 --- a/src/ui/qml/NumberModel.cpp +++ b/src/ui/qml/NumberModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "NumberModel.h" @@ -61,7 +61,7 @@ void NumberModel::resetContext(const QSharedPointer& pContext) connect(mContext.data(), &WorkflowContext::firePaceResultUpdated, this, &NumberModel::fireInputErrorChanged); // The length of the pin doesn't matter for the core. Requesting - // a 5 or 6 digits PIN is only part of the gui. Therefore we handle + // a 5- or 6-digit PIN is only part of the gui. Therefore we handle // this state in the NumberModel. The only case where the core need // to know if the transport PIN should be requested is, when we // are in an authentication workflow and want to start a pin change. @@ -241,23 +241,23 @@ QString NumberModel::getInputError() const case CardReturnCode::INVALID_PIN_2: //: INFO ALL_PLATFORMS The wrong PIN was entered twice, the next attempt requires the CAN for additional verification. - return tr("You have entered the wrong PIN twice. " - "Prior to a third attempt, you have to enter your six-digit card access number first. " - "You can find your card access number on the front of your ID card."); + return tr("A wrong PIN has been entered twice on your ID card. " + "Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. " + "You can find your card access number (CAN) on the front of your ID card."); case CardReturnCode::INVALID_PIN_3: - //: INFO ALL_PLATFORMS The PIN was entered wrongfully three times, the id card needs to be unlocked using the PUK. - return tr("You have entered a wrong PIN three times. " + //: INFO ALL_PLATFORMS The PIN was entered wrongfully three times, the ID card needs to be unlocked using the PUK. + return tr("A wrong PIN has been entered three times on your ID card. " "Your PIN is now blocked. " - "You have to enter the PUK now for unblocking."); + "To unblock your PIN you have to enter the PUK."); case CardReturnCode::INVALID_CAN: //: INFO ALL_PLATFORMS The CAN was entered wrongfully and needs to be supplied again. - return tr("You have entered a wrong CAN, please try again."); + return tr("The entered card access number (CAN) is incorrect. Please try again."); case CardReturnCode::INVALID_PUK: //: INFO ALL_PLATFORMS The PUK entered wrongfully and needs to be supplied again. - return tr("You have entered a wrong PUK. " + return tr("The entered PUK is incorrect. " "Please try again."); default: diff --git a/src/ui/qml/NumberModel.h b/src/ui/qml/NumberModel.h index 42889172e..c4649f59e 100644 --- a/src/ui/qml/NumberModel.h +++ b/src/ui/qml/NumberModel.h @@ -2,7 +2,7 @@ * \brief Model for accessing PIN, CAN, PUK, according to the * currently active workflow. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -29,7 +29,6 @@ class NumberModel Q_PROPERTY(QString puk READ getPuk WRITE setPuk NOTIFY firePukChanged) Q_PROPERTY(bool hasError READ hasError NOTIFY fireInputErrorChanged) Q_PROPERTY(bool hasPasswordError READ hasPasswordError NOTIFY fireInputErrorChanged) - Q_PROPERTY(CardReturnCode inputErrorCode READ getInputErrorCode NOTIFY fireInputErrorChanged) Q_PROPERTY(QString inputError READ getInputError NOTIFY fireInputErrorChanged) Q_PROPERTY(int retryCounter READ getRetryCounter NOTIFY fireReaderInfoChanged) Q_PROPERTY(bool pinDeactivated READ isPinDeactivated NOTIFY fireReaderInfoChanged) @@ -41,6 +40,8 @@ class NumberModel bool mRequestTransportPin; bool mRequestNewPin; + CardReturnCode getInputErrorCode() const; + private Q_SLOTS: void onCardConnectionChanged(); @@ -75,7 +76,6 @@ class NumberModel bool hasError() const; bool hasPasswordError() const; - CardReturnCode getInputErrorCode() const; QString getInputError() const; int getRetryCounter() const; diff --git a/src/ui/qml/PlatformHelper.cpp b/src/ui/qml/PlatformHelper.cpp index d42b7d3d9..a0d6a56e4 100644 --- a/src/ui/qml/PlatformHelper.cpp +++ b/src/ui/qml/PlatformHelper.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "PlatformHelper.h" diff --git a/src/ui/qml/PlatformHelper.h b/src/ui/qml/PlatformHelper.h index 8a31149bd..f2f8c7463 100644 --- a/src/ui/qml/PlatformHelper.h +++ b/src/ui/qml/PlatformHelper.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/ProviderCategoryFilterModel.cpp b/src/ui/qml/ProviderCategoryFilterModel.cpp index 764228f4b..8d369bd1c 100644 --- a/src/ui/qml/ProviderCategoryFilterModel.cpp +++ b/src/ui/qml/ProviderCategoryFilterModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderCategoryFilterModel.h" @@ -27,7 +27,7 @@ void ProviderCategoryFilterModel::updateSearchString(const QString& pSearchStrin QStringList ProviderCategoryFilterModel::getSelectedCategories() const { - return mSelectedCategories.toList(); + return mSelectedCategories.values(); } diff --git a/src/ui/qml/ProviderCategoryFilterModel.h b/src/ui/qml/ProviderCategoryFilterModel.h index 800135137..d8fd6f2af 100644 --- a/src/ui/qml/ProviderCategoryFilterModel.h +++ b/src/ui/qml/ProviderCategoryFilterModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the providers. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/ProviderModel.cpp b/src/ui/qml/ProviderModel.cpp index dd1424f2a..189f6b515 100644 --- a/src/ui/qml/ProviderModel.cpp +++ b/src/ui/qml/ProviderModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderModel.h" diff --git a/src/ui/qml/ProviderModel.h b/src/ui/qml/ProviderModel.h index 4a64c4039..e392d8471 100644 --- a/src/ui/qml/ProviderModel.h +++ b/src/ui/qml/ProviderModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the providers. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/ProviderNameFilterModel.cpp b/src/ui/qml/ProviderNameFilterModel.cpp index 8fe41c93d..fc24be30e 100644 --- a/src/ui/qml/ProviderNameFilterModel.cpp +++ b/src/ui/qml/ProviderNameFilterModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderNameFilterModel.h" diff --git a/src/ui/qml/ProviderNameFilterModel.h b/src/ui/qml/ProviderNameFilterModel.h index 1af6db903..2e6219170 100644 --- a/src/ui/qml/ProviderNameFilterModel.h +++ b/src/ui/qml/ProviderNameFilterModel.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/Random.cpp b/src/ui/qml/Random.cpp new file mode 100644 index 000000000..3aa596944 --- /dev/null +++ b/src/ui/qml/Random.cpp @@ -0,0 +1,27 @@ +/*! + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + + +#include "Random.h" + +#include "Randomizer.h" +#include "SingletonHelper.h" + +#include + +using namespace governikus; + +defineSingleton(Random) + +Random & Random::getInstance() +{ + return *Instance; +} + + +int Random::randomInt(int pLowerBound, int pUpperBound) const +{ + std::uniform_int_distribution distribution(pLowerBound, pUpperBound); + return distribution(Randomizer::getInstance().getGenerator()); +} diff --git a/src/ui/qml/Random.h b/src/ui/qml/Random.h new file mode 100644 index 000000000..a3e50a1ec --- /dev/null +++ b/src/ui/qml/Random.h @@ -0,0 +1,25 @@ +/*! + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + + +#pragma once + +#include + +namespace governikus +{ + +class Random + : public QObject +{ + Q_OBJECT + + public: + static Random& getInstance(); + + /// A discrete random distribution on the range [pLowerBound, pUpperBound] with equal probability throughout the range. + Q_INVOKABLE int randomInt(int pLowerBound, int pUpperBound) const; +}; + +} // namespace governikus diff --git a/src/ui/qml/ReaderScanEnabler.cpp b/src/ui/qml/ReaderScanEnabler.cpp index 669004dee..6ecbcab03 100644 --- a/src/ui/qml/ReaderScanEnabler.cpp +++ b/src/ui/qml/ReaderScanEnabler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderScanEnabler.h" @@ -17,12 +17,9 @@ using namespace governikus; ReaderScanEnabler::ReaderScanEnabler(QQuickItem* pParent) : QQuickItem(pParent) + , mPlugInType(ReaderManagerPlugInType::UNKNOWN) , mObligedToStopScan(false) { - if (isVisible()) - { - enableScan(true); - } } @@ -37,15 +34,37 @@ void ReaderScanEnabler::enableScan(const bool pEnable) const auto manager = Env::getSingleton(); if (pEnable && !manager->isScanRunning()) { - qCDebug(qml) << "Starting scan."; + qCDebug(qml) << "Starting scan on" << mPlugInType; mObligedToStopScan = true; - manager->startScanAll(false); + manager->startScan(mPlugInType, false); } else if (mObligedToStopScan) { - qCDebug(qml) << "Stopping scan."; + qCDebug(qml) << "Stopping scan on" << mPlugInType; mObligedToStopScan = false; - manager->stopScanAll(); + manager->stopScan(mPlugInType); + } +} + + +ReaderManagerPlugInType ReaderScanEnabler::getPlugInType() const +{ + return mPlugInType; +} + + +void ReaderScanEnabler::setPlugInType(ReaderManagerPlugInType pPlugInType) +{ + if (mPlugInType == pPlugInType) + { + return; + } + + enableScan(false); + mPlugInType = pPlugInType; + if (isVisible()) + { + enableScan(true); } } diff --git a/src/ui/qml/ReaderScanEnabler.h b/src/ui/qml/ReaderScanEnabler.h index 28fd0fc9b..48405c3cb 100644 --- a/src/ui/qml/ReaderScanEnabler.h +++ b/src/ui/qml/ReaderScanEnabler.h @@ -1,9 +1,11 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once +#include "ReaderManagerPlugInInfo.h" + #include namespace governikus @@ -14,7 +16,10 @@ class ReaderScanEnabler { Q_OBJECT + Q_PROPERTY(ReaderManagerPlugInType plugInType READ getPlugInType WRITE setPlugInType) + private: + ReaderManagerPlugInType mPlugInType; bool mObligedToStopScan; void enableScan(const bool pEnable); @@ -23,6 +28,8 @@ class ReaderScanEnabler explicit ReaderScanEnabler(QQuickItem* pParent = nullptr); ~ReaderScanEnabler() override; + ReaderManagerPlugInType getPlugInType() const; + void setPlugInType(ReaderManagerPlugInType pPlugInType); void itemChange(QQuickItem::ItemChange pChange, const QQuickItem::ItemChangeData& pValue) override; }; diff --git a/src/ui/qml/RemoteServiceModel.cpp b/src/ui/qml/RemoteServiceModel.cpp index 494b3b798..e8a97c2d8 100644 --- a/src/ui/qml/RemoteServiceModel.cpp +++ b/src/ui/qml/RemoteServiceModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteServiceModel.h" @@ -178,28 +178,32 @@ bool RemoteServiceModel::rememberServer(const QString& pDeviceId) void RemoteServiceModel::onEstablishConnectionDone(const QSharedPointer& pEntry, const GlobalStatus& pStatus) { - Q_UNUSED(pEntry) auto* const remoteClient = Env::getSingleton(); disconnect(remoteClient, &RemoteClient::fireEstablishConnectionDone, this, &RemoteServiceModel::onEstablishConnectionDone); qDebug() << "Pairing finished:" << pStatus; + const auto deviceName = pEntry->getRemoteDeviceDescriptor().getIfdName(); if (pStatus.isError()) { - Q_EMIT firePairingFailed(); + Q_EMIT firePairingFailed(deviceName, pStatus.toErrorDescription()); + } + else + { + Q_EMIT firePairingSuccess(deviceName); } } void RemoteServiceModel::onConnectionInfoChanged(bool pConnected) { - if (pConnected) + if (mContext && pConnected) { const RemoteServiceSettings& settings = Env::getSingleton()->getRemoteServiceSettings(); - const QString peerName = settings.getRemoteInfo(getCurrentFingerprint()).getName(); + const QString peerName = settings.getRemoteInfo(mContext->getRemoteServer()->getCurrentCertificate()).getName(); //: INFO ANDROID IOS The smartphone is connected as card reader (SaK) and currently processing an authentication request. The user is asked to pay attention the its screen. mConnectionInfo = tr("Please pay attention to the display on your other device \"%1\".").arg(peerName); Q_EMIT fireConnectionInfoChanged(); } - Q_EMIT fireConnectedChanged(pConnected); + Q_EMIT fireConnectedChanged(); } @@ -229,7 +233,7 @@ void RemoteServiceModel::resetContext(const QSharedPointer connect(mContext.data(), &RemoteServiceContext::fireEstablishPaceChannelMessageUpdated, this, &RemoteServiceModel::onEstablishPaceChannelMessageUpdated); } - Q_EMIT fireConnectedChanged(isConnected()); + Q_EMIT fireConnectedChanged(); } @@ -242,22 +246,11 @@ void RemoteServiceModel::setPairing(bool pEnabled) } -QString RemoteServiceModel::getCurrentFingerprint() const -{ - if (mContext && mContext->getRemoteServer()->isConnected()) - { - return RemoteServiceSettings::generateFingerprint(mContext->getRemoteServer()->getCurrentCertificate()); - } - - return QString(); -} - - -bool RemoteServiceModel::isConnected() const +bool RemoteServiceModel::isConnectedToPairedDevice() const { if (mContext) { - return mContext->getRemoteServer()->isConnected(); + return mContext->getRemoteServer()->isConnected() && !mContext->getRemoteServer()->isPairingConnection(); } return false; diff --git a/src/ui/qml/RemoteServiceModel.h b/src/ui/qml/RemoteServiceModel.h index a4242ee1b..b237cefa8 100644 --- a/src/ui/qml/RemoteServiceModel.h +++ b/src/ui/qml/RemoteServiceModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the remote service component * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -30,8 +30,7 @@ class RemoteServiceModel Q_PROPERTY(bool canEnableNfc READ isCanEnableNfc NOTIFY fireEnvironmentChanged) Q_PROPERTY(QString errorMessage READ getErrorMessage NOTIFY fireEnvironmentChanged) Q_PROPERTY(QByteArray psk READ getPsk NOTIFY firePskChanged) - Q_PROPERTY(QString currentFingerprint READ getCurrentFingerprint NOTIFY fireConnectedChanged) - Q_PROPERTY(bool connected READ isConnected NOTIFY fireConnectedChanged) + Q_PROPERTY(bool connectedToPairedDevice READ isConnectedToPairedDevice NOTIFY fireConnectedChanged) Q_PROPERTY(QString connectionInfo READ getConnectionInfo NOTIFY fireConnectionInfoChanged) Q_PROPERTY(QString connectedServerDeviceNames READ getConnectedServerDeviceNames NOTIFY fireConnectedServerDeviceNamesChanged) Q_PROPERTY(RemoteDeviceModel * availableRemoteDevices READ getAvailableRemoteDevices CONSTANT) @@ -84,8 +83,7 @@ class RemoteServiceModel void resetContext(const QSharedPointer& pContext = QSharedPointer()); Q_INVOKABLE void setPairing(bool pEnabled = true); - QString getCurrentFingerprint() const; - bool isConnected() const; + bool isConnectedToPairedDevice() const; bool isSaCPinChangeWorkflow() const; bool isRunnable() const; bool isCanEnableNfc() const; @@ -103,10 +101,11 @@ class RemoteServiceModel void fireIsRunningChanged(); void fireEnvironmentChanged(); void firePskChanged(const QByteArray& pPsk); - void fireConnectedChanged(bool pConnected); + void fireConnectedChanged(); void fireServerPskChanged(); void fireDetectionChanged(); - void firePairingFailed(); + void firePairingFailed(QString pDeviceName, QString pErrorMessage); + void firePairingSuccess(QString pDeviceName); void fireConnectionInfoChanged(); void fireConnectedServerDeviceNamesChanged(); void fireEstablishPaceChannelMessageUpdated(); diff --git a/src/ui/qml/SelfAuthModel.cpp b/src/ui/qml/SelfAuthModel.cpp index 12d7810ea..7f71c543b 100644 --- a/src/ui/qml/SelfAuthModel.cpp +++ b/src/ui/qml/SelfAuthModel.cpp @@ -1,10 +1,11 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "SelfAuthModel.h" #include "context/SelfAuthContext.h" +#include "PdfExporter.h" #include "SingletonHelper.h" using namespace governikus; @@ -92,6 +93,20 @@ bool SelfAuthModel::isBasicReader() } +void SelfAuthModel::exportData(const QUrl& pFilename) const +{ + const auto& selfdata = mContext->getSelfAuthenticationData(); + const auto& orderedSelfData = selfdata.getOrderedSelfData(); + if (!orderedSelfData.isEmpty()) + { + const auto& dataTime = selfdata.getDateTime(); + + PdfExporter exporter(pFilename.toLocalFile()); + exporter.exportSelfInfo(dataTime, orderedSelfData); + } +} + + int SelfAuthModel::rowCount(const QModelIndex&) const { return mSelfData.size(); diff --git a/src/ui/qml/SelfAuthModel.h b/src/ui/qml/SelfAuthModel.h index a6f39b3fc..05f75e56b 100644 --- a/src/ui/qml/SelfAuthModel.h +++ b/src/ui/qml/SelfAuthModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the self authentication workflow. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -47,6 +47,7 @@ class SelfAuthModel Q_INVOKABLE void startWorkflow(); Q_INVOKABLE void cancelWorkflow(); Q_INVOKABLE bool isBasicReader(); + Q_INVOKABLE void exportData(const QUrl& pFilename) const; int rowCount(const QModelIndex& = QModelIndex()) const override; QVariant data(const QModelIndex& pIndex, int pRole = Qt::DisplayRole) const override; diff --git a/src/ui/qml/SelfDiagnosisModel.cpp b/src/ui/qml/SelfDiagnosisModel.cpp index 75be0f821..7429ab84f 100644 --- a/src/ui/qml/SelfDiagnosisModel.cpp +++ b/src/ui/qml/SelfDiagnosisModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "SelfDiagnosisModel.h" diff --git a/src/ui/qml/SelfDiagnosisModel.h b/src/ui/qml/SelfDiagnosisModel.h index 12b6070c1..a824f5374 100644 --- a/src/ui/qml/SelfDiagnosisModel.h +++ b/src/ui/qml/SelfDiagnosisModel.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/SettingsModel.cpp b/src/ui/qml/SettingsModel.cpp index 3ccd32672..c072a53db 100644 --- a/src/ui/qml/SettingsModel.cpp +++ b/src/ui/qml/SettingsModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "SettingsModel.h" @@ -25,14 +25,17 @@ defineSingleton(SettingsModel) SettingsModel::SettingsModel() : QObject() , mIsStartedByAuth(false) + , mShowBetaTesting(true) { const HistorySettings& settings = Env::getSingleton()->getHistorySettings(); connect(&settings, &HistorySettings::fireEnabledChanged, this, &SettingsModel::fireHistoryEnabledChanged); - const auto* service = Env::getSingleton(); - const auto* dataModel = Env::getSingleton(); - connect(service, &Service::fireAppUpdateFinished, dataModel, &AppUpdateDataModel::onAppUpdateFinished); - connect(service, &Service::fireAppUpdateFinished, this, &SettingsModel::fireAppUpdateDataChanged); + connect(Env::getSingleton(), &AppUpdateDataModel::fireAppUpdateDataChanged, this, &SettingsModel::fireAppUpdateDataChanged); + + const auto& generalSettings = Env::getSingleton()->getGeneralSettings(); + + connect(&generalSettings, &GeneralSettings::fireShowInAppNotificationsChanged, this, &SettingsModel::fireShowInAppNotificationsChanged); + connect(&generalSettings, &GeneralSettings::fireDeveloperOptionsChanged, this, &SettingsModel::fireDeveloperOptionsChanged); #ifdef Q_OS_ANDROID mIsStartedByAuth = QAndroidJniObject::callStaticMethod("com/governikus/ausweisapp2/MainActivity", "isStartedByAuth"); @@ -70,6 +73,23 @@ void SettingsModel::setLanguage(const QString& pLanguage) } +bool SettingsModel::isDeveloperOptions() const +{ + return Env::getSingleton()->getGeneralSettings().isDeveloperOptions(); +} + + +void SettingsModel::setDeveloperOptions(bool pEnable) +{ + if (isDeveloperOptions() != pEnable) + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + settings.setDeveloperOptions(pEnable); + settings.save(); + } +} + + bool SettingsModel::isDeveloperMode() const { return Env::getSingleton()->getGeneralSettings().isDeveloperMode(); @@ -83,7 +103,6 @@ void SettingsModel::setDeveloperMode(bool pEnable) auto& settings = Env::getSingleton()->getGeneralSettings(); settings.setDeveloperMode(pEnable); settings.save(); - Q_EMIT fireDeveloperModeChanged(); } } @@ -101,7 +120,6 @@ void SettingsModel::setUseSelfauthenticationTestUri(bool pUse) auto& settings = Env::getSingleton()->getGeneralSettings(); settings.setUseSelfauthenticationTestUri(pUse); settings.save(); - Q_EMIT fireUseSelfauthenticationTestUriChanged(); } } @@ -112,12 +130,6 @@ QString SettingsModel::getServerName() const } -bool SettingsModel::isValidServerName(const QString& name) const -{ - return !name.isEmpty(); -} - - void SettingsModel::setServerName(const QString& name) { RemoteServiceSettings& settings = Env::getSingleton()->getRemoteServiceSettings(); @@ -198,6 +210,24 @@ void SettingsModel::setUseScreenKeyboard(bool pUseScreenKeyboard) } +bool SettingsModel::isVisualPrivacy() const +{ + return Env::getSingleton()->getGeneralSettings().isVisualPrivacy(); +} + + +void SettingsModel::setVisualPrivacy(bool pVisualPrivacy) +{ + if (isVisualPrivacy() != pVisualPrivacy) + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + settings.setVisualPrivacy(pVisualPrivacy); + settings.save(); + Q_EMIT fireScreenKeyboardChanged(); + } +} + + bool SettingsModel::isShuffleScreenKeyboard() const { return Env::getSingleton()->getGeneralSettings().isShuffleScreenKeyboard(); @@ -235,6 +265,12 @@ void SettingsModel::setShowSetupAssistantOnStart(bool pShowSetupAssistantOnStart } +bool SettingsModel::isAutoStartAvailable() const +{ + return Env::getSingleton()->getGeneralSettings().isAutoStartAvailable(); +} + + bool SettingsModel::isAutoStart() const { return Env::getSingleton()->getGeneralSettings().isAutoStart(); @@ -313,6 +349,12 @@ void SettingsModel::setAutoCloseWindowAfterAuthentication(bool pEnabled) } +bool SettingsModel::isAutoUpdateAvailable() const +{ + return Env::getSingleton()->getGeneralSettings().isAutoUpdateAvailable(); +} + + bool SettingsModel::isAutoUpdateCheck() const { return Env::getSingleton()->getGeneralSettings().isAutoUpdateCheck(); @@ -355,6 +397,24 @@ void SettingsModel::setRemindUserToClose(bool pRemindUser) } +bool SettingsModel::isTransportPinReminder() const +{ + return Env::getSingleton()->getGeneralSettings().isTransportPinReminder(); +} + + +void SettingsModel::setTransportPinReminder(bool pTransportPinReminder) +{ + if (isTransportPinReminder() != pTransportPinReminder) + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + settings.setTransportPinReminder(pTransportPinReminder); + settings.save(); + Q_EMIT fireTransportPinReminderChanged(); + } +} + + bool SettingsModel::isShowInAppNotifications() const { @@ -366,11 +426,26 @@ void SettingsModel::setShowInAppNotifications(bool pShowInAppNotifications) { if (isShowInAppNotifications() != pShowInAppNotifications) { - auto& settings = Env::getSingleton()->getGeneralSettings(); settings.setShowInAppNotifications(pShowInAppNotifications); settings.save(); - Q_EMIT fireShowInAppNotificationsChanged(); + } +} + + +bool SettingsModel::isShowNewUiHint() const +{ + return Env::getSingleton()->getGeneralSettings().isShowNewUiHint(); +} + + +void SettingsModel::setShowNewUiHint(bool pShowNewUiHint) +{ + if (pShowNewUiHint != isShowNewUiHint()) + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + settings.setShowNewUiHint(pShowNewUiHint); + Q_EMIT fireShowNewUiHintChanged(); } } diff --git a/src/ui/qml/SettingsModel.h b/src/ui/qml/SettingsModel.h index e858e9ec5..f72063073 100644 --- a/src/ui/qml/SettingsModel.h +++ b/src/ui/qml/SettingsModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the settings. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -22,25 +22,33 @@ class SettingsModel Q_PROPERTY(QString translationTrigger READ getEmptyString NOTIFY fireLanguageChanged) Q_PROPERTY(QString language READ getLanguage WRITE setLanguage NOTIFY fireLanguageChanged) - Q_PROPERTY(bool developerMode READ isDeveloperMode WRITE setDeveloperMode NOTIFY fireDeveloperModeChanged) - Q_PROPERTY(bool useSelfauthenticationTestUri READ useSelfauthenticationTestUri WRITE setUseSelfauthenticationTestUri NOTIFY fireUseSelfauthenticationTestUriChanged) + Q_PROPERTY(bool developerOptions READ isDeveloperOptions WRITE setDeveloperOptions NOTIFY fireDeveloperOptionsChanged) + Q_PROPERTY(bool developerMode READ isDeveloperMode WRITE setDeveloperMode NOTIFY fireDeveloperOptionsChanged) + Q_PROPERTY(bool showBetaTesting MEMBER mShowBetaTesting NOTIFY fireDeveloperOptionsChanged) + Q_PROPERTY(bool useSelfauthenticationTestUri READ useSelfauthenticationTestUri WRITE setUseSelfauthenticationTestUri NOTIFY fireDeveloperOptionsChanged) Q_PROPERTY(bool pinPadMode READ getPinPadMode WRITE setPinPadMode NOTIFY firePinPadModeChanged) Q_PROPERTY(QString serverName READ getServerName WRITE setServerName NOTIFY fireDeviceNameChanged) Q_PROPERTY(bool historyEnabled READ isHistoryEnabled WRITE setHistoryEnabled NOTIFY fireHistoryEnabledChanged) Q_PROPERTY(bool useScreenKeyboard READ isUseScreenKeyboard WRITE setUseScreenKeyboard NOTIFY fireScreenKeyboardChanged) + Q_PROPERTY(bool visualPrivacy READ isVisualPrivacy WRITE setVisualPrivacy NOTIFY fireScreenKeyboardChanged) Q_PROPERTY(bool shuffleScreenKeyboard READ isShuffleScreenKeyboard WRITE setShuffleScreenKeyboard NOTIFY fireScreenKeyboardChanged) Q_PROPERTY(bool showSetupAssistantOnStart READ isShowSetupAssistantOnStart WRITE setShowSetupAssistantOnStart NOTIFY fireShowSetupAssistantOnStartChanged) + Q_PROPERTY(bool autoStartAvailable READ isAutoStartAvailable CONSTANT) Q_PROPERTY(bool autoStartApp READ isAutoStart WRITE setAutoStart NOTIFY fireAutoStartChanged) Q_PROPERTY(bool autoStartSetByAdmin READ autoStartIsSetByAdmin CONSTANT) + Q_PROPERTY(bool autoUpdateAvailable READ isAutoUpdateAvailable CONSTANT) Q_PROPERTY(bool autoCloseWindowAfterAuthentication READ isAutoCloseWindowAfterAuthentication WRITE setAutoCloseWindowAfterAuthentication NOTIFY fireAutoCloseWindowAfterAuthenticationChanged) Q_PROPERTY(bool autoUpdateCheck READ isAutoUpdateCheck WRITE setAutoUpdateCheck NOTIFY fireAutoUpdateCheckChanged) Q_PROPERTY(bool autoUpdateCheckSetByAdmin READ autoUpdateCheckIsSetByAdmin CONSTANT) Q_PROPERTY(bool remindUserToClose READ isRemindUserToClose WRITE setRemindUserToClose NOTIFY fireRemindUserToCloseChanged) + Q_PROPERTY(bool transportPinReminder READ isTransportPinReminder WRITE setTransportPinReminder NOTIFY fireTransportPinReminderChanged) Q_PROPERTY(bool showInAppNotifications READ isShowInAppNotifications WRITE setShowInAppNotifications NOTIFY fireShowInAppNotificationsChanged) Q_PROPERTY(AppUpdateDataModel * appUpdateData READ getAppUpdateData NOTIFY fireAppUpdateDataChanged) + Q_PROPERTY(bool showNewUiHint READ isShowNewUiHint WRITE setShowNewUiHint NOTIFY fireShowNewUiHintChanged) private: bool mIsStartedByAuth; + bool mShowBetaTesting; protected: SettingsModel(); @@ -52,6 +60,9 @@ class SettingsModel QString getLanguage() const; void setLanguage(const QString& pLanguage); + bool isDeveloperOptions() const; + void setDeveloperOptions(bool pEnabled); + bool isDeveloperMode() const; void setDeveloperMode(bool pEnabled); @@ -59,7 +70,6 @@ class SettingsModel void setUseSelfauthenticationTestUri(bool pUse); QString getServerName() const; - Q_INVOKABLE bool isValidServerName(const QString& name) const; void setServerName(const QString& name); Q_INVOKABLE void removeTrustedCertificate(const QString& pFingerprint); @@ -75,12 +85,16 @@ class SettingsModel bool isUseScreenKeyboard() const; void setUseScreenKeyboard(bool pUseScreenKeyboard); + bool isVisualPrivacy() const; + void setVisualPrivacy(bool pVisualPrivacy); + bool isShuffleScreenKeyboard() const; void setShuffleScreenKeyboard(bool pShuffleScreenKeyboard); bool isShowSetupAssistantOnStart() const; void setShowSetupAssistantOnStart(bool pShowSetupAssistantOnStart); + bool isAutoStartAvailable() const; bool isAutoStart() const; bool autoStartIsSetByAdmin() const; void setAutoStart(bool pEnabled); @@ -88,6 +102,7 @@ class SettingsModel bool isAutoCloseWindowAfterAuthentication() const; void setAutoCloseWindowAfterAuthentication(bool pEnabled); + bool isAutoUpdateAvailable() const; bool isAutoUpdateCheck() const; bool autoUpdateCheckIsSetByAdmin() const; void setAutoUpdateCheck(bool pAutoUpdateCheck); @@ -95,9 +110,15 @@ class SettingsModel bool isRemindUserToClose() const; void setRemindUserToClose(bool pRemindUser); + bool isTransportPinReminder() const; + void setTransportPinReminder(bool pTransportPinReminder); + bool isShowInAppNotifications() const; void setShowInAppNotifications(bool pShowInAppNotifications); + bool isShowNewUiHint() const; + void setShowNewUiHint(bool pShowNewUiHint); + Q_INVOKABLE bool requestStoreFeedback() const; Q_INVOKABLE void hideFutureStoreFeedbackDialogs(); @@ -110,8 +131,7 @@ class SettingsModel Q_SIGNALS: void fireLanguageChanged(); - void fireDeveloperModeChanged(); - void fireUseSelfauthenticationTestUriChanged(); + void fireDeveloperOptionsChanged(); void fireDeviceNameChanged(); void firePinPadModeChanged(); void fireHistoryEnabledChanged(); @@ -121,8 +141,10 @@ class SettingsModel void fireAutoCloseWindowAfterAuthenticationChanged(); void fireAutoUpdateCheckChanged(); void fireRemindUserToCloseChanged(); - void fireAppUpdateDataChanged(bool pUpdateAvailable, const GlobalStatus& pStatus); + void fireTransportPinReminderChanged(); + void fireAppUpdateDataChanged(); void fireShowInAppNotificationsChanged(); + void fireShowNewUiHintChanged(); }; diff --git a/src/ui/qml/ShareUtil.java b/src/ui/qml/ShareUtil.java index bcf2f243c..1ece48442 100644 --- a/src/ui/qml/ShareUtil.java +++ b/src/ui/qml/ShareUtil.java @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ package com.governikus.ausweisapp2; @@ -15,8 +15,8 @@ import android.content.pm.PackageManager; import android.content.pm.ResolveInfo; import android.net.Uri; -import android.support.v4.content.FileProvider; import android.util.Log; +import androidx.core.content.FileProvider; public final class ShareUtil @@ -79,7 +79,7 @@ public static void mailLog(Activity activity, final String email, final String s } catch (Exception e) { - Log.e(LOG_TAG, "Error sharing log file", e); + Log.e(LOG_TAG, "Error sharing logfile", e); } } @@ -96,7 +96,7 @@ public static void shareLog(Activity activity, final String logFilePath, final S } catch (Exception e) { - Log.e(LOG_TAG, "Error sharing log file", e); + Log.e(LOG_TAG, "Error sharing logfile", e); } } diff --git a/src/ui/qml/UIPlugInQml.cpp b/src/ui/qml/UIPlugInQml.cpp index 539b69104..f4e9a4645 100644 --- a/src/ui/qml/UIPlugInQml.cpp +++ b/src/ui/qml/UIPlugInQml.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugInQml.h" @@ -10,7 +10,6 @@ #include "context/AuthContext.h" #include "context/ChangePinContext.h" #include "context/SelfAuthContext.h" -#include "CardReturnCode.h" #include "ChangePinModel.h" #include "Env.h" #include "FileDestination.h" @@ -20,6 +19,7 @@ #include "NotificationModel.h" #include "PlatformTools.h" #include "ProviderCategoryFilterModel.h" +#include "Random.h" #include "ReaderScanEnabler.h" #include "RemoteServiceModel.h" #include "SelfAuthModel.h" @@ -27,6 +27,7 @@ #include "Service.h" #include "SingletonHelper.h" #include "SurveyModel.h" +#include "VersionNumber.h" #if defined(Q_OS_WIN) || (defined(Q_OS_BSD4) && !defined(Q_OS_IOS)) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) #include "ReaderDriverModel.h" @@ -38,13 +39,20 @@ #include #endif +#if !defined(Q_OS_ANDROID) && !defined(Q_OS_IOS) +#include +#include +#endif + #include +#include +#include +#include #include #include #include #include #include -#include #include #include #include @@ -114,13 +122,24 @@ UIPlugInQml::UIPlugInQml() , mChatModel() , mExplicitPlatformStyle(getPlatformSelectors()) , mConnectivityManager() + , mUpdateInformationPending(false) , mTrayIcon() + , mHighContrastEnabled(false) #if defined(Q_OS_MACOS) , mMenuBar() #endif { #if defined(Q_OS_ANDROID) QGuiApplication::setFont(QFont(QStringLiteral("Roboto"))); +#elif defined(Q_OS_LINUX) && QT_VERSION >= QT_VERSION_CHECK(5, 11, 0) + if (auto font = QGuiApplication::font(); QFontMetrics(font.family()).horizontalAdvance(QLatin1Char('m')) > 15) + { + // Fonts like "DejaVu Sans" (used on some Linux distributions) are unusually wide when compared to Windows' and macOS' default font. This will break some layouts where this wasn't taken into account. + const auto oldFamily = QFontInfo(font).family(); + font.setFamily(QStringLiteral("Arial")); // will usually resolve to "Liberation Sans" or "Arimo" + qCDebug(qml) << "Changing font family from" << oldFamily << "to" << QFontInfo(font).family(); + QGuiApplication::setFont(font); + } #endif #ifdef Q_OS_WIN @@ -137,6 +156,13 @@ UIPlugInQml::UIPlugInQml() connect(Env::getSingleton(), &RemoteServiceModel::fireStartWorkflow, this, &UIPlugIn::fireRemoteServiceRequested); connect(Env::getSingleton(), &LogHandler::fireRawLog, this, &UIPlugInQml::onRawLog, Qt::QueuedConnection); connect(this, &UIPlugIn::fireShowUserInformation, this, &UIPlugInQml::onShowUserInformation); + connect(qGuiApp, &QGuiApplication::paletteChanged, this, &UIPlugInQml::onWindowPaletteChanged); + + auto* service = Env::getSingleton(); + connect(service, &Service::fireAppUpdateFinished, this, &UIPlugInQml::onUpdateAvailable); + connect(service, &Service::fireUpdateScheduled, this, &UIPlugInQml::onUpdateScheduled); + service->runUpdateIfNeeded(); + init(); } @@ -145,27 +171,28 @@ void UIPlugInQml::registerQmlTypes() { qmlRegisterUncreatableType("Governikus.Type.UiModule", 1, 0, "UiModule", QStringLiteral("Not creatable as it is an enum type")); qmlRegisterUncreatableType("Governikus.Type.ReaderPlugIn", 1, 0, "ReaderPlugIn", QStringLiteral("Not creatable as it is an enum type")); - qmlRegisterUncreatableType("Governikus.Type.CardReturnCode", 1, 0, "CardReturnCode", QStringLiteral("Not creatable as it is an enum type")); registerQmlType(); - registerQmlSingletonType(&provideQmlType ); - registerQmlSingletonType(&provideQmlType ); + registerQmlSingletonType(&provideQmlType); + registerQmlSingletonType(&provideQmlType); #if defined(Q_OS_WIN) || (defined(Q_OS_BSD4) && !defined(Q_OS_IOS)) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)) - registerQmlSingletonType(&provideQmlType ); + registerQmlSingletonType(&provideQmlType); #endif - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); - registerQmlSingletonType(&provideSingletonQmlType ); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); + registerQmlSingletonType(&provideSingletonQmlType); } @@ -175,7 +202,8 @@ void UIPlugInQml::init() qputenv("QML_DISABLE_DISK_CACHE", "true"); #endif - logRenderingEnvironment(); + // Activate logging of Qt scenegraph information on startup, e.g. GL_RENDERER, GL_VERSION, ... + qputenv("QSG_INFO", "1"); mEngine.reset(new QQmlApplicationEngine()); @@ -192,11 +220,30 @@ void UIPlugInQml::init() UIPlugInQml::registerQmlTypes(); +#if defined(Q_OS_WIN) || defined(Q_OS_MACOS) || defined(Q_OS_ANDROID) || defined(Q_OS_IOS) mEngine->addImportPath(getPath(QStringLiteral("qml/"), false).toString()); +#endif mEngine->addImportPath(getPath(QStringLiteral("qml/")).toString()); mEngine->load(getPath(QStringLiteral("qml/main.qml"))); + if (!mEngine->rootObjects().isEmpty()) + { + QQuickWindow* rootWindow = qobject_cast(mEngine->rootObjects().first()); + if (rootWindow != nullptr) + { +#if defined(Q_OS_WIN) && QT_VERSION < QT_VERSION_CHECK(5, 14, 1) + // we need to call create() explicitly because Windows needs a handle to fire WM_ENDSESSION! + // Since we start as a systemtray only we don't have a correct handle until we call show() + rootWindow->create(); +#endif + connect(rootWindow, &QQuickWindow::sceneGraphError, this, &UIPlugInQml::onSceneGraphError); + qCDebug(qml) << "Using renderer interface:" << rootWindow->rendererInterface()->graphicsApi(); + } + } + Env::getSingleton()->updateConfigurations(); + + onWindowPaletteChanged(); } @@ -216,26 +263,6 @@ void UIPlugInQml::switchUi() } -void UIPlugInQml::logRenderingEnvironment() const -{ - QString openGLContext = QStringLiteral("Unknown"); - switch (QOpenGLContext::openGLModuleType()) - { - case QOpenGLContext::LibGL: - openGLContext = QStringLiteral("OpenGL"); - break; - - case QOpenGLContext::LibGLES: - openGLContext = QStringLiteral("OpenGL ES 2.0 or higher"); - break; - } - qCDebug(qml).noquote() << "QOpenGLContext:" << openGLContext; - - // Activate logging of Qt scenegraph information on startup, e.g. GL_RENDERER, GL_VERSION, ... - qputenv("QSG_INFO", "1"); -} - - QString UIPlugInQml::getPlatformSelectors() const { #ifndef QT_NO_DEBUG @@ -323,7 +350,11 @@ void UIPlugInQml::onWorkflowFinished(QSharedPointer pContext) mChatModel.resetContext(); const auto& generalSettings = Env::getSingleton()->getGeneralSettings(); - if (!pContext.objectCast() && generalSettings.isAutoCloseWindowAfterAuthentication()) + + // Only hide the UI if we don't need to show the update information view. This behaviour ensures that + // the user is (aggressively) notified about a pending update if the AA2 is only shown for authentication + // workflows and never manually brought to foreground in between. + if (!pContext.objectCast() && !pContext->hasNextWorkflowPending() && generalSettings.isAutoCloseWindowAfterAuthentication() && !showUpdateInformationIfPending()) { Q_EMIT fireHideRequest(); } @@ -398,40 +429,70 @@ void UIPlugInQml::onUiDominationReleased() void UIPlugInQml::onShowUserInformation(const QString& pMessage) { +#if defined(Q_OS_ANDROID) || defined(Q_OS_IOS) Env::getSingleton()->showFeedback(pMessage); +#else + QMessageBox msgBox; + msgBox.setWindowTitle(QCoreApplication::applicationName() + QStringLiteral(" - ") + tr("Information")); + msgBox.setIcon(QMessageBox::Information); + msgBox.setText(pMessage); + msgBox.setStandardButtons(QMessageBox::Ok); + msgBox.button(QMessageBox::Ok)->setFocus(); + msgBox.exec(); +#endif } -void UIPlugInQml::show() +void UIPlugInQml::onUpdateScheduled() { - onShowUi(UiModule::CURRENT); Env::getSingleton()->runUpdateIfNeeded(); } -void UIPlugInQml::doShutdown() +void UIPlugInQml::onUpdateAvailable(bool pUpdateAvailable, const GlobalStatus& pStatus) { + Q_UNUSED(pStatus) + mUpdateInformationPending = pUpdateAvailable; } -QUrl UIPlugInQml::getPath(const QString& pRelativePath, bool pQrc) +void UIPlugInQml::show() { -#if !defined(QT_NO_DEBUG) && !defined(Q_OS_IOS) && !defined(Q_OS_ANDROID) && !defined(Q_OS_WINRT) - const QString ressourceFolderPath(QStringLiteral(RES_DIR) + QLatin1Char('/') + pRelativePath); - if (QFile::exists(ressourceFolderPath)) + if (!showUpdateInformationIfPending()) { - return QUrl::fromLocalFile(ressourceFolderPath); + onShowUi(UiModule::CURRENT); } +} -#endif +bool UIPlugInQml::showUpdateInformationIfPending() +{ + if (!mUpdateInformationPending) + { + return false; + } + + mUpdateInformationPending = false; + onShowUi(UiModule::UPDATEINFORMATION); + + return true; +} + + +void UIPlugInQml::doShutdown() +{ + mTrayIcon.shutdown(); +} + + +QUrl UIPlugInQml::getPath(const QString& pRelativePath, bool pQrc) +{ if (pQrc) { return QStringLiteral("qrc:///") + pRelativePath; } - const QString path = FileDestination::getPath(pRelativePath); - return QUrl::fromLocalFile(path); + return QUrl::fromLocalFile(FileDestination::getPath(pRelativePath, QStandardPaths::LocateDirectory)); } @@ -466,6 +527,21 @@ void UIPlugInQml::onQmlObjectCreated(QObject* pObject) } +void UIPlugInQml::onSceneGraphError(QQuickWindow::SceneGraphError pError, const QString& pMessage) +{ + qCDebug(qml) << "Cannot initialize UI rendering:" << pError << '|' << pMessage; + + const char* envKey = "QT_QUICK_BACKEND"; + const auto envValue = QByteArrayLiteral("software"); + if (qgetenv(envKey) != envValue) + { + qputenv(envKey, envValue); + qCDebug(qml) << "Restart application with" << envKey << envValue; + Q_EMIT fireRestartApplicationRequested(); + } +} + + void UIPlugInQml::onRawLog(const QString& pMessage, const QString& pCategoryName) { if (pCategoryName == QLatin1String("developermode") || pCategoryName == QLatin1String("feedback")) @@ -488,7 +564,7 @@ QString UIPlugInQml::getPlatformStyle() const } -bool UIPlugInQml::isDeveloperBuild() const +bool UIPlugInQml::isDebugBuild() const { #ifndef QT_NO_DEBUG return true; @@ -500,6 +576,12 @@ bool UIPlugInQml::isDeveloperBuild() const } +bool UIPlugInQml::isDeveloperVersion() const +{ + return VersionNumber::getApplicationVersion().isDeveloperVersion(); +} + + QString UIPlugInQml::getDominator() const { return mDominator; @@ -518,11 +600,14 @@ QVariantMap UIPlugInQml::getSafeAreaMargins() const QVariantMap marginMap; #ifdef Q_OS_ANDROID + auto screen = QGuiApplication::primaryScreen(); - marginMap[QStringLiteral("top")] = QtAndroid::androidActivity().callMethod("getStatusBarHeight", "()I") / screen->devicePixelRatio(); - marginMap[QStringLiteral("right")] = 0; - marginMap[QStringLiteral("bottom")] = 0; - marginMap[QStringLiteral("left")] = 0; + auto windowInsets = QtAndroid::androidActivity().callObjectMethod("getWindowInsets", "()Landroid/view/ViewGroup$MarginLayoutParams;"); + + marginMap[QStringLiteral("top")] = windowInsets.getField("topMargin") / screen->devicePixelRatio(); + marginMap[QStringLiteral("left")] = windowInsets.getField("leftMargin") / screen->devicePixelRatio(); + marginMap[QStringLiteral("right")] = windowInsets.getField("rightMargin") / screen->devicePixelRatio(); + marginMap[QStringLiteral("bottom")] = windowInsets.getField("bottomMargin") / screen->devicePixelRatio(); #else marginMap[QStringLiteral("top")] = 0; marginMap[QStringLiteral("right")] = 0; @@ -536,6 +621,39 @@ QVariantMap UIPlugInQml::getSafeAreaMargins() const #endif +#ifndef Q_OS_MACOS +bool UIPlugInQml::isHighContrastEnabled() const +{ +#ifdef Q_OS_WIN + HIGHCONTRAST hc; + hc.cbSize = sizeof(hc); + return SystemParametersInfo(SPI_GETHIGHCONTRAST, sizeof(hc), &hc, FALSE) && (hc.dwFlags & HCF_HIGHCONTRASTON); + +#else + return false; + +#endif +} + + +#endif + +QString UIPlugInQml::getFixedFontFamily() const +{ + return QFontDatabase::systemFont(QFontDatabase::FixedFont).family(); +} + + +void UIPlugInQml::onWindowPaletteChanged() +{ + const bool highContrast = isHighContrastEnabled(); + if (mHighContrastEnabled != highContrast) + { + mHighContrastEnabled = highContrast; + Q_EMIT fireHighContrastEnabledChanged(); + } +} + void UIPlugInQml::applyPlatformStyle(const QString& pPlatformStyle) { diff --git a/src/ui/qml/UIPlugInQml.h b/src/ui/qml/UIPlugInQml.h index 42ac3ed93..3adef8172 100644 --- a/src/ui/qml/UIPlugInQml.h +++ b/src/ui/qml/UIPlugInQml.h @@ -1,7 +1,7 @@ /*! * \brief UIPlugIn implementation of QML. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -9,6 +9,7 @@ #include "CertificateDescriptionModel.h" #include "ChatModel.h" #include "ConnectivityManager.h" +#include "GlobalStatus.h" #include "HistoryModel.h" #include "NumberModel.h" #include "SettingsModel.h" @@ -17,6 +18,7 @@ #include "VersionInformationModel.h" #include +#include #include #if defined (Q_OS_MACOS) #include @@ -32,10 +34,13 @@ class UIPlugInQml Q_PLUGIN_METADATA(IID "governikus.UIPlugIn" FILE "metadata.json") Q_INTERFACES(governikus::UIPlugIn) Q_PROPERTY(QString platformStyle READ getPlatformStyle CONSTANT) - Q_PROPERTY(bool developerBuild READ isDeveloperBuild CONSTANT) + Q_PROPERTY(bool debugBuild READ isDebugBuild CONSTANT) + Q_PROPERTY(bool developerVersion READ isDeveloperVersion CONSTANT) Q_PROPERTY(QString dominator READ getDominator NOTIFY fireDominatorChanged) Q_PROPERTY(bool dominated READ isDominated NOTIFY fireDominatorChanged) Q_PROPERTY(QVariantMap safeAreaMargins READ getSafeAreaMargins NOTIFY fireSafeAreaMarginsChanged) + Q_PROPERTY(bool highContrastEnabled READ isHighContrastEnabled NOTIFY fireHighContrastEnabledChanged) + Q_PROPERTY(QString fixedFontFamily READ getFixedFontFamily CONSTANT) private: QScopedPointer mEngine; @@ -45,16 +50,18 @@ class UIPlugInQml ChatModel mChatModel; QString mExplicitPlatformStyle; ConnectivityManager mConnectivityManager; + bool mUpdateInformationPending; TrayIcon mTrayIcon; QString mDominator; + bool mHighContrastEnabled; #if defined(Q_OS_MACOS) QMenuBar mMenuBar; #endif - void logRenderingEnvironment() const; QString getPlatformSelectors() const; static QUrl getPath(const QString& pRelativePath, bool pQrc = true); bool isTablet() const; + bool showUpdateInformationIfPending(); public: UIPlugInQml(); @@ -63,10 +70,13 @@ class UIPlugInQml static void registerQmlTypes(); QString getPlatformStyle() const; - bool isDeveloperBuild() const; + bool isDebugBuild() const; + bool isDeveloperVersion() const; QString getDominator() const; bool isDominated() const; QVariantMap getSafeAreaMargins() const; + bool isHighContrastEnabled() const; + QString getFixedFontFamily() const; Q_INVOKABLE void applyPlatformStyle(const QString& pPlatformStyle); Q_INVOKABLE void init(); @@ -78,6 +88,7 @@ class UIPlugInQml void fireHideRequest(); void fireDominatorChanged(); void fireSafeAreaMarginsChanged(); + void fireHighContrastEnabledChanged(); private Q_SLOTS: void show(); @@ -90,12 +101,17 @@ class UIPlugInQml virtual void onUiDomination(const UIPlugIn* pUi, const QString& pInformation, bool pAccepted) override; virtual void onUiDominationReleased() override; void onShowUserInformation(const QString& pMessage); + void onUpdateScheduled(); + void onUpdateAvailable(bool pUpdateAvailable, const GlobalStatus& pStatus); void onQmlWarnings(const QList& pWarnings); void onQmlObjectCreated(QObject* pObject); + void onSceneGraphError(QQuickWindow::SceneGraphError pError, const QString& pMessage); void onRawLog(const QString& pMessage, const QString& pCategoryName); + void onWindowPaletteChanged(); + public Q_SLOTS: void doRefresh(); }; diff --git a/src/ui/qml/UIPlugInQml_ios.mm b/src/ui/qml/UIPlugInQml_ios.mm index 3a1062258..852aa2883 100644 --- a/src/ui/qml/UIPlugInQml_ios.mm +++ b/src/ui/qml/UIPlugInQml_ios.mm @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugInQml.h" @@ -11,15 +11,15 @@ bool UIPlugInQml::isTablet() const { - return [[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad; + return [UIDevice currentDevice].userInterfaceIdiom == UIUserInterfaceIdiomPad; } QVariantMap UIPlugInQml::getSafeAreaMargins() const { - UIViewController* rootController = [[UIApplication sharedApplication].windows[0] rootViewController]; + UIViewController* rootController = [UIApplication sharedApplication].windows[0].rootViewController; - UIEdgeInsets safeAreaInsets = [rootController view].safeAreaInsets; + UIEdgeInsets safeAreaInsets = rootController.view.safeAreaInsets; QVariantMap insetMap; diff --git a/src/ui/qml/UIPlugInQml_osx.mm b/src/ui/qml/UIPlugInQml_osx.mm new file mode 100644 index 000000000..b0964154d --- /dev/null +++ b/src/ui/qml/UIPlugInQml_osx.mm @@ -0,0 +1,14 @@ +/*! + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +#include "UIPlugInQml.h" + +#include + +using namespace governikus; + +bool UIPlugInQml::isHighContrastEnabled() const +{ + return NSWorkspace.sharedWorkspace.accessibilityDisplayShouldIncreaseContrast; +} diff --git a/src/ui/qml/VersionInformationModel.cpp b/src/ui/qml/VersionInformationModel.cpp index a4b3964e6..56c99ab0f 100644 --- a/src/ui/qml/VersionInformationModel.cpp +++ b/src/ui/qml/VersionInformationModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Model implementation for version information. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "VersionInformationModel.h" diff --git a/src/ui/qml/VersionInformationModel.h b/src/ui/qml/VersionInformationModel.h index ba541ea76..5bde65217 100644 --- a/src/ui/qml/VersionInformationModel.h +++ b/src/ui/qml/VersionInformationModel.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/qml/WorkflowModel.cpp b/src/ui/qml/WorkflowModel.cpp index 63522bc9c..5b3c4b9a8 100644 --- a/src/ui/qml/WorkflowModel.cpp +++ b/src/ui/qml/WorkflowModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "WorkflowModel.h" @@ -127,16 +127,6 @@ void WorkflowModel::cancelWorkflow() } -void WorkflowModel::cancelWorkflowOnPinBlocked() -{ - if (mContext) - { - mContext->setStatus(GlobalStatus::Code::Workflow_Pin_Blocked_And_Puk_Objectionable); - Q_EMIT mContext->fireCancelWorkflow(); - } -} - - void WorkflowModel::cancelWorkflowToChangePin() { if (mContext) diff --git a/src/ui/qml/WorkflowModel.h b/src/ui/qml/WorkflowModel.h index 867082417..3a6228e5c 100644 --- a/src/ui/qml/WorkflowModel.h +++ b/src/ui/qml/WorkflowModel.h @@ -1,7 +1,7 @@ /*! * \brief Model implementation for the authentication action. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -59,7 +59,6 @@ class WorkflowModel Q_INVOKABLE void startWorkflow(); Q_INVOKABLE void cancelWorkflow(); - Q_INVOKABLE void cancelWorkflowOnPinBlocked(); Q_INVOKABLE void cancelWorkflowToChangePin(); Q_INVOKABLE void continueWorkflow(); Q_INVOKABLE void setInitialPluginType(); diff --git a/src/ui/websocket/UIPlugInWebSocket.cpp b/src/ui/websocket/UIPlugInWebSocket.cpp index 8fee20359..68b47aba6 100644 --- a/src/ui/websocket/UIPlugInWebSocket.cpp +++ b/src/ui/websocket/UIPlugInWebSocket.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugInWebSocket.h" @@ -15,6 +15,7 @@ #include #include #include +#include Q_DECLARE_LOGGING_CATEGORY(websocket) diff --git a/src/ui/websocket/UIPlugInWebSocket.h b/src/ui/websocket/UIPlugInWebSocket.h index bd247e148..6ffd78824 100644 --- a/src/ui/websocket/UIPlugInWebSocket.h +++ b/src/ui/websocket/UIPlugInWebSocket.h @@ -1,7 +1,7 @@ /*! * \brief UIPlugIn implementation of the Websocket. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/AboutDialog.cpp b/src/ui/widget/AboutDialog.cpp index 781ff0040..d9b8bd74e 100644 --- a/src/ui/widget/AboutDialog.cpp +++ b/src/ui/widget/AboutDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "AboutDialog.h" @@ -37,13 +37,6 @@ AboutDialog::AboutDialog(QWidget* pParent) mUi->lblVersion->setText(QStringLiteral("%1: %2").arg(tr("Version"), QApplication::applicationVersion())); - mUi->lblDeveloperModeWarning->setText(QStringLiteral("

%1

") - .arg(tr("The developer mode is aimed at integrators / developers for new service applications." - " For this reason, the developer mode works only in the test PKI." - " By activating the developer mode, some safety tests are deactivated." - " This means that the authentication process continues although the AusweisApp2 would usually abort the process with an error message when used in normal operation mode." - " Information on the disregarded error in the developer mode is displayed in the attached window below the AusweisApp2."))); - const QIcon icon = windowIcon(); const QSize size = icon.actualSize(QSize(64, 64)); mUi->imgAusweisApp2->setPixmap(icon.pixmap(size)); @@ -51,10 +44,8 @@ AboutDialog::AboutDialog(QWidget* pParent) connect(mUi->btnOkay, &QPushButton::clicked, this, &QDialog::accept); connect(this, &QDialog::accepted, this, &AboutDialog::onAccept); - mUi->chkbDeveloperMode->setCheckState(Env::getSingleton()->getGeneralSettings().isDeveloperMode() ? Qt::Checked : Qt::Unchecked); - - connect(mUi->chkbDeveloperMode, &QCheckBox::stateChanged, this, &AboutDialog::onCheckboxStateChanged); - onCheckboxStateChanged(); + connect(&Env::getSingleton()->getGeneralSettings(), &GeneralSettings::fireDeveloperOptionsChanged, this, &AboutDialog::onDeveloperOptionsChanged); + onDeveloperOptionsChanged(); } @@ -63,24 +54,17 @@ AboutDialog::~AboutDialog() } -void AboutDialog::onCheckboxStateChanged() +void AboutDialog::onDeveloperOptionsChanged() { - const bool developerModeActivated = mUi->chkbDeveloperMode->checkState() == Qt::Checked; - mUi->lblDeveloperModeWarning->setVisible(developerModeActivated); - resize(minimumSize()); - adjustSize(); + mUi->chkbDeveloperOptions->setCheckState(Env::getSingleton()->getGeneralSettings().isDeveloperOptions() ? Qt::Checked : Qt::Unchecked); } void AboutDialog::onAccept() { - const bool developerModeActivated = mUi->chkbDeveloperMode->checkState() == Qt::Checked; + const bool developerOptionsActivated = mUi->chkbDeveloperOptions->checkState() == Qt::Checked; GeneralSettings& generalSettings = Env::getSingleton()->getGeneralSettings(); - if (generalSettings.isDeveloperMode() != developerModeActivated) - { - generalSettings.setDeveloperMode(developerModeActivated); - generalSettings.save(); - } + generalSettings.setDeveloperOptions(developerOptionsActivated); } diff --git a/src/ui/widget/AboutDialog.h b/src/ui/widget/AboutDialog.h index 37d219803..5051d23ae 100644 --- a/src/ui/widget/AboutDialog.h +++ b/src/ui/widget/AboutDialog.h @@ -1,7 +1,7 @@ /*! * \brief Dialog to display information about the application * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -26,7 +26,7 @@ class AboutDialog QScopedPointer mUi; private Q_SLOTS: - void onCheckboxStateChanged(); + void onDeveloperOptionsChanged(); void onAccept(); protected: diff --git a/src/ui/widget/AboutDialog.ui b/src/ui/widget/AboutDialog.ui index db1472743..e2ff4872c 100644 --- a/src/ui/widget/AboutDialog.ui +++ b/src/ui/widget/AboutDialog.ui @@ -132,7 +132,7 @@ - $Release Notes + $Release notes Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop @@ -163,12 +163,12 @@ - Developer mode: + Developer options: - + 0 @@ -176,22 +176,12 @@ - use + show in the settings - - - - $developerWarning - - - true - - - diff --git a/src/ui/widget/AppQtGui.cpp b/src/ui/widget/AppQtGui.cpp index 36d6edf5e..ef8ced0e3 100644 --- a/src/ui/widget/AppQtGui.cpp +++ b/src/ui/widget/AppQtGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AppQtGui.h" @@ -45,7 +45,6 @@ AppQtGui::AppQtGui() , mUpdateInfo(new QMessageBox(mMainWidget)) , mCertificateInfo(new QMessageBox(mMainWidget)) , mLockedInfo(new QMessageBox(mMainWidget)) - , mSwitchUiInquiry(new QMessageBox(mMainWidget)) , mUpdateWindow(new UpdateWindow(mMainWidget)) , mAggressiveToForeground(false) { @@ -62,7 +61,7 @@ AppQtGui::AppQtGui() mUpdateInfo->setWindowTitle(QApplication::applicationName() + QStringLiteral(" - ") + tr("Updates")); mUpdateInfo->setWindowIcon(mTrayIcon.getIcon()); - mUpdateInfo->setWindowModality(Qt::WindowModal); + mUpdateInfo->setWindowModality(Qt::ApplicationModal); mUpdateInfo->setStandardButtons(QMessageBox::Ok); mUpdateInfo->button(QMessageBox::Ok)->setFocus(); connect(mUpdateWindow, &UpdateWindow::fireShowUpdateDialog, this, @@ -88,12 +87,6 @@ AppQtGui::AppQtGui() mLockedInfo->setText(tr("Another application uses AusweisApp2.")); mLockedInfo->setStandardButtons(QMessageBox::NoButton); - mSwitchUiInquiry->setWindowTitle(QCoreApplication::applicationName() + QStringLiteral(" - ") + tr("Switch UI")); - mSwitchUiInquiry->setIcon(QMessageBox::Information); - mSwitchUiInquiry->setText(tr("Do you want to switch to the new beta UI? You can switch back to the old UI in \"Settings\".")); - mSwitchUiInquiry->setStandardButtons(QMessageBox::Yes | QMessageBox::No); - mSwitchUiInquiry->button(QMessageBox::Yes)->setFocus(); - auto* service = Env::getSingleton(); connect(service, &Service::fireAppUpdateFinished, this, &AppQtGui::onAppUpdateReady); connect(service, &Service::fireUpdateScheduled, this, &AppQtGui::onUpdateScheduled); @@ -217,6 +210,7 @@ void AppQtGui::onShowUserInformation(const QString& pInformationMessage) { QMessageBox msgBox(mMainWidget); msgBox.setWindowTitle(QCoreApplication::applicationName() + QStringLiteral(" - ") + tr("Information")); + msgBox.setWindowModality(Qt::ApplicationModal); msgBox.setIcon(QMessageBox::Information); msgBox.setText(pInformationMessage); msgBox.setStandardButtons(QMessageBox::Ok); @@ -372,10 +366,6 @@ void AppQtGui::closeDialogs() { mDiagnosisGui->deactivate(); } - if (mSwitchUiInquiry) - { - mSwitchUiInquiry->reject(); - } } @@ -423,11 +413,6 @@ void AppQtGui::onCloseWindowRequested(bool* pDoClose) void AppQtGui::onSwitchUiRequested() { - if (mSwitchUiInquiry->exec() != QMessageBox::Yes) - { - return; - } - auto& generalSettings = Env::getSingleton()->getGeneralSettings(); generalSettings.setSelectedUi(QStringLiteral("qml")); generalSettings.save(); @@ -489,8 +474,12 @@ void AppQtGui::show(UiModule pModule) mMainWidget->switchToGuiModule(GuiModule::START_PAGE); break; + // Don't switch the module, just show the current one, + // the Widgets UI does not feature a distinct view for update information. + case UiModule::UPDATEINFORMATION: + Q_FALLTHROUGH(); + case UiModule::CURRENT: - // don't switch the module, just show the current one break; } diff --git a/src/ui/widget/AppQtGui.h b/src/ui/widget/AppQtGui.h index a32f5bff3..c37e2ce0d 100644 --- a/src/ui/widget/AppQtGui.h +++ b/src/ui/widget/AppQtGui.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -81,7 +81,6 @@ class AppQtGui QMessageBox* mUpdateInfo; QMessageBox* mCertificateInfo; QMessageBox* mLockedInfo; - QMessageBox* mSwitchUiInquiry; UpdateWindow* mUpdateWindow; bool mAggressiveToForeground; diff --git a/src/ui/widget/AppQtMainWidget.cpp b/src/ui/widget/AppQtMainWidget.cpp index 130ad66b5..5b984b5ad 100644 --- a/src/ui/widget/AppQtMainWidget.cpp +++ b/src/ui/widget/AppQtMainWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AppQtMainWidget.h" diff --git a/src/ui/widget/AppQtMainWidget.h b/src/ui/widget/AppQtMainWidget.h index aed709a35..6d7767ab0 100644 --- a/src/ui/widget/AppQtMainWidget.h +++ b/src/ui/widget/AppQtMainWidget.h @@ -1,7 +1,7 @@ /*! * \brief Main class for the top level main widget * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/AppStartPage.cpp b/src/ui/widget/AppStartPage.cpp index aae4f73ac..2f9077ff2 100644 --- a/src/ui/widget/AppStartPage.cpp +++ b/src/ui/widget/AppStartPage.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AppStartPage.h" diff --git a/src/ui/widget/AppStartPage.h b/src/ui/widget/AppStartPage.h index e361338fa..091196d44 100644 --- a/src/ui/widget/AppStartPage.h +++ b/src/ui/widget/AppStartPage.h @@ -1,7 +1,7 @@ /*! * \brief Main page widget. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/CredentialDialog.cpp b/src/ui/widget/CredentialDialog.cpp index 00cb06d71..90902374c 100644 --- a/src/ui/widget/CredentialDialog.cpp +++ b/src/ui/widget/CredentialDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CredentialDialog.h" diff --git a/src/ui/widget/CredentialDialog.h b/src/ui/widget/CredentialDialog.h index 01818c6f1..c23b885fb 100644 --- a/src/ui/widget/CredentialDialog.h +++ b/src/ui/widget/CredentialDialog.h @@ -1,7 +1,7 @@ /*! * \brief Show a dialog to fill in proxy credentials. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/DeleteHistoryDialog.cpp b/src/ui/widget/DeleteHistoryDialog.cpp index 373076ff5..d447969ae 100644 --- a/src/ui/widget/DeleteHistoryDialog.cpp +++ b/src/ui/widget/DeleteHistoryDialog.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DeleteHistoryDialog.h" diff --git a/src/ui/widget/DeleteHistoryDialog.h b/src/ui/widget/DeleteHistoryDialog.h index 56af2846b..18561417f 100644 --- a/src/ui/widget/DeleteHistoryDialog.h +++ b/src/ui/widget/DeleteHistoryDialog.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/DetailDialog.cpp b/src/ui/widget/DetailDialog.cpp index d21dfb11f..af6dcd9d5 100644 --- a/src/ui/widget/DetailDialog.cpp +++ b/src/ui/widget/DetailDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DetailDialog.h" @@ -21,7 +21,7 @@ DetailDialog::DetailDialog(QWidget* pParent) mUi->setupUi(this); setWindowFlags(Qt::Dialog | Qt::WindowTitleHint | Qt::WindowCloseButtonHint); - setWindowTitle(QCoreApplication::applicationName() + QStringLiteral(" - ") + tr("Service provider data")); + setWindowTitle(QCoreApplication::applicationName() + QStringLiteral(" - ") + tr("Provider data")); installEventFilter(this); diff --git a/src/ui/widget/DetailDialog.h b/src/ui/widget/DetailDialog.h index 053d1551b..9ee5719a9 100644 --- a/src/ui/widget/DetailDialog.h +++ b/src/ui/widget/DetailDialog.h @@ -1,7 +1,7 @@ /*! * \brief Detail dialog for certificate description * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/DetailDialog.ui b/src/ui/widget/DetailDialog.ui index e00cbf129..967d3af23 100644 --- a/src/ui/widget/DetailDialog.ui +++ b/src/ui/widget/DetailDialog.ui @@ -20,7 +20,7 @@
- Service provider data + Provider data QDialog{background-image: url(:/images/bg_da.png); background-repeat: repeat-y; border: none} diff --git a/src/ui/widget/DetailWidget.cpp b/src/ui/widget/DetailWidget.cpp index ce950594e..01a1882ca 100644 --- a/src/ui/widget/DetailWidget.cpp +++ b/src/ui/widget/DetailWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DetailWidget.h" @@ -38,7 +38,7 @@ DetailWidget::~DetailWidget() void DetailWidget::setDetails(const QString& pDetails) { - mUi->detailText->setAccessibleName(tr("Service provider details dialog") + pDetails); + mUi->detailText->setAccessibleName(tr("Provider details dialog") + pDetails); mUi->detailText->setText(pDetails); } diff --git a/src/ui/widget/DetailWidget.h b/src/ui/widget/DetailWidget.h index c67e5a74f..3d008ed7b 100644 --- a/src/ui/widget/DetailWidget.h +++ b/src/ui/widget/DetailWidget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for cvc description. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/DeveloperModeHistoryWidget.cpp b/src/ui/widget/DeveloperModeHistoryWidget.cpp index bb5787839..df8d7919b 100644 --- a/src/ui/widget/DeveloperModeHistoryWidget.cpp +++ b/src/ui/widget/DeveloperModeHistoryWidget.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "DeveloperModeHistoryWidget.h" @@ -21,12 +21,14 @@ DeveloperModeHistoryWidget::DeveloperModeHistoryWidget(QWidget* pParent) { mUi->setupUi(this); - connect(Env::getSingleton(), &AppSettings::fireSettingsChanged, this, &DeveloperModeHistoryWidget::onSettingsChanged); + + const auto& generalSettings = Env::getSingleton()->getGeneralSettings(); + connect(&generalSettings, &GeneralSettings::fireDeveloperOptionsChanged, this, &DeveloperModeHistoryWidget::onDeveloperOptionsChanged); connect(Env::getSingleton(), &LogHandler::fireRawLog, this, &DeveloperModeHistoryWidget::onRawLog); connect(mUi->btnDisableDeveloperMode, &QPushButton::clicked, this, &DeveloperModeHistoryWidget::onDisableDeveloperMode); // initialize visibility state - onSettingsChanged(); + onDeveloperOptionsChanged(); } @@ -60,7 +62,7 @@ void DeveloperModeHistoryWidget::onRawLog(const QString& pMsg, const QString& pC } -void DeveloperModeHistoryWidget::onSettingsChanged() +void DeveloperModeHistoryWidget::onDeveloperOptionsChanged() { QWidget::setVisible(Env::getSingleton()->getGeneralSettings().isDeveloperMode()); } diff --git a/src/ui/widget/DeveloperModeHistoryWidget.h b/src/ui/widget/DeveloperModeHistoryWidget.h index 6b2c1f0d7..def530da5 100644 --- a/src/ui/widget/DeveloperModeHistoryWidget.h +++ b/src/ui/widget/DeveloperModeHistoryWidget.h @@ -1,7 +1,7 @@ /*! * \brief A Widget to display developer mode errors which occurred * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -40,7 +40,7 @@ class DeveloperModeHistoryWidget public Q_SLOTS: void onRawLog(const QString& pMsg, const QString& pCategoryName); - void onSettingsChanged(); + void onDeveloperOptionsChanged(); }; } // namespace governikus diff --git a/src/ui/widget/DeveloperSettingsWidget.cpp b/src/ui/widget/DeveloperSettingsWidget.cpp index 1f533bc38..90f2d3764 100644 --- a/src/ui/widget/DeveloperSettingsWidget.cpp +++ b/src/ui/widget/DeveloperSettingsWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "DeveloperSettingsWidget.h" @@ -7,6 +7,8 @@ #include "AppSettings.h" +#include + using namespace governikus; DeveloperSettingsWidget::DeveloperSettingsWidget(QWidget* pParent) @@ -15,9 +17,20 @@ DeveloperSettingsWidget::DeveloperSettingsWidget(QWidget* pParent) { mUi->setupUi(this); - reset(); + mUi->lblDeveloperModeWarning->setText(QStringLiteral("

%1

") + .arg(tr("The developer mode is aimed at integrators / developers for new service applications." + " For this reason, the developer mode works only in the test PKI." + " By activating the developer mode, some safety tests are deactivated." + " This means that the authentication process continues although the AusweisApp2 would usually abort the process with an error message when used in normal operation mode." + " Information on the disregarded error in the developer mode is displayed in the attached window below the AusweisApp2."))); connect(mUi->selfAuthTestCheckBox, &QCheckBox::stateChanged, this, &DeveloperSettingsWidget::onCheckBoxStateChanged); + connect(mUi->chkbDeveloperMode, &QCheckBox::stateChanged, this, &DeveloperSettingsWidget::onCheckBoxStateChanged); + + const auto& generalSettings = Env::getSingleton()->getGeneralSettings(); + connect(&generalSettings, &GeneralSettings::fireDeveloperOptionsChanged, this, &DeveloperSettingsWidget::reset); + + reset(); } @@ -42,13 +55,18 @@ void DeveloperSettingsWidget::apply() { auto& generalSettings = Env::getSingleton()->getGeneralSettings(); generalSettings.setUseSelfauthenticationTestUri(mUi->selfAuthTestCheckBox->isChecked()); + generalSettings.setDeveloperMode(mUi->chkbDeveloperMode->isChecked()); generalSettings.save(); } void DeveloperSettingsWidget::reset() { + // Avoid the fireSettingsChanged signal in onCheckBoxStateChanged when the + // developer mode is disabled by the button outside of the settings view. + const QSignalBlocker blocker(this); mUi->selfAuthTestCheckBox->setChecked(Env::getSingleton()->getGeneralSettings().useSelfAuthTestUri()); + mUi->chkbDeveloperMode->setChecked(Env::getSingleton()->getGeneralSettings().isDeveloperMode()); } diff --git a/src/ui/widget/DeveloperSettingsWidget.h b/src/ui/widget/DeveloperSettingsWidget.h index 45017b989..4d4d93dbd 100644 --- a/src/ui/widget/DeveloperSettingsWidget.h +++ b/src/ui/widget/DeveloperSettingsWidget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for the developer settings. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -38,6 +38,8 @@ class DeveloperSettingsWidget virtual ~DeveloperSettingsWidget() override; void apply(); + + public Q_SLOTS: void reset(); Q_SIGNALS: diff --git a/src/ui/widget/DeveloperSettingsWidget.ui b/src/ui/widget/DeveloperSettingsWidget.ui index f62347107..e7e6bda02 100644 --- a/src/ui/widget/DeveloperSettingsWidget.ui +++ b/src/ui/widget/DeveloperSettingsWidget.ui @@ -12,7 +12,7 @@
- 0 + 20 @@ -38,7 +38,7 @@ Qt::TabFocus - Self-authentication test URI: + Testmode for the self-authentication: @@ -52,9 +52,45 @@ + + + + true + + + Qt::TabFocus + + + Developer mode: + + + + + + + true + + + use + + + + + + + $developerWarning + + + true + + + Qt::TabFocus + + + diff --git a/src/ui/widget/DiagnosisDialog.cpp b/src/ui/widget/DiagnosisDialog.cpp index 6bbe3156e..2a9524df0 100644 --- a/src/ui/widget/DiagnosisDialog.cpp +++ b/src/ui/widget/DiagnosisDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisDialog.h" diff --git a/src/ui/widget/DiagnosisDialog.h b/src/ui/widget/DiagnosisDialog.h index 3b2e116a6..06c29d8cc 100644 --- a/src/ui/widget/DiagnosisDialog.h +++ b/src/ui/widget/DiagnosisDialog.h @@ -1,7 +1,7 @@ /*! * \brief Dialog for display the diagnosis information. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/DiagnosisGui.cpp b/src/ui/widget/DiagnosisGui.cpp index eb1fb76e2..d149ad707 100644 --- a/src/ui/widget/DiagnosisGui.cpp +++ b/src/ui/widget/DiagnosisGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisGui.h" diff --git a/src/ui/widget/DiagnosisGui.h b/src/ui/widget/DiagnosisGui.h index 6871749ec..f1c4f6f59 100644 --- a/src/ui/widget/DiagnosisGui.h +++ b/src/ui/widget/DiagnosisGui.h @@ -1,7 +1,7 @@ /*! * \brief Qt widget based DiagnosisUi implementation. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/GeneralSettingsWidget.cpp b/src/ui/widget/GeneralSettingsWidget.cpp index 8e70e7e23..2495c3912 100644 --- a/src/ui/widget/GeneralSettingsWidget.cpp +++ b/src/ui/widget/GeneralSettingsWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "GeneralSettingsWidget.h" @@ -35,6 +35,15 @@ GeneralSettingsWidget::GeneralSettingsWidget(QWidget* pParent) qCInfo(settings) << "Auto update check is configured system wide"; mUi->regularlyUpdateCheckBox->setEnabled(false); } + if (!generalSettings.isAutoStartAvailable()) + { + mUi->autostartCheckBox->setEnabled(false); + } + if (!generalSettings.isAutoUpdateAvailable()) + { + mUi->regularlyUpdateCheckBox->setEnabled(false); + mUi->updateCheckButton->setEnabled(false); + } reset(); diff --git a/src/ui/widget/GeneralSettingsWidget.h b/src/ui/widget/GeneralSettingsWidget.h index ec8ae1081..f61b0727a 100644 --- a/src/ui/widget/GeneralSettingsWidget.h +++ b/src/ui/widget/GeneralSettingsWidget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for the general settings. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/GeneralSettingsWidget.ui b/src/ui/widget/GeneralSettingsWidget.ui index 90f4863bc..281b1d964 100644 --- a/src/ui/widget/GeneralSettingsWidget.ui +++ b/src/ui/widget/GeneralSettingsWidget.ui @@ -44,25 +44,16 @@ - - true - check software update on program start check on program start - - true - - - true - 0 diff --git a/src/ui/widget/HistoryDetailWidget.cpp b/src/ui/widget/HistoryDetailWidget.cpp index f3f8b6ac3..5f7add106 100644 --- a/src/ui/widget/HistoryDetailWidget.cpp +++ b/src/ui/widget/HistoryDetailWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "HistoryDetailWidget.h" diff --git a/src/ui/widget/HistoryDetailWidget.h b/src/ui/widget/HistoryDetailWidget.h index 8c8b3f7d9..67db2e931 100644 --- a/src/ui/widget/HistoryDetailWidget.h +++ b/src/ui/widget/HistoryDetailWidget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for history item. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/HistoryWidget.cpp b/src/ui/widget/HistoryWidget.cpp index d6b3fde39..a53803082 100644 --- a/src/ui/widget/HistoryWidget.cpp +++ b/src/ui/widget/HistoryWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "HistoryWidget.h" diff --git a/src/ui/widget/HistoryWidget.h b/src/ui/widget/HistoryWidget.h index b3e063e7f..a07d18f02 100644 --- a/src/ui/widget/HistoryWidget.h +++ b/src/ui/widget/HistoryWidget.h @@ -1,7 +1,7 @@ /*! * \brief Show history entries. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/HistoryWidget.ui b/src/ui/widget/HistoryWidget.ui index 71977cd49..3e720e4dd 100644 --- a/src/ui/widget/HistoryWidget.ui +++ b/src/ui/widget/HistoryWidget.ui @@ -31,7 +31,7 @@ Qt::TabFocus - This page displays the history of your successful authentications. Double-click on a service provider for more information. You can delete parts or the entire history. You can also save the history as a PDF file. + This page displays the history of your successful authentications. Double-click on a provider for more information. You can delete parts or the entire history. You can also save the history as a PDF file. true diff --git a/src/ui/widget/LogFileSaveDialog.cpp b/src/ui/widget/LogFileSaveDialog.cpp index fa8042b5c..a47e82a26 100644 --- a/src/ui/widget/LogFileSaveDialog.cpp +++ b/src/ui/widget/LogFileSaveDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "Env.h" diff --git a/src/ui/widget/LogFileSaveDialog.h b/src/ui/widget/LogFileSaveDialog.h index d6aa981af..27abe4fb4 100644 --- a/src/ui/widget/LogFileSaveDialog.h +++ b/src/ui/widget/LogFileSaveDialog.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/LogFilesDialog.cpp b/src/ui/widget/LogFilesDialog.cpp index 73a9039b1..3fbef84bd 100644 --- a/src/ui/widget/LogFilesDialog.cpp +++ b/src/ui/widget/LogFilesDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "LogFilesDialog.h" @@ -139,11 +139,11 @@ void LogFilesDialog::onCurrentIndexChanged(int pIndex) void LogFilesDialog::onDeleteButtonClicked() { QMessageBox box(this); - box.setWindowTitle(tr("Delete log files")); + box.setWindowTitle(tr("Delete logfiles")); box.setWindowModality(Qt::ApplicationModal); box.setIcon(QMessageBox::Question); box.setWindowFlags(box.windowFlags() & ~Qt::WindowContextHelpButtonHint); - box.setText(tr("Do you really want to delete all old log files?")); + box.setText(tr("Do you really want to delete all old logfiles?")); box.setStandardButtons(QMessageBox::Yes | QMessageBox::No); box.button(QMessageBox::Yes)->setFocus(); diff --git a/src/ui/widget/LogFilesDialog.h b/src/ui/widget/LogFilesDialog.h index ebed48200..ce1907fab 100644 --- a/src/ui/widget/LogFilesDialog.h +++ b/src/ui/widget/LogFilesDialog.h @@ -1,7 +1,7 @@ /*! - * \brief Dialog for display the old log files. + * \brief Dialog for display the old logfiles. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/LogFilesDialog.ui b/src/ui/widget/LogFilesDialog.ui index b62f844d0..7545313d0 100644 --- a/src/ui/widget/LogFilesDialog.ui +++ b/src/ui/widget/LogFilesDialog.ui @@ -11,7 +11,7 @@
- Log files + Logfiles diff --git a/src/ui/widget/PinSettingsInfoWidget.cpp b/src/ui/widget/PinSettingsInfoWidget.cpp index 742b59129..81b619489 100644 --- a/src/ui/widget/PinSettingsInfoWidget.cpp +++ b/src/ui/widget/PinSettingsInfoWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PinSettingsInfoWidget.h" diff --git a/src/ui/widget/PinSettingsInfoWidget.h b/src/ui/widget/PinSettingsInfoWidget.h index 52fdb0088..929eff607 100644 --- a/src/ui/widget/PinSettingsInfoWidget.h +++ b/src/ui/widget/PinSettingsInfoWidget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for PIN settings information. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/PinSettingsWidget.cpp b/src/ui/widget/PinSettingsWidget.cpp index 5c032340e..832414ddb 100644 --- a/src/ui/widget/PinSettingsWidget.cpp +++ b/src/ui/widget/PinSettingsWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PinSettingsWidget.h" diff --git a/src/ui/widget/PinSettingsWidget.h b/src/ui/widget/PinSettingsWidget.h index 2cbe45d6d..e616b9b09 100644 --- a/src/ui/widget/PinSettingsWidget.h +++ b/src/ui/widget/PinSettingsWidget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for the PIN settings. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/PinSettingsWidget.ui b/src/ui/widget/PinSettingsWidget.ui index 52ca4a0de..3ae8a618e 100644 --- a/src/ui/widget/PinSettingsWidget.ui +++ b/src/ui/widget/PinSettingsWidget.ui @@ -114,7 +114,7 @@ Please note that the PIN may only consist of digits (0-9). Qt::TabFocus - You have entered the wrong PIN three times. The online identification function is now blocked. Please use your personal unblocking key (PUK) to unblock your ID card. You received the PUK with the letter sent to you by your competent authority. + A wrong PIN has been entered three times on your ID card. Your PIN is now blocked. To unblock your PIN you have to enter the PUK. You received the PUK with the letter sent to you by your competent authority. Please note that you can only use the PUK to unblock the eID function. If you have forgotten your PIN, you can have a new PIN set at your competent authority. @@ -156,7 +156,7 @@ Please note that you can only use the PUK to unblock the eID function. If you ha Qt::TabFocus - CAN on nPA icon + Display of the card access number (CAN) in the lower right corner of the id card :/images/canHint.png @@ -172,7 +172,7 @@ Please note that you can only use the PUK to unblock the eID function. If you ha Qt::TabFocus - You have entered the wrong PIN two times. For a third attempt you first have to enter your six-digit card access number. You can find your card access number on the front side of your ID card next to the date of expiry. On the electronic residence permit the card access number is printed above your signature. + A wrong PIN has been entered twice on your ID card. Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. You can find your card access number (CAN) on the front of your ID card. true @@ -340,7 +340,7 @@ Please note that you can only use the PUK to unblock the eID function. If you ha <html> <h4>Extended Length is not supported.</h4> -<p>Your remote reader does not meet the technical requirements (Extended Length not supported).</p> +<p>Your smartphone as card reader (SaC) does not meet the technical requirements (Extended Length not supported).</p> </html> @@ -416,7 +416,7 @@ Please note that you can only use the PUK to unblock the eID function. If you ha <html> <h4>eID feature deactivated</h4> -<p>The eID function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the eID function.</p> +<p>The eID function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the eID function.</p> </html> @@ -1007,7 +1007,7 @@ Please note that you can only use the PUK to unblock the eID function. If you ha - Click on "Change PIN" to enter your card access number and then set a new PIN. You can find your card access number on the front side of your ID card next to the date of expiry. On the electronic residence permit the card access number is printed above your signature. + Click on "Change PIN" to enter your card access number (CAN) and then set a new PIN. You can find your card access number (CAN) on the front side of your ID card next to the date of expiry. On the electronic residence permit the card access number (CAN) is printed above your signature. Qt::AlignCenter @@ -1217,7 +1217,7 @@ If not, you can now remove your ID card form the card reader. Qt::TabFocus - no id card icon + no ID card icon Qt::AlignCenter diff --git a/src/ui/widget/ProviderWidget.cpp b/src/ui/widget/ProviderWidget.cpp index 866ad64b5..97170de63 100644 --- a/src/ui/widget/ProviderWidget.cpp +++ b/src/ui/widget/ProviderWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderWidget.h" diff --git a/src/ui/widget/ProviderWidget.h b/src/ui/widget/ProviderWidget.h index 043b2d42b..c0652bd47 100644 --- a/src/ui/widget/ProviderWidget.h +++ b/src/ui/widget/ProviderWidget.h @@ -1,7 +1,7 @@ /*! * \brief The provider page in gui. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/ProviderWidget.ui b/src/ui/widget/ProviderWidget.ui index a6f3b974e..8d1237f6e 100644 --- a/src/ui/widget/ProviderWidget.ui +++ b/src/ui/widget/ProviderWidget.ui @@ -31,10 +31,10 @@ Qt::TabFocus - This section lists offers of service providers that support online identification. Click on an entry to go to the provider's web site. This section will be continuously updated with further applications for the online identification function. + This section lists offers of providers that support online identification. Click on an entry to go to the provider's web site. This section will be continuously updated with further applications for the online identification function. - This section lists offers of service providers that support online identification. Click on an entry to go to the provider's web site. This section will be continuously updated with further applications for the online identification function. + This section lists offers of providers that support online identification. Click on an entry to go to the provider's web site. This section will be continuously updated with further applications for the online identification function. true diff --git a/src/ui/widget/RandomPinDialog.cpp b/src/ui/widget/RandomPinDialog.cpp index fff864d38..d76ecc66a 100644 --- a/src/ui/widget/RandomPinDialog.cpp +++ b/src/ui/widget/RandomPinDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "RandomPinDialog.h" diff --git a/src/ui/widget/RandomPinDialog.h b/src/ui/widget/RandomPinDialog.h index 2232bccbe..34b6d735c 100644 --- a/src/ui/widget/RandomPinDialog.h +++ b/src/ui/widget/RandomPinDialog.h @@ -1,7 +1,7 @@ /*! * \brief Dialog for display the random PIN. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/ReaderDeviceDialog.cpp b/src/ui/widget/ReaderDeviceDialog.cpp index ecb474714..00864ef9d 100644 --- a/src/ui/widget/ReaderDeviceDialog.cpp +++ b/src/ui/widget/ReaderDeviceDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDeviceDialog.h" diff --git a/src/ui/widget/ReaderDeviceDialog.h b/src/ui/widget/ReaderDeviceDialog.h index b1f1f726f..c84c8f573 100644 --- a/src/ui/widget/ReaderDeviceDialog.h +++ b/src/ui/widget/ReaderDeviceDialog.h @@ -2,7 +2,7 @@ * \brief Dialog for detecting attached card readers or available * remote card readers. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/ReaderDeviceGui.cpp b/src/ui/widget/ReaderDeviceGui.cpp index e9e03c2b6..6fbdc82e3 100644 --- a/src/ui/widget/ReaderDeviceGui.cpp +++ b/src/ui/widget/ReaderDeviceGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDeviceGui.h" diff --git a/src/ui/widget/ReaderDeviceGui.h b/src/ui/widget/ReaderDeviceGui.h index b212a8541..0fd481500 100644 --- a/src/ui/widget/ReaderDeviceGui.h +++ b/src/ui/widget/ReaderDeviceGui.h @@ -1,7 +1,7 @@ /*! * \brief Qt widget based ReaderDriverUi implementation. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/ReaderDeviceWidget.cpp b/src/ui/widget/ReaderDeviceWidget.cpp index 05167f087..bad6f7c73 100644 --- a/src/ui/widget/ReaderDeviceWidget.cpp +++ b/src/ui/widget/ReaderDeviceWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDeviceWidget.h" @@ -226,6 +226,14 @@ void ReaderDeviceWidget::onUpdateRemoteTableSelection() selectionModel->select(mRemoteReaderDataModel.index(0, RemoteDeviceModel::ColumnId::ReaderName), QItemSelectionModel::Select); selectionModel->select(mRemoteReaderDataModel.index(0, RemoteDeviceModel::ColumnId::ReaderStatus), QItemSelectionModel::Select); } + else + { + Q_ASSERT(selectionModel->selectedRows().size() == 1); + const auto currentIndex = selectionModel->selectedRows().at(0); + const auto model = selectionModel->model(); + mUi->tableViewRemote->update(model->index(currentIndex.row(), RemoteDeviceModel::ColumnId::ReaderName)); + mUi->tableViewRemote->update(model->index(currentIndex.row(), RemoteDeviceModel::ColumnId::ReaderStatus)); + } } else { @@ -284,7 +292,7 @@ void ReaderDeviceWidget::onConnectClicked() setEnabled(false); QMessageBox pairingInfoBox(this); - pairingInfoBox.setText(tr("Please start pairing mode first.")); + pairingInfoBox.setText(tr("Start the pairing mode on your smartphone if you haven't done it already.")); pairingInfoBox.setWindowModality(Qt::WindowModal); pairingInfoBox.setWindowFlags(pairingInfoBox.windowFlags() & ~Qt::WindowContextHelpButtonHint); pairingInfoBox.setStandardButtons(QMessageBox::Ok | QMessageBox::Cancel); diff --git a/src/ui/widget/ReaderDeviceWidget.h b/src/ui/widget/ReaderDeviceWidget.h index 90358385d..852eb75a0 100644 --- a/src/ui/widget/ReaderDeviceWidget.h +++ b/src/ui/widget/ReaderDeviceWidget.h @@ -2,7 +2,7 @@ * \brief Widget for detecting attached card readers and * suggesting an appropriate driver to be installed. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/RemotePinInputDialog.cpp b/src/ui/widget/RemotePinInputDialog.cpp index dc6ac7558..39a4c011d 100644 --- a/src/ui/widget/RemotePinInputDialog.cpp +++ b/src/ui/widget/RemotePinInputDialog.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemotePinInputDialog.h" diff --git a/src/ui/widget/RemotePinInputDialog.h b/src/ui/widget/RemotePinInputDialog.h index f7c726e74..85b1e1f33 100644 --- a/src/ui/widget/RemotePinInputDialog.h +++ b/src/ui/widget/RemotePinInputDialog.h @@ -1,7 +1,7 @@ /*! * \brief Dialog for PIN input for device pairing. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/SelfInformationWidget.cpp b/src/ui/widget/SelfInformationWidget.cpp index bdbefbdcd..bb663fd89 100644 --- a/src/ui/widget/SelfInformationWidget.cpp +++ b/src/ui/widget/SelfInformationWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SelfInformationWidget.h" @@ -21,12 +21,15 @@ SelfInformationWidget::SelfInformationWidget(QWidget* pParent) mUi->setupUi(this); connect(mUi->selfAuthenticationButton, &QAbstractButton::clicked, this, &SelfInformationWidget::selfAuthenticationRequested); - connect(&Env::getSingleton()->getGeneralSettings(), &AbstractSettings::fireSettingsChanged, this, &SelfInformationWidget::onSettingsChanged); + const auto& generalSettings = Env::getSingleton()->getGeneralSettings(); + connect(&generalSettings, &GeneralSettings::fireLanguageChanged, this, &SelfInformationWidget::onLanguageChanged); + connect(&generalSettings, &GeneralSettings::fireDeveloperOptionsChanged, this, &SelfInformationWidget::onDeveloperOptionsChanged); mPixDescLogoLabel.reset(new QPixmap(QStringLiteral(":/images/siteWithLogo.png"))); mUi->descriptionLogoLabel->setPixmap(mPixDescLogoLabel->scaled(159, 120, Qt::IgnoreAspectRatio, Qt::SmoothTransformation)); - onSettingsChanged(); + onLanguageChanged(); + onDeveloperOptionsChanged(); } @@ -44,13 +47,17 @@ void SelfInformationWidget::paintEvent(QPaintEvent*) } -void SelfInformationWidget::onSettingsChanged() +void SelfInformationWidget::onLanguageChanged() { const auto desc = tr("Use the button 'See my personal data now...' to display the data stored on your ID card. An Internet connection is required to display the data."); const auto hyperlink = QStringLiteral(R"(%2)").arg(tr("https://www.ausweisapp.bund.de/datenschutz/"), tr("data privacy statement")); const auto info = tr("Your personal data is neither saved nor processed in any way. Please see our %1 for details on how your personal data is processed.").arg(hyperlink); mUi->descriptionLabel->setText(desc + QStringLiteral("

") + info); +} + +void SelfInformationWidget::onDeveloperOptionsChanged() +{ if (Env::getSingleton()->getGeneralSettings().useSelfAuthTestUri()) { mUi->selfAuthenticationButton->setStyleSheet(QStringLiteral("QPushButton { background: red; }")); @@ -69,7 +76,7 @@ void SelfInformationWidget::changeEvent(QEvent* pEvent) if (pEvent->type() == QEvent::LanguageChange) { mUi->retranslateUi(this); - onSettingsChanged(); + onLanguageChanged(); } QWidget::changeEvent(pEvent); } diff --git a/src/ui/widget/SelfInformationWidget.h b/src/ui/widget/SelfInformationWidget.h index 5c4fa8e2c..dee65c458 100644 --- a/src/ui/widget/SelfInformationWidget.h +++ b/src/ui/widget/SelfInformationWidget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for starting the self information workflow. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -39,7 +39,8 @@ class SelfInformationWidget virtual void paintEvent(QPaintEvent*) override; private Q_SLOTS: - void onSettingsChanged(); + void onLanguageChanged(); + void onDeveloperOptionsChanged(); }; } // namespace governikus diff --git a/src/ui/widget/SettingsWidget.cpp b/src/ui/widget/SettingsWidget.cpp index b88a681e0..b70afd5f9 100644 --- a/src/ui/widget/SettingsWidget.cpp +++ b/src/ui/widget/SettingsWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SettingsWidget.h" @@ -37,20 +37,18 @@ SettingsWidget::SettingsWidget(QWidget* pParent) connect(mUi->settingsTabWidget, &QTabWidget::currentChanged, this, &SettingsWidget::onTabChanged); - mUi->pinTab->setUseScreenKeyboard(Env::getSingleton()->getGeneralSettings().isUseScreenKeyboard()); + const auto& generalSettings = Env::getSingleton()->getGeneralSettings(); + mUi->pinTab->setUseScreenKeyboard(generalSettings.isUseScreenKeyboard()); connect(this, &SettingsWidget::fireBackspacePressedOnApply, mUi->pinTab, &PinSettingsWidget::onBackspacePressedOnApply); -#ifndef QT_NO_DEBUG mDeveloperTab.reset(new DeveloperSettingsWidget()); mDeveloperTab->setObjectName(QStringLiteral("developerTab")); - mUi->settingsTabWidget->addTab(mDeveloperTab.data(), QString()); - setDeveloperTabName(); - connect(mDeveloperTab.data(), &DeveloperSettingsWidget::fireSettingsChanged, this, &SettingsWidget::onSettingsChanged); -#endif + connect(&generalSettings, &GeneralSettings::fireDeveloperOptionsChanged, this, &SettingsWidget::onDeveloperOptionsChanged); setSettingsChanged(false); onUpdateApplyButtonText(); + onDeveloperOptionsChanged(); } @@ -155,7 +153,7 @@ void SettingsWidget::showEvent(QShowEvent* pEvent) void SettingsWidget::onTabChanged(int pIndex) { QWidget* const currentWidget = mUi->settingsTabWidget->widget(pIndex); - if (currentWidget != mUi->generalTab) + if (currentWidget != mUi->generalTab && currentWidget != mDeveloperTab.data()) { if (mSettingsChanged) { @@ -224,11 +222,7 @@ void SettingsWidget::onApplyButtonClicked() Q_EMIT changePinRequested(); } } - else if (currentWidget == mUi->generalTab -#ifndef QT_NO_DEBUG - || currentWidget == mDeveloperTab.data() -#endif - ) + else if (currentWidget == mUi->generalTab || currentWidget == mDeveloperTab.data()) { applyAppSettings(); } @@ -247,12 +241,8 @@ bool SettingsWidget::isSettingsChanged() void SettingsWidget::applyAppSettings() { - // apply button clicked mUi->generalTab->apply(); -#ifndef QT_NO_DEBUG mDeveloperTab->apply(); -#endif - setSettingsChanged(false); } @@ -275,12 +265,33 @@ void SettingsWidget::onSettingsChanged() } +void SettingsWidget::onDeveloperOptionsChanged() +{ + const auto& generalSettings = Env::getSingleton()->getGeneralSettings(); + const int index = mUi->settingsTabWidget->indexOf(mDeveloperTab.data()); + + if (generalSettings.isDeveloperOptions() && index == -1) + { + mUi->settingsTabWidget->addTab(mDeveloperTab.data(), QString()); + setDeveloperTabName(); + return; + } + + if (!generalSettings.isDeveloperOptions() && index > -1) + { + if (index == mUi->settingsTabWidget->currentIndex()) + { + mSettingsChanged = false; + } + mUi->settingsTabWidget->removeTab(index); + } +} + + void SettingsWidget::resetSettings() { mUi->generalTab->reset(); -#ifndef QT_NO_DEBUG mDeveloperTab->reset(); -#endif setSettingsChanged(false); } @@ -312,20 +323,18 @@ void SettingsWidget::changeEvent(QEvent* pEvent) void SettingsWidget::setDeveloperTabName() { -#ifndef QT_NO_DEBUG - mUi->settingsTabWidget->setTabText(mUi->settingsTabWidget->indexOf(mDeveloperTab.data()), tr("Developer Settings")); -#endif + const int index = mUi->settingsTabWidget->indexOf(mDeveloperTab.data()); + if (index > -1) + { + mUi->settingsTabWidget->setTabText(index, tr("Developer options")); + } } void SettingsWidget::onUpdateApplyButtonText() { const QWidget* const currentWidget = mUi->settingsTabWidget->currentWidget(); - if (currentWidget == mUi->generalTab -#ifndef QT_NO_DEBUG - || currentWidget == mDeveloperTab.data() -#endif - ) + if (currentWidget == mUi->generalTab || currentWidget == mDeveloperTab.data()) { mUi->applyButton->setText(tr("Apply")); } @@ -348,11 +357,7 @@ void SettingsWidget::onUpdateButtonState() cancelButton->setEnabled(true); const QWidget* const currentWidget = mUi->settingsTabWidget->currentWidget(); - if (currentWidget == mUi->generalTab -#ifndef QT_NO_DEBUG - || currentWidget == mDeveloperTab.data() -#endif - ) + if (currentWidget == mUi->generalTab || currentWidget == mDeveloperTab.data()) { applyButton->setEnabled(mSettingsChanged); } diff --git a/src/ui/widget/SettingsWidget.h b/src/ui/widget/SettingsWidget.h index a6c5c4b65..8ce7e01bd 100644 --- a/src/ui/widget/SettingsWidget.h +++ b/src/ui/widget/SettingsWidget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for the settings. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -30,10 +30,7 @@ class SettingsWidget bool mScanRunning; bool mWorkflowRunning; bool mSettingsChanged; - -#ifndef QT_NO_DEBUG QScopedPointer mDeveloperTab; -#endif void resetSettings(); void setSettingsChanged(bool pChanged); @@ -50,6 +47,7 @@ class SettingsWidget void onUpdateButtonState(); void onUpdateApplyButtonText(); void onSettingsChanged(); + void onDeveloperOptionsChanged(); protected: virtual void paintEvent(QPaintEvent*) override; diff --git a/src/ui/widget/SetupAssistantGui.cpp b/src/ui/widget/SetupAssistantGui.cpp index 66246e84b..484255ffc 100644 --- a/src/ui/widget/SetupAssistantGui.cpp +++ b/src/ui/widget/SetupAssistantGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "SetupAssistantGui.h" diff --git a/src/ui/widget/SetupAssistantGui.h b/src/ui/widget/SetupAssistantGui.h index 08db637ba..c0a9374fa 100644 --- a/src/ui/widget/SetupAssistantGui.h +++ b/src/ui/widget/SetupAssistantGui.h @@ -1,7 +1,7 @@ /*! * \brief Qt widget based SetupAssistantUi implementation. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/SetupAssistantWizard.cpp b/src/ui/widget/SetupAssistantWizard.cpp index 426d03743..a6069b722 100644 --- a/src/ui/widget/SetupAssistantWizard.cpp +++ b/src/ui/widget/SetupAssistantWizard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SetupAssistantWizard.h" @@ -167,7 +167,7 @@ QWizardPage* SetupAssistantWizard::createConclusionPage() auto* conclusionPageVLayout = new QVBoxLayout(conclusionPage); - const auto& title = tr("Personal 6 - digit PIN"); + const auto& title = tr("Personal 6-digit PIN"); const auto& desc = tr("Prior to the first use of the online identification function, you have to replace the transport PIN by an individual 6-digit PIN. " "The transport PIN was sent to you by postal mail."); QLabel* transportPinLabel = new QLabel(createDescription(title, desc)); diff --git a/src/ui/widget/SetupAssistantWizard.h b/src/ui/widget/SetupAssistantWizard.h index d3572c9ee..481145301 100644 --- a/src/ui/widget/SetupAssistantWizard.h +++ b/src/ui/widget/SetupAssistantWizard.h @@ -1,7 +1,7 @@ /*! * \brief Setup assistant wizard before application startup. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/UIPlugInWidgets.cpp b/src/ui/widget/UIPlugInWidgets.cpp index c3a87b6cf..f9b1723ec 100644 --- a/src/ui/widget/UIPlugInWidgets.cpp +++ b/src/ui/widget/UIPlugInWidgets.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugInWidgets.h" diff --git a/src/ui/widget/UIPlugInWidgets.h b/src/ui/widget/UIPlugInWidgets.h index e8628c70f..00af86752 100644 --- a/src/ui/widget/UIPlugInWidgets.h +++ b/src/ui/widget/UIPlugInWidgets.h @@ -1,7 +1,7 @@ /*! * \brief QWidgets implementation of UIPlugIn. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/UpdateWindow.cpp b/src/ui/widget/UpdateWindow.cpp index 462102bdb..a6026294b 100644 --- a/src/ui/widget/UpdateWindow.cpp +++ b/src/ui/widget/UpdateWindow.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "UpdateWindow.h" diff --git a/src/ui/widget/UpdateWindow.h b/src/ui/widget/UpdateWindow.h index 0b2ba2f7c..f9452f21f 100644 --- a/src/ui/widget/UpdateWindow.h +++ b/src/ui/widget/UpdateWindow.h @@ -1,7 +1,7 @@ /*! * \brief Window for application updates * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/UpdateWindow.ui b/src/ui/widget/UpdateWindow.ui index 8d1e3b482..da81ec27e 100644 --- a/src/ui/widget/UpdateWindow.ui +++ b/src/ui/widget/UpdateWindow.ui @@ -84,7 +84,7 @@ Qt::TabFocus
- Release Notes: + Release notes: diff --git a/src/ui/widget/generic/BusyOverlay.cpp b/src/ui/widget/generic/BusyOverlay.cpp index bea53fb9f..953a04fc5 100644 --- a/src/ui/widget/generic/BusyOverlay.cpp +++ b/src/ui/widget/generic/BusyOverlay.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "BusyOverlay.h" diff --git a/src/ui/widget/generic/BusyOverlay.h b/src/ui/widget/generic/BusyOverlay.h index 14bbc3b9b..f1fdbe21f 100644 --- a/src/ui/widget/generic/BusyOverlay.h +++ b/src/ui/widget/generic/BusyOverlay.h @@ -1,7 +1,7 @@ /*! * \brief Widget for the settings. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/BusyOverlayContainer.cpp b/src/ui/widget/generic/BusyOverlayContainer.cpp index b99bdf386..8eef8c193 100644 --- a/src/ui/widget/generic/BusyOverlayContainer.cpp +++ b/src/ui/widget/generic/BusyOverlayContainer.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "BusyOverlayContainer.h" diff --git a/src/ui/widget/generic/BusyOverlayContainer.h b/src/ui/widget/generic/BusyOverlayContainer.h index 4ebf70b3a..7859e1cbb 100644 --- a/src/ui/widget/generic/BusyOverlayContainer.h +++ b/src/ui/widget/generic/BusyOverlayContainer.h @@ -1,7 +1,7 @@ /*! * \brief An overlay to show a busy indicator. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/ButtonState.h b/src/ui/widget/generic/ButtonState.h index 599255bcd..8c1f0e41e 100644 --- a/src/ui/widget/generic/ButtonState.h +++ b/src/ui/widget/generic/ButtonState.h @@ -1,7 +1,7 @@ /*! * \brief Defines the ButtonState enum. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/ExclusiveButtonGroup.cpp b/src/ui/widget/generic/ExclusiveButtonGroup.cpp index 31cf3c101..9560d3f37 100644 --- a/src/ui/widget/generic/ExclusiveButtonGroup.cpp +++ b/src/ui/widget/generic/ExclusiveButtonGroup.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ExclusiveButtonGroup.h" diff --git a/src/ui/widget/generic/ExclusiveButtonGroup.h b/src/ui/widget/generic/ExclusiveButtonGroup.h index 5957f61c5..8b17892cd 100644 --- a/src/ui/widget/generic/ExclusiveButtonGroup.h +++ b/src/ui/widget/generic/ExclusiveButtonGroup.h @@ -4,7 +4,7 @@ * Bug in Qt 5.2.1: Buttons in a QButtonGroup cannot be navigated via the Tab key. This * class provides a work-around for simple cases. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/GuiModule.h b/src/ui/widget/generic/GuiModule.h index 585397bc6..c02555759 100644 --- a/src/ui/widget/generic/GuiModule.h +++ b/src/ui/widget/generic/GuiModule.h @@ -1,7 +1,7 @@ /*! * \brief Defines the GuiModule enum. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/GuiUtils.cpp b/src/ui/widget/generic/GuiUtils.cpp index 51e0c7ee6..d8949dd20 100644 --- a/src/ui/widget/generic/GuiUtils.cpp +++ b/src/ui/widget/generic/GuiUtils.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "GuiUtils.h" @@ -29,8 +29,7 @@ bool GuiUtils::showPinCanPukErrorDialog(CardReturnCode pReturnCode, bool pCanAll else { text = tr("The given card access number (CAN) is not correct. You have one more try to enter the correct PIN." - " Please mind that you have to acknowledge this last try with your card access" - " number (CAN)."); + " Please mind that you have to acknowledge this last try with your card access number (CAN)."); } break; @@ -113,7 +112,7 @@ bool GuiUtils::showPinUnlockedDialog(QWidget* pParent) { QMessageBox messageBox(pParent); - QString title = tr("PIN successfully unblocked"); + QString title = tr("You have successfully unblocked your PIN"); QString text = tr("Your ID card is unblocked. You now have three more tries to change your PIN"); messageBox.setWindowTitle(QCoreApplication::applicationName() + QStringLiteral(" - ") + title); messageBox.setWindowModality(Qt::WindowModal); diff --git a/src/ui/widget/generic/GuiUtils.h b/src/ui/widget/generic/GuiUtils.h index 34e2ce7bf..fdb2cf040 100644 --- a/src/ui/widget/generic/GuiUtils.h +++ b/src/ui/widget/generic/GuiUtils.h @@ -1,7 +1,7 @@ /*! * \brief Gui utility functions. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/ListCheckItemWidget.cpp b/src/ui/widget/generic/ListCheckItemWidget.cpp index d60a73c31..06fc927eb 100644 --- a/src/ui/widget/generic/ListCheckItemWidget.cpp +++ b/src/ui/widget/generic/ListCheckItemWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ListCheckItemWidget.h" diff --git a/src/ui/widget/generic/ListCheckItemWidget.h b/src/ui/widget/generic/ListCheckItemWidget.h index c044ea562..3b46fb2f6 100644 --- a/src/ui/widget/generic/ListCheckItemWidget.h +++ b/src/ui/widget/generic/ListCheckItemWidget.h @@ -1,7 +1,7 @@ /*! * \brief List item widget for list actions. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/ListItem.cpp b/src/ui/widget/generic/ListItem.cpp index 9e3a49eb6..9973d006c 100644 --- a/src/ui/widget/generic/ListItem.cpp +++ b/src/ui/widget/generic/ListItem.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ListItem.h" diff --git a/src/ui/widget/generic/ListItem.h b/src/ui/widget/generic/ListItem.h index ef0cc2ee4..d239bcf6e 100644 --- a/src/ui/widget/generic/ListItem.h +++ b/src/ui/widget/generic/ListItem.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/ListItemIconLeft.cpp b/src/ui/widget/generic/ListItemIconLeft.cpp index 624339310..eff4dcf37 100644 --- a/src/ui/widget/generic/ListItemIconLeft.cpp +++ b/src/ui/widget/generic/ListItemIconLeft.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ListItemIconLeft.h" diff --git a/src/ui/widget/generic/ListItemIconLeft.h b/src/ui/widget/generic/ListItemIconLeft.h index a47545214..56a855b77 100644 --- a/src/ui/widget/generic/ListItemIconLeft.h +++ b/src/ui/widget/generic/ListItemIconLeft.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/ListItemIconRight.cpp b/src/ui/widget/generic/ListItemIconRight.cpp index 644ffee74..129db61e1 100644 --- a/src/ui/widget/generic/ListItemIconRight.cpp +++ b/src/ui/widget/generic/ListItemIconRight.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ListItemIconRight.h" diff --git a/src/ui/widget/generic/ListItemIconRight.h b/src/ui/widget/generic/ListItemIconRight.h index 0dab030bb..261d3c885 100644 --- a/src/ui/widget/generic/ListItemIconRight.h +++ b/src/ui/widget/generic/ListItemIconRight.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/ListItemSubTitle.cpp b/src/ui/widget/generic/ListItemSubTitle.cpp index 883cfd8a5..39ad1a04c 100644 --- a/src/ui/widget/generic/ListItemSubTitle.cpp +++ b/src/ui/widget/generic/ListItemSubTitle.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ListItemSubTitle.h" diff --git a/src/ui/widget/generic/ListItemSubTitle.h b/src/ui/widget/generic/ListItemSubTitle.h index b24fb80bd..a47a531dd 100644 --- a/src/ui/widget/generic/ListItemSubTitle.h +++ b/src/ui/widget/generic/ListItemSubTitle.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/ListItemTitle.cpp b/src/ui/widget/generic/ListItemTitle.cpp index 5e987fec5..c15e634fd 100644 --- a/src/ui/widget/generic/ListItemTitle.cpp +++ b/src/ui/widget/generic/ListItemTitle.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ListItemTitle.h" diff --git a/src/ui/widget/generic/ListItemTitle.h b/src/ui/widget/generic/ListItemTitle.h index e19bad886..190c7d0c6 100644 --- a/src/ui/widget/generic/ListItemTitle.h +++ b/src/ui/widget/generic/ListItemTitle.h @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/PasswordEdit.cpp b/src/ui/widget/generic/PasswordEdit.cpp index 5eeec94e2..2ccbb4e38 100644 --- a/src/ui/widget/generic/PasswordEdit.cpp +++ b/src/ui/widget/generic/PasswordEdit.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/src/ui/widget/generic/PasswordEdit.h b/src/ui/widget/generic/PasswordEdit.h index 50756b3c9..f337064e9 100644 --- a/src/ui/widget/generic/PasswordEdit.h +++ b/src/ui/widget/generic/PasswordEdit.h @@ -1,7 +1,7 @@ /*! * \brief Widget for entering a password that uses the password echo mode. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/generic/TabButtonGroup.cpp b/src/ui/widget/generic/TabButtonGroup.cpp index 9aef2a919..fe8072a39 100644 --- a/src/ui/widget/generic/TabButtonGroup.cpp +++ b/src/ui/widget/generic/TabButtonGroup.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "TabButtonGroup.h" diff --git a/src/ui/widget/generic/TabButtonGroup.h b/src/ui/widget/generic/TabButtonGroup.h index a3be62c2e..27173d5ee 100644 --- a/src/ui/widget/generic/TabButtonGroup.h +++ b/src/ui/widget/generic/TabButtonGroup.h @@ -3,7 +3,7 @@ * * The other classes defined in this header are implementation private. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/AuthenticateStepsWidget.cpp b/src/ui/widget/step/AuthenticateStepsWidget.cpp index 8ec3893f1..9617ca8e3 100644 --- a/src/ui/widget/step/AuthenticateStepsWidget.cpp +++ b/src/ui/widget/step/AuthenticateStepsWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "AuthenticateStepsWidget.h" diff --git a/src/ui/widget/step/AuthenticateStepsWidget.h b/src/ui/widget/step/AuthenticateStepsWidget.h index 3b319b99d..7f6cc2015 100644 --- a/src/ui/widget/step/AuthenticateStepsWidget.h +++ b/src/ui/widget/step/AuthenticateStepsWidget.h @@ -1,7 +1,7 @@ /*! * \brief A stacked widget containing the widgets for the authentication steps. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/SelfInfoWidget.cpp b/src/ui/widget/step/SelfInfoWidget.cpp index 9a8de1975..e0e17d609 100644 --- a/src/ui/widget/step/SelfInfoWidget.cpp +++ b/src/ui/widget/step/SelfInfoWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SelfInfoWidget.h" @@ -70,7 +70,7 @@ void SelfInfoWidget::fillLayout() } QPushButton* exportButton = new QPushButton(tr("Save as PDF...")); - exportButton->setAccessibleName(tr("save id card data as pdf")); + exportButton->setAccessibleName(tr("save ID card data as pdf")); connect(exportButton, &QPushButton::clicked, this, &SelfInfoWidget::onPrintButtonClicked); diff --git a/src/ui/widget/step/SelfInfoWidget.h b/src/ui/widget/step/SelfInfoWidget.h index ab04fb4c0..47fb40ce5 100644 --- a/src/ui/widget/step/SelfInfoWidget.h +++ b/src/ui/widget/step/SelfInfoWidget.h @@ -1,7 +1,7 @@ /*! * \brief A widget displaying the card data retrieved in the self info workflow. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepAdviseUserToRemoveCardGui.cpp b/src/ui/widget/step/StepAdviseUserToRemoveCardGui.cpp index bcad1425b..0226720f5 100644 --- a/src/ui/widget/step/StepAdviseUserToRemoveCardGui.cpp +++ b/src/ui/widget/step/StepAdviseUserToRemoveCardGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepAdviseUserToRemoveCardGui.h" diff --git a/src/ui/widget/step/StepAdviseUserToRemoveCardGui.h b/src/ui/widget/step/StepAdviseUserToRemoveCardGui.h index e770e6939..b01908f4a 100644 --- a/src/ui/widget/step/StepAdviseUserToRemoveCardGui.h +++ b/src/ui/widget/step/StepAdviseUserToRemoveCardGui.h @@ -1,7 +1,7 @@ /*! * \brief Qt UI for the advise user to remove card step. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepAuthenticationDoneGui.cpp b/src/ui/widget/step/StepAuthenticationDoneGui.cpp index 0839cd863..4405be696 100644 --- a/src/ui/widget/step/StepAuthenticationDoneGui.cpp +++ b/src/ui/widget/step/StepAuthenticationDoneGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepAuthenticationDoneGui.h" diff --git a/src/ui/widget/step/StepAuthenticationDoneGui.h b/src/ui/widget/step/StepAuthenticationDoneGui.h index ce5fbabe1..17f5399b1 100644 --- a/src/ui/widget/step/StepAuthenticationDoneGui.h +++ b/src/ui/widget/step/StepAuthenticationDoneGui.h @@ -1,7 +1,7 @@ /*! * \brief Qt UI for the authentication done step. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepAuthenticationEac1Gui.cpp b/src/ui/widget/step/StepAuthenticationEac1Gui.cpp index cb87f24bd..9251bf30f 100644 --- a/src/ui/widget/step/StepAuthenticationEac1Gui.cpp +++ b/src/ui/widget/step/StepAuthenticationEac1Gui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepAuthenticationEac1Gui.h" diff --git a/src/ui/widget/step/StepAuthenticationEac1Gui.h b/src/ui/widget/step/StepAuthenticationEac1Gui.h index 99a1b2a25..aa8124fa7 100644 --- a/src/ui/widget/step/StepAuthenticationEac1Gui.h +++ b/src/ui/widget/step/StepAuthenticationEac1Gui.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepAuthenticationEac1Widget.cpp b/src/ui/widget/step/StepAuthenticationEac1Widget.cpp index fdfde691b..bf65f71a6 100644 --- a/src/ui/widget/step/StepAuthenticationEac1Widget.cpp +++ b/src/ui/widget/step/StepAuthenticationEac1Widget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepAuthenticationEac1Widget.h" @@ -123,15 +123,15 @@ void StepAuthenticationEac1Widget::updateButtonsAndPinWidget() { if (mContext->isCanAllowedMode()) { - mUi->pinGroupBox->setTitle(tr("Please enter the six-digit card access number (CAN) for identification.")); + mUi->pinGroupBox->setTitle(tr("Please enter the 6-digit card access number (CAN) for identification.")); } else if (cardConnection->getReaderInfo().getRetryCounter() == 1) { - mUi->pinGroupBox->setTitle(tr("Please enter your six-digit card access number (CAN) and your PIN for identification.")); + mUi->pinGroupBox->setTitle(tr("Please enter your 6-digit card access number (CAN) and your PIN for identification.")); } else { - mUi->pinGroupBox->setTitle(tr("Please enter your six digit PIN for identification")); + mUi->pinGroupBox->setTitle(tr("Please enter your 6-digit PIN for identification")); } if (cardConnection->getReaderInfo().isBasicReader()) @@ -193,7 +193,7 @@ void StepAuthenticationEac1Widget::onDetailsButtonClicked() auto certificateDescription = eac1->getCertificateDescription(); QString details; - details += tr("Service provider:") + QLatin1Char('\n'); + details += tr("Provider:") + QLatin1Char('\n'); details += certificateDescription->getSubjectName(); details += QLatin1Char('\n'); details += certificateDescription->getSubjectUrl(); @@ -221,10 +221,10 @@ void StepAuthenticationEac1Widget::setToolTip() { const auto& align = QStringLiteral("

%1

"); - const auto& certDesc = tr("Information on the service provider who wants to read out data from your ID card is given here. For further information press the button \"more...\"."); + const auto& certDesc = tr("Information on the provider who wants to read out data from your ID card is given here. For further information press the button \"more...\"."); mUi->certificateDescriptionGroupBox->setToolTip(align.arg(certDesc)); - const auto& fieldDesc = tr("Here you can select or deselect data fields to be read out. Mandatory data fields required by the service provider cannot be deselected."); + const auto& fieldDesc = tr("Here you can select or deselect data fields to be read out. Mandatory data fields required by the provider cannot be deselected."); mUi->groupBox->setToolTip(align.arg(fieldDesc)); } @@ -348,6 +348,12 @@ void StepAuthenticationEac1Widget::addChatRightToGui(AccessRight pRight, bool pO auto* cb = new QCheckBox(displayText); cb->setEnabled(pOptional); cb->setChecked(mContext->getEffectiveAccessRights().contains(pRight)); + if (AccessRoleAndRightsUtil::isWriteAccessRight(pRight)) + { + QPalette palette = cb->palette(); + palette.setColor(QPalette::WindowText, Qt::red); + cb->setPalette(palette); + } mMap.insert(cb, pRight); @@ -418,7 +424,7 @@ void StepAuthenticationEac1Widget::createBasicReaderWidget() mPINField->setEnabled(false); } - const QString labelLabel = mContext->isCanAllowedMode() == false ? tr("PIN:") : tr("CAN:"); + const QString labelLabel = mContext->isCanAllowedMode() == false ? tr("PIN:") : tr("Card access number (CAN):"); QLabel* pinLabel = new QLabel(labelLabel); pinLabel->setFocusPolicy(Qt::TabFocus); basicReaderWidgetLayout->addWidget(pinLabel); @@ -484,7 +490,7 @@ void StepAuthenticationEac1Widget::updateProgressPanel() doneWidgetLayout->addStretch(); QLabel* doneIcon = new QLabel; - QLabel* doneText = new QLabel(cancelled ? tr("The process was cancelled by the user") : tr("Identification successful")); + QLabel* doneText = new QLabel(cancelled ? tr("The process has been cancelled") : tr("Identification successful")); doneIcon->setPixmap(QPixmap(cancelled ? QStringLiteral(":/images/icon_cancelled.png") : QStringLiteral(":/images/icon_ok.png"))); doneWidgetLayout->addWidget(doneIcon); doneWidgetLayout->addWidget(doneText); diff --git a/src/ui/widget/step/StepAuthenticationEac1Widget.h b/src/ui/widget/step/StepAuthenticationEac1Widget.h index ace4e34a0..d7f14ddd9 100644 --- a/src/ui/widget/step/StepAuthenticationEac1Widget.h +++ b/src/ui/widget/step/StepAuthenticationEac1Widget.h @@ -1,7 +1,7 @@ /*! * \brief Widget for the desktop StepAuthenticationEac1Gui. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepAuthenticationEac1Widget.ui b/src/ui/widget/step/StepAuthenticationEac1Widget.ui index 5fd1b9718..349a2d607 100644 --- a/src/ui/widget/step/StepAuthenticationEac1Widget.ui +++ b/src/ui/widget/step/StepAuthenticationEac1Widget.ui @@ -26,7 +26,7 @@ Qt::TabFocus
- Service provider + Provider @@ -148,7 +148,7 @@ Qt::TabFocus
- The following data is required by the service provider. You can deselect the non-mandatory data fields if you do not want this data to be transmitted. + The following data is required by the provider. You can deselect the non-mandatory data fields if you do not want this data to be transmitted. true diff --git a/src/ui/widget/step/StepChooseCardGui.cpp b/src/ui/widget/step/StepChooseCardGui.cpp index b28c664b3..12be489b2 100644 --- a/src/ui/widget/step/StepChooseCardGui.cpp +++ b/src/ui/widget/step/StepChooseCardGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepChooseCardGui.h" @@ -230,7 +230,7 @@ void StepChooseCardGui::onReaderManagerSignal() if (askForRetry) { - updateErrorMessage(tr("Retry?"), tr("Weak NFC signal. Please reposition your card."), + updateErrorMessage(tr("Retry?"), tr("Weak NFC signal. Please\n- change the card position\n- remove the mobile phone case (if present)\n- connect the smartphone with a charging cable"), QString(), false, QStringLiteral(":/images/reader/default_card_position.png")); return; } @@ -242,7 +242,7 @@ void StepChooseCardGui::onReaderManagerSignal() if (readers.size() == 1) { updateErrorMessage(tr("Extended Length is not supported."), - tr("Your remote reader does not meet the technical requirements (Extended Length not supported)."), + tr("Your smartphone as card reader (SaC) does not meet the technical requirements (Extended Length not supported)."), QString(), false); return; @@ -260,7 +260,7 @@ void StepChooseCardGui::onReaderManagerSignal() QString remoteReaderInfo; if (remoteReaders.size() > 0) { - remoteReaderInfo = tr("Connected to following remote readers: %1.").arg(connectedRemoteReaderNames()); + remoteReaderInfo = tr("Connected to the following smartphones as card readers (SaCs): %1.").arg(connectedRemoteReaderNames()); } const QString onlineHelpUrl = HelpAction::getOnlineUrl(QStringLiteral("stepChooseCardGui")); const QString onlineHelpText = tr("If you have already placed an ID card on your card reader, " @@ -285,8 +285,8 @@ void StepChooseCardGui::onReaderManagerSignal() if (readersWithNpa[0].isPinDeactivated() && !mContext->isCanAllowedMode()) { updateErrorMessage(tr("Online identification function is disabled."), - tr("This action cannot be performed. The online identification function of your ID card is deactivated." - " Please contact the authority responsible for issuing your identification document to activate the online identification function."), + tr("This action cannot be performed. The online identification function of your ID card is not activated." + " Please contact the authority responsible for issuing your identification card to activate the online identification function."), QString(), false); } diff --git a/src/ui/widget/step/StepChooseCardGui.h b/src/ui/widget/step/StepChooseCardGui.h index 4b52f4d11..35435daa8 100644 --- a/src/ui/widget/step/StepChooseCardGui.h +++ b/src/ui/widget/step/StepChooseCardGui.h @@ -1,7 +1,7 @@ /*! * \brief GUI to select reader/card. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepErrorGui.cpp b/src/ui/widget/step/StepErrorGui.cpp index 293ef35fe..f38caab3d 100644 --- a/src/ui/widget/step/StepErrorGui.cpp +++ b/src/ui/widget/step/StepErrorGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepErrorGui.h" diff --git a/src/ui/widget/step/StepErrorGui.h b/src/ui/widget/step/StepErrorGui.h index b5a65bf5e..966b65685 100644 --- a/src/ui/widget/step/StepErrorGui.h +++ b/src/ui/widget/step/StepErrorGui.h @@ -1,7 +1,7 @@ /*! * \brief GUI for step "Error". * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepGui.cpp b/src/ui/widget/step/StepGui.cpp index f539dac92..1fc0686f4 100644 --- a/src/ui/widget/step/StepGui.cpp +++ b/src/ui/widget/step/StepGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepGui.h" diff --git a/src/ui/widget/step/StepGui.h b/src/ui/widget/step/StepGui.h index a7a85d49b..bf4da7d38 100644 --- a/src/ui/widget/step/StepGui.h +++ b/src/ui/widget/step/StepGui.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepProcessingGui.cpp b/src/ui/widget/step/StepProcessingGui.cpp index 94b28a8e4..3e13b27a4 100644 --- a/src/ui/widget/step/StepProcessingGui.cpp +++ b/src/ui/widget/step/StepProcessingGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepProcessingGui.h" diff --git a/src/ui/widget/step/StepProcessingGui.h b/src/ui/widget/step/StepProcessingGui.h index e32218d73..6940e4c4b 100644 --- a/src/ui/widget/step/StepProcessingGui.h +++ b/src/ui/widget/step/StepProcessingGui.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/step/StepShowSelfAuthenticationDataGui.cpp b/src/ui/widget/step/StepShowSelfAuthenticationDataGui.cpp index 202ec9b60..8ddfb624d 100644 --- a/src/ui/widget/step/StepShowSelfAuthenticationDataGui.cpp +++ b/src/ui/widget/step/StepShowSelfAuthenticationDataGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "StepShowSelfAuthenticationDataGui.h" diff --git a/src/ui/widget/step/StepShowSelfAuthenticationDataGui.h b/src/ui/widget/step/StepShowSelfAuthenticationDataGui.h index 831b708f2..6305f393e 100644 --- a/src/ui/widget/step/StepShowSelfAuthenticationDataGui.h +++ b/src/ui/widget/step/StepShowSelfAuthenticationDataGui.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/workflow/GenericWorkflowGui.h b/src/ui/widget/workflow/GenericWorkflowGui.h index da05d22bd..8225bfbdf 100644 --- a/src/ui/widget/workflow/GenericWorkflowGui.h +++ b/src/ui/widget/workflow/GenericWorkflowGui.h @@ -1,7 +1,7 @@ /*! * \brief Generic base class for Qt based WorkflowUi implementations. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/workflow/WorkflowAuthenticateQtGui.cpp b/src/ui/widget/workflow/WorkflowAuthenticateQtGui.cpp index 008cd3923..d858a1e11 100644 --- a/src/ui/widget/workflow/WorkflowAuthenticateQtGui.cpp +++ b/src/ui/widget/workflow/WorkflowAuthenticateQtGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "WorkflowAuthenticateQtGui.h" @@ -73,7 +73,7 @@ bool WorkflowAuthenticateQtGui::verifyAbortWorkflow() msgBox.setWindowTitle(QCoreApplication::applicationName() + QStringLiteral(" - ") + tr("Cancel")); msgBox.setWindowModality(Qt::WindowModal); msgBox.setText(tr("Do you really want to cancel?")); - msgBox.setInformativeText(tr("You can as well identity later by calling the service provider's Internet page" + msgBox.setInformativeText(tr("You can as well identity later by calling the provider's Internet page" " again.")); msgBox.setIconPixmap(QIcon(QStringLiteral(":/images/npa.svg")).pixmap(32, 32)); msgBox.setWindowFlags(msgBox.windowFlags() & ~Qt::WindowContextHelpButtonHint); diff --git a/src/ui/widget/workflow/WorkflowAuthenticateQtGui.h b/src/ui/widget/workflow/WorkflowAuthenticateQtGui.h index 98b5f51e6..39e44a04f 100644 --- a/src/ui/widget/workflow/WorkflowAuthenticateQtGui.h +++ b/src/ui/widget/workflow/WorkflowAuthenticateQtGui.h @@ -1,7 +1,7 @@ /*! * \brief Qt widget based WorkflowAuthenticateUi implementation. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/workflow/WorkflowChangePinQtGui.cpp b/src/ui/widget/workflow/WorkflowChangePinQtGui.cpp index b73106b33..cad548d5c 100644 --- a/src/ui/widget/workflow/WorkflowChangePinQtGui.cpp +++ b/src/ui/widget/workflow/WorkflowChangePinQtGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "WorkflowChangePinQtGui.h" diff --git a/src/ui/widget/workflow/WorkflowChangePinQtGui.h b/src/ui/widget/workflow/WorkflowChangePinQtGui.h index 6d99b9e54..8718c9f91 100644 --- a/src/ui/widget/workflow/WorkflowChangePinQtGui.h +++ b/src/ui/widget/workflow/WorkflowChangePinQtGui.h @@ -1,7 +1,7 @@ /*! * \brief Qt widget based WorkflowChangePinUi implementation. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/workflow/WorkflowGui.cpp b/src/ui/widget/workflow/WorkflowGui.cpp index 6e35813ad..f5b8a9bdd 100644 --- a/src/ui/widget/workflow/WorkflowGui.cpp +++ b/src/ui/widget/workflow/WorkflowGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "WorkflowGui.h" diff --git a/src/ui/widget/workflow/WorkflowGui.h b/src/ui/widget/workflow/WorkflowGui.h index 7df9c81a7..477333604 100644 --- a/src/ui/widget/workflow/WorkflowGui.h +++ b/src/ui/widget/workflow/WorkflowGui.h @@ -1,7 +1,7 @@ /*! * \brief Base class for Qt based WorkflowUi implementations. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/workflow/WorkflowQtWidget.cpp b/src/ui/widget/workflow/WorkflowQtWidget.cpp index 64c3df8a9..26cfb8774 100644 --- a/src/ui/widget/workflow/WorkflowQtWidget.cpp +++ b/src/ui/widget/workflow/WorkflowQtWidget.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "WorkflowQtWidget.h" diff --git a/src/ui/widget/workflow/WorkflowQtWidget.h b/src/ui/widget/workflow/WorkflowQtWidget.h index ad379dde4..cc0e19534 100644 --- a/src/ui/widget/workflow/WorkflowQtWidget.h +++ b/src/ui/widget/workflow/WorkflowQtWidget.h @@ -1,7 +1,7 @@ /*! * \brief Base class for workflow Qt GUI widgets. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/workflow/WorkflowSelfInfoQtGui.cpp b/src/ui/widget/workflow/WorkflowSelfInfoQtGui.cpp index 0991e0449..dd3bb1001 100644 --- a/src/ui/widget/workflow/WorkflowSelfInfoQtGui.cpp +++ b/src/ui/widget/workflow/WorkflowSelfInfoQtGui.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "WorkflowSelfInfoQtGui.h" diff --git a/src/ui/widget/workflow/WorkflowSelfInfoQtGui.h b/src/ui/widget/workflow/WorkflowSelfInfoQtGui.h index 87f939364..f20d29d67 100644 --- a/src/ui/widget/workflow/WorkflowSelfInfoQtGui.h +++ b/src/ui/widget/workflow/WorkflowSelfInfoQtGui.h @@ -1,7 +1,7 @@ /*! * \brief Qt widget based WorkflowSelfInfoUi implementation. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/ui/widget/workflow/WorkflowWidgetParent.h b/src/ui/widget/workflow/WorkflowWidgetParent.h index 0396b6214..74a866806 100644 --- a/src/ui/widget/workflow/WorkflowWidgetParent.h +++ b/src/ui/widget/workflow/WorkflowWidgetParent.h @@ -2,7 +2,7 @@ * \brief Enum identifying the containers in the application GUI which can be * parent to a workflow widget. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/whitelist_client/SurveyModel.cpp b/src/whitelist_client/SurveyModel.cpp index fd5264a14..e9dc44ec7 100644 --- a/src/whitelist_client/SurveyModel.cpp +++ b/src/whitelist_client/SurveyModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "SurveyModel.h" diff --git a/src/whitelist_client/SurveyModel.h b/src/whitelist_client/SurveyModel.h index a9989507d..2e719f113 100644 --- a/src/whitelist_client/SurveyModel.h +++ b/src/whitelist_client/SurveyModel.h @@ -2,7 +2,7 @@ * \brief Class holding information about an Android device to be sent to * the whitelist server. * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/src/windows.rc b/src/windows.rc index a303371d4..69a06e87a 100644 --- a/src/windows.rc +++ b/src/windows.rc @@ -1,9 +1,8 @@ // http://msdn.microsoft.com/en-us/library/aa381058(VS.85).aspx #include -#include "config.h" +#include "init/config.h" #define EXECUTABLE PRODUCT ".exe" -#define COPYRIGHT "2014-2017 " VENDOR IDR_MAINFRAME ICON "..\\resources\\images\\npa.ico" IDI_ICON1 ICON DISCARDABLE "..\\resources\\images\\npa.ico" @@ -24,7 +23,7 @@ BEGIN VALUE "FileDescription", PRODUCT VALUE "FileVersion", VERSION VALUE "InternalName", PRODUCT - VALUE "LegalCopyright", COPYRIGHT + VALUE "LegalCopyright", COPYRIGHT_TEXT VALUE "OriginalFilename", EXECUTABLE VALUE "ProductName", PRODUCT VALUE "ProductVersion", VERSION @@ -36,7 +35,7 @@ BEGIN VALUE "FileDescription", PRODUCT VALUE "FileVersion", VERSION VALUE "InternalName", PRODUCT - VALUE "LegalCopyright", COPYRIGHT + VALUE "LegalCopyright", COPYRIGHT_TEXT VALUE "OriginalFilename", EXECUTABLE VALUE "ProductName", PRODUCT VALUE "ProductVersion", VERSION diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index f721b251f..8c5a3d1c0 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -71,9 +71,10 @@ FUNCTION(ADD_QML_TEST_FILES) ENDFOREACH() ENDFUNCTION() - -ADD_SUBDIRECTORY(helper) -IF(TARGET Qt5::Qml) - ADD_SUBDIRECTORY(qml) +IF(TARGET Qt5::Test) + ADD_SUBDIRECTORY(helper) + IF(TARGET Qt5::Qml AND TARGET Qt5::QuickTest) + ADD_SUBDIRECTORY(qml) + ENDIF() + ADD_SUBDIRECTORY(qt) ENDIF() -ADD_SUBDIRECTORY(qt) diff --git a/test/fixture/fixture.qrc b/test/fixture/fixture.qrc index 25f2a9b2b..51d47f458 100644 --- a/test/fixture/fixture.qrc +++ b/test/fixture/fixture.qrc @@ -86,9 +86,6 @@ paos/DIDAuthenticateResponse2.xml logfiles/empty.txt logfiles/size1.txt - logfiles/size78.txt - logfiles/size80.txt - logfiles/size82.txt - logfiles/size160.txt + logfiles/size42.txt
diff --git a/test/fixture/logfiles/size160.txt b/test/fixture/logfiles/size160.txt deleted file mode 100644 index 3ea13def9..000000000 --- a/test/fixture/logfiles/size160.txt +++ /dev/null @@ -1,80 +0,0 @@ -1 input : 1 test -2 input : 2 test -3 input : 3 test -4 input : 4 test -5 input : 5 test -6 input : 6 test -7 input : 7 test -8 input : 8 test -9 input : 9 test -10 input : 10test -11 input : 11 test -12 input : 12 test -13 input : 13 test -14 input : 14 test -15 input : 15 test -16 input : 16 test -17 input : 17 test -18 input : 18 test -19 input : 19 test -20 input : 20 test -21 input : 21 test -22 input : 22 test -23 input : 23 test -24 input : 24 test -25 input : 25 test -26 input : 26 test -27 input : 27 test -28 input : 28 test -29 input : 29 test -30 input : 30 test -31 input : 31 test -32 input : 32 test -33 input : 33 test -34 input : 34 test -35 input : 35 test -36 input : 36 test -37 input : 37 test -38 input : 38 test -39 input : 39 test -40 input : 40 test -41 input : 41 test -42 input : 42 test -43 input : 43 test -44 input : 44 test -45 input : 45 test -46 input : 46 test -47 input : 47 test -48 input : 48 test -49 input : 49 test -50 input : 50 test -51 input : 51 test -52 input : 52 test -53 input : 53 test -54 input : 54 test -55 input : 55 test -56 input : 56 test -57 input : 57 test -58 input : 58 test -59 input : 59 test -60 input : 60 test -61 input : 61 test -62 input : 62 test -63 input : 63 test -64 input : 64 test -65 input : 65 test -66 input : 66 test -67 input : 67 test -68 input : 68 test -69 input : 69 test -70 input : 70 test -71 input : 71 test -72 input : 72 test -73 input : 73 test -74 input : 74 test -75 input : 75 test -76 input : 76 test -77 input : 77 test -78 input : 78 test -79 input : 79 test -80 input : 80 test diff --git a/test/fixture/logfiles/size82.txt b/test/fixture/logfiles/size42.txt similarity index 97% rename from test/fixture/logfiles/size82.txt rename to test/fixture/logfiles/size42.txt index e62f7c9a3..c8be0b7c2 100644 --- a/test/fixture/logfiles/size82.txt +++ b/test/fixture/logfiles/size42.txt @@ -39,3 +39,4 @@ 39 input : 39 test 40 input : 40 test 41 input : 41 test +42 input : 42 test diff --git a/test/fixture/logfiles/size78.txt b/test/fixture/logfiles/size78.txt deleted file mode 100644 index 845a016a8..000000000 --- a/test/fixture/logfiles/size78.txt +++ /dev/null @@ -1,39 +0,0 @@ -1 input : 1 test -2 input : 2 test -3 input : 3 test -4 input : 4 test -5 input : 5 test -6 input : 6 test -7 input : 7 test -8 input : 8 test -9 input : 9 test -10 input : 10test -11 input : 11 test -12 input : 12 test -13 input : 13 test -14 input : 14 test -15 input : 15 test -16 input : 16 test -17 input : 17 test -18 input : 18 test -19 input : 19 test -20 input : 20 test -21 input : 21 test -22 input : 22 test -23 input : 23 test -24 input : 24 test -25 input : 25 test -26 input : 26 test -27 input : 27 test -28 input : 28 test -29 input : 29 test -30 input : 30 test -31 input : 31 test -32 input : 32 test -33 input : 33 test -34 input : 34 test -35 input : 35 test -36 input : 36 test -37 input : 37 test -38 input : 38 test -39 input : 39 test diff --git a/test/fixture/logfiles/size80.txt b/test/fixture/logfiles/size80.txt deleted file mode 100644 index dacf7e033..000000000 --- a/test/fixture/logfiles/size80.txt +++ /dev/null @@ -1,40 +0,0 @@ -1 input : 1 test -2 input : 2 test -3 input : 3 test -4 input : 4 test -5 input : 5 test -6 input : 6 test -7 input : 7 test -8 input : 8 test -9 input : 9 test -10 input : 10test -11 input : 11 test -12 input : 12 test -13 input : 13 test -14 input : 14 test -15 input : 15 test -16 input : 16 test -17 input : 17 test -18 input : 18 test -19 input : 19 test -20 input : 20 test -21 input : 21 test -22 input : 22 test -23 input : 23 test -24 input : 24 test -25 input : 25 test -26 input : 26 test -27 input : 27 test -28 input : 28 test -29 input : 29 test -30 input : 30 test -31 input : 31 test -32 input : 32 test -33 input : 33 test -34 input : 34 test -35 input : 35 test -36 input : 36 test -37 input : 37 test -38 input : 38 test -39 input : 39 test -40 input : 40 test diff --git a/test/helper/MockActivationContext.cpp b/test/helper/MockActivationContext.cpp index 6489e9b68..be17e7c6f 100644 --- a/test/helper/MockActivationContext.cpp +++ b/test/helper/MockActivationContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MockActivationContext.h" diff --git a/test/helper/MockActivationContext.h b/test/helper/MockActivationContext.h index c67fc9b1e..45925bfa0 100644 --- a/test/helper/MockActivationContext.h +++ b/test/helper/MockActivationContext.h @@ -1,7 +1,7 @@ /*! * \brief Mocked ActivationContext for unit tests. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockCard.cpp b/test/helper/MockCard.cpp index fcabfa069..35df4184a 100644 --- a/test/helper/MockCard.cpp +++ b/test/helper/MockCard.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MockCard.h" @@ -32,7 +32,7 @@ CardReturnCode MockCard::disconnect() } -CardReturnCode MockCard::transmit(const CommandApdu& pCmd, ResponseApdu& pRes) +ResponseApduResult MockCard::transmit(const CommandApdu& pCmd) { Q_UNUSED(pCmd) if (mCardConfig.mTransmits.isEmpty()) @@ -40,8 +40,7 @@ CardReturnCode MockCard::transmit(const CommandApdu& pCmd, ResponseApdu& pRes) qFatal("No (more) response APDU configured, but a(nother) command transmitted"); } QPair config = mCardConfig.mTransmits.takeFirst(); - pRes.setBuffer(config.second); - return config.first; + return {config.first, ResponseApdu(config.second)}; } diff --git a/test/helper/MockCard.h b/test/helper/MockCard.h index 585bb8b6e..8065dc8e8 100644 --- a/test/helper/MockCard.h +++ b/test/helper/MockCard.h @@ -1,7 +1,7 @@ /*! * \brief Card mock for tests * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -55,7 +55,7 @@ class MockCard } - CardReturnCode transmit(const CommandApdu& pCmd, ResponseApdu& pRes) override; + ResponseApduResult transmit(const CommandApdu& pCmd) override; void setConnected(bool pConnected); }; diff --git a/test/helper/MockCardConnectionWorker.cpp b/test/helper/MockCardConnectionWorker.cpp index 870156efa..ffe222193 100644 --- a/test/helper/MockCardConnectionWorker.cpp +++ b/test/helper/MockCardConnectionWorker.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "MockCardConnectionWorker.h" @@ -39,11 +39,21 @@ void MockCardConnectionWorker::addPaceCode(CardReturnCode pCode) } -CardReturnCode MockCardConnectionWorker::transmit(const CommandApdu& pCommandApdu, ResponseApdu& pResponseApdu) +ResponseApduResult MockCardConnectionWorker::getMockedResponse() +{ + if (mResponseData.empty()) + { + return {CardReturnCode::UNDEFINED}; + } + + return {mResponseCodes.takeFirst(), ResponseApdu(mResponseData.takeFirst())}; +} + + +ResponseApduResult MockCardConnectionWorker::transmit(const CommandApdu& pCommandApdu) { Q_UNUSED(pCommandApdu) - pResponseApdu.setBuffer(mResponseData.empty() ? QByteArray() : mResponseData.takeFirst()); - return mResponseCodes.empty() ? CardReturnCode::UNDEFINED : mResponseCodes.takeFirst(); + return getMockedResponse(); } @@ -76,10 +86,9 @@ CardReturnCode MockCardConnectionWorker::destroyPaceChannel() } -CardReturnCode MockCardConnectionWorker::setEidPin(const QString& pNewPin, quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) +ResponseApduResult MockCardConnectionWorker::setEidPin(const QString& pNewPin, quint8 pTimeoutSeconds) { Q_UNUSED(pNewPin) Q_UNUSED(pTimeoutSeconds) - pResponseApdu.setBuffer(mResponseData.empty() ? QByteArray() : mResponseData.takeFirst()); - return mResponseCodes.empty() ? CardReturnCode::UNDEFINED : mResponseCodes.takeFirst(); + return getMockedResponse(); } diff --git a/test/helper/MockCardConnectionWorker.h b/test/helper/MockCardConnectionWorker.h index 9a4f5e569..0d06b2070 100644 --- a/test/helper/MockCardConnectionWorker.h +++ b/test/helper/MockCardConnectionWorker.h @@ -1,7 +1,7 @@ /*! * \brief CardConnectionWorker mock for tests * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -26,6 +26,8 @@ class MockCardConnectionWorker QByteArrayList mResponseData; QList mPaceCodes; + ResponseApduResult getMockedResponse(); + public: explicit MockCardConnectionWorker(Reader* pReader = new MockReader()); virtual ~MockCardConnectionWorker() override; @@ -33,14 +35,14 @@ class MockCardConnectionWorker void addResponse(CardReturnCode pCode, const QByteArray& pData = QByteArray()); void addPaceCode(CardReturnCode pCode); - virtual CardReturnCode transmit(const CommandApdu& pCommandApdu, ResponseApdu& pResponseApdu) override; + virtual ResponseApduResult transmit(const CommandApdu& pCommandApdu) override; virtual CardReturnCode updateRetryCounter() override; virtual EstablishPaceChannelOutput establishPaceChannel(PacePasswordId pPasswordId, const QString& pPasswordValue, const QByteArray& pChat, const QByteArray& pCertificateDescription) override; virtual CardReturnCode destroyPaceChannel() override; - virtual CardReturnCode setEidPin(const QString& pNewPin, quint8 pTimeoutSeconds, ResponseApdu& pResponseApdu) override; + virtual ResponseApduResult setEidPin(const QString& pNewPin, quint8 pTimeoutSeconds) override; }; } // namespace governikus diff --git a/test/helper/MockDataChannel.cpp b/test/helper/MockDataChannel.cpp index c644445b7..6c94a04fa 100644 --- a/test/helper/MockDataChannel.cpp +++ b/test/helper/MockDataChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "MockDataChannel.h" diff --git a/test/helper/MockDataChannel.h b/test/helper/MockDataChannel.h index f2068eced..e8dc58acd 100644 --- a/test/helper/MockDataChannel.h +++ b/test/helper/MockDataChannel.h @@ -1,7 +1,7 @@ /*! * \brief Data channel mock for tests. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockDownloader.cpp b/test/helper/MockDownloader.cpp index fea8e7bd5..37273bb1b 100644 --- a/test/helper/MockDownloader.cpp +++ b/test/helper/MockDownloader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "MockDownloader.h" diff --git a/test/helper/MockDownloader.h b/test/helper/MockDownloader.h index 165a6262f..f0166a568 100644 --- a/test/helper/MockDownloader.h +++ b/test/helper/MockDownloader.h @@ -1,7 +1,7 @@ /*! * \brief MockDownloader of class Downloader, part of \ref Updater and \ref UpdatableFile tests * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/test/helper/MockHttpServer.cpp b/test/helper/MockHttpServer.cpp index 97cf114ba..ea07dc5a1 100644 --- a/test/helper/MockHttpServer.cpp +++ b/test/helper/MockHttpServer.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MockHttpServer.h" diff --git a/test/helper/MockHttpServer.h b/test/helper/MockHttpServer.h index 7091e8664..2435d2aad 100644 --- a/test/helper/MockHttpServer.h +++ b/test/helper/MockHttpServer.h @@ -1,7 +1,7 @@ /*! * \brief Provide a HTTP-Server for tests * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockNetworkManager.cpp b/test/helper/MockNetworkManager.cpp index 8e50a88c5..edfe45545 100644 --- a/test/helper/MockNetworkManager.cpp +++ b/test/helper/MockNetworkManager.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "MockNetworkManager.h" diff --git a/test/helper/MockNetworkManager.h b/test/helper/MockNetworkManager.h index e74fc1da4..7621ad708 100644 --- a/test/helper/MockNetworkManager.h +++ b/test/helper/MockNetworkManager.h @@ -1,7 +1,7 @@ /*! * \brief Mock \ref NetworkManager for tests * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockNetworkReply.cpp b/test/helper/MockNetworkReply.cpp index beca6b5ec..482b3d255 100644 --- a/test/helper/MockNetworkReply.cpp +++ b/test/helper/MockNetworkReply.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "MockNetworkReply.h" diff --git a/test/helper/MockNetworkReply.h b/test/helper/MockNetworkReply.h index 429e8e36d..7f5c6561b 100644 --- a/test/helper/MockNetworkReply.h +++ b/test/helper/MockNetworkReply.h @@ -1,7 +1,7 @@ /*! * \brief Mock a QNetworkReply for tests. * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockReader.cpp b/test/helper/MockReader.cpp index 75a985359..6955d72e7 100644 --- a/test/helper/MockReader.cpp +++ b/test/helper/MockReader.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MockReader.h" diff --git a/test/helper/MockReader.h b/test/helper/MockReader.h index 3c1c15eb5..ed68f9f67 100644 --- a/test/helper/MockReader.h +++ b/test/helper/MockReader.h @@ -1,7 +1,7 @@ /*! * \brief Reader mock for tests * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockReaderConfiguration.cpp b/test/helper/MockReaderConfiguration.cpp index 1fc4b3287..4e07a7948 100644 --- a/test/helper/MockReaderConfiguration.cpp +++ b/test/helper/MockReaderConfiguration.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "MockReaderConfiguration.h" diff --git a/test/helper/MockReaderConfiguration.h b/test/helper/MockReaderConfiguration.h index d3db62864..212923f21 100644 --- a/test/helper/MockReaderConfiguration.h +++ b/test/helper/MockReaderConfiguration.h @@ -1,7 +1,7 @@ /*! * \brief ReaderConfigurationFile mock for tests * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockReaderDetector.cpp b/test/helper/MockReaderDetector.cpp index 5a2506ed1..9227acec0 100644 --- a/test/helper/MockReaderDetector.cpp +++ b/test/helper/MockReaderDetector.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "MockReaderDetector.h" diff --git a/test/helper/MockReaderDetector.h b/test/helper/MockReaderDetector.h index 32eb92975..a31688162 100644 --- a/test/helper/MockReaderDetector.h +++ b/test/helper/MockReaderDetector.h @@ -1,7 +1,7 @@ /*! * \brief ReaderDetector mock for tests * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockReaderManagerPlugIn.cpp b/test/helper/MockReaderManagerPlugIn.cpp index c8e3c9638..bf2aa5765 100644 --- a/test/helper/MockReaderManagerPlugIn.cpp +++ b/test/helper/MockReaderManagerPlugIn.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/test/helper/MockReaderManagerPlugIn.h b/test/helper/MockReaderManagerPlugIn.h index d99d960a7..39b1ae75a 100644 --- a/test/helper/MockReaderManagerPlugIn.h +++ b/test/helper/MockReaderManagerPlugIn.h @@ -1,7 +1,7 @@ /*! * \brief Mock implementation of ReaderManagerPlugIn * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/test/helper/MockRemoteDispatcher.cpp b/test/helper/MockRemoteDispatcher.cpp index 9d6ff45b7..1ace09a3d 100644 --- a/test/helper/MockRemoteDispatcher.cpp +++ b/test/helper/MockRemoteDispatcher.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "MockRemoteDispatcher.h" @@ -63,7 +63,7 @@ void MockRemoteDispatcher::send(const QSharedPointer& pMess if (pMessage->getType() == RemoteCardMessageType::IFDConnect) { - const QSharedPointer request = pMessage.dynamicCast(); + const QSharedPointer request = pMessage.staticCast(); const QString readerName = request->getSlotName(); const QSharedPointer message(new IfdConnectResponse(readerName, resultMinor)); Q_EMIT fireReceived(message->getType(), QJsonDocument::fromJson(message->toByteArray(mContextHandle)).object(), mId); @@ -71,7 +71,7 @@ void MockRemoteDispatcher::send(const QSharedPointer& pMess if (pMessage->getType() == RemoteCardMessageType::IFDTransmit) { - const QSharedPointer request = pMessage.dynamicCast(); + const QSharedPointer request = pMessage.staticCast(); const QString readerName = request->getSlotHandle(); const QSharedPointer message(new IfdTransmitResponse(readerName, resultMinor == ECardApiResult::Minor::null ? QByteArray("pong") : QByteArray(), resultMinor)); Q_EMIT fireReceived(message->getType(), QJsonDocument::fromJson(message->toByteArray(mContextHandle)).object(), mId); @@ -79,7 +79,7 @@ void MockRemoteDispatcher::send(const QSharedPointer& pMess if (pMessage->getType() == RemoteCardMessageType::IFDDisconnect) { - const QSharedPointer request = pMessage.dynamicCast(); + const QSharedPointer request = pMessage.staticCast(); const QString readerName = request->getSlotHandle(); const QSharedPointer message(new IfdDisconnectResponse(readerName, resultMinor)); Q_EMIT fireReceived(message->getType(), QJsonDocument::fromJson(message->toByteArray(mContextHandle)).object(), mId); diff --git a/test/helper/MockRemoteDispatcher.h b/test/helper/MockRemoteDispatcher.h index dce9313d6..177caf224 100644 --- a/test/helper/MockRemoteDispatcher.h +++ b/test/helper/MockRemoteDispatcher.h @@ -1,7 +1,7 @@ /*! * \brief Remote dispatcher mock for tests. * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockRemoteServer.cpp b/test/helper/MockRemoteServer.cpp index 93eff3c02..030fee5d9 100644 --- a/test/helper/MockRemoteServer.cpp +++ b/test/helper/MockRemoteServer.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "MockRemoteServer.h" @@ -54,6 +54,12 @@ bool MockRemoteServer::isConnected() const } +bool MockRemoteServer::isPairingConnection() const +{ + return false; +} + + void MockRemoteServer::setConnected(bool pConnected) { mConnected = pConnected; diff --git a/test/helper/MockRemoteServer.h b/test/helper/MockRemoteServer.h index a56b751f8..77bf4998f 100644 --- a/test/helper/MockRemoteServer.h +++ b/test/helper/MockRemoteServer.h @@ -1,7 +1,7 @@ /*! * \brief Provide a RemoteServer for tests * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once @@ -33,6 +33,7 @@ class MockRemoteServer virtual void setPairing(bool pEnable) override; bool getPairing(); virtual bool isConnected() const override; + virtual bool isPairingConnection() const override; void setConnected(bool pConnected); virtual QSslCertificate getCurrentCertificate() const override; virtual const QSharedPointer& getMessageHandler() const override; diff --git a/test/helper/MockSocket.cpp b/test/helper/MockSocket.cpp index 6e6d60721..9f1565c80 100644 --- a/test/helper/MockSocket.cpp +++ b/test/helper/MockSocket.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MockSocket.h" diff --git a/test/helper/MockSocket.h b/test/helper/MockSocket.h index e83665ae5..c7ea9ab63 100644 --- a/test/helper/MockSocket.h +++ b/test/helper/MockSocket.h @@ -1,7 +1,7 @@ /*! * \brief Mock a QAbstractSocket for tests. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockWorkflowAuthenticateUi.h b/test/helper/MockWorkflowAuthenticateUi.h index c43d7fdc3..c1b494175 100644 --- a/test/helper/MockWorkflowAuthenticateUi.h +++ b/test/helper/MockWorkflowAuthenticateUi.h @@ -1,7 +1,7 @@ /*! * \brief Mock implementation of WorkflowAuthenticateUi. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MockWorkflowChangePinUi.h b/test/helper/MockWorkflowChangePinUi.h index 93458065f..aa5315949 100644 --- a/test/helper/MockWorkflowChangePinUi.h +++ b/test/helper/MockWorkflowChangePinUi.h @@ -1,7 +1,7 @@ /*! * \brief Mock implementation of WorkflowAuthenticateUi. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/MsgHandlerEnterPassword.cpp b/test/helper/MsgHandlerEnterPassword.cpp index 23f62ad4a..7f619dd04 100644 --- a/test/helper/MsgHandlerEnterPassword.cpp +++ b/test/helper/MsgHandlerEnterPassword.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "MsgHandlerEnterPassword.h" diff --git a/test/helper/MsgHandlerEnterPassword.h b/test/helper/MsgHandlerEnterPassword.h index 4ef861d36..d0ca89b7b 100644 --- a/test/helper/MsgHandlerEnterPassword.h +++ b/test/helper/MsgHandlerEnterPassword.h @@ -1,7 +1,7 @@ /*! * \brief Helper static methods for \ref test_MsgHandlerEnterPin, \ref test_MsgHandlerEnterCan and \ref test_MsgHandlerEnterPuk * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/PersoSimController.cpp b/test/helper/PersoSimController.cpp index 6e3b83062..5090328aa 100644 --- a/test/helper/PersoSimController.cpp +++ b/test/helper/PersoSimController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PersoSimController.h" diff --git a/test/helper/PersoSimController.h b/test/helper/PersoSimController.h index 324af6df6..c6dd4fe07 100644 --- a/test/helper/PersoSimController.h +++ b/test/helper/PersoSimController.h @@ -1,7 +1,7 @@ /*! * \brief Controller for an external PersoSim process. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/TestAuthContext.cpp b/test/helper/TestAuthContext.cpp index 0b26ebbe7..2a8448a5e 100644 --- a/test/helper/TestAuthContext.cpp +++ b/test/helper/TestAuthContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "TestAuthContext.h" @@ -22,7 +22,7 @@ TestAuthContext::TestAuthContext(ActivationContext* pActivationContext, const QS setTerminalCvc(mDidAuthenticateEac1->getCvCertificates().at(0)); setDvCvc(mDidAuthenticateEac1->getCvCertificates().at(1)); - mDidAuthenticateEac2.reset(dynamic_cast(DidAuthenticateEac2Parser().parse(TestFileHelper::readFile(":/paos/DIDAuthenticateEAC2.xml")))); + mDidAuthenticateEac2.reset(static_cast(DidAuthenticateEac2Parser().parse(TestFileHelper::readFile(":/paos/DIDAuthenticateEAC2.xml")))); setDidAuthenticateEac2(mDidAuthenticateEac2); } diff --git a/test/helper/TestAuthContext.h b/test/helper/TestAuthContext.h index 2a68100e3..a0d214b66 100644 --- a/test/helper/TestAuthContext.h +++ b/test/helper/TestAuthContext.h @@ -1,7 +1,7 @@ /*! * \brief Helper to use AuthContext in an easy way. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/TestFileHelper.cpp b/test/helper/TestFileHelper.cpp index d1b5bea75..bea6d8e24 100644 --- a/test/helper/TestFileHelper.cpp +++ b/test/helper/TestFileHelper.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "TestFileHelper.h" diff --git a/test/helper/TestFileHelper.h b/test/helper/TestFileHelper.h index bff805b78..ba6e76e73 100644 --- a/test/helper/TestFileHelper.h +++ b/test/helper/TestFileHelper.h @@ -1,7 +1,7 @@ /*! * \brief Helper for some file functions. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/helper/WebSocketHelper.cpp b/test/helper/WebSocketHelper.cpp index 4c14a879f..27892e418 100644 --- a/test/helper/WebSocketHelper.cpp +++ b/test/helper/WebSocketHelper.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "WebSocketHelper.h" @@ -48,8 +48,8 @@ WebSocketHelper::WebSocketHelper(int pPort, int pConnectionTimeout) connectWebsocket(pPort); } while (mWebSocket.state() != QAbstractSocket::SocketState::ConnectedState - && mWebSocket.error() == QAbstractSocket::SocketError::ConnectionRefusedError - && QDateTime::currentMSecsSinceEpoch() - start < mConnectionTiemout); + && mWebSocket.error() == QAbstractSocket::SocketError::ConnectionRefusedError + && QDateTime::currentMSecsSinceEpoch() - start < mConnectionTiemout); } diff --git a/test/helper/WebSocketHelper.h b/test/helper/WebSocketHelper.h index 71f9b6221..f71674502 100644 --- a/test/helper/WebSocketHelper.h +++ b/test/helper/WebSocketHelper.h @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #pragma once diff --git a/test/qml/QmlTestRunner.cpp b/test/qml/QmlTestRunner.cpp index 17a6d6122..934992d2d 100644 --- a/test/qml/QmlTestRunner.cpp +++ b/test/qml/QmlTestRunner.cpp @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "LogHandler.h" diff --git a/test/qml/desktop/test_Global.qml b/test/qml/desktop/test_Global.qml index 448a4577c..3870a3139 100644 --- a/test/qml/desktop/test_Global.qml +++ b/test/qml/desktop/test_Global.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 @@ -8,11 +8,19 @@ TestCase { name: "ModuleImportTest" id: parent + function test_load_BinaryDecisionView() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + BinaryDecisionView {} + ", parent); + item.destroy(); + } + function test_load_NavigationButton() { var item = createTemporaryQmlObject(" import Governikus.Global 1.0; NavigationButton { - buttonType: Qt.ForwardButton + buttonType: NavigationButton.Type.Forward } ", parent); item.destroy(); diff --git a/test/qml/desktop/test_MainView.qml b/test/qml/desktop/test_MainView.qml index 07ce0f1bd..beceae461 100644 --- a/test/qml/desktop/test_MainView.qml +++ b/test/qml/desktop/test_MainView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/desktop/test_SettingsView.qml b/test/qml/desktop/test_SettingsView.qml index f079ec6a5..aa1da507e 100644 --- a/test/qml/desktop/test_SettingsView.qml +++ b/test/qml/desktop/test_SettingsView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/desktop/test_TitleBar.qml b/test/qml/desktop/test_TitleBar.qml index adecf39b7..2c882a8ba 100644 --- a/test/qml/desktop/test_TitleBar.qml +++ b/test/qml/desktop/test_TitleBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/desktop/test_TutorialView.qml b/test/qml/desktop/test_TutorialView.qml index 2f027dacd..cb99cd281 100644 --- a/test/qml/desktop/test_TutorialView.qml +++ b/test/qml/desktop/test_TutorialView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/desktop/test_View.qml b/test/qml/desktop/test_View.qml index 3c14ee8b9..41b84d016 100644 --- a/test/qml/desktop/test_View.qml +++ b/test/qml/desktop/test_View.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_ChangePinView.qml b/test/qml/generic/test_ChangePinView.qml index 884967e87..287f048e0 100644 --- a/test/qml/generic/test_ChangePinView.qml +++ b/test/qml/generic/test_ChangePinView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_EnterPasswordView.qml b/test/qml/generic/test_EnterPasswordView.qml index bc58bee88..c2797c79d 100644 --- a/test/qml/generic/test_EnterPasswordView.qml +++ b/test/qml/generic/test_EnterPasswordView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_FeedbackView.qml b/test/qml/generic/test_FeedbackView.qml index 12c56c024..bb77c65c1 100644 --- a/test/qml/generic/test_FeedbackView.qml +++ b/test/qml/generic/test_FeedbackView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_Global.qml b/test/qml/generic/test_Global.qml index 3e1db912f..cec91180a 100644 --- a/test/qml/generic/test_Global.qml +++ b/test/qml/generic/test_Global.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 @@ -57,14 +57,6 @@ TestCase { item.destroy(); } - function test_load_PaneTitle() { - var item = createTemporaryQmlObject(" - import Governikus.Global 1.0; - PaneTitle {} - ", parent); - item.destroy(); - } - function test_load_Pane() { var item = createTemporaryQmlObject(" import Governikus.Global 1.0; @@ -124,4 +116,68 @@ TestCase { ", parent); item.destroy(); } + + function test_load_GFlickable() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + GFlickable {} + ", parent); + item.destroy(); + } + + function test_load_GListView() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + GListView {} + ", parent); + item.destroy(); + } + + function test_load_GGridView() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + GGridView {} + ", parent); + item.destroy(); + } + + function test_load_GScrollBar() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + GScrollBar {} + ", parent); + item.destroy(); + } + + function test_load_GRadioButton() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + GRadioButton {} + ", parent); + item.destroy(); + } + + function test_load_LocationButton() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + LocationButton {} + ", parent); + item.destroy(); + } + + function test_load_TintableIcon() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + TintableIcon {} + ", parent); + item.destroy(); + } + + function test_load_NumberField() { + var item = createTemporaryQmlObject(" + import Governikus.Global 1.0; + NumberField {} + ", parent); + item.destroy(); + } } diff --git a/test/qml/generic/test_HistoryView.qml b/test/qml/generic/test_HistoryView.qml index bcc77c114..06d74f9fe 100644 --- a/test/qml/generic/test_HistoryView.qml +++ b/test/qml/generic/test_HistoryView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_IdentifyView.qml b/test/qml/generic/test_IdentifyView.qml index e9e5b12c1..57392e39e 100644 --- a/test/qml/generic/test_IdentifyView.qml +++ b/test/qml/generic/test_IdentifyView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_InformationView.qml b/test/qml/generic/test_InformationView.qml deleted file mode 100644 index 031e42831..000000000 --- a/test/qml/generic/test_InformationView.qml +++ /dev/null @@ -1,18 +0,0 @@ -/* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany - */ - -import QtTest 1.10 - -TestCase { - name: "ModuleImportTest" - id: parent - - function test_load_InformationView() { - var item = createTemporaryQmlObject(" - import Governikus.InformationView 1.0; - InformationView {} - ", parent); - item.destroy(); - } -} diff --git a/test/qml/mobile/test_MoreView.qml b/test/qml/generic/test_MoreView.qml similarity index 79% rename from test/qml/mobile/test_MoreView.qml rename to test/qml/generic/test_MoreView.qml index b35c63647..97afacc2f 100644 --- a/test/qml/mobile/test_MoreView.qml +++ b/test/qml/generic/test_MoreView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_ProgressView.qml b/test/qml/generic/test_ProgressView.qml index cc50e1db8..72e3a56da 100644 --- a/test/qml/generic/test_ProgressView.qml +++ b/test/qml/generic/test_ProgressView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_Provider.qml b/test/qml/generic/test_Provider.qml index c2423a1d1..7a0ddd790 100644 --- a/test/qml/generic/test_Provider.qml +++ b/test/qml/generic/test_Provider.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_ProviderView.qml b/test/qml/generic/test_ProviderView.qml index f9f36f661..709336e2f 100644 --- a/test/qml/generic/test_ProviderView.qml +++ b/test/qml/generic/test_ProviderView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_ResultView.qml b/test/qml/generic/test_ResultView.qml index 50bbc3f5d..51522ece4 100644 --- a/test/qml/generic/test_ResultView.qml +++ b/test/qml/generic/test_ResultView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_SelfAuthenticationView.qml b/test/qml/generic/test_SelfAuthenticationView.qml index 9ba3ca9a9..daeef479b 100644 --- a/test/qml/generic/test_SelfAuthenticationView.qml +++ b/test/qml/generic/test_SelfAuthenticationView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_Style.qml b/test/qml/generic/test_Style.qml index 947f09515..6d9b65dbe 100644 --- a/test/qml/generic/test_Style.qml +++ b/test/qml/generic/test_Style.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_TitleBar.qml b/test/qml/generic/test_TitleBar.qml index 7f6afb497..4b37e830e 100644 --- a/test/qml/generic/test_TitleBar.qml +++ b/test/qml/generic/test_TitleBar.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_UiPluginQml.qml b/test/qml/generic/test_UiPluginQml.qml index 4b6797952..6ee955d40 100644 --- a/test/qml/generic/test_UiPluginQml.qml +++ b/test/qml/generic/test_UiPluginQml.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_Utils.qml b/test/qml/generic/test_Utils.qml index d7ebc7e45..25b4f80e2 100644 --- a/test/qml/generic/test_Utils.qml +++ b/test/qml/generic/test_Utils.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_View.qml b/test/qml/generic/test_View.qml index e016fa212..fb6405392 100644 --- a/test/qml/generic/test_View.qml +++ b/test/qml/generic/test_View.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/generic/test_Workflow.qml b/test/qml/generic/test_Workflow.qml index 713fa2424..1ae357d92 100644 --- a/test/qml/generic/test_Workflow.qml +++ b/test/qml/generic/test_Workflow.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_DeveloperView.qml b/test/qml/mobile/test_DeveloperView.qml index 61459ba37..94add2b1a 100644 --- a/test/qml/mobile/test_DeveloperView.qml +++ b/test/qml/mobile/test_DeveloperView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_FeedbackView.qml b/test/qml/mobile/test_FeedbackView.qml index 366ae1899..115c8c9f5 100644 --- a/test/qml/mobile/test_FeedbackView.qml +++ b/test/qml/mobile/test_FeedbackView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 @@ -8,14 +8,6 @@ TestCase { name: "ModuleImportTest" id: parent - function test_load_FeedbackView() { - var item = createTemporaryQmlObject(" - import Governikus.FeedbackView 1.0; - Feedback {} - ", parent); - item.destroy(); - } - function test_load_StoreFeedbackPopup() { var item = createTemporaryQmlObject(" import Governikus.FeedbackView 1.0; diff --git a/test/qml/mobile/test_Global.qml b/test/qml/mobile/test_Global.qml index 4be7e7f61..559f2fb6d 100644 --- a/test/qml/mobile/test_Global.qml +++ b/test/qml/mobile/test_Global.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 @@ -8,14 +8,6 @@ TestCase { name: "ModuleImportTest" id: parent - function test_load_GRadioButton() { - var item = createTemporaryQmlObject(" - import Governikus.Global 1.0; - GRadioButton {} - ", parent); - item.destroy(); - } - function test_load_GSwitch() { var item = createTemporaryQmlObject(" import Governikus.Global 1.0; @@ -24,14 +16,6 @@ TestCase { item.destroy(); } - function test_load_LocationButton() { - var item = createTemporaryQmlObject(" - import Governikus.Global 1.0; - LocationButton {} - ", parent); - item.destroy(); - } - function test_load_ListItem() { var item = createTemporaryQmlObject(" import Governikus.Global 1.0; @@ -39,36 +23,4 @@ TestCase { ", parent); item.destroy(); } - - function test_load_GFlickable() { - var item = createTemporaryQmlObject(" - import Governikus.Global 1.0; - GFlickable {} - ", parent); - item.destroy(); - } - - function test_load_GListView() { - var item = createTemporaryQmlObject(" - import Governikus.Global 1.0; - GListView {} - ", parent); - item.destroy(); - } - - function test_load_GGridView() { - var item = createTemporaryQmlObject(" - import Governikus.Global 1.0; - GGridView {} - ", parent); - item.destroy(); - } - - function test_load_GScrollBar() { - var item = createTemporaryQmlObject(" - import Governikus.Global 1.0; - GScrollBar {} - ", parent); - item.destroy(); - } } diff --git a/test/qml/mobile/test_InformationView.qml b/test/qml/mobile/test_InformationView.qml deleted file mode 100644 index 7b63ce4d5..000000000 --- a/test/qml/mobile/test_InformationView.qml +++ /dev/null @@ -1,18 +0,0 @@ -/* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany - */ - -import QtTest 1.10 - -TestCase { - name: "ModuleLoadingInformationView" - id: parent - - function test_load_VersionInformationView() { - var item = createTemporaryQmlObject(" - import Governikus.InformationView 1.0; - VersionInformation {} - ", parent); - item.destroy(); - } -} diff --git a/test/qml/mobile/test_Navigation.qml b/test/qml/mobile/test_Navigation.qml index 6af6de88a..5a25b1847 100644 --- a/test/qml/mobile/test_Navigation.qml +++ b/test/qml/mobile/test_Navigation.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_Provider.qml b/test/qml/mobile/test_Provider.qml index 7386aafb8..91465ab50 100644 --- a/test/qml/mobile/test_Provider.qml +++ b/test/qml/mobile/test_Provider.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_RemoteServiceView.qml b/test/qml/mobile/test_RemoteServiceView.qml index 81b06fa93..36e6e7ed3 100644 --- a/test/qml/mobile/test_RemoteServiceView.qml +++ b/test/qml/mobile/test_RemoteServiceView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_SplashScreen.qml b/test/qml/mobile/test_SplashScreen.qml index ed8955256..4ebb21004 100644 --- a/test/qml/mobile/test_SplashScreen.qml +++ b/test/qml/mobile/test_SplashScreen.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_TechnologyInfo.qml b/test/qml/mobile/test_TechnologyInfo.qml index 021f5c133..b54f973db 100644 --- a/test/qml/mobile/test_TechnologyInfo.qml +++ b/test/qml/mobile/test_TechnologyInfo.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_TutorialView.qml b/test/qml/mobile/test_TutorialView.qml index 7fa7c3f24..3b4d06154 100644 --- a/test/qml/mobile/test_TutorialView.qml +++ b/test/qml/mobile/test_TutorialView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_View.qml b/test/qml/mobile/test_View.qml index 954e088ef..6df4d834f 100644 --- a/test/qml/mobile/test_View.qml +++ b/test/qml/mobile/test_View.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qml/mobile/test_WhiteListClientView.qml b/test/qml/mobile/test_WhiteListClientView.qml index effe55ea2..c20a1e1ea 100644 --- a/test/qml/mobile/test_WhiteListClientView.qml +++ b/test/qml/mobile/test_WhiteListClientView.qml @@ -1,5 +1,5 @@ /* - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ import QtTest 1.10 diff --git a/test/qt/CMakeLists.txt b/test/qt/CMakeLists.txt index 11ff329e3..fdf6b8517 100644 --- a/test/qt/CMakeLists.txt +++ b/test/qt/CMakeLists.txt @@ -70,12 +70,13 @@ FUNCTION(SHOULD_SKIP_TEST _out filename) SET(${_out} FALSE PARENT_SCOPE) STRING(REPLACE "${CMAKE_CURRENT_SOURCE_DIR}/" "" test "${sourcefile}") - IF(IOS OR ANDROID) - IF(ANDROID_BUILD_AAR AND test MATCHES "ui/qml") - SET(${_out} TRUE PARENT_SCOPE) - RETURN() - ENDIF() + IF(INTEGRATED_SDK AND (test MATCHES "ui/qml" + OR test MATCHES "ui/widget")) + SET(${_out} TRUE PARENT_SCOPE) + RETURN() + ENDIF() + IF(IOS OR ANDROID) IF(test MATCHES "ui/widget" OR test MATCHES "card/pcsc") SET(${_out} TRUE PARENT_SCOPE) diff --git a/test/qt/activation/webservice/test_Template.cpp b/test/qt/activation/webservice/test_Template.cpp index f850c7dd6..a931746e9 100644 --- a/test/qt/activation/webservice/test_Template.cpp +++ b/test/qt/activation/webservice/test_Template.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Template * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "Template.h" diff --git a/test/qt/activation/webservice/test_WebserviceActivationContext.cpp b/test/qt/activation/webservice/test_WebserviceActivationContext.cpp index 8698ba7cc..adbfba82e 100644 --- a/test/qt/activation/webservice/test_WebserviceActivationContext.cpp +++ b/test/qt/activation/webservice/test_WebserviceActivationContext.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref WebserviceActivationContext * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "WebserviceActivationContext.h" diff --git a/test/qt/activation/webservice/test_WebserviceActivationHandler.cpp b/test/qt/activation/webservice/test_WebserviceActivationHandler.cpp index dd136a3a3..90a1d1f61 100644 --- a/test/qt/activation/webservice/test_WebserviceActivationHandler.cpp +++ b/test/qt/activation/webservice/test_WebserviceActivationHandler.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref WebserviceActivationHandler * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "WebserviceActivationHandler.h" diff --git a/test/qt/card/asn1/test_AccessRoleAndRight.cpp b/test/qt/card/asn1/test_AccessRoleAndRight.cpp index 05f871fd3..7c7e87a5a 100644 --- a/test/qt/card/asn1/test_AccessRoleAndRight.cpp +++ b/test/qt/card/asn1/test_AccessRoleAndRight.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref AccessRoleAndRight * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/AccessRoleAndRight.h" @@ -37,6 +37,10 @@ class test_AccessRoleAndRight QTest::newRow("Pseudonym") << AccessRight::RESTRICTED_IDENTIFICATION; QTest::newRow("AddressVerification") << AccessRight::COMMUNITY_ID_VERIFICATION; QTest::newRow("AgeVerification") << AccessRight::AGE_VERIFICATION; + QTest::newRow("WriteAddress") << AccessRight::WRITE_DG17; + QTest::newRow("WriteCommunityID") << AccessRight::WRITE_DG18; + QTest::newRow("WriteResidencePermitI") << AccessRight::WRITE_DG19; + QTest::newRow("WriteResidencePermitII") << AccessRight::WRITE_DG20; } @@ -44,7 +48,7 @@ class test_AccessRoleAndRight void checkAccessRightNames_data() { fillTestData(); - QTest::newRow("") << AccessRight::WRITE_DG17; + QTest::newRow("") << AccessRight::WRITE_DG21; QTest::newRow("") << AccessRight::RFU_32; QTest::newRow("") << AccessRight::CAN_ALLOWED; QTest::newRow("") << AccessRight::PRIVILEGED_TERMINAL; @@ -148,10 +152,10 @@ class test_AccessRoleAndRight QTest::newRow("RFU_31") << AccessRight::RFU_31 << reserved; QTest::newRow("RFU_32") << AccessRight::RFU_32 << reserved; - QTest::newRow("writeDG17") << AccessRight::WRITE_DG17 << QString("WRITE_DG17"); - QTest::newRow("writeDG18") << AccessRight::WRITE_DG18 << QString("WRITE_DG18"); - QTest::newRow("writeDG19") << AccessRight::WRITE_DG19 << QString("WRITE_DG19"); - QTest::newRow("writeDG20") << AccessRight::WRITE_DG20 << QString("WRITE_DG20"); + QTest::newRow("writeDG17") << AccessRight::WRITE_DG17 << QString("Write address"); + QTest::newRow("writeDG18") << AccessRight::WRITE_DG18 << QString("Write community-ID"); + QTest::newRow("writeDG19") << AccessRight::WRITE_DG19 << QString("Write residence permit I"); + QTest::newRow("writeDG20") << AccessRight::WRITE_DG20 << QString("Write residence permit II"); QTest::newRow("writeDG21") << AccessRight::WRITE_DG21 << QString("WRITE_DG21"); QTest::newRow("readDG21") << AccessRight::READ_DG21 << QString("Optional data"); QTest::newRow("readDG20") << AccessRight::READ_DG20 << QString("Residence permit II"); diff --git a/test/qt/card/asn1/test_Asn1BCDDateUtil.cpp b/test/qt/card/asn1/test_Asn1BCDDateUtil.cpp index 7149b3d47..010330ae2 100644 --- a/test/qt/card/asn1/test_Asn1BCDDateUtil.cpp +++ b/test/qt/card/asn1/test_Asn1BCDDateUtil.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Asn1BCDDateUtil * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_Asn1IntegerUtil.cpp b/test/qt/card/asn1/test_Asn1IntegerUtil.cpp index 30b2ba00b..6de4f87bc 100644 --- a/test/qt/card/asn1/test_Asn1IntegerUtil.cpp +++ b/test/qt/card/asn1/test_Asn1IntegerUtil.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Asn1IntegerUtil * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_Asn1ObjectUtil.cpp b/test/qt/card/asn1/test_Asn1ObjectUtil.cpp index 0f18440fb..147a9a21f 100644 --- a/test/qt/card/asn1/test_Asn1ObjectUtil.cpp +++ b/test/qt/card/asn1/test_Asn1ObjectUtil.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Asn1ObjectUtil * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_Asn1OctetStringUtil.cpp b/test/qt/card/asn1/test_Asn1OctetStringUtil.cpp index a6d14fe92..1c27f54db 100644 --- a/test/qt/card/asn1/test_Asn1OctetStringUtil.cpp +++ b/test/qt/card/asn1/test_Asn1OctetStringUtil.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Asn1OctetStringUtil * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_Asn1StringUtil.cpp b/test/qt/card/asn1/test_Asn1StringUtil.cpp index 8b9cda3d5..ae65330aa 100644 --- a/test/qt/card/asn1/test_Asn1StringUtil.cpp +++ b/test/qt/card/asn1/test_Asn1StringUtil.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Asn1StringUtil * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_Asn1TypeUtil.cpp b/test/qt/card/asn1/test_Asn1TypeUtil.cpp index 8c0aa404d..e6de14f5d 100644 --- a/test/qt/card/asn1/test_Asn1TypeUtil.cpp +++ b/test/qt/card/asn1/test_Asn1TypeUtil.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Asn1TypeUtil * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_Asn1Util.cpp b/test/qt/card/asn1/test_Asn1Util.cpp index f56c27090..8fbae4b3b 100644 --- a/test/qt/card/asn1/test_Asn1Util.cpp +++ b/test/qt/card/asn1/test_Asn1Util.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_AuxiliaryAuthenticatedData.cpp b/test/qt/card/asn1/test_AuxiliaryAuthenticatedData.cpp index 803e3039f..6cba7b22d 100644 --- a/test/qt/card/asn1/test_AuxiliaryAuthenticatedData.cpp +++ b/test/qt/card/asn1/test_AuxiliaryAuthenticatedData.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref AuxiliaryAuthenticatedData * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_CVCertificate.cpp b/test/qt/card/asn1/test_CVCertificate.cpp index a05dd7b05..293b47c43 100644 --- a/test/qt/card/asn1/test_CVCertificate.cpp +++ b/test/qt/card/asn1/test_CVCertificate.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CVCertificate * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/test/qt/card/asn1/test_CVCertificateBody.cpp b/test/qt/card/asn1/test_CVCertificateBody.cpp index 81f24b6b1..eac6f5c48 100644 --- a/test/qt/card/asn1/test_CVCertificateBody.cpp +++ b/test/qt/card/asn1/test_CVCertificateBody.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CVCertificateBody * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/asn1/test_CVCertificateChainBuilder.cpp b/test/qt/card/asn1/test_CVCertificateChainBuilder.cpp index fa61a69e1..0333e0717 100644 --- a/test/qt/card/asn1/test_CVCertificateChainBuilder.cpp +++ b/test/qt/card/asn1/test_CVCertificateChainBuilder.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CVCertificateChain * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/asn1/test_CertificateDescription.cpp b/test/qt/card/asn1/test_CertificateDescription.cpp index d43ad1859..13fbda006 100644 --- a/test/qt/card/asn1/test_CertificateDescription.cpp +++ b/test/qt/card/asn1/test_CertificateDescription.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CertificateDescription * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/asn1/test_ChainBuilder.cpp b/test/qt/card/asn1/test_ChainBuilder.cpp index 1242581f9..c83031f27 100644 --- a/test/qt/card/asn1/test_ChainBuilder.cpp +++ b/test/qt/card/asn1/test_ChainBuilder.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ChainBuilder * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/asn1/test_Chat.cpp b/test/qt/card/asn1/test_Chat.cpp index 5017c5644..921406142 100644 --- a/test/qt/card/asn1/test_Chat.cpp +++ b/test/qt/card/asn1/test_Chat.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CHAT * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ASN1Util.h" diff --git a/test/qt/card/asn1/test_ChipAuthenticationInfo.cpp b/test/qt/card/asn1/test_ChipAuthenticationInfo.cpp index 38f3590a0..022fb5a26 100644 --- a/test/qt/card/asn1/test_ChipAuthenticationInfo.cpp +++ b/test/qt/card/asn1/test_ChipAuthenticationInfo.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ChipAuthenticationInfo * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/asn1/test_EcdsaPublicKey.cpp b/test/qt/card/asn1/test_EcdsaPublicKey.cpp index c27c42c71..a67e4bac8 100644 --- a/test/qt/card/asn1/test_EcdsaPublicKey.cpp +++ b/test/qt/card/asn1/test_EcdsaPublicKey.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref EcdsaPublicKey * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/CVCertificate.h" diff --git a/test/qt/card/asn1/test_KnownOIDs.cpp b/test/qt/card/asn1/test_KnownOIDs.cpp index 7c1bdee46..ea2633e4a 100644 --- a/test/qt/card/asn1/test_KnownOIDs.cpp +++ b/test/qt/card/asn1/test_KnownOIDs.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref KnownOIDs * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/KnownOIDs.h" diff --git a/test/qt/card/asn1/test_PaceInfo.cpp b/test/qt/card/asn1/test_PaceInfo.cpp index 51ab7d78f..2169b0aa6 100644 --- a/test/qt/card/asn1/test_PaceInfo.cpp +++ b/test/qt/card/asn1/test_PaceInfo.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PACEInfo * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/asn1/test_SecurityInfo.cpp b/test/qt/card/asn1/test_SecurityInfo.cpp index a236270d8..552c2bb35 100644 --- a/test/qt/card/asn1/test_SecurityInfo.cpp +++ b/test/qt/card/asn1/test_SecurityInfo.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref SecurityInfo * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ diff --git a/test/qt/card/asn1/test_SecurityInfos.cpp b/test/qt/card/asn1/test_SecurityInfos.cpp index 97c060efe..c0f800862 100644 --- a/test/qt/card/asn1/test_SecurityInfos.cpp +++ b/test/qt/card/asn1/test_SecurityInfos.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref SecurityInfos * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/asn1/test_SignatureChecker.cpp b/test/qt/card/asn1/test_SignatureChecker.cpp index b6703a9a3..85625b190 100644 --- a/test/qt/card/asn1/test_SignatureChecker.cpp +++ b/test/qt/card/asn1/test_SignatureChecker.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref SignatureChecker * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/asn1/test_efCardAccess.cpp b/test/qt/card/asn1/test_efCardAccess.cpp index 725c766b8..e6de68e92 100644 --- a/test/qt/card/asn1/test_efCardAccess.cpp +++ b/test/qt/card/asn1/test_efCardAccess.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/ChipAuthenticationInfo.h" diff --git a/test/qt/card/asn1/test_efCardSecurity.cpp b/test/qt/card/asn1/test_efCardSecurity.cpp index 1b6ef6944..63f0fe44b 100644 --- a/test/qt/card/asn1/test_efCardSecurity.cpp +++ b/test/qt/card/asn1/test_efCardSecurity.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/EFCardSecurity.h" diff --git a/test/qt/card/base/command/test_BaseCardCommand.cpp b/test/qt/card/base/command/test_BaseCardCommand.cpp index 4374990ff..2c024d381 100644 --- a/test/qt/card/base/command/test_BaseCardCommand.cpp +++ b/test/qt/card/base/command/test_BaseCardCommand.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref BaseCardCommand * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "command/BaseCardCommand.h" diff --git a/test/qt/card/base/command/test_DestroyPaceChannelCommand.cpp b/test/qt/card/base/command/test_DestroyPaceChannelCommand.cpp index d6b6d449a..ba83ce838 100644 --- a/test/qt/card/base/command/test_DestroyPaceChannelCommand.cpp +++ b/test/qt/card/base/command/test_DestroyPaceChannelCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "command/DestroyPaceChannelCommand.h" diff --git a/test/qt/card/base/command/test_DidAuthenticateEAC1Command.cpp b/test/qt/card/base/command/test_DidAuthenticateEAC1Command.cpp index b07e859fe..3c47ce72f 100644 --- a/test/qt/card/base/command/test_DidAuthenticateEAC1Command.cpp +++ b/test/qt/card/base/command/test_DidAuthenticateEAC1Command.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "command/DidAuthenticateEAC1Command.h" diff --git a/test/qt/card/base/command/test_DidAuthenticateEAC2Command.cpp b/test/qt/card/base/command/test_DidAuthenticateEAC2Command.cpp index 8b15c2b2b..1fad8e782 100644 --- a/test/qt/card/base/command/test_DidAuthenticateEAC2Command.cpp +++ b/test/qt/card/base/command/test_DidAuthenticateEAC2Command.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "command/DidAuthenticateEAC2Command.h" @@ -57,31 +57,31 @@ class test_DidAuthenticateEAC2Command auto chipAuthenticationInfo = ChipAuthenticationInfo::decode(bytes); QTest::ignoreMessage(QtDebugMsg, "Performing CA MSE:Set AT"); - QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input, input, input), CardReturnCode::COMMAND_FAILED); + QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input), CardReturnCode::COMMAND_FAILED); mWorker->addResponse(CardReturnCode::OK); QTest::ignoreMessage(QtDebugMsg, "Performing CA MSE:Set AT"); QTest::ignoreMessage(QtWarningMsg, "CA MSE:Set AT failed: EMPTY"); - QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input, input, input), CardReturnCode::PROTOCOL_ERROR); + QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input), CardReturnCode::PROTOCOL_ERROR); mWorker->addResponse(CardReturnCode::OK, QByteArray::fromHex("9000")); mWorker->addResponse(CardReturnCode::CANCELLATION_BY_USER); QTest::ignoreMessage(QtDebugMsg, "Performing CA MSE:Set AT"); QTest::ignoreMessage(QtDebugMsg, "Performing CA General Authenticate"); - QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input, input, input), CardReturnCode::CANCELLATION_BY_USER); + QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input), CardReturnCode::CANCELLATION_BY_USER); mWorker->addResponse(CardReturnCode::OK, QByteArray::fromHex("9000")); mWorker->addResponse(CardReturnCode::OK); QTest::ignoreMessage(QtDebugMsg, "Performing CA MSE:Set AT"); QTest::ignoreMessage(QtDebugMsg, "Performing CA General Authenticate"); QTest::ignoreMessage(QtWarningMsg, "CA General Authenticate failed: EMPTY"); - QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input, input, input), CardReturnCode::PROTOCOL_ERROR); + QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input), CardReturnCode::PROTOCOL_ERROR); mWorker->addResponse(CardReturnCode::OK, QByteArray::fromHex("9000")); mWorker->addResponse(CardReturnCode::OK, QByteArray::fromHex("9000")); QTest::ignoreMessage(QtDebugMsg, "Performing CA MSE:Set AT"); QTest::ignoreMessage(QtDebugMsg, "Performing CA General Authenticate"); - QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input, input, input), CardReturnCode::OK); + QCOMPARE(command.performChipAuthentication(chipAuthenticationInfo, input), CardReturnCode::OK); } diff --git a/test/qt/card/base/command/test_EstablishPaceChannelCommand.cpp b/test/qt/card/base/command/test_EstablishPaceChannelCommand.cpp index 4b7f0fccb..8449e302a 100644 --- a/test/qt/card/base/command/test_EstablishPaceChannelCommand.cpp +++ b/test/qt/card/base/command/test_EstablishPaceChannelCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "command/EstablishPaceChannelCommand.h" diff --git a/test/qt/card/base/command/test_SetEidPinCommand.cpp b/test/qt/card/base/command/test_SetEidPinCommand.cpp index 00f4a8c13..89b90290b 100644 --- a/test/qt/card/base/command/test_SetEidPinCommand.cpp +++ b/test/qt/card/base/command/test_SetEidPinCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "command/SetEidPinCommand.h" diff --git a/test/qt/card/base/command/test_TransmitCommand.cpp b/test/qt/card/base/command/test_TransmitCommand.cpp index b345c07d5..323d479e2 100644 --- a/test/qt/card/base/command/test_TransmitCommand.cpp +++ b/test/qt/card/base/command/test_TransmitCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "command/TransmitCommand.h" diff --git a/test/qt/card/base/command/test_UnblockPinCommand.cpp b/test/qt/card/base/command/test_UnblockPinCommand.cpp index d1bfc3cc0..e6e47b18f 100644 --- a/test/qt/card/base/command/test_UnblockPinCommand.cpp +++ b/test/qt/card/base/command/test_UnblockPinCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "command/UnblockPinCommand.h" diff --git a/test/qt/card/base/command/test_UpdRetryCounterCommand.cpp b/test/qt/card/base/command/test_UpdRetryCounterCommand.cpp index cf5149506..06d5bce5b 100644 --- a/test/qt/card/base/command/test_UpdRetryCounterCommand.cpp +++ b/test/qt/card/base/command/test_UpdRetryCounterCommand.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "command/UpdateRetryCounterCommand.h" diff --git a/test/qt/card/base/test_CardConnection.cpp b/test/qt/card/base/test_CardConnection.cpp index 5b3a298a6..0c347e5ce 100644 --- a/test/qt/card/base/test_CardConnection.cpp +++ b/test/qt/card/base/test_CardConnection.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for the class CardConnection. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnection.h" diff --git a/test/qt/card/base/test_CardConnectionWorker.cpp b/test/qt/card/base/test_CardConnectionWorker.cpp index f47aef247..6c404dbdd 100644 --- a/test/qt/card/base/test_CardConnectionWorker.cpp +++ b/test/qt/card/base/test_CardConnectionWorker.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for the class CardConnectionWorker. * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "CardConnectionWorker.h" @@ -48,16 +48,16 @@ class test_CardConnectionWorker void test_Transmit() { - CommandApdu emptyCommandApdu(QByteArray("")); - ResponseApdu emptyApdu; + const CommandApdu emptyCommandApdu(QByteArray("")); //no card - QCOMPARE(mWorker->transmit(emptyCommandApdu, emptyApdu), CardReturnCode::CARD_NOT_FOUND); + QCOMPARE(mWorker->transmit(emptyCommandApdu), ResponseApduResult({CardReturnCode::CARD_NOT_FOUND})); setCard(); //no secure messaging - QCOMPARE(mWorker->transmit(emptyCommandApdu, emptyApdu), CardReturnCode::OK); + ResponseApdu apdu(QByteArray::fromHex("6982")); + QCOMPARE(mWorker->transmit(emptyCommandApdu), ResponseApduResult({CardReturnCode::OK, apdu})); } @@ -114,23 +114,20 @@ class test_CardConnectionWorker void test_SetEidPin() { const QString newPin("111111"); - ResponseApdu emptyApdu; - ResponseApdu apduSuccess(StatusCode::SUCCESS); //no card - QCOMPARE(mWorker->setEidPin(newPin, 5, emptyApdu), CardReturnCode::CARD_NOT_FOUND); + QCOMPARE(mWorker->setEidPin(newPin, 5), ResponseApduResult({CardReturnCode::CARD_NOT_FOUND})); setCard(); //basic reader QTest::ignoreMessage(QtWarningMsg, "Modify PIN failed"); - QCOMPARE(mWorker->setEidPin(newPin, 5, emptyApdu), CardReturnCode::COMMAND_FAILED); - QCOMPARE(mWorker->setEidPin(newPin, 5, apduSuccess), CardReturnCode::OK); + QCOMPARE(mWorker->setEidPin(newPin, 5), ResponseApduResult({CardReturnCode::COMMAND_FAILED})); //comfort reader mReader->getReaderInfo().setBasicReader(false); QTest::ignoreMessage(QtWarningMsg, "Setting eID PIN is not supported"); - QCOMPARE(mWorker->setEidPin(QString(), 5, apduSuccess), CardReturnCode::COMMAND_FAILED); + QCOMPARE(mWorker->setEidPin(QString(), 5), ResponseApduResult({CardReturnCode::COMMAND_FAILED})); } diff --git a/test/qt/card/base/test_CardInfo.cpp b/test/qt/card/base/test_CardInfo.cpp index 1d59b04f0..81128e998 100644 --- a/test/qt/card/base/test_CardInfo.cpp +++ b/test/qt/card/base/test_CardInfo.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for \ref CardInfo. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "CardInfo.h" diff --git a/test/qt/card/base/test_CommandApdu.cpp b/test/qt/card/base/test_CommandApdu.cpp index 1d8c8dba7..d6762d1cd 100644 --- a/test/qt/card/base/test_CommandApdu.cpp +++ b/test/qt/card/base/test_CommandApdu.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for the class CommandApdu. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CommandApdu.h" diff --git a/test/qt/card/base/test_Commands.cpp b/test/qt/card/base/test_Commands.cpp index 92bdfb038..3d0fbf251 100644 --- a/test/qt/card/base/test_Commands.cpp +++ b/test/qt/card/base/test_Commands.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for the class Commands. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "EABuilder.h" diff --git a/test/qt/card/base/test_PinModify.cpp b/test/qt/card/base/test_PinModify.cpp index 840fcf995..91ae29a57 100644 --- a/test/qt/card/base/test_PinModify.cpp +++ b/test/qt/card/base/test_PinModify.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/base/test_PinModifyOutput.cpp b/test/qt/card/base/test_PinModifyOutput.cpp index df5ddcf7f..7cb92c47d 100644 --- a/test/qt/card/base/test_PinModifyOutput.cpp +++ b/test/qt/card/base/test_PinModifyOutput.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/base/test_Reader.cpp b/test/qt/card/base/test_Reader.cpp index 0e77425dd..028dfacc6 100644 --- a/test/qt/card/base/test_Reader.cpp +++ b/test/qt/card/base/test_Reader.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Reader * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "Reader.h" diff --git a/test/qt/card/base/test_ResponseApdu.cpp b/test/qt/card/base/test_ResponseApdu.cpp index ffc8577ea..fdafe5aa5 100644 --- a/test/qt/card/base/test_ResponseApdu.cpp +++ b/test/qt/card/base/test_ResponseApdu.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Apdu * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ResponseApdu.h" @@ -33,34 +33,30 @@ class test_ResponceApdu } - void testRetryCounter0() + void testRetryCounter_data() { - ResponseApdu apdu(QByteArray::fromHex("9000")); - QCOMPARE(apdu.getRetryCounter(), 3); - - apdu.setBuffer(QByteArray::fromHex("63c2")); - QCOMPARE(apdu.getRetryCounter(), 2); - - apdu.setBuffer(QByteArray::fromHex("63c1")); - QCOMPARE(apdu.getRetryCounter(), 1); - - apdu.setBuffer(QByteArray::fromHex("63c0")); - QCOMPARE(apdu.getRetryCounter(), 0); - - apdu.setBuffer(QByteArray::fromHex("6400")); - QCOMPARE(apdu.getRetryCounter(), -1); - - apdu.setBuffer(QByteArray::fromHex("1234")); - QCOMPARE(apdu.getRetryCounter(), -1); + QTest::addColumn("apdu"); + QTest::addColumn("retryCounter"); + + QTest::newRow("9000") << QByteArray::fromHex("9000") << 3; + QTest::newRow("63c2") << QByteArray::fromHex("63c2") << 2; + QTest::newRow("63c1") << QByteArray::fromHex("63c1") << 1; + QTest::newRow("63c0") << QByteArray::fromHex("63c0") << 0; + QTest::newRow("63c3") << QByteArray::fromHex("63c3") << -1; + QTest::newRow("6400") << QByteArray::fromHex("6400") << -1; + QTest::newRow("1234") << QByteArray::fromHex("1234") << -1; + QTest::newRow("12") << QByteArray::fromHex("12") << -1; + QTest::newRow("6283") << QByteArray::fromHex("6283") << 0; + QTest::newRow("empty") << QByteArray() << -1; + } - apdu.setBuffer(QByteArray::fromHex("12")); - QCOMPARE(apdu.getRetryCounter(), -1); - apdu.setBuffer(QByteArray::fromHex("6283")); - QCOMPARE(apdu.getRetryCounter(), 0); + void testRetryCounter() + { + QFETCH(QByteArray, apdu); + QFETCH(int, retryCounter); - apdu.setBuffer(QByteArray()); - QCOMPARE(apdu.getRetryCounter(), -1); + QCOMPARE(ResponseApdu(apdu).getRetryCounter(), retryCounter); } @@ -88,7 +84,7 @@ class test_ResponceApdu QCOMPARE(apdu.getReturnCode(), statusCode); QCOMPARE(apdu.getBuffer(), bufferOut); - apdu.setBuffer(bufferIn); + apdu = ResponseApdu(bufferIn); QCOMPARE(apdu.getReturnCode(), statusCode); QCOMPARE(apdu.getBuffer(), bufferIn); } diff --git a/test/qt/card/bluetooth/test_BluetoothMessage.cpp b/test/qt/card/bluetooth/test_BluetoothMessage.cpp index 692cb8b92..006ea5679 100644 --- a/test/qt/card/bluetooth/test_BluetoothMessage.cpp +++ b/test/qt/card/bluetooth/test_BluetoothMessage.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref BluetoothMessage * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/BluetoothMessage.h" diff --git a/test/qt/card/bluetooth/test_BluetoothMessageParameterCardReaderStatus.cpp b/test/qt/card/bluetooth/test_BluetoothMessageParameterCardReaderStatus.cpp index 4b8b7590e..059b3b436 100644 --- a/test/qt/card/bluetooth/test_BluetoothMessageParameterCardReaderStatus.cpp +++ b/test/qt/card/bluetooth/test_BluetoothMessageParameterCardReaderStatus.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref BluetoothMessageParameterCardReaderStatus * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/parameter/BluetoothMessageParameterCardReaderStatus.h" diff --git a/test/qt/card/bluetooth/test_BluetoothMessageParameterMaxMsgSize.cpp b/test/qt/card/bluetooth/test_BluetoothMessageParameterMaxMsgSize.cpp index 5f4d86e8d..98c3a2e66 100644 --- a/test/qt/card/bluetooth/test_BluetoothMessageParameterMaxMsgSize.cpp +++ b/test/qt/card/bluetooth/test_BluetoothMessageParameterMaxMsgSize.cpp @@ -1,6 +1,6 @@ /*! * \brief Unit tests for \ref BluetoothMessageParameterMaxMsgSize * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/parameter/BluetoothMessageParameterMaxMsgSize.h" diff --git a/test/qt/card/bluetooth/test_BluetoothMessageParser.cpp b/test/qt/card/bluetooth/test_BluetoothMessageParser.cpp index 2ede1e54b..30538ebda 100644 --- a/test/qt/card/bluetooth/test_BluetoothMessageParser.cpp +++ b/test/qt/card/bluetooth/test_BluetoothMessageParser.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref BluetoothMessageParser * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/BluetoothMessageParser.h" diff --git a/test/qt/card/drivers/test_ReaderDetector.cpp b/test/qt/card/drivers/test_ReaderDetector.cpp index 042b959e5..067e70f4f 100644 --- a/test/qt/card/drivers/test_ReaderDetector.cpp +++ b/test/qt/card/drivers/test_ReaderDetector.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ReaderDetector * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDetector.h" diff --git a/test/qt/card/pace/test_CipherMAC.cpp b/test/qt/card/pace/test_CipherMAC.cpp index b191b9615..6dd3281d5 100644 --- a/test/qt/card/pace/test_CipherMAC.cpp +++ b/test/qt/card/pace/test_CipherMAC.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/KnownOIDs.h" diff --git a/test/qt/card/pace/test_EcUtil.cpp b/test/qt/card/pace/test_EcUtil.cpp index 067973b81..3961921ce 100644 --- a/test/qt/card/pace/test_EcUtil.cpp +++ b/test/qt/card/pace/test_EcUtil.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/ec/EcUtil.h" diff --git a/test/qt/card/pace/test_EcdhKeyAgreement.cpp b/test/qt/card/pace/test_EcdhKeyAgreement.cpp index 411a9ce24..020f10709 100644 --- a/test/qt/card/pace/test_EcdhKeyAgreement.cpp +++ b/test/qt/card/pace/test_EcdhKeyAgreement.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for the EcdhKeyAgreement * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/ec/EcdhKeyAgreement.h" diff --git a/test/qt/card/pace/test_EllipticCurveFactory.cpp b/test/qt/card/pace/test_EllipticCurveFactory.cpp index 63cfc6450..2c42739b5 100644 --- a/test/qt/card/pace/test_EllipticCurveFactory.cpp +++ b/test/qt/card/pace/test_EllipticCurveFactory.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/ec/EllipticCurveFactory.h" diff --git a/test/qt/card/pace/test_KeyDerivationFunction.cpp b/test/qt/card/pace/test_KeyDerivationFunction.cpp index 02cb8aacb..08bb409ae 100644 --- a/test/qt/card/pace/test_KeyDerivationFunction.cpp +++ b/test/qt/card/pace/test_KeyDerivationFunction.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/KnownOIDs.h" diff --git a/test/qt/card/pace/test_PaceHandler.cpp b/test/qt/card/pace/test_PaceHandler.cpp index 1dc10102c..7c67e1b5e 100644 --- a/test/qt/card/pace/test_PaceHandler.cpp +++ b/test/qt/card/pace/test_PaceHandler.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for the PaceHandler * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "pace/PaceHandler.h" diff --git a/test/qt/card/pace/test_SymmetricCipher.cpp b/test/qt/card/pace/test_SymmetricCipher.cpp index c5ccca108..d0ca5eb51 100644 --- a/test/qt/card/pace/test_SymmetricCipher.cpp +++ b/test/qt/card/pace/test_SymmetricCipher.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/KnownOIDs.h" diff --git a/test/qt/card/pcsc/test_PcscUtils.cpp b/test/qt/card/pcsc/test_PcscUtils.cpp index f96b11e50..d1fa7c273 100644 --- a/test/qt/card/pcsc/test_PcscUtils.cpp +++ b/test/qt/card/pcsc/test_PcscUtils.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PcscUtils * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscUtils.h" diff --git a/test/qt/card/pcsc/test_pcscReaderFeature.cpp b/test/qt/card/pcsc/test_pcscReaderFeature.cpp index 5a2e7ce49..5c9a90c88 100644 --- a/test/qt/card/pcsc/test_pcscReaderFeature.cpp +++ b/test/qt/card/pcsc/test_pcscReaderFeature.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PcscReaderFeature * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscReaderFeature.h" diff --git a/test/qt/card/pcsc/test_pcscReaderPaceCapability.cpp b/test/qt/card/pcsc/test_pcscReaderPaceCapability.cpp index e19500feb..57e97c69b 100644 --- a/test/qt/card/pcsc/test_pcscReaderPaceCapability.cpp +++ b/test/qt/card/pcsc/test_pcscReaderPaceCapability.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PcscReaderPaceCapability * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PcscReaderPaceCapability.h" diff --git a/test/qt/card/test_EstablishPaceChannel.cpp b/test/qt/card/test_EstablishPaceChannel.cpp index 01d54337a..7b271e852 100644 --- a/test/qt/card/test_EstablishPaceChannel.cpp +++ b/test/qt/card/test_EstablishPaceChannel.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for card EstablishPaceChannelBuilder * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/test_EstablishPaceChannelOutput.cpp b/test/qt/card/test_EstablishPaceChannelOutput.cpp index b841fdf4c..387c38da9 100644 --- a/test/qt/card/test_EstablishPaceChannelOutput.cpp +++ b/test/qt/card/test_EstablishPaceChannelOutput.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for card EstablishPACEChannelOutput * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/test_EstablishPaceChannelParser.cpp b/test/qt/card/test_EstablishPaceChannelParser.cpp index fd11d30f1..1c95aa3ea 100644 --- a/test/qt/card/test_EstablishPaceChannelParser.cpp +++ b/test/qt/card/test_EstablishPaceChannelParser.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for \ref EstablishPaceChannelParser * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "EstablishPaceChannelParser.h" diff --git a/test/qt/card/test_GeneralAuthenticateResponse.cpp b/test/qt/card/test_GeneralAuthenticateResponse.cpp index a8515a8f5..ef7e1faa2 100644 --- a/test/qt/card/test_GeneralAuthenticateResponse.cpp +++ b/test/qt/card/test_GeneralAuthenticateResponse.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for GeneralAuthenticate response APDUs * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/test_MSEBuilder.cpp b/test/qt/card/test_MSEBuilder.cpp index 63759eb99..9c201e450 100644 --- a/test/qt/card/test_MSEBuilder.cpp +++ b/test/qt/card/test_MSEBuilder.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MSEBuilder.h" diff --git a/test/qt/card/test_ReaderManager.cpp b/test/qt/card/test_ReaderManager.cpp index cc63ac91f..ee9394de4 100644 --- a/test/qt/card/test_ReaderManager.cpp +++ b/test/qt/card/test_ReaderManager.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderManager.h" diff --git a/test/qt/card/test_SecureMessaging.cpp b/test/qt/card/test_SecureMessaging.cpp index d56d1c8ca..e8ce62195 100644 --- a/test/qt/card/test_SecureMessaging.cpp +++ b/test/qt/card/test_SecureMessaging.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/card/test_SecureMessagingResponse.cpp b/test/qt/card/test_SecureMessagingResponse.cpp index 3503ad175..1e05ada95 100644 --- a/test/qt/card/test_SecureMessagingResponse.cpp +++ b/test/qt/card/test_SecureMessagingResponse.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests for SecureMessagingResponse * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/configuration/test_ProviderConfiguration.cpp b/test/qt/configuration/test_ProviderConfiguration.cpp index 5f1ada2f2..62d3fbac2 100644 --- a/test/qt/configuration/test_ProviderConfiguration.cpp +++ b/test/qt/configuration/test_ProviderConfiguration.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ProviderConfiguration * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderConfiguration.h" @@ -83,9 +83,9 @@ class test_ProviderConfiguration /* postal address */ QStringLiteral("Am Fallturm 9\n28359 Bremen"), /* icon */ QString(), /* image */ QString(), - /* tcTokenUrl */ QStringLiteral("https://npa.allianz.de/azservice/NpaEIDService/nparef/-wnf"), + /* tcTokenUrl */ QStringLiteral("https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml"), /* clientUrl */ QStringLiteral("https://www.bva.bund.de/bafoeg-online/Bafoeg/flow/anmeld"), - /* subjectUrls */ QStringList({QStringLiteral("https://npa.allianz.de/bla1"), QStringLiteral("https://npa.allianz.de/bla1")}) + /* subjectUrls */ QStringList({QStringLiteral("https://www.autentapp.de/bla1"), QStringLiteral("https://www.autentapp.de/bla1")}) ); QCOMPARE(provider.getShortName().toString(), QStringLiteral("Provider 1")); @@ -100,9 +100,9 @@ class test_ProviderConfiguration QCOMPARE(provider.getPostalAddress(), QStringLiteral("Am Fallturm 9\n28359 Bremen")); QVERIFY(provider.getIcon()->lookupPath().endsWith("/CategoryA_button.svg")); QVERIFY(provider.getImage()->lookupPath().endsWith("/CategoryA_bg.svg")); - QCOMPARE(provider.getTcTokenUrl(), QUrl(QStringLiteral("https://npa.allianz.de/azservice/NpaEIDService/nparef/-wnf"))); + QCOMPARE(provider.getTcTokenUrl(), QUrl(QStringLiteral("https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml"))); QCOMPARE(provider.getClientUrl(), QUrl(QStringLiteral("https://www.bva.bund.de/bafoeg-online/Bafoeg/flow/anmeld"))); - QCOMPARE(provider.getSubjectUrls(), QStringList({QStringLiteral("https://npa.allianz.de/bla1"), QStringLiteral("https://npa.allianz.de/bla1")})); + QCOMPARE(provider.getSubjectUrls(), QStringList({QStringLiteral("https://www.autentapp.de/bla1"), QStringLiteral("https://www.autentapp.de/bla1")})); } @@ -231,9 +231,9 @@ class test_ProviderConfiguration /* postal address */ QStringLiteral("Am Fallturm 9\n28359 Bremen"), /* icon */ QString(), /* image */ QString(), - /* tcTokenUrl */ QStringLiteral("https://npa.allianz.de/azservice/NpaEIDService/nparef/-wnf"), + /* tcTokenUrl */ QStringLiteral("https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml"), /* clientUrl */ QStringLiteral("https://www.bva.bund.de/bafoeg-online/Bafoeg/flow/anmeld"), - /* subjectUrls */ QStringList({QStringLiteral("https://npa.allianz.de/bla1"), QStringLiteral("https://npa.allianz.de/bla1")}) + /* subjectUrls */ QStringList({QStringLiteral("https://www.autentapp.de/bla1"), QStringLiteral("https://www.autentapp.de/bla1")}) ); const ProviderConfigurationInfo provider2( @@ -249,9 +249,9 @@ class test_ProviderConfiguration /* postal address */ QStringLiteral("Am Fallturm 9\n28359 Bremen"), /* icon */ QString(), /* image */ QString(), - /* tcTokenUrl */ QStringLiteral("https://npa.allianz.de/azservice/NpaEIDService/nparef/-wnf"), + /* tcTokenUrl */ QStringLiteral("https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml"), /* clientUrl */ QStringLiteral("https://www.bva.bund.de/bafoeg-online/Bafoeg/flow/anmeld"), - /* subjectUrls */ QStringList({QStringLiteral("https://npa.allianz.de/bla1"), QStringLiteral("https://npa.allianz.de/bla1")}) + /* subjectUrls */ QStringList({QStringLiteral("https://www.autentapp.de/bla1"), QStringLiteral("https://www.autentapp.de/bla1")}) ); const ProviderConfigurationInfo provider3( @@ -267,9 +267,9 @@ class test_ProviderConfiguration /* postal address */ QStringLiteral("Am Fallturm 9\n28359 Bremen"), /* icon */ QString(), /* image */ QString(), - /* tcTokenUrl */ QStringLiteral("https://npa.allianz.de/azservice/NpaEIDService/nparef/-wnf"), + /* tcTokenUrl */ QStringLiteral("https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml"), /* clientUrl */ QStringLiteral("https://www.bva.bund.de/bafoeg-online/Bafoeg/flow/anmeld"), - /* subjectUrls */ QStringList({QStringLiteral("https://npa.allianz.de/bla1"), QStringLiteral("https://npa.allianz.de/bla1")}) + /* subjectUrls */ QStringList({QStringLiteral("https://www.autentapp.de/bla1"), QStringLiteral("https://www.autentapp.de/bla1")}) ); QVERIFY(provider1 == provider1); diff --git a/test/qt/configuration/test_ProviderConfigurationParser.cpp b/test/qt/configuration/test_ProviderConfigurationParser.cpp index eed194024..c3193b3c2 100644 --- a/test/qt/configuration/test_ProviderConfigurationParser.cpp +++ b/test/qt/configuration/test_ProviderConfigurationParser.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ProviderConfigurationParser * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderConfigurationParser.h" @@ -52,16 +52,16 @@ class test_ProviderConfigurationParser " \"category\": \"other\"" " }," " {" - " \"shortName\": {\"\" : \"Allianz Kundenportal\"}," - " \"longName\": {\"\" : \"Allianz Kundenportal - Meine Allianz\"}," - " \"shortDescription\": {\"\" : \"Kundenportal von Allianz\"}," - " \"longDescription\": {\"\" : \"Kundenportal von Allianz - Meine Allianz\"}," - " \"address\": \"https://meine.allianz.de/form\"," - " \"homepage\": \"https://meine.allianz.de\"," - " \"phone\": \"0421 123456\"," - " \"email\": \"abc@def.de\"," - " \"postalAddress\": \"Am Fallturm 9,\n28359 Bremen\"," - " \"category\": \"insurance\"" + " \"shortName\": {\"\" : \"Selbstauskunft\"}," + " \"longName\": {\"\" : \"Selbstauskunft - \\\"Meine Daten einsehen\\\"\"}," + " \"shortDescription\": {\"\" : \"Funktion der AusweisApp2\"}," + " \"longDescription\": {\"\" : \"Die AusweisApp2 verfuegt ueber die Funktion \\\"Meine Daten einsehen\\\"\"}," + " \"address\": \"https://www.ausweisapp.bund.de/online-ausweisen/meine-daten-auslesen/\"," + " \"homepage\": \"https://www.ausweisapp.bund.de/\"," + " \"phone\": \"+49 421 - 204 95 995\"," + " \"email\": \"support@ausweisapp.de\"," + " \"postalAddress\": \"Governikus GmbH & Co. KG
- im Auftrag des Bundesamtes fuer Sicherheit in der Informationstechnik -
Hochschulring 4
D-28359 Bremen\"," + " \"category\": \"citizen\"" " }" " ]" "}"); @@ -98,18 +98,18 @@ class test_ProviderConfigurationParser QVERIFY(provider.getImage()->lookupPath().endsWith("/other_bg.svg")); provider = providers[1]; - QCOMPARE(provider.getShortName().toString(), QStringLiteral("Allianz Kundenportal")); - QCOMPARE(provider.getLongName().toString(), QStringLiteral("Allianz Kundenportal - Meine Allianz")); - QCOMPARE(provider.getShortDescription().toString(), QStringLiteral("Kundenportal von Allianz")); - QCOMPARE(provider.getLongDescription().toString(), QStringLiteral("Kundenportal von Allianz - Meine Allianz")); - QCOMPARE(provider.getAddress(), QStringLiteral("https://meine.allianz.de/form")); - QCOMPARE(provider.getHomepage(), QStringLiteral("https://meine.allianz.de")); - QCOMPARE(provider.getPhone(), QStringLiteral("0421 123456")); - QCOMPARE(provider.getEMail(), QStringLiteral("abc@def.de")); - QCOMPARE(provider.getPostalAddress(), QStringLiteral("Am Fallturm 9,\n28359 Bremen")); - QCOMPARE(provider.getCategory(), QStringLiteral("insurance")); - QVERIFY(provider.getIcon()->lookupPath().endsWith("/insurance_button.svg")); - QVERIFY(provider.getImage()->lookupPath().endsWith("/insurance_bg.svg")); + QCOMPARE(provider.getShortName().toString(), QStringLiteral("Selbstauskunft")); + QCOMPARE(provider.getLongName().toString(), QStringLiteral("Selbstauskunft - \"Meine Daten einsehen\"")); + QCOMPARE(provider.getShortDescription().toString(), QStringLiteral("Funktion der AusweisApp2")); + QCOMPARE(provider.getLongDescription().toString(), QStringLiteral("Die AusweisApp2 verfuegt ueber die Funktion \"Meine Daten einsehen\"")); + QCOMPARE(provider.getAddress(), QStringLiteral("https://www.ausweisapp.bund.de/online-ausweisen/meine-daten-auslesen/")); + QCOMPARE(provider.getHomepage(), QStringLiteral("https://www.ausweisapp.bund.de/")); + QCOMPARE(provider.getPhone(), QStringLiteral("+49 421 - 204 95 995")); + QCOMPARE(provider.getEMail(), QStringLiteral("support@ausweisapp.de")); + QCOMPARE(provider.getPostalAddress(), QStringLiteral("Governikus GmbH & Co. KG
- im Auftrag des Bundesamtes fuer Sicherheit in der Informationstechnik -
Hochschulring 4
D-28359 Bremen")); + QCOMPARE(provider.getCategory(), QStringLiteral("citizen")); + QVERIFY(provider.getIcon()->lookupPath().endsWith("/citizen_button.svg")); + QVERIFY(provider.getImage()->lookupPath().endsWith("/citizen_bg.svg")); } @@ -149,7 +149,7 @@ class test_ProviderConfigurationParser " {" " }," " {" - " \"tcTokenUrl\": \"https://npa.allianz.de/azservice/NpaEIDService/nparef/-wnf\"" + " \"tcTokenUrl\": \"https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml\"" " }" " ]" "}"); @@ -162,7 +162,7 @@ class test_ProviderConfigurationParser QCOMPARE(provider.getTcTokenUrl(), QUrl()); provider = providers[1]; - QCOMPARE(provider.getTcTokenUrl(), QUrl(QStringLiteral("https://npa.allianz.de/azservice/NpaEIDService/nparef/-wnf"))); + QCOMPARE(provider.getTcTokenUrl(), QUrl(QStringLiteral("https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml"))); } @@ -200,10 +200,10 @@ class test_ProviderConfigurationParser " \"subjectUrls\": []" " }," " {" - " \"subjectUrls\": [\"https://npa.allianz.de/bla1\"]" + " \"subjectUrls\": [\"https://www.autentapp.de/bla1\"]" " }," " {" - " \"subjectUrls\": [\"https://npa.allianz.de/bla1\", \"https://npa.allianz.de/bla2\"]" + " \"subjectUrls\": [\"https://www.autentapp.de/bla1\", \"https://www.autentapp.de/bla2\"]" " }" " ]" "}"); @@ -219,10 +219,10 @@ class test_ProviderConfigurationParser QCOMPARE(provider.getSubjectUrls(), QStringList()); provider = providers[2]; - QCOMPARE(provider.getSubjectUrls(), QStringList({QStringLiteral("https://npa.allianz.de/bla1")})); + QCOMPARE(provider.getSubjectUrls(), QStringList({QStringLiteral("https://www.autentapp.de/bla1")})); provider = providers[3]; - QCOMPARE(provider.getSubjectUrls(), QStringList({QStringLiteral("https://npa.allianz.de/bla1"), QStringLiteral("https://npa.allianz.de/bla2")})); + QCOMPARE(provider.getSubjectUrls(), QStringList({QStringLiteral("https://www.autentapp.de/bla1"), QStringLiteral("https://www.autentapp.de/bla2")})); } @@ -250,12 +250,12 @@ class test_ProviderConfigurationParser { QTest::addColumn("count"); - const int desktop = 58; + const int desktop = 62; QTest::newRow("win") << desktop; QTest::newRow("mac") << desktop; QTest::newRow("linux") << desktop; QTest::newRow("android") << desktop; - QTest::newRow("ios") << 17; + QTest::newRow("ios") << 30; } diff --git a/test/qt/configuration/test_ReaderConfiguration.cpp b/test/qt/configuration/test_ReaderConfiguration.cpp index 9fc042861..686c9a011 100644 --- a/test/qt/configuration/test_ReaderConfiguration.cpp +++ b/test/qt/configuration/test_ReaderConfiguration.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ReaderConfiguration * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderConfiguration.h" @@ -74,6 +74,9 @@ class test_ReaderConfiguration QTest::newRow("Remote card reader") << UsbId(0x0000, 0x0000) << "NFC-abcdef1234567890" << QStringLiteral("Smartphone als Kartenleser") << "img_RemoteReader" << "^NFC.*"; + QTest::newRow("PersoSim SaC") << UsbId(0x0000, 0x0001) << "PersoSimHandshake 00 00" << QStringLiteral("PersoSim") << "img_PersoSim" << "^PersoSim.*"; + QTest::newRow("PersoSim native") << UsbId(0x0000, 0x0001) << "PersoSim Virtual Card Reader 0" << QStringLiteral("PersoSim") << "img_PersoSim" << "^PersoSim.*"; + QTest::newRow("REINER SCT cyberJack RFID komfort") << UsbId(0x0C4B, 0x0501) << "REINER SCT cyberJack RFID komfort" << "REINER SCT cyberJack RFID komfort" << "img_Reiner_SCT_cyberjack_RFID_komfort" << "REINER SCT cyberJack RFID komfort"; QTest::newRow("REINER SCT cyberJack RFID standard") << UsbId(0x0C4B, 0x0500) << "REINER SCT cyberJack RFID standard" << "REINER SCT cyberJack RFID standard" << "img_Reiner_SCT_cyberjack_RFID_standard" << "REINER SCT cyberJack RFID standard"; QTest::newRow("REINER SCT cyberJack RFID basis") << UsbId(0x0C4B, 0x9102) << "REINER SCT cyberJack RFID basis" << "REINER SCT cyberJack RFID basis" << "img_Reiner_SCT_cyberjack_RFID_basis" << "REINER SCT cyberJack RFID basis"; @@ -140,6 +143,9 @@ class test_ReaderConfiguration QTest::newRow("Remote card reader") << UsbId(0x0000, 0x0000) << "NFC-abcdef1234567890" << QStringLiteral("Smartphone als Kartenleser"); + QTest::newRow("PersoSim SaC") << UsbId(0x0000, 0x0001) << "PersoSimHandshake 00 00" << QStringLiteral("PersoSim"); + QTest::newRow("PersoSim native") << UsbId(0x0000, 0x0001) << "PersoSim Virtual Card Reader 0" << QStringLiteral("PersoSim"); + QTest::newRow("REINER SCT cyberJack RFID komfort-windows-7-10") << UsbId(0x0C4B, 0x0501) << "REINER SCT cyberJack RFID komfort USB 1" << "REINER SCT cyberJack RFID komfort"; QTest::newRow("REINER SCT cyberJack RFID komfort-macosx-10.11-10.14") << UsbId(0x0C4B, 0x0501) << "REINER SCT cyberJack RFID komfort" << "REINER SCT cyberJack RFID komfort"; @@ -284,7 +290,7 @@ class test_ReaderConfiguration }; -const int test_ReaderConfiguration::cCardReadersInConfigurationFile = 26; +const int test_ReaderConfiguration::cCardReadersInConfigurationFile = 27; QTEST_GUILESS_MAIN(test_ReaderConfiguration) #include "test_ReaderConfiguration.moc" diff --git a/test/qt/configuration/test_ReaderConfigurationEntryParser.cpp b/test/qt/configuration/test_ReaderConfigurationEntryParser.cpp index 6fec98f5b..6d1fcef74 100644 --- a/test/qt/configuration/test_ReaderConfigurationEntryParser.cpp +++ b/test/qt/configuration/test_ReaderConfigurationEntryParser.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ReaderConfigurationParser * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderConfigurationParser.h" diff --git a/test/qt/configuration/test_ReaderConfigurationParser.cpp b/test/qt/configuration/test_ReaderConfigurationParser.cpp index 0618e6a43..c3ccfbb6e 100644 --- a/test/qt/configuration/test_ReaderConfigurationParser.cpp +++ b/test/qt/configuration/test_ReaderConfigurationParser.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ReaderDetector * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderConfigurationParser.h" diff --git a/test/qt/core/context/test_AuthContext.cpp b/test/qt/core/context/test_AuthContext.cpp index 68e07a62a..4d17ea91a 100644 --- a/test/qt/core/context/test_AuthContext.cpp +++ b/test/qt/core/context/test_AuthContext.cpp @@ -1,7 +1,7 @@ /*! * \brief Test for the chat administration in authentication context. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "TestAuthContext.h" diff --git a/test/qt/core/context/test_ChangePinContext.cpp b/test/qt/core/context/test_ChangePinContext.cpp index 7ed9dea38..bf2d12a93 100644 --- a/test/qt/core/context/test_ChangePinContext.cpp +++ b/test/qt/core/context/test_ChangePinContext.cpp @@ -1,7 +1,7 @@ /*! * \brief Test for \ref ChangePinContext. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "context/ChangePinContext.h" diff --git a/test/qt/core/context/test_DiagnosisContext.cpp b/test/qt/core/context/test_DiagnosisContext.cpp index 0c889f64c..e49a58504 100644 --- a/test/qt/core/context/test_DiagnosisContext.cpp +++ b/test/qt/core/context/test_DiagnosisContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "context/DiagnosisContext.h" diff --git a/test/qt/core/context/test_RemoteServiceContext.cpp b/test/qt/core/context/test_RemoteServiceContext.cpp index 3887142aa..33ea7c425 100644 --- a/test/qt/core/context/test_RemoteServiceContext.cpp +++ b/test/qt/core/context/test_RemoteServiceContext.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for the class \ref RemoteServiceContext. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "context/RemoteServiceContext.h" diff --git a/test/qt/core/context/test_WorkflowContext.cpp b/test/qt/core/context/test_WorkflowContext.cpp index feee58507..60d53e9d0 100644 --- a/test/qt/core/context/test_WorkflowContext.cpp +++ b/test/qt/core/context/test_WorkflowContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "context/WorkflowContext.h" diff --git a/test/qt/core/controller/test_AppController.cpp b/test/qt/core/controller/test_AppController.cpp index e1ec13d60..970578c3f 100644 --- a/test/qt/core/controller/test_AppController.cpp +++ b/test/qt/core/controller/test_AppController.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "controller/AppController.h" diff --git a/test/qt/core/controller/test_ChangePinController.cpp b/test/qt/core/controller/test_ChangePinController.cpp index 773161632..f64631796 100644 --- a/test/qt/core/controller/test_ChangePinController.cpp +++ b/test/qt/core/controller/test_ChangePinController.cpp @@ -1,7 +1,7 @@ /*! * \brief Test for the Change PIN functionality. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "controller/ChangePinController.h" diff --git a/test/qt/core/paos/invoke/test_DidAuthenticateResponseEAC1.cpp b/test/qt/core/paos/invoke/test_DidAuthenticateResponseEAC1.cpp index c4cb8870c..6b779919a 100644 --- a/test/qt/core/paos/invoke/test_DidAuthenticateResponseEAC1.cpp +++ b/test/qt/core/paos/invoke/test_DidAuthenticateResponseEAC1.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DidAuthenticateEAC1 * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/invoke/DidAuthenticateResponseEac1.h" diff --git a/test/qt/core/paos/invoke/test_DidAuthenticateResponseEAC2.cpp b/test/qt/core/paos/invoke/test_DidAuthenticateResponseEAC2.cpp index 8ea2498a5..c96c5c132 100644 --- a/test/qt/core/paos/invoke/test_DidAuthenticateResponseEAC2.cpp +++ b/test/qt/core/paos/invoke/test_DidAuthenticateResponseEAC2.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DidAuthenticateEAC2 * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/invoke/DidAuthenticateResponseEac2.h" diff --git a/test/qt/core/paos/invoke/test_DisconnectResponse.cpp b/test/qt/core/paos/invoke/test_DisconnectResponse.cpp index 0fe66ffe0..c2e69df7a 100644 --- a/test/qt/core/paos/invoke/test_DisconnectResponse.cpp +++ b/test/qt/core/paos/invoke/test_DisconnectResponse.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DisconnectResponse * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "CardReturnCode.h" diff --git a/test/qt/core/paos/invoke/test_PaosCreator.cpp b/test/qt/core/paos/invoke/test_PaosCreator.cpp index dde6d5de8..1e4c19eef 100644 --- a/test/qt/core/paos/invoke/test_PaosCreator.cpp +++ b/test/qt/core/paos/invoke/test_PaosCreator.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PaosCreator * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/invoke/PaosCreator.h" diff --git a/test/qt/core/paos/invoke/test_StartPaos.cpp b/test/qt/core/paos/invoke/test_StartPaos.cpp index ab1a57bf8..7c96b7c79 100644 --- a/test/qt/core/paos/invoke/test_StartPaos.cpp +++ b/test/qt/core/paos/invoke/test_StartPaos.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StartPaos * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/invoke/StartPaos.h" diff --git a/test/qt/core/paos/invoke/test_TransmitResponse.cpp b/test/qt/core/paos/invoke/test_TransmitResponse.cpp index d0cebc215..fa432de32 100644 --- a/test/qt/core/paos/invoke/test_TransmitResponse.cpp +++ b/test/qt/core/paos/invoke/test_TransmitResponse.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref TransmitResponse * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/invoke/TransmitResponse.h" diff --git a/test/qt/core/paos/retrieve/test_DidAuthenticateEac1.cpp b/test/qt/core/paos/retrieve/test_DidAuthenticateEac1.cpp index 5eb7d76a6..da57be5c6 100644 --- a/test/qt/core/paos/retrieve/test_DidAuthenticateEac1.cpp +++ b/test/qt/core/paos/retrieve/test_DidAuthenticateEac1.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \DidAuthenticateEac1 * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/DidAuthenticateEac1.h" diff --git a/test/qt/core/paos/retrieve/test_DidAuthenticateEac2.cpp b/test/qt/core/paos/retrieve/test_DidAuthenticateEac2.cpp index 2df373972..14becf437 100644 --- a/test/qt/core/paos/retrieve/test_DidAuthenticateEac2.cpp +++ b/test/qt/core/paos/retrieve/test_DidAuthenticateEac2.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \DidAuthenticateEac1 * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/DidAuthenticateEac2.h" diff --git a/test/qt/core/paos/retrieve/test_DidAuthenticateEacAdditional.cpp b/test/qt/core/paos/retrieve/test_DidAuthenticateEacAdditional.cpp index a7061870f..fe561dfd6 100644 --- a/test/qt/core/paos/retrieve/test_DidAuthenticateEacAdditional.cpp +++ b/test/qt/core/paos/retrieve/test_DidAuthenticateEacAdditional.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \DidAuthenticateEACAdditionalInputType * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/DidAuthenticateEacAdditional.h" diff --git a/test/qt/core/paos/retrieve/test_InitializeFramework.cpp b/test/qt/core/paos/retrieve/test_InitializeFramework.cpp index d30a25fdf..cc77b410b 100644 --- a/test/qt/core/paos/retrieve/test_InitializeFramework.cpp +++ b/test/qt/core/paos/retrieve/test_InitializeFramework.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \InitializeFramework * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/InitializeFramework.h" diff --git a/test/qt/core/paos/retrieve/test_StartPAOSResponse.cpp b/test/qt/core/paos/retrieve/test_StartPAOSResponse.cpp index 7518a16b0..aa2586d5d 100644 --- a/test/qt/core/paos/retrieve/test_StartPAOSResponse.cpp +++ b/test/qt/core/paos/retrieve/test_StartPAOSResponse.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \InitializeFramework * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/StartPaosResponse.h" diff --git a/test/qt/core/paos/retrieve/test_transmit.cpp b/test/qt/core/paos/retrieve/test_transmit.cpp index f77a89dda..4624c3c8e 100644 --- a/test/qt/core/paos/retrieve/test_transmit.cpp +++ b/test/qt/core/paos/retrieve/test_transmit.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \transmit * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/retrieve/Transmit.h" diff --git a/test/qt/core/paos/test_PaosMessage.cpp b/test/qt/core/paos/test_PaosMessage.cpp index c5c94a1ca..aca10cca9 100644 --- a/test/qt/core/paos/test_PaosMessage.cpp +++ b/test/qt/core/paos/test_PaosMessage.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PaosMessage * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/PaosMessage.h" diff --git a/test/qt/core/paos/test_RequestType.cpp b/test/qt/core/paos/test_RequestType.cpp index 6d7b99371..a06f0d33d 100644 --- a/test/qt/core/paos/test_RequestType.cpp +++ b/test/qt/core/paos/test_RequestType.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RequestType * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/core/paos/test_UserAgent.cpp b/test/qt/core/paos/test_UserAgent.cpp index 5f2e14ad3..56d85b635 100644 --- a/test/qt/core/paos/test_UserAgent.cpp +++ b/test/qt/core/paos/test_UserAgent.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref UserAgent * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "paos/element/UserAgent.h" diff --git a/test/qt/core/paos/test_paoshandler.cpp b/test/qt/core/paos/test_paoshandler.cpp index a23ef886c..e1a244fca 100644 --- a/test/qt/core/paos/test_paoshandler.cpp +++ b/test/qt/core/paos/test_paoshandler.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/core/states/test_StateCertificateDescriptionCheck.cpp b/test/qt/core/states/test_StateCertificateDescriptionCheck.cpp index 92e77a116..7c4799feb 100644 --- a/test/qt/core/states/test_StateCertificateDescriptionCheck.cpp +++ b/test/qt/core/states/test_StateCertificateDescriptionCheck.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateCertificateDescriptionCheck.h" diff --git a/test/qt/core/states/test_StateChangePin.cpp b/test/qt/core/states/test_StateChangePin.cpp index ea8718fb5..76b1b411a 100644 --- a/test/qt/core/states/test_StateChangePin.cpp +++ b/test/qt/core/states/test_StateChangePin.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StateChangePin * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateChangePin.h" diff --git a/test/qt/core/states/test_StateChangePinRemote.cpp b/test/qt/core/states/test_StateChangePinRemote.cpp index dbef5c7e8..f52958143 100644 --- a/test/qt/core/states/test_StateChangePinRemote.cpp +++ b/test/qt/core/states/test_StateChangePinRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/remote_service/StateChangePinRemote.h" @@ -46,7 +46,7 @@ class test_StateChangePinRemote private Q_SLOTS: void initTestCase() { - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { return new MockRemoteServer(); })); } diff --git a/test/qt/core/states/test_StateCheckRefreshAddress.cpp b/test/qt/core/states/test_StateCheckRefreshAddress.cpp index 446e59705..d52987982 100644 --- a/test/qt/core/states/test_StateCheckRefreshAddress.cpp +++ b/test/qt/core/states/test_StateCheckRefreshAddress.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateCheckRefreshAddress.h" @@ -191,6 +191,8 @@ class test_StateCheckRefreshAddress void isMatchingSameOriginPolicyInDevMode() { + Env::getSingleton()->getGeneralSettings().setDeveloperOptions(true); + Env::getSingleton()->getGeneralSettings().setDeveloperMode(false); QVERIFY(!mState->isMatchingSameOriginPolicyInDevMode()); @@ -242,7 +244,7 @@ class test_StateCheckRefreshAddress mAuthContext->setStatus(GlobalStatus::Code::No_Error); - QTest::ignoreMessage(QtCriticalMsg, "Network_Other_Error | \"An unknown network error occurred.\""); + QTest::ignoreMessage(QtCriticalMsg, "Network_Other_Error | \"An unknown network error occurred. Check your network connection and try to restart the app.\""); mState->reportCommunicationError(GlobalStatus::Code::Network_Other_Error); QCOMPARE(mAuthContext->getStatus().getStatusCode(), GlobalStatus::Code::Network_Other_Error); QCOMPARE(spy.count(), 2); diff --git a/test/qt/core/states/test_StateConnectCard.cpp b/test/qt/core/states/test_StateConnectCard.cpp index e9876959b..1e3ec2fe8 100644 --- a/test/qt/core/states/test_StateConnectCard.cpp +++ b/test/qt/core/states/test_StateConnectCard.cpp @@ -1,7 +1,7 @@ /*! * \brief unit tests for \ref StateConnectCard * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateConnectCard.h" diff --git a/test/qt/core/states/test_StateDestroyPace.cpp b/test/qt/core/states/test_StateDestroyPace.cpp index accb763a8..c61162f71 100644 --- a/test/qt/core/states/test_StateDestroyPace.cpp +++ b/test/qt/core/states/test_StateDestroyPace.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateDestroyPace.h" diff --git a/test/qt/core/states/test_StateDidAuthenticateEac1.cpp b/test/qt/core/states/test_StateDidAuthenticateEac1.cpp index a97138a3f..dcc38b298 100644 --- a/test/qt/core/states/test_StateDidAuthenticateEac1.cpp +++ b/test/qt/core/states/test_StateDidAuthenticateEac1.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit test for \ref StateDidAuthenticateEac1 * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateDidAuthenticateEac1.h" diff --git a/test/qt/core/states/test_StateDidAuthenticateEac2.cpp b/test/qt/core/states/test_StateDidAuthenticateEac2.cpp index eb174dba0..5c5ce1169 100644 --- a/test/qt/core/states/test_StateDidAuthenticateEac2.cpp +++ b/test/qt/core/states/test_StateDidAuthenticateEac2.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit test for \ref StateDidAuthenticateEac2 * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateDidAuthenticateEac2.h" diff --git a/test/qt/core/states/test_StateEnterPacePassword.cpp b/test/qt/core/states/test_StateEnterPacePassword.cpp new file mode 100644 index 000000000..cae453581 --- /dev/null +++ b/test/qt/core/states/test_StateEnterPacePassword.cpp @@ -0,0 +1,60 @@ +/*! + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany + */ + +#include "states/StateEnterPacePassword.h" + +#include "TestAuthContext.h" + +#include + +using namespace governikus; + + +class test_StateEnterPacePassword + : public QObject +{ + Q_OBJECT + QSharedPointer mAuthContext; + QSharedPointer mState; + + private Q_SLOTS: + void init() + { + mAuthContext.reset(new TestAuthContext(nullptr, ":/paos/DIDAuthenticateEAC1.xml")); + mState.reset(new StateEnterPacePassword(mAuthContext)); + } + + + void cleanup() + { + mState.clear(); + mAuthContext.clear(); + } + + + void test_Run() + { + QSignalSpy spyContinue(mState.data(), &AbstractState::fireContinue); + + mState->run(); + + QCOMPARE(spyContinue.count(), 1); + } + + + void test_RunContextError() + { + mAuthContext->setStatus(GlobalStatus::Code::Card_Cancellation_By_User); + QSignalSpy spyAbort(mState.data(), &AbstractState::fireAbort); + + mState->run(); + + QCOMPARE(spyAbort.count(), 1); + } + + +}; + +QTEST_GUILESS_MAIN(test_StateEnterPacePassword) +#include "test_StateEnterPacePassword.moc" diff --git a/test/qt/core/states/test_StateEstablishPaceChannel.cpp b/test/qt/core/states/test_StateEstablishPaceChannel.cpp index 89104419c..ac630e2aa 100644 --- a/test/qt/core/states/test_StateEstablishPaceChannel.cpp +++ b/test/qt/core/states/test_StateEstablishPaceChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateEstablishPaceChannel.h" @@ -107,6 +107,30 @@ class test_StateEstablishPaceChannel } + void test_OnContextError() + { + mAuthContext->setStatus(GlobalStatus::Code::Card_Cancellation_By_User); + QSignalSpy spyAbort(mState.data(), &AbstractState::fireAbort); + + mState->run(); + + QCOMPARE(spyAbort.count(), 1); + } + + + void test_OnKillWorkflow() + { + QSignalSpy spyAbort(mState.data(), &AbstractState::fireAbort); + mState->setStateName("StateEstablishPaceChannel"); + mState->onEntry(nullptr); + QCOMPARE(spyAbort.count(), 0); + + mAuthContext->killWorkflow(); + + QCOMPARE(spyAbort.count(), 2); + } + + void test_OnUserCancelled() { const QSharedPointer worker(new MockCardConnectionWorker()); @@ -158,7 +182,7 @@ class test_StateEstablishPaceChannel QFETCH(bool, canAllowed); QSignalSpy spyPaceChannelEstablished(mState.data(), &StateEstablishPaceChannel::firePaceChannelEstablished); - QSignalSpy spyPacePukEstablished(mState.data(), &StateEstablishPaceChannel::firePacePukEstablished); + QSignalSpy spyPaceChannelInoperative(mState.data(), &StateEstablishPaceChannel::firePaceChannelInoperative); QSignalSpy spyAbort(mState.data(), &StateEstablishPaceChannel::fireAbort); QSignalSpy spyContinue(mState.data(), &StateEstablishPaceChannel::fireContinue); @@ -177,7 +201,7 @@ class test_StateEstablishPaceChannel if (code == CardReturnCode::OK && password == PacePasswordId::PACE_PIN) { - QTest::ignoreMessage(QtDebugMsg, "PACE PIN succeeded. Setting expected retry counter to: 3"); + QTest::ignoreMessage(QtDebugMsg, "PACE_PIN succeeded. Setting expected retry counter to: 3"); mState->onEstablishConnectionDone(command); QCOMPARE(mAuthContext->getLastPaceResult(), result); QCOMPARE(mAuthContext->getExpectedRetryCounter(), 3); @@ -201,11 +225,11 @@ class test_StateEstablishPaceChannel if (code == CardReturnCode::OK && password == PacePasswordId::PACE_PUK) { - QTest::ignoreMessage(QtDebugMsg, "PACE PUK succeeded. Resetting PACE passwords and setting expected retry counter to: -1"); + QTest::ignoreMessage(QtDebugMsg, "PACE_PUK succeeded. Resetting PACE passwords and setting expected retry counter to: -1"); mState->onEstablishConnectionDone(command); QCOMPARE(mAuthContext->getLastPaceResult(), result); QCOMPARE(mAuthContext->getExpectedRetryCounter(), -1); - QCOMPARE(spyPacePukEstablished.count(), 1); + QCOMPARE(spyPaceChannelInoperative.count(), 1); return; } @@ -222,7 +246,19 @@ class test_StateEstablishPaceChannel } QCOMPARE(mAuthContext->getLastPaceResult(), result); - QCOMPARE(spyAbort.count(), 1); + if (password == PacePasswordId::PACE_PUK + || mAuthContext->getLastPaceResult() == CardReturnCode::INVALID_PIN + || mAuthContext->getLastPaceResult() == CardReturnCode::INVALID_PIN_2 + || mAuthContext->getLastPaceResult() == CardReturnCode::INVALID_PIN_3) + { + QCOMPARE(spyAbort.count(), 0); + QCOMPARE(spyPaceChannelInoperative.count(), 1); + + } + else + { + QCOMPARE(spyAbort.count(), 1); + } } diff --git a/test/qt/core/states/test_StateEstablishPaceChannelRemote.cpp b/test/qt/core/states/test_StateEstablishPaceChannelRemote.cpp index d5adc46fb..717c3b3a1 100644 --- a/test/qt/core/states/test_StateEstablishPaceChannelRemote.cpp +++ b/test/qt/core/states/test_StateEstablishPaceChannelRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/remote_service/StateEstablishPaceChannelRemote.h" diff --git a/test/qt/core/states/test_StateEstablishPaceChannelResponse.cpp b/test/qt/core/states/test_StateEstablishPaceChannelResponse.cpp index 7b5dd22e9..e47f566d2 100644 --- a/test/qt/core/states/test_StateEstablishPaceChannelResponse.cpp +++ b/test/qt/core/states/test_StateEstablishPaceChannelResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "states/remote_service/StateEstablishPaceChannelResponse.h" @@ -59,7 +59,7 @@ class test_StateEstablishPaceChannelResponse private Q_SLOTS: void initTestCase() { - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { return new MockRemoteServer(); })); } diff --git a/test/qt/core/states/test_StateExtractCvcsFromEac1InputType.cpp b/test/qt/core/states/test_StateExtractCvcsFromEac1InputType.cpp index 9a317d629..1f2716a08 100644 --- a/test/qt/core/states/test_StateExtractCvcsFromEac1InputType.cpp +++ b/test/qt/core/states/test_StateExtractCvcsFromEac1InputType.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests the StateExtractCvcsFromEac1InputType * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateExtractCvcsFromEac1InputType.h" diff --git a/test/qt/core/states/test_StateGenericSendReceive.cpp b/test/qt/core/states/test_StateGenericSendReceive.cpp index 69c790ac5..92b1972cf 100644 --- a/test/qt/core/states/test_StateGenericSendReceive.cpp +++ b/test/qt/core/states/test_StateGenericSendReceive.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "Env.h" diff --git a/test/qt/core/states/test_StateGetSelfAuthenticationData.cpp b/test/qt/core/states/test_StateGetSelfAuthenticationData.cpp index 7acd4f79d..76e12eb52 100644 --- a/test/qt/core/states/test_StateGetSelfAuthenticationData.cpp +++ b/test/qt/core/states/test_StateGetSelfAuthenticationData.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateGetSelfAuthenticationData.h" diff --git a/test/qt/core/states/test_StateGetTcToken.cpp b/test/qt/core/states/test_StateGetTcToken.cpp index 2692cf408..c8df1b595 100644 --- a/test/qt/core/states/test_StateGetTcToken.cpp +++ b/test/qt/core/states/test_StateGetTcToken.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StateGetTcToken * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateGetTcToken.h" @@ -46,7 +46,7 @@ class test_StateGetTcToken const QSharedPointer context(new AuthContext(nullptr)); StateGetTcToken state(context); - QTest::ignoreMessage(QtCriticalMsg, "Error while connecting to the service provider. The server returns an invalid or empty redirect URL."); + QTest::ignoreMessage(QtCriticalMsg, "Error while connecting to the provider. The server returns an invalid or empty redirect URL."); const QUrl emptyUrl; QVERIFY(!state.isValidRedirectUrl(emptyUrl)); diff --git a/test/qt/core/states/test_StateInitializeFramework.cpp b/test/qt/core/states/test_StateInitializeFramework.cpp index fd7fd51fa..554ce1948 100644 --- a/test/qt/core/states/test_StateInitializeFramework.cpp +++ b/test/qt/core/states/test_StateInitializeFramework.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateBuilder.h" diff --git a/test/qt/core/states/test_StateMaintainCardConnection.cpp b/test/qt/core/states/test_StateMaintainCardConnection.cpp index b7815ce9d..2d3937c95 100644 --- a/test/qt/core/states/test_StateMaintainCardConnection.cpp +++ b/test/qt/core/states/test_StateMaintainCardConnection.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateMaintainCardConnection.h" @@ -100,7 +100,7 @@ class test_StateMaintainCardConnection mContext->setPuk(password); mContext->setLastPaceResult(code); - QTest::ignoreMessage(QtDebugMsg, "Reseting all PACE passwords."); + QTest::ignoreMessage(QtDebugMsg, "Resetting all PACE passwords."); QTest::ignoreMessage(QtDebugMsg, "No card connection available."); mState->run(); QCOMPARE(spyNoCardConnection.count(), 1); @@ -110,7 +110,7 @@ class test_StateMaintainCardConnection const QSharedPointer connection(new CardConnection(worker)); mContext->setCardConnection(connection); - QTest::ignoreMessage(QtDebugMsg, "Reseting all PACE passwords."); + QTest::ignoreMessage(QtDebugMsg, "Resetting all PACE passwords."); QTest::ignoreMessage(QtDebugMsg, "Trigger retry counter update."); mState->run(); QCOMPARE(spyUpdateRetryCounter.count(), 1); diff --git a/test/qt/core/states/test_StatePreVerification.cpp b/test/qt/core/states/test_StatePreVerification.cpp index ba3700883..3bdbbc676 100644 --- a/test/qt/core/states/test_StatePreVerification.cpp +++ b/test/qt/core/states/test_StatePreVerification.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StatePreVerification * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StatePreVerification.h" diff --git a/test/qt/core/states/test_StatePreparePace.cpp b/test/qt/core/states/test_StatePreparePace.cpp index a5675b523..14bd36f3f 100644 --- a/test/qt/core/states/test_StatePreparePace.cpp +++ b/test/qt/core/states/test_StatePreparePace.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StatePreparePace * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StatePreparePace.h" @@ -106,7 +106,7 @@ class test_StatePreparePace Q_EMIT worker->fireReaderInfoChanged(readerInfo); QTest::ignoreMessage(QtDebugMsg, "CAN required"); - QTest::ignoreMessage(QtDebugMsg, "PACE CAN done: false"); + QTest::ignoreMessage(QtDebugMsg, "PACE_CAN done: false"); mContext->setStateApproved(); mContext->setStateApproved(false); @@ -114,7 +114,7 @@ class test_StatePreparePace const QString can("000000"); mContext->setCan(can); QTest::ignoreMessage(QtDebugMsg, "CAN required"); - QTest::ignoreMessage(QtDebugMsg, "PACE CAN done: false"); + QTest::ignoreMessage(QtDebugMsg, "PACE_CAN done: false"); mContext->setStateApproved(); QCOMPARE(spyEstablishPaceChannel.count(), 1); } @@ -133,7 +133,7 @@ class test_StatePreparePace QSignalSpy spyEstablishPaceChannel(mState.data(), &StatePreparePace::fireEstablishPaceChannel); QTest::ignoreMessage(QtDebugMsg, "PIN allowed"); - QTest::ignoreMessage(QtDebugMsg, "PACE PIN done: false"); + QTest::ignoreMessage(QtDebugMsg, "PACE_PIN done: false"); mContext->setStateApproved(); QCOMPARE(spyEnterPacePassword.count(), 1); QCOMPARE(spyEstablishPaceChannel.count(), 0); diff --git a/test/qt/core/states/test_StatePreparePaceRemote.cpp b/test/qt/core/states/test_StatePreparePaceRemote.cpp index 52fc12dbf..bb947e6a6 100644 --- a/test/qt/core/states/test_StatePreparePaceRemote.cpp +++ b/test/qt/core/states/test_StatePreparePaceRemote.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "states/remote_service/StatePreparePaceRemote.h" diff --git a/test/qt/core/states/test_StateProcessCertificatesFromEac2.cpp b/test/qt/core/states/test_StateProcessCertificatesFromEac2.cpp index 968fd1666..5ba6a50b9 100644 --- a/test/qt/core/states/test_StateProcessCertificatesFromEac2.cpp +++ b/test/qt/core/states/test_StateProcessCertificatesFromEac2.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StatePreVerification * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateProcessCertificatesFromEac2.h" diff --git a/test/qt/core/states/test_StateProcessRemoteMessages.cpp b/test/qt/core/states/test_StateProcessRemoteMessages.cpp index 43befc19b..2896be45b 100644 --- a/test/qt/core/states/test_StateProcessRemoteMessages.cpp +++ b/test/qt/core/states/test_StateProcessRemoteMessages.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/remote_service/StateProcessRemoteMessages.h" @@ -22,7 +22,7 @@ class test_StateProcessRemoteMessages private Q_SLOTS: void initTestCase() { - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { return new MockRemoteServer(); })); } diff --git a/test/qt/core/states/test_StateRedirectBrowser.cpp b/test/qt/core/states/test_StateRedirectBrowser.cpp index df0108e3a..605cff589 100644 --- a/test/qt/core/states/test_StateRedirectBrowser.cpp +++ b/test/qt/core/states/test_StateRedirectBrowser.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateRedirectBrowser.h" diff --git a/test/qt/core/states/test_StateSelectPasswordId.cpp b/test/qt/core/states/test_StateSelectPasswordId.cpp index c7701991e..af60a93c9 100644 --- a/test/qt/core/states/test_StateSelectPasswordId.cpp +++ b/test/qt/core/states/test_StateSelectPasswordId.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests the StateSelectPasswordId * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateSelectPasswordId.h" diff --git a/test/qt/core/states/test_StateSelectReader.cpp b/test/qt/core/states/test_StateSelectReader.cpp index c52d13eb5..0b7b990e0 100644 --- a/test/qt/core/states/test_StateSelectReader.cpp +++ b/test/qt/core/states/test_StateSelectReader.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests the StateSelectReader * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateSelectReader.h" diff --git a/test/qt/core/states/test_StateSendWhitelistSurvey.cpp b/test/qt/core/states/test_StateSendWhitelistSurvey.cpp index 7ecd6fd14..eb04c1d84 100644 --- a/test/qt/core/states/test_StateSendWhitelistSurvey.cpp +++ b/test/qt/core/states/test_StateSendWhitelistSurvey.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateSendWhitelistSurvey.h" diff --git a/test/qt/core/states/test_StateStartPaosResponse.cpp b/test/qt/core/states/test_StateStartPaosResponse.cpp index e645eaddf..46f62668b 100644 --- a/test/qt/core/states/test_StateStartPaosResponse.cpp +++ b/test/qt/core/states/test_StateStartPaosResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/core/states/test_StateStartRemoteService.cpp b/test/qt/core/states/test_StateStartRemoteService.cpp index dc2dee3d5..64faef64d 100644 --- a/test/qt/core/states/test_StateStartRemoteService.cpp +++ b/test/qt/core/states/test_StateStartRemoteService.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/remote_service/StateStartRemoteService.h" @@ -21,7 +21,7 @@ class test_StateStartRemoteService private Q_SLOTS: void initTestCase() { - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { return new MockRemoteServer(); })); } diff --git a/test/qt/core/states/test_StateStopRemoteService.cpp b/test/qt/core/states/test_StateStopRemoteService.cpp index 570440e45..58f5c9931 100644 --- a/test/qt/core/states/test_StateStopRemoteService.cpp +++ b/test/qt/core/states/test_StateStopRemoteService.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/remote_service/StateStopRemoteService.h" @@ -25,7 +25,7 @@ class test_StateStopRemoteService private Q_SLOTS: void initTestCase() { - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { return new MockRemoteServer(); })); } diff --git a/test/qt/core/states/test_StateTransmit.cpp b/test/qt/core/states/test_StateTransmit.cpp index 3d2238bd2..f7ba4c810 100644 --- a/test/qt/core/states/test_StateTransmit.cpp +++ b/test/qt/core/states/test_StateTransmit.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StateTransmit * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateTransmit.h" diff --git a/test/qt/core/states/test_StateUpdRetryCounter.cpp b/test/qt/core/states/test_StateUpdRetryCounter.cpp index edc23d3ab..47202a0ed 100644 --- a/test/qt/core/states/test_StateUpdRetryCounter.cpp +++ b/test/qt/core/states/test_StateUpdRetryCounter.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StateUpdateRetryCounter * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateUpdateRetryCounter.h" diff --git a/test/qt/core/states/test_StateVerifyRetryCounter.cpp b/test/qt/core/states/test_StateVerifyRetryCounter.cpp index 99f2fc1ab..c2d113ed7 100644 --- a/test/qt/core/states/test_StateVerifyRetryCounter.cpp +++ b/test/qt/core/states/test_StateVerifyRetryCounter.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StateVerifyRetryCounter * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateVerifyRetryCounter.h" diff --git a/test/qt/core/states/test_StateWriteHistory.cpp b/test/qt/core/states/test_StateWriteHistory.cpp index e1b2de9fd..f81f2836e 100644 --- a/test/qt/core/states/test_StateWriteHistory.cpp +++ b/test/qt/core/states/test_StateWriteHistory.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref StateWriteHistory * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "states/StateWriteHistory.h" diff --git a/test/qt/core/states/test_TermsOfUsage.cpp b/test/qt/core/states/test_TermsOfUsage.cpp index 34493d2d5..169794850 100644 --- a/test/qt/core/states/test_TermsOfUsage.cpp +++ b/test/qt/core/states/test_TermsOfUsage.cpp @@ -1,7 +1,7 @@ /*! * \brief Tests the Terms of Usage of CertificateDescription * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "asn1/CertificateDescription.h" diff --git a/test/qt/core/test_CertificateChecker.cpp b/test/qt/core/test_CertificateChecker.cpp index c6107e7f5..0fb7d8c4b 100644 --- a/test/qt/core/test_CertificateChecker.cpp +++ b/test/qt/core/test_CertificateChecker.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CertificateChecker * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "CertificateChecker.h" diff --git a/test/qt/core/test_DiagnosisAntivirusDetection.cpp b/test/qt/core/test_DiagnosisAntivirusDetection.cpp index 2e63a549c..24cc6ac46 100644 --- a/test/qt/core/test_DiagnosisAntivirusDetection.cpp +++ b/test/qt/core/test_DiagnosisAntivirusDetection.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DiagnosisAntivirusDetection * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisAntivirusDetection.h" diff --git a/test/qt/core/test_DiagnosisConnectionTest.cpp b/test/qt/core/test_DiagnosisConnectionTest.cpp index f936f53ca..cdf5121f2 100644 --- a/test/qt/core/test_DiagnosisConnectionTest.cpp +++ b/test/qt/core/test_DiagnosisConnectionTest.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DiagnosisConnectionTest * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisConnectionTest.h" diff --git a/test/qt/core/test_DiagnosisModel.cpp b/test/qt/core/test_DiagnosisModel.cpp index 5ac02312a..d0295e565 100644 --- a/test/qt/core/test_DiagnosisModel.cpp +++ b/test/qt/core/test_DiagnosisModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DiagnosisModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisModel.h" @@ -90,17 +90,18 @@ class test_DiagnosisModel QCOMPARE(mModel->mSections.at(2).second, mModel->mCombinedNetworkSection); QCOMPARE(mModel->mSections.at(3).second, mModel->mCombinedAntivirusFirewallSection); - QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(0)->mTitle, QString("Card reader")); - QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(1)->mContent, QString("Diagnosis is running...")); - QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(2)->mTitle, QString("Paired remote devices")); - QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(4)->mTitle, QString("PC/SC information")); + QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(0)->mTitle, QString("Paired smartphones")); + QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(1)->mContent, QString("No devices paired.")); + QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(2)->mTitle, QString("Card reader")); + QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(3)->mContent, QString("Diagnosis is running...")); + QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(4)->mTitle, QString("PC/SC driver information")); QCOMPARE(mModel->mSections.at(1).second->mContentItems.at(5)->mContent, QString("Diagnosis is running...")); - QCOMPARE(mModel->mSections.at(1).second->mContentItems.mid(0, 2), mModel->mCardReaderSection->mContentItems); - QCOMPARE(mModel->mSections.at(1).second->mContentItems.mid(2, 2), mModel->mRemoteDeviceSection->mContentItems); + QCOMPARE(mModel->mSections.at(1).second->mContentItems.mid(0, 2), mModel->mRemoteDeviceSection->mContentItems); + QCOMPARE(mModel->mSections.at(1).second->mContentItems.mid(2, 2), mModel->mCardReaderSection->mContentItems); QCOMPARE(mModel->mSections.at(1).second->mContentItems.mid(4, 2), mModel->mPcscSection->mContentItems); QCOMPARE(true, verifyOrder(mModel->mSections.at(1).second, - {mModel->mCardReaderSection, mModel->mRemoteDeviceSection, mModel->mPcscSection})); + {mModel->mRemoteDeviceSection, mModel->mCardReaderSection, mModel->mPcscSection})); QCOMPARE(true, verifyOrder(mModel->mSections.at(2).second, {mModel->mNetworkConnectionSection, mModel->mNetworkInterfaceSection})); QCOMPARE(true, verifyOrder(mModel->mSections.at(3).second, @@ -135,8 +136,8 @@ class test_DiagnosisModel QCOMPARE(mModel->mCardReaderSection->mContentItems.at(3)->mContent, QString("Type: Standard / comfort card reader\nCard: unknown type")); QCOMPARE(true, verifyOrder(mModel->mCombinedReaderSection->mContentItems, { - mModel->mCardReaderSection->mContentItems, mModel->mRemoteDeviceSection->mContentItems, + mModel->mCardReaderSection->mContentItems, mModel->mPcscSection->mContentItems})); } @@ -145,18 +146,18 @@ class test_DiagnosisModel { mModel->onRemoteInfosChanged(); QCOMPARE(mModel->mRemoteDeviceSection->mContentItems.size(), 2); - QCOMPARE(mModel->mRemoteDeviceSection->mContentItems.at(0)->mTitle, QString("Paired remote devices")); + QCOMPARE(mModel->mRemoteDeviceSection->mContentItems.at(0)->mTitle, QString("Paired smartphones")); QCOMPARE(mModel->mRemoteDeviceSection->mContentItems.at(1)->mContent, QString("No devices paired.")); QCOMPARE(true, verifyOrder(mModel->mCombinedReaderSection->mContentItems, { - mModel->mCardReaderSection->mContentItems, mModel->mRemoteDeviceSection->mContentItems, + mModel->mCardReaderSection->mContentItems, mModel->mPcscSection->mContentItems})); } void test_OnPcscInfoChanged() { - const QString version("version"); + const QString version("Version"); const DiagnosisContext::ComponentInfo component1(QString("/path/to/component1"), QString("description1"), QString("version1"), QString("vendor1")); const DiagnosisContext::ComponentInfo component2(QString("/path/to/component2"), QString("description2"), QString("version2"), QString("vendor2")); const DiagnosisContext::ComponentInfo driver1(QString("/path/to/driver1"), QString("description1"), QString("version1"), QString("vendor1")); @@ -169,14 +170,14 @@ class test_DiagnosisModel QCOMPARE(mModel->mPcscSection->mContentItems.size(), 4); QCOMPARE(mModel->mPcscSection->mContentItems.at(0)->mTitle, QString("PC/SC information")); - QCOMPARE(mModel->mPcscSection->mContentItems.at(1)->mContent, QString("Version: version")); + QCOMPARE(mModel->mPcscSection->mContentItems.at(1)->mContent, QString("Version")); QCOMPARE(mModel->mPcscSection->mContentItems.at(2)->mTitle, QString("Components")); QCOMPARE(mModel->mPcscSection->mContentItems.at(2)->mContent, QString("description1\nVendor: vendor1\nVersion: version1\nFile path: /path/to/component1\ndescription2\nVendor: vendor2\nVersion: version2\nFile path: /path/to/component2")); QCOMPARE(mModel->mPcscSection->mContentItems.at(3)->mTitle, QString("Driver")); QCOMPARE(mModel->mPcscSection->mContentItems.at(3)->mContent, QString("description1\nVendor: vendor1\nVersion: version1\nFile path: /path/to/driver1\ndescription2\nVendor: vendor2\nVersion: version2\nFile path: /path/to/driver2")); QCOMPARE(true, verifyOrder(mModel->mCombinedReaderSection->mContentItems, { - mModel->mCardReaderSection->mContentItems, mModel->mRemoteDeviceSection->mContentItems, + mModel->mCardReaderSection->mContentItems, mModel->mPcscSection->mContentItems})); } @@ -212,7 +213,7 @@ class test_DiagnosisModel QCOMPARE(mModel->mNetworkInterfaceSection->mContentItems.size(), 3); for (const auto& item : qAsConst(mModel->mNetworkInterfaceSection->mContentItems)) { - QCOMPARE(item->mTitle, QString("Interface: \"\"")); + QCOMPARE(item->mTitle, QString("")); QCOMPARE(item->mContent, QString("Hardware address: \nNo IP addresses assigned")); } diff --git a/test/qt/core/test_DiagnosisTreeModel.cpp b/test/qt/core/test_DiagnosisTreeModel.cpp index 53b9d18e5..2f37af9fb 100644 --- a/test/qt/core/test_DiagnosisTreeModel.cpp +++ b/test/qt/core/test_DiagnosisTreeModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DiagnosisModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "DiagnosisTreeModel.h" diff --git a/test/qt/core/test_SelfAuthenticationData.cpp b/test/qt/core/test_SelfAuthenticationData.cpp index 11d4f6616..39e77819c 100644 --- a/test/qt/core/test_SelfAuthenticationData.cpp +++ b/test/qt/core/test_SelfAuthenticationData.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref SelfAuthenticationData * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "SelfAuthenticationData.h" diff --git a/test/qt/core/test_TcToken.cpp b/test/qt/core/test_TcToken.cpp index cc820dfd7..df12dd85b 100644 --- a/test/qt/core/test_TcToken.cpp +++ b/test/qt/core/test_TcToken.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref TcToken * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "TcToken.h" diff --git a/test/qt/export/test_PdfExporter.cpp b/test/qt/export/test_PdfExporter.cpp index e103e759f..0cb6d3eb1 100644 --- a/test/qt/export/test_PdfExporter.cpp +++ b/test/qt/export/test_PdfExporter.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PdfExporter * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "PdfExporter.h" @@ -14,9 +14,9 @@ using namespace governikus; -Q_DECLARE_METATYPE(QVector ) +Q_DECLARE_METATYPE(QVector) using Pair = QPair; -Q_DECLARE_METATYPE(QVector ) +Q_DECLARE_METATYPE(QVector) class test_PdfExporter : public QObject diff --git a/test/qt/file_provider/test_Downloader.cpp b/test/qt/file_provider/test_Downloader.cpp index 2ad3505c0..5d509d50f 100644 --- a/test/qt/file_provider/test_Downloader.cpp +++ b/test/qt/file_provider/test_Downloader.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for class \ref Downloader * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "Downloader.h" diff --git a/test/qt/file_provider/test_FileProvider.cpp b/test/qt/file_provider/test_FileProvider.cpp index ddcf126f4..bcc0f5f57 100644 --- a/test/qt/file_provider/test_FileProvider.cpp +++ b/test/qt/file_provider/test_FileProvider.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "FileProvider.h" diff --git a/test/qt/file_provider/test_UpdatableFile.cpp b/test/qt/file_provider/test_UpdatableFile.cpp index 5025678ee..181671f6f 100644 --- a/test/qt/file_provider/test_UpdatableFile.cpp +++ b/test/qt/file_provider/test_UpdatableFile.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "UpdatableFile.h" diff --git a/test/qt/global/test_BuildHelper.cpp b/test/qt/global/test_BuildHelper.cpp index 2006f3ba4..0251dd1b6 100644 --- a/test/qt/global/test_BuildHelper.cpp +++ b/test/qt/global/test_BuildHelper.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref BuildHelper * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "BuildHelper.h" diff --git a/test/qt/global/test_CardReturnCode.cpp b/test/qt/global/test_CardReturnCode.cpp index cfde5f1e9..dc52cf205 100644 --- a/test/qt/global/test_CardReturnCode.cpp +++ b/test/qt/global/test_CardReturnCode.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for return codes. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CardReturnCode.h" @@ -23,7 +23,7 @@ class test_CardReturnCode void check_errorCodeToMessage() { QCOMPARE(CardReturnCodeUtil::toGlobalStatus(CardReturnCode::CANCELLATION_BY_USER).toErrorDescription(), - QString("The process was cancelled by the user.")); + QString("The process has been cancelled.")); } @@ -37,7 +37,7 @@ class test_CardReturnCode { const ECardApiResult& result = ECardApiResult(CardReturnCodeUtil::toGlobalStatus(CardReturnCode::CANCELLATION_BY_USER)); QCOMPARE(result.getMinor(), ECardApiResult::Minor::SAL_Cancellation_by_User); - QCOMPARE(result.getMessage(), QString("The process was cancelled by the user.")); + QCOMPARE(result.getMessage(), QString("The process has been cancelled.")); } diff --git a/test/qt/global/test_DeviceInfo.cpp b/test/qt/global/test_DeviceInfo.cpp index 2785dafd8..bdd293a6c 100644 --- a/test/qt/global/test_DeviceInfo.cpp +++ b/test/qt/global/test_DeviceInfo.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DeviceInfo * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/global/test_ECardApiResult.cpp b/test/qt/global/test_ECardApiResult.cpp index 84c91f16f..d8df4e67f 100644 --- a/test/qt/global/test_ECardApiResult.cpp +++ b/test/qt/global/test_ECardApiResult.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "CardReturnCode.h" @@ -97,7 +97,7 @@ class test_ECardApiResult qDebug() << ECardApiResult(CardReturnCodeUtil::toGlobalStatus(CardReturnCode::CANCELLATION_BY_USER)); QCOMPARE(spy.count(), 1); param = spy.takeFirst(); - QVERIFY(param.at(0).toString().contains("Result: \"http://www.bsi.bund.de/ecard/api/1.1/resultmajor#error | http://www.bsi.bund.de/ecard/api/1.1/resultminor/sal#cancellationByUser | The process was cancelled by the user.\"")); + QVERIFY(param.at(0).toString().contains("Result: \"http://www.bsi.bund.de/ecard/api/1.1/resultmajor#error | http://www.bsi.bund.de/ecard/api/1.1/resultminor/sal#cancellationByUser | The process has been cancelled.\"")); spy.clear(); @@ -122,9 +122,9 @@ class test_ECardApiResult expected = "{\"major\":\"http://www.bsi.bund.de/ecard/api/1.1/resultmajor#ok\"}"; QCOMPARE(bytes(ECardApiResult::createOk().toJson()), expected); - expected = "{\"description\":\"The process was cancelled by the user.\"," + expected = "{\"description\":\"The process has been cancelled.\"," "\"language\":\"en\",\"major\":\"http://www.bsi.bund.de/ecard/api/1.1/resultmajor#error\"," - "\"message\":\"The process was cancelled by the user.\"," + "\"message\":\"The process has been cancelled.\"," "\"minor\":\"http://www.bsi.bund.de/ecard/api/1.1/resultminor/sal#cancellationByUser\"}"; QCOMPARE(bytes(ECardApiResult(CardReturnCodeUtil::toGlobalStatus(CardReturnCode::CANCELLATION_BY_USER)).toJson()), expected); @@ -303,9 +303,9 @@ class test_ECardApiResult QTest::newRow("repeatedDataMismatch") << ECardApiResult::Minor::IFDL_IO_RepeatedDataMismatch << tr("The new PIN and the confirmation do not match."); QTest::newRow("unknownPinFormat") << ECardApiResult::Minor::IFDL_IO_UnknownPINFormat << tr("The format of the PIN is wrong."); QTest::newRow("keyGenerationNotPossible") << ECardApiResult::Minor::KEY_KeyGenerationNotPossible << tr("Signature certificate key generation is not possible."); - QTest::newRow("cancellationByUser") << ECardApiResult::Minor::SAL_Cancellation_by_User << tr("The process was cancelled by the user."); + QTest::newRow("cancellationByUser") << ECardApiResult::Minor::SAL_Cancellation_by_User << tr("The process has been cancelled."); QTest::newRow("invalidCertificatePath") << ECardApiResult::Minor::IL_Signature_InvalidCertificatePath << tr("One or more certificate checks failed. The operation will be aborted due to security reasons."); - QTest::newRow("invalidKey") << ECardApiResult::Minor::SAL_Invalid_Key << tr("This action cannot be performed. The online identification function of your ID card is deactivated. Please contact the authority responsible for issuing your identification document to activate the online identification function."); + QTest::newRow("invalidKey") << ECardApiResult::Minor::SAL_Invalid_Key << tr("This action cannot be performed. The online identification function of your ID card is not activated. Please contact the authority responsible for issuing your identification card to activate the online identification function."); QTest::newRow("securityConditionNotSatisfied") << ECardApiResult::Minor::SAL_SecurityConditionNotSatisfied << tr("The authenticity of your ID card could not be verified. Please make sure that you are using a genuine ID card. Please note that test applications require the use of a test ID card."); QTest::newRow("ageVerificationFailed") << ECardApiResult::Minor::SAL_MEAC_AgeVerificationFailedWarning << tr("The age verification failed."); QTest::newRow("comunityVerificationFailed") << ECardApiResult::Minor::SAL_MEAC_CommunityVerificationFailedWarning << tr("The community verification failed."); diff --git a/test/qt/global/test_EnumHelper.cpp b/test/qt/global/test_EnumHelper.cpp index 43d0160a5..2b81689ac 100644 --- a/test/qt/global/test_EnumHelper.cpp +++ b/test/qt/global/test_EnumHelper.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for EnumHelper. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "EnumHelper.h" diff --git a/test/qt/global/test_Env.cpp b/test/qt/global/test_Env.cpp index ce4a0ee1f..f3de80faf 100644 --- a/test/qt/global/test_Env.cpp +++ b/test/qt/global/test_Env.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Env * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "Env.h" @@ -222,7 +222,7 @@ class TestSingleInCtor } // namespace -Q_DECLARE_METATYPE(std::function ) +Q_DECLARE_METATYPE(std::function) namespace governikus { @@ -312,7 +312,7 @@ class test_Env QScopedPointer obj(Env::create()); QVERIFY(obj); - const std::function func = [](){ + const std::function func = [](){ return nullptr; }; Env::setCreator(func); @@ -381,7 +381,7 @@ class test_Env QVERIFY(mock == mocked); QVERIFY(orig != mocked); - Env::setShared(TestSharedInstance::staticMetaObject); + Env::setShared(TestSharedInstance::staticMetaObject, {}); auto orig3 = Env::getShared(); QVERIFY(orig != orig3); QCOMPARE(orig3->something(), QLatin1String("orig")); @@ -407,7 +407,7 @@ class test_Env QCOMPARE(implOrig->dummy(), QLatin1String("impl")); implOrig.reset(); - std::function func = [](){ + std::function func = [](){ class tmp : public AbstractTestInstanceImpl { @@ -441,7 +441,7 @@ class test_Env QCOMPARE(impl->dummy(), QLatin1String("flupp")); impl.reset(); - std::function funcString = [](const QString& pStr){ + std::function funcString = [](const QString& pStr){ class tmp : public AbstractTestPodInstance { @@ -463,7 +463,7 @@ class test_Env return new tmp(pStr); }; - std::function funcDefault = [](){ + std::function funcDefault = [](){ class tmp : public AbstractTestPodInstance { diff --git a/test/qt/global/test_FileDestination.cpp b/test/qt/global/test_FileDestination.cpp index 478eaba2f..b2892180d 100644 --- a/test/qt/global/test_FileDestination.cpp +++ b/test/qt/global/test_FileDestination.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref FileDestination * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "FileDestination.h" diff --git a/test/qt/global/test_FuncUtils.cpp b/test/qt/global/test_FuncUtils.cpp index a36f2ed5e..d4d5fce84 100644 --- a/test/qt/global/test_FuncUtils.cpp +++ b/test/qt/global/test_FuncUtils.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref FuncUtils * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "FuncUtils.h" diff --git a/test/qt/global/test_GlobalStatus.cpp b/test/qt/global/test_GlobalStatus.cpp index 74d0cd331..67bcbc37b 100644 --- a/test/qt/global/test_GlobalStatus.cpp +++ b/test/qt/global/test_GlobalStatus.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref GlobalStatus. * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "GlobalStatus.h" @@ -45,11 +45,10 @@ class test_GlobalStatus QTest::addColumn("code"); QTest::addColumn("message"); - QTest::newRow("inProgress") << GlobalStatus::Code::Workflow_AlreadyInProgress_Error << tr("Cannot start authentication. An operation is already in progress."); + QTest::newRow("inProgress") << GlobalStatus::Code::Workflow_AlreadyInProgress_Error << tr("Cannot start authentication. An operation is already active."); QTest::newRow("cardRemoved") << GlobalStatus::Code::Workflow_Card_Removed << tr("The connection to the ID card has been lost. The process was aborted."); QTest::newRow("unknownPaos") << GlobalStatus::Code::Workflow_Unknown_Paos_From_EidServer << tr("The program received an unknown message from the server."); QTest::newRow("unexpectedMessage") << GlobalStatus::Code::Workflow_Unexpected_Message_From_EidServer << tr("The program received an unexpected message from the server."); - QTest::newRow("pinBlocked") << GlobalStatus::Code::Workflow_Pin_Blocked_And_Puk_Objectionable << tr("After three wrong entries your PIN is blocked. Please use the PIN management in this app to unblock it with the help of your PUK."); QTest::newRow("preverificationDevelopermode") << GlobalStatus::Code::Workflow_Preverification_Developermode_Error << tr("Using the developer mode is only allowed in a test environment."); QTest::newRow("noUniqueAtCvc") << GlobalStatus::Code::Workflow_No_Unique_AtCvc << tr("No unique AT CVC"); QTest::newRow("noUniqueDvCvc") << GlobalStatus::Code::Workflow_No_Unique_DvCvc << tr("No unique DV CVC"); @@ -60,14 +59,14 @@ class test_GlobalStatus QTest::newRow("certificateSop") << GlobalStatus::Code::Workflow_Certificate_Sop_Error << tr("The subject URL in the certificate description and the TCToken URL don't satisfy the same origin policy."); QTest::newRow("wrongParameter") << GlobalStatus::Code::Workflow_Wrong_Parameter_Invocation << tr("Application was invoked with wrong parameters."); QTest::newRow("incompleteInformation") << GlobalStatus::Code::Workflow_Server_Incomplete_Information_Provided << tr("The server provided no or incomplete information. Your personal data could not be read out."); - QTest::newRow("deviceConnection") << GlobalStatus::Code::Workflow_Bluetooth_Reader_Connection_Error << tr("An error occurred while connecting to a reader device."); - QTest::newRow("deviceScan") << GlobalStatus::Code::Workflow_Reader_Device_Scan_Error << tr("An error occurred while scanning for reader devices."); - QTest::newRow("abnormalClose") << GlobalStatus::Code::RemoteReader_CloseCode_AbnormalClose << tr("The remote card reader connection was not closed properly."); - QTest::newRow("invalidRequest") << GlobalStatus::Code::RemoteConnector_InvalidRequest << tr("Remote reader connection request contains invalid parameters."); - QTest::newRow("noSupportedApiLevel") << GlobalStatus::Code::RemoteConnector_NoSupportedApiLevel << tr("Your remote reader version is incompatible with the local version. Please install the latest AusweisApp2 version on both your smartphone and your computer."); - QTest::newRow("connectionTimeout") << GlobalStatus::Code::RemoteConnector_ConnectionTimeout << tr("A timeout occurred while trying to establish a connection to a remote reader."); - QTest::newRow("connectionError") << GlobalStatus::Code::RemoteConnector_ConnectionError << tr("An error occurred while trying to establish a connection to a remote reader."); - QTest::newRow("hostRefused") << GlobalStatus::Code::RemoteConnector_RemoteHostRefusedConnection << tr("Remote device has rejected the connection. Please check the pairing code."); + QTest::newRow("deviceConnection") << GlobalStatus::Code::Workflow_Bluetooth_Reader_Connection_Error << tr("An error occurred while connecting to a bluetooth card reader."); + QTest::newRow("deviceScan") << GlobalStatus::Code::Workflow_Reader_Device_Scan_Error << tr("An error occurred while scanning for a bluetooth card reader."); + QTest::newRow("abnormalClose") << GlobalStatus::Code::RemoteReader_CloseCode_AbnormalClose << tr("The smartphone as card reader (SaC) connection was aborted."); + QTest::newRow("invalidRequest") << GlobalStatus::Code::RemoteConnector_InvalidRequest << tr("Smartphone as card reader (SaC) connection request was invalid."); + QTest::newRow("noSupportedApiLevel") << GlobalStatus::Code::RemoteConnector_NoSupportedApiLevel << tr("Your smartphone as card reader (SaC) version is incompatible with the local version. Please install the latest AusweisApp2 version on both your smartphone and your computer."); + QTest::newRow("connectionTimeout") << GlobalStatus::Code::RemoteConnector_ConnectionTimeout << tr("A timeout occurred while trying to establish a connection to the smartphone as card reader (SaC)."); + QTest::newRow("connectionError") << GlobalStatus::Code::RemoteConnector_ConnectionError << tr("An error occurred while trying to establish a connection to the smartphone as card reader (SaC)."); + QTest::newRow("hostRefused") << GlobalStatus::Code::RemoteConnector_RemoteHostRefusedConnection << tr("The smartphone to be paired has rejected the connection. Please check the pairing code. If no pairing code is shown activate the pairing mode."); QTest::newRow("cannotSaveFile") << GlobalStatus::Code::Downloader_Cannot_Save_File << tr("Cannot save file."); QTest::newRow("dataCorrupted") << GlobalStatus::Code::Downloader_Data_Corrupted << tr("Received data were corrupted."); } diff --git a/test/qt/global/test_Initializer.cpp b/test/qt/global/test_Initializer.cpp index 2c0a400b6..6329aae22 100644 --- a/test/qt/global/test_Initializer.cpp +++ b/test/qt/global/test_Initializer.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Initializer * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "Initializer.h" diff --git a/test/qt/global/test_LanguageLoader.cpp b/test/qt/global/test_LanguageLoader.cpp index 1dea6b627..d1c109ecf 100644 --- a/test/qt/global/test_LanguageLoader.cpp +++ b/test/qt/global/test_LanguageLoader.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref LanguageLoader * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "LanguageLoader.h" diff --git a/test/qt/global/test_LogHandler.cpp b/test/qt/global/test_LogHandler.cpp index 4cb22d2b8..54dc9fe9d 100644 --- a/test/qt/global/test_LogHandler.cpp +++ b/test/qt/global/test_LogHandler.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref LogHandler * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "LogHandler.h" @@ -232,6 +232,23 @@ class test_LogHandler } + void handleMessage() + { + QSignalSpy logSpy(Env::getSingleton(), &LogHandler::fireLog); + const auto& logger = Env::getSingleton(); + + QMessageLogContext logContext1("/src/ui/qml/ApplicationModel.cpp", 411, "bool ApplicationModel::isScreenReaderRunning()", "ui"); + logger->handleMessage(QtMsgType::QtDebugMsg, logContext1, "testMessage"); + QCOMPARE(logSpy.count(), 1); + QVERIFY(logSpy.takeFirst().at(0).toString().contains("ApplicationModel::isScreenReaderRunning(ui/qml/ApplicationModel.cpp:411) : testMessage")); + + QMessageLogContext logContext2("/src/ui/qml/ApplicationModel.cpp", 411, "bool ApplicationModel::isScreenReaderRunning() const", "ui"); + logger->handleMessage(QtMsgType::QtDebugMsg, logContext2, "testMessage2"); + QCOMPARE(logSpy.count(), 1); + QVERIFY(logSpy.takeFirst().at(0).toString().contains("ApplicationModel::isScreenReaderRunning(ui/qml/ApplicationModel.cpp:411) : testMessage2")); + } + + void removeUpMultipleOldLogfilesWithInit() { #ifdef Q_OS_WIN diff --git a/test/qt/global/test_Randomizer.cpp b/test/qt/global/test_Randomizer.cpp index 5c610bd41..4bf10ef42 100644 --- a/test/qt/global/test_Randomizer.cpp +++ b/test/qt/global/test_Randomizer.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref Randomizer * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "Randomizer.h" diff --git a/test/qt/global/test_ResourceLoader.cpp b/test/qt/global/test_ResourceLoader.cpp index 2514c7c9e..63c18b7d4 100644 --- a/test/qt/global/test_ResourceLoader.cpp +++ b/test/qt/global/test_ResourceLoader.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ResourceLoader * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ResourceLoader.h" @@ -42,8 +42,8 @@ class test_ResourceLoader ResourceLoader::getInstance().init(); QVERIFY(ResourceLoader::getInstance().isLoaded()); - QCOMPARE(spy.count(), 1); - auto param = spy.takeAt(0); + QVERIFY(spy.count() > 0); + auto param = spy.takeLast(); QVERIFY(param.at(0).toString().contains("Register resource: ")); QVERIFY(param.at(0).toString().contains(" | true")); } @@ -59,8 +59,8 @@ class test_ResourceLoader ResourceLoader::getInstance().shutdown(); QVERIFY(!ResourceLoader::getInstance().isLoaded()); - QCOMPARE(spy.count(), 2); - auto param = spy.takeAt(1); + QVERIFY(spy.count() > 1); + auto param = spy.takeLast(); QVERIFY(param.at(0).toString().contains("Unregister resource: ")); QVERIFY(param.at(0).toString().contains(" | true")); } @@ -72,7 +72,7 @@ class test_ResourceLoader ResourceLoader::getInstance().init(); QVERIFY(!QFile(":/non_existing_dummy_test").exists()); - QVERIFY(QFile(":/images/ausweis.png").exists()); + QVERIFY(QFile(":/images/ausweis.svg").exists()); } diff --git a/test/qt/global/test_ScopeGuard.cpp b/test/qt/global/test_ScopeGuard.cpp index 63fe4580d..cbaa8489f 100644 --- a/test/qt/global/test_ScopeGuard.cpp +++ b/test/qt/global/test_ScopeGuard.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ScopeGuard * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ScopeGuard.h" diff --git a/test/qt/global/test_VersionInfo.cpp b/test/qt/global/test_VersionInfo.cpp index 75452eb8c..423cffd7c 100644 --- a/test/qt/global/test_VersionInfo.cpp +++ b/test/qt/global/test_VersionInfo.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/global/test_VersionNumber.cpp b/test/qt/global/test_VersionNumber.cpp index 7a3d9fbec..a0be03562 100644 --- a/test/qt/global/test_VersionNumber.cpp +++ b/test/qt/global/test_VersionNumber.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref VersionNumber. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "VersionNumber.h" diff --git a/test/qt/network/test_DatagramHandlerImpl.cpp b/test/qt/network/test_DatagramHandlerImpl.cpp index abc0adc2f..2f59a1ef2 100644 --- a/test/qt/network/test_DatagramHandlerImpl.cpp +++ b/test/qt/network/test_DatagramHandlerImpl.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref DatagramHandlerImpl * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "DatagramHandlerImpl.h" diff --git a/test/qt/network/test_HttpRequest.cpp b/test/qt/network/test_HttpRequest.cpp index 74f697e85..8bfadb024 100644 --- a/test/qt/network/test_HttpRequest.cpp +++ b/test/qt/network/test_HttpRequest.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref HttpResponse * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "HttpRequest.h" diff --git a/test/qt/network/test_HttpResponse.cpp b/test/qt/network/test_HttpResponse.cpp index 6c61988fd..793571456 100644 --- a/test/qt/network/test_HttpResponse.cpp +++ b/test/qt/network/test_HttpResponse.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref HttpResponse * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "HttpResponse.h" diff --git a/test/qt/network/test_HttpServer.cpp b/test/qt/network/test_HttpServer.cpp index e22b2cc4b..e699f5ed8 100644 --- a/test/qt/network/test_HttpServer.cpp +++ b/test/qt/network/test_HttpServer.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref HttpResponse * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "HttpServer.h" diff --git a/test/qt/network/test_NetworkManager.cpp b/test/qt/network/test_NetworkManager.cpp index 6f3ce4352..bdbf1c2fc 100644 --- a/test/qt/network/test_NetworkManager.cpp +++ b/test/qt/network/test_NetworkManager.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref NetworkManager * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "NetworkManager.h" @@ -21,7 +21,7 @@ using namespace governikus; -Q_DECLARE_METATYPE(QSharedPointer ) +Q_DECLARE_METATYPE(QSharedPointer) class test_NetworkManager : public QObject diff --git a/test/qt/network/test_PortFile.cpp b/test/qt/network/test_PortFile.cpp index 291fe3255..ecbf7d5d5 100644 --- a/test/qt/network/test_PortFile.cpp +++ b/test/qt/network/test_PortFile.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PortFile * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "PortFile.h" diff --git a/test/qt/network/test_TlsChecker.cpp b/test/qt/network/test_TlsChecker.cpp index cd21a6185..2b62fe7b5 100644 --- a/test/qt/network/test_TlsChecker.cpp +++ b/test/qt/network/test_TlsChecker.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CertificateChecker * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "TlsChecker.h" diff --git a/test/qt/network/test_UrlUtil.cpp b/test/qt/network/test_UrlUtil.cpp index 2f8feaa36..60f7f3f50 100644 --- a/test/qt/network/test_UrlUtil.cpp +++ b/test/qt/network/test_UrlUtil.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref UrlUtil * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "UrlUtil.h" diff --git a/test/qt/network/test_WifiInfo.cpp b/test/qt/network/test_WifiInfo.cpp index 9d2544550..f503438e1 100644 --- a/test/qt/network/test_WifiInfo.cpp +++ b/test/qt/network/test_WifiInfo.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref WifiInfo * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "WifiInfo.h" @@ -45,7 +45,7 @@ class test_WifiInfo QTest::newRow("governikus") << QHostAddress("194.31.70.66") << false; QTest::newRow("telekom") << QHostAddress("91.39.48.2") << false; QTest::newRow("vodafone mobile") << QHostAddress("100.90.174.1") << false; - QTest::newRow("service provider") << QHostAddress("100.64.0.0") << false; + QTest::newRow("provider") << QHostAddress("100.64.0.0") << false; } diff --git a/test/qt/remote_device/messages/test_Discovery.cpp b/test/qt/remote_device/messages/test_Discovery.cpp index b42653a3b..d6507baf6 100644 --- a/test/qt/remote_device/messages/test_Discovery.cpp +++ b/test/qt/remote_device/messages/test_Discovery.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/Discovery.h" diff --git a/test/qt/remote_device/messages/test_IfdConnect.cpp b/test/qt/remote_device/messages/test_IfdConnect.cpp index fdca65858..efb5206a8 100644 --- a/test/qt/remote_device/messages/test_IfdConnect.cpp +++ b/test/qt/remote_device/messages/test_IfdConnect.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdConnect.h" diff --git a/test/qt/remote_device/messages/test_IfdConnectResponse.cpp b/test/qt/remote_device/messages/test_IfdConnectResponse.cpp index 216aa7524..0bee06702 100644 --- a/test/qt/remote_device/messages/test_IfdConnectResponse.cpp +++ b/test/qt/remote_device/messages/test_IfdConnectResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdConnectResponse.h" diff --git a/test/qt/remote_device/messages/test_IfdDisconnect.cpp b/test/qt/remote_device/messages/test_IfdDisconnect.cpp index 13849edec..4a830ccf0 100644 --- a/test/qt/remote_device/messages/test_IfdDisconnect.cpp +++ b/test/qt/remote_device/messages/test_IfdDisconnect.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdDisconnect.h" diff --git a/test/qt/remote_device/messages/test_IfdDisconnectResponse.cpp b/test/qt/remote_device/messages/test_IfdDisconnectResponse.cpp index afc034b18..c62c17fce 100644 --- a/test/qt/remote_device/messages/test_IfdDisconnectResponse.cpp +++ b/test/qt/remote_device/messages/test_IfdDisconnectResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdDisconnectResponse.h" diff --git a/test/qt/remote_device/messages/test_IfdError.cpp b/test/qt/remote_device/messages/test_IfdError.cpp index d65cefa07..7b88dc470 100644 --- a/test/qt/remote_device/messages/test_IfdError.cpp +++ b/test/qt/remote_device/messages/test_IfdError.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdError.h" diff --git a/test/qt/remote_device/messages/test_IfdEstablishContext.cpp b/test/qt/remote_device/messages/test_IfdEstablishContext.cpp index a4cd10545..aaeca6fa3 100644 --- a/test/qt/remote_device/messages/test_IfdEstablishContext.cpp +++ b/test/qt/remote_device/messages/test_IfdEstablishContext.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdEstablishContext.h" diff --git a/test/qt/remote_device/messages/test_IfdEstablishContextResponse.cpp b/test/qt/remote_device/messages/test_IfdEstablishContextResponse.cpp index d18c30d78..5bd9426bf 100644 --- a/test/qt/remote_device/messages/test_IfdEstablishContextResponse.cpp +++ b/test/qt/remote_device/messages/test_IfdEstablishContextResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdEstablishContextResponse.h" diff --git a/test/qt/remote_device/messages/test_IfdEstablishPaceChannel.cpp b/test/qt/remote_device/messages/test_IfdEstablishPaceChannel.cpp index 6137456a1..97fc7e39e 100644 --- a/test/qt/remote_device/messages/test_IfdEstablishPaceChannel.cpp +++ b/test/qt/remote_device/messages/test_IfdEstablishPaceChannel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdEstablishPaceChannel.h" diff --git a/test/qt/remote_device/messages/test_IfdEstablishPaceChannelResponse.cpp b/test/qt/remote_device/messages/test_IfdEstablishPaceChannelResponse.cpp index 0d710f88a..f5cd4555b 100644 --- a/test/qt/remote_device/messages/test_IfdEstablishPaceChannelResponse.cpp +++ b/test/qt/remote_device/messages/test_IfdEstablishPaceChannelResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdEstablishPaceChannelResponse.h" diff --git a/test/qt/remote_device/messages/test_IfdGetStatus.cpp b/test/qt/remote_device/messages/test_IfdGetStatus.cpp index 178d7cead..bf2ca87d7 100644 --- a/test/qt/remote_device/messages/test_IfdGetStatus.cpp +++ b/test/qt/remote_device/messages/test_IfdGetStatus.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdGetStatus.h" diff --git a/test/qt/remote_device/messages/test_IfdModifyPin.cpp b/test/qt/remote_device/messages/test_IfdModifyPin.cpp index ae84b3146..8dd05cddc 100644 --- a/test/qt/remote_device/messages/test_IfdModifyPin.cpp +++ b/test/qt/remote_device/messages/test_IfdModifyPin.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdModifyPin.h" diff --git a/test/qt/remote_device/messages/test_IfdModifyPinResponse.cpp b/test/qt/remote_device/messages/test_IfdModifyPinResponse.cpp index 474f9ddc0..7e0db357c 100644 --- a/test/qt/remote_device/messages/test_IfdModifyPinResponse.cpp +++ b/test/qt/remote_device/messages/test_IfdModifyPinResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdModifyPinResponse.h" diff --git a/test/qt/remote_device/messages/test_IfdStatus.cpp b/test/qt/remote_device/messages/test_IfdStatus.cpp index 2f9669eb8..f5bfedb53 100644 --- a/test/qt/remote_device/messages/test_IfdStatus.cpp +++ b/test/qt/remote_device/messages/test_IfdStatus.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdStatus.h" diff --git a/test/qt/remote_device/messages/test_IfdTransmit.cpp b/test/qt/remote_device/messages/test_IfdTransmit.cpp index ad9ae9da6..875f36940 100644 --- a/test/qt/remote_device/messages/test_IfdTransmit.cpp +++ b/test/qt/remote_device/messages/test_IfdTransmit.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdTransmit.h" diff --git a/test/qt/remote_device/messages/test_IfdTransmitResponse.cpp b/test/qt/remote_device/messages/test_IfdTransmitResponse.cpp index 7bc383597..73b93d2b4 100644 --- a/test/qt/remote_device/messages/test_IfdTransmitResponse.cpp +++ b/test/qt/remote_device/messages/test_IfdTransmitResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdTransmitResponse.h" diff --git a/test/qt/remote_device/messages/test_IfdVersion.cpp b/test/qt/remote_device/messages/test_IfdVersion.cpp index 46d4358b4..fe8632215 100644 --- a/test/qt/remote_device/messages/test_IfdVersion.cpp +++ b/test/qt/remote_device/messages/test_IfdVersion.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/IfdVersion.h" diff --git a/test/qt/remote_device/messages/test_RemoteMessage.cpp b/test/qt/remote_device/messages/test_RemoteMessage.cpp index 8ef18c36d..a5cd0d0e4 100644 --- a/test/qt/remote_device/messages/test_RemoteMessage.cpp +++ b/test/qt/remote_device/messages/test_RemoteMessage.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/RemoteMessage.h" diff --git a/test/qt/remote_device/messages/test_RemoteMessageResponse.cpp b/test/qt/remote_device/messages/test_RemoteMessageResponse.cpp index 04e54d85c..e4b9c7c35 100644 --- a/test/qt/remote_device/messages/test_RemoteMessageResponse.cpp +++ b/test/qt/remote_device/messages/test_RemoteMessageResponse.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/RemoteMessageResponse.h" diff --git a/test/qt/remote_device/test_RemoteClientImpl.cpp b/test/qt/remote_device/test_RemoteClientImpl.cpp index 491225cce..a8f24acf6 100644 --- a/test/qt/remote_device/test_RemoteClientImpl.cpp +++ b/test/qt/remote_device/test_RemoteClientImpl.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteClientImpl.h" @@ -119,17 +119,17 @@ class test_RemoteClient void init() { - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { mDatagramHandlerMock = new DatagramHandlerMock; return mDatagramHandlerMock; })); - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { mRemoteDeviceListMock = new RemoteDeviceListMock(0, 0); return mRemoteDeviceListMock; })); - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { mRemoteConnectorMock = new RemoteConnectorMock; return mRemoteConnectorMock; })); diff --git a/test/qt/remote_device/test_RemoteConnector.cpp b/test/qt/remote_device/test_RemoteConnector.cpp index 809272ca7..fb89d408b 100644 --- a/test/qt/remote_device/test_RemoteConnector.cpp +++ b/test/qt/remote_device/test_RemoteConnector.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RemoteConnector * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteConnectorImpl.h" @@ -22,7 +22,7 @@ using namespace governikus; Q_DECLARE_METATYPE(RemoteDeviceDescriptor) -Q_DECLARE_METATYPE(QSharedPointer ) +Q_DECLARE_METATYPE(QSharedPointer) Q_DECLARE_METATYPE(RemoteErrorCode) diff --git a/test/qt/remote_device/test_RemoteDeviceDescriptor.cpp b/test/qt/remote_device/test_RemoteDeviceDescriptor.cpp index 51ce93739..ee8c7cd2b 100644 --- a/test/qt/remote_device/test_RemoteDeviceDescriptor.cpp +++ b/test/qt/remote_device/test_RemoteDeviceDescriptor.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDeviceDescriptor.h" diff --git a/test/qt/remote_device/test_RemoteDeviceListImpl.cpp b/test/qt/remote_device/test_RemoteDeviceListImpl.cpp index e01fe7195..39e84c82e 100644 --- a/test/qt/remote_device/test_RemoteDeviceListImpl.cpp +++ b/test/qt/remote_device/test_RemoteDeviceListImpl.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDeviceList.h" diff --git a/test/qt/remote_device/test_RemoteDeviceModel.cpp b/test/qt/remote_device/test_RemoteDeviceModel.cpp index 3292f245b..95760ba90 100644 --- a/test/qt/remote_device/test_RemoteDeviceModel.cpp +++ b/test/qt/remote_device/test_RemoteDeviceModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDeviceModel.h" @@ -221,7 +221,7 @@ class test_RemoteDeviceModel QVector readers; QSharedPointer listEntry(new RemoteDeviceListEntry(RemoteDeviceDescriptor())); - const RemoteDeviceModelEntry entry1(QString("reader 1"), QString("test id"), true, true, true, QDateTime(QDate(2019, 5, 14), QTime(0, 0)), listEntry); + const RemoteDeviceModelEntry entry1(QString("reader 1"), QString("test id"), true, false, true, QDateTime(QDate(2019, 5, 14), QTime(0, 0)), listEntry); const RemoteDeviceModelEntry entry2(QString("reader 2")); readers << entry1 << entry2; mModel->mAllRemoteReaders = readers; diff --git a/test/qt/remote_device/test_RemoteDisp.cpp b/test/qt/remote_device/test_RemoteDisp.cpp index 8a5b72b7d..72c189906 100644 --- a/test/qt/remote_device/test_RemoteDisp.cpp +++ b/test/qt/remote_device/test_RemoteDisp.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RemoteDispatcher * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteDispatcherClient.h" diff --git a/test/qt/remote_device/test_RemoteReaderAdvertiser.cpp b/test/qt/remote_device/test_RemoteReaderAdvertiser.cpp index bcc748c8d..2ea377865 100644 --- a/test/qt/remote_device/test_RemoteReaderAdvertiser.cpp +++ b/test/qt/remote_device/test_RemoteReaderAdvertiser.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RemoteReaderAdvertiserImpl * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteReaderAdvertiser.h" @@ -53,7 +53,7 @@ class test_RemoteReaderAdvertiser void init() { mMock = new DatagramHandlerMock; - std::function creator = [this](bool){ + std::function creator = [this](bool){ return mMock.data(); }; Env::setCreator(creator); diff --git a/test/qt/remote_device/test_RemoteReaderManagerPlugin.cpp b/test/qt/remote_device/test_RemoteReaderManagerPlugin.cpp index a5ca1897f..1b70e9c5b 100644 --- a/test/qt/remote_device/test_RemoteReaderManagerPlugin.cpp +++ b/test/qt/remote_device/test_RemoteReaderManagerPlugin.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RemoteReaderManagerPlugIn * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "plugin/RemoteReaderManagerPlugIn.h" @@ -30,7 +30,7 @@ using namespace governikus; -Q_DECLARE_METATYPE(QSharedPointer ) +Q_DECLARE_METATYPE(QSharedPointer) class MockRemoteClient @@ -450,14 +450,14 @@ class test_RemoteReaderManagerPlugIn QCOMPARE(static_cast(result.data())->getSlotHandle(), QStringLiteral("NFC Reader")); CommandApdu cmd(QByteArray("ping")); - ResponseApdu res; - QCOMPARE(card->transmit(cmd, res), CardReturnCode::OK); + ResponseApduResult res = card->transmit(cmd); + QCOMPARE(res.mReturnCode, CardReturnCode::OK); QTRY_COMPARE(spySend.count(), 1); result = qvariant_cast >(spySend.takeFirst().at(0)); QCOMPARE(result->getType(), RemoteCardMessageType::IFDTransmit); QCOMPARE(static_cast(result.data())->getSlotHandle(), QStringLiteral("NFC Reader")); QCOMPARE(static_cast(result.data())->getInputApdu(), QByteArray("ping")); - QCOMPARE(res.getBuffer(), QByteArray("pong")); + QCOMPARE(res.mResponseApdu.getBuffer(), QByteArray("pong")); mDispatcher1->setState(MockRemoteDispatcher::DispatcherState::ReaderWithCardError); @@ -473,14 +473,14 @@ class test_RemoteReaderManagerPlugIn QCOMPARE(result->getType(), RemoteCardMessageType::IFDDisconnect); QCOMPARE(static_cast(result.data())->getSlotHandle(), QStringLiteral("NFC Reader")); - res.setBuffer(QByteArray()); - QCOMPARE(card->transmit(cmd, res), CardReturnCode::COMMAND_FAILED); + res = card->transmit(cmd); + QCOMPARE(res.mReturnCode, CardReturnCode::COMMAND_FAILED); QTRY_COMPARE(spySend.count(), 1); result = qvariant_cast >(spySend.takeFirst().at(0)); QCOMPARE(result->getType(), RemoteCardMessageType::IFDTransmit); QCOMPARE(static_cast(result.data())->getSlotHandle(), QStringLiteral("NFC Reader")); QCOMPARE(static_cast(result.data())->getInputApdu(), QByteArray("ping")); - QCOMPARE(res.getBuffer(), QByteArray()); + QCOMPARE(res.mResponseApdu.getBuffer(), QByteArray()); } @@ -513,7 +513,7 @@ class test_RemoteReaderManagerPlugIn const QVariant remoteMessageVariant = arguments.at(0); QVERIFY(remoteMessageVariant.canConvert >()); const QSharedPointer message = remoteMessageVariant.value >(); - const QSharedPointer errorMessage = message.dynamicCast(); + const QSharedPointer errorMessage = message.staticCast(); QVERIFY(!errorMessage.isNull()); QCOMPARE(errorMessage->getType(), RemoteCardMessageType::IFDError); diff --git a/test/qt/remote_device/test_RemoteServerImpl.cpp b/test/qt/remote_device/test_RemoteServerImpl.cpp index bd29a5578..fd310fdfe 100644 --- a/test/qt/remote_device/test_RemoteServerImpl.cpp +++ b/test/qt/remote_device/test_RemoteServerImpl.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RemoteServerImpl * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteServerImpl.h" @@ -40,6 +40,12 @@ class RemoteWebSocketServerMock } + bool isPairingConnection() const override + { + return false; + } + + void setConnected(bool pConnected) { if (mConnected != pConnected) @@ -143,12 +149,12 @@ class test_RemoteServerImpl private Q_SLOTS: void init() { - std::function creator = [this](const QString& pIfdName, const QString& pIfdId, quint16& pPort){ + std::function creator = [this](const QString& pIfdName, const QString& pIfdId, quint16& pPort){ mAdvertiserMock = new RemoteReaderAdvertiserMock(pIfdName, pIfdId, pPort); return mAdvertiserMock; }; Env::setCreator(creator); - std::function creator2 = [this](){ + std::function creator2 = [this](){ mWebSocketMock = new RemoteWebSocketServerMock; return mWebSocketMock; }; diff --git a/test/qt/remote_device/test_RemoteTlsServer.cpp b/test/qt/remote_device/test_RemoteTlsServer.cpp index 89789fe35..0f43db48b 100644 --- a/test/qt/remote_device/test_RemoteTlsServer.cpp +++ b/test/qt/remote_device/test_RemoteTlsServer.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RemoteTlsServer * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteTlsServer.h" diff --git a/test/qt/remote_device/test_RemoteWebSocketServer.cpp b/test/qt/remote_device/test_RemoteWebSocketServer.cpp index cb77b8453..61e735646 100644 --- a/test/qt/remote_device/test_RemoteWebSocketServer.cpp +++ b/test/qt/remote_device/test_RemoteWebSocketServer.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RemoteWebSocketServer * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteWebSocketServer.h" diff --git a/test/qt/remote_device/test_ServerMessageHandler.cpp b/test/qt/remote_device/test_ServerMessageHandler.cpp index baff3b7c9..f3ddc77b6 100644 --- a/test/qt/remote_device/test_ServerMessageHandler.cpp +++ b/test/qt/remote_device/test_ServerMessageHandler.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ServerMessageHandlerImpl * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ServerMessageHandler.h" @@ -117,7 +117,7 @@ class test_ServerMessageHandler readerManager->init(); readerManager->getPlugInInfos(); // just to wait until initialization finished - Env::setCreator(std::function& pDataChannel)>([this](const QSharedPointer ){ + Env::setCreator(std::function& pDataChannel)>([this](const QSharedPointer){ mRemoteDispatcher = new MockRemoteDispatcherServer(mDataChannel); return mRemoteDispatcher.data(); })); diff --git a/test/qt/secure_storage/test_SecureStorage.cpp b/test/qt/secure_storage/test_SecureStorage.cpp index ca9fc69cf..501bd70b8 100644 --- a/test/qt/secure_storage/test_SecureStorage.cpp +++ b/test/qt/secure_storage/test_SecureStorage.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref SecureStorage * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include diff --git a/test/qt/secure_storage/test_TlsConfiguration.cpp b/test/qt/secure_storage/test_TlsConfiguration.cpp index 4b5ee908b..66cacbb55 100644 --- a/test/qt/secure_storage/test_TlsConfiguration.cpp +++ b/test/qt/secure_storage/test_TlsConfiguration.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref TlsConfiguration * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "TlsConfiguration.h" diff --git a/test/qt/services/test_AppUpdatr.cpp b/test/qt/services/test_AppUpdatr.cpp index 4e8ed9272..f4b115fbf 100644 --- a/test/qt/services/test_AppUpdatr.cpp +++ b/test/qt/services/test_AppUpdatr.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref AppUpdater * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "AppUpdater.h" diff --git a/test/qt/settings/test_GeneralSettings.cpp b/test/qt/settings/test_GeneralSettings.cpp index 052dcd848..4b1abed9f 100644 --- a/test/qt/settings/test_GeneralSettings.cpp +++ b/test/qt/settings/test_GeneralSettings.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref GeneralSettings * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include @@ -21,6 +21,22 @@ class test_GeneralSettings { Q_OBJECT + private: + bool getNotificationsOsDefault() + { +#if defined(Q_OS_WIN) + return QOperatingSystemVersion::current() < QOperatingSystemVersion::Windows10; + +#elif defined(Q_OS_MACOS) + return false; + +#else + return true; + +#endif + } + + private Q_SLOTS: void init() { @@ -94,6 +110,21 @@ class test_GeneralSettings } + void testVisualPrivacy() + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + bool initial = settings.isVisualPrivacy(); + + settings.setVisualPrivacy(!initial); + QCOMPARE(settings.isVisualPrivacy(), !initial); + settings.save(); + + settings.setVisualPrivacy(initial); + QCOMPARE(settings.isVisualPrivacy(), initial); + settings.save(); + } + + void testShuffleScreenKeyboard() { auto& settings = Env::getSingleton()->getGeneralSettings(); @@ -113,16 +144,24 @@ class test_GeneralSettings { auto& settings = Env::getSingleton()->getGeneralSettings(); +#if defined(Q_OS_WIN) || defined(Q_OS_MACOS) + QCOMPARE(settings.isAutoUpdateCheck(), true); +#else + QCOMPARE(settings.isAutoUpdateCheck(), false); +#endif + QCOMPARE(settings.isAutoCloseWindowAfterAuthentication(), true); QCOMPARE(settings.isAutoStart(), GENERAL_SETTINGS_DEFAULT_AUTOSTART); - QCOMPARE(settings.isAutoUpdateCheck(), true); + QCOMPARE(settings.isDeveloperOptions(), false); + QCOMPARE(settings.isDeveloperMode(), false); + QCOMPARE(settings.useSelfAuthTestUri(), false); QCOMPARE(settings.isUseScreenKeyboard(), false); QCOMPARE(settings.isShowSetupAssistant(), true); + QCOMPARE(settings.isShowNewUiHint(), true); + QCOMPARE(settings.isShowInAppNotifications(), getNotificationsOsDefault()); QCOMPARE(settings.isRemindUserToClose(), true); QCOMPARE(settings.isTransportPinReminder(), true); QCOMPARE(settings.getPersistentSettingsVersion(), QString()); - QCOMPARE(settings.isDeveloperMode(), false); - QCOMPARE(settings.useSelfAuthTestUri(), false); QCOMPARE(settings.getLastReaderPluginType(), QString()); } @@ -144,6 +183,126 @@ class test_GeneralSettings } + void testShowNewUiHint() + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + + bool initial = settings.isShowNewUiHint(); + bool newValue = !initial; + + settings.setShowNewUiHint(newValue); + QCOMPARE(settings.isShowNewUiHint(), newValue); + settings.save(); + + settings.setShowNewUiHint(initial); + QCOMPARE(settings.isShowNewUiHint(), initial); + settings.save(); + } + + + void testDeveloperOptions() + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + + bool initial = settings.isDeveloperOptions(); + bool newValue = !initial; + + settings.setDeveloperOptions(newValue); + QCOMPARE(settings.isDeveloperOptions(), newValue); + settings.save(); + + settings.setDeveloperOptions(initial); + QCOMPARE(settings.isDeveloperOptions(), initial); + settings.save(); + } + + + void testEnableDeveloperMode() + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + + bool initial = settings.isDeveloperMode(); + bool newValue = !initial; + + settings.setDeveloperMode(newValue); + QCOMPARE(settings.isDeveloperMode(), initial); + settings.save(); + + settings.setDeveloperMode(initial); + QCOMPARE(settings.isDeveloperMode(), initial); + settings.save(); + + settings.setDeveloperOptions(true); + + settings.setDeveloperMode(newValue); + QCOMPARE(settings.isDeveloperMode(), newValue); + settings.save(); + + settings.setDeveloperMode(initial); + QCOMPARE(settings.isDeveloperMode(), initial); + settings.save(); + + settings.setDeveloperOptions(false); + settings.save(); + } + + + void testUseSelfAuthTestUri() + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + + bool initial = settings.useSelfAuthTestUri(); + bool newValue = !initial; + + settings.setUseSelfauthenticationTestUri(newValue); + QCOMPARE(settings.useSelfAuthTestUri(), initial); + settings.save(); + + settings.setUseSelfauthenticationTestUri(initial); + QCOMPARE(settings.useSelfAuthTestUri(), initial); + settings.save(); + + settings.setDeveloperOptions(true); + + settings.setUseSelfauthenticationTestUri(newValue); + QCOMPARE(settings.useSelfAuthTestUri(), newValue); + settings.save(); + + settings.setUseSelfauthenticationTestUri(initial); + QCOMPARE(settings.useSelfAuthTestUri(), initial); + settings.save(); + + settings.setDeveloperOptions(false); + settings.save(); + } + + + void testEnableNotificationsOnDeveloperMode() + { + auto& settings = Env::getSingleton()->getGeneralSettings(); + settings.setDeveloperOptions(true); + settings.setDeveloperMode(false); + + QSignalSpy spyShowInAppNotifications(&settings, &GeneralSettings::fireShowInAppNotificationsChanged); + + const bool osDefaultNotifications = getNotificationsOsDefault(); + + QCOMPARE(settings.isShowInAppNotifications(), osDefaultNotifications); + + settings.setDeveloperMode(true); + QCOMPARE(settings.isDeveloperMode(), true); + QCOMPARE(settings.isShowInAppNotifications(), true); + QCOMPARE(spyShowInAppNotifications.count(), 1); + settings.save(); + + settings.setDeveloperMode(false); + QCOMPARE(settings.isDeveloperMode(), false); + QCOMPARE(settings.isShowInAppNotifications(), osDefaultNotifications); + QCOMPARE(spyShowInAppNotifications.count(), 2); + settings.save(); + } + + void testRemindUserToClose() { auto& settings = Env::getSingleton()->getGeneralSettings(); diff --git a/test/qt/settings/test_HistorySettings.cpp b/test/qt/settings/test_HistorySettings.cpp index 97d529681..cffc75f69 100644 --- a/test/qt/settings/test_HistorySettings.cpp +++ b/test/qt/settings/test_HistorySettings.cpp @@ -4,7 +4,7 @@ * All tests end with _QTEST to be able to identify them later. * All original history entry from AusweisApp2 do not have this. * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "HistorySettings.h" diff --git a/test/qt/settings/test_KeyPair.cpp b/test/qt/settings/test_KeyPair.cpp index 41488647b..0092f7968 100644 --- a/test/qt/settings/test_KeyPair.cpp +++ b/test/qt/settings/test_KeyPair.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CertificateGenerator * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "KeyPair.h" diff --git a/test/qt/settings/test_PreVerificationSettings.cpp b/test/qt/settings/test_PreVerificationSettings.cpp index 312eab076..eb7bcb667 100644 --- a/test/qt/settings/test_PreVerificationSettings.cpp +++ b/test/qt/settings/test_PreVerificationSettings.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref PreVerificationSettings * - * \copyright Copyright (c) 2014-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2014-2020 Governikus GmbH & Co. KG, Germany */ #include "PreVerificationSettings.h" diff --git a/test/qt/settings/test_RemoteServiceSettings.cpp b/test/qt/settings/test_RemoteServiceSettings.cpp index bc5b9c123..2b3eca594 100644 --- a/test/qt/settings/test_RemoteServiceSettings.cpp +++ b/test/qt/settings/test_RemoteServiceSettings.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref RemoteSertviceSettings * - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteServiceSettings.h" @@ -38,10 +38,27 @@ class test_RemoteServiceSettings { RemoteServiceSettings settings; QCOMPARE(settings.getServerName(), DeviceInfo::getName()); + settings.save(); QCOMPARE(settings.getServerName(), DeviceInfo::getName()); + + settings.setServerName(QLatin1String(" ")); + QCOMPARE(settings.getServerName(), DeviceInfo::getName()); + + settings.setServerName(QLatin1String(" \n ")); + QCOMPARE(settings.getServerName(), DeviceInfo::getName()); + settings.setServerName(QLatin1String("Google Pixel")); QCOMPARE(settings.getServerName(), QLatin1String("Google Pixel")); + + settings.setServerName(QLatin1String(" Google Pixel")); + QCOMPARE(settings.getServerName(), QLatin1String("Google Pixel")); + + settings.setServerName(QLatin1String("Google Pixel ")); + QCOMPARE(settings.getServerName(), QLatin1String("Google Pixel")); + + settings.setServerName(QLatin1String("Google Pixel \n ")); + QCOMPARE(settings.getServerName(), QLatin1String("Google Pixel")); } diff --git a/test/qt/ui/aidl/test_PskManager.cpp b/test/qt/ui/aidl/test_PskManager.cpp index ce5a641d8..ac2114214 100644 --- a/test/qt/ui/aidl/test_PskManager.cpp +++ b/test/qt/ui/aidl/test_PskManager.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for PskManager. * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "PskManager.h" diff --git a/test/qt/ui/json/test_Message.cpp b/test/qt/ui/json/test_Message.cpp index 53f8cfb00..beed3e9d1 100644 --- a/test/qt/ui/json/test_Message.cpp +++ b/test/qt/ui/json/test_Message.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MessageDispatcher * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "MessageDispatcher.h" diff --git a/test/qt/ui/json/test_MsgContext.cpp b/test/qt/ui/json/test_MsgContext.cpp index 6abf7557a..95222e6ee 100644 --- a/test/qt/ui/json/test_MsgContext.cpp +++ b/test/qt/ui/json/test_MsgContext.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgContext * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgContext.h" diff --git a/test/qt/ui/json/test_MsgHandler.cpp b/test/qt/ui/json/test_MsgHandler.cpp index 5e1de12e7..acd29d770 100644 --- a/test/qt/ui/json/test_MsgHandler.cpp +++ b/test/qt/ui/json/test_MsgHandler.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandler * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandler.h" diff --git a/test/qt/ui/json/test_MsgHandlerAccessRights.cpp b/test/qt/ui/json/test_MsgHandlerAccessRights.cpp index 86ba07fe7..4c41a96a5 100644 --- a/test/qt/ui/json/test_MsgHandlerAccessRights.cpp +++ b/test/qt/ui/json/test_MsgHandlerAccessRights.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerAccessRights * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerAccessRights.h" @@ -61,7 +61,7 @@ class test_MsgHandlerAccessRights dispatcher.init(context); QCOMPARE(dispatcher.processStateChange("StateEditAccessRights"), - QByteArray(R"({"chat":{"effective":["ResidencePermitI","Address","BirthName","Nationality","PlaceOfBirth","DateOfBirth","DoctoralDegree","ArtisticName","FamilyName","GivenNames","ValidUntil","IssuingCountry","DocumentType","Pseudonym"],"optional":["ResidencePermitI","Address","BirthName","Nationality","PlaceOfBirth","DateOfBirth","DoctoralDegree","ArtisticName","FamilyName","GivenNames","ValidUntil","IssuingCountry","DocumentType","Pseudonym"],"required":[]},"msg":"ACCESS_RIGHTS"})")); + QByteArray(R"({"chat":{"effective":["WriteAddress","WriteCommunityID","WriteResidencePermitI","WriteResidencePermitII","ResidencePermitI","Address","BirthName","Nationality","PlaceOfBirth","DateOfBirth","DoctoralDegree","ArtisticName","FamilyName","GivenNames","ValidUntil","IssuingCountry","DocumentType","Pseudonym"],"optional":["WriteAddress","WriteCommunityID","WriteResidencePermitI","WriteResidencePermitII","ResidencePermitI","Address","BirthName","Nationality","PlaceOfBirth","DateOfBirth","DoctoralDegree","ArtisticName","FamilyName","GivenNames","ValidUntil","IssuingCountry","DocumentType","Pseudonym"],"required":[]},"msg":"ACCESS_RIGHTS"})")); } diff --git a/test/qt/ui/json/test_MsgHandlerApiLevel.cpp b/test/qt/ui/json/test_MsgHandlerApiLevel.cpp index 9644bab35..21d97458f 100644 --- a/test/qt/ui/json/test_MsgHandlerApiLevel.cpp +++ b/test/qt/ui/json/test_MsgHandlerApiLevel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerApiLevel * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerApiLevel.h" diff --git a/test/qt/ui/json/test_MsgHandlerAuth.cpp b/test/qt/ui/json/test_MsgHandlerAuth.cpp index 1d128eae5..426484334 100644 --- a/test/qt/ui/json/test_MsgHandlerAuth.cpp +++ b/test/qt/ui/json/test_MsgHandlerAuth.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerAuth * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerAuth.h" diff --git a/test/qt/ui/json/test_MsgHandlerCertificate.cpp b/test/qt/ui/json/test_MsgHandlerCertificate.cpp index c6732a78e..98a53626a 100644 --- a/test/qt/ui/json/test_MsgHandlerCertificate.cpp +++ b/test/qt/ui/json/test_MsgHandlerCertificate.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerCertificate * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerCertificate.h" diff --git a/test/qt/ui/json/test_MsgHandlerEnterCan.cpp b/test/qt/ui/json/test_MsgHandlerEnterCan.cpp index c19b3be0b..ae04d83c3 100644 --- a/test/qt/ui/json/test_MsgHandlerEnterCan.cpp +++ b/test/qt/ui/json/test_MsgHandlerEnterCan.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerEnterCan * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerEnterCan.h" diff --git a/test/qt/ui/json/test_MsgHandlerEnterPin.cpp b/test/qt/ui/json/test_MsgHandlerEnterPin.cpp index 5b3d528d7..3fd88ba16 100644 --- a/test/qt/ui/json/test_MsgHandlerEnterPin.cpp +++ b/test/qt/ui/json/test_MsgHandlerEnterPin.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerEnterPin * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerEnterPin.h" diff --git a/test/qt/ui/json/test_MsgHandlerEnterPuk.cpp b/test/qt/ui/json/test_MsgHandlerEnterPuk.cpp index 4cce0e048..0b3267300 100644 --- a/test/qt/ui/json/test_MsgHandlerEnterPuk.cpp +++ b/test/qt/ui/json/test_MsgHandlerEnterPuk.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerEnterPuk * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerEnterPuk.h" diff --git a/test/qt/ui/json/test_MsgHandlerInsertCard.cpp b/test/qt/ui/json/test_MsgHandlerInsertCard.cpp index ecf7fad7c..70c174192 100644 --- a/test/qt/ui/json/test_MsgHandlerInsertCard.cpp +++ b/test/qt/ui/json/test_MsgHandlerInsertCard.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerInsertCard * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerInsertCard.h" diff --git a/test/qt/ui/json/test_MsgHandlerInternalError.cpp b/test/qt/ui/json/test_MsgHandlerInternalError.cpp index 3d8863151..ee0095cd5 100644 --- a/test/qt/ui/json/test_MsgHandlerInternalError.cpp +++ b/test/qt/ui/json/test_MsgHandlerInternalError.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerInternalError * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerInternalError.h" diff --git a/test/qt/ui/json/test_MsgHandlerReader.cpp b/test/qt/ui/json/test_MsgHandlerReader.cpp index c2a80e9cc..2cf704190 100644 --- a/test/qt/ui/json/test_MsgHandlerReader.cpp +++ b/test/qt/ui/json/test_MsgHandlerReader.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerReader * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerReader.h" diff --git a/test/qt/ui/json/test_MsgHandlerReaderList.cpp b/test/qt/ui/json/test_MsgHandlerReaderList.cpp index 666690252..72b3dfce9 100644 --- a/test/qt/ui/json/test_MsgHandlerReaderList.cpp +++ b/test/qt/ui/json/test_MsgHandlerReaderList.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref MsgHandlerReaderList * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "messages/MsgHandlerReader.h" diff --git a/test/qt/ui/json/test_UIPlugInJson.cpp b/test/qt/ui/json/test_UIPlugInJson.cpp index f3f90d8e7..34c8be0ba 100644 --- a/test/qt/ui/json/test_UIPlugInJson.cpp +++ b/test/qt/ui/json/test_UIPlugInJson.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref UIPlugInJsonApi * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugInJson.h" diff --git a/test/qt/ui/qml/test_AuthModel.cpp b/test/qt/ui/qml/test_AuthModel.cpp index b69015b28..0609f2c6d 100644 --- a/test/qt/ui/qml/test_AuthModel.cpp +++ b/test/qt/ui/qml/test_AuthModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref AuthModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "AuthModel.h" diff --git a/test/qt/ui/qml/test_CertificateDescriptionModel.cpp b/test/qt/ui/qml/test_CertificateDescriptionModel.cpp index c43278161..7e435a977 100644 --- a/test/qt/ui/qml/test_CertificateDescriptionModel.cpp +++ b/test/qt/ui/qml/test_CertificateDescriptionModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref CertificateDescriptionModel * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "CertificateDescriptionModel.h" @@ -45,11 +45,11 @@ class test_CertificateDescriptionModel QCOMPARE(mModel->rowCount(), 4); const QString termsOfUsage = QStringLiteral("Anschrift:\nbremen online services GmbH & Co. KG\nAm Fallturm 9\n28359 Bremen\n\nE-Mail-Adresse:\nhb@bos-bremen.de\n\nZweck des Auslesevorgangs:\nDemonstration des eID-Service\n\nZust\u00E4ndige Datenschutzaufsicht:\nDie Landesbeauftragte f\u00FCr Datenschutz und Informationsfreiheit der Freien Hansestadt Bremen\nArndtstra\u00DFe 1\n27570 Bremerhaven"); - QCOMPARE(mModel->data(mModel->index(0), CertificateDescriptionModel::UserRoles::LABEL), QString("Service provider")); + QCOMPARE(mModel->data(mModel->index(0), CertificateDescriptionModel::UserRoles::LABEL), QString("Provider")); QCOMPARE(mModel->data(mModel->index(0), CertificateDescriptionModel::UserRoles::TEXT), QStringLiteral("bos KG\nhttps://dev-demo.governikus-eid.de:8443")); QCOMPARE(mModel->data(mModel->index(1), CertificateDescriptionModel::UserRoles::LABEL), QString("Certificate issuer")); QCOMPARE(mModel->data(mModel->index(1), CertificateDescriptionModel::UserRoles::TEXT), QStringLiteral("Deutsche Post Com, Gesch\u00E4ftsfeld Signtrust\nhttp://www.signtrust.de")); - QCOMPARE(mModel->data(mModel->index(2), CertificateDescriptionModel::UserRoles::LABEL), QString("Service provider information")); + QCOMPARE(mModel->data(mModel->index(2), CertificateDescriptionModel::UserRoles::LABEL), QString("Provider information")); QCOMPARE(mModel->data(mModel->index(2), CertificateDescriptionModel::UserRoles::TEXT), termsOfUsage); QCOMPARE(mModel->data(mModel->index(3), CertificateDescriptionModel::UserRoles::LABEL), QString("Validity")); QCOMPARE(spy.count(), 1); diff --git a/test/qt/ui/qml/test_ChangePinModel.cpp b/test/qt/ui/qml/test_ChangePinModel.cpp index d29bdee1e..7d5ed2f4c 100644 --- a/test/qt/ui/qml/test_ChangePinModel.cpp +++ b/test/qt/ui/qml/test_ChangePinModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ChangePinModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "ChangePinModel.h" diff --git a/test/qt/ui/qml/test_ChatModel.cpp b/test/qt/ui/qml/test_ChatModel.cpp index 3ef4f89d9..ac16ba2d9 100644 --- a/test/qt/ui/qml/test_ChatModel.cpp +++ b/test/qt/ui/qml/test_ChatModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ChatModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "ChatModel.h" @@ -62,7 +62,13 @@ class test_ChatModel QVERIFY(mModel->mAllRights.contains(AccessRight::READ_DG06)); QVERIFY(mModel->mAllRights.contains(AccessRight::READ_DG02)); QVERIFY(mModel->mAllRights.contains(AccessRight::READ_DG19)); - QCOMPARE(mModel->mSelectedRights, mModel->mAllRights.toSet()); + +#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)) + auto uniqueRights = QSet(mModel->mAllRights.constBegin(), mModel->mAllRights.constEnd()); +#else + auto uniqueRights = mModel->mAllRights.toSet(); +#endif + QCOMPARE(mModel->mSelectedRights, uniqueRights); mModel->resetContext(selfAuthContext); QVERIFY(mModel->mAllRights.contains(AccessRight::READ_DG05)); @@ -77,7 +83,13 @@ class test_ChatModel QVERIFY(mModel->mAllRights.contains(AccessRight::READ_DG06)); QVERIFY(mModel->mAllRights.contains(AccessRight::READ_DG02)); QVERIFY(mModel->mAllRights.contains(AccessRight::READ_DG19)); - QCOMPARE(mModel->mSelectedRights, mModel->mAllRights.toSet()); + +#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)) + uniqueRights = QSet(mModel->mAllRights.constBegin(), mModel->mAllRights.constEnd()); +#else + uniqueRights = mModel->mAllRights.toSet(); +#endif + QCOMPARE(mModel->mSelectedRights, uniqueRights); mModel->resetContext(mAuthContext); QVERIFY(mModel->mAllRights.isEmpty()); diff --git a/test/qt/ui/qml/test_ConnectivityManager.cpp b/test/qt/ui/qml/test_ConnectivityManager.cpp index 4c5503c97..7a548d9e6 100644 --- a/test/qt/ui/qml/test_ConnectivityManager.cpp +++ b/test/qt/ui/qml/test_ConnectivityManager.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ConnectivityManager * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "ConnectivityManager.h" diff --git a/test/qt/ui/qml/test_HistoryModel.cpp b/test/qt/ui/qml/test_HistoryModel.cpp index ff81f07f2..324a3e592 100644 --- a/test/qt/ui/qml/test_HistoryModel.cpp +++ b/test/qt/ui/qml/test_HistoryModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref HistoryModel * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "HistoryModel.h" @@ -43,7 +43,7 @@ class test_HistoryModel /* postal address */ QStringLiteral("Am Fallturm 9\n28359 Bremen"), /* icon */ QString(), /* image */ QString(), - /* tcTokenUrl */ QStringLiteral("https://npa.allianz.de/azservice/NpaEIDService/nparef/-wnf"), + /* tcTokenUrl */ QStringLiteral("https://www.autentapp.de/AusweisAuskunft/WebServiceRequesterServlet?mode=xml"), /* clientUrl */ QStringLiteral("https://www.bva.bund.de/bafoeg-online/Bafoeg/flow/anmeld"), /* subjectUrls */ subjectUrls); } @@ -54,7 +54,7 @@ class test_HistoryModel QStringList subjectUrls1({QStringLiteral("https://test.test/"), QStringLiteral("https://abc.abc/"), QStringLiteral("abc.abc")}); QStringList subjectUrls2({QStringLiteral("abc.abc")}); - QStringList subjectUrls3({QStringLiteral("https://npa.allianz.de/bla1"), QStringLiteral("https://npa.allianz.de/bla1")}); + QStringList subjectUrls3({QStringLiteral("https://www.autentapp.de/bla1"), QStringLiteral("https://www.autentapp.de/bla1")}); auto& infos = Env::getSingleton()->mProviderConfigurationInfos; infos.clear(); @@ -209,7 +209,7 @@ class test_HistoryModel QFETCH(int, count); QFETCH(int, newSize); - HistoryInfo historyInfo("SubjectName", "https://npa.allianz.de/bla1", "Usage", QDateTime::currentDateTime(), "TermOfUsage", {"RequestedData"}); + HistoryInfo historyInfo("SubjectName", "https://www.autentapp.de/bla1", "Usage", QDateTime::currentDateTime(), "TermOfUsage", {"RequestedData"}); QVector infos(oldSize, historyInfo); QSignalSpy spyRemove(mModel.data(), &HistoryModel::rowsAboutToBeRemoved); diff --git a/test/qt/ui/qml/test_LogModel.cpp b/test/qt/ui/qml/test_LogModel.cpp index 0d406ec48..f42d49c0d 100644 --- a/test/qt/ui/qml/test_LogModel.cpp +++ b/test/qt/ui/qml/test_LogModel.cpp @@ -1,13 +1,11 @@ /*! * \brief Unit tests for \ref LogModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "LogModel.h" -#include "LogHandler.h" - #include #include @@ -24,6 +22,9 @@ class test_LogModel void init() { mModel.reset(new LogModel()); + // The test only covers the LogModel functionality, LogHandler will return an + // error message to the LogModel if not properly initialised; discard that. + mModel->mLogEntries.clear(); } @@ -36,8 +37,8 @@ class test_LogModel void test_AddLogEntry_data() { QTest::addColumn("input"); - QTest::addColumn("entry1"); - QTest::addColumn("entry2"); + QTest::addColumn("origin"); + QTest::addColumn("message"); QTest::newRow("validEntry") << QString("input : test") << QString("input") << QString("test"); QTest::newRow("empty") << QString(" : ") << QString() << QString(); @@ -56,12 +57,15 @@ class test_LogModel void test_AddLogEntry() { QFETCH(QString, input); - QFETCH(QString, entry1); - QFETCH(QString, entry2); + QFETCH(QString, origin); + QFETCH(QString, message); mModel->addLogEntry(input); - QCOMPARE(mModel->mLogEntries.at(0), entry1); - QCOMPARE(mModel->mLogEntries.at(1), entry2); + QCOMPARE(mModel->mLogEntries.at(0), input); + const QModelIndex index = mModel->index(0); + QCOMPARE(mModel->data(index, LogModel::OriginRole), origin); + QCOMPARE(mModel->data(index, LogModel::MessageRole), message); + QCOMPARE(mModel->data(index, Qt::DisplayRole), input); } @@ -69,13 +73,10 @@ class test_LogModel { QTest::addColumn("fileName"); QTest::addColumn("logEntriesSize"); - QTest::addColumn("count"); - QTest::newRow("empty") << QString(":/logfiles/empty.txt") << 0 << 0; - QTest::newRow("size78") << QString(":/logfiles/size78.txt") << 78 << 78; - QTest::newRow("size80") << QString(":/logfiles/size80.txt") << 80 << 80; - QTest::newRow("size82") << QString(":/logfiles/size82.txt") << 82 << 80; - QTest::newRow("size160") << QString(":/logfiles/size160.txt") << 160 << 80; + QTest::newRow("empty") << QString(":/logfiles/empty.txt") << 0; + QTest::newRow("size1") << QString(":/logfiles/size1.txt") << 1; + QTest::newRow("size42") << QString(":/logfiles/size42.txt") << 42; } @@ -101,21 +102,11 @@ class test_LogModel QTest::addColumn("newLogMsgCounter"); QTest::addColumn("logEntriesSizeChange"); - QTest::newRow("emptyFile_MsgAdded") << QString(" : ") << QString(":/logfiles/empty.txt") << 0 << 1 << 2; + QTest::newRow("emptyFile_MsgAdded") << QString("test : input") << QString(":/logfiles/empty.txt") << 0 << 1 << 1; QTest::newRow("emptyFile_MsgNotAdded") << QString(" : ") << QString(":/logfiles/empty.txt") << 1 << 0 << 0; - QTest::newRow("emptyFile_MsgAdded_ViewChanged") << QString("test : input") << QString(":/logfiles/empty.txt") << 0 << 1 << 2; - - QTest::newRow("MsgAdded_Size78") << QString() << QString(":/logfiles/size78.txt") << 0 << 1 << 2; - QTest::newRow("MsgAdded_ViewChanged_Size78") << QString("test : input") << QString(":/logfiles/size78.txt") << 0 << 1 << 2; - QTest::newRow("MsgNotAdded_Size78") << QString("test : input") << QString(":/logfiles/size78.txt") << 2 << 0 << 0; - - QTest::newRow("MsgAdded_Size80") << QString() << QString(":/logfiles/size80.txt") << 0 << 1 << 2; - QTest::newRow("MsgNotAdded_Size80") << QString("test : input") << QString(":/logfiles/size80.txt") << 1 << 0 << 0; - QTest::newRow("MsgAdded_ViewChanged_Size80") << QString("test : input") << QString(":/logfiles/size80.txt") << 0 << 1 << 2; - QTest::newRow("MsgAdded_Size82") << QString("test : input") << QString(":/logfiles/size82.txt") << 0 << 1 << 2; - QTest::newRow("MsgNotAdded_Size82") << QString(" : ") << QString(":/logfiles/size82.txt") << 3 << 0 << 0; - QTest::newRow("MsgAdded_ViewChanged_Size82") << QString("test : input") << QString(":/logfiles/size82.txt") << 0 << 1 << 2; + QTest::newRow("size1_MsgAdded") << QString("test : input") << QString(":/logfiles/size1.txt") << 0 << 1 << 1; + QTest::newRow("size1_MsgNotAdded") << QString(" : ") << QString(":/logfiles/size1.txt") << 1 << 0 << 0; } diff --git a/test/qt/ui/qml/test_NotificationModel.cpp b/test/qt/ui/qml/test_NotificationModel.cpp index 9b4aaef51..f68b22fe5 100644 --- a/test/qt/ui/qml/test_NotificationModel.cpp +++ b/test/qt/ui/qml/test_NotificationModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref NotificationModel * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "NotificationModel.h" diff --git a/test/qt/ui/qml/test_NumberModel.cpp b/test/qt/ui/qml/test_NumberModel.cpp index a358a9070..d75f01e35 100644 --- a/test/qt/ui/qml/test_NumberModel.cpp +++ b/test/qt/ui/qml/test_NumberModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref NumberModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "NumberModel.h" @@ -249,23 +249,22 @@ class test_NumberModel QVERIFY(mModel->hasError()); context->setLastPaceResult(CardReturnCode::INVALID_PIN_2); - QCOMPARE(mModel->getInputError(), tr("You have entered the wrong PIN twice. " - "Prior to a third attempt, you have to enter your six-digit card access number first. " - "You can find your card access number on the front of your ID card.")); + QCOMPARE(mModel->getInputError(), tr("A wrong PIN has been entered twice on your ID card. " + "Prior to a third attempt, you have to enter your 6-digit card access number (CAN) first. " + "You can find your card access number (CAN) on the front of your ID card.")); QVERIFY(mModel->hasError()); context->setLastPaceResult(CardReturnCode::INVALID_PIN_3); - QCOMPARE(mModel->getInputError(), tr("You have entered a wrong PIN three times. " + QCOMPARE(mModel->getInputError(), tr("A wrong PIN has been entered three times on your ID card. " "Your PIN is now blocked. " - "You have to enter the PUK now for unblocking.")); + "To unblock your PIN you have to enter the PUK.")); QVERIFY(mModel->hasError()); context->setLastPaceResult(CardReturnCode::INVALID_CAN); - QCOMPARE(mModel->getInputError(), tr("You have entered a wrong CAN, please try again.")); + QCOMPARE(mModel->getInputError(), tr("The entered card access number (CAN) is incorrect. Please try again.")); context->setLastPaceResult(CardReturnCode::INVALID_PUK); - QCOMPARE(mModel->getInputError(), tr("You have entered a wrong PUK. " - "Please try again.")); + QCOMPARE(mModel->getInputError(), tr("The entered PUK is incorrect. Please try again.")); QVERIFY(mModel->hasError()); context->setLastPaceResult(CardReturnCode::UNKNOWN); diff --git a/test/qt/ui/qml/test_ProviderCategoryFilterModel.cpp b/test/qt/ui/qml/test_ProviderCategoryFilterModel.cpp index 7ca5bea16..cf3433426 100644 --- a/test/qt/ui/qml/test_ProviderCategoryFilterModel.cpp +++ b/test/qt/ui/qml/test_ProviderCategoryFilterModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ProviderCategoryFilterModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderCategoryFilterModel.h" diff --git a/test/qt/ui/qml/test_ProviderModel.cpp b/test/qt/ui/qml/test_ProviderModel.cpp index 01225fdfd..262f780fe 100644 --- a/test/qt/ui/qml/test_ProviderModel.cpp +++ b/test/qt/ui/qml/test_ProviderModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ProviderModel * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderModel.h" diff --git a/test/qt/ui/qml/test_ProviderNameFilterModel.cpp b/test/qt/ui/qml/test_ProviderNameFilterModel.cpp index 1642547e5..672548527 100644 --- a/test/qt/ui/qml/test_ProviderNameFilterModel.cpp +++ b/test/qt/ui/qml/test_ProviderNameFilterModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ProviderNameFilterModel * - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ #include "ProviderNameFilterModel.h" @@ -48,11 +48,11 @@ class test_ProviderNameFilterModel HistoryModel model; mModel->setSourceModel(&model); - HistoryInfo historyInfo1("SubjectName", QString("https://makler.allianz.de"), "Usage", QDateTime::currentDateTime(), "TermOfUsage", {"RequestedData"}); + HistoryInfo historyInfo1("SubjectName", QString("https://www.ausweisapp.bund.de/online-ausweisen/meine-daten-auslesen/"), "Usage", QDateTime::currentDateTime(), "TermOfUsage", {"RequestedData"}); HistoryInfo historyInfo2("SubjectName", QString("https://test.de"), "Usage", QDateTime::currentDateTime(), "TermOfUsage", {"RequestedData"}); Env::getSingleton()->getHistorySettings().addHistoryInfo(historyInfo1); Env::getSingleton()->getHistorySettings().addHistoryInfo(historyInfo2); - const QString providerAddress("https://makler.allianz.de"); + const QString providerAddress("https://www.ausweisapp.bund.de/online-ausweisen/meine-daten-auslesen/"); mModel->setProviderAddress(providerAddress); QVERIFY(!mModel->filterAcceptsRow(0, QModelIndex())); @@ -67,7 +67,7 @@ class test_ProviderNameFilterModel mModel->setProviderAddress(invalidProviderAddress); QCOMPARE(mModel->mProvider.getAddress(), QString()); - const QString validProviderAddress("https://makler.allianz.de"); + const QString validProviderAddress("https://www.ausweisapp.bund.de/online-ausweisen/meine-daten-auslesen/"); mModel->setProviderAddress(validProviderAddress); QCOMPARE(mModel->mProvider.getAddress(), validProviderAddress); } diff --git a/test/qt/ui/qml/test_QmlFileStructure.cpp b/test/qt/ui/qml/test_QmlFileStructure.cpp index 1c0737fb7..240ecb7f8 100644 --- a/test/qt/ui/qml/test_QmlFileStructure.cpp +++ b/test/qt/ui/qml/test_QmlFileStructure.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "ResourceLoader.h" diff --git a/test/qt/ui/qml/test_RemoteServiceModel.cpp b/test/qt/ui/qml/test_RemoteServiceModel.cpp index 8b244d698..8aa9f3791 100644 --- a/test/qt/ui/qml/test_RemoteServiceModel.cpp +++ b/test/qt/ui/qml/test_RemoteServiceModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref ProviderModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "RemoteServiceModel.h" @@ -46,7 +46,7 @@ class test_RemoteServiceModel private Q_SLOTS: void initTestCase() { - Env::setCreator(std::function([&] { + Env::setCreator(std::function([&] { return new MockRemoteServer(); })); mModel = Env::getSingleton(); diff --git a/test/qt/ui/qml/test_SelfAuthModel.cpp b/test/qt/ui/qml/test_SelfAuthModel.cpp index f272e804e..bb10c6ab4 100644 --- a/test/qt/ui/qml/test_SelfAuthModel.cpp +++ b/test/qt/ui/qml/test_SelfAuthModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref SelfAuthModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "SelfAuthModel.h" diff --git a/test/qt/ui/qml/test_UIPlugInQml.cpp b/test/qt/ui/qml/test_UIPlugInQml.cpp index 17ada66f5..084e2a0bd 100644 --- a/test/qt/ui/qml/test_UIPlugInQml.cpp +++ b/test/qt/ui/qml/test_UIPlugInQml.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2019-2020 Governikus GmbH & Co. KG, Germany */ @@ -7,7 +7,9 @@ #include "WebSocketHelper.h" #include +#include #include +#include #include using namespace governikus; @@ -30,8 +32,10 @@ class test_UIPlugInQml bool initContainedInLog = false; bool initContainedAndSuccess = false; + bool showUiReceived = false; + bool noQmlWarning = true; QString logData; - mHelper->waitForMessage([&initContainedInLog, &initContainedAndSuccess, &logData](const QJsonObject& pMessage){ + mHelper->waitForMessage([&initContainedInLog, &initContainedAndSuccess, &showUiReceived, &noQmlWarning, &logData](const QJsonObject& pMessage){ if (pMessage[QLatin1String("data")].isNull()) { return false; @@ -41,12 +45,15 @@ class test_UIPlugInQml logData = data; initContainedInLog = data.contains(QLatin1String("QML engine initialization finished")); initContainedAndSuccess = data.contains(QLatin1String("QML engine initialization finished with 0 warnings.")); + showUiReceived = (data.count(QStringLiteral("/eID-Client?showui=")) == 3); + noQmlWarning = !data.contains(QRegularExpression(" W .*\\.qml:")); + return true; }); if (pCheckDoneAndSuccessful) { - if (initContainedAndSuccess) + if (initContainedAndSuccess && showUiReceived && noQmlWarning) { return true; } @@ -63,6 +70,7 @@ class test_UIPlugInQml void initTestCase() { qRegisterMetaType("QProcess::ProcessState"); + qRegisterMetaType("QNetworkReply*"); } @@ -94,7 +102,7 @@ class test_UIPlugInQml args << "--ui" << "qml"; args << "--ui" << "websocket"; args << "--port" << "0"; - args << "-platform" << "minimal"; + args << "-platform" << "offscreen"; mApp2.reset(new QProcess()); mApp2->setProgram(app); @@ -112,11 +120,21 @@ class test_UIPlugInQml QTRY_COMPARE_WITH_TIMEOUT(portInfoFile.exists(), true, PROCESS_TIMEOUT); QVERIFY(portInfoFile.open(QIODevice::ReadOnly)); - quint16 webSocketPort = 0; - QTextStream(&portInfoFile) >> webSocketPort; - QVERIFY(webSocketPort > 0); - - mHelper.reset(new WebSocketHelper(webSocketPort)); + quint16 applicationPort = 0; + QTextStream(&portInfoFile) >> applicationPort; + QVERIFY(applicationPort > 0); + + const QString showUiUri = QStringLiteral("http://localhost:%1/eID-Client?showui=%2").arg(applicationPort); + QNetworkAccessManager accessManager; + QSignalSpy logSpy(&accessManager, &QNetworkAccessManager::finished); + accessManager.get(QNetworkRequest(QUrl(showUiUri.arg("IDENTIFY")))); + QTRY_COMPARE_WITH_TIMEOUT(logSpy.size(), 1, PROCESS_TIMEOUT); + accessManager.get(QNetworkRequest(QUrl(showUiUri.arg("SETTINGS")))); + QTRY_COMPARE_WITH_TIMEOUT(logSpy.size(), 2, PROCESS_TIMEOUT); + accessManager.get(QNetworkRequest(QUrl(showUiUri.arg("UPDATEINFORMATION")))); + QTRY_COMPARE_WITH_TIMEOUT(logSpy.size(), 3, PROCESS_TIMEOUT); + + mHelper.reset(new WebSocketHelper(applicationPort)); QCOMPARE(mHelper->getState(), QAbstractSocket::SocketState::ConnectedState); QTRY_VERIFY_WITH_TIMEOUT(isQmlEngineInitDone(false), PROCESS_TIMEOUT); diff --git a/test/qt/ui/qml/test_WorkflowModel.cpp b/test/qt/ui/qml/test_WorkflowModel.cpp index fab17a3d1..0116bb231 100644 --- a/test/qt/ui/qml/test_WorkflowModel.cpp +++ b/test/qt/ui/qml/test_WorkflowModel.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref WorkflowModel * - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "WorkflowModel.h" @@ -62,17 +62,6 @@ class test_WorkflowModel } - void test_CancelWorkflowOnPinBlocked() - { - WorkflowModel model; - QSharedPointer context(new WorkflowContext()); - model.mContext = context; - - model.cancelWorkflowOnPinBlocked(); - QCOMPARE(context->getStatus().getStatusCode(), GlobalStatus::Code::Workflow_Pin_Blocked_And_Puk_Objectionable); - } - - void test_IsBasicReader() { QThread connectionThread; diff --git a/test/qt/ui/websocket/test_UIPlugInWebSocket.cpp b/test/qt/ui/websocket/test_UIPlugInWebSocket.cpp index a1ad24c98..8379cd85c 100644 --- a/test/qt/ui/websocket/test_UIPlugInWebSocket.cpp +++ b/test/qt/ui/websocket/test_UIPlugInWebSocket.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref UIPlugInWebSocket * - * \copyright Copyright (c) 2016-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2016-2020 Governikus GmbH & Co. KG, Germany */ #include "UIPlugInWebSocket.h" diff --git a/test/qt/ui/widget/test_HelpAction.cpp b/test/qt/ui/widget/test_HelpAction.cpp index ba6ecd94d..fc9629fbf 100644 --- a/test/qt/ui/widget/test_HelpAction.cpp +++ b/test/qt/ui/widget/test_HelpAction.cpp @@ -1,7 +1,7 @@ /*! * \brief Unit tests for \ref HelpAction * - * \copyright Copyright (c) 2015-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2015-2020 Governikus GmbH & Co. KG, Germany */ #include "TestFileHelper.h" @@ -41,7 +41,7 @@ class test_HelpAction const QString sys = "Windows"; #endif - return QStringLiteral("https://www.ausweisapp.bund.de/ausweisapp2/handbuch/1.9/%1/%2/index.html").arg(pLang, sys); + return QStringLiteral("https://www.ausweisapp.bund.de/ausweisapp2/handbuch/1.16/%1/%2/index.html").arg(pLang, sys); } @@ -54,7 +54,7 @@ class test_HelpAction private Q_SLOTS: void init() { - QCoreApplication::setApplicationVersion(QStringLiteral("1.9")); + QCoreApplication::setApplicationVersion(QStringLiteral("1.16")); QVERIFY(!helpDir.exists()); } diff --git a/test/qt/ui/widget/test_ReaderDriverModel.cpp b/test/qt/ui/widget/test_ReaderDriverModel.cpp index b8776d25e..35aa90afc 100644 --- a/test/qt/ui/widget/test_ReaderDriverModel.cpp +++ b/test/qt/ui/widget/test_ReaderDriverModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2017-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2017-2020 Governikus GmbH & Co. KG, Germany */ #include "ReaderDriverModel.h" @@ -137,10 +137,10 @@ class test_ReaderDriverModel void test_04_usbId_readerManager_equal() { #if defined(Q_OS_FREEBSD) - QSKIP("No driver available for UsbId(0x0D46, 0x301D) on FreeBSD"); + QSKIP("No driver available for UsbId(0x04E6, 0x5790) on FreeBSD"); #endif - mUsbIds += UsbId(0x0D46, 0x301D); // KOBIL Systems IDToken - mReaderInfos += ReaderInfo("KOBIL Systems IDToken (NS1252PT188E1) 00 00", ReaderManagerPlugInType::PCSC); + mUsbIds += UsbId(0x04E6, 0x5790); // Identiv Cloud 3700 F + mReaderInfos += ReaderInfo("Identiv CLOUD 3700 F Contactless Reader 0", ReaderManagerPlugInType::PCSC); ReaderDriverModel readerDriverModel; QCOMPARE(readerDriverModel.rowCount(), 1); @@ -152,11 +152,11 @@ class test_ReaderDriverModel void test_05_usbId_readerManager_different() { #if defined(Q_OS_FREEBSD) - QSKIP("No driver available for UsbId(0x0C4B, 0x0501) on FreeBSD"); + QSKIP("No driver available for UsbId(0x04E6, 0x5790) on FreeBSD"); #endif mUsbIds += UsbId(0x0C4B, 0x0501); // REINER SCT cyberJack RFID komfort - mUsbIds += UsbId(0x0D46, 0x301D); // KOBIL Systems IDToken - mReaderInfos += ReaderInfo("KOBIL Systems IDToken (NS1252PT188E1) 00 00", ReaderManagerPlugInType::PCSC); + mUsbIds += UsbId(0x04E6, 0x5790); // Identiv Cloud 3700 F + mReaderInfos += ReaderInfo("Identiv CLOUD 3700 F Contactless Reader 0", ReaderManagerPlugInType::PCSC); QModelIndex index; ReaderDriverModel readerDriverModel; diff --git a/test/qt/whitelist_client/test_SurveyModel.cpp b/test/qt/whitelist_client/test_SurveyModel.cpp index 3edf6f139..4bb6d674b 100644 --- a/test/qt/whitelist_client/test_SurveyModel.cpp +++ b/test/qt/whitelist_client/test_SurveyModel.cpp @@ -1,5 +1,5 @@ /*! - * \copyright Copyright (c) 2018-2019 Governikus GmbH & Co. KG, Germany + * \copyright Copyright (c) 2018-2020 Governikus GmbH & Co. KG, Germany */ #include "SurveyModel.h" diff --git a/uncrustify.cfg b/uncrustify.cfg index 5a69ccc8c..421db65ac 100644 --- a/uncrustify.cfg +++ b/uncrustify.cfg @@ -1,4 +1,4 @@ -# Uncrustify-0.69.0_f +# Uncrustify_d-0.70.1_f newlines = lf input_tab_size = 4 output_tab_size = 4 @@ -12,11 +12,16 @@ enable_digraphs = false utf8_bom = remove utf8_byte = false utf8_force = false +sp_do_brace_open = ignore +sp_brace_close_while = ignore +sp_while_paren_open = ignore sp_arith = force sp_arith_additive = ignore sp_assign = force sp_cpp_lambda_assign = ignore -sp_cpp_lambda_paren = ignore +sp_cpp_lambda_square_paren = ignore +sp_cpp_lambda_square_brace = ignore +sp_cpp_lambda_fparen = ignore sp_assign_default = force sp_before_assign = force sp_after_assign = force @@ -80,6 +85,8 @@ sp_after_semi = add sp_after_semi_for = force sp_after_semi_for_empty = remove sp_before_square = ignore +sp_before_vardef_square = remove +sp_before_square_asm_block = ignore sp_before_squares = ignore sp_cpp_before_struct_binding = ignore sp_inside_square = remove @@ -120,10 +127,12 @@ sp_before_type_brace_init_lst_close = ignore sp_inside_type_brace_init_lst = ignore sp_inside_braces = remove sp_inside_braces_empty = remove +sp_trailing_return = ignore sp_type_func = remove sp_type_brace_init_lst = ignore sp_func_proto_paren = remove sp_func_proto_paren_empty = ignore +sp_func_type_paren = ignore sp_func_def_paren = remove sp_func_def_paren_empty = ignore sp_inside_fparens = remove @@ -262,6 +271,7 @@ indent_shift = false indent_func_def_force_col1 = false indent_func_call_param = true indent_func_def_param = true +indent_func_def_param_paren_pos_threshold = 0 indent_func_proto_param = false indent_func_class_param = false indent_func_ctor_var_param = false @@ -269,11 +279,13 @@ indent_template_param = false indent_func_param_double = true indent_func_const = 0 indent_func_throw = 0 +indent_macro_brace = true indent_member = 0 indent_member_single = false indent_sing_line_comments = 0 indent_relative_single_line_comments = false indent_switch_case = 4 +indent_switch_break_with_case = false indent_switch_pp = true indent_case_shift = 0 indent_case_brace = 0 @@ -328,6 +340,9 @@ nl_for_leave_one_liners = false nl_oc_msg_leave_one_liner = false nl_oc_mdef_brace = ignore nl_oc_block_brace = ignore +nl_oc_before_interface = ignore +nl_oc_before_implementation = ignore +nl_oc_before_end = ignore nl_oc_interface_brace = ignore nl_oc_implementation_brace = ignore nl_start_of_file = remove @@ -374,6 +389,8 @@ nl_brace_while = force nl_switch_brace = force nl_synchronized_brace = ignore nl_multi_line_cond = false +nl_multi_line_sparen_open = ignore +nl_multi_line_sparen_close = ignore nl_multi_line_define = false nl_before_case = true nl_after_case = true @@ -381,6 +398,17 @@ nl_case_colon_brace = ignore nl_before_throw = ignore nl_namespace_brace = force nl_template_class = ignore +nl_template_class_decl = ignore +nl_template_class_decl_special = ignore +nl_template_class_def = ignore +nl_template_class_def_special = ignore +nl_template_func = ignore +nl_template_func_decl = ignore +nl_template_func_decl_special = ignore +nl_template_func_def = ignore +nl_template_func_def_special = ignore +nl_template_var = ignore +nl_template_using = ignore nl_class_brace = force nl_class_init_args = force nl_constr_init_args = ignore @@ -419,6 +447,9 @@ nl_func_call_start = ignore nl_func_call_start_multi_line = false nl_func_call_args_multi_line = false nl_func_call_end_multi_line = false +nl_template_start = false +nl_template_args = false +nl_template_end = false nl_oc_msg_args = false nl_fdef_brace = force nl_fdef_brace_cond = ignore @@ -454,6 +485,8 @@ nl_before_do = ignore nl_after_do = ignore nl_before_return = false nl_after_return = true +nl_before_member = ignore +nl_after_member = ignore nl_ds_struct_enum_cmt = false nl_ds_struct_enum_close_brace = false nl_class_colon = force @@ -463,6 +496,7 @@ nl_create_if_one_liner = false nl_create_for_one_liner = false nl_create_while_one_liner = false nl_create_func_def_one_liner = false +nl_create_list_one_liner = false nl_split_if_one_liner = false nl_split_for_one_liner = false nl_split_while_one_liner = false @@ -495,6 +529,9 @@ nl_after_label_colon = false nl_after_struct = 0 nl_before_class = 0 nl_after_class = 2 +nl_before_namespace = 0 +nl_inside_namespace = 0 +nl_after_namespace = 0 nl_before_access_spec = 2 nl_after_access_spec = 1 nl_comment_func_def = 1 @@ -502,7 +539,6 @@ nl_after_try_catch_finally = 0 nl_around_cs_property = 0 nl_between_get_set = 0 nl_property_brace = ignore -nl_inside_namespace = 0 eat_blanks_after_open_brace = false eat_blanks_before_close_brace = false nl_remove_extra_newlines = 0 @@ -632,6 +668,7 @@ mod_add_long_class_closebrace_comment = 0 mod_add_long_switch_closebrace_comment = 0 mod_add_long_ifdef_endif_comment = 0 mod_add_long_ifdef_else_comment = 0 +mod_sort_case_sensitive = false mod_sort_import = true mod_sort_using = false mod_sort_include = true @@ -668,6 +705,7 @@ include_category_2 = "" use_indent_func_call_param = true use_indent_continue_only_once = false indent_cpp_lambda_only_once = false +use_sp_after_angle_always = false use_options_overriding_for_qt_macros = true warn_level_tabs_found_in_verbatim_string_literals = 2 macro-open ASN1_ITEM_TEMPLATE