From f9d3c102ec4d0ed87e1ec0dfc65f37fb6f7a8afa Mon Sep 17 00:00:00 2001 From: nowrep Date: Fri, 14 Feb 2014 19:31:35 +0100 Subject: [PATCH] [Cleanup] QTimer::start() restarts timer if it is already running --- src/lib/bookmarks/bookmarksmodel.cpp | 1 - src/lib/bookmarks/bookmarkstoolbar.cpp | 1 - src/lib/desktopnotifications/desktopnotification.cpp | 1 - src/lib/history/historymodel.cpp | 1 - 4 files changed, 4 deletions(-) diff --git a/src/lib/bookmarks/bookmarksmodel.cpp b/src/lib/bookmarks/bookmarksmodel.cpp index eb6e9f20b..3619701de 100644 --- a/src/lib/bookmarks/bookmarksmodel.cpp +++ b/src/lib/bookmarks/bookmarksmodel.cpp @@ -322,7 +322,6 @@ void BookmarksFilterModel::setFilterFixedString(const QString &pattern) { m_pattern = pattern; - m_filterTimer->stop(); m_filterTimer->start(); } diff --git a/src/lib/bookmarks/bookmarkstoolbar.cpp b/src/lib/bookmarks/bookmarkstoolbar.cpp index b56135d45..ab6b9831b 100644 --- a/src/lib/bookmarks/bookmarkstoolbar.cpp +++ b/src/lib/bookmarks/bookmarkstoolbar.cpp @@ -109,7 +109,6 @@ void BookmarksToolbar::refresh() void BookmarksToolbar::bookmarksChanged() { - m_updateTimer->stop(); m_updateTimer->start(); } diff --git a/src/lib/desktopnotifications/desktopnotification.cpp b/src/lib/desktopnotifications/desktopnotification.cpp index db192449b..ca315a1a9 100644 --- a/src/lib/desktopnotifications/desktopnotification.cpp +++ b/src/lib/desktopnotifications/desktopnotification.cpp @@ -51,7 +51,6 @@ void DesktopNotification::show() ui->text->setText(m_text); if (!m_settingPosition) { - m_timer->stop(); m_timer->setInterval(m_timeout); m_timer->start(); } diff --git a/src/lib/history/historymodel.cpp b/src/lib/history/historymodel.cpp index 1e74febe6..998c9320d 100644 --- a/src/lib/history/historymodel.cpp +++ b/src/lib/history/historymodel.cpp @@ -529,7 +529,6 @@ void HistoryFilterModel::setFilterFixedString(const QString &pattern) { m_pattern = pattern; - m_filterTimer->stop(); m_filterTimer->start(); }