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

Side by Side Diff: components/pdf/renderer/pepper_pdf_host.cc

Issue 2100753003: Enable PDF accessibility when RenderFrame's accessibility mode changes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix win assertion Created 4 years, 5 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "components/pdf/renderer/pepper_pdf_host.h" 5 #include "components/pdf/renderer/pepper_pdf_host.h"
6 6
7 #include "components/pdf/common/pdf_messages.h" 7 #include "components/pdf/common/pdf_messages.h"
8 #include "components/pdf/renderer/pdf_accessibility_tree.h" 8 #include "components/pdf/renderer/pdf_accessibility_tree.h"
9 #include "content/public/common/referrer.h" 9 #include "content/public/common/referrer.h"
10 #include "content/public/renderer/pepper_plugin_instance.h" 10 #include "content/public/renderer/pepper_plugin_instance.h"
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 CreatePdfAccessibilityTreeIfNeeded(instance); 230 CreatePdfAccessibilityTreeIfNeeded(instance);
231 pdf_accessibility_tree_->SetAccessibilityPageInfo( 231 pdf_accessibility_tree_->SetAccessibilityPageInfo(
232 page_info, text_run_info, chars); 232 page_info, text_run_info, chars);
233 return PP_OK; 233 return PP_OK;
234 } 234 }
235 235
236 void PepperPDFHost::CreatePdfAccessibilityTreeIfNeeded( 236 void PepperPDFHost::CreatePdfAccessibilityTreeIfNeeded(
237 content::PepperPluginInstance* instance) { 237 content::PepperPluginInstance* instance) {
238 if (!pdf_accessibility_tree_) { 238 if (!pdf_accessibility_tree_) {
239 pdf_accessibility_tree_.reset( 239 pdf_accessibility_tree_.reset(
240 new PdfAccessibilityTree(instance->GetRenderView())); 240 new PdfAccessibilityTree(instance->GetRenderFrame()));
raymes 2016/07/12 01:36:23 There's already a function in RendererPpapiHost (h
dmazzoni 2016/07/13 23:17:53 Got it. OK, now I'm passing RendererPpapiHost and
241 } 241 }
242 } 242 }
243 243
244 } // namespace pdf 244 } // namespace pdf
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698