[Webkit-unassigned] [Bug 51818] GeolocationPositionCache should not use ScriptExecutionContext::Task

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jan 3 06:23:41 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=51818


Steve Block <steveblock at google.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Factor out a generic task   |GeolocationPositionCache
                   |class from                  |should not use
                   |ScriptExecutionContext::Tas |ScriptExecutionContext::Tas
                   |k                           |k
                 CC|                            |steveblock at google.com




--- Comment #1 from Steve Block <steveblock at google.com>  2011-01-03 06:23:42 PST ---
The convenience of using ScriptExecutionTask::Task is that CrossThreadTask provides generic machinery to create a ScriptExecutionContext::Task which simply invokes a supplied method. This machinery is heavily templated and modifying it to support tasks both with and without a ScriptExecutionContext would be messy.

The classes that currently use tasks with MessageQueue and which do not use a ScriptExecutionContext are as follows ...
FileThread
LocalStorageThread
DatabaseThread

Each of these uses a custom task class which could not be replaced by a simple generic task similar to CrossThreadTask. So the only user of such a generic task would be GeolocationPositionCache. I don't think it's worth adding the complexity of this generic machinery for a single user, though this can be revisited in the future.

So I think the correct approach is to add a custom task class for GeolocationPositionCache. We can also add a base class to provide a performTask() method for all of the existing task classes.

Patch coming soon.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list