feat: add about panel customization on linux (#15658)
This commit is contained in:
parent
bc9a7806a5
commit
787dbbe610
5 changed files with 63 additions and 20 deletions
|
@ -392,13 +392,12 @@ void Browser::ShowAboutPanel() {
|
|||
void Browser::SetAboutPanelOptions(const base::DictionaryValue& options) {
|
||||
about_panel_options_.Clear();
|
||||
|
||||
// Upper case option keys for orderFrontStandardAboutPanelWithOptions format
|
||||
for (base::DictionaryValue::Iterator iter(options); !iter.IsAtEnd();
|
||||
iter.Advance()) {
|
||||
std::string key = iter.key();
|
||||
if (!key.empty() && iter.value().is_string()) {
|
||||
for (const auto& pair : options) {
|
||||
std::string key = pair.first;
|
||||
const auto& val = pair.second;
|
||||
if (!key.empty() && val->is_string()) {
|
||||
key[0] = base::ToUpperASCII(key[0]);
|
||||
about_panel_options_.SetString(key, iter.value().GetString());
|
||||
about_panel_options_.SetString(key, val->GetString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue