mirror of
https://git.jami.net/savoirfairelinux/jami-client-qt.git
synced 2025-10-30 07:53:33 +08:00
Compare commits
4 Commits
stable/202
...
beta/20240
| Author | SHA1 | Date | |
|---|---|---|---|
| 043a715c59 | |||
| 5bd3ead22d | |||
| a9aa1cac80 | |||
| 409ba70258 |
@ -116,7 +116,8 @@ ApplicationWindow {
|
||||
function close(force = false) {
|
||||
// If we're in the onboarding wizard or 'MinimizeOnClose'
|
||||
// is set, then we can quit
|
||||
if (force || !UtilsAdapter.getAppValue(Settings.MinimizeOnClose) || !UtilsAdapter.getAccountListSize()) {
|
||||
var minimizeToTray = UtilsAdapter.getAppValue(Settings.MinimizeOnClose) && UtilsAdapter.isSystemTrayIconVisible();
|
||||
if (force || !minimizeToTray || !UtilsAdapter.getAccountListSize()) {
|
||||
Qt.quit();
|
||||
} else {
|
||||
layoutManager.closeToTray();
|
||||
|
||||
@ -43,7 +43,7 @@ extern const QString defaultDownloadPath;
|
||||
|
||||
// Common key-value pairs for both APPSTORE and non-APPSTORE builds
|
||||
#define COMMON_KEYS \
|
||||
X(MinimizeOnClose, false) \
|
||||
X(MinimizeOnClose, true) \
|
||||
X(DownloadPath, defaultDownloadPath) \
|
||||
X(ScreenshotPath, {}) \
|
||||
X(EnableNotifications, true) \
|
||||
|
||||
@ -424,9 +424,9 @@ Control {
|
||||
id: editedRow
|
||||
anchors.left: root.bigMsg ? bubble.left : timestampItem.left
|
||||
anchors.bottom: parent.bottom
|
||||
anchors.bottomMargin: root.bigMsg || bubble.isDeleted ? 6 : 10
|
||||
anchors.bottomMargin: root.bigMsg ? 6 : 10
|
||||
anchors.leftMargin: root.bigMsg ? 10 : -timestampItem.width - 16
|
||||
visible: bubble.isEdited
|
||||
visible: bubble.isEdited && !bubble.isDeleted
|
||||
z: 1
|
||||
ResponsiveImage {
|
||||
id: editedImage
|
||||
|
||||
@ -274,7 +274,7 @@ BaseModalDialog {
|
||||
height: qrImage.height + 4
|
||||
anchors.centerIn: parent
|
||||
radius: 5
|
||||
color: JamiTheme.darkTheme ? JamiTheme.whiteColor : JamiTheme.jamiButtonBorderColor
|
||||
color: JamiTheme.whiteColor
|
||||
Image {
|
||||
id: qrImage
|
||||
anchors.centerIn: parent
|
||||
|
||||
@ -101,8 +101,7 @@ SettingsPageBase {
|
||||
id: closeOrMinCheckBox
|
||||
Layout.fillWidth: true
|
||||
|
||||
visible: UtilsAdapter.isSystemTrayIconVisible()
|
||||
checked: UtilsAdapter.getAppValue(Settings.MinimizeOnClose) && UtilsAdapter.isSystemTrayIconVisible()
|
||||
checked: UtilsAdapter.getAppValue(Settings.MinimizeOnClose)
|
||||
labelText: JamiStrings.keepMinimized
|
||||
onSwitchToggled: UtilsAdapter.setAppValue(Settings.Key.MinimizeOnClose, checked)
|
||||
}
|
||||
|
||||
@ -26,6 +26,7 @@
|
||||
#include "systemtray.h"
|
||||
#include "utils.h"
|
||||
#include "version.h"
|
||||
#include "global.h"
|
||||
|
||||
#include <api/datatransfermodel.h>
|
||||
#include <api/contact.h>
|
||||
@ -229,7 +230,7 @@ UtilsAdapter::getConvIdForUri(const QString& accountId, const QString& uri)
|
||||
return {};
|
||||
return convInfo->get().uid;
|
||||
} catch (const std::out_of_range& e) {
|
||||
qDebug() << e.what();
|
||||
C_DBG << e.what();
|
||||
return "";
|
||||
}
|
||||
}
|
||||
@ -242,7 +243,7 @@ UtilsAdapter::getPeerUri(const QString& accountId, const QString& uid)
|
||||
const auto& convInfo = convModel->getConversationForUid(uid).value();
|
||||
return convInfo.get().participants.front().uri;
|
||||
} catch (const std::out_of_range& e) {
|
||||
qDebug() << e.what();
|
||||
C_DBG << e.what();
|
||||
return "";
|
||||
}
|
||||
}
|
||||
@ -745,7 +746,7 @@ UtilsAdapter::isSystemThemeDark()
|
||||
#endif
|
||||
return readAppsUseLightThemeRegistry(true);
|
||||
#else
|
||||
qWarning("System theme detection is not implemented or is not supported");
|
||||
C_WARN << "System theme detection is not implemented or is not supported";
|
||||
return false;
|
||||
#endif // WIN32
|
||||
#endif // __has_include(<gio/gio.h>)
|
||||
@ -827,13 +828,7 @@ UtilsAdapter::isRTL()
|
||||
bool
|
||||
UtilsAdapter::isSystemTrayIconVisible()
|
||||
{
|
||||
if (!systemTray_)
|
||||
return false;
|
||||
// https://bugreports.qt.io/browse/QTBUG-118656
|
||||
#if defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)
|
||||
return true;
|
||||
#endif
|
||||
return systemTray_->geometry() != QRect();
|
||||
return QSystemTrayIcon::isSystemTrayAvailable() && systemTray_;
|
||||
}
|
||||
|
||||
QString
|
||||
@ -891,7 +886,7 @@ UtilsAdapter::createDummyImage() const
|
||||
qInfo() << "Dummy image created" << QDir::tempPath() + "/dummy.png";
|
||||
return QDir::tempPath() + "/dummy.png";
|
||||
} else {
|
||||
qWarning() << "Could not create dummy image";
|
||||
C_WARN << "Could not create dummy image";
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
@ -707,7 +707,7 @@ Jami will now quit.</source>
|
||||
<message>
|
||||
<location filename="../src/app/net/jami/Constants/JamiStrings.qml" line="315"/>
|
||||
<source>Turn off sharing</source>
|
||||
<translation>Ακλείστε τη διανομή</translation>
|
||||
<translation>Απενεργοποίηση κοινοποίησης</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/app/net/jami/Constants/JamiStrings.qml" line="316"/>
|
||||
|
||||
Reference in New Issue
Block a user