Why Google Chrome and XCode shares keyword on their search box?

272 Views Asked by At

When I search in Chrome by Command+F, the same keyword appears on XCode's search box.
And also when I search in XCode by Command+F, the same keyword appears on Chrome's search box.

Why does that happen?
Is it safe?
Does XCode record my search history on Chrome?

1

There are 1 best solutions below

1
On BEST ANSWER

This is the "Find pasteboard" in action. Mac OS X has several pasteboards (what are called clipboards on other OSes). The general pasteboard is for cut/copy/paste operations, but there are other pasteboards for fonts and rulers, etc. One is the Find pasteboard. Apps that support a Find operation can put the searched-for text on the find pasteboard which makes it available to other apps. Effectively, there's one, global "text to be searched for" across all applications (assuming they support the Find pasteboard).

I assume Chrome's Command-F is for searching within a web page, not performing a web search (like a Google search), right?

As far as safety, well, it's intended behavior. I suppose it's a privacy leak of sorts, although you have to trust apps that run on your system, because there are very few protections between them.

Xcode is presumably not recording anything of this sort.