diff --git a/src/support/FileMonitor.cpp b/src/support/FileMonitor.cpp index df88723509..1abca468ed 100644 --- a/src/support/FileMonitor.cpp +++ b/src/support/FileMonitor.cpp @@ -58,7 +58,9 @@ FileMonitor::FileMonitor(FileName const & file_with_path, int interval) FileMonitor::~FileMonitor() -{} +{ + delete pimpl_; +} void FileMonitor::reset(FileName const & file_with_path) const diff --git a/src/support/FileMonitor.h b/src/support/FileMonitor.h index 2c21310251..5b04b6c8ff 100644 --- a/src/support/FileMonitor.h +++ b/src/support/FileMonitor.h @@ -15,8 +15,6 @@ #ifndef FILEMONITOR_H #define FILEMONITOR_H -#include -#include #include namespace lyx { @@ -24,14 +22,15 @@ namespace support { class FileName; -class FileMonitor : boost::noncopyable { +class FileMonitor +{ public: /** Once monitoring begins, the file will be monitored every * interval ms. */ FileMonitor(FileName const & file_with_path, int interval); - /// Define an empty d-tor out-of-line to keep boost::scoped_ptr happy. + /// Destructor ~FileMonitor(); /// @@ -60,11 +59,14 @@ public: boost::signals::connection connect(slot_type const &) const; private: + /// noncopyable + FileMonitor(FileMonitor const &); + void operator=(FileMonitor const &); + /// Use the Pimpl idiom to hide the internals. class Impl; - /// The pointer never changes although *pimpl_'s contents may. - boost::scoped_ptr const pimpl_; + Impl * const pimpl_; }; } // namespace support