GODT-2210: v3.0 splash screen.

Other: new splash screen content.
This commit is contained in:
Xavier Michelon
2023-01-19 13:37:50 +01:00
parent 1bfabf9a83
commit 24c68f100e
34 changed files with 2365 additions and 5255 deletions

View File

@ -77,7 +77,6 @@ void QMLBackend::init(GRPCConfig const &serviceConfig) {
});
// Grab from bridge the value that will not change during the execution of this app (or that will only change locally).
app().grpc().showSplashScreen(showSplashScreen_);
app().grpc().goos(goos_);
app().grpc().logsPath(logsPath_);
app().grpc().licensePath(licensePath_);
@ -468,19 +467,6 @@ bool QMLBackend::isDoHEnabled() const {
)
}
//****************************************************************************************************************************************************
/// \return The value for the 'isFirstGUIStart' property.
//****************************************************************************************************************************************************
bool QMLBackend::isFirstGUIStart() const {
HANDLE_EXCEPTION_RETURN_BOOL(
bool v;
app().grpc().isFirstGUIStart(v);
return v;
)
}
//****************************************************************************************************************************************************
/// \return The value for the 'isAutomaticUpdateOn' property.
//****************************************************************************************************************************************************
@ -699,9 +685,11 @@ void QMLBackend::changeKeychain(QString const &keychain) {
//****************************************************************************************************************************************************
//
//****************************************************************************************************************************************************
void QMLBackend::guiReady() const {
void QMLBackend::guiReady() {
HANDLE_EXCEPTION(
app().grpc().guiReady();
bool showSplashScreen;
app().grpc().guiReady(showSplashScreen);
this->setShowSplashScreen(showSplashScreen);
)
}

View File

@ -74,7 +74,6 @@ public: // Qt/QML properties. Note that the NOTIFY-er signal is required even fo
Q_PROPERTY(int imapPort READ imapPort WRITE setIMAPPort NOTIFY imapPortChanged)
Q_PROPERTY(int smtpPort READ smtpPort WRITE setSMTPPort NOTIFY smtpPortChanged)
Q_PROPERTY(bool isDoHEnabled READ isDoHEnabled NOTIFY isDoHEnabledChanged)
Q_PROPERTY(bool isFirstGUIStart READ isFirstGUIStart)
Q_PROPERTY(bool isAutomaticUpdateOn READ isAutomaticUpdateOn NOTIFY isAutomaticUpdateOnChanged)
Q_PROPERTY(QString currentEmailClient READ currentEmailClient NOTIFY currentEmailClientChanged)
Q_PROPERTY(QStringList availableKeychain READ availableKeychain NOTIFY availableKeychainChanged)
@ -111,7 +110,6 @@ public: // Qt/QML properties. Note that the NOTIFY-er signal is required even fo
void setSMTPPort(int port); ///< Setter for the 'smtpPort' property.
int smtpPort() const; ///< Getter for the 'smtpPort' property.
bool isDoHEnabled() const; ///< Getter for the 'isDoHEnabled' property.
bool isFirstGUIStart() const; ///< Getter for the 'isFirstGUIStart' property.
bool isAutomaticUpdateOn() const; ///< Getter for the 'isAutomaticUpdateOn' property.
QString currentEmailClient() const; ///< Getter for the 'currentEmail' property.
QStringList availableKeychain() const; ///< Getter for the 'availableKeychain' property.
@ -163,7 +161,7 @@ public slots: // slot for signals received from QML -> To be forwarded to Bridge
void toggleAutomaticUpdate(bool makeItActive); ///< Slot for the automatic update toggle
void updateCurrentMailClient(); ///< Slot for the change of the current mail client.
void changeKeychain(QString const &keychain); ///< Slot for the change of keychain.
void guiReady() const; ///< Slot for the GUI ready signal.
void guiReady(); ///< Slot for the GUI ready signal.
void quit() const; ///< Slot for the quit signal.
void restart() const; ///< Slot for the restart signal.
void forceLauncher(QString launcher) const; ///< Slot for the change of the launcher.

View File

@ -42,6 +42,9 @@
<file>qml/icons/ic-other-mail-clients.svg</file>
<file>qml/icons/ic-plus.svg</file>
<file>qml/icons/ic-question-circle.svg</file>
<file>qml/icons/ic-splash-card.svg</file>
<file>qml/icons/ic-splash-drive.svg</file>
<file>qml/icons/ic-splash-view.svg</file>
<file>qml/icons/ic-success.svg</file>
<file>qml/icons/ic-three-dots-vertical.svg</file>
<file>qml/icons/ic-trash.svg</file>

View File

@ -281,11 +281,12 @@ QtObject {
}
}
if (Backend.showOnStartup) {
Backend.guiReady()
if (Backend.showOnStartup || Backend.showSplashScreen) {
mainWindow.showAndRise()
}
Backend.guiReady()
}
function setColorScheme() {

View File

@ -39,11 +39,11 @@ Dialog {
Image {
Layout.alignment: Qt.AlignHCenter
sourceSize.width: 400
sourceSize.height: 225
sourceSize.width: 384
sourceSize.height: 144
Layout.preferredWidth: 400
Layout.preferredHeight: 225
Layout.preferredWidth: 384
Layout.preferredHeight: 144
source: "./icons/img-splash.png"
}
@ -58,27 +58,110 @@ Dialog {
type: Label.Title
horizontalAlignment: Text.AlignHCenter
text: qsTr("Updated Proton, unified protection")
text: qsTr("What's new in Bridge")
}
Label {
colorScheme: root.colorScheme
RowLayout {
width: root.width
Layout.fillWidth: true
Layout.alignment: Qt.AlignHCenter;
Layout.preferredWidth: 336
Layout.leftMargin: 24
Layout.rightMargin: 24
wrapMode: Text.WordWrap
Item {
Layout.fillHeight: true
width: 24
Layout.leftMargin: 24
Layout.rightMargin: 24
Image {
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
sourceSize.width: 24
sourceSize.height: 24
source: "./icons/ic-splash-view.svg"
}
}
type: Label.Body
horizontalAlignment: Text.AlignHCenter
textFormat: Text.StyledText
text: qsTr("Introducing Protons refreshed look.<br/>") +
qsTr("Many services, one mission. Welcome to an Internet where privacy is the default. ") +
link("https://proton.me/news/updated-proton",qsTr("Learn More"))
Label {
colorScheme: root.colorScheme
onLinkActivated: Qt.openUrlExternally(link)
Layout.fillWidth: true
Layout.alignment: Qt.AlignHCenter;
Layout.preferredWidth: 264
Layout.leftMargin: 0
Layout.rightMargin: 24
wrapMode: Text.WordWrap
type: Label.Body
horizontalAlignment: Text.AlignLeft
textFormat: Text.StyledText
text: qsTr("<b>New IMAP engine</b><br/>For improved stability and performances.")
}
}
RowLayout {
width: root.width
Item {
Layout.fillHeight: true
width: 24
Layout.leftMargin: 24
Layout.rightMargin: 24
Image {
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
sourceSize.width: 24
sourceSize.height: 24
source: "./icons/ic-splash-card.svg"
}
}
Label {
colorScheme: root.colorScheme
Layout.fillWidth: true
Layout.alignment: Qt.AlignHCenter;
Layout.preferredWidth: 264
Layout.leftMargin: 0
Layout.rightMargin: 24
wrapMode: Text.WordWrap
type: Label.Body
horizontalAlignment: Text.AlignLeft
textFormat: Text.StyledText
text: qsTr("<b>Faster than ever</b><br/>Up to 10x faster syncing and receiving.")
}
}
RowLayout {
width: root.width
Item {
Layout.fillHeight: true
width: 24
Layout.leftMargin: 24
Layout.rightMargin: 24
Image {
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
sourceSize.width: 24
sourceSize.height: 24
source: "./icons/ic-splash-drive.svg"
}
}
Label {
colorScheme: root.colorScheme
Layout.fillWidth: true
Layout.alignment: Qt.AlignHCenter;
Layout.preferredWidth: 264
Layout.leftMargin: 0
Layout.rightMargin: 24
wrapMode: Text.WordWrap
type: Label.Body
horizontalAlignment: Text.AlignLeft
textFormat: Text.StyledText
text: qsTr("<b>Extra security</b><br/>New, encrypted local database and keychain improvements.")
}
}
Button {
@ -90,16 +173,21 @@ Dialog {
onClicked: Backend.showSplashScreen = false
}
Image {
Layout.alignment: Qt.AlignHCenter
Label {
colorScheme: root.colorScheme
Layout.fillWidth: true
Layout.alignment: Qt.AlignHCenter;
Layout.preferredWidth: 336
Layout.leftMargin: 24
Layout.rightMargin: 24
wrapMode: Text.WordWrap
sourceSize.width: 164
sourceSize.height: 32
type: Label.Body
horizontalAlignment: Text.AlignHCenter
textFormat: Text.StyledText
text: qsTr("Note that your client will redownload all the emails.<br/>") + link("https://proton.me/blog/new-proton-mail-bridge", qsTr("Learn more about new Bridge."))
Layout.preferredWidth: 164
Layout.preferredHeight: 32
source: "/qml/icons/img-proton-logos.svg"
onLinkActivated: function(link) { Qt.openUrlExternally(link) }
}
}
}

View File

@ -0,0 +1,6 @@
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.98 14.46C8.95341 14.4661 9.83408 13.8836 10.2094 12.9854C10.5847 12.0872 10.3803 11.0513 9.69201 10.363C9.00369 9.67467 7.96778 9.47029 7.06961 9.84561C6.17144 10.2209 5.58894 11.1016 5.595 12.075C5.595 13.3922 6.6628 14.46 7.98 14.46ZM7.98 11.175C8.42847 11.2333 8.76405 11.6153 8.76405 12.0675C8.76405 12.5197 8.42847 12.9017 7.98 12.96C7.53154 12.9017 7.19595 12.5197 7.19595 12.0675C7.19595 11.6153 7.53154 11.2333 7.98 11.175Z" fill="#657EE4"/>
<path d="M13.5 12H19.5V13.5H13.5V12Z" fill="#657EE4"/>
<path d="M19.5 15H13.5V16.5H19.5V15Z" fill="#657EE4"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M1.5 21V6H22.5V21H1.5ZM5.46 18.735V19.5H10.5V18.735L9.15 17.355H6.81L5.46 18.735ZM21 19.5H12V18.12L9.78 15.855H6.18L3.96 18.12V19.5H3V7.5H21V19.5Z" fill="#657EE4"/>
</svg>

After

Width:  |  Height:  |  Size: 929 B

View File

@ -0,0 +1,3 @@
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M17.7841 4.5L20.8523 11.25H3.14769L6.21587 4.5H17.7841ZM21 12.75H3V18H21V12.75ZM18.75 3H5.25L1.5 11.25V19.5H22.5V11.25L18.75 3ZM18 16.05V14.55H19.5V16.05H18ZM15 16.05H16.5V14.55H15V16.05Z" fill="#657EE4"/>
</svg>

After

Width:  |  Height:  |  Size: 358 B

View File

@ -0,0 +1,4 @@
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M1.5 3V22.5H22.5V3H1.5ZM21 21H3V19.185L6.3 17.235L9.84 18L15.675 15.075L21 19.125V21ZM15.825 13.38L21 17.25V9H3V17.445L6 15.645L9.66 16.5L15.825 13.38ZM21 7.5H3V4.5H15V6H16.5V4.5H18V6H19.5V4.5H21V7.5Z" fill="#657EE4"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M8.25 15C9.49264 15 10.5 13.9926 10.5 12.75C10.5 11.5074 9.49264 10.5 8.25 10.5C7.00736 10.5 6 11.5074 6 12.75C6 13.9926 7.00736 15 8.25 15ZM8.25 13.5C8.66421 13.5 9 13.1642 9 12.75C9 12.3358 8.66421 12 8.25 12C7.83579 12 7.5 12.3358 7.5 12.75C7.5 13.1642 7.83579 13.5 8.25 13.5Z" fill="#657EE4"/>
</svg>

After

Width:  |  Height:  |  Size: 718 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 937 KiB

After

Width:  |  Height:  |  Size: 127 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 213 KiB

After

Width:  |  Height:  |  Size: 122 KiB