remove deprecated code
This commit is contained in:
parent
a08e274088
commit
b9ab3f8a4f
@ -40,16 +40,7 @@ namespace nana
|
||||
timer& operator=(timer&&) = delete;
|
||||
public:
|
||||
timer();
|
||||
#if 0 //deprecated
|
||||
[[deprecated("prefer a std::chrono::duration (like std::chrono::milliseconds) over "
|
||||
"raw integers for durations")]]
|
||||
timer(unsigned int ms) : timer{} { interval_(ms); } /// Accepts an initial interval in ms
|
||||
|
||||
template <typename Rep, typename Period> /// Accepts an initial interval in any chrono unit
|
||||
explicit timer(std::chrono::duration<Rep, Period> const & time) : timer{} { interval(time); }
|
||||
#else
|
||||
explicit timer(std::chrono::milliseconds ms);
|
||||
#endif
|
||||
~timer();
|
||||
|
||||
template<typename Function>
|
||||
@ -63,23 +54,8 @@ namespace nana
|
||||
bool started() const;
|
||||
void stop();
|
||||
|
||||
#if 0 //deprecated
|
||||
[[deprecated("prefer a std::chrono::duration (like std::chrono::milliseconds) over "
|
||||
"raw integers for durations")]]
|
||||
inline void interval(unsigned milliseconds) { interval_(milliseconds); }
|
||||
|
||||
template <typename Rep, typename Period>
|
||||
inline void interval(std::chrono::duration<Rep, Period> const & time_interval) ///< Set the duration between calls, accepts std::chrono
|
||||
{
|
||||
_m_interval(static_cast<unsigned>(std::chrono::duration_cast<std::chrono::milliseconds>(time_interval).count()));
|
||||
}
|
||||
#else
|
||||
void interval(std::chrono::milliseconds ms);
|
||||
#endif
|
||||
|
||||
#if 0 //deprecated
|
||||
unsigned interval() const;
|
||||
#endif
|
||||
template <typename Duration = std::chrono::milliseconds>
|
||||
inline Duration interval() const
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user