summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authoryusukes@google.com <yusukes@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-10 18:19:04 +0000
committeryusukes@google.com <yusukes@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-10 18:19:04 +0000
commitd2f2e494291d1eccb2be7b1886afbbf3c4fb3b77 (patch)
treeae037418a41227f9af047ec97bbfdc8298686b32 /chrome
parent858db8931765ec49fcf1ffd49b2e73b017b9d21b (diff)
downloadchromium_src-d2f2e494291d1eccb2be7b1886afbbf3c4fb3b77.zip
chromium_src-d2f2e494291d1eccb2be7b1886afbbf3c4fb3b77.tar.gz
chromium_src-d2f2e494291d1eccb2be7b1886afbbf3c4fb3b77.tar.bz2
Don't draw the red line when the security level is SECURE.
Review URL: http://codereview.chromium.org/273016/show BUG=24510 TEST=see the bug git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28667 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/autocomplete/autocomplete_edit_view_gtk.cc14
1 files changed, 7 insertions, 7 deletions
diff --git a/chrome/browser/autocomplete/autocomplete_edit_view_gtk.cc b/chrome/browser/autocomplete/autocomplete_edit_view_gtk.cc
index 46e92e8..35017b6 100644
--- a/chrome/browser/autocomplete/autocomplete_edit_view_gtk.cc
+++ b/chrome/browser/autocomplete/autocomplete_edit_view_gtk.cc
@@ -1199,17 +1199,17 @@ void AutocompleteEditViewGtk::EmphasizeURLComponents() {
// Emphasize the scheme for security UI display purposes (if necessary).
if (!model_->user_input_in_progress() && parts.scheme.is_nonempty() &&
(scheme_security_level_ != ToolbarModel::NORMAL)) {
- strikethrough_ = CharRange(GetUTF8Offset(text, parts.scheme.begin),
- GetUTF8Offset(text, parts.scheme.end()));
- ItersFromCharRange(strikethrough_, &start, &end);
- // When we draw the strikethrough, we don't want to include the ':' at the
- // end of the scheme.
- strikethrough_.cp_max--;
-
if (scheme_security_level_ == ToolbarModel::SECURE) {
gtk_text_buffer_apply_tag(text_buffer_, secure_scheme_tag_,
&start, &end);
} else {
+ strikethrough_ = CharRange(GetUTF8Offset(text, parts.scheme.begin),
+ GetUTF8Offset(text, parts.scheme.end()));
+ ItersFromCharRange(strikethrough_, &start, &end);
+ // When we draw the strikethrough, we don't want to include the ':' at the
+ // end of the scheme.
+ strikethrough_.cp_max--;
+
gtk_text_buffer_apply_tag(text_buffer_, insecure_scheme_tag_,
&start, &end);
}