Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(159)

Side by Side Diff: chrome/browser/ui/website_settings/website_settings.cc

Issue 1459793002: Android: Allow compiling browser without Java UI (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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/website_settings/website_settings.h" 5 #include "chrome/browser/ui/website_settings/website_settings.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 12 matching lines...) Expand all
23 #include "chrome/browser/browsing_data/browsing_data_indexed_db_helper.h" 23 #include "chrome/browser/browsing_data/browsing_data_indexed_db_helper.h"
24 #include "chrome/browser/browsing_data/browsing_data_local_storage_helper.h" 24 #include "chrome/browser/browsing_data/browsing_data_local_storage_helper.h"
25 #include "chrome/browser/content_settings/host_content_settings_map_factory.h" 25 #include "chrome/browser/content_settings/host_content_settings_map_factory.h"
26 #include "chrome/browser/history/history_service_factory.h" 26 #include "chrome/browser/history/history_service_factory.h"
27 #include "chrome/browser/infobars/infobar_service.h" 27 #include "chrome/browser/infobars/infobar_service.h"
28 #include "chrome/browser/profiles/profile.h" 28 #include "chrome/browser/profiles/profile.h"
29 #include "chrome/browser/ssl/chrome_ssl_host_state_delegate.h" 29 #include "chrome/browser/ssl/chrome_ssl_host_state_delegate.h"
30 #include "chrome/browser/ssl/chrome_ssl_host_state_delegate_factory.h" 30 #include "chrome/browser/ssl/chrome_ssl_host_state_delegate_factory.h"
31 #include "chrome/browser/ui/website_settings/website_settings_ui.h" 31 #include "chrome/browser/ui/website_settings/website_settings_ui.h"
32 #include "chrome/common/chrome_switches.h" 32 #include "chrome/common/chrome_switches.h"
33 #include "chrome/common/features.h"
33 #include "chrome/common/pref_names.h" 34 #include "chrome/common/pref_names.h"
34 #include "chrome/common/url_constants.h" 35 #include "chrome/common/url_constants.h"
35 #include "chrome/grit/chromium_strings.h" 36 #include "chrome/grit/chromium_strings.h"
36 #include "chrome/grit/generated_resources.h" 37 #include "chrome/grit/generated_resources.h"
37 #include "components/content_settings/core/browser/content_settings_utils.h" 38 #include "components/content_settings/core/browser/content_settings_utils.h"
38 #include "components/content_settings/core/browser/host_content_settings_map.h" 39 #include "components/content_settings/core/browser/host_content_settings_map.h"
39 #include "components/content_settings/core/browser/local_shared_objects_counter. h" 40 #include "components/content_settings/core/browser/local_shared_objects_counter. h"
40 #include "components/content_settings/core/common/content_settings.h" 41 #include "components/content_settings/core/common/content_settings.h"
41 #include "components/content_settings/core/common/content_settings_pattern.h" 42 #include "components/content_settings/core/common/content_settings_pattern.h"
42 #include "components/rappor/rappor_utils.h" 43 #include "components/rappor/rappor_utils.h"
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 DCHECK(chrome_ssl_host_state_delegate_); 307 DCHECK(chrome_ssl_host_state_delegate_);
307 chrome_ssl_host_state_delegate_->RevokeUserAllowExceptionsHard( 308 chrome_ssl_host_state_delegate_->RevokeUserAllowExceptionsHard(
308 site_url().host()); 309 site_url().host());
309 did_revoke_user_ssl_decisions_ = true; 310 did_revoke_user_ssl_decisions_ = true;
310 } 311 }
311 312
312 void WebsiteSettings::Init( 313 void WebsiteSettings::Init(
313 const GURL& url, 314 const GURL& url,
314 const SecurityStateModel::SecurityInfo& security_info) { 315 const SecurityStateModel::SecurityInfo& security_info) {
315 bool isChromeUINativeScheme = false; 316 bool isChromeUINativeScheme = false;
316 #if defined(OS_ANDROID) 317 #if BUILDFLAG(ANDROID_JAVA_UI)
317 isChromeUINativeScheme = url.SchemeIs(chrome::kChromeUINativeScheme); 318 isChromeUINativeScheme = url.SchemeIs(chrome::kChromeUINativeScheme);
318 #endif 319 #endif
319 320
320 if (url.SchemeIs(url::kAboutScheme)) { 321 if (url.SchemeIs(url::kAboutScheme)) {
321 // All about: URLs except about:blank are redirected. 322 // All about: URLs except about:blank are redirected.
322 DCHECK_EQ(url::kAboutBlankURL, url.spec()); 323 DCHECK_EQ(url::kAboutBlankURL, url.spec());
323 site_identity_status_ = SITE_IDENTITY_STATUS_NO_CERT; 324 site_identity_status_ = SITE_IDENTITY_STATUS_NO_CERT;
324 site_identity_details_ = 325 site_identity_details_ =
325 l10n_util::GetStringUTF16(IDS_PAGE_INFO_SECURITY_TAB_INSECURE_IDENTITY); 326 l10n_util::GetStringUTF16(IDS_PAGE_INFO_SECURITY_TAB_INSECURE_IDENTITY);
326 site_connection_status_ = SITE_CONNECTION_STATUS_UNENCRYPTED; 327 site_connection_status_ = SITE_CONNECTION_STATUS_UNENCRYPTED;
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after
699 info.connection_status = site_connection_status_; 700 info.connection_status = site_connection_status_;
700 info.connection_status_description = 701 info.connection_status_description =
701 UTF16ToUTF8(site_connection_details_); 702 UTF16ToUTF8(site_connection_details_);
702 info.identity_status = site_identity_status_; 703 info.identity_status = site_identity_status_;
703 info.identity_status_description = 704 info.identity_status_description =
704 UTF16ToUTF8(site_identity_details_); 705 UTF16ToUTF8(site_identity_details_);
705 info.cert_id = cert_id_; 706 info.cert_id = cert_id_;
706 info.show_ssl_decision_revoke_button = show_ssl_decision_revoke_button_; 707 info.show_ssl_decision_revoke_button = show_ssl_decision_revoke_button_;
707 ui_->SetIdentityInfo(info); 708 ui_->SetIdentityInfo(info);
708 } 709 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698