Commit 5202bde3 authored by James Hollyer's avatar James Hollyer Committed by Commit Bot

Clear the message with System Geolocation permission bubble

The Geolocation Bubble is a SimpleBubbleModel which sets a
message. When asking for System Location permission there
is no message. Therefore I set up a simple way to clear the
message and cleared it when needed.

Bug: 1051591
Change-Id: Idcfe468a5a49b961da25741550aab7f350da0586
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2393522Reviewed-by: default avatarBalazs Engedy <engedy@chromium.org>
Commit-Queue: Balazs Engedy <engedy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#804602}
parent 2ecc42be
...@@ -1350,6 +1350,7 @@ void ContentSettingGeolocationBubbleModel::OnManageButtonClicked() { ...@@ -1350,6 +1350,7 @@ void ContentSettingGeolocationBubbleModel::OnManageButtonClicked() {
void ContentSettingGeolocationBubbleModel:: void ContentSettingGeolocationBubbleModel::
InitializeSystemGeolocationPermissionBubble() { InitializeSystemGeolocationPermissionBubble() {
set_title(l10n_util::GetStringUTF16(IDS_GEOLOCATION_TURNED_OFF_IN_MACOS)); set_title(l10n_util::GetStringUTF16(IDS_GEOLOCATION_TURNED_OFF_IN_MACOS));
clear_message();
AddListItem(ContentSettingBubbleModel::ListItem( AddListItem(ContentSettingBubbleModel::ListItem(
&vector_icons::kLocationOnIcon, &vector_icons::kLocationOnIcon,
l10n_util::GetStringUTF16(IDS_GEOLOCATION), l10n_util::GetStringUTF16(IDS_GEOLOCATION),
......
...@@ -240,6 +240,7 @@ class ContentSettingBubbleModel { ...@@ -240,6 +240,7 @@ class ContentSettingBubbleModel {
void set_message(const base::string16& message) { void set_message(const base::string16& message) {
bubble_content_.message = message; bubble_content_.message = message;
} }
void clear_message() { bubble_content_.message.clear(); }
void AddListItem(const ListItem& item); void AddListItem(const ListItem& item);
void RemoveListItem(int index); void RemoveListItem(int index);
void set_radio_group(const RadioGroup& radio_group) { void set_radio_group(const RadioGroup& radio_group) {
......
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