2 * \file Timeout_pimpl.C
3 * Copyright 2001 LyX Team
6 * \author Lars Gullik Bjønnes
12 #include FORMS_H_LOCATION
15 #pragma implementation
18 #include "Timeout_pimpl.h"
28 void C_intern_timeout_cb(int, void * data)
30 Timeout * to = static_cast<Timeout *>(data);
39 Timeout::Pimpl::Pimpl(Timeout * owner)
40 : owner_(owner), timeout_id(-1)
45 void Timeout::Pimpl::reset()
51 void Timeout::Pimpl::start()
54 lyxerr << "Timeout::start: already running!" << endl;
55 timeout_id = fl_add_timeout(owner_->timeout_ms,
56 C_intern_timeout_cb, owner_);
60 void Timeout::Pimpl::stop()
62 if (timeout_id != -1) {
63 fl_remove_timeout(timeout_id);