mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 15:07:45 +00:00
HackStudio: Rename Project::get_file() to Project::create_file()
The function no longer looks for the already opened files, so let's emphasize that by renaming it to `create_file`. :^)
This commit is contained in:
parent
4a1974b174
commit
d811ad921c
3 changed files with 5 additions and 5 deletions
|
@ -40,12 +40,12 @@ static void traverse_model(const GUI::FileSystemModel& model, const GUI::ModelIn
|
|||
void Project::for_each_text_file(Function<void(const ProjectFile&)> callback) const
|
||||
{
|
||||
traverse_model(model(), {}, [&](auto& index) {
|
||||
auto file = get_file(model().full_path(index));
|
||||
auto file = create_file(model().full_path(index));
|
||||
callback(*file);
|
||||
});
|
||||
}
|
||||
|
||||
NonnullRefPtr<ProjectFile> Project::get_file(const String& path) const
|
||||
NonnullRefPtr<ProjectFile> Project::create_file(const String& path) const
|
||||
{
|
||||
auto full_path = to_absolute_path(path);
|
||||
return ProjectFile::construct_with_name(full_path);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue