Commit d7b38248 authored by Gavin Williams's avatar Gavin Williams Committed by Commit Bot

Use title parameter for select dialog

This change uses the existing |title| parameter to set the title when
creating select dialogs. If the |title| is left empty, get the title
based on the select dialog type.

Screenshot: http://screen/3MwL5RSCHVhVXN6

Bug: 1143994
Change-Id: I5b653f892e3e295180692ffa89428cc2472aa9ad
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2508671
Commit-Queue: Gavin Williams <gavinwill@chromium.org>
Reviewed-by: default avatarLuciano Pacheco <lucmult@chromium.org>
Cr-Commit-Position: refs/heads/master@{#822504}
parent 52bd5337
......@@ -402,7 +402,9 @@ void SelectFileDialogExtension::SelectFileWithFileManagerParams(
dialog_params.is_modal = (owner.window != nullptr);
dialog_params.min_size = {kFileManagerMinimumWidth,
kFileManagerMinimumHeight};
dialog_params.title = file_manager::util::GetSelectFileDialogTitle(type);
dialog_params.title =
!title.empty() ? title
: file_manager::util::GetSelectFileDialogTitle(type);
if (base::FeatureList::IsEnabled(chromeos::features::kFilesNG)) {
dialog_params.title_color = kFilePickerActiveTitleColor;
dialog_params.title_inactive_color = kFilePickerInactiveTitleColor;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment