CNotifier.cpp 315 B

123456789101112131415
  1. #include <LibCore/CEvent.h>
  2. #include <LibCore/CEventLoop.h>
  3. #include <LibCore/CNotifier.h>
  4. CNotifier::CNotifier(int fd, unsigned event_mask)
  5. : m_fd(fd)
  6. , m_event_mask(event_mask)
  7. {
  8. CEventLoop::register_notifier({}, *this);
  9. }
  10. CNotifier::~CNotifier()
  11. {
  12. CEventLoop::unregister_notifier({}, *this);
  13. }