Changeset 261423 in webkit


Ignore:
Timestamp:
May 8, 2020 4:11:38 PM (4 years ago)
Author:
Chris Dumez
Message:

Regression(r210945): No attachment when sharing to mail
https://bugs.webkit.org/show_bug.cgi?id=211651
<rdar://problem/63040170>

Reviewed by Tim Horton.

When failing to determine foreground state, the code before r210945 was assuming
'foreground', while the code in r210945 assume 'background'. This causes things
to not render properly when we fail to determine the foreground state.

This patch merely restores pre-r210945 behavior. I will investigate why we are
unable to determinate the host application PID for the MailCompositionService.

  • UIProcess/ApplicationStateTracker.mm:

(WebKit::isApplicationForeground):

Location:
trunk/Source/WebKit
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/ChangeLog

    r261412 r261423  
     12020-05-08  Chris Dumez  <cdumez@apple.com>
     2
     3        Regression(r210945): No attachment when sharing to mail
     4        https://bugs.webkit.org/show_bug.cgi?id=211651
     5        <rdar://problem/63040170>
     6
     7        Reviewed by Tim Horton.
     8
     9        When failing to determine foreground state, the code before r210945 was assuming
     10        'foreground', while the code in r210945 assume 'background'. This causes things
     11        to not render properly when we fail to determine the foreground state.
     12
     13        This patch merely restores pre-r210945 behavior. I will investigate why we are
     14        unable to determinate the host application PID for the MailCompositionService.
     15
     16        * UIProcess/ApplicationStateTracker.mm:
     17        (WebKit::isApplicationForeground):
     18
    1192020-05-08  Nikos Mouchtaris  <nmouchtaris@apple.com>
    220
  • trunk/Source/WebKit/UIProcess/ApplicationStateTracker.mm

    r261088 r261423  
    172172    if (!processIdentifier) {
    173173        RELEASE_LOG_ERROR(ProcessSuspension, "isApplicationForeground: Failed to construct RBSProcessIdentifier from PID %d", pid);
    174         return false;
     174        // We assume foreground when unable to determine state to maintain pre-existing behavior and to avoid
     175        // not rendering anything when we fail.
     176        return true;
    175177    }
    176178
     
    179181    if (!processHandle) {
    180182        RELEASE_LOG_ERROR(ProcessSuspension, "isApplicationForeground: Failed to get RBSProcessHandle for process with PID %d, error: %{public}@", pid, error);
    181         return false;
     183        // We assume foreground when unable to determine state to maintain pre-existing behavior and to avoid
     184        // not rendering anything when we fail.
     185        return true;
    182186    }
    183187
Note: See TracChangeset for help on using the changeset viewer.