Commit 036b3bc9 authored by Halla Rempt's avatar Halla Rempt
Browse files

KisIdleWatcher: actually _use_ the delay parameter

A parameter "delay" was added to KisIdleWatcher, but the hard-coded
constant was used instead. This makes it possible to update the
overview widget a bit more aggressively.

BUG:443674
(cherry picked from commit 958a8d7a)
parent 84fa3052
Pipeline #196546 passed with stage
in 73 minutes and 31 seconds
......@@ -14,7 +14,6 @@
struct KisIdleWatcher::Private
{
static const int IDLE_CHECK_PERIOD = 200; /* ms */
static const int IDLE_CHECK_COUNT = 4; /* ticks */
Private(int delay, KisIdleWatcher *q)
......@@ -23,7 +22,7 @@ struct KisIdleWatcher::Private
idleCheckCounter(0)
{
idleCheckTimer.setSingleShot(true);
idleCheckTimer.setInterval(IDLE_CHECK_PERIOD);
idleCheckTimer.setInterval(delay);
}
KisSignalAutoConnectionsStore connectionsStore;
......
......@@ -20,7 +20,7 @@ class KRITAIMAGE_EXPORT KisIdleWatcher : public QObject
{
Q_OBJECT
public:
KisIdleWatcher(int delay, QObject* parent = 0);
KisIdleWatcher(int delay = 200, QObject* parent = 0);
~KisIdleWatcher() override;
bool isIdle() const;
......
......@@ -30,7 +30,7 @@ OverviewWidget::OverviewWidget(QWidget * parent)
: QWidget(parent)
, m_canvas(0)
, m_dragging(false)
, m_imageIdleWatcher(250)
, m_imageIdleWatcher(150)
{
setMouseTracking(true);
KisConfig cfg(true);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment