Bug 233940

Summary: Allow `Pasteboard::readBuffer` to read from the pasteboard as a whole instead of a specific item
Product: WebKit Reporter: Devin Rousso <hi>
Component: New BugsAssignee: Devin Rousso <hi>
Status: RESOLVED FIXED    
Severity: Normal CC: akeerthi, hi, megan_gardner, thorton, webkit-bug-importer, wenson_hsieh
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 191379    
Attachments:
Description Flags
Patch
ews-feeder: commit-queue-
Patch
ews-feeder: commit-queue-
Patch
wenson_hsieh: review+, ews-feeder: commit-queue-
Patch none

Description Devin Rousso 2021-12-07 10:57:47 PST
.
Comment 1 Devin Rousso 2021-12-07 12:15:41 PST
Created attachment 446219 [details]
Patch
Comment 2 Devin Rousso 2021-12-07 12:31:44 PST
Created attachment 446220 [details]
Patch
Comment 3 Devin Rousso 2021-12-07 14:03:43 PST
Created attachment 446235 [details]
Patch
Comment 4 Devin Rousso 2021-12-07 15:26:02 PST
This is not actually needed for bug 191379.
Comment 5 Devin Rousso 2021-12-07 21:15:02 PST
actually, this might be necessary
Comment 6 Wenson Hsieh 2021-12-08 22:16:03 PST
Comment on attachment 446235 [details]
Patch

(In reply to Devin Rousso from comment #5)
> actually, this might be necessary

It's not really clear from the ChangeLog (or the comments) why this is the case, but it does seem like a fairly straightforward refactoring. I would've thought that simply reading the item at index 0 (or none if there are no items) would achieve the same thing.
Comment 7 Devin Rousso 2021-12-09 16:17:14 PST
(In reply to Wenson Hsieh from comment #6)
> (In reply to Devin Rousso from comment #5)
> > actually, this might be necessary
> 
> It's not really clear from the ChangeLog (or the comments) why this is the case, but it does seem like a fairly straightforward refactoring. I would've thought that simply reading the item at index 0 (or none if there are no items) would achieve the same thing.

I agree that it's not super clear, but as you said since it's pretty straightforward I didn't see a huge benefit in digging into it, both because it would allow us to match WK1 and this approach does work.
Comment 8 Devin Rousso 2021-12-09 16:17:45 PST
Created attachment 446629 [details]
Patch
Comment 9 EWS 2021-12-10 13:16:59 PST
Committed r286870 (245101@main): <https://commits.webkit.org/245101@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 446629 [details].
Comment 10 Radar WebKit Bug Importer 2021-12-10 13:18:18 PST
<rdar://problem/86336945>