summaryrefslogtreecommitdiffstats
path: root/pdf
Commit message (Collapse)AuthorAgeFilesLines
* Extracted method to CreateSinglePageRasterPdf() to simplify ↵vitalybuka@chromium.org2014-08-202-46/+73
| | | | | | | | | | | | | PrintPagesAsRasterPDF(). Fixed page passed into FPDFPageObj_NewImgeObj(). BUG=385119 Review URL: https://codereview.chromium.org/485413002 Cr-Commit-Position: refs/heads/master@{#290780} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@290780 0039d316-1c4b-4281-b951-d872f2087c98
* pdf: Use the default resource if high-dpi resources are unavailable.sadrul@chromium.org2014-08-201-3/+7
| | | | | | | | | | BUG=401242 R=thestig@chromium.org Review URL: https://codereview.chromium.org/484393002 Cr-Commit-Position: refs/heads/master@{#290766} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@290766 0039d316-1c4b-4281-b951-d872f2087c98
* pdf: Early out from CopyImage if there's nothing to copy.sadrul@chromium.org2014-08-201-1/+3
| | | | | | | | | | | | | | If CopyImage is called with src is an empty rectangle (this can happen for example if one of the resources is not available), then the code ends up trying to read from null/uninitialized memory. So early out instead in such cases. BUG=401242 R=thestig@chromium.org Review URL: https://codereview.chromium.org/465133005 Cr-Commit-Position: refs/heads/master@{#290736} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@290736 0039d316-1c4b-4281-b951-d872f2087c98
* OOP PDF - Add support for "page" open pdf parametern.bansal@samsung.com2014-08-191-55/+1
| | | | | | | | | | | | | | | This patch adds support for "page" feature of open PDF parameters in OOP PDF. When page is used as an open PDF parameter, then PDF should initially be loaded at the page specified by user. BUG=64309 Review URL: https://codereview.chromium.org/476733003 Cr-Commit-Position: refs/heads/master@{#290529} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@290529 0039d316-1c4b-4281-b951-d872f2087c98
* Defer request to print a PDF when the user initiates the entire frame and ↵ivandavid@chromium.org2014-08-151-5/+6
| | | | | | | | | | | | | | | | the PDF hasn't loaded. Original fix: https://codereview.chromium.org/427723004/ The original fix was reverted, however it actually shouldn't have been because it was mostly correct. This fix is the same as the old one, with an additional change. The call to DidStopLoading() in Instance::DocumentLoadComplete was moved to an earlier part of the function, causing DidStopLoading to be called before the print preview request. BUG=376969 Review URL: https://codereview.chromium.org/467343003 Cr-Commit-Position: refs/heads/master@{#290010} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@290010 0039d316-1c4b-4281-b951-d872f2087c98
* PDF: Add some CHECKS to help debug a crash.thestig@chromium.org2014-08-151-0/+6
| | | | | | | | | BUG=402035 Review URL: https://codereview.chromium.org/457873003 Cr-Commit-Position: refs/heads/master@{#289822} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@289822 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 289312 "Move StringToUpperASCII and LowerCaseEqualsASCII ..."brettw@chromium.org2014-08-131-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | > Move StringToUpperASCII and LowerCaseEqualsASCII to the base namespace > > Convert LowerCaseEqualsASCII to take StringPiece. In the current patch this is > generally a NOP but will allow me to delete the other 4 variants in a followup > (wanted to do that separately since that will require more review, since > callsites will be changed in nontrivial ways). > > In some cases, LowerCaseEqualsASCII is called with a WebString, which no > longer is implicitly converted. I added base::string16(...) around such > calls to force the right conversion. It happened in these files: > window_container_type.cc > savable_resources.cc > render_view_impl.cc > blink_ax_tree_source.cc > password_form_conversion_utils.cc > translate_helper.cc > chrome_render_view_observer.cc > dom_serializer_browsertest.cc > > R=jamesr@chromium.org > > Review URL: https://codereview.chromium.org/448143008 TBR=brettw@chromium.org Review URL: https://codereview.chromium.org/474483002 Cr-Commit-Position: refs/heads/master@{#289320} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@289320 0039d316-1c4b-4281-b951-d872f2087c98
* Move StringToUpperASCII and LowerCaseEqualsASCII to the base namespacebrettw@chromium.org2014-08-131-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | Convert LowerCaseEqualsASCII to take StringPiece. In the current patch this is generally a NOP but will allow me to delete the other 4 variants in a followup (wanted to do that separately since that will require more review, since callsites will be changed in nontrivial ways). In some cases, LowerCaseEqualsASCII is called with a WebString, which no longer is implicitly converted. I added base::string16(...) around such calls to force the right conversion. It happened in these files: window_container_type.cc savable_resources.cc render_view_impl.cc blink_ax_tree_source.cc password_form_conversion_utils.cc translate_helper.cc chrome_render_view_observer.cc dom_serializer_browsertest.cc R=jamesr@chromium.org Review URL: https://codereview.chromium.org/448143008 Cr-Commit-Position: refs/heads/master@{#289312} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@289312 0039d316-1c4b-4281-b951-d872f2087c98
* Fix crasher in the pdf tear down code path.ananta@chromium.org2014-08-131-0/+4
| | | | | | | | | | | | | | | The crash occurs because of a timer dereferencing a null engine pointer. The crash appears to have occurred due to this patch https://codereview.chromium.org/427583003/ Fix is to cancel all timers when the pdf instance is being torn down before destroying the engine. BUG=403036 Review URL: https://codereview.chromium.org/462283002 Cr-Commit-Position: refs/heads/master@{#289218} git-svn-id: svn://svn.chromium.org/chrome/trunk/src@289218 0039d316-1c4b-4281-b951-d872f2087c98
* Move StringToLowerASCII to base namespacebrettw@chromium.org2014-08-072-3/+3
| | | | | | | | TBR=sky Review URL: https://codereview.chromium.org/448853002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@288085 0039d316-1c4b-4281-b951-d872f2087c98
* Fix UAF in chrome_pdf::Instance::GetURL()tsepez@chromium.org2014-08-071-0/+3
| | | | | | | | | | | | | | The instance owns the engine via its engine_ scoped_ptr, so if the engine is being destroyed via the scoped_ptr destructor, it may not be safe to access anything in the instance since the instance may be partially destroyed. Instead, destroy the engine as the first step in the process so the instance is still intact. BUG=392956 Review URL: https://codereview.chromium.org/427583003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@287955 0039d316-1c4b-4281-b951-d872f2087c98
* Fix scrollbar painting problems in pdf files in HiDPI mode with fractional ↵ananta@chromium.org2014-08-071-5/+0
| | | | | | | | | | | | | | | | scales. Reason for the bug is painting code in the pdf plugin which converts back and forth from pixels to DIP and back to pixels causing us to draw over the scrollbars. Division and multiplication with fractional scales Is a lossy operation. BUG=399150 TEST=Tested manually with fractional scales on Windows. Review URL: https://codereview.chromium.org/437873002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@287952 0039d316-1c4b-4281-b951-d872f2087c98
* PDF: Handle the space bar key like page down.thestig@chromium.org2014-08-051-12/+12
| | | | | | | | BUG=397624 Review URL: https://codereview.chromium.org/431303002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@287520 0039d316-1c4b-4281-b951-d872f2087c98
* Remove OS_NACL #ifdefs in pdf/raymes@chromium.org2014-08-012-8/+0
| | | | | | | | | | | There are some OS_NACL ifdefs in pdf/{instance.cc/out_of_process_instance.cc}. I assume these are from long ago when we tried to get PDF running in NaCl but I believe that at present many more changes would be required to get it running in NaCl again so we might as well remove these. Review URL: https://codereview.chromium.org/424763008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286927 0039d316-1c4b-4281-b951-d872f2087c98
* Don't return uninitialized memory from PDFiumEngine::Form_Response().tsepez@chromium.org2014-07-291-2/+4
| | | | | | | | | | | | If the response is too long to return in the caller-supplied buffer, truncate it to fit per the description of the app_response method in third_party/pdfium/fpdfsdk/include/fpdfformfill.h BUG=397834 Review URL: https://codereview.chromium.org/424883002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286323 0039d316-1c4b-4281-b951-d872f2087c98
* Ensure pdf plugin sends DidStartLoading() consistentlyjaphet@chromium.org2014-07-171-0/+4
| | | | | | | | | | | | | | | | | | | | | | | There are situations where the pdf plugin will initialize itself in such a way that it never notifies content/renderer/ that it has started. In so doing, it also fails to send a stop message, since it tries to ensure it doesn't send mismatched start/stop messages. Print preview decides when to display the preview based on when loading stops. Since this only considers the page's content and not the pdf plugin's initialization, there is a race condition where we may try to preview before the plugin is ready. In this cases, we show "Loading preivew..." and never load the actual preview. There is a hack in place in print_preview_web_helper.cc to delay the process of showing the preview to maximize the chance that the pdf plugin will be ready. This change should allow us to rip that out. BUG=376969 Review URL: https://codereview.chromium.org/397713005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@283837 0039d316-1c4b-4281-b951-d872f2087c98
* Fix potential integer overflow when initializing Rect.palmer@chromium.org2014-07-161-8/+10
| | | | | | | | BUG=350782 Review URL: https://codereview.chromium.org/385173004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@283481 0039d316-1c4b-4281-b951-d872f2087c98
* PDF: Fix navigation for links that are just relative fragments.thestig@chromium.org2014-07-152-1/+23
| | | | | | | | | BUG=389333 TEST=Manual, see bug. Review URL: https://codereview.chromium.org/335993006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@283268 0039d316-1c4b-4281-b951-d872f2087c98
* Added GetPDFPageSizeByIndex to expose FPDF_GetPageSizeByIndex. The function ↵ivandavid@chromium.org2014-07-104-10/+66
| | | | | | | | | | outputs the width and height, in points, of a given PDF document page. BUG=388517 Review URL: https://codereview.chromium.org/376083002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@282300 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes for re-enabling more MSVC level 4 warnings: pdf/ editionpkasting@chromium.org2014-07-096-77/+43
| | | | | | | | | | | | | | | | | | This contains fixes for the following sorts of issues: * Signedness mismatch This relies on https://codereview.chromium.org/376003003 to make FPDF_FillRect() take a 32-bit value for the color in order to make the changes here as simple and clean as possible. This also contains a few other cleanups to make code simpler or more consistent. BUG=81439 TEST=none Review URL: https://codereview.chromium.org/372273005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@282146 0039d316-1c4b-4281-b951-d872f2087c98
* Disable font mapping when pepper API is not initializednoamsml@chromium.org2014-07-081-0/+6
| | | | | | | | | | | For cases such as Privet local printing when the pepper API is not initialized, disable font mapping to prevent it from crashing. BUG=391977 Review URL: https://codereview.chromium.org/378733002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@281653 0039d316-1c4b-4281-b951-d872f2087c98
* Don't use a version script when linking libpdf.soraymes@chromium.org2014-07-033-24/+0
| | | | | | | | | | | | | It appears we used to use a version script when compiling libpdf.so. This was causing crashes such as the one in the associated bug. The reason given for using the version map was to hide vendor symbols, but since the PDF code is all open source now, this shouldn't be an issue. BUG=386436 Review URL: https://codereview.chromium.org/351773005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@281157 0039d316-1c4b-4281-b951-d872f2087c98
* Converted dos line endings to unix for pdf/BUILD.gnraymes@google.com2014-07-021-108/+108
| | | | | | | | TBR=brettw@chromium.org Review URL: https://codereview.chromium.org/367893002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@281116 0039d316-1c4b-4281-b951-d872f2087c98
* PDF: Cleanup the declarations for a bunch of const char* variables.thestig@chromium.org2014-06-272-79/+79
| | | | | | Review URL: https://codereview.chromium.org/354513007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@280228 0039d316-1c4b-4281-b951-d872f2087c98
* Improve scrolling performance in OOP PDFraymes@chromium.org2014-06-262-37/+59
| | | | | | | | | | | | | | | | | | | | | | | This increases the performance of scrolling in OOP PDF by not sending viewport changes via postMessage every time a scroll event occurs on the page. Instead, scroll events are sent along with pepper DidChangeView messages, which is a much more responsive way of updating the scroll position. Unfortunately this introduces some issues coordinating zoom and scroll events on the page. When a zoom happens in the container page, a scroll message might be sent to the plugin via DidChangeView. Then we send a zoom change message via postMessage. The result is that the zooming and scrolling happen asynchronously and result in a flickering effect. To avoid this, we first notify the plugin that we are about to zoom which causes it to stop reacting to scroll messages. After we have finished zooming we notify the plugin again so that it can continue reacting to scroll messages. BUG=386920 Review URL: https://codereview.chromium.org/347763007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@279910 0039d316-1c4b-4281-b951-d872f2087c98
* Windows Printing: Auto-rotate pages 90 degrees counter-clockwise.thestig@chromium.org2014-06-241-1/+1
| | | | | | | | | | | It was reported Adobe Reader rotates this way, and so does Mac's Preview.App. BUG=369206 TEST=Manual, see bug. Review URL: https://codereview.chromium.org/350803002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@279455 0039d316-1c4b-4281-b951-d872f2087c98
* Re-enable PDFExtensionTest.BasicPluginraymes@chromium.org2014-06-191-1/+1
| | | | | | | | | | | | | This test was disabled because it was failing. A few changes have been made: -The page zoom cannot be assumed to be 100% on load as it will depend on the screen size being tested on. So testPageSize now doesn't make that assumption. -testAccessibilityWithPage was flaking because accessibility information was not always returned for the two text boxes. I spent a bit of time investigating, but couldn't work it out so I've left it partially disabled for now and filed crbug.com/378091. -The files have all been moved to a more appropriate location (in particular the test was moved out of the data directory). BUG=303491 Review URL: https://codereview.chromium.org/290803007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@278340 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 278043 "Re-enable PDFExtensionTest.BasicPlugin"brettw@chromium.org2014-06-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This test fails consistently on Linux Tests (dbg) (1) [ RUN ] PDFExtensionTest.BasicPlugin ... [1023:1023:0618/142028:INFO:CONSOLE(0)] "[SUCCESS] testPageSize", source: chrome-extension://mhjfbmdgcfjbbpaeojofohoefgiehjai/index.html?http://127.0.0.1:42118/pdf/test.pdf (0) [17:17:0618/142028:WARNING:resource_message_handler.cc(49)] 'Post' message handler failed to complete successfully. [17:17:0618/142028:ERROR:pepper_uma_host.cc(106)] Host or histogram name is not allowed to use the UMA API. [17:17:0618/142028:WARNING:resource_message_handler.cc(49)] 'Post' message handler failed to complete successfully. memory allocation bug: object at 0x7f5a852272c0 has never been allocated BrowserTestBase signal handler received SIGTERM. Backtrace: #0 0x7f9e4351c8b5 base::debug::StackTrace::StackTrace() #1 0x00000462f8f2 content::(anonymous namespace)::DumpStackTraceSignalHandler() #2 0x7f9e2fb2f4a0 \u003Cunknown> #3 0x7f9e2fbe1a43 __poll #4 0x7f9e30917ff6 \u003Cunknown> #5 0x7f9e30918124 g_main_context_iteration #6 0x7f9e434e49e5 base::MessagePumpGlib::Run() <truncated, full output is in gzipped JSON output at end of step> #31 0x7f9e34f05dc7 content::RunNamedProcessTypeMain() #32 0x7f9e34f074df content::ContentMainRunnerImpl::Run() #33 0x7f9e34f0528b content::ContentMain() ... > Re-enable PDFExtensionTest.BasicPlugin > > This test was disabled because it was failing. A few changes have been made: > -The page zoom cannot be assumed to be 100% on load as it will depend on the screen size being tested on. So testPageSize now doesn't make that assumption. > -testAccessibilityWithPage was flaking because accessibility information was not always returned for the two text boxes. I spent a bit of time investigating, but couldn't work it out so I've left it partially disabled for now and filed crbug.com/378091. > -The files have all been moved to a more appropriate location (in particular the test was moved out of the data directory). > > BUG=303491 > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=273819 > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=274186 > > Review URL: https://codereview.chromium.org/290803007 TBR=raymes@chromium.org Review URL: https://codereview.chromium.org/346693002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@278191 0039d316-1c4b-4281-b951-d872f2087c98
* Re-enable PDFExtensionTest.BasicPluginraymes@chromium.org2014-06-181-1/+1
| | | | | | | | | | | | | | | | | This test was disabled because it was failing. A few changes have been made: -The page zoom cannot be assumed to be 100% on load as it will depend on the screen size being tested on. So testPageSize now doesn't make that assumption. -testAccessibilityWithPage was flaking because accessibility information was not always returned for the two text boxes. I spent a bit of time investigating, but couldn't work it out so I've left it partially disabled for now and filed crbug.com/378091. -The files have all been moved to a more appropriate location (in particular the test was moved out of the data directory). BUG=303491 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=273819 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=274186 Review URL: https://codereview.chromium.org/290803007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@278043 0039d316-1c4b-4281-b951-d872f2087c98
* Fix min threshhold calculation for resizing the PDF graphics contextraymes@chromium.org2014-06-161-5/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | This fixes the calculation for the threshhold we use to calculate whether the graphics context needs to be resized. There isn't a correctness issue here, as the context will always be large enough but it results in resizing more than necessary. This example demonstrates the issue: -If the plugin size was 100 x 100, we would set the context size to 100+kBufferSize x 100+kBufferSize. -If the plugin was then resized to 90x90 we would check to see if the plugin size is smaller than (100+kBufferSize)-kBufferSize x (100+kBufferSize)-kBufferSize which is equal to 100 x 100. -But we really intend to check whether it is smaller than 100-kBufferSize x 100-kBufferSize Thus we should check whether the plugin is smaller than the (current context size) - 2*kBufferSize which is kBufferSize less than the plugin size when the context size was last computed. BUG=303491 Review URL: https://codereview.chromium.org/337443002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@277387 0039d316-1c4b-4281-b951-d872f2087c98
* Merge DidStartLoading/DidStopLoading imbalance patch to OOP PDFraymes@chromium.org2014-06-132-14/+28
| | | | | | | | | | | This merges this CL https://chromereviews.googleplex.com/32997013/ to OOP PDF and also corrects some minor differences that had arisen in document loading. BUG=303491 Review URL: https://codereview.chromium.org/333553003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276954 0039d316-1c4b-4281-b951-d872f2087c98
* Add a target to produce a SyzyASan instrumented version of pdf.dllsebmarchand@chromium.org2014-06-121-0/+36
| | | | | | | | | | This will be used on Clusterfuzz, and we might ship this on the Canary sometimes if the performances are reasonable. BUG= Review URL: https://codereview.chromium.org/321303002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276746 0039d316-1c4b-4281-b951-d872f2087c98
* Linux: Take into account the weight/italic parameters when mapping fonts on ↵thestig@chromium.org2014-06-101-0/+16
| | | | | | | | | | Linux. BUG=pdfium:7 Review URL: https://codereview.chromium.org/326823002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@276161 0039d316-1c4b-4281-b951-d872f2087c98
* Print Preview: Enable PrintPreviewTest on Linux ASAN.thestig@chromium.org2014-06-061-1/+4
| | | | | | | | | | Fix an easily reproducible crash that happens locally in the PDF plugin. BUG=375126 Review URL: https://codereview.chromium.org/298803010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275534 0039d316-1c4b-4281-b951-d872f2087c98
* Fix some links in PDFs not working.jam@chromium.org2014-06-061-2/+2
| | | | | | | | | | | We were adding an extra null into the string because FPDFLink_GetURL only gives the length without the null terminator. BUG=pdfium:6 R=thestig@chromium.org Review URL: https://codereview.chromium.org/316233002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275439 0039d316-1c4b-4281-b951-d872f2087c98
* Roll pdfium, add GN build for pdf and pdfium.brettw@chromium.org2014-06-052-1/+109
| | | | | | | | | | | | | | | | | | | | | | | Pdfium changes: d68f9a3 Add GN build file for pdfium, rename GYP target. f0a5576 fix two uninitialized reads https://code.google.com/p/pdfium/issues/detail?id=9 https://code.google.com/p/pdfium/issues/detail?id=10 bb2b1e7 Use unsigned type for iteration to avoid int overflow. 62a7fd6 Wrong variable assignment in Pdfium. In the GN build this separates out the no-exceptions flag since pdfium must be compiled with exceptions enabled. Updates pdfium naming in GYP from fpdfsdk. Removes src/pdf from .gitignore now that it is checked in. BUG= R=jam@chromium.org Review URL: https://codereview.chromium.org/315313002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275269 0039d316-1c4b-4281-b951-d872f2087c98
* Do not exclude pdf from DEPS check.tfarina@chromium.org2014-06-051-0/+4
| | | | | | | | | | | | | | Otherwise the DEPS file under pdf/ directory has no effect. As a result of enabling it, some entries had to be added. BUG=None TEST=./tools/checkdeps/checkdeps.py - SUCCESS R=thestig@chromium.org Review URL: https://codereview.chromium.org/318763005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275148 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 273547 "Reset scoped_ptr to make plugin crash before ente..."vitalybuka@chromium.org2014-06-041-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | > Reset scoped_ptr to make plugin crash before entering engine_->HandleDocumentLoad, if called for deleted "Instance". > Suspecting method call for deleted instance. > > Example to explain why reset() makes difference: > > scoped_ptr<int>* pt = NULL; > { > scoped_ptr<int> t(new int); > pt = &t; > } > DCHECK(!(*pt)); // Fail > { > scoped_ptr<int> t(new int); > pt = &t; > t.reset(); > } > DCHECK(!(*pt)); // OK > > BUG=372095,372548 > > Review URL: https://codereview.chromium.org/300403002 TBR=vitalybuka@chromium.org Review URL: https://codereview.chromium.org/318743003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@274854 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 274186 "Re-enable PDFExtensionTest.BasicPlugin"battre@chromium.org2014-06-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | Reverting - still flaky. See http://crbug.com/303491#c104 for details. > Re-enable PDFExtensionTest.BasicPlugin > > This test was disabled because it was failing. A few changes have been made: > -The page zoom cannot be assumed to be 100% on load as it will depend on the screen size being tested on. So testPageSize now doesn't make that assumption. > -testAccessibilityWithPage was flaking because accessibility information was not always returned for the two text boxes. I spent a bit of time investigating, but couldn't work it out so I've left it partially disabled for now and filed crbug.com/378091. > -The files have all been moved to a more appropriate location (in particular the test was moved out of the data directory). > > BUG=303491 > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=273819 > > Review URL: https://codereview.chromium.org/290803007 TBR=raymes@chromium.org Review URL: https://codereview.chromium.org/302163007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@274219 0039d316-1c4b-4281-b951-d872f2087c98
* Re-enable PDFExtensionTest.BasicPluginraymes@chromium.org2014-06-021-1/+1
| | | | | | | | | | | | | | | This test was disabled because it was failing. A few changes have been made: -The page zoom cannot be assumed to be 100% on load as it will depend on the screen size being tested on. So testPageSize now doesn't make that assumption. -testAccessibilityWithPage was flaking because accessibility information was not always returned for the two text boxes. I spent a bit of time investigating, but couldn't work it out so I've left it partially disabled for now and filed crbug.com/378091. -The files have all been moved to a more appropriate location (in particular the test was moved out of the data directory). BUG=303491 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=273819 Review URL: https://codereview.chromium.org/290803007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@274186 0039d316-1c4b-4281-b951-d872f2087c98
* Fix loading PDFs with no HTTP response headers in OOP PDFraymes@chromium.org2014-05-312-2/+7
| | | | | | | | | | | | | | | | | | | Currently if no response headers are passed into the plugin in OOP PDF then the headers fetched URLLoader that loaded the stream URL will be used, but the MIME type for the blob URL is always plain text, which causes the document loader to refuse to load the document. Currently, if no headers are passed to the in process plugin, we always try to load the document, so this just mimics that behavior in the OOP plugin. When the in-process plugin is removed we can change the document loader and remove the hack. This also removes blob: URLs from the MIME type check in document loader because they are no longer ever passed in. BUG=303491 Review URL: https://codereview.chromium.org/301223004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@274081 0039d316-1c4b-4281-b951-d872f2087c98
* Removed unnecessary map.vitalybuka@chromium.org2014-05-292-18/+6
| | | | | | Review URL: https://codereview.chromium.org/301033003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@273580 0039d316-1c4b-4281-b951-d872f2087c98
* Reset scoped_ptr to make plugin crash before entering ↵vitalybuka@chromium.org2014-05-291-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | engine_->HandleDocumentLoad, if called for deleted "Instance". Suspecting method call for deleted instance. Example to explain why reset() makes difference: scoped_ptr<int>* pt = NULL; { scoped_ptr<int> t(new int); pt = &t; } DCHECK(!(*pt)); // Fail { scoped_ptr<int> t(new int); pt = &t; t.reset(); } DCHECK(!(*pt)); // OK BUG=372095,372548 Review URL: https://codereview.chromium.org/300403002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@273547 0039d316-1c4b-4281-b951-d872f2087c98
* Roll in latest pdfium.jam@chromium.org2014-05-262-324/+0
| | | | | | | | R=scottmg@chromium.org Review URL: https://codereview.chromium.org/299353002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@272860 0039d316-1c4b-4281-b951-d872f2087c98
* Fix more cases of unreachable code on Windows, mostly added recently.pkasting@chromium.org2014-05-221-2/+0
| | | | | | | | | BUG=346399 TEST=none Review URL: https://codereview.chromium.org/296053005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@272069 0039d316-1c4b-4281-b951-d872f2087c98
* Remove most references to VarPrivate/InstancePrivate from OOP PDFraymes@chromium.org2014-05-212-26/+55
| | | | | | | | | | | | | | | | | This removes most references to VarPrivate and InstancePrivate from OOP PDF. These APIs are deprecated and we'd like to remove them. In most cases where they are currently used, we can simply switch to using a PostMessage to communicate with the extension. In the case of modal dialogs, these need to run synchronously from the perspective of the PDF engine and so PostMessage isn't sufficient. Right now these calls still use InstancePrivate but we should switch to using a specific private API eventually. BUG=303491 Review URL: https://codereview.chromium.org/286933011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@271998 0039d316-1c4b-4281-b951-d872f2087c98
* Add the pdf plugin's source in src\pdf.jam@chromium.org2014-05-2056-0/+15757
I've updated gypi files to not use internal_pdf variable anymore, which was brought in from pdf repo's supplemental.gypi. R=thestig@chromium.org TBR=darin Review URL: https://codereview.chromium.org/294793003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@271531 0039d316-1c4b-4281-b951-d872f2087c98