OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/ui/gtk/website_settings/website_settings_popup_gtk.h" | 5 #include "chrome/browser/ui/gtk/website_settings/website_settings_popup_gtk.h" |
6 | 6 |
7 #include "base/i18n/rtl.h" | 7 #include "base/i18n/rtl.h" |
8 #include "base/strings/string_number_conversions.h" | 8 #include "base/strings/string_number_conversions.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "chrome/browser/certificate_viewer.h" | 10 #include "chrome/browser/certificate_viewer.h" |
(...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
482 GtkWidget* hbox = gtk_hbox_new(FALSE, 0); | 482 GtkWidget* hbox = gtk_hbox_new(FALSE, 0); |
483 GtkWidget* identity_label = theme_service_->BuildLabel( | 483 GtkWidget* identity_label = theme_service_->BuildLabel( |
484 identity_info.site_identity, ui::kGdkBlack); | 484 identity_info.site_identity, ui::kGdkBlack); |
485 gtk_label_set_selectable(GTK_LABEL(identity_label), TRUE); | 485 gtk_label_set_selectable(GTK_LABEL(identity_label), TRUE); |
486 PangoAttrList* attributes = pango_attr_list_new(); | 486 PangoAttrList* attributes = pango_attr_list_new(); |
487 pango_attr_list_insert(attributes, | 487 pango_attr_list_insert(attributes, |
488 pango_attr_weight_new(PANGO_WEIGHT_BOLD)); | 488 pango_attr_weight_new(PANGO_WEIGHT_BOLD)); |
489 gtk_label_set_attributes(GTK_LABEL(identity_label), attributes); | 489 gtk_label_set_attributes(GTK_LABEL(identity_label), attributes); |
490 pango_attr_list_unref(attributes); | 490 pango_attr_list_unref(attributes); |
491 gtk_box_pack_start(GTK_BOX(hbox), identity_label, FALSE, FALSE, 0); | 491 gtk_box_pack_start(GTK_BOX(hbox), identity_label, FALSE, FALSE, 0); |
492 close_button_.reset(CustomDrawButton::CloseButton(theme_service_)); | 492 close_button_.reset(CustomDrawButton::CloseButtonBubble(theme_service_)); |
493 g_signal_connect(close_button_->widget(), "clicked", | 493 g_signal_connect(close_button_->widget(), "clicked", |
494 G_CALLBACK(OnCloseButtonClickedThunk), this); | 494 G_CALLBACK(OnCloseButtonClickedThunk), this); |
495 gtk_box_pack_start(GTK_BOX(hbox), close_button_->widget(), FALSE, FALSE, 0); | 495 gtk_box_pack_start(GTK_BOX(hbox), close_button_->widget(), FALSE, FALSE, 0); |
496 int label_width = kPopupWidth - close_button_->SurfaceWidth(); | 496 int label_width = kPopupWidth - close_button_->SurfaceWidth(); |
497 gtk_util::SetLabelWidth(identity_label, label_width); | 497 gtk_util::SetLabelWidth(identity_label, label_width); |
498 gtk_box_pack_start(GTK_BOX(header_box_), hbox, FALSE, FALSE, 0); | 498 gtk_box_pack_start(GTK_BOX(header_box_), hbox, FALSE, FALSE, 0); |
499 | 499 |
500 std::string identity_status_text; | 500 std::string identity_status_text; |
501 const GdkColor* color = &ui::kGdkBlack; | 501 const GdkColor* color = &ui::kGdkBlack; |
502 | 502 |
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
733 } | 733 } |
734 | 734 |
735 void WebsiteSettingsPopupGtk::OnHelpLinkClicked(GtkWidget* widget) { | 735 void WebsiteSettingsPopupGtk::OnHelpLinkClicked(GtkWidget* widget) { |
736 browser_->OpenURL(OpenURLParams(GURL(chrome::kPageInfoHelpCenterURL), | 736 browser_->OpenURL(OpenURLParams(GURL(chrome::kPageInfoHelpCenterURL), |
737 content::Referrer(), | 737 content::Referrer(), |
738 NEW_FOREGROUND_TAB, | 738 NEW_FOREGROUND_TAB, |
739 content::PAGE_TRANSITION_LINK, | 739 content::PAGE_TRANSITION_LINK, |
740 false)); | 740 false)); |
741 bubble_->Close(); | 741 bubble_->Close(); |
742 } | 742 } |
OLD | NEW |