dirmonitor: add watch to subdirs on file limit mode (#1155)
This commit is contained in:
parent
fb8bc08a67
commit
f89088d0ec
|
@ -373,6 +373,11 @@ end
|
||||||
function core.update_project_subdir(dir, filename, expanded)
|
function core.update_project_subdir(dir, filename, expanded)
|
||||||
assert(dir.files_limit, "function should be called only when directory is in files limit mode")
|
assert(dir.files_limit, "function should be called only when directory is in files limit mode")
|
||||||
dir.shown_subdir[filename] = expanded
|
dir.shown_subdir[filename] = expanded
|
||||||
|
if expanded then
|
||||||
|
dir.watch:watch(dir.name .. PATHSEP .. filename)
|
||||||
|
else
|
||||||
|
dir.watch:unwatch(dir.name .. PATHSEP .. filename)
|
||||||
|
end
|
||||||
return refresh_directory(dir, filename)
|
return refresh_directory(dir, filename)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue