diff --git a/localization/rssguard_en.ts b/localization/rssguard_en.ts index ded3199c6..1bfc5e889 100644 --- a/localization/rssguard_en.ts +++ b/localization/rssguard_en.ts @@ -127,82 +127,67 @@ Error: %1 Application - + Application is already running. Application is already running - + Output directory is not writable. Output directory is not writable - - %1 survey - - - - - Please, fill the survey. - - - - - Go to survey - - - - + Settings file not copied to output directory successfully. Settings file not copied to output directory successfully. - + Database restoration was not initiated. Make sure that output directory is writable. Database restoration was not initiated. Make sure that output directory is writable. - + Settings restoration was not initiated. Make sure that output directory is writable. Settings restoration was not initiated. Make sure that output directory is writable. - + Cannot add feed Cannot add feed - + Feed cannot be added because there is no active account which can add feeds. - + Packages %1 were updated. - + Unread articles fetched - + Go to changelog - + AdBlock needs to be configured - + Welcome - + Welcome to %1. Please, check NEW stuff included in this @@ -210,17 +195,17 @@ version by clicking this popup notification. - + AdBlock is not configured properly. Go to "Settings" -> "Node.js" and check if your Node.js is properly configured. - + Already running - + Packages %1 were NOT updated because of error: %2. @@ -319,6 +304,14 @@ version by clicking this popup notification. + + BaseToastNotification + + + Close this notification + + + ColorToolButton @@ -1862,27 +1855,27 @@ QtWebEngine cache folder -> "%7" FormMain - + No possible actions No possible actions - + No recycle bin No recycle bin - + Main menu Main menu - + Open main menu - + Open &main menu @@ -2323,7 +2316,7 @@ QtWebEngine cache folder -> "%7" - + Add new category Add new category @@ -2494,37 +2487,37 @@ QtWebEngine cache folder -> "%7" - + Add new feed Add new feed - + No actions possible No actions possible - + Cannot cleanup database Cannot cleanup database - + Cannot cleanup database, because another critical action is running. Cannot cleanup database, because another critical action is running. - + Close opened modal dialogs first. Close opened modal dialogs first. - + Fetching common data - + Close dialogs @@ -3862,17 +3855,17 @@ Login tokens expiration: %2 LabelsNode - + Labels - + You can see all your labels (tags) here. - + New label @@ -4691,37 +4684,37 @@ Login tokens expiration: %2 MessagesView - + Problem with starting external e-mail client Problem with starting external e-mail client - + External e-mail client could not be started. External e-mail client could not be started. - + Open with external tool - + Cannot run external tool - + External tool '%1' could not be started. - + No external tools activated - + Context menu for articles @@ -5441,12 +5434,12 @@ List of supported readers: - + User-published articles - + Published articles @@ -5757,7 +5750,7 @@ Login tokens expiration: %2 Search - + Regular expression: %1 @@ -5816,7 +5809,7 @@ Login tokens expiration: %2 - + New regex query @@ -5824,17 +5817,17 @@ Login tokens expiration: %2 ServiceRoot - + Synchronize folders && other items - + Synchronize article cache - + Number of feeds: %1 Number of categories: %2 @@ -6247,27 +6240,27 @@ Authors of this application are NOT responsible for lost data. SettingsFeedsMessages - + Select new font - + Enter format for count of articles displayed next to each feed/category in feed list. Use "%all" and "%unread" strings which are placeholders for the actual count of all (or unread) articles. - + Note that enabling this might have drastic consequences on performance of article list with big number of articles. - + days (turned off) - + day(s) @@ -6275,10 +6268,20 @@ Authors of this application are NOT responsible for lost data. - + = unchanged size + + + PC restart needed + + + + + Your PC needs to be restarted to make some of enabled features fully working. + + Feed fetching @@ -6754,17 +6757,17 @@ Description: %3 - + Translators needed! - + The translation '%1' is incomplete and anyone able to help with translating %2 is greatly welcomed. - + Do you want to help with the translation now? @@ -6976,12 +6979,17 @@ Also, there are some built-in sounds. Just start typing ":" and they w SqliteDriver - + + cannot get native 'sqlite3' DB handle + + + + SQLite (embedded database) SQLite (embedded database) - + Database file not copied to output directory successfully. Database file not copied to output directory successfully. @@ -7472,12 +7480,12 @@ Unread news: %2 TabBar - + Close this tab. - + Close tab Close tab @@ -7523,27 +7531,27 @@ Unread news: %2 TextBrowserViewer - + image - + Enable external resources - + Open in external browser - + Download - + Open with external tool @@ -7582,20 +7590,53 @@ Unread news: %2 + + ToastNotification + + + Dialog + + + + + ... + + + + + 11 + + + + + TextLabel + + + + + PushButton + + + + + Do it! + + + ToolBarEditor - - + - - + + + Separator Separator - + Toolbar spacer Toolbar spacer @@ -7951,7 +7992,7 @@ Last login on: %4 - + cannot get list of feeds, network error '%1' @@ -7972,53 +8013,53 @@ Last login on: %4 WebBrowser - + Navigation panel Navigation panel - + View website in reader mode - + No title Webbrowser tab title when no title is available. No title - + Reader mode failed for this website - + Reader mode cannot be applied to current page. - + Back Back - + Forward Forward - + Reload Reload - + Stop Stop - + Open this website in system web browser diff --git a/src/librssguard/definitions/definitions.h b/src/librssguard/definitions/definitions.h index 3b9857df2..d4e347dbd 100644 --- a/src/librssguard/definitions/definitions.h +++ b/src/librssguard/definitions/definitions.h @@ -99,8 +99,10 @@ #define DEFAULT_NOTIFICATION_VOLUME 50 #define MAX_THREADPOOL_THREADS 32 #define WEB_BROWSER_SCROLL_STEP 50.0 -#define NOTIFICATIONS_MARGIN 16 -#define NOTIFICATIONS_WIDTH 256 + +#define NOTIFICATIONS_MARGIN 16 +#define NOTIFICATIONS_WIDTH 256 +#define NOTIFICATIONS_TIMEOUT 15s #define GOOGLE_SEARCH_URL "https://www.google.com/search?q=%1&ie=utf-8&oe=utf-8" #define GOOGLE_SUGGEST_URL "http://suggestqueries.google.com/complete/search?output=toolbar&hl=en&q=%1" diff --git a/src/librssguard/gui/notifications/basetoastnotification.cpp b/src/librssguard/gui/notifications/basetoastnotification.cpp index e01f13f68..07fc295a3 100644 --- a/src/librssguard/gui/notifications/basetoastnotification.cpp +++ b/src/librssguard/gui/notifications/basetoastnotification.cpp @@ -33,13 +33,14 @@ BaseToastNotification::BaseToastNotification(QWidget* parent) : QDialog(parent) BaseToastNotification::~BaseToastNotification() {} void BaseToastNotification::setupCloseButton(QAbstractButton* btn) { + btn->setToolTip(tr("Close this notification")); btn->setIcon(qApp->icons()->fromTheme(QSL("dialog-close"), QSL("gtk-close"))); connect(btn, &QAbstractButton::clicked, this, &BaseToastNotification::close); } void BaseToastNotification::setupTimedClosing() { - QTimer::singleShot(15s, this, &BaseToastNotification::close); + QTimer::singleShot(NOTIFICATIONS_TIMEOUT, this, &BaseToastNotification::close); } bool BaseToastNotification::eventFilter(QObject* watched, QEvent* event) { diff --git a/src/librssguard/gui/notifications/toastnotification.cpp b/src/librssguard/gui/notifications/toastnotification.cpp index c1a2a3c2b..bb2dd3d11 100644 --- a/src/librssguard/gui/notifications/toastnotification.cpp +++ b/src/librssguard/gui/notifications/toastnotification.cpp @@ -8,6 +8,15 @@ #include #endif +void ToastNotification::setupHeading() { + auto fon = m_ui.m_lblTitle->font(); + + fon.setBold(true); + fon.setPointSize(fon.pointSize() * 1.2); + + m_ui.m_lblTitle->setFont(fon); +} + ToastNotification::ToastNotification(Notification::Event event, const GuiMessage& msg, const GuiAction& action, @@ -15,13 +24,7 @@ ToastNotification::ToastNotification(Notification::Event event, : BaseToastNotification(parent) { m_ui.setupUi(this); - auto fon = m_ui.m_lblTitle->font(); - - fon.setBold(true); - // fon.s - - m_ui.m_lblTitle->setFont(fon); - + setupHeading(); setupCloseButton(m_ui.m_btnClose); setupTimedClosing(); diff --git a/src/librssguard/gui/notifications/toastnotification.h b/src/librssguard/gui/notifications/toastnotification.h index 5a127e045..b14f8bbd0 100644 --- a/src/librssguard/gui/notifications/toastnotification.h +++ b/src/librssguard/gui/notifications/toastnotification.h @@ -21,6 +21,7 @@ class ToastNotification : public BaseToastNotification { virtual bool alwaysOnTop() const; private: + void setupHeading(); void loadNotification(Notification::Event event, const GuiMessage& msg, const GuiAction& action); QIcon iconForType(QSystemTrayIcon::MessageIcon icon) const; diff --git a/src/librssguard/gui/notifications/toastnotification.ui b/src/librssguard/gui/notifications/toastnotification.ui index 1a7e89308..029cec080 100644 --- a/src/librssguard/gui/notifications/toastnotification.ui +++ b/src/librssguard/gui/notifications/toastnotification.ui @@ -14,6 +14,18 @@ Dialog + + 6 + + + 6 + + + 6 + + + 6 + @@ -24,6 +36,9 @@ Qt::AlignCenter + + true +