FileManager: Disable open_parent_directory_action if the new path is "/"

This commit is contained in:
Andres Vieira 2020-04-26 15:23:33 +02:00 committed by Andreas Kling
parent 421b6cd393
commit 1617be1e6f
Notes: sideshowbarker 2024-07-19 07:17:06 +09:00

View File

@ -652,6 +652,7 @@ int run_in_windowed_mode(RefPtr<Core::ConfigFile> config, String initial_locatio
go_forward_action->set_enabled(directory_view.path_history_position()
< directory_view.path_history_size() - 1);
go_back_action->set_enabled(directory_view.path_history_position() > 0);
open_parent_directory_action->set_enabled(new_path != "/");
};
directory_view.on_error = [&](int, const char* error_string, bool quit) {