| Index: chrome/browser/ui/webui/ntp/new_tab_ui.cc
|
| diff --git a/chrome/browser/ui/webui/ntp/new_tab_ui.cc b/chrome/browser/ui/webui/ntp/new_tab_ui.cc
|
| index 52c3cd17052d7ae0089c2b3765d11cc5f92df8c2..561571832dc696bf946291a5aad61fcb0519df15 100644
|
| --- a/chrome/browser/ui/webui/ntp/new_tab_ui.cc
|
| +++ b/chrome/browser/ui/webui/ntp/new_tab_ui.cc
|
| @@ -27,6 +27,7 @@
|
| #include "components/user_prefs/pref_registry_syncable.h"
|
| #include "content/public/browser/browser_thread.h"
|
| #include "content/public/browser/notification_service.h"
|
| +#include "content/public/browser/render_process_host.h"
|
| #include "content/public/browser/render_view_host.h"
|
| #include "content/public/browser/url_data_source.h"
|
| #include "content/public/browser/web_contents.h"
|
| @@ -315,7 +316,8 @@ std::string NewTabUI::NewTabHTMLSource::GetSource() const {
|
|
|
| void NewTabUI::NewTabHTMLSource::StartDataRequest(
|
| const std::string& path,
|
| - bool is_incognito,
|
| + int render_process_id,
|
| + int render_view_id,
|
| const content::URLDataSource::GotDataCallback& callback) {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
|
|
|
| @@ -345,6 +347,9 @@ void NewTabUI::NewTabHTMLSource::StartDataRequest(
|
| return;
|
| }
|
|
|
| + content::RenderProcessHost* render_host =
|
| + content::RenderProcessHost::FromID(render_process_id);
|
| + bool is_incognito = render_host->GetBrowserContext()->IsOffTheRecord();
|
| scoped_refptr<base::RefCountedMemory> html_bytes(
|
| NTPResourceCacheFactory::GetForProfile(profile_)->
|
| GetNewTabHTML(is_incognito));
|
|
|