mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 02:47:35 +00:00
GDirectoryModel: Add on_path_change hook
This commit is contained in:
parent
bf23f1e8bc
commit
f1c4b65089
2 changed files with 3 additions and 0 deletions
|
@ -351,5 +351,7 @@ void GDirectoryModel::open(const StringView& a_path)
|
||||||
int rc = read(m_notifier->fd(), buffer, sizeof(buffer));
|
int rc = read(m_notifier->fd(), buffer, sizeof(buffer));
|
||||||
ASSERT(rc >= 0);
|
ASSERT(rc >= 0);
|
||||||
};
|
};
|
||||||
|
if (on_path_change)
|
||||||
|
on_path_change();
|
||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,6 +34,7 @@ public:
|
||||||
size_t bytes_in_files() const { return m_bytes_in_files; }
|
size_t bytes_in_files() const { return m_bytes_in_files; }
|
||||||
|
|
||||||
Function<void(int done, int total)> on_thumbnail_progress;
|
Function<void(int done, int total)> on_thumbnail_progress;
|
||||||
|
Function<void()> on_path_change;
|
||||||
|
|
||||||
struct Entry {
|
struct Entry {
|
||||||
String name;
|
String name;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue