summaryrefslogtreecommitdiffstats
blob: 1fb3d69e707486e3eac834cc83e9fb6543beaf55 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#pragma once

#include <boost/signals.hpp>
#include <boost/shared_ptr.hpp>

namespace Swift {
	class IdleDetector {
		public:
			virtual ~IdleDetector();

			void setIdleTimeSeconds(int time) {
				idleTimeSeconds = time;
			}

			int getIdleTimeSeconds() const {
				return idleTimeSeconds;
			}

			boost::signal<void (bool /* isIdle */)> onIdleChanged;

		private:
			int idleTimeSeconds;
	};
}