Add SharedWorkerServiceImpl::CheckWorkerDependency().

This method checks the worker dependency of renderer processes and calls IncrementWorkerRefCount and DecrementWorkerRefCount of RenderProcessHostImpl on UI thread if necessary.

The old cl (http://crrev.com/256305) was reverted (http://crrev.com/256323) because of the memory leak in MockMessagePortMessageFilter::Send and MockSharedWorkerMessageFilter::Send.
This cl has fixed it.

The difference between this cl and the old cl is the null value handling of message_queue_ in MockMessagePortMessageFilter::Send and MockSharedWorkerMessageFilter::Send. 


BUG=327256,351492
TBR=jochen@chromium.org

Review URL: https://codereview.chromium.org/196483003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@256749 0039d316-1c4b-4281-b951-d872f2087c98
7 files changed