From 800796fb06509a5b39b4c93dff64168268ea3d5a Mon Sep 17 00:00:00 2001 From: Dorian Zedler Date: Mon, 5 Jul 2021 20:55:34 +0200 Subject: [PATCH] - more translations - some fixes --- CHANGELOG.md | 15 ++- android/AndroidManifest.xml | 2 +- android/build.gradle | 2 +- .../src/de/itsblue/blueROCK/MainActivity.java | 23 ++--- blueROCK.pro | 2 +- resources/qml/Components/MovingLabel.qml | 88 ++++++++++++++++++ resources/qml/Components/SelectorPopup.qml | 34 ++++--- .../qml/Components/SpeedFlowChartLocker.qml | 50 +++++----- .../qml/Components/SpeedFlowChartPopup.qml | 3 + resources/qml/Components/SwipeGallery.qml | 1 + resources/qml/Pages/StartPage.qml | 2 +- resources/qml/Widgets/StartlistWidget.qml | 2 +- resources/qml/main.qml | 20 ++-- resources/qml/qml.qrc | 1 + resources/translations/de.qm | Bin 5834 -> 5856 bytes resources/translations/de.ts | 61 ++++-------- resources/translations/en.qm | Bin 5438 -> 5436 bytes resources/translations/en.ts | 47 ++-------- sources/bluerockbackend.cpp | 5 +- sources/shareUtils/androidshareutils.cpp | 16 ++-- 20 files changed, 215 insertions(+), 159 deletions(-) create mode 100644 resources/qml/Components/MovingLabel.qml diff --git a/CHANGELOG.md b/CHANGELOG.md index 88150d9..41b286a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,17 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +# [0.06] - UNRELEASED +### Changed + +### Added +- Dark mode +- QR-Code scanning +- Sharing of every view using either link, QR-Code or a poster +- Text which is too large too fit is scrollable now in most places +- German translations +- URL handler for https://l.bluerock.dev and https://app.bluerock.dev + # [0.05] - 2021-06-07 ### Changed - the boulder result rect doesn't have a background if there is no result now @@ -16,7 +27,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - the calendar now scrolls less far down - improoved layout in landscape mode - some design changes in profile page and speed flowchart -- added second link for "further infos" in calendar + +### Added +- Second link for "further infos" in calendar # [0.03.0] - 2019-07-11 ### Added diff --git a/android/AndroidManifest.xml b/android/AndroidManifest.xml index be5f1c5..a78be6b 100644 --- a/android/AndroidManifest.xml +++ b/android/AndroidManifest.xml @@ -10,7 +10,7 @@ - + diff --git a/android/build.gradle b/android/build.gradle index de92470..7ef94c3 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -73,7 +73,7 @@ android { defaultConfig { resConfig "en" minSdkVersion = qtMinSdkVersion - targetSdkVersion = 29 + targetSdkVersion = qtTargetSdkVersion } lintOptions { diff --git a/android/src/de/itsblue/blueROCK/MainActivity.java b/android/src/de/itsblue/blueROCK/MainActivity.java index 8bf57ae..c070a26 100755 --- a/android/src/de/itsblue/blueROCK/MainActivity.java +++ b/android/src/de/itsblue/blueROCK/MainActivity.java @@ -61,18 +61,18 @@ public class MainActivity extends QtActivity @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); - Log.d("ekkescorner", "onCreate QShareActivity"); - // now we're checking if the App was started from another Android App via Intent - Intent theIntent = getIntent(); - if (theIntent != null){ - String theAction = theIntent.getAction(); - if (theAction != null){ - Log.d("ekkescorner onCreate ", theAction); - // QML UI not ready yet - // delay processIntent(); - isIntentPending = true; - } + Log.d("ekkescorner", "onCreate QShareActivity"); + // now we're checking if the App was started from another Android App via Intent + Intent theIntent = getIntent(); + if (theIntent != null){ + String theAction = theIntent.getAction(); + if (theAction != null){ + Log.d("ekkescorner onCreate ", theAction); + // QML UI not ready yet + // delay processIntent(); + isIntentPending = true; } + } } // onCreate // WIP - trying to find a solution to survive a 2nd onCreate @@ -96,6 +96,7 @@ public class MainActivity extends QtActivity // this method here - otherwise you'll get wrong request or result codes @Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { + super.onActivityResult(requestCode, resultCode, data); // Check which request we're responding to Log.d("ekkescorner onActivityResult", "requestCode: "+requestCode); if (resultCode == RESULT_OK) { diff --git a/blueROCK.pro b/blueROCK.pro index 2ad3af7..1ddd50a 100644 --- a/blueROCK.pro +++ b/blueROCK.pro @@ -89,7 +89,7 @@ android { ANDROID_VERSION_NAME = $$VERSION ANDROID_VERSION_CODE = $$droidVersionCode($$ANDROID_VERSION_NAME) - message(Android version code: $$ANDROID_VERSION_CODE) + ANDROID_TARGET_SDK_VERSION = 29 include(/home/dorian/Android/Sdk/android_openssl/openssl.pri) ANDROID_PACKAGE_SOURCE_DIR = $$PWD/android diff --git a/resources/qml/Components/MovingLabel.qml b/resources/qml/Components/MovingLabel.qml new file mode 100644 index 0000000..c7f1ca8 --- /dev/null +++ b/resources/qml/Components/MovingLabel.qml @@ -0,0 +1,88 @@ +import QtQuick 2.15 +import QtQuick.Controls 2.15 +import QtQuick.Controls.Material 2.12 + +Item { + id: control + + property alias text: firstLabel.text + property alias font: firstLabel.font + property alias verticalAlignment: firstLabel.verticalAlignment + property int spacing: 30 + + property MovingLabel syncWithLabel + property int _spacing: syncWithLabel && syncWithLabel._labelWidth > _labelWidth ? (syncWithLabel._labelWidth - _labelWidth + syncWithLabel.spacing) : spacing + property alias _labelWidth: firstLabel.width + + signal linkActivated(string link) + + clip: true + height: firstLabel.height + + onTextChanged: { + _resetScroll() + } + + function startScroll(triggerSyncedLabel=true) { + if(control.syncWithLabel && triggerSyncedLabel) + control.syncWithLabel.startScroll(false) + if(control.width < firstLabel.width && !scrollAnimation.running) + scrollAnimation.start() + } + + function _resetScroll() { + scrollAnimation.stop() + firstLabel.anchors.leftMargin = 0 + } + + Label { + id: firstLabel + + anchors { + left: parent.left + verticalCenter: parent.verticalCenter + } + + onLinkActivated: control.onLinkActivated(link) + } + + Label { + id: secondLabel + + anchors { + left: firstLabel.right + leftMargin: control._spacing + verticalCenter: firstLabel.verticalCenter + } + + visible: scrollAnimation.running + + font: firstLabel.font + text: firstLabel.text + verticalAlignment: firstLabel.verticalAlignment + elide: firstLabel.elide + bottomPadding: firstLabel.bottomPadding + padding: firstLabel.padding + + onLinkActivated: control.onLinkActivated(link) + } + + MouseArea { + anchors.fill: parent + onClicked: control.startScroll() + } + + NumberAnimation { + id: scrollAnimation + target: firstLabel + property: "anchors.leftMargin" + from: 0 + to: -(firstLabel.width + control._spacing) + duration: (to / -100) * 1500 + + onRunningChanged: { + if(!running) + control._resetScroll() + } + } +} diff --git a/resources/qml/Components/SelectorPopup.qml b/resources/qml/Components/SelectorPopup.qml index 3e7c058..356441e 100644 --- a/resources/qml/Components/SelectorPopup.qml +++ b/resources/qml/Components/SelectorPopup.qml @@ -1,5 +1,5 @@ -import QtQuick 2.9 -import QtQuick.Controls 2.4 +import QtQuick 2.15 +import QtQuick.Controls 2.15 import QtQuick.Controls.Material 2.3 Dialog { @@ -33,37 +33,35 @@ Dialog { id: selectorPuHeaderCol width: control.width - height: headerSubLa.text !== "" && headerLa.text !== "" ? 73 : 40 + height: headerLa.height + headerTopSpacerItm.height + (control.subTitle ? headerSubLa.height:0) - Label { + Item { + id: headerTopSpacerItm + height: control.padding + width: parent.width + } + + MovingLabel { id: headerLa - visible: control.title + anchors.horizontalCenter: parent.horizontalCenter + width: selectorPuHeaderCol.width - control.padding * 2 - width: selectorPuHeaderCol.width - - elide: "ElideRight" - padding: control.padding - bottomPadding: 0 font.bold: true font.pixelSize: 16 text: control.title - onLinkActivated: { - control.linkActivated(link) - } + onLinkActivated: control.linkActivated(link) } Label { id: headerSubLa - visible: control.subTitle + anchors.horizontalCenter: parent.horizontalCenter + width: selectorPuHeaderCol.width - control.padding * 2 - width: selectorPuHeaderCol.width - - elide: "ElideRight" - padding: control.padding + wrapMode: Text.Wrap topPadding: 5 bottomPadding: 0 font.bold: true diff --git a/resources/qml/Components/SpeedFlowChartLocker.qml b/resources/qml/Components/SpeedFlowChartLocker.qml index 27acda2..f636caa 100644 --- a/resources/qml/Components/SpeedFlowChartLocker.qml +++ b/resources/qml/Components/SpeedFlowChartLocker.qml @@ -4,13 +4,10 @@ import QtQuick.Controls.Material 2.12 import QtQuick.Layouts 1.15 import QtPurchasing 1.12 -Rectangle { - id: speedFlowChartLockedOverlay +Page { + id: control anchors.fill: parent - anchors.margins: -20 - - color: Material.background Connections { target: speedFlowChartProduct @@ -38,42 +35,40 @@ Rectangle { } } - ColumnLayout { + Column { id: lockedLayout anchors { fill: parent - topMargin: parent.height * 0.05 + topMargin: parent.height * 0.02 bottomMargin: parent.height * 0.05 rightMargin: parent.width * 0.1 + 20 leftMargin: parent.width * 0.1 + 20 } - //spacing: parent.height * 0.05 + spacing: lockedLayout.height * 0.01 Label { - Layout.fillWidth: true - - height: parent.height * 0.015 - + anchors.horizontalCenter: parent.horizontalCenter + height: lockedLayout.height * 0.03 + width: lockedLayout.width //% "This is a premium feature." text: qsTrId("#thisIsAPremiumFeature") - font.bold: true font.pixelSize: height + font.bold: true fontSizeMode: Text.Fit + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter minimumPixelSize: 1 - - horizontalAlignment: Text.AlignHCenter - } SwipeGallery { property string platformIcons: Qt.platform.os === "osx" || Qt.platform.os === "iso" ? "ios":"android" - Layout.fillHeight: true - Layout.fillWidth: true + height: lockedLayout.height * 0.85 + width: lockedLayout.width images: [ "qrc:/screenshots/SpeedFlowchartDemo/" + platformIcons + "/1.jpeg", @@ -84,25 +79,33 @@ Rectangle { Button { id: purchaseBt - Layout.alignment: Layout.Center + anchors.horizontalCenter: parent.horizontalCenter + height: lockedLayout.height * 0.07 enabled: speedFlowChartProduct.status === Product.Registered text: speedFlowChartProduct.status === Product.Registered - ? "\uf218 "+ qsTrId("#buyNowFor") +" " + speedFlowChartProduct.price + ? "\uf218 "+ qsTrId("#buyNowFor") + " " + speedFlowChartProduct.price : qsTrId("#itemIsUnavailable") font.family: fa5solid.name + font.pixelSize: height * 0.4 + font.capitalization: Font.MixedCase onClicked: speedFlowChartProduct.purchase() } RowLayout { + id: bottomRow - Layout.alignment: Layout.Center + anchors.horizontalCenter: parent.horizontalCenter + height: lockedLayout.height * 0.065 Button { id: restorePurchaseButton Layout.alignment: Layout.Center - visible: speedFlowChartProduct.status === Product.Registered + Layout.preferredHeight: bottomRow.height + //visible: speedFlowChartProduct.status === Product.Registered flat: true + font.pixelSize: height * 0.4 + font.capitalization: Font.MixedCase //% "Restore purchase" text: qsTrId("#restorePurchase") @@ -112,8 +115,11 @@ Rectangle { Button { id: contactSupportButton Layout.alignment: Layout.Center + Layout.preferredHeight: bottomRow.height flat: true + font.pixelSize: height * 0.4 + font.capitalization: Font.MixedCase //% "contact support" text: qsTrId("#contact support") diff --git a/resources/qml/Components/SpeedFlowChartPopup.qml b/resources/qml/Components/SpeedFlowChartPopup.qml index 5456a8d..3200d82 100644 --- a/resources/qml/Components/SpeedFlowChartPopup.qml +++ b/resources/qml/Components/SpeedFlowChartPopup.qml @@ -11,6 +11,9 @@ Rectangle { //property bool unlocked: QT_DEBUG || appSettings.read("speedBackendPurchase") === "1" property bool unlocked: appSettings.read("speedBackendPurchase") === "1" + Component.onCompleted: { + console.warn("unlocked:", appSettings.read("speedBackendPurchase")) + } state: "hidden" diff --git a/resources/qml/Components/SwipeGallery.qml b/resources/qml/Components/SwipeGallery.qml index d159c5c..ea07b81 100644 --- a/resources/qml/Components/SwipeGallery.qml +++ b/resources/qml/Components/SwipeGallery.qml @@ -14,6 +14,7 @@ Item { anchors.fill: parent anchors.margins: 1 anchors.bottomMargin: indicator.height + spacing: width * 0.2 Repeater { model: control.images.length diff --git a/resources/qml/Pages/StartPage.qml b/resources/qml/Pages/StartPage.qml index eb8b0db..2b766eb 100644 --- a/resources/qml/Pages/StartPage.qml +++ b/resources/qml/Pages/StartPage.qml @@ -94,7 +94,7 @@ Page { } width: app.landscape() ? childrenRect.width : parent.width * 0.8 - height: app.landscape() ? headerBadge.height : headerBadge.height * 2 + height: app.landscape() ? headerBadge.height : Math.min(headerBadge.height * 2, width * 0.27) columnSpacing: height * 0.1 diff --git a/resources/qml/Widgets/StartlistWidget.qml b/resources/qml/Widgets/StartlistWidget.qml index 2c1e1e9..44cce04 100644 --- a/resources/qml/Widgets/StartlistWidget.qml +++ b/resources/qml/Widgets/StartlistWidget.qml @@ -95,7 +95,7 @@ DataListView { } } - selector.appear(selectOptions, qsTrId("#startlistHeadline")) + selector.appear(selectOptions, qsTrId("#selectCategory")) } Connections { diff --git a/resources/qml/main.qml b/resources/qml/main.qml index 45c3334..c6b3e84 100644 --- a/resources/qml/main.qml +++ b/resources/qml/main.qml @@ -195,7 +195,7 @@ Window { //app.openAthlete() // dorian: 53139 , rustam: 6933 , helen: 53300 //openWidget({nation:'GER'}) //mainStack.push("Pages/AthleteSearchPage.qml") - //openWidget({comp: 11651, cat: 26}) + openWidget({comp: 11651, cat: 26}) //openWidget({person: 6623}) //console.log(JSON.stringify(serverConn.getParamsFromUrl(""))) //openWidgetFromUrl("https://l.bluerock.dev/?comp=11601&type=starters") @@ -321,15 +321,13 @@ Window { height: childrenRect.height width: parent.width - extraComponentLoader.width - toolButton.width - 3 * parent.spacing - Label { + MovingLabel { id: toolBarTitleLa + syncWithLabel: toolBarSubTitleLa width: parent.width - scale: 1 - elide: "ElideRight" - font.bold: true verticalAlignment: Text.AlignVCenter @@ -361,13 +359,13 @@ Window { } } - Label { + MovingLabel { id: toolBarSubTitleLa - width: parent.width - height: text !== "" ? undefined:0 + visible: text !== "" - elide: "ElideRight" + syncWithLabel: toolBarTitleLa + width: parent.width font.bold: false @@ -380,7 +378,7 @@ Window { titleString = mainStack.currentItem.subTitle } - return(titleString) + return titleString } Behavior on text { @@ -566,7 +564,7 @@ Window { Product { id: speedFlowChartProduct //identifier: "speed_flowchart" - identifier: QT_DEBUG ? "android.test.purchased":"speed_flowchart" + identifier: "android.test.purchased" //identifier: "android.test.canceled" //identifier: "android.test.refunded" diff --git a/resources/qml/qml.qrc b/resources/qml/qml.qrc index 4393e01..323af13 100644 --- a/resources/qml/qml.qrc +++ b/resources/qml/qml.qrc @@ -30,5 +30,6 @@ Components/AlignedButton.qml Components/SharePopup.qml Pages/QrCodeScanPage.qml + Components/MovingLabel.qml diff --git a/resources/translations/de.qm b/resources/translations/de.qm index 4d78569e73bb12676524a4eaaf85b4c544d85417..cf8a115f8f12848386796645cb6ffbd2cc119f03 100644 GIT binary patch delta 840 zcmZWlO-K}B7=C7VW@q-_)int_teR5(k%kb_qNR1&G72q_$aI}H-CT8lu=X-hcIl$E zS!5-YWC#0E)`MXuB?!$+5k-g45`qp~EE_1%UI+AviB_J0|cwp9Uc7>_>s1lW6xO~HKfdW^@eeg|xqj1M*y zlGkONG0zYm7K@vwDTEkPvjI6Ko@={7{Gs@#jkUX4+U-sPu3b`nO#`4gH%R00yMR(7 zO}-hS;D_|(_A?s4HhJf0?EEMz6K^T}CWp!gfy^xVO#gY-qw=k@2F~%y!+8wiT9)s8 z-VS7CC?yN`sJp3@`ZKwROBpDY=<8L+M<*Hlz4CkH1B0%b-xaPvgRR!Q^mvweFI(~* z7XfRBWk-F2!t0jCI1R1y7Jp-e#!swO&*wR4+Ik_tz%I>}JJiQOL-wGLx6NV?UaRGx zS^Mh!Mh>WPG!&61zI3Py`XVPB-HWg2bKF^(yFy)^v$dno44A&Q1KC@W6T+aF=Rp%< z2q27hoaFH!&iXW35aCe~N;I4LOMI+5S%rD)_*#Ce&caVb=@39Pu~9D81Or-W5+igN z2T=st<(K1kuFBEl_M<$~PgwzORXjz&RLF6{q++5~1Q*Vqiy3|-J zl728Ly@+zm3!$G2BM3_Dgp=bHuApQTRvPmFrj-; z=?B)>be|e(0oA5=6m0^e?fU5=5Pzv(*y;wdmkh0UKLhqA!{JaN=RAfZ7rz6xcEg?g zV$RhYX3R6}_Zmx%-X{^pxIYJwn~bM@SJ*#q{OM!u+9K7s(tvZV)VQk|7*M}Sll?aV zC109)J4V6_>Fc#86i%6{XDRG>C@ZOVBz}-16-g4m$h|{nSP#or`}Fjwmai8ui1U#= zx>UuWic&gvi@dl}=FQ?FW@WfcqHeA-d3%b%ri`{^?pC9P)z4D38)%NrR4vSRj-hqran9=cRV zqZ{^L<1I8;uQqSyoN-q5&xu8Ls$KK1sB_SsK{H@_9t3i-(kWfin7a-& z2=ko4DQGwbFOMHlL=yqiP-z{JPS)ML|LL;oCVmoe1T%lWM1foq#v)iH>LV7Xh(_zb?Sf=#>~)hXBK%=TGjox|sGJ?BAX-mVjq!t-MOOTJ zRv99scU5CWOJfd^LUcru2>N(;;W#mYiiSiY~)QF~& HIUe0_bmO)s diff --git a/resources/translations/de.ts b/resources/translations/de.ts index 31cf122..6e39f9f 100644 --- a/resources/translations/de.ts +++ b/resources/translations/de.ts @@ -18,18 +18,18 @@ Camera access required Camera access denied - + Kamerazugriff benötigt blueROCK needs to access your camera in order to scan QR-Codes. It will never record or store any photos or videos. This app needs to access your camera in order to scan QR-Codes. It will never record or store any photos or videos. - + blueROCK benötig Zugriff auf die Kamera um QR-Codes zu scannen. Es werden keine Fotos oder Videos aufgezeichnet oder gespeichert. Allow access - + Zugriff zulassen @@ -85,7 +85,7 @@ This item is currently unavailable - Diese Produkt ist nicht verfügbar + Dieses Produkt ist nicht verfügbar @@ -130,7 +130,7 @@ This app was built using the <a href='https://qt.io'>Qt Framework</a> licensed under the <a href='https://www.gnu.org/licenses/lgpl-3.0.en.html'>GNU lgplV3 license</a>.<br><br>This app is open source and licensed under the <a href='https://www.gnu.org/licenses/agpl-3.0.en.html'>GNU agplV3 license</a>, the source code can be found <a href='https://itsblue.dev/dorian/blueROCK/'>here</a>.<br><br>Resultservice and rankings provided by <a href='http://www.digitalROCK.de'>digital ROCK</a>. - Diese App wurde unter Verwendung des <a href='https://qt.io'>Qt Frameworks</a> unter der <a href='https://www.gnu.org/licenses/lgpl-3.0.en.html'>GNU lgplV3 Lizenz</a> erstellt.<br><br>Diese App ist Open-source und lizensiert unter der <a href='https://www.gnu.org/licenses/agpl-3.0.en.html'>GNU agplV3 Lizenz</a>. Der Sourcecode findet sich <a href='https://itsblue.dev/dorian/blueROCK/'>hier</a>.Die Ergebnisse und Ranglisten werden von <a href='http://www.digitalROCK.de'>digital ROCK</a> zur Verfügung gestellt. + Diese App wurde unter Verwendung des <a href='https://qt.io'>Qt Frameworks</a> unter der <a href='https://www.gnu.org/licenses/lgpl-3.0.en.html'>GNU lgplV3 Lizenz</a> erstellt.<br><br>Diese App ist Open-source und lizensiert unter der <a href='https://www.gnu.org/licenses/agpl-3.0.en.html'>GNU agplV3 Lizenz</a>. Der Sourcecode findet sich <a href='https://itsblue.dev/dorian/blueROCK/'>hier</a>.Die Ergebnisse und Ranglisten werden von <a href='http://www.digitalROCK.de'>digital ROCK</a> zur Verfügung gestellt. @@ -176,6 +176,7 @@ + Select category Kategorie auswählen @@ -217,7 +218,7 @@ Show results - + Ergebnisse anzeigen @@ -226,72 +227,44 @@ - (Startlist) (Startliste) - + Loading Laden - + No connection to server Keine Verbindung zum Server - + Not found Nicht gefunden - + No Data Keine Daten - + Invalid Request Ungültige Anfrage - + Unexpected error Unerwarteter Fehler - - Check out the results of %1 over here: - Verfolge die Ergebnisse vom Wettkampf "%1" hier live: - - - - AndroidShareUtils - - - Share: an Error occured - - - - - Share: an Error occured -WorkingDir not valid - - - - - - - - Empty URL received - - - - - - File does not exist: %1 - + + Check out the results of %1 over here: + Check out the results of %1 over here: + Verfolge die Ergebnisse von "%1" hier: diff --git a/resources/translations/en.qm b/resources/translations/en.qm index 728b0f486d809c247a55029b054374266b76c4fb..e12ab652e960d1d7ceb69e06b877652087a5f5ff 100644 GIT binary patch delta 87 zcmdm|wMT1$4`bOxUw6jM6Q`OBhO_7CO=VyZ*v($i-^9QmEHv@1IOC>?U&9$~C;KwG ri+$ralKu*mf5V@Y)xyBQ)|ClVG->lHMh8JgpUJO6Q`OBMzZJWO=VyZ*v($i-^9QmEHd$~IOCRyU&9&gC;KwG ri~Zm?lKu*mf5V@Y)xyBQ)|ClVG-dNDMh8JgzsawKEH^6&OECce>}wk& diff --git a/resources/translations/en.ts b/resources/translations/en.ts index ba048c1..5891f2c 100644 --- a/resources/translations/en.ts +++ b/resources/translations/en.ts @@ -172,6 +172,7 @@ + Select category @@ -222,71 +223,43 @@ - (Startlist) - + Loading - + No connection to server - + Not found - + No Data - + Invalid Request - + Unexpected error - - Check out the results of %1 over here: - - - - - AndroidShareUtils - - - Share: an Error occured - - - - - Share: an Error occured -WorkingDir not valid - - - - - - - - Empty URL received - - - - - - File does not exist: %1 + + Check out the results of %1 over here: + Check out the results of %1 over here: diff --git a/sources/bluerockbackend.cpp b/sources/bluerockbackend.cpp index 38094d5..8a1e655 100644 --- a/sources/bluerockbackend.cpp +++ b/sources/bluerockbackend.cpp @@ -97,7 +97,7 @@ QVariantMap BlueRockBackend::getParamsFromUrl(QString stringUrl) { } void BlueRockBackend::shareResultsAsUrl(QString url, QString compName) { - //% "Check out the results of %1 over here:" + //% "Check out the results of %1 over here:" this->_shareUtils->shareText(qtTrId("#shareResultsLinkText").arg(compName) + " \n", url); } @@ -112,6 +112,7 @@ void BlueRockBackend::shareResultsAsPoster(QString url, QString compName) { } } + compName = compName.replace("/", ""); path += "/" + compName + ".pdf"; QFile file(path); @@ -206,7 +207,7 @@ bool BlueRockBackend::requestCameraPermission() { return false; } - return true; + return false; #elif defined Q_OS_IOS return this->_iosPermissionUtils->requestCameraPermission(); #else diff --git a/sources/shareUtils/androidshareutils.cpp b/sources/shareUtils/androidshareutils.cpp index 42b9b8f..f3fdf64 100755 --- a/sources/shareUtils/androidshareutils.cpp +++ b/sources/shareUtils/androidshareutils.cpp @@ -188,7 +188,7 @@ void AndroidShareUtils::processActivityResult(int requestCode, int resultCode) emit shareFinished(requestCode); } else { qDebug() << "wrong result code: " << resultCode << " from request: " << requestCode; - emit shareError(requestCode, tr("Share: an Error occured")); + emit shareError(requestCode, "Share: an Error occured"); } } @@ -200,7 +200,7 @@ void AndroidShareUtils::checkPendingIntents(const QString workingDirPath) QAndroidJniObject jniWorkingDir = QAndroidJniObject::fromString(workingDirPath); if(!jniWorkingDir.isValid()) { qWarning() << "QAndroidJniObject jniWorkingDir not valid."; - emit shareError(0, tr("Share: an Error occured\nWorkingDir not valid")); + emit shareError(0, "Share: an Error occured\nWorkingDir not valid"); return; } activity.callMethod("checkPendingIntents","(Ljava/lang/String;)V", jniWorkingDir.object()); @@ -214,7 +214,7 @@ void AndroidShareUtils::setFileUrlReceived(const QString &url) { if(url.isEmpty()) { qWarning() << "setFileUrlReceived: we got an empty URL"; - emit shareError(0, tr("Empty URL received")); + emit shareError(0, "Empty URL received"); return; } qDebug() << "AndroidShareUtils setFileUrlReceived: we got the File URL from JAVA: " << url; @@ -232,7 +232,7 @@ void AndroidShareUtils::setFileUrlReceived(const QString &url) emit fileUrlReceived(myUrl); } else { qDebug() << "setFileUrlReceived: FILE does NOT exist "; - emit shareError(0, tr("File does not exist: %1").arg(myUrl)); + emit shareError(0, QString("File does not exist: %1").arg(myUrl)); } } @@ -240,7 +240,7 @@ void AndroidShareUtils::setOtherUrlReceived(const QString &url, const QString &s { if(url.isEmpty()) { qWarning() << "setFileUrlReceived: we got an empty URL"; - emit shareError(0, tr("Empty URL received")); + emit shareError(0, "Empty URL received"); return; } qDebug() << "AndroidShareUtils setOtherUrlReceived: we got the Other URL from JAVA: " << url; @@ -252,7 +252,7 @@ void AndroidShareUtils::setFileReceivedAndSaved(const QString &url) { if(url.isEmpty()) { qWarning() << "setFileReceivedAndSaved: we got an empty URL"; - emit shareError(0, tr("Empty URL received")); + emit shareError(0, "Empty URL received"); return; } qDebug() << "AndroidShareUtils setFileReceivedAndSaved: we got the File URL from JAVA: " << url; @@ -270,7 +270,7 @@ void AndroidShareUtils::setFileReceivedAndSaved(const QString &url) emit fileReceivedAndSaved(myUrl); } else { qDebug() << "setFileReceivedAndSaved: FILE does NOT exist "; - emit shareError(0, tr("File does not exist: %1").arg(myUrl)); + emit shareError(0, QString("File does not exist: %1").arg(myUrl)); } } @@ -280,7 +280,7 @@ bool AndroidShareUtils::checkFileExits(const QString &url) { if(url.isEmpty()) { qWarning() << "checkFileExits: we got an empty URL"; - emit shareError(0, tr("Empty URL received")); + emit shareError(0, "Empty URL received"); return false; } qDebug() << "AndroidShareUtils checkFileExits: we got the File URL from JAVA: " << url;