1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 20:37:35 +00:00

LibGUI: Remove GUI::FilePicker::file_exists()

I have no idea why this existed but everyone should just use
Core::File::exists() instead. :^)
This commit is contained in:
Andreas Kling 2021-02-19 23:46:54 +01:00
parent a8e0671344
commit 4f0be55770
4 changed files with 4 additions and 18 deletions

View file

@ -199,7 +199,7 @@ bool PropertiesWindow::apply_changes()
String new_name = m_name_box->text();
String new_file = make_full_path(new_name).characters();
if (GUI::FilePicker::file_exists(new_file)) {
if (Core::File::exists(new_file)) {
GUI::MessageBox::show(this, String::formatted("A file \"{}\" already exists!", new_name), "Error", GUI::MessageBox::Type::Error);
return false;
}