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

Side by Side Diff: chrome/browser/ui/webui/collected_cookies_ui_delegate.cc

Issue 7828065: chromeos: Add WebUI implementation of form repost dialog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge. again. Created 9 years, 3 months 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/webui/collected_cookies_ui_delegate.h" 5 #include "chrome/browser/ui/webui/collected_cookies_ui_delegate.h"
6 6
7 #include "base/message_loop.h" 7 #include "base/message_loop.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "base/values.h" 9 #include "base/values.h"
10 #include "chrome/browser/content_settings/host_content_settings_map.h" 10 #include "chrome/browser/content_settings/host_content_settings_map.h"
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 ResourceBundle::GetSharedInstance().GetRawDataResource( 122 ResourceBundle::GetSharedInstance().GetRawDataResource(
123 IDR_COLLECTED_COOKIES_HTML)); 123 IDR_COLLECTED_COOKIES_HTML));
124 std::string response = jstemplate_builder::GetI18nTemplateHtml( 124 std::string response = jstemplate_builder::GetI18nTemplateHtml(
125 html, &localized_strings); 125 html, &localized_strings);
126 126
127 SendResponse(request_id, base::RefCountedString::TakeString(&response)); 127 SendResponse(request_id, base::RefCountedString::TakeString(&response));
128 } 128 }
129 129
130 } // namespace 130 } // namespace
131 131
132 namespace browser {
133
134 // Declared in browser_dialogs.h so others don't have to depend on our header.
135 void ShowCollectedCookiesDialog(gfx::NativeWindow parent_window,
136 TabContentsWrapper* wrapper) {
137 CollectedCookiesUIDelegate::Show(wrapper);
138 }
139
140 } // namespace browser
141
132 // static 142 // static
133 void CollectedCookiesUIDelegate::Show(TabContentsWrapper* wrapper) { 143 void CollectedCookiesUIDelegate::Show(TabContentsWrapper* wrapper) {
134 CollectedCookiesUIDelegate* delegate = 144 CollectedCookiesUIDelegate* delegate =
135 new CollectedCookiesUIDelegate(wrapper); 145 new CollectedCookiesUIDelegate(wrapper);
136 Profile* profile = wrapper->profile(); 146 Profile* profile = wrapper->profile();
137 ConstrainedHtmlUI::CreateConstrainedHtmlDialog(profile, 147 ConstrainedHtmlUI::CreateConstrainedHtmlDialog(profile,
138 delegate, 148 delegate,
139 wrapper->tab_contents()); 149 wrapper->tab_contents());
140 } 150 }
141 151
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 if (!args->GetString(0, &node_path)) 289 if (!args->GetString(0, &node_path))
280 return; 290 return;
281 291
282 CookieTreeOriginNode* origin_node = GetOriginNode( 292 CookieTreeOriginNode* origin_node = GetOriginNode(
283 blocked_cookies_tree_model_.get(), node_path); 293 blocked_cookies_tree_model_.get(), node_path);
284 if (!origin_node) 294 if (!origin_node)
285 return; 295 return;
286 296
287 AddContentException(origin_node, CONTENT_SETTING_SESSION_ONLY); 297 AddContentException(origin_node, CONTENT_SETTING_SESSION_ONLY);
288 } 298 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/chrome_web_ui_factory.cc ('k') | chrome/browser/ui/webui/repost_form_warning_ui.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698