From ebd033a3e6b3fd7bb04b1121615e22323c691d01 Mon Sep 17 00:00:00 2001 From: Julien Wadel Date: Wed, 9 Mar 2022 17:11:12 +0100 Subject: [PATCH] On default build : Revert webview subscription and keep old sheets (avoid deployment issues) but keep a way to reactivate it. --- .gitlab-ci.yml | 4 +- CMakeLists.txt | 12 +- linphone-app/CMakeLists.txt | 31 ++- linphone-app/assets/images/chat_delivered.svg | 122 ++++++------ linphone-app/assets/images/chat_read.svg | 121 ++++++------ linphone-app/assets/languages/da.ts | 60 ++++++ linphone-app/assets/languages/de.ts | 60 ++++++ linphone-app/assets/languages/en.ts | 19 ++ linphone-app/assets/languages/es.ts | 60 ++++++ linphone-app/assets/languages/fr_FR.ts | 34 ++++ linphone-app/assets/languages/hu.ts | 60 ++++++ linphone-app/assets/languages/it.ts | 60 ++++++ linphone-app/assets/languages/ja.ts | 60 ++++++ linphone-app/assets/languages/lt.ts | 60 ++++++ linphone-app/assets/languages/pt_BR.ts | 60 ++++++ linphone-app/assets/languages/ru.ts | 60 ++++++ linphone-app/assets/languages/sv.ts | 60 ++++++ linphone-app/assets/languages/tr.ts | 83 ++++++-- linphone-app/assets/languages/uk.ts | 60 ++++++ linphone-app/assets/languages/zh_CN.ts | 60 ++++++ .../linphone_package/CMakeLists.txt | 49 ++++- .../linphone_package/packaging.cmake.in | 10 +- linphone-app/src/app/AppController.cpp | 9 +- .../components/assistant/AssistantModel.cpp | 6 +- .../src/components/settings/SettingsModel.cpp | 21 +- .../src/components/settings/SettingsModel.hpp | 2 + linphone-app/src/config.h.cmake | 1 + linphone-app/tools/create_appimage.sh | 21 +- .../modules/Common/Form/DroppableTextArea.qml | 6 +- linphone-app/ui/modules/Common/Image/Icon.qml | 6 +- .../modules/Linphone/Blocks/RequestBlock.qml | 122 ++++++------ .../modules/Linphone/Chat/ChatFileMessage.qml | 3 + .../Styles/Blocks/RequestBlockStyle.qml | 2 +- .../Linphone/Styles/Chat/ChatStyle.qml | 6 +- .../Main/Assistant/AssistantAbstractView.qml | 7 + .../App/Main/Assistant/AssistantHome.qml | 10 +- .../Main/Assistant/CreateAppSipAccount.qml | 186 +++--------------- .../CreateAppSipAccountWithWebView.qml | 167 ++++++++++++++++ .../App/Main/Assistant/UseOtherSipAccount.qml | 90 +++++---- linphone-app/webview_resources.qrc | 5 + 40 files changed, 1418 insertions(+), 457 deletions(-) create mode 100644 linphone-app/ui/views/App/Main/Assistant/CreateAppSipAccountWithWebView.qml create mode 100644 linphone-app/webview_resources.qrc diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a5a833186..cb9617223 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -41,8 +41,8 @@ include: #- '.gitlab-ci-files/job-linux-desktop-debian8.yml' #Removed as there is 5.10 and not at least 5.12 - '.gitlab-ci-files/job-linux-desktop-debian9.yml' ## - '.gitlab-ci-files/job-linux-desktop-debian10.yml' - - '.gitlab-ci-files/job-linux-desktop-ubuntu-rolling.yml' - - '.gitlab-ci-files/job-linux-desktop-archlinux-latest.yml' +# - '.gitlab-ci-files/job-linux-desktop-ubuntu-rolling.yml' #Removed as there is no QtWebengine in image +# - '.gitlab-ci-files/job-linux-desktop-archlinux-latest.yml' #Removed as there is no QtWebengine in image # - '.gitlab-ci-files/job-linux-desktop-centos7.yml' #QtWebengine cannot be build (support for C++14 is not found in configuration) - '.gitlab-ci-files/job-windows-desktop.yml' - '.gitlab-ci-files/job-macosx-desktop.yml' diff --git a/CMakeLists.txt b/CMakeLists.txt index a8de3b685..2cf1928b7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -38,14 +38,7 @@ endforeach() if(ENABLE_BUILD_VERBOSE) message("User Args : ${USER_ARGS}") endif() -if(WIN32) - if(NOT ${CMAKE_GENERATOR} MATCHES "Ninja") - if(NOT CMAKE_GENERATOR_PLATFORM) - set(CMAKE_GENERATOR_PLATFORM "Win32") - message(STATUS "Setting Platform to ${CMAKE_GENERATOR_PLATFORM}") - endif() - endif() -elseif( APPLE ) +if( APPLE ) if( NOT CMAKE_OSX_DEPLOYMENT_TARGET) set(CMAKE_OSX_DEPLOYMENT_TARGET "10.9" CACHE STRING "Minimum OS X deployment version") endif() @@ -117,6 +110,8 @@ option(ENABLE_CONSOLE_UI "Turn on or off compilation of console interface." NO) option(ENABLE_APP_LICENSE "Enable the license in packages." YES) +#Webview is not fully supported because of deployments. Used for subscription. +option(ENABLE_APP_WEBVIEW "Enable webviews." NO) @@ -144,6 +139,7 @@ list(APPEND APP_OPTIONS "-DENABLE_CONSOLE_UI=${ENABLE_CONSOLE_UI}") list(APPEND APP_OPTIONS "-DENABLE_VIDEO=${ENABLE_VIDEO}") list(APPEND APP_OPTIONS "-DENABLE_APP_LICENSE=${ENABLE_APP_LICENSE}") list(APPEND APP_OPTIONS "-DENABLE_LDAP=YES") +list(APPEND APP_OPTIONS "-DENABLE_APP_WEBVIEW=${ENABLE_APP_WEBVIEW}") diff --git a/linphone-app/CMakeLists.txt b/linphone-app/CMakeLists.txt index fc3118677..be3b60e57 100644 --- a/linphone-app/CMakeLists.txt +++ b/linphone-app/CMakeLists.txt @@ -96,13 +96,18 @@ if( WIN32) endif() set(CMAKE_INCLUDE_CURRENT_DIR ON)#useful for config.h -set(QT5_PACKAGES Core Gui Quick Widgets QuickControls2 Svg LinguistTools Concurrent Network Test WebView) +set(QT5_PACKAGES Core Gui Quick Widgets QuickControls2 Svg LinguistTools Concurrent Network Test) +if(ENABLE_APP_WEBVIEW) + list(APPEND QT5_PACKAGES WebView WebEngine WebEngineCore) + add_definitions(-DENABLE_WEBVIEW) +endif() if (UNIX AND NOT APPLE) list(APPEND QT5_PACKAGES DBus) endif () set(QT5_PACKAGES_OPTIONAL TextToSpeech) set(CMAKE_AUTOMOC ON) + find_package(Qt5 COMPONENTS ${QT5_PACKAGES} REQUIRED) find_package(Qt5 COMPONENTS ${QT5_PACKAGES_OPTIONAL} QUIET) @@ -378,6 +383,9 @@ else () endif () set(QRC_RESOURCES resources.qrc) +if(ENABLE_APP_WEBVIEW) + set(QRC_WEBVIEW_RESOURCES webview_resources.qrc) +endif() #qt5_add_big_resources(QRC_BIG_RESOURCES resources.qrc) #Use this macro if resources size is too high @@ -409,6 +417,10 @@ PREPEND(PLUGIN_HEADERS "${CMAKE_CURRENT_SOURCE_DIR}/") set(QML_SOURCES) file(STRINGS ${QRC_RESOURCES} QRC_RESOURCES_CONTENT) +if(ENABLE_APP_WEBVIEW) + file(STRINGS ${QRC_WEBVIEW_RESOURCES} QRC_WEBVIEW_RESOURCES_CONTENT) + list(APPEND QRC_RESOURCES_CONTENT ${QRC_WEBVIEW_RESOURCES_CONTENT}) +endif() foreach (line ${QRC_RESOURCES_CONTENT}) set(result) string(REGEX REPLACE @@ -490,7 +502,7 @@ if(WIN32) endif() add_library(${APP_PLUGIN} SHARED ${PLUGIN_SOURCES} ${PLUGIN_HEADERS}) -add_library(${APP_LIBRARY} OBJECT ${SOURCES} ${HEADERS} ${QML_SOURCES} ${QRC_RESOURCES} ${PLUGIN_HEADERS})#Need to add Headers to resolve moc Qt symbols +add_library(${APP_LIBRARY} OBJECT ${SOURCES} ${HEADERS} ${QML_SOURCES} ${QRC_RESOURCES} ${QRC_WEBVIEW_RESOURCES} ${PLUGIN_HEADERS})#Need to add Headers to resolve moc Qt symbols if (WIN32) add_executable(${TARGET_NAME} WIN32 $ ${MAIN_FILE} ${QRC_BIG_RESOURCES} ${RC_FILE}) @@ -554,7 +566,10 @@ foreach (package ${QT5_PACKAGES}) # `qt5_create_translation` is provided from `LinguistTools` package. # But the `Qt5::LinguistTools` lib does not exist. Remove it. if (NOT (${package} STREQUAL LinguistTools)) - list(APPEND LIBRARIES ${Qt5${package}_LIBRARIES}) + # list(APPEND LIBRARIES ${Qt5${package}_LIBRARIES}) + target_link_libraries(${APP_LIBRARY} Qt5::${package}) + target_link_libraries(${APP_PLUGIN} Qt5::${package}) + target_link_libraries(${TARGET_NAME} Qt5::${package}) endif () endforeach () @@ -588,8 +603,8 @@ target_link_libraries(${TARGET_NAME} ${LIBRARIES}) target_link_libraries(${TARGET_NAME} ${APP_PLUGIN}) if(WIN32) - find_library(LDAP_LIBRARIES NAMES ldap libldap HINTS "${LINPHONE_OUTPUT_DIR}/lib") - find_library(LBER_LIBRARIES NAMES lber liblber HINTS "${LINPHONE_OUTPUT_DIR}/lib") + find_library(LDAP_LIBRARIES NAMES ldap libldap HINTS "${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_LIBDIR}") + find_library(LBER_LIBRARIES NAMES lber liblber HINTS "${LINPHONE_OUTPUT_DIR}/${CMAKE_INSTALL_LIBDIR}") target_link_libraries(${TARGET_NAME} wsock32 ws2_32 ${LDAP_LIBRARIES} ${LBER_LIBRARIES}) endif() @@ -604,9 +619,9 @@ set(TOOLS_DIR "${CMAKE_BINARY_DIR}/programs") set(LINPHONE_BUILDER_SIGNING_IDENTITY ${LINPHONE_BUILDER_SIGNING_IDENTITY}) add_custom_command(TARGET ${TARGET_NAME} PRE_BUILD COMMAND ${CMAKE_COMMAND} -E copy_directory "${CMAKE_CURRENT_SOURCE_DIR}/include/" "${CMAKE_INSTALL_PREFIX}/include/") -add_custom_command(TARGET ${APP_PLUGIN} POST_BUILD COMMAND ${CMAKE_COMMAND} -E make_directory "${CMAKE_INSTALL_PREFIX}/lib/") -add_custom_command(TARGET ${APP_PLUGIN} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy $ "${CMAKE_INSTALL_PREFIX}/lib/") -add_custom_command(TARGET ${APP_PLUGIN} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy $ "${CMAKE_INSTALL_PREFIX}/lib/") +add_custom_command(TARGET ${APP_PLUGIN} POST_BUILD COMMAND ${CMAKE_COMMAND} -E make_directory "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/") +add_custom_command(TARGET ${APP_PLUGIN} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy $ "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/") +add_custom_command(TARGET ${APP_PLUGIN} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy $ "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/") #add_custom_command(TARGET ${TARGET_NAME} PRE_BUILD COMMAND ${CMAKE_COMMAND} -E copy "${CMAKE_CURRENT_SOURCE_DIR}/include/LinphoneApp/*" "${CMAKE_INSTALL_PREFIX}/include/LinphoneApp/") #configure_file("${CMAKE_CURRENT_SOURCE_DIR}/include/*" "${CMAKE_INSTALL_PREFIX}/include/LinphoneApp/" COPYONLY) install(DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/include" DESTINATION ".") diff --git a/linphone-app/assets/images/chat_delivered.svg b/linphone-app/assets/images/chat_delivered.svg index 6d363cd12..2e49394ed 100644 --- a/linphone-app/assets/images/chat_delivered.svg +++ b/linphone-app/assets/images/chat_delivered.svg @@ -1,78 +1,68 @@ + inkscape:version="1.1.2 (0a00cf5339, 2022-02-04)" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns="http://www.w3.org/2000/svg" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:dc="http://purl.org/dc/elements/1.1/"> + + + imdn_read + + + + + id="metadata830"> - image/svg+xml - - chat_delivered + imdn_read - - - chat_delivered - Created with Sketch. - - - - - - - - - diff --git a/linphone-app/assets/images/chat_read.svg b/linphone-app/assets/images/chat_read.svg index aca186b50..f1fd33842 100644 --- a/linphone-app/assets/images/chat_read.svg +++ b/linphone-app/assets/images/chat_read.svg @@ -1,78 +1,67 @@ + inkscape:version="1.1.2 (0a00cf5339, 2022-02-04)" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns="http://www.w3.org/2000/svg" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:dc="http://purl.org/dc/elements/1.1/"> + + + imdn_read + + + + + id="metadata830"> - image/svg+xml - - chat_read + imdn_read - - - chat_read - Created with Sketch. - - - - - - - - - diff --git a/linphone-app/assets/languages/da.ts b/linphone-app/assets/languages/da.ts index 33284f969..6139f4874 100644 --- a/linphone-app/assets/languages/da.ts +++ b/linphone-app/assets/languages/da.ts @@ -7,6 +7,11 @@ ok OK + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -897,6 +902,25 @@ Server url ikke konfigureret. + + CreateAppSipAccount + + createAppSipAccountDescription + Hvordan vil du oprette din konto? + + + createAppSipAccountTitle + OPRET EN %1 KONTO + + + withPhoneNumber + MED ET TELEFONNUMMER + + + withEmailAddress + MED EN E-MAILADRESSE + + CreateAppSipAccountWithEmail @@ -2606,6 +2630,16 @@ Klik her: <a href="%1">%1</a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2805,6 +2839,11 @@ Klik her: <a href="%1">%1</a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2856,6 +2895,7 @@ Klik her: <a href="%1">%1</a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form BRUG @@ -2886,6 +2926,26 @@ Klik her: <a href="%1">%1</a> addOtherSipAccountError Umuligt at oprette kontoen. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/de.ts b/linphone-app/assets/languages/de.ts index dd17cb25d..aeccd9f45 100644 --- a/linphone-app/assets/languages/de.ts +++ b/linphone-app/assets/languages/de.ts @@ -7,6 +7,11 @@ ok OK + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -897,6 +902,25 @@ Server URL ist nicht konfiguriert. Nachrichten durchsuchen + + CreateAppSipAccount + + createAppSipAccountDescription + Wie würden Sie gerne Ihr Konto erstellen? + + + createAppSipAccountTitle + ERSTELLE EIN %1 KONTO + + + withPhoneNumber + MIT EINER TELEFONNUMMER + + + withEmailAddress + MIT EINER E-MAIL-ADRESSE + + CreateAppSipAccountWithEmail @@ -2606,6 +2630,16 @@ Klicken Sie hier: <a href="%1">%1</a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. Mipmap-Filterung führt bei Verkleinerung im Vergleich zu "Smooth" zu besserer Bildqualität, aber es ist langsamer (sowohl beim Initialisieren als auch bei der Anzeige). + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2805,6 +2839,11 @@ Klicken Sie hier: <a href="%1">%1</a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2856,6 +2895,7 @@ Klicken Sie hier: <a href="%1">%1</a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form VERWENDEN @@ -2886,6 +2926,26 @@ Klicken Sie hier: <a href="%1">%1</a> addOtherSipAccountError Dieses Konto kann nicht hinzugefügt werden. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/en.ts b/linphone-app/assets/languages/en.ts index 44a70bac8..49519b982 100644 --- a/linphone-app/assets/languages/en.ts +++ b/linphone-app/assets/languages/en.ts @@ -902,6 +902,25 @@ Server URL not configured. Search messages + + CreateAppSipAccount + + createAppSipAccountDescription + How would you like to create your account? + + + createAppSipAccountTitle + CREATE A %1 ACCOUNT + + + withPhoneNumber + WITH A PHONE NUMBER + + + withEmailAddress + WITH AN EMAIL ADDRESS + + CreateAppSipAccountWithEmail diff --git a/linphone-app/assets/languages/es.ts b/linphone-app/assets/languages/es.ts index 7180e3972..d181adc86 100644 --- a/linphone-app/assets/languages/es.ts +++ b/linphone-app/assets/languages/es.ts @@ -7,6 +7,11 @@ ok OK + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -897,6 +902,25 @@ URL del servidor no configurada. + + CreateAppSipAccount + + createAppSipAccountDescription + ¿Cómo prefieres crear tu cuenta? + + + createAppSipAccountTitle + CREAR UNA CUENTA %1 + + + withPhoneNumber + CON UN NÚMERO DE TELÉFONO + + + withEmailAddress + CON UN CORREO ELECTRÓNICO + + CreateAppSipAccountWithEmail @@ -2606,6 +2630,16 @@ Haga clic aquí: <a href="%1">%1 </a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2805,6 +2839,11 @@ Haga clic aquí: <a href="%1">%1 </a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2856,6 +2895,7 @@ Haga clic aquí: <a href="%1">%1 </a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form USE @@ -2886,6 +2926,26 @@ Haga clic aquí: <a href="%1">%1 </a> addOtherSipAccountError Imposible añadir esta cuenta. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/fr_FR.ts b/linphone-app/assets/languages/fr_FR.ts index 2a9c3333c..acc9012e7 100644 --- a/linphone-app/assets/languages/fr_FR.ts +++ b/linphone-app/assets/languages/fr_FR.ts @@ -902,6 +902,25 @@ URL du serveur non configurée. Rechercher dans les messages + + CreateAppSipAccount + + createAppSipAccountDescription + Comment souhaitez-vous créer votre compte ? + + + createAppSipAccountTitle + CRÉER UN COMPTE %1 + + + withPhoneNumber + AVEC UN NUMÉRO DE TÉLÉPHONE + + + withEmailAddress + AVEC UNE ADRESSE EMAIL + + CreateAppSipAccountWithEmail @@ -2611,6 +2630,16 @@ Cliquez ici : <a href="%1">%1</a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. Lorsque les images sont rétrécies, un filtre Mipmap a une meilleure qualité visuelle par rapport à un lissage standard mais nécessite plus de calculs lors de l'initialisation des images et pendant le rendu. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2810,6 +2839,11 @@ Cliquez ici : <a href="%1">%1</a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. Sans éphémères + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount diff --git a/linphone-app/assets/languages/hu.ts b/linphone-app/assets/languages/hu.ts index fdc5a3dff..23895a002 100644 --- a/linphone-app/assets/languages/hu.ts +++ b/linphone-app/assets/languages/hu.ts @@ -7,6 +7,11 @@ ok Rendben + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -892,6 +897,25 @@ A kiszolgáló URL-je nincs konfigurálva. Üzenetek keresése + + CreateAppSipAccount + + createAppSipAccountDescription + Hogyan szeretné létrehozni a fiókját? + + + createAppSipAccountTitle + %1 fiók létrehozása + + + withPhoneNumber + Telefonszámmal + + + withEmailAddress + E-mail címmel + + CreateAppSipAccountWithEmail @@ -2595,6 +2619,16 @@ Kattintson ide: <a href="%1">%1</a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. A mipmap-szűrés jobb vizuális minőséget biztosít kicsinyítéskor, mint a sima, de teljesítményköltséggel járhat (mind a kép inicializálásakor, mind a renderelés során). + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2794,6 +2828,11 @@ Kattintson ide: <a href="%1">%1</a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. Elmúlók nélkül + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2845,6 +2884,7 @@ Kattintson ide: <a href="%1">%1</a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form Használat @@ -2875,6 +2915,26 @@ Kattintson ide: <a href="%1">%1</a> addOtherSipAccountError Nem sikerült hozzáadni ezt a fiókot. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/it.ts b/linphone-app/assets/languages/it.ts index 6525e0eb8..3b9cd3b1a 100644 --- a/linphone-app/assets/languages/it.ts +++ b/linphone-app/assets/languages/it.ts @@ -7,6 +7,11 @@ ok OK + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -897,6 +902,25 @@ URL del server non configurato. + + CreateAppSipAccount + + createAppSipAccountDescription + Come ti piacerebbe creare il tuo account? + + + createAppSipAccountTitle + CREA UN ACCOUNT %1 + + + withPhoneNumber + CON UN NUMERO DI TELEFONO + + + withEmailAddress + CON UN INDIRIZZO E-MAIL + + CreateAppSipAccountWithEmail @@ -2606,6 +2630,16 @@ Clicca: <a href="%1">%1</a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2805,6 +2839,11 @@ Clicca: <a href="%1">%1</a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2856,6 +2895,7 @@ Clicca: <a href="%1">%1</a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form USA @@ -2886,6 +2926,26 @@ Clicca: <a href="%1">%1</a> addOtherSipAccountError Impossibile aggiungere questo account. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/ja.ts b/linphone-app/assets/languages/ja.ts index 44a2f708e..2adce7b1b 100644 --- a/linphone-app/assets/languages/ja.ts +++ b/linphone-app/assets/languages/ja.ts @@ -7,6 +7,11 @@ ok OK + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -892,6 +897,25 @@ + + CreateAppSipAccount + + createAppSipAccountDescription + どのようにアカウントを作成しますか? + + + createAppSipAccountTitle + %1アカウントを作成する + + + withPhoneNumber + 電話番号を利用 + + + withEmailAddress + メールアドレスを利用 + + CreateAppSipAccountWithEmail @@ -2595,6 +2619,16 @@ 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2794,6 +2828,11 @@ 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2845,6 +2884,7 @@ UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form 使う @@ -2875,6 +2915,26 @@ addOtherSipAccountError このアカウントを追加出来ませんでした。 + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/lt.ts b/linphone-app/assets/languages/lt.ts index 26624c7e5..e6f176d55 100644 --- a/linphone-app/assets/languages/lt.ts +++ b/linphone-app/assets/languages/lt.ts @@ -7,6 +7,11 @@ ok GERAI + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -902,6 +907,25 @@ Nesukonfigūruotas serverio url. + + CreateAppSipAccount + + createAppSipAccountDescription + Kaip norėtumėte susikurti savo paskyrą? + + + createAppSipAccountTitle + SUSIKURTI %1 PASKYRĄ + + + withPhoneNumber + NAUDOJANT TELEFONO NUMERĮ + + + withEmailAddress + NAUDOJANT EL. PAŠTO ADRESĄ + + CreateAppSipAccountWithEmail @@ -2617,6 +2641,16 @@ Spustelėkite čia: <a href="%1">%1</a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2816,6 +2850,11 @@ Spustelėkite čia: <a href="%1">%1</a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2867,6 +2906,7 @@ Spustelėkite čia: <a href="%1">%1</a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form NAUDOTI @@ -2897,6 +2937,26 @@ Spustelėkite čia: <a href="%1">%1</a> addOtherSipAccountError Nepavyko pridėti šios paskyros. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/pt_BR.ts b/linphone-app/assets/languages/pt_BR.ts index aea4c85a9..a69a4954d 100644 --- a/linphone-app/assets/languages/pt_BR.ts +++ b/linphone-app/assets/languages/pt_BR.ts @@ -7,6 +7,11 @@ ok OK + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -897,6 +902,25 @@ URL do servidor não configurado. Pesquisar mensagens + + CreateAppSipAccount + + createAppSipAccountDescription + Como você gostaria de criar sua conta? + + + createAppSipAccountTitle + CRIAR UMA CONTA %1 + + + withPhoneNumber + COM UM NÚMERO DE TELEFONE + + + withEmailAddress + COM UM ENDEREÇO DE E-MAIL + + CreateAppSipAccountWithEmail @@ -2606,6 +2630,16 @@ Clique aqui: <a href="%1">%1 </a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2805,6 +2839,11 @@ Clique aqui: <a href="%1">%1 </a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2856,6 +2895,7 @@ Clique aqui: <a href="%1">%1 </a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form USO @@ -2886,6 +2926,26 @@ Clique aqui: <a href="%1">%1 </a> addOtherSipAccountError Não foi possível adicionar esta conta. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/ru.ts b/linphone-app/assets/languages/ru.ts index f4c2e5b65..acd2bf840 100644 --- a/linphone-app/assets/languages/ru.ts +++ b/linphone-app/assets/languages/ru.ts @@ -7,6 +7,11 @@ ok OK + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -902,6 +907,25 @@ + + CreateAppSipAccount + + createAppSipAccountDescription + Как бы вы хотели создать аккаунт? + + + createAppSipAccountTitle + СОЗДАТЬ АККАУНТ %1 + + + withPhoneNumber + С ПОМОЩЬЮ НОМЕРА ТЕЛЕФОНА + + + withEmailAddress + С ПОМОЩЬЮ EMAIL + + CreateAppSipAccountWithEmail @@ -2617,6 +2641,16 @@ 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2816,6 +2850,11 @@ 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2867,6 +2906,7 @@ UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form ИСПОЛЬЗОВАТЬ @@ -2897,6 +2937,26 @@ addOtherSipAccountError Не удалось добавить этот аккаунт. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/sv.ts b/linphone-app/assets/languages/sv.ts index 0aad02719..5257a3cb2 100644 --- a/linphone-app/assets/languages/sv.ts +++ b/linphone-app/assets/languages/sv.ts @@ -7,6 +7,11 @@ ok OK + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -897,6 +902,25 @@ Serverwebbadressen är inte konfigurerad. + + CreateAppSipAccount + + createAppSipAccountDescription + Hur vill du skapa ditt konto? + + + createAppSipAccountTitle + SKAPA ETT %1-KONTO + + + withPhoneNumber + MED ETT TELEFONNUMMER + + + withEmailAddress + MED E-POSTADRESS + + CreateAppSipAccountWithEmail @@ -2606,6 +2630,16 @@ Klicka här: <a href="%1">%1</a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2805,6 +2839,11 @@ Klicka här: <a href="%1">%1</a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2856,6 +2895,7 @@ Klicka här: <a href="%1">%1</a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form ANVÄND @@ -2886,6 +2926,26 @@ Klicka här: <a href="%1">%1</a> addOtherSipAccountError Det gick inte att lägga till det här kontot. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/tr.ts b/linphone-app/assets/languages/tr.ts index 0b79ae8f1..16723f486 100644 --- a/linphone-app/assets/languages/tr.ts +++ b/linphone-app/assets/languages/tr.ts @@ -7,6 +7,11 @@ ok TAMAM + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -470,7 +475,6 @@ Sunucu url'si yapılandırılmadı. '%1 is typing...' indicate that someone is composing in chat %1 yazıyor… - %1 yazıyor… @@ -572,28 +576,24 @@ Sunucu url'si yapılandırılmadı. nMinute %1 dakika - %1 dakika nHour %1 saat - %1 saat nDay %1 gün - %1 gün nWeek %1 hafta - %1 hafta @@ -897,6 +897,25 @@ Sunucu url'si yapılandırılmadı. İletileri ara + + CreateAppSipAccount + + createAppSipAccountDescription + Hesabınızı nasıl oluşturmak istersiniz? + + + createAppSipAccountTitle + %1 HESABI OLUŞTUR + + + withPhoneNumber + TELEFON NUMARASIYLA + + + withEmailAddress + E-POSTA ADRESİYLE + + CreateAppSipAccountWithEmail @@ -1019,28 +1038,28 @@ Sunucu url'si yapılandırılmadı. nMinute '%1 minute' - + %1 dakika nHour '%1 hour' - + %1 saat nDay '%1 day' - + %1 gün nWeek '%1 week' - + %1 hafta @@ -1238,7 +1257,7 @@ Sunucu url'si yapılandırılmadı. adminStatus 'Admin' : Admin(istrator) - + Yönetici word for admin status @@ -1381,7 +1400,7 @@ Buraya tıklayın: <a href="%1">%1</a> checkForUpdates 'Check for updates' : Item menu for checking updates - + Güncellemeleri denetle @@ -1401,7 +1420,7 @@ Buraya tıklayın: <a href="%1">%1</a> checkForUpdates 'Check for updates' : Item menu for checking updates - + Güncellemeleri denetle @@ -1453,7 +1472,7 @@ Buraya tıklayın: <a href="%1">%1</a> missingConferenceURI 'You need to set the conference URI in your account settings to create a conference based chat room.' : Tooltip to warn the user that a setting is missong in its configuration. - + Toplantı tabanlı konuşma odası oluşturmak için hesap ayarlarınızda toplantı URI'si belirlemelisiniz. newChatRoomTitle @@ -1489,7 +1508,7 @@ Buraya tıklayın: <a href="%1">%1</a> adminStatus 'Admin' : Admin(istrator) - + Yönetici word for admin status @@ -2600,6 +2619,16 @@ Buraya tıklayın: <a href="%1">%1</a> 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2799,6 +2828,11 @@ Buraya tıklayın: <a href="%1">%1</a> 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2850,6 +2884,7 @@ Buraya tıklayın: <a href="%1">%1</a> UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form KULLAN @@ -2880,6 +2915,26 @@ Buraya tıklayın: <a href="%1">%1</a> addOtherSipAccountError Bu hesap eklenemiyor. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/uk.ts b/linphone-app/assets/languages/uk.ts index bf039e169..53a02f629 100644 --- a/linphone-app/assets/languages/uk.ts +++ b/linphone-app/assets/languages/uk.ts @@ -7,6 +7,11 @@ ok Так + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -902,6 +907,25 @@ + + CreateAppSipAccount + + createAppSipAccountDescription + Як би ви воліли створити обліківку? + + + createAppSipAccountTitle + СТВОРИТИ ОБЛІКІВКУ %1 + + + withPhoneNumber + ЗА ДОПОМОГОЮ НОМЕРУ ТЕЛЕФОНУ + + + withEmailAddress + ЗА ДОПОМОГОЮ EMAIL + + CreateAppSipAccountWithEmail @@ -2617,6 +2641,16 @@ 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2816,6 +2850,11 @@ 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2867,6 +2906,7 @@ UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form ВИКОРИСТОВУВАТИ @@ -2897,6 +2937,26 @@ addOtherSipAccountError Не вдалося додати цю обліківку. + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/assets/languages/zh_CN.ts b/linphone-app/assets/languages/zh_CN.ts index 530ccc237..179cef872 100644 --- a/linphone-app/assets/languages/zh_CN.ts +++ b/linphone-app/assets/languages/zh_CN.ts @@ -7,6 +7,11 @@ ok + + aboutTranslation + 'Help us translate %1' : %1 is the application name + + ActivateAppSipAccountWithEmail @@ -892,6 +897,25 @@ 查找信息 + + CreateAppSipAccount + + createAppSipAccountDescription + 您想要如何创建账户? + + + createAppSipAccountTitle + 创建一个 %1 账户 + + + withPhoneNumber + 用手机号码 + + + withEmailAddress + 用电子邮箱地址 + + CreateAppSipAccountWithEmail @@ -2595,6 +2619,16 @@ 'Mipmap filtering gives better visual quality when scaling down compared to smooth, but it may come at a performance cost (both when initializing the image and during rendering).' : Second line of a tooltip about Mipmap mode. + + minimalTimelineFilterLabel + 'Minimal Timeline filter' + + + + minimalTimelineFilterTooltip + 'Show a minimal version of what to display in timeline.' : + + SettingsVideo @@ -2794,6 +2828,11 @@ 'No Ephemerals' : Filter item. Selecting it will hide all chat rooms where the ephemeral mode has been enabled. + + timelineFilterConferences + 'Conferences' : Filter item. Selecting it will show all conferences. + + UseAppSipAccount @@ -2845,6 +2884,7 @@ UseOtherSipAccount confirmAction + 'Use' : Popup confirmation for a form 使用 @@ -2875,6 +2915,26 @@ addOtherSipAccountError 无法添加此账户。 + + understandAction + 'I understand' : Popup confirmation for a warning + + + + warningFeatures + 'Some features require a Linphone account, such as group messaging or ephemeral messaging.' : Warning text about features. + + + + warningThirdParty + 'These features are hidden when you register with a third party SIP account.' : Warning text for using third party account. + + + + warningContact + 'To enable it in a commercial project, please contact us.' : Warning text for contacting about enabling features. + + ZrtpTokenAuthentication diff --git a/linphone-app/cmake_builder/linphone_package/CMakeLists.txt b/linphone-app/cmake_builder/linphone_package/CMakeLists.txt index 27c982400..2d350bd1b 100644 --- a/linphone-app/cmake_builder/linphone_package/CMakeLists.txt +++ b/linphone-app/cmake_builder/linphone_package/CMakeLists.txt @@ -33,8 +33,16 @@ if (POLICY CMP0079) cmake_policy(SET CMP0079 NEW) endif () -set(LINPHONE_QML_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../../ui") - +set(LINPHONE_QML_DIR "WORK/qml_files/ui") +set(QT_PATH "${Qt5Core_DIR}/../../..") +install(CODE "execute_process(COMMAND \"${CMAKE_COMMAND}\" \"-E\" \"copy_directory\" \"${CMAKE_CURRENT_SOURCE_DIR}/../../ui\" \"${LINPHONE_QML_DIR}\" WORKING_DIRECTORY \"${CMAKE_INSTALL_PREFIX}/..\")") +if(NOT ENABLE_APP_WEBVIEW) + set(RM_COMMAND "rm") + if(CMAKE_VERSION VERSION_LESS 3.17) + set(RM_COMMAND "remove") + endif() + install(CODE "execute_process(COMMAND \"${CMAKE_COMMAND}\" \"-E\" \"${RM_COMMAND}\" \"-f\" \"${LINPHONE_QML_DIR}/views/App/Main/Assistant/CreateAppSipAccountWithWebView.qml\" WORKING_DIRECTORY \"${CMAKE_INSTALL_PREFIX}/..\")") +endif() # ============================================================================== # Build package version. # ============================================================================== @@ -147,8 +155,10 @@ if (WIN32) LIBRARY DESTINATION "${LIBDIR}" RUNTIME DESTINATION "${LIBDIR}" ) +#Workaround windeployqt bug on webview plugin : folder "webview" can be in bin/ where it should be in bin/plugins. Else, we got "Webview plugin not found" => use of --plugindir + install(CODE "execute_process(COMMAND ${DEPLOYQT_PROGRAM} \"\${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR}/${EXECUTABLE_NAME}.exe\" --qmldir=${LINPHONE_QML_DIR} --plugindir ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR}/plugins --compiler-runtime)")# -verbose=2)" COMPONENT binary_application) + - install(CODE "execute_process(COMMAND ${DEPLOYQT_PROGRAM} \"\${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR}/${EXECUTABLE_NAME}.exe\" -qmldir=${LINPHONE_QML_DIR} --compiler-runtime)")# -verbose=2)" COMPONENT binary_application) #On Windows, OpenLDAP couldn't be build with static libraries. Add them in installation for deployment. find_program(MSYS2_PROGRAM NAMES msys2_shell.cmd @@ -216,6 +226,7 @@ elseif (APPLE) if (NOT DEPLOYQT_PROGRAM) message(FATAL_ERROR "Could not find the macdeployqt program. Make sure it is in the PATH.") endif() + install(CODE "execute_process(COMMAND ${DEPLOYQT_PROGRAM} \${CMAKE_INSTALL_PREFIX}/${APPLICATION_NAME}.app -qmldir=${LINPHONE_QML_DIR} -no-strip )") if (LINPHONE_BUILDER_SIGNING_IDENTITY) @@ -296,6 +307,10 @@ else()# Not Windows and Apple LIBRARY DESTINATION "${LIBDIR}" RUNTIME DESTINATION "${LIBDIR}" ) +# WEBVIEW + if(ENABLE_APP_WEBVIEW) + install(FILES "${QT_PATH}/plugins/webview/libqtwebview_webengine.so" DESTINATION "plugins/webview") #Workaround : linuxdeploy doesn't deploy it + endif() endif () @@ -376,6 +391,34 @@ if(${ENABLE_APP_PACKAGING}) set(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${PACKAGE_VERSION}-win32") string(COMPARE EQUAL ${CPACK_GENERATOR} "NSIS" IS_NSIS) if (${IS_NSIS}) + find_program(NSIS_PROGRAM makensis) + if(NOT NSIS_PROGRAM) + if(MSVC) + set(MSVC_ARCH ${CMAKE_CXX_COMPILER_ARCHITECTURE_ID})# ${MSVC_ARCH} MATCHES "X64" + string(TOUPPER ${MSVC_ARCH} MSVC_ARCH) + if(${MSVC_ARCH} MATCHES "X64") + set(MINGW_PACKAGE_PREFIX "mingw-w64-x86_64-") + set(MINGW_TYPE "mingw64") + else() + set(MINGW_PACKAGE_PREFIX "mingw-w64-i686-") + set(MINGW_TYPE "mingw32") + endif() + elseif(CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64" OR CMAKE_SYSTEM_PROCESSOR STREQUAL "AMD64") + set(MINGW_PACKAGE_PREFIX "mingw-w64-x86_64-") + set(MINGW_TYPE "mingw64") + else() + set(MINGW_PACKAGE_PREFIX "mingw-w64-i686-") + set(MINGW_TYPE "mingw32") + endif() + find_program(MSYS2_PROGRAM + NAMES msys2_shell.cmd + HINTS "C:/msys64/" + ) + message(STATUS "Installing windows tools for nsis") + execute_process( + COMMAND "${MSYS2_PROGRAM}" "-${MINGW_TYPE}" "-here" "-full-path" "-defterm" "-shell" "sh" "-l" "-c" "pacman -Sy ${MINGW_PACKAGE_PREFIX}nsis --noconfirm --needed" + ) + endif() set(PACKAGE_EXT "exe") # Use magic `NSIS.template.in` template from the current source directory to force uninstallation # and ensure that linphone is not running before installation. diff --git a/linphone-app/cmake_builder/linphone_package/packaging.cmake.in b/linphone-app/cmake_builder/linphone_package/packaging.cmake.in index ed0b76d04..67a168cec 100644 --- a/linphone-app/cmake_builder/linphone_package/packaging.cmake.in +++ b/linphone-app/cmake_builder/linphone_package/packaging.cmake.in @@ -59,13 +59,13 @@ if (NOT "${CMAKE_INSTALL_PREFIX}" MATCHES .*/_CPack_Packages/.*) endif() endif() if(DO_APPIMAGE) - set(ENV QML_SOURCES_PATHS="@QML_SOURCES_PATHS@") - set(ENV QML_MODULES_PATHS="@QML_MODULES_PATHS@") + set(ENV QML_SOURCES_PATHS="@LINPHONE_QML_DIR@") + set(ENV QML_MODULES_PATHS="@LINPHONE_QML_DIR@") execute_process( COMMAND mkdir -p "WORK/Packages/AppImageDir/" WORKING_DIRECTORY "@CMAKE_INSTALL_PREFIX@/..") - execute_process( COMMAND cp -rf "@CMAKE_CURRENT_SOURCE_DIR@/../../ui" "WORK/Packages/AppImageDir/" WORKING_DIRECTORY "@CMAKE_INSTALL_PREFIX@/..") - execute_process( COMMAND "@CMAKE_CURRENT_SOURCE_DIR@/../../tools/create_appimage.sh" @EXECUTABLE_NAME@ @CPACK_PACKAGE_FILE_NAME@ @LINPHONE_BUILDER_SIGNING_IDENTITY@ @LINPHONE_BUILDER_SIGNING_PASSPHRASE@ RESULT_VARIABLE CPACK_COMMAND_RESULT WORKING_DIRECTORY "@CMAKE_INSTALL_PREFIX@/.." ) + execute_process( COMMAND cp -rf "@LINPHONE_QML_DIR@" "WORK/Packages/AppImageDir/" WORKING_DIRECTORY "@CMAKE_INSTALL_PREFIX@/..") + execute_process( COMMAND "@CMAKE_CURRENT_SOURCE_DIR@/../../tools/create_appimage.sh" @EXECUTABLE_NAME@ @CPACK_PACKAGE_FILE_NAME@ @QT_PATH@ @LINPHONE_BUILDER_SIGNING_IDENTITY@ @LINPHONE_BUILDER_SIGNING_PASSPHRASE@ RESULT_VARIABLE CPACK_COMMAND_RESULT WORKING_DIRECTORY "@CMAKE_INSTALL_PREFIX@/.." ) if(CPACK_COMMAND_RESULT) - message(FATAL_ERROR "Failed to create AppImage package with this command : '@CMAKE_CURRENT_SOURCE_DIR@/../../tools/create_appimage.sh @EXECUTABLE_NAME@ @APP_PROJECT_VERSION@' at @CMAKE_INSTALL_PREFIX@/..\nMaybe the .appimage already exists and is running. Please remove the file before packaging if it is the case.") + message(FATAL_ERROR "Failed to create AppImage package with this command : '@CMAKE_CURRENT_SOURCE_DIR@/../../tools/create_appimage.sh @EXECUTABLE_NAME@ @QT_PATH@ @APP_PROJECT_VERSION@' at @CMAKE_INSTALL_PREFIX@/..\nMaybe the .appimage already exists and is running. Please remove the file before packaging if it is the case.") endif() endif() if (@PERFORM_SIGNING@) diff --git a/linphone-app/src/app/AppController.cpp b/linphone-app/src/app/AppController.cpp index b2bfaa4ef..2b5fd156b 100644 --- a/linphone-app/src/app/AppController.cpp +++ b/linphone-app/src/app/AppController.cpp @@ -18,14 +18,17 @@ * along with this program. If not, see . */ +#include "config.h" + #include #include #include #include #include +#ifdef ENABLE_APP_WEBVIEW #include +#endif -#include "config.h" #include "gitversion.h" #include "AppController.hpp" @@ -51,12 +54,16 @@ AppController::AppController (int &argc, char *argv[]) { QCoreApplication::setApplicationName(EXECUTABLE_NAME); QApplication::setOrganizationDomain(EXECUTABLE_NAME); QCoreApplication::setApplicationVersion(LINPHONE_QT_GIT_VERSION); +#ifdef ENABLE_APP_WEBVIEW #if QT_VERSION < QT_VERSION_CHECK(5, 15, 0) mApp = new App(argc, argv); QtWebView::initialize(); #else QtWebView::initialize(); mApp = new App(argc, argv); +#endif +#else + mApp = new App(argc, argv); #endif // --------------------------------------------------------------------------- // App creation. diff --git a/linphone-app/src/components/assistant/AssistantModel.cpp b/linphone-app/src/components/assistant/AssistantModel.cpp index e26b7d8a4..91692cc93 100644 --- a/linphone-app/src/components/assistant/AssistantModel.cpp +++ b/linphone-app/src/components/assistant/AssistantModel.cpp @@ -215,7 +215,11 @@ bool AssistantModel::addOtherSipAccount (const QVariantMap &map) { shared_ptr address = factory->createAddress( Utils::appStringToCoreString(QStringLiteral("sip:%1").arg(domain)) ); - + if(!address) { + qWarning() << QStringLiteral("Unable to create address from domain `%1`.") + .arg(domain); + return false; + } const QString &transport(map["transport"].toString()); if (!transport.isEmpty()) address->setTransport(Utils::stringToTransportType(transport)); diff --git a/linphone-app/src/components/settings/SettingsModel.cpp b/linphone-app/src/components/settings/SettingsModel.cpp index 9f1c51a7b..7cb98be13 100644 --- a/linphone-app/src/components/settings/SettingsModel.cpp +++ b/linphone-app/src/components/settings/SettingsModel.cpp @@ -26,6 +26,8 @@ #include #include +#include "config.h" + #include "app/App.hpp" #include "app/logger/Logger.hpp" #include "app/paths/Paths.hpp" @@ -163,6 +165,14 @@ void SettingsModel::setAssistantSupportsPhoneNumbers (bool status) { emit assistantSupportsPhoneNumbersChanged(status); } +bool SettingsModel::useWebview() const{ +#ifdef ENABLE_APP_WEBVIEW + return true; +#else + return false; +#endif +} + QString SettingsModel::getAssistantRegistrationUrl () const { return Utils::coreStringToAppString(mConfig->getString(UiSection, "assistant_registration_url", Constants::DefaultAssistantRegistrationUrl)); } @@ -195,8 +205,11 @@ bool SettingsModel::isCguAccepted () const{ } void SettingsModel::acceptCgu(const bool accept){ - mConfig->setInt(UiSection, "read_and_agree_terms_and_privacy", accept); - emit cguAcceptedChanged(accept); + bool oldAccept = isCguAccepted(); + if( oldAccept != accept){ + mConfig->setInt(UiSection, "read_and_agree_terms_and_privacy", accept); + emit cguAcceptedChanged(accept); + } } // ============================================================================= @@ -1361,11 +1374,7 @@ bool SettingsModel::getShowStartVideoCallButton ()const{ } bool SettingsModel::isMipmapEnabled() const{ -#ifdef __APPLE__ - return !!mConfig->getInt(UiSection, "mipmap_enabled", 1); -#else return !!mConfig->getInt(UiSection, "mipmap_enabled", 0); -#endif } void SettingsModel::setMipmapEnabled(const bool& enabled){ diff --git a/linphone-app/src/components/settings/SettingsModel.hpp b/linphone-app/src/components/settings/SettingsModel.hpp index 9db273962..a006737f9 100644 --- a/linphone-app/src/components/settings/SettingsModel.hpp +++ b/linphone-app/src/components/settings/SettingsModel.hpp @@ -246,6 +246,8 @@ public: bool getAssistantSupportsPhoneNumbers () const; void setAssistantSupportsPhoneNumbers (bool status); + + Q_INVOKABLE bool useWebview() const; QString getAssistantRegistrationUrl () const; void setAssistantRegistrationUrl (QString url); diff --git a/linphone-app/src/config.h.cmake b/linphone-app/src/config.h.cmake index 1cc4b8df1..e999c64ca 100644 --- a/linphone-app/src/config.h.cmake +++ b/linphone-app/src/config.h.cmake @@ -30,3 +30,4 @@ #cmakedefine ENABLE_UPDATE_CHECK 1 #cmakedefine EXECUTABLE_NAME "${EXECUTABLE_NAME}" #cmakedefine MSPLUGINS_DIR "${MSPLUGINS_DIR}" +#cmakedefine ENABLE_APP_WEBVIEW "${ENABLE_APP_WEBVIEW}" diff --git a/linphone-app/tools/create_appimage.sh b/linphone-app/tools/create_appimage.sh index d3399c01b..3fcb2999a 100755 --- a/linphone-app/tools/create_appimage.sh +++ b/linphone-app/tools/create_appimage.sh @@ -22,10 +22,12 @@ # Arguments : # $1 = Executable Name # $2 = Output Filename -# $3 = Key of the code sign (optional but mendatory if code signing) -# $4 = Passphrase of the code sign (Optional) +# $3 = Qt root path (eg. "~/Qt/5.15.2/gcc_64") +# $4 = Key of the code sign (optional but mendatory if code signing) +# $5 = Passphrase of the code sign (Optional) APP_NAME="$1" +QT_PATH="$3" BIN_SOURCE_DIR="OUTPUT/" @@ -45,6 +47,8 @@ rm -rf "${WORK_DIR}/AppDir/usr/lib64" mkdir -p "${WORK_DIR}/AppDir/usr/lib" cp -f "${BIN_SOURCE_DIR}/lib"/libsoci_sqlite3* "${WORK_DIR}/AppDir/usr/lib/" cp -f "${BIN_SOURCE_DIR}/lib"/libapp-plugin* "${WORK_DIR}/AppDir/usr/lib/" +cp -f "${BIN_SOURCE_DIR}/lib64"/libsoci_sqlite3* "${WORK_DIR}/AppDir/usr/lib/" +cp -f "${BIN_SOURCE_DIR}/lib64"/libapp-plugin* "${WORK_DIR}/AppDir/usr/lib/" if [ -d "${BIN_SOURCE_DIR}/lib64/mediastreamer" ]; then mkdir -p "${WORK_DIR}/AppDir/usr/plugins/" @@ -70,11 +74,14 @@ else chmod +x "${WORK_DIR}/AppBin/linuxdeploy-plugin-qt-x86_64.AppImage" fi - +########################################################################################### export QML_SOURCES_PATHS=${QML_SOURCES_PATHS}:${WORK_DIR}/.. +export LD_LIBRARY_PATH=${QT_PATH}/lib +#export EXTRA_QT_PLUGINS=webenginecore;webview;webengine + echo "-- Generating AppDir for AppImage" -if [ -z "$3" ]; then +if [ -z "$4" ]; then ./${WORK_DIR}/AppBin/linuxdeploy-x86_64.AppImage --appdir=${WORK_DIR}/AppDir -e ${WORK_DIR}/AppDir/usr/bin/${APP_NAME} --output appimage --desktop-file=${WORK_DIR}/AppDir/usr/share/applications/${APP_NAME}.desktop -i ${WORK_DIR}/AppDir/usr/share/icons/hicolor/scalable/apps/${APP_NAME}.svg --plugin qt else if [ -f "${WORK_DIR}/AppBin/appimagetool-x86_64.AppImage" ]; then @@ -86,10 +93,10 @@ else ./${WORK_DIR}/AppBin/linuxdeploy-x86_64.AppImage --appdir=${WORK_DIR}/AppDir -e ${WORK_DIR}/AppDir/usr/bin/${APP_NAME} --desktop-file=${WORK_DIR}/AppDir/usr/share/applications/${APP_NAME}.desktop -i ${WORK_DIR}/AppDir/usr/share/icons/hicolor/scalable/apps/${APP_NAME}.svg --plugin qt #./linuxdeploy-x86_64.AppImage --appdir=${WORK_DIR}/ -e ${WORK_DIR}/app/bin/${APP_NAME} --output appimage --desktop-file=${WORK_DIR}/app/share/applications/${APP_NAME}.desktop -i ${WORK_DIR}/app/share/icons/hicolor/scalable/apps/${APP_NAME}.svg echo "-- Code Signing of AppImage" - if [ -z "$4" ]; then - ./${WORK_DIR}/AppBin/appimagetool-x86_64.AppImage ${WORK_DIR}/AppDir --sign --sign-key $3 + if [ -z "$5" ]; then + ./${WORK_DIR}/AppBin/appimagetool-x86_64.AppImage ${WORK_DIR}/AppDir --sign --sign-key $4 else - ./${WORK_DIR}/AppBin/appimagetool-x86_64.AppImage ${WORK_DIR}/AppDir --sign --sign-key $3 --sign-args "--pinentry-mode loopback --passphrase $4" + ./${WORK_DIR}/AppBin/appimagetool-x86_64.AppImage ${WORK_DIR}/AppDir --sign --sign-key $4 --sign-args "--pinentry-mode loopback --passphrase $5" fi fi diff --git a/linphone-app/ui/modules/Common/Form/DroppableTextArea.qml b/linphone-app/ui/modules/Common/Form/DroppableTextArea.qml index 14e802e8e..0ad917f62 100644 --- a/linphone-app/ui/modules/Common/Form/DroppableTextArea.qml +++ b/linphone-app/ui/modules/Common/Form/DroppableTextArea.qml @@ -193,8 +193,8 @@ Item { ActionButton { id: sendButton property int totalWidth: Layout.rightMargin + Layout.leftMargin + width - Layout.rightMargin: 15 - Layout.leftMargin: 10 + Layout.rightMargin: droppableTextArea.isEphemeral ? 20 : 15 + Layout.leftMargin: droppableTextArea.isEphemeral ? 5 : 10 Layout.alignment: Qt.AlignVCenter visible: droppableTextArea.enabled isCustom: true @@ -209,7 +209,7 @@ Item { iconSize: DroppableTextAreaStyle.ephemeralTimer.iconSize anchors.right:parent.right anchors.bottom : parent.bottom - anchors.rightMargin:-10 + anchors.rightMargin:-20 } } } diff --git a/linphone-app/ui/modules/Common/Image/Icon.qml b/linphone-app/ui/modules/Common/Image/Icon.qml index 2cce3b32d..26f0b2625 100644 --- a/linphone-app/ui/modules/Common/Image/Icon.qml +++ b/linphone-app/ui/modules/Common/Image/Icon.qml @@ -36,7 +36,7 @@ Item { mipmap: SettingsModel.mipmapEnabled cache: Images.areReadOnlyImages asynchronous: true - + smooth: true //anchors.centerIn: parent anchors.fill: parent @@ -45,8 +45,8 @@ Item { fillMode: Image.PreserveAspectFit source: Utils.resolveImageUri(icon) - sourceSize.width: iconWidth > 0 ? iconWidth : iconSize - sourceSize.height: iconHeight > 0 ? iconHeight : iconSize + sourceSize.width: (iconWidth > 0 ? iconWidth : iconSize) + sourceSize.height: ( iconHeight > 0 ? iconHeight : iconSize) layer { enabled: image.colorOverwriteEnabled effect: ColorOverlay { diff --git a/linphone-app/ui/modules/Linphone/Blocks/RequestBlock.qml b/linphone-app/ui/modules/Linphone/Blocks/RequestBlock.qml index 7170cc96d..63be79715 100644 --- a/linphone-app/ui/modules/Linphone/Blocks/RequestBlock.qml +++ b/linphone-app/ui/modules/Linphone/Blocks/RequestBlock.qml @@ -5,65 +5,65 @@ import Linphone.Styles 1.0 // ============================================================================= -Item { - id: block - - property var action - readonly property alias loading: block._loading - - property bool _loading: false - - // ---------------------------------------------------------------------------- - - function execute () { - block._loading = true - action() - } - function setText(txt){ - errorBlock.text = txt - } - - - function stop (error) { - errorBlock.text = error - block._loading = false - } - - // ---------------------------------------------------------------------------- - - height: RequestBlockStyle.height - - TextEdit { - id: errorBlock - readOnly: true - selectByMouse: true - - color: RequestBlockStyle.error.color - - font { - italic: true - pointSize: RequestBlockStyle.error.pointSize - } - - height: parent.height - width: parent.width - - horizontalAlignment: Text.AlignHCenter - padding: RequestBlockStyle.error.padding - wrapMode: Text.WordWrap - - visible: !block.loading - } - - BusyIndicator { - anchors { - horizontalCenter: parent.horizontalCenter - top: parent.top - } - - height: RequestBlockStyle.loadingIndicator.height - width: RequestBlockStyle.loadingIndicator.width - - running: block.loading - } +Column { + id: block + + property var action + readonly property alias loading: block._loading + + property bool _loading: false + + // ---------------------------------------------------------------------------- + + function execute () { + block._loading = true + action() + } + function setText(txt){ + errorBlock.text = txt + } + + + function stop (error) { + errorBlock.text = error + block._loading = false + } + + // ---------------------------------------------------------------------------- + + //height: errorBlock.implicitHeight + busy.height// RequestBlockStyle.height + TextEdit { + id: errorBlock + readOnly: true + selectByMouse: true + + color: RequestBlockStyle.error.color + + font { + italic: true + pointSize: RequestBlockStyle.error.pointSize + } + + height: visible ? undefined : 0 + width: parent.width + + horizontalAlignment: Text.AlignHCenter + padding: RequestBlockStyle.error.padding + wrapMode: Text.WordWrap + + visible: !block.loading && errorBlock.text != '' + } + + BusyIndicator { + id: busy + anchors { + horizontalCenter: parent.horizontalCenter + //top: parent.top + } + + height: visible ? RequestBlockStyle.loadingIndicator.height : 0 + width: RequestBlockStyle.loadingIndicator.width + + running: block.loading + } } diff --git a/linphone-app/ui/modules/Linphone/Chat/ChatFileMessage.qml b/linphone-app/ui/modules/Linphone/Chat/ChatFileMessage.qml index 7b5c0fc5c..d25dfb080 100644 --- a/linphone-app/ui/modules/Linphone/Chat/ChatFileMessage.qml +++ b/linphone-app/ui/modules/Linphone/Chat/ChatFileMessage.qml @@ -77,6 +77,9 @@ Row { id: thumbnailImageSource mipmap: SettingsModel.mipmapEnabled source: mainRow.contentModel.thumbnail + fillMode: Image.PreserveAspectFit + sourceSize.width: 100 + sourceSize.height: 100 } } diff --git a/linphone-app/ui/modules/Linphone/Styles/Blocks/RequestBlockStyle.qml b/linphone-app/ui/modules/Linphone/Styles/Blocks/RequestBlockStyle.qml index 74732c5c3..bb79ad9fd 100644 --- a/linphone-app/ui/modules/Linphone/Styles/Blocks/RequestBlockStyle.qml +++ b/linphone-app/ui/modules/Linphone/Styles/Blocks/RequestBlockStyle.qml @@ -8,7 +8,7 @@ import ColorsList 1.0 QtObject { property string sectionName: 'RequestBlock' - property int height: 60 + property int height: 80 property QtObject error: QtObject { property color color: ColorsList.add(sectionName+'_error', 'error').color diff --git a/linphone-app/ui/modules/Linphone/Styles/Chat/ChatStyle.qml b/linphone-app/ui/modules/Linphone/Styles/Chat/ChatStyle.qml index dfacfa2a3..7d3920c09 100644 --- a/linphone-app/ui/modules/Linphone/Styles/Chat/ChatStyle.qml +++ b/linphone-app/ui/modules/Linphone/Styles/Chat/ChatStyle.qml @@ -248,9 +248,9 @@ QtObject { property QtObject outgoing: QtObject { property color backgroundColor: ColorsList.add(sectionName+'_outgoing_bg', 'e').color - property int areaSize: 16 - property int busyIndicatorSize: 16 - property int sendIconSize: 12 + property int areaSize: 12 + property int busyIndicatorSize: 12 + property int sendIconSize: 60 property QtObject text: QtObject { property color color: ColorsList.add(sectionName+'_outgoing_text', 'd').color diff --git a/linphone-app/ui/views/App/Main/Assistant/AssistantAbstractView.qml b/linphone-app/ui/views/App/Main/Assistant/AssistantAbstractView.qml index ab2b87142..5f4c7b19c 100644 --- a/linphone-app/ui/views/App/Main/Assistant/AssistantAbstractView.qml +++ b/linphone-app/ui/views/App/Main/Assistant/AssistantAbstractView.qml @@ -24,11 +24,18 @@ Item { default property alias _content: content.data property alias contentItem: content + + property int decorationHeight: title.implicitHeight + title.anchors.topMargin + +description.implicitHeight + description.anchors.topMargin + +content.anchors.topMargin + +buttons.implicitHeight+AssistantAbstractViewStyle.info.spacing // --------------------------------------------------------------------------- height: (maximized?stack.height:AssistantAbstractViewStyle.content.height) width: (maximized?stack.width:AssistantAbstractViewStyle.content.width) + anchors.horizontalCenter: maximized || !parent? undefined : parent.horizontalCenter + anchors.verticalCenter: maximized || !parent? undefined : parent.verticalCenter // --------------------------------------------------------------------------- // Info. diff --git a/linphone-app/ui/views/App/Main/Assistant/AssistantHome.qml b/linphone-app/ui/views/App/Main/Assistant/AssistantHome.qml index 17b5bf90d..74ca5cee9 100644 --- a/linphone-app/ui/views/App/Main/Assistant/AssistantHome.qml +++ b/linphone-app/ui/views/App/Main/Assistant/AssistantHome.qml @@ -124,15 +124,17 @@ ColumnLayout { Component.onCompleted: { insert(0, { $text: qsTr('createAppSipAccount'), - $view: 'CreateAppSipAccount', + $view: SettingsModel.useWebview() ? 'CreateAppSipAccountWithWebView' : 'CreateAppSipAccount', $viewType: 'CreateAppSipAccount', - $props:{defaultUrl: SettingsModel.assistantRegistrationUrl, defaultLogoutUrl:SettingsModel.assistantLogoutUrl, configFilename: 'create-app-sip-account.rc'} + $props: SettingsModel.useWebview() ? {defaultUrl: SettingsModel.assistantRegistrationUrl, defaultLogoutUrl:SettingsModel.assistantLogoutUrl, configFilename: 'create-app-sip-account.rc'} + : {} }) append({ $text: qsTr('useAppSipAccount'), - $view: 'CreateAppSipAccount', + $view: SettingsModel.useWebview() ? 'CreateAppSipAccountWithWebView' : 'UseAppSipAccount', $viewType: 'UseAppSipAccount', - $props:{defaultUrl: SettingsModel.assistantLoginUrl, defaultLogoutUrl:SettingsModel.assistantLogoutUrl, configFilename: 'use-app-sip-account.rc'} + $props: SettingsModel.useWebview() ? {defaultUrl: SettingsModel.assistantLoginUrl, defaultLogoutUrl:SettingsModel.assistantLogoutUrl, configFilename: 'use-app-sip-account.rc'} + : {} }) append({ $text: qsTr('useOtherSipAccount'), diff --git a/linphone-app/ui/views/App/Main/Assistant/CreateAppSipAccount.qml b/linphone-app/ui/views/App/Main/Assistant/CreateAppSipAccount.qml index 131db64ab..ff49deb93 100644 --- a/linphone-app/ui/views/App/Main/Assistant/CreateAppSipAccount.qml +++ b/linphone-app/ui/views/App/Main/Assistant/CreateAppSipAccount.qml @@ -1,167 +1,43 @@ import QtQuick 2.7 -import QtWebView 1.1 -import QtQuick.Controls 1.3 // Busy indicator import Common 1.0 -import Linphone 1.0 as Linphone import App.Styles 1.0 // ============================================================================= -AssistantAbstractView { - id: view - maximized:true - height: (parent?parent.height:0) - width: (parent?parent.width:0) - property string defaultUrl - property string defaultLogoutUrl - property string configFilename - property bool printed : stack.currentItem == view - onPrintedChanged: { - webviewLoader.active = printed - } - - //------------------------------- - - property int status : 0 // 0:nothing, -1:error, 1:ok - property bool newPage : true - - - // --------------------------------------------------------------------------- - // Menu. - // --------------------------------------------------------------------------- -// Note : Use opacity and not visibility to allow smooth updating (when moving visibility to true, we could show the old page) - Component{ - id: webviewComponent - WebView{ - id:webview - property bool isLogingOut : true - state: 'hidden' - Component.onCompleted: {if(webview.httpUserAgent != undefined) webview.httpUserAgent = Linphone.CoreManager.getUserAgent() // only available on Qt 5.15 (QtWebView 1.15) - isLogingOut = true - webview.url = view.defaultLogoutUrl - } - function getData(){// Check if account_infos exists in the page and retrieve data to make/update an account - if(webview.loading){ - view.status = 0 - }else { - var js = "(typeof account_infos !== 'undefined'?account_infos:'')"; - webview.runJavaScript(js, function(result) { - if( result == ''){ - view.status = 0 - }else{ - webview.state = 'hidden' - reloadTimer.stop(); - console.log("[CreateAccount] SIP : " +result.sip); - console.log("[CreateAccount] Username : " +result.username); - console.log("[CreateAccount] Registrar : " +result.registrar_address); - console.log("[CreateAccount] Domain : " +result.domain); - if (Linphone.AccountSettingsModel.addOrUpdateProxyConfig( { - sipAddress: result.sip, - serverAddress: result.registrar_address, - configFilename: view.configFilename - })) { - - console.log("[CreateAccount] Account created") - view.status = 1 - Linphone.AccountSettingsModel.setDefaultProxyConfigFromSipAddress("sip:"+result.sip) - } else { - console.error("[CreateAccount] Cannot create account. Check logs.") - view.status = -1 - } - - } - }); - } - } - - Timer {// Check data - id:reloadTimer - interval: 1000; - running: true; repeat: true - onTriggered: {webview.getData();} - } - - onLoadingChanged: { - if (loadRequest.errorString) - console.error("[CreateAccount] error on loading page : " +loadRequest.errorString); - if(loading){ - view.newPage = true; - }else if(view.newPage) { - view.newPage = false; - webview.runJavaScript("document.querySelector('nav').remove(); document.querySelector('footer').remove();"); - } - webview.state = (loading || isLogingOut ? 'hidden' : 'showed') - if(!loading){ - if(isLogingOut){ - isLogingOut = false - webview.url = view.defaultUrl - }else{ - reloadTimer.stop(); - webview.getData(); - if(view.status == 0) - reloadTimer.start(); - } - }else - reloadTimer.stop(); - } - states: [ - State { - name: 'hidden' - PropertyChanges { target: webview; opacity: 0 } - }, - State { - name: 'showed' - PropertyChanges { target: webview; opacity: 1 } - } - ] - transitions: [ - Transition { - from: '*'; to: 'showed' - SequentialAnimation{ - NumberAnimation{ properties: "opacity"; easing.type: Easing.OutBounce; duration: 500 } - } - }, - Transition { - SequentialAnimation{ - NumberAnimation{ properties: "opacity"; duration: 1000 } - } - } - ] - } - } - Loader{ - id: webviewLoader - active: false - anchors.fill:parent - sourceComponent: webviewComponent + + AssistantAbstractView { + description: qsTr('createAppSipAccountDescription') + title: qsTr('createAppSipAccountTitle').replace('%1', Qt.application.name.toUpperCase()) - } - - Rectangle{ - id:statusPage - anchors.fill:parent - visible: webviewLoader.item && (webviewLoader.item.loading || webviewLoader.item.isLogingOut || webviewLoader.item.state == 'hidden') - BusyIndicator{ - id:busy - anchors.centerIn : parent - running:true - width:CreateAppSipAccountStyle.busy.size - height:CreateAppSipAccountStyle.busy.size - } - - Icon{ - visible: view.status != 0 - icon: (view.status>0?"chat_read":"chat_error") - iconSize:busy.width - anchors.fill:busy - MouseArea{ - anchors.fill:parent - onClicked: { - assistant.popView() - } + + // --------------------------------------------------------------------------- + // Menu. + // --------------------------------------------------------------------------- + + Column { + anchors.centerIn: parent + spacing: CreateAppSipAccountStyle.buttons.spacing + width: CreateAppSipAccountStyle.buttons.button.width + + TextButtonA { + text: qsTr('withPhoneNumber') + + height: CreateAppSipAccountStyle.buttons.button.height + width: parent.width + + onClicked: assistant.pushView('CreateAppSipAccountWithPhoneNumber') + } + + TextButtonA { + text: qsTr('withEmailAddress') + + height: CreateAppSipAccountStyle.buttons.button.height + width: parent.width + + onClicked: assistant.pushView('CreateAppSipAccountWithEmail') } } } -} + diff --git a/linphone-app/ui/views/App/Main/Assistant/CreateAppSipAccountWithWebView.qml b/linphone-app/ui/views/App/Main/Assistant/CreateAppSipAccountWithWebView.qml new file mode 100644 index 000000000..131db64ab --- /dev/null +++ b/linphone-app/ui/views/App/Main/Assistant/CreateAppSipAccountWithWebView.qml @@ -0,0 +1,167 @@ +import QtQuick 2.7 +import QtWebView 1.1 +import QtQuick.Controls 1.3 // Busy indicator + +import Common 1.0 +import Linphone 1.0 as Linphone + +import App.Styles 1.0 + +// ============================================================================= + +AssistantAbstractView { + id: view + maximized:true + height: (parent?parent.height:0) + width: (parent?parent.width:0) + property string defaultUrl + property string defaultLogoutUrl + property string configFilename + property bool printed : stack.currentItem == view + onPrintedChanged: { + webviewLoader.active = printed + } + + //------------------------------- + + property int status : 0 // 0:nothing, -1:error, 1:ok + property bool newPage : true + + + // --------------------------------------------------------------------------- + // Menu. + // --------------------------------------------------------------------------- +// Note : Use opacity and not visibility to allow smooth updating (when moving visibility to true, we could show the old page) + Component{ + id: webviewComponent + WebView{ + id:webview + property bool isLogingOut : true + state: 'hidden' + Component.onCompleted: {if(webview.httpUserAgent != undefined) webview.httpUserAgent = Linphone.CoreManager.getUserAgent() // only available on Qt 5.15 (QtWebView 1.15) + isLogingOut = true + webview.url = view.defaultLogoutUrl + } + function getData(){// Check if account_infos exists in the page and retrieve data to make/update an account + if(webview.loading){ + view.status = 0 + }else { + var js = "(typeof account_infos !== 'undefined'?account_infos:'')"; + webview.runJavaScript(js, function(result) { + if( result == ''){ + view.status = 0 + }else{ + webview.state = 'hidden' + reloadTimer.stop(); + console.log("[CreateAccount] SIP : " +result.sip); + console.log("[CreateAccount] Username : " +result.username); + console.log("[CreateAccount] Registrar : " +result.registrar_address); + console.log("[CreateAccount] Domain : " +result.domain); + if (Linphone.AccountSettingsModel.addOrUpdateProxyConfig( { + sipAddress: result.sip, + serverAddress: result.registrar_address, + configFilename: view.configFilename + })) { + + console.log("[CreateAccount] Account created") + view.status = 1 + Linphone.AccountSettingsModel.setDefaultProxyConfigFromSipAddress("sip:"+result.sip) + } else { + console.error("[CreateAccount] Cannot create account. Check logs.") + view.status = -1 + } + + } + }); + } + } + + Timer {// Check data + id:reloadTimer + interval: 1000; + running: true; repeat: true + onTriggered: {webview.getData();} + } + + onLoadingChanged: { + if (loadRequest.errorString) + console.error("[CreateAccount] error on loading page : " +loadRequest.errorString); + if(loading){ + view.newPage = true; + }else if(view.newPage) { + view.newPage = false; + webview.runJavaScript("document.querySelector('nav').remove(); document.querySelector('footer').remove();"); + } + webview.state = (loading || isLogingOut ? 'hidden' : 'showed') + if(!loading){ + if(isLogingOut){ + isLogingOut = false + webview.url = view.defaultUrl + }else{ + reloadTimer.stop(); + webview.getData(); + if(view.status == 0) + reloadTimer.start(); + } + }else + reloadTimer.stop(); + } + states: [ + State { + name: 'hidden' + PropertyChanges { target: webview; opacity: 0 } + }, + State { + name: 'showed' + PropertyChanges { target: webview; opacity: 1 } + } + ] + transitions: [ + Transition { + from: '*'; to: 'showed' + SequentialAnimation{ + NumberAnimation{ properties: "opacity"; easing.type: Easing.OutBounce; duration: 500 } + } + }, + Transition { + SequentialAnimation{ + NumberAnimation{ properties: "opacity"; duration: 1000 } + } + } + ] + } + } + Loader{ + id: webviewLoader + active: false + anchors.fill:parent + sourceComponent: webviewComponent + + } + + Rectangle{ + id:statusPage + anchors.fill:parent + visible: webviewLoader.item && (webviewLoader.item.loading || webviewLoader.item.isLogingOut || webviewLoader.item.state == 'hidden') + BusyIndicator{ + id:busy + anchors.centerIn : parent + running:true + width:CreateAppSipAccountStyle.busy.size + height:CreateAppSipAccountStyle.busy.size + } + + Icon{ + visible: view.status != 0 + icon: (view.status>0?"chat_read":"chat_error") + iconSize:busy.width + anchors.fill:busy + MouseArea{ + anchors.fill:parent + onClicked: { + assistant.popView() + } + } + } + } +} diff --git a/linphone-app/ui/views/App/Main/Assistant/UseOtherSipAccount.qml b/linphone-app/ui/views/App/Main/Assistant/UseOtherSipAccount.qml index 586c2dcdf..227c5ae92 100644 --- a/linphone-app/ui/views/App/Main/Assistant/UseOtherSipAccount.qml +++ b/linphone-app/ui/views/App/Main/Assistant/UseOtherSipAccount.qml @@ -13,10 +13,8 @@ Item{ AssistantAbstractView { id: mainItem mainAction: requestBlock.execute - - mainActionEnabled: username.text.length && - sipDomain.text.length && - password.text.length + property bool isValid: false + mainActionEnabled: mainItem.showWarning || isValid //: 'I understand' : Popup confirmation for a warning mainActionLabel: showWarning ? qsTr('understandAction').toUpperCase() //: 'Use' : Popup confirmation for a form @@ -24,29 +22,28 @@ Item{ title: qsTr('useOtherSipAccountTitle') - width: AssistantAbstractViewStyle.content.width - height: AssistantAbstractViewStyle.content.height + width: mainStack.currentItem.implicitWidth + height: mainStack.currentItem.implicitHeight + + (requestBlock.implicitHeight > 0 ? requestBlock.implicitHeight : 0) + + mainItem.decorationHeight anchors.horizontalCenter: parent.horizontalCenter anchors.verticalCenter: parent.verticalCenter property bool showWarning : true - // --------------------------------------------------------------------------- StackView { id: mainStack - anchors.fill: parent.contentItem - width: AssistantAbstractViewStyle.content.width - height: AssistantAbstractViewStyle.content.height + width: currentItem.implicitWidth>0 ? currentItem.implicitWidth : currentItem.width + height: currentItem.implicitHeight>0 ? currentItem.implicitHeight : currentItem.height initialItem: warningComponent } Component{ id: warningComponent - Column{ + Column{ spacing: UseAppSipAccountStyle.warningBlock.spacing - anchors.fill: parent.contentItem - - Text { + width: AssistantAbstractViewStyle.content.width + Text { elide: Text.ElideRight font.pointSize: UseAppSipAccountStyle.warningBlock.pointSize @@ -100,18 +97,28 @@ Item{ cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.IBeamCursor - } + } } } - } + Component { id: formComponent Column { - anchors.fill: parent.contentItem width: AssistantAbstractViewStyle.content.width - height: AssistantAbstractViewStyle.content.height + property bool isValid: username.text.length && + sipDomain.text.length && + password.text.length + onIsValidChanged: mainItem.isValid = isValid + property alias usernameText: username.text + property alias displayNameText: displayName.text + property alias sipDomainText: sipDomain.text + property alias passwordText: password.text + function getTransport(){ + return transport.model[transport.currentIndex] + } + Form { orientation: Qt.Vertical width: parent.width @@ -169,30 +176,33 @@ Item{ } RequestBlock { - id: requestBlock - width: parent.width - - action: (function () { - if(mainItem.showWarning) { - mainItem.showWarning = false - mainStack.replace(formComponent); - requestBlock.stop('') - }else{ - if (!assistantModel.addOtherSipAccount({ - username: username.text, - displayName: displayName.text, - sipDomain: sipDomain.text, - password: password.text, - transport: transport.model[transport.currentIndex] - })) { - requestBlock.stop(qsTr('addOtherSipAccountError')) - } else { + id: requestBlock + width: parent.width + anchors.top: mainStack.bottom + anchors.topMargin: UseAppSipAccountStyle.warningBlock.spacing + + action: (function () { + if(mainItem.showWarning) { + mainItem.showWarning = false + mainStack.push(formComponent); requestBlock.stop('') - window.setView('Home') + }else{ + if (!assistantModel.addOtherSipAccount({ + username: mainStack.currentItem.usernameText, + displayName: mainStack.currentItem.displayNameText, + sipDomain: mainStack.currentItem.sipDomainText, + password: mainStack.currentItem.passwordText, + transport: mainStack.currentItem.getTransport() + })) { + requestBlock.stop(qsTr('addOtherSipAccountError')) + } else { + requestBlock.stop('') + window.setView('Home') + } } - } - }) - } + }) + } + AssistantModel { id: assistantModel configFilename: 'use-other-sip-account.rc' diff --git a/linphone-app/webview_resources.qrc b/linphone-app/webview_resources.qrc new file mode 100644 index 000000000..845afee60 --- /dev/null +++ b/linphone-app/webview_resources.qrc @@ -0,0 +1,5 @@ + + + ui/views/App/Main/Assistant/CreateAppSipAccountWithWebView.qml + +