mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-23 09:51:57 -05:00
LibCore: Allow subclassing FileWatcher
This will be handy for platforms which need to be able to store extra OS-specific members. For example, macOS needs to store a dispatch queue, and event stream, etc.
This commit is contained in:
parent
5063e218af
commit
0e7a48bd7d
1 changed files with 2 additions and 2 deletions
|
@ -69,7 +69,7 @@ public:
|
|||
Optional<FileWatcherEvent> wait_for_event();
|
||||
};
|
||||
|
||||
class FileWatcher final : public FileWatcherBase
|
||||
class FileWatcher : public FileWatcherBase
|
||||
, public RefCounted<FileWatcher> {
|
||||
AK_MAKE_NONCOPYABLE(FileWatcher);
|
||||
|
||||
|
@ -79,7 +79,7 @@ public:
|
|||
|
||||
Function<void(FileWatcherEvent const&)> on_change;
|
||||
|
||||
private:
|
||||
protected:
|
||||
FileWatcher(int watcher_fd, NonnullRefPtr<Notifier>);
|
||||
|
||||
NonnullRefPtr<Notifier> m_notifier;
|
||||
|
|
Loading…
Add table
Reference in a new issue