Changeset 262649 in webkit


Ignore:
Timestamp:
Jun 5, 2020 1:15:51 PM (4 years ago)
Author:
achristensen@apple.com
Message:

Fix PDF opening after r262592
https://bugs.webkit.org/show_bug.cgi?id=212795

  • UIProcess/mac/WebPageProxyMac.mm:

(WebKit::WebPageProxy::savePDFToTemporaryFolderAndOpenWithNativeApplication):
(WebKit::WebPageProxy::openPDFFromTemporaryFolderWithNativeApplication):
As Darin mentioned and I was about to discover, my last-minute switching things around got the boolean condition backwards.
We want to do nothing if we're not allowed to open the PDF, and we want to open the PDF if we are allowed to.s

Location:
trunk/Source/WebKit
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/ChangeLog

    r262648 r262649  
     12020-06-05  Alex Christensen  <achristensen@webkit.org>
     2
     3        Fix PDF opening after r262592
     4        https://bugs.webkit.org/show_bug.cgi?id=212795
     5
     6        * UIProcess/mac/WebPageProxyMac.mm:
     7        (WebKit::WebPageProxy::savePDFToTemporaryFolderAndOpenWithNativeApplication):
     8        (WebKit::WebPageProxy::openPDFFromTemporaryFolderWithNativeApplication):
     9        As Darin mentioned and I was about to discover, my last-minute switching things around got the boolean condition backwards.
     10        We want to do nothing if we're not allowed to open the PDF, and we want to open the PDF if we are allowed to.s
     11
    1122020-06-05  David Kilzer  <ddkilzer@apple.com>
    213
  • trunk/Source/WebKit/UIProcess/mac/WebPageProxyMac.mm

    r262592 r262649  
    513513
    514514    m_uiClient->confirmPDFOpening(*this, WTFMove(frameInfo), [nsPath = WTFMove(nsPath)] (bool allowed) {
    515         if (allowed)
     515        if (!allowed)
    516516            return;
    517517        [[NSWorkspace sharedWorkspace] openURL:[NSURL fileURLWithPath:nsPath.get() isDirectory:NO]];
     
    529529
    530530    m_uiClient->confirmPDFOpening(*this, WTFMove(frameInfo), [pdfFilename = WTFMove(pdfFilename)] (bool allowed) {
    531         if (allowed)
     531        if (!allowed)
    532532            return;
    533533        [[NSWorkspace sharedWorkspace] openURL:[NSURL fileURLWithPath:pdfFilename isDirectory:NO]];
Note: See TracChangeset for help on using the changeset viewer.