summaryrefslogtreecommitdiffstats
path: root/webkit/tools
diff options
context:
space:
mode:
authormaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-03-05 12:46:38 +0000
committermaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-03-05 12:46:38 +0000
commitf0a51fb571f46531025fa09240bbc3e1af925e84 (patch)
tree558b4f0e737fda4b9ab60f252c9c23b8a4ca523e /webkit/tools
parent6390be368205705f49ead3cec40396519f13b889 (diff)
downloadchromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.zip
chromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.tar.gz
chromium_src-f0a51fb571f46531025fa09240bbc3e1af925e84.tar.bz2
Fixes CRLF and trailing white spaces.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10982 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/tools')
-rw-r--r--webkit/tools/layout_tests/layout_package/compare_failures.py22
-rw-r--r--webkit/tools/layout_tests/layout_package/compare_failures_unittest.py22
-rw-r--r--webkit/tools/layout_tests/layout_package/path_utils.py2
-rw-r--r--webkit/tools/layout_tests/layout_package/platform_utils_mac.py10
-rw-r--r--webkit/tools/layout_tests/layout_package/platform_utils_win.py8
-rw-r--r--webkit/tools/layout_tests/layout_package/test_expectations.py60
-rw-r--r--webkit/tools/layout_tests/layout_package/test_types_unittest.py2
-rwxr-xr-xwebkit/tools/layout_tests/run_webkit_tests.py10
-rw-r--r--webkit/tools/layout_tests/test_types/simplified_text_diff.py10
-rw-r--r--webkit/tools/layout_tests/test_types/test_type_base.py18
-rwxr-xr-xwebkit/tools/merge/diff3-wrapper.py20
-rw-r--r--webkit/tools/npapi_layout_test_plugin/PluginObject.cpp28
-rw-r--r--webkit/tools/npapi_layout_test_plugin/PluginObject.h2
-rw-r--r--webkit/tools/npapi_layout_test_plugin/TestObject.cpp22
-rw-r--r--webkit/tools/npapi_layout_test_plugin/TestObject.h2
-rw-r--r--webkit/tools/npapi_layout_test_plugin/main.cpp64
-rw-r--r--webkit/tools/npapi_layout_test_plugin/resource.h2
-rw-r--r--webkit/tools/test_shell/event_sending_controller.h2
-rw-r--r--webkit/tools/test_shell/foreground_helper.h10
-rw-r--r--webkit/tools/test_shell/image_decoder_unittest.cc4
-rw-r--r--webkit/tools/test_shell/mac/DumpRenderTreePasteboard.h6
-rw-r--r--webkit/tools/test_shell/mac/DumpRenderTreePasteboard.m6
-rw-r--r--webkit/tools/test_shell/mac/test_shell_webview.mm14
-rwxr-xr-xwebkit/tools/test_shell/mac/test_webview_delegate.mm8
-rw-r--r--webkit/tools/test_shell/mac/webwidget_host.mm10
-rw-r--r--webkit/tools/test_shell/plugin_tests.cc4
-rw-r--r--webkit/tools/test_shell/resource.h4
-rw-r--r--webkit/tools/test_shell/run_all_tests.cc2
-rw-r--r--webkit/tools/test_shell/simple_resource_loader_bridge.cc2
-rw-r--r--webkit/tools/test_shell/test_navigation_controller.cc2
-rw-r--r--webkit/tools/test_shell/test_navigation_controller.h2
-rw-r--r--webkit/tools/test_shell/test_shell_gtk.cc2
-rw-r--r--webkit/tools/test_shell/test_shell_mac.mm74
-rw-r--r--webkit/tools/test_shell/test_shell_main.cc10
-rw-r--r--webkit/tools/test_shell/test_shell_platform_delegate.h2
-rw-r--r--webkit/tools/test_shell/test_shell_platform_delegate_gtk.cc2
-rw-r--r--webkit/tools/test_shell/test_shell_platform_delegate_mac.mm36
-rw-r--r--webkit/tools/test_shell/test_shell_test.cc4
-rw-r--r--webkit/tools/test_shell/test_shell_test.h4
-rw-r--r--webkit/tools/test_shell/test_shell_webkit_init.h2
-rw-r--r--webkit/tools/test_shell/test_shell_win.cc2
-rwxr-xr-xwebkit/tools/test_shell/test_webview_delegate_gtk.cc4
-rwxr-xr-xwebkit/tools/test_shell/test_webview_delegate_win.cc2
-rw-r--r--webkit/tools/test_shell/webwidget_host_win.cc2
-rw-r--r--webkit/tools/webcore_unit_tests/BMPImageDecoder_unittest.cpp6
-rw-r--r--webkit/tools/webcore_unit_tests/GKURL_unittest.cpp10
-rw-r--r--webkit/tools/webcore_unit_tests/ICOImageDecoder_unittest.cpp6
-rw-r--r--webkit/tools/webcore_unit_tests/TransparencyWin_unittest.cpp14
-rw-r--r--webkit/tools/webcore_unit_tests/UniscribeHelper_unittest.cpp2
-rw-r--r--webkit/tools/webcore_unit_tests/XBMImageDecoder_unittest.cpp6
50 files changed, 285 insertions, 285 deletions
diff --git a/webkit/tools/layout_tests/layout_package/compare_failures.py b/webkit/tools/layout_tests/layout_package/compare_failures.py
index 5850fda..70745d7 100644
--- a/webkit/tools/layout_tests/layout_package/compare_failures.py
+++ b/webkit/tools/layout_tests/layout_package/compare_failures.py
@@ -16,7 +16,7 @@ import test_expectations
def PrintFilesFromSet(filenames, header_text, output, opt_expectations=None):
"""A helper method to print a list of files to output.
-
+
Args:
filenames: a list of absolute filenames
header_text: a string to display before the list of filenames
@@ -25,7 +25,7 @@ def PrintFilesFromSet(filenames, header_text, output, opt_expectations=None):
"""
if not len(filenames):
return
-
+
filenames = list(filenames)
filenames.sort()
output.write("\n")
@@ -36,7 +36,7 @@ def PrintFilesFromSet(filenames, header_text, output, opt_expectations=None):
output_string += "\n"
for filename in filenames:
output.write(output_string % path_utils.RelativeTestFilename(filename))
-
+
class CompareFailures:
@@ -70,7 +70,7 @@ class CompareFailures:
# Print unexpected passes by category.
passes = self._regressed_passes
- PrintFilesFromSet(passes & self._expectations.GetFixableFailures(),
+ PrintFilesFromSet(passes & self._expectations.GetFixableFailures(),
"Expected to fail, but passed",
output)
PrintFilesFromSet(passes & self._expectations.GetFixableTimeouts(),
@@ -79,18 +79,18 @@ class CompareFailures:
PrintFilesFromSet(passes & self._expectations.GetFixableCrashes(),
"Expected to crash, but passed",
output)
-
- PrintFilesFromSet(passes & self._expectations.GetIgnoredFailures(),
+
+ PrintFilesFromSet(passes & self._expectations.GetIgnoredFailures(),
"Expected to fail (ignored), but passed",
output)
PrintFilesFromSet(passes & self._expectations.GetIgnoredTimeouts(),
"Expected to timeout (ignored), but passed",
output)
# Crashes should never be deferred.
- PrintFilesFromSet(passes & self._expectations.GetFixableDeferredFailures(),
+ PrintFilesFromSet(passes & self._expectations.GetFixableDeferredFailures(),
"Expected to fail (deferred), but passed",
- output)
- PrintFilesFromSet(passes & self._expectations.GetFixableDeferredTimeouts(),
+ output)
+ PrintFilesFromSet(passes & self._expectations.GetFixableDeferredTimeouts(),
"Expected to timeout (deferred), but passed",
output)
# Print real regressions.
@@ -113,7 +113,7 @@ class CompareFailures:
def _CalculateRegressions(self):
"""Calculate regressions from this run through the layout tests."""
worklist = self._test_files.copy()
-
+
passes = set()
crashes = set()
hangs = set()
@@ -146,7 +146,7 @@ class CompareFailures:
# Check that all passing tests are expected to pass.
expectations = self._expectations.GetExpectations(test)
if not test_expectations.PASS in expectations: passes.add(test)
-
+
self._regressed_passes = passes
self._regressed_crashes = crashes
self._regressed_hangs = hangs
diff --git a/webkit/tools/layout_tests/layout_package/compare_failures_unittest.py b/webkit/tools/layout_tests/layout_package/compare_failures_unittest.py
index b5d286c..21022f4 100644
--- a/webkit/tools/layout_tests/layout_package/compare_failures_unittest.py
+++ b/webkit/tools/layout_tests/layout_package/compare_failures_unittest.py
@@ -28,7 +28,7 @@ class CompareFailuresUnittest(unittest.TestCase):
# copyfile doesn't copy file permissions so we can delete the files later
shutil.copyfile(os.path.join(testdatadir, filename),
os.path.join(self._tempdir, filename))
-
+
def tearDown(self):
"""Remove temp directory."""
shutil.rmtree(self._tempdir)
@@ -62,7 +62,7 @@ class CompareFailuresUnittest(unittest.TestCase):
def testPassingToFailure(self):
"""When there's a new failure, we don't add it to the baseline."""
failures = self.GetTestFailures()
-
+
# Test case where we don't update new baseline. We have a new failure,
# but it shouldn't be added to the expected-failures.txt file.
pass_file = os.path.join(path_utils.LayoutDataDir(), 'fast', 'pass1.html')
@@ -72,12 +72,12 @@ class CompareFailuresUnittest(unittest.TestCase):
# Same thing as before: pass -> crash
failures[pass_file] = [test_failures.FailureCrash()]
self.CheckNoChanges(failures)
-
+
def testFailureToCrash(self):
"""When there's a new crash, we don't add it to the baseline or remove it
from the failure list."""
failures = self.GetTestFailures()
-
+
# Test case where we don't update new baseline. A failure moving to a
# crash shouldn't be added to the expected-crashes.txt file.
failure_file = os.path.join(path_utils.LayoutDataDir(),
@@ -106,7 +106,7 @@ class CompareFailuresUnittest(unittest.TestCase):
def testCrashToPassing(self):
"""This is better than before, so we update the crashes file."""
failures = self.GetTestFailures()
-
+
crash_file = os.path.join(path_utils.LayoutDataDir(),
'fast', 'bar', 'betz', 'crash3.html')
del failures[crash_file]
@@ -121,7 +121,7 @@ class CompareFailuresUnittest(unittest.TestCase):
def testCrashToFailure(self):
"""This is better than before, so we should update both lists."""
failures = self.GetTestFailures()
-
+
crash_file = os.path.join(path_utils.LayoutDataDir(),
'fast', 'bar', 'betz', 'crash3.html')
failures[crash_file] = [test_failures.FailureTextMismatch(None)]
@@ -163,7 +163,7 @@ class CompareFailuresUnittest(unittest.TestCase):
self.CheckOutputWithExpectedFiles('expected-passing.txt',
'expected-failures-new-test.txt',
'expected-crashes.txt')
-
+
def testNewTestCrash(self):
"""After a merge, we need to update new crashing tests properly."""
files = self.GetTestFiles()
@@ -195,7 +195,7 @@ class CompareFailuresUnittest(unittest.TestCase):
cf = compare_failures.CompareFailures(files, failures, set(), set(),
self.GetTmpDir(), False)
self.failUnless(cf.HasNewFailures())
-
+
# Failing to passing
failures = self.GetTestFailures()
failure_file = os.path.join(path_utils.LayoutDataDir(),
@@ -204,7 +204,7 @@ class CompareFailuresUnittest(unittest.TestCase):
cf = compare_failures.CompareFailures(files, failures, set(), set(),
self.GetTmpDir(), False)
self.failUnless(not cf.HasNewFailures())
-
+
# A new test that fails, this doesn't count as a new failure.
new_test_file = os.path.join(path_utils.LayoutDataDir(), "new-test.html")
files.add(new_test_file)
@@ -261,7 +261,7 @@ class CompareFailuresUnittest(unittest.TestCase):
'fast\\bar\\fail2.html',
'fast\\bar\\betz\\fail3.html',
]
-
+
return set([os.path.join(layout_dir, f) for f in files])
def GetTestFailures(self):
@@ -275,7 +275,7 @@ class CompareFailuresUnittest(unittest.TestCase):
failures[filename] = [test_failures.FailureTextMismatch(None)]
return failures
-
+
if '__main__' == __name__:
unittest.main()
diff --git a/webkit/tools/layout_tests/layout_package/path_utils.py b/webkit/tools/layout_tests/layout_package/path_utils.py
index e2f0dcb..cdb6554 100644
--- a/webkit/tools/layout_tests/layout_package/path_utils.py
+++ b/webkit/tools/layout_tests/layout_package/path_utils.py
@@ -165,7 +165,7 @@ def TestShellBinaryPath(target):
"""Gets the full path to the test_shell binary for the target build
configuration. Raises PathNotFound if the file doesn't exist"""
platform_util = platform_utils.PlatformUtility('')
- full_path = os.path.join(WebKitRoot(), target,
+ full_path = os.path.join(WebKitRoot(), target,
platform_util.TestShellBinary())
if not os.path.exists(full_path):
# try output directory from either Xcode or chrome.sln
diff --git a/webkit/tools/layout_tests/layout_package/platform_utils_mac.py b/webkit/tools/layout_tests/layout_package/platform_utils_mac.py
index dbc6963..fd0e725 100644
--- a/webkit/tools/layout_tests/layout_package/platform_utils_mac.py
+++ b/webkit/tools/layout_tests/layout_package/platform_utils_mac.py
@@ -96,13 +96,13 @@ class PlatformUtility(object):
port += 443
use_ssl = True
return PlatformUtility._FilenameToUri(self,
- relative_path,
+ relative_path,
use_http=True,
use_ssl=use_ssl,
port=port)
# Run off file://
- return PlatformUtility._FilenameToUri(self, full_path, use_http=False,
+ return PlatformUtility._FilenameToUri(self, full_path, use_http=False,
use_ssl=False, port=0)
def LigHTTPdExecutablePath(self):
@@ -119,7 +119,7 @@ class PlatformUtility(object):
def ShutDownHTTPServer(self, server_process):
"""Shut down the lighttpd web server. Blocks until it's fully shut down.
-
+
Args:
server_process: The subprocess object representing the running server
"""
@@ -139,10 +139,10 @@ class PlatformUtility(object):
def TestShellBinary(self):
"""The name of the binary for TestShell."""
return 'TestShell'
-
+
def TestShellBinaryPath(self, target):
"""Return the platform-specific binary path for our TestShell.
-
+
Args:
target: Build target mode (debug or release)
"""
diff --git a/webkit/tools/layout_tests/layout_package/platform_utils_win.py b/webkit/tools/layout_tests/layout_package/platform_utils_win.py
index c6bd525..5695a28 100644
--- a/webkit/tools/layout_tests/layout_package/platform_utils_win.py
+++ b/webkit/tools/layout_tests/layout_package/platform_utils_win.py
@@ -100,9 +100,9 @@ class PlatformUtility(google.platform_utils_win.PlatformUtility):
"""Prepares the config file and output directory to start an httpd server.
Returns a list of strings containing the server's command line+args.
- Creates the test output directory and generates an httpd.conf (or
- httpd2.conf for Apache 2 if apache2 is True) file in it that contains
- the necessary <VirtualHost> directives for running all the http tests.
+ Creates the test output directory and generates an httpd.conf (or
+ httpd2.conf for Apache 2 if apache2 is True) file in it that contains
+ the necessary <VirtualHost> directives for running all the http tests.
WebKit http tests expect the DocumentRoot to be in LayoutTests/http/tests/,
but that prevents us from running http tests in chrome/ or pending/. So we
@@ -126,7 +126,7 @@ class PlatformUtility(google.platform_utils_win.PlatformUtility):
chrome_document_root = layout_dir
apache_config_dir = google.httpd_utils.ApacheConfigDir(self._base_dir)
mime_types_path = os.path.join(apache_config_dir, "mime.types")
-
+
conf_file_name = "httpd.conf"
if apache2:
conf_file_name = "httpd2.conf"
diff --git a/webkit/tools/layout_tests/layout_package/test_expectations.py b/webkit/tools/layout_tests/layout_package/test_expectations.py
index 28dade7..0d343ca 100644
--- a/webkit/tools/layout_tests/layout_package/test_expectations.py
+++ b/webkit/tools/layout_tests/layout_package/test_expectations.py
@@ -35,13 +35,13 @@ class TestExpectations:
def GetFixable(self):
return (self._fixable.GetTests() -
- self._fixable.GetNonSkippedDeferred() -
+ self._fixable.GetNonSkippedDeferred() -
self._fixable.GetSkippedDeferred())
def GetFixableSkipped(self):
return self._fixable.GetSkipped()
- def GetFixableSkippedDeferred(self):
+ def GetFixableSkippedDeferred(self):
return self._fixable.GetSkippedDeferred()
def GetFixableFailures(self):
@@ -58,15 +58,15 @@ class TestExpectations:
def GetFixableCrashes(self):
return self._fixable.GetTestsExpectedTo(CRASH)
- def GetFixableDeferred(self):
- return self._fixable.GetNonSkippedDeferred()
+ def GetFixableDeferred(self):
+ return self._fixable.GetNonSkippedDeferred()
- def GetFixableDeferredFailures(self):
- return (self._fixable.GetNonSkippedDeferred() &
- self._fixable.GetTestsExpectedTo(FAIL))
+ def GetFixableDeferredFailures(self):
+ return (self._fixable.GetNonSkippedDeferred() &
+ self._fixable.GetTestsExpectedTo(FAIL))
- def GetFixableDeferredTimeouts(self):
- return (self._fixable.GetNonSkippedDeferred() &
+ def GetFixableDeferredTimeouts(self):
+ return (self._fixable.GetNonSkippedDeferred() &
self._fixable.GetTestsExpectedTo(TIMEOUT))
def GetIgnored(self):
@@ -112,7 +112,7 @@ class TestExpectations:
"""Read the expectation files for the given filename and return a single
expectations file with the merged results.
"""
-
+
path = os.path.join(self._directory, filename)
return TestExpectationsFile(path, self._tests, self._platform,
self._is_debug_mode)
@@ -131,11 +131,11 @@ def StripComments(line):
"""Strips comments from a line and return None if the line is empty
or else the contents of line with leading and trailing spaces removed
and all other whitespace collapsed"""
-
+
commentIndex = line.find('//')
if commentIndex is -1:
commentIndex = len(line)
-
+
line = re.sub(r'\s+', ' ', line[:commentIndex].strip())
if line == '': return None
else: return line
@@ -146,7 +146,7 @@ class TestExpectationsFile:
in which case the expectations apply to all test cases in that
directory and any subdirectory. The format of the file is along the
lines of:
-
+
LayoutTests/fast/js/fixme.js = FAIL
LayoutTests/fast/js/flaky.js = FAIL PASS
LayoutTests/fast/js/crash.js = CRASH TIMEOUT FAIL PASS
@@ -173,22 +173,22 @@ class TestExpectationsFile:
'fail': FAIL,
'timeout': TIMEOUT,
'crash': CRASH }
-
+
PLATFORMS = [ 'mac', 'linux', 'win' ]
def __init__(self, path, full_test_list, platform, is_debug_mode):
"""
path: The path to the expectation file. An error is thrown if a test is
- listed more than once.
+ listed more than once.
full_test_list: The list of all tests to be run pending processing of the
expections for those tests.
platform: Which platform from self.PLATFORMS to filter tests for.
is_debug_mode: Whether we testing a test_shell built debug mode.
"""
-
+
self._full_test_list = full_test_list
self._skipped = set()
- self._skipped_deferred = set()
+ self._skipped_deferred = set()
self._non_skipped_deferred = set()
self._expectations = {}
self._test_list_paths = {}
@@ -203,10 +203,10 @@ class TestExpectationsFile:
def GetSkipped(self):
return self._skipped
- def GetNonSkippedDeferred(self):
- return self._non_skipped_deferred
-
- def GetSkippedDeferred(self):
+ def GetNonSkippedDeferred(self):
+ return self._non_skipped_deferred
+
+ def GetSkippedDeferred(self):
return self._skipped_deferred
def GetExpectations(self, test):
@@ -233,7 +233,7 @@ class TestExpectationsFile:
platforms are listed.
"""
has_any_platforms = False
-
+
for platform in self.PLATFORMS:
if platform in options:
has_any_platforms = True
@@ -300,7 +300,7 @@ class TestExpectationsFile:
else:
tests = self._ExpandTests(test_list_path)
- if is_skipped:
+ if is_skipped:
self._AddSkippedTests(tests, is_deferred)
else:
self._AddTests(tests, expectations, test_list_path, lineno,
@@ -308,7 +308,7 @@ class TestExpectationsFile:
if len(self._errors) is not 0:
print "\nFAILURES FOR PLATFORM: %s, IS_DEBUG_MODE: %s" \
- % (self._platform.upper(), self._is_debug_mode)
+ % (self._platform.upper(), self._is_debug_mode)
raise SyntaxError('\n'.join(map(str, self._errors)))
def _GetOptionsList(self, listString):
@@ -329,8 +329,8 @@ class TestExpectationsFile:
path = os.path.join(path_utils.LayoutDataDir(), test_list_path)
path = os.path.normpath(path)
if os.path.isdir(path): path = os.path.join(path, '')
- # This is kind of slow - O(n*m) - since this is called for all
- # entries in the test lists. It has not been a performance
+ # This is kind of slow - O(n*m) - since this is called for all
+ # entries in the test lists. It has not been a performance
# issue so far. Maybe we should re-measure the time spent reading
# in the test lists?
result = []
@@ -360,19 +360,19 @@ class TestExpectationsFile:
self._expectations[test] = expectations
self._test_list_paths[test] = os.path.normpath(test_list_path)
- if is_deferred:
+ if is_deferred:
self._non_skipped_deferred.add(test)
for expectation in expectations:
if expectation == CRASH and is_deferred:
self._AddError(lineno, 'Crashes cannot be deferred.', test)
self._tests[expectation].add(test)
-
+
def _AddSkippedTests(self, tests, is_deferred):
for test in tests:
- if is_deferred:
+ if is_deferred:
self._skipped_deferred.add(test)
self._skipped.add(test)
def _AddError(self, lineno, msg, path):
- self._errors.append('\nLine:%s %s\n%s' % (lineno, msg, path)) \ No newline at end of file
+ self._errors.append('\nLine:%s %s\n%s' % (lineno, msg, path))
diff --git a/webkit/tools/layout_tests/layout_package/test_types_unittest.py b/webkit/tools/layout_tests/layout_package/test_types_unittest.py
index 24e1e75..a7b9bb6 100644
--- a/webkit/tools/layout_tests/layout_package/test_types_unittest.py
+++ b/webkit/tools/layout_tests/layout_package/test_types_unittest.py
@@ -29,7 +29,7 @@ class SimplifiedDiffUnittest(unittest.TestCase):
prefix + "-expected.txt")
output = differ._SimplifyText(open(output_filename).read())
expected = differ._SimplifyText(open(expected_filename).read())
-
+
if output != expected:
lst = difflib.unified_diff(expected.splitlines(True),
output.splitlines(True),
diff --git a/webkit/tools/layout_tests/run_webkit_tests.py b/webkit/tools/layout_tests/run_webkit_tests.py
index 1494f64..a11f1c2 100755
--- a/webkit/tools/layout_tests/run_webkit_tests.py
+++ b/webkit/tools/layout_tests/run_webkit_tests.py
@@ -237,7 +237,7 @@ class TestRunner:
else:
logging.info('Run: %d tests' % len(self._test_files))
- logging.info('Deferred: %d tests' %
+ logging.info('Deferred: %d tests' %
len(self._expectations.GetFixableDeferred()))
logging.info('Expected passes: %d tests' %
len(self._test_files -
@@ -480,10 +480,10 @@ class TestRunner:
skipped,
output)
- self._PrintResultSummary("=> Tests to be fixed for a future release",
- self._expectations.GetFixableDeferred(),
- deferred_failures,
- deferred_counts,
+ self._PrintResultSummary("=> Tests to be fixed for a future release",
+ self._expectations.GetFixableDeferred(),
+ deferred_failures,
+ deferred_counts,
self._expectations.GetFixableSkippedDeferred(),
output)
diff --git a/webkit/tools/layout_tests/test_types/simplified_text_diff.py b/webkit/tools/layout_tests/test_types/simplified_text_diff.py
index 00af6c1..3767a43 100644
--- a/webkit/tools/layout_tests/test_types/simplified_text_diff.py
+++ b/webkit/tools/layout_tests/test_types/simplified_text_diff.py
@@ -21,12 +21,12 @@ class SimplifiedTextDiff(text_diff.TestTextDiff):
"""Removes position and size information from a render tree dump. This
also combines contiguous lines of text together so lines that wrap between
different words match. Returns the simplified text."""
-
+
# SVG render paths are a little complicated: we want to strip digits after
# a decimal point only for strings that begin with "RenderPath.*data".
def simplify_svg_path(match):
return match.group(1) + re.sub(r"([0-9]*)\.[0-9]{2}", "\\1", match.group(2))
-
+
# Regular expressions to remove or substitue text.
simplifications = (
# Ignore TypeError and ReferenceError, V8 has different error text.
@@ -67,13 +67,13 @@ class SimplifiedTextDiff(text_diff.TestTextDiff):
# Handle RTL "...Browse" text. The space gets inserted when text lines
# are merged together in the step above.
(re.compile(r"... Browse"), "Browse..."),
-
+
# Some SVG tests inexplicably emit -0.00 rather than 0.00 in the expected results
(re.compile(r"-0\.00"), '0.00'),
-
+
# Remove size information from SVG text
(re.compile(r"(chunk.*width )([0-9]+\.[0-9]{2})"), '\\1'),
-
+
# Remove decimals from SVG paths
(re.compile(r"(RenderPath.*data)(.*)"), simplify_svg_path),
)
diff --git a/webkit/tools/layout_tests/test_types/test_type_base.py b/webkit/tools/layout_tests/test_types/test_type_base.py
index 4d6fdb7..9fab50e 100644
--- a/webkit/tools/layout_tests/test_types/test_type_base.py
+++ b/webkit/tools/layout_tests/test_types/test_type_base.py
@@ -58,7 +58,7 @@ class TestTypeBase(object):
"""
self._root_output_dir = root_output_dir
self._platform = platform
-
+
def _MakeOutputDirectory(self, filename):
"""Creates the output directory (if needed) for a given test filename."""
output_filename = os.path.join(self._root_output_dir,
@@ -88,11 +88,11 @@ class TestTypeBase(object):
def OutputFilename(self, filename, modifier):
"""Returns a filename inside the output dir that contains modifier.
-
+
For example, if filename is c:/.../fast/dom/foo.html and modifier is
"-expected.txt", the return value is
c:/cygwin/tmp/layout-test-results/fast/dom/foo-expected.txt
-
+
Args:
filename: absolute filename to test file
modifier: a string to replace the extension of filename with
@@ -105,12 +105,12 @@ class TestTypeBase(object):
return os.path.splitext(output_filename)[0] + modifier
def RelativeOutputFilename(self, filename, modifier):
- """Returns a relative filename inside the output dir that contains
+ """Returns a relative filename inside the output dir that contains
modifier.
-
+
For example, if filename is fast\dom\foo.html and modifier is
"-expected.txt", the return value is fast\dom\foo-expected.txt
-
+
Args:
filename: relative filename to test file
modifier: a string to replace the extension of filename with
@@ -122,16 +122,16 @@ class TestTypeBase(object):
def CompareOutput(self, filename, proc, output, test_args, target):
"""Method that compares the output from the test with the expected value.
-
+
This is an abstract method to be implemented by all sub classes.
-
+
Args:
filename: absolute filename to test file
proc: a reference to the test_shell process
output: a string containing the output of the test
test_args: a TestArguments object holding optional additional arguments
target: Debug or Release
-
+
Return:
a list of TestFailure objects, empty if the test passes
"""
diff --git a/webkit/tools/merge/diff3-wrapper.py b/webkit/tools/merge/diff3-wrapper.py
index 4e31ebd..2d0f0e2 100755
--- a/webkit/tools/merge/diff3-wrapper.py
+++ b/webkit/tools/merge/diff3-wrapper.py
@@ -29,7 +29,7 @@ def EnsureWindowsPath(path):
path = path[CYGLEN:CYGLEN + 1] + ':' + path[CYGLEN + 1:]
path = path.replace('/', '\\')
return path
-
+
def GetPathToBinary(exe):
""" Try to find a copy of the binary that exists. Search for the full path
and then the basename.
@@ -44,9 +44,9 @@ def main(args):
args: The arguments passed by svn merge to its diff3 tool.
"""
- # Grab the arguments from the end of the list since svn will add any other
+ # Grab the arguments from the end of the list since svn will add any other
# arguments provided before these.
-
+
# The titles of the files being diffed.
title_mine = EnsureWindowsPath(args[-8])
title_older = EnsureWindowsPath(args[-6])
@@ -56,15 +56,15 @@ def main(args):
mine = EnsureWindowsPath(args[-3])
older = EnsureWindowsPath(args[-2])
yours = EnsureWindowsPath(args[-1])
-
+
# The command for which diff3 tool to use.
diff_tool = args[1]
-
+
if diff_tool == "--use-beyondcompare":
exe = GetPathToBinary("c:/Progra~1/Beyond~1/BComp.exe")
if not os.path.exists(exe):
exe = GetPathToBinary("c:/Progra~2/Beyond~1/BComp.exe")
- cmd = [exe,
+ cmd = [exe,
mine,
yours,
older,
@@ -74,9 +74,9 @@ def main(args):
'/leftreadonly',
'/rightreadonly',
'/ignoreunimportant',
- '/lefttitle', title_mine,
- '/righttitle', title_yours,
- '/centertitle', title_older,
+ '/lefttitle', title_mine,
+ '/righttitle', title_yours,
+ '/centertitle', title_older,
'/outputtitle', 'merged']
elif diff_tool == "--use-kdiff3":
exe = GetPathToBinary("c:/Progra~1/KDiff3/kdiff3.exe")
@@ -106,7 +106,7 @@ def main(args):
traceback.print_exc(file=sys.stdout)
# After performing the merge, this script needs to print the contents
- # of the merged file to stdout.
+ # of the merged file to stdout.
# Return an errorcode of 0 on successful merge, 1 if unresolved conflicts
# remain in the result. Any other errorcode will be treated as fatal.
merged_file_contents = open(mine).read()
diff --git a/webkit/tools/npapi_layout_test_plugin/PluginObject.cpp b/webkit/tools/npapi_layout_test_plugin/PluginObject.cpp
index 2afda67..afcb60f 100644
--- a/webkit/tools/npapi_layout_test_plugin/PluginObject.cpp
+++ b/webkit/tools/npapi_layout_test_plugin/PluginObject.cpp
@@ -413,19 +413,19 @@ static bool destroyStream(PluginObject* obj, const NPVariant* args, uint32_t arg
static bool testEnumerate(PluginObject* obj, const NPVariant* args, uint32_t argCount, NPVariant* result)
{
if (argCount == 2 && NPVARIANT_IS_OBJECT(args[0]) && NPVARIANT_IS_OBJECT(args[1])) {
- uint32_t count;
+ uint32_t count;
NPIdentifier* identifiers;
if (browser->enumerate(obj->npp, NPVARIANT_TO_OBJECT(args[0]), &identifiers, &count)) {
NPObject* outArray = NPVARIANT_TO_OBJECT(args[1]);
NPIdentifier pushIdentifier = browser->getstringidentifier("push");
-
+
for (uint32_t i = 0; i < count; i++) {
NPUTF8* string = browser->utf8fromidentifier(identifiers[i]);
-
+
if (!string)
continue;
-
+
NPVariant args[1];
STRINGZ_TO_NPVARIANT(string, args[0]);
NPVariant browserResult;
@@ -433,12 +433,12 @@ static bool testEnumerate(PluginObject* obj, const NPVariant* args, uint32_t arg
browser->releasevariantvalue(&browserResult);
browser->memfree(string);
}
-
+
browser->memfree(identifiers);
}
-
+
VOID_TO_NPVARIANT(*result);
- return true;
+ return true;
}
return false;
}
@@ -639,7 +639,7 @@ static bool pluginInvoke(NPObject* header, NPIdentifier name, const NPVariant* a
// object before returning it and the calling JS gets a garbage
// value. Firefox handles it fine.
OBJECT_TO_NPVARIANT(NPVARIANT_TO_OBJECT(browserResult), *result);
- } else {
+ } else {
browser->releasevariantvalue(&browserResult);
VOID_TO_NPVARIANT(*result);
}
@@ -682,21 +682,21 @@ static bool pluginInvoke(NPObject* header, NPIdentifier name, const NPVariant* a
// NPObject.
// Arguments:
// arg1: Callback that returns a script object.
- // arg2: Name of the method to call on the script object returned
+ // arg2: Name of the method to call on the script object returned
// from the callback
NPObject *windowScriptObject;
- browser->getvalue(plugin->npp, NPNVWindowNPObject,
+ browser->getvalue(plugin->npp, NPNVWindowNPObject,
&windowScriptObject);
// Arg1 is the name of the callback
NPUTF8* callbackString = createCStringFromNPVariant(&args[0]);
- NPIdentifier callbackIdentifier =
+ NPIdentifier callbackIdentifier =
browser->getstringidentifier(callbackString);
free(callbackString);
// Invoke a callback that returns a script object
NPVariant object_result;
- browser->invoke(plugin->npp, windowScriptObject, callbackIdentifier,
+ browser->invoke(plugin->npp, windowScriptObject, callbackIdentifier,
&args[1], 1, &object_result);
// Script object returned
@@ -704,7 +704,7 @@ static bool pluginInvoke(NPObject* header, NPIdentifier name, const NPVariant* a
// Arg2 is the name of the method to be called on the script object
NPUTF8* object_mehod_string = createCStringFromNPVariant(&args[1]);
- NPIdentifier object_method =
+ NPIdentifier object_method =
browser->getstringidentifier(object_mehod_string);
free(object_mehod_string);
@@ -729,7 +729,7 @@ static bool pluginInvoke(NPObject* header, NPIdentifier name, const NPVariant* a
// value. Firefox handles it fine.
OBJECT_TO_NPVARIANT(NPVARIANT_TO_OBJECT(object_method_result),
*result);
- } else {
+ } else {
browser->releasevariantvalue(&object_method_result);
VOID_TO_NPVARIANT(*result);
}
diff --git a/webkit/tools/npapi_layout_test_plugin/PluginObject.h b/webkit/tools/npapi_layout_test_plugin/PluginObject.h
index f344a36..5027f22 100644
--- a/webkit/tools/npapi_layout_test_plugin/PluginObject.h
+++ b/webkit/tools/npapi_layout_test_plugin/PluginObject.h
@@ -20,7 +20,7 @@
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "webkit/glue/plugins/nphostapi.h"
diff --git a/webkit/tools/npapi_layout_test_plugin/TestObject.cpp b/webkit/tools/npapi_layout_test_plugin/TestObject.cpp
index e82ba13..659da76 100644
--- a/webkit/tools/npapi_layout_test_plugin/TestObject.cpp
+++ b/webkit/tools/npapi_layout_test_plugin/TestObject.cpp
@@ -20,7 +20,7 @@
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "TestObject.h"
@@ -35,10 +35,10 @@ static bool testGetProperty(NPObject *obj, NPIdentifier name, NPVariant *variant
static NPObject *testAllocate(NPP npp, NPClass *theClass);
static void testDeallocate(NPObject *obj);
-static NPClass testClass = {
+static NPClass testClass = {
NP_CLASS_STRUCT_VERSION,
- testAllocate,
- testDeallocate,
+ testAllocate,
+ testDeallocate,
0,
0,
0,
@@ -88,16 +88,16 @@ static NPObject *testAllocate(NPP npp, NPClass *theClass)
static_cast<TestObject*>(malloc(sizeof(TestObject)));
newInstance->testObject = NULL;
++testObjectCount;
-
+
if (!identifiersInitialized) {
identifiersInitialized = true;
initializeIdentifiers();
}
-
+
return reinterpret_cast<NPObject*>(newInstance);
}
-static void testDeallocate(NPObject *obj)
+static void testDeallocate(NPObject *obj)
{
TestObject *testObject = reinterpret_cast<TestObject*>(obj);
if (testObject->testObject)
@@ -119,11 +119,11 @@ static bool testHasProperty(NPObject *obj, NPIdentifier name)
if (testIdentifiers[i] == name)
return true;
}
-
+
return false;
}
-static bool testGetProperty(NPObject *obj, NPIdentifier name,
+static bool testGetProperty(NPObject *obj, NPIdentifier name,
NPVariant *variant)
{
if (name == testIdentifiers[ID_PROPERTY_FOO]) {
@@ -151,10 +151,10 @@ static bool testGetProperty(NPObject *obj, NPIdentifier name,
static bool testEnumerate(NPObject *npobj, NPIdentifier **value, uint32_t *count)
{
*count = NUM_TEST_IDENTIFIERS;
-
+
*value = (NPIdentifier*)browser->memalloc(NUM_TEST_IDENTIFIERS * sizeof(NPIdentifier));
memcpy(*value, testIdentifiers, sizeof(NPIdentifier) * NUM_TEST_IDENTIFIERS);
-
+
return true;
}
diff --git a/webkit/tools/npapi_layout_test_plugin/TestObject.h b/webkit/tools/npapi_layout_test_plugin/TestObject.h
index 2babaaf..812603c 100644
--- a/webkit/tools/npapi_layout_test_plugin/TestObject.h
+++ b/webkit/tools/npapi_layout_test_plugin/TestObject.h
@@ -20,7 +20,7 @@
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "third_party/npapi/bindings/npapi.h"
diff --git a/webkit/tools/npapi_layout_test_plugin/main.cpp b/webkit/tools/npapi_layout_test_plugin/main.cpp
index dce0e3d..65426c0 100644
--- a/webkit/tools/npapi_layout_test_plugin/main.cpp
+++ b/webkit/tools/npapi_layout_test_plugin/main.cpp
@@ -1,33 +1,33 @@
/*
IMPORTANT: This Apple software is supplied to you by Apple Computer, Inc. ("Apple") in
- consideration of your agreement to the following terms, and your use, installation,
- modification or redistribution of this Apple software constitutes acceptance of these
- terms. If you do not agree with these terms, please do not use, install, modify or
+ consideration of your agreement to the following terms, and your use, installation,
+ modification or redistribution of this Apple software constitutes acceptance of these
+ terms. If you do not agree with these terms, please do not use, install, modify or
redistribute this Apple software.
-
- In consideration of your agreement to abide by the following terms, and subject to these
- terms, Apple grants you a personal, non-exclusive license, under Apple’s copyrights in
- this original Apple software (the "Apple Software"), to use, reproduce, modify and
- redistribute the Apple Software, with or without modifications, in source and/or binary
- forms; provided that if you redistribute the Apple Software in its entirety and without
- modifications, you must retain this notice and the following text and disclaimers in all
- such redistributions of the Apple Software. Neither the name, trademarks, service marks
- or logos of Apple Computer, Inc. may be used to endorse or promote products derived from
+
+ In consideration of your agreement to abide by the following terms, and subject to these
+ terms, Apple grants you a personal, non-exclusive license, under Apple’s copyrights in
+ this original Apple software (the "Apple Software"), to use, reproduce, modify and
+ redistribute the Apple Software, with or without modifications, in source and/or binary
+ forms; provided that if you redistribute the Apple Software in its entirety and without
+ modifications, you must retain this notice and the following text and disclaimers in all
+ such redistributions of the Apple Software. Neither the name, trademarks, service marks
+ or logos of Apple Computer, Inc. may be used to endorse or promote products derived from
the Apple Software without specific prior written permission from Apple. Except as expressly
stated in this notice, no other rights or licenses, express or implied, are granted by Apple
- herein, including but not limited to any patent rights that may be infringed by your
+ herein, including but not limited to any patent rights that may be infringed by your
derivative works or by other works in which the Apple Software may be incorporated.
-
- The Apple Software is provided by Apple on an "AS IS" basis. APPLE MAKES NO WARRANTIES,
- EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF NON-INFRINGEMENT,
- MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS
+
+ The Apple Software is provided by Apple on an "AS IS" basis. APPLE MAKES NO WARRANTIES,
+ EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF NON-INFRINGEMENT,
+ MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS
USE AND OPERATION ALONE OR IN COMBINATION WITH YOUR PRODUCTS.
-
- IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ARISING IN ANY WAY OUT OF THE USE,
- REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED AND
- WHETHER UNDER THEORY OF CONTRACT, TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR
+
+ IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ARISING IN ANY WAY OUT OF THE USE,
+ REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED AND
+ WHETHER UNDER THEORY OF CONTRACT, TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR
OTHERWISE, EVEN IF APPLE HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
@@ -81,7 +81,7 @@ NPError NPAPI NP_GetEntryPoints(NPPluginFuncs *pluginFuncs)
pluginFuncs->urlnotify = NPP_URLNotify;
pluginFuncs->getvalue = NPP_GetValue;
pluginFuncs->setvalue = NPP_SetValue;
-
+
return NPERR_NO_ERROR;
}
@@ -93,7 +93,7 @@ NPError NPP_New(NPMIMEType pluginType, NPP instance, uint16 mode, int16 argc, ch
{
if (browser->version >= 14) {
PluginObject* obj = (PluginObject*)browser->createobject(instance, getPluginClass());
-
+
for (int i = 0; i < argc; i++) {
if (strcasecmp(argn[i], "onstreamload") == 0 && !obj->onStreamLoad)
obj->onStreamLoad = strdup(argv[i]);
@@ -104,10 +104,10 @@ NPError NPP_New(NPMIMEType pluginType, NPP instance, uint16 mode, int16 argc, ch
else if (strcasecmp(argn[i], "logfirstsetwindow") == 0)
obj->logSetWindow = TRUE;
}
-
+
instance->pdata = obj;
}
-
+
// On Windows and Unix, plugins only get events if they are windowless.
return browser->setvalue(instance, NPPVpluginWindowBool, NULL);
}
@@ -141,7 +141,7 @@ NPError NPP_SetWindow(NPP instance, NPWindow *window)
if (window->window == NULL) {
return NPERR_NO_ERROR;
}
-
+
PluginObject* obj = static_cast<PluginObject*>(instance->pdata);
if (obj) {
@@ -150,7 +150,7 @@ NPError NPP_SetWindow(NPP instance, NPWindow *window)
obj->logSetWindow = false;
}
}
-
+
return NPERR_NO_ERROR;
}
@@ -220,7 +220,7 @@ int16 NPP_HandleEvent(NPP instance, void *event)
PluginObject* obj = static_cast<PluginObject*>(instance->pdata);
if (!obj->eventLogging)
return 0;
-
+
#ifdef WIN32
// Below is the event handling code. Per the NPAPI spec, the events don't
// map directly between operating systems:
@@ -268,7 +268,7 @@ int16 NPP_HandleEvent(NPP instance, void *event)
printf("PLUGIN: loseFocusEvent\n");
break;
default:
- printf("PLUGIN: event %d\n", evt->event);
+ printf("PLUGIN: event %d\n", evt->event);
}
fflush(stdout);
@@ -378,7 +378,7 @@ int16 NPP_HandleEvent(NPP instance, void *event)
printf("PLUGIN: event %d\n", evt->what);
}
#endif
-
+
return 0;
}
diff --git a/webkit/tools/npapi_layout_test_plugin/resource.h b/webkit/tools/npapi_layout_test_plugin/resource.h
index c2bcf92..fe773d32 100644
--- a/webkit/tools/npapi_layout_test_plugin/resource.h
+++ b/webkit/tools/npapi_layout_test_plugin/resource.h
@@ -3,7 +3,7 @@
// Used by npapi_layout_test_plugin.rc
// Next default values for new objects
-//
+//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 101
diff --git a/webkit/tools/test_shell/event_sending_controller.h b/webkit/tools/test_shell/event_sending_controller.h
index aaa7a74..38715dd 100644
--- a/webkit/tools/test_shell/event_sending_controller.h
+++ b/webkit/tools/test_shell/event_sending_controller.h
@@ -8,7 +8,7 @@
Bound to a JavaScript window.eventSender object using
CppBoundClass::BindToJavascript(), this allows layout tests that are run in
the test_shell to fire DOM events.
-
+
The OSX reference file is in
WebKit/WebKitTools/DumpRenderTree/EventSendingController.m
*/
diff --git a/webkit/tools/test_shell/foreground_helper.h b/webkit/tools/test_shell/foreground_helper.h
index 4829832..aeccef8 100644
--- a/webkit/tools/test_shell/foreground_helper.h
+++ b/webkit/tools/test_shell/foreground_helper.h
@@ -12,7 +12,7 @@
// move to the foreground, unless requested by the current window in the
// foreground. For automated testing, we really want some of our windows
// to be capable of moving to the foreground.
-//
+//
// This is probably leveraging a windows bug.
class ForegroundHelper : public CWindowImpl<ForegroundHelper> {
public:
@@ -21,7 +21,7 @@ BEGIN_MSG_MAP(ForegroundHelper)
END_MSG_MAP()
// Brings a window into the foreground.
- // Can be called from any window, even if the caller is not the
+ // Can be called from any window, even if the caller is not the
// foreground window.
static HRESULT SetForeground(HWND window) {
DCHECK(::IsWindow(window));
@@ -32,7 +32,7 @@ END_MSG_MAP()
private:
HRESULT ForegroundHotKey(HWND window) {
- // This implementation registers a hot key (F22) and then
+ // This implementation registers a hot key (F22) and then
// triggers the hot key. When receiving the hot key, we'll
// be in the foreground and allowed to move the target window
// into the foreground too.
@@ -60,7 +60,7 @@ END_MSG_MAP()
return E_FAIL;
// Loop until we get the key.
- // TODO: It may be possible to get stuck here if the
+ // TODO: It may be possible to get stuck here if the
// message gets lost?
while(GetMessage(&msg, NULL, 0, 0)) {
TranslateMessage(&msg);
@@ -77,7 +77,7 @@ END_MSG_MAP()
}
// Handle the registered Hotkey being pressed.
- LRESULT OnHotKey(UINT /*uMsg*/, WPARAM /*wParam*/,
+ LRESULT OnHotKey(UINT /*uMsg*/, WPARAM /*wParam*/,
LPARAM /*lParam*/, BOOL& bHandled) {
HWND window = reinterpret_cast<HWND>(GetWindowLongPtr(GWLP_USERDATA));
SetForegroundWindow(window);
diff --git a/webkit/tools/test_shell/image_decoder_unittest.cc b/webkit/tools/test_shell/image_decoder_unittest.cc
index 89ed594..7a55eea 100644
--- a/webkit/tools/test_shell/image_decoder_unittest.cc
+++ b/webkit/tools/test_shell/image_decoder_unittest.cc
@@ -37,7 +37,7 @@ void SaveMD5Sum(const std::wstring& path, WebCore::RGBA32Buffer* buffer) {
// Calculate MD5 sum.
MD5Digest digest;
- SkAutoLockPixels bmp_lock(buffer->bitmap());
+ SkAutoLockPixels bmp_lock(buffer->bitmap());
MD5Sum(buffer->bitmap().getPixels(),
buffer->rect().width() * buffer->rect().height() * sizeof(unsigned),
&digest);
@@ -60,7 +60,7 @@ void VerifyImage(WebCore::ImageDecoder* decoder,
// Calculate MD5 sum.
MD5Digest actual_digest;
- SkAutoLockPixels bmp_lock(image_buffer->bitmap());
+ SkAutoLockPixels bmp_lock(image_buffer->bitmap());
MD5Sum(image_buffer->bitmap().getPixels(), image_buffer->rect().width() *
image_buffer->rect().height() * sizeof(unsigned), &actual_digest);
diff --git a/webkit/tools/test_shell/mac/DumpRenderTreePasteboard.h b/webkit/tools/test_shell/mac/DumpRenderTreePasteboard.h
index 60e2ab5..f2c1953 100644
--- a/webkit/tools/test_shell/mac/DumpRenderTreePasteboard.h
+++ b/webkit/tools/test_shell/mac/DumpRenderTreePasteboard.h
@@ -8,13 +8,13 @@
* are met:
*
* 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
+ * notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
+ * documentation and/or other materials provided with the distribution.
* 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of
* its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
+ * from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
diff --git a/webkit/tools/test_shell/mac/DumpRenderTreePasteboard.m b/webkit/tools/test_shell/mac/DumpRenderTreePasteboard.m
index e8fa4ee..0e6731a 100644
--- a/webkit/tools/test_shell/mac/DumpRenderTreePasteboard.m
+++ b/webkit/tools/test_shell/mac/DumpRenderTreePasteboard.m
@@ -8,13 +8,13 @@
* are met:
*
* 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
+ * notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
+ * documentation and/or other materials provided with the distribution.
* 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of
* its contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
+ * from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
diff --git a/webkit/tools/test_shell/mac/test_shell_webview.mm b/webkit/tools/test_shell/mac/test_shell_webview.mm
index 17d6b79..4767e63 100644
--- a/webkit/tools/test_shell/mac/test_shell_webview.mm
+++ b/webkit/tools/test_shell/mac/test_shell_webview.mm
@@ -35,7 +35,7 @@
- (void) dealloc {
[self removeTrackingArea:trackingArea_];
[trackingArea_ release];
-
+
[super dealloc];
}
@@ -43,7 +43,7 @@
CGContextRef context =
reinterpret_cast<CGContextRef>([[NSGraphicsContext currentContext]
graphicsPort]);
-
+
// start by filling the rect with magenta, so that we can see what's drawn
CGContextSetRGBFillColor (context, 1, 0, 1, 1);
CGContextFillRect(context, NSRectToCGRect(rect));
@@ -53,7 +53,7 @@
// flip from cocoa coordinates
client_rect.set_y([self frame].size.height -
client_rect.height() - client_rect.y());
-
+
shell_->webViewHost()->UpdatePaintRect(client_rect);
shell_->webViewHost()->Paint();
}
@@ -81,8 +81,8 @@
- (IBAction)takeURLStringValueFrom:(NSTextField *)sender {
NSString *url = [sender stringValue];
-
- // if it doesn't already have a prefix, add http. If we can't parse it,
+
+ // if it doesn't already have a prefix, add http. If we can't parse it,
// just don't bother rather than making things worse.
NSURL* tempUrl = [NSURL URLWithString:url];
if (tempUrl && ![tempUrl scheme])
@@ -182,7 +182,7 @@
shell_->webViewHost()->SetFocus(YES);
return YES;
}
-
+
return NO;
}
@@ -191,7 +191,7 @@
shell_->webViewHost()->SetFocus(NO);
return YES;
}
-
+
return NO;
}
diff --git a/webkit/tools/test_shell/mac/test_webview_delegate.mm b/webkit/tools/test_shell/mac/test_webview_delegate.mm
index 48e2c3f..e80f75a 100755
--- a/webkit/tools/test_shell/mac/test_webview_delegate.mm
+++ b/webkit/tools/test_shell/mac/test_webview_delegate.mm
@@ -74,7 +74,7 @@ void TestWebViewDelegate::CloseWidgetSoon(WebWidget* webwidget) {
}
}
-void TestWebViewDelegate::SetCursor(WebWidget* webwidget,
+void TestWebViewDelegate::SetCursor(WebWidget* webwidget,
const WebCursor& cursor) {
NSCursor* ns_cursor = cursor.GetCursor();
[ns_cursor set];
@@ -114,7 +114,7 @@ void TestWebViewDelegate::GetRootWindowRect(WebWidget* webwidget,
- (NSRect)_growBoxRect;
@end
-void TestWebViewDelegate::GetRootWindowResizerRect(WebWidget* webwidget,
+void TestWebViewDelegate::GetRootWindowResizerRect(WebWidget* webwidget,
gfx::Rect* out_rect) {
NSRect resize_rect = NSMakeRect(0, 0, 0, 0);
WebWidgetHost* host = GetHostForWidget(webwidget);
@@ -131,8 +131,8 @@ void TestWebViewDelegate::GetRootWindowResizerRect(WebWidget* webwidget,
// Convert to view coordinates from window coordinates.
resize_rect = [view convertRect:resize_rect fromView:nil];
// Flip the rect in view coordinates
- resize_rect.origin.y =
- [view frame].size.height - resize_rect.origin.y -
+ resize_rect.origin.y =
+ [view frame].size.height - resize_rect.origin.y -
resize_rect.size.height;
}
*out_rect = gfx::Rect(NSRectToCGRect(resize_rect));
diff --git a/webkit/tools/test_shell/mac/webwidget_host.mm b/webkit/tools/test_shell/mac/webwidget_host.mm
index b99aca7..fd95535 100644
--- a/webkit/tools/test_shell/mac/webwidget_host.mm
+++ b/webkit/tools/test_shell/mac/webwidget_host.mm
@@ -23,7 +23,7 @@ WebWidgetHost* WebWidgetHost::Create(NSView* parent_view,
content_rect.size.height -= 64;
host->view_ = [[NSView alloc] initWithFrame:content_rect];
[parent_view addSubview:host->view_];
-
+
// win_util::SetWindowUserData(host->hwnd_, host);
host->webwidget_ = WebWidget::Create(delegate);
@@ -162,10 +162,10 @@ void WebWidgetHost::Paint() {
[NSGraphicsContext setCurrentContext:
[NSGraphicsContext graphicsContextWithGraphicsPort:bitmap_context
flipped:NO]];
-
+
// This may result in more invalidation
webwidget_->Layout();
-
+
// Scroll the canvas if necessary
scroll_rect_ = client_rect.Intersect(scroll_rect_);
if (!scroll_rect_.IsEmpty()) {
@@ -188,7 +188,7 @@ void WebWidgetHost::Paint() {
}
}
DCHECK(paint_rect_.IsEmpty());
-
+
// set the context back to our window
[NSGraphicsContext setCurrentContext: view_context];
@@ -201,7 +201,7 @@ void WebWidgetHost::Paint() {
{ bitmap_width, bitmap_height } };
canvas_->getTopPlatformDevice().DrawToContext(
context, 0, client_rect.height() - bitmap_height, &bitmap_rect);
-
+
[view_ unlockFocus];
}
}
diff --git a/webkit/tools/test_shell/plugin_tests.cc b/webkit/tools/test_shell/plugin_tests.cc
index 36737e4..5da7cf2 100644
--- a/webkit/tools/test_shell/plugin_tests.cc
+++ b/webkit/tools/test_shell/plugin_tests.cc
@@ -52,7 +52,7 @@ class PluginTest : public TestShellTest {
void WaitForFinish(const std::string &name, const std::string &id) {
test_shell_->WaitTestFinished();
- std::string cookies =
+ std::string cookies =
request_context_->cookie_store()->GetCookies(test_url_);
EXPECT_FALSE(cookies.empty());
@@ -115,7 +115,7 @@ class PluginTest : public TestShellTest {
};
TEST_F(PluginTest, DISABLED_VerifyPluginWindowRect) {
- std::wstring test_url = GetTestURL(plugin_data_dir_,
+ std::wstring test_url = GetTestURL(plugin_data_dir_,
L"verify_plugin_window_rect.html");
NavigateToURL(test_url);
WaitForFinish("checkwindowrect", "1");
diff --git a/webkit/tools/test_shell/resource.h b/webkit/tools/test_shell/resource.h
index 7deb4b9..f2deaaf 100644
--- a/webkit/tools/test_shell/resource.h
+++ b/webkit/tools/test_shell/resource.h
@@ -4,7 +4,7 @@
//
#define IDS_APP_TITLE 103
-
+
#define IDR_MAINFRAME 128
#define IDD_TESTSHELL_DIALOG 102
#define IDD_ABOUTBOX 103
@@ -26,7 +26,7 @@
#define IDC_STATIC -1
#endif
// Next default values for new objects
-//
+//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
diff --git a/webkit/tools/test_shell/run_all_tests.cc b/webkit/tools/test_shell/run_all_tests.cc
index 5cc12a2..ba37d68 100644
--- a/webkit/tools/test_shell/run_all_tests.cc
+++ b/webkit/tools/test_shell/run_all_tests.cc
@@ -30,7 +30,7 @@
#include "webkit/tools/test_shell/test_shell_webkit_init.h"
#include "testing/gtest/include/gtest/gtest.h"
-const char* TestShellTest::kJavascriptDelayExitScript =
+const char* TestShellTest::kJavascriptDelayExitScript =
"<script>"
"window.layoutTestController.waitUntilDone();"
"window.addEventListener('load', function() {"
diff --git a/webkit/tools/test_shell/simple_resource_loader_bridge.cc b/webkit/tools/test_shell/simple_resource_loader_bridge.cc
index 79ffee0..696502b 100644
--- a/webkit/tools/test_shell/simple_resource_loader_bridge.cc
+++ b/webkit/tools/test_shell/simple_resource_loader_bridge.cc
@@ -498,7 +498,7 @@ ResourceLoaderBridge* ResourceLoaderBridge::Create(
headers, load_flags);
}
-// Issue the proxy resolve request on the io thread, and wait
+// Issue the proxy resolve request on the io thread, and wait
// for the result.
bool FindProxyForUrl(const GURL& url, std::string* proxy_list) {
DCHECK(request_context);
diff --git a/webkit/tools/test_shell/test_navigation_controller.cc b/webkit/tools/test_shell/test_navigation_controller.cc
index cf9bff5..ff4a753 100644
--- a/webkit/tools/test_shell/test_navigation_controller.cc
+++ b/webkit/tools/test_shell/test_navigation_controller.cc
@@ -226,7 +226,7 @@ int TestNavigationController::GetEntryIndexWithPageID(int32 page_id) const {
void TestNavigationController::NavigateToPendingEntry(bool reload) {
// For session history navigations only the pending_entry_index_ is set.
if (!pending_entry_) {
- DCHECK(pending_entry_index_ != -1);
+ DCHECK(pending_entry_index_ != -1);
pending_entry_ = entries_[pending_entry_index_].get();
}
diff --git a/webkit/tools/test_shell/test_navigation_controller.h b/webkit/tools/test_shell/test_navigation_controller.h
index f65c85a..aeec2bf 100644
--- a/webkit/tools/test_shell/test_navigation_controller.h
+++ b/webkit/tools/test_shell/test_navigation_controller.h
@@ -80,7 +80,7 @@ class TestNavigationEntry {
std::string state_;
mutable scoped_refptr<WebHistoryItem> cached_history_item_;
-
+
std::wstring target_frame_;
DISALLOW_COPY_AND_ASSIGN(TestNavigationEntry);
diff --git a/webkit/tools/test_shell/test_shell_gtk.cc b/webkit/tools/test_shell/test_shell_gtk.cc
index 5cde156..fb56328 100644
--- a/webkit/tools/test_shell/test_shell_gtk.cc
+++ b/webkit/tools/test_shell/test_shell_gtk.cc
@@ -495,7 +495,7 @@ void TestShell::ResizeSubViews() {
static_cast<TestShell*>(g_object_get_data(G_OBJECT(window), "test-shell"));
shell->ResetTestController();
- // ResetTestController may have closed the window we were holding on to.
+ // ResetTestController may have closed the window we were holding on to.
// Grab the first window again.
window = *(TestShell::windowList()->begin());
shell = static_cast<TestShell*>(g_object_get_data(G_OBJECT(window), "test-shell"));
diff --git a/webkit/tools/test_shell/test_shell_mac.mm b/webkit/tools/test_shell/test_shell_mac.mm
index dea940a..54c2859 100644
--- a/webkit/tools/test_shell/test_shell_mac.mm
+++ b/webkit/tools/test_shell/test_shell_mac.mm
@@ -109,8 +109,8 @@ FilePath GetResourcesFilePath() {
// clean ourselves up and do the work after clearing the stack of anything
// that might have the shell on it.
- [self performSelectorOnMainThread:@selector(cleanup:)
- withObject:window
+ [self performSelectorOnMainThread:@selector(cleanup:)
+ withObject:window
waitUntilDone:NO];
return YES;
@@ -161,7 +161,7 @@ void TestShell::PlatformShutdown() {
}
// assert if we have anything left over, that would be bad.
DCHECK(window_map_.Get().size() == 0);
-
+
// Dump the pasteboards we built up.
[DumpRenderTreePasteboard releaseLocalPasteboards];
}
@@ -173,9 +173,9 @@ void TestShell::InitializeTestShell(bool layout_test_mode) {
window_list_ = new WindowList;
layout_test_mode_ = layout_test_mode;
-
+
web_prefs_ = new WebPreferences;
-
+
ResetWebPreferences();
// Load the Ahem font, which is used by layout tests.
@@ -214,7 +214,7 @@ NSButton* MakeTestButton(NSRect* rect, NSString* title, NSView* parent) {
bool TestShell::Initialize(const std::wstring& startingURL) {
// Perform application initialization:
// send message to app controller? need to work this out
-
+
// TODO(awalker): this is a straight recreation of windows test_shell.cc's
// window creation code--we should really pull this from the nib and grab
// references to the already-created subviews that way.
@@ -230,30 +230,30 @@ bool TestShell::Initialize(const std::wstring& startingURL) {
backing:NSBackingStoreBuffered
defer:NO];
[m_mainWnd setTitle:@"TestShell"];
-
+
// Add to our map
window_map_.Get()[m_mainWnd] = this;
-
+
// Create a window delegate to watch for when it's asked to go away. It will
// clean itself up so we don't need to hold a reference.
[m_mainWnd setDelegate:[[WindowCloseDelegate alloc] init]];
-
- // Rely on the window delegate to clean us up rather than immediately
- // releasing when the window gets closed. We use the delegate to do
+
+ // Rely on the window delegate to clean us up rather than immediately
+ // releasing when the window gets closed. We use the delegate to do
// everything from the autorelease pool so the shell isn't on the stack
// during cleanup (ie, a window close from javascript).
[m_mainWnd setReleasedWhenClosed:NO];
-
+
// Create a webview. Note that |web_view| takes ownership of this shell so we
// will get cleaned up when it gets destroyed.
m_webViewHost.reset(
WebViewHost::Create([m_mainWnd contentView], delegate_.get(), *TestShell::web_prefs_));
webView()->SetUseEditorDelegate(true);
delegate_->RegisterDragDrop();
- TestShellWebView* web_view =
+ TestShellWebView* web_view =
static_cast<TestShellWebView*>(m_webViewHost->view_handle());
[web_view setShell:this];
-
+
// create buttons
NSRect button_rect = [[m_mainWnd contentView] bounds];
button_rect.origin.y = window_rect.size.height - URLBAR_HEIGHT +
@@ -261,27 +261,27 @@ bool TestShell::Initialize(const std::wstring& startingURL) {
button_rect.size.height = BUTTON_HEIGHT;
button_rect.origin.x += BUTTON_MARGIN;
button_rect.size.width = BUTTON_WIDTH;
-
+
NSView* content = [m_mainWnd contentView];
-
+
NSButton* button = MakeTestButton(&button_rect, @"Back", content);
[button setTarget:web_view];
[button setAction:@selector(goBack:)];
-
+
button = MakeTestButton(&button_rect, @"Forward", content);
[button setTarget:web_view];
[button setAction:@selector(goForward:)];
-
+
// reload button
button = MakeTestButton(&button_rect, @"Reload", content);
[button setTarget:web_view];
[button setAction:@selector(reload:)];
-
+
// stop button
button = MakeTestButton(&button_rect, @"Stop", content);
[button setTarget:web_view];
[button setAction:@selector(stopLoading:)];
-
+
// text field for URL
button_rect.origin.x += BUTTON_MARGIN;
button_rect.size.width = [[m_mainWnd contentView] bounds].size.width -
@@ -296,7 +296,7 @@ bool TestShell::Initialize(const std::wstring& startingURL) {
// show the window
[m_mainWnd makeKeyAndOrderFront: nil];
-
+
// Load our initial content.
if (!startingURL.empty())
LoadURL(startingURL.c_str());
@@ -315,7 +315,7 @@ bool TestShell::Initialize(const std::wstring& startingURL) {
void TestShell::TestFinished() {
if (!test_is_pending_)
return; // reached when running under test_shell_tests
-
+
test_is_pending_ = false;
NSWindow* window = *(TestShell::windowList()->begin());
WindowMap::iterator it = window_map_.Get().find(window);
@@ -347,14 +347,14 @@ void TestShell::TestFinished() {
- (void)run:(id)ignore {
NSAutoreleasePool* pool = [[NSAutoreleasePool alloc] init];
-
+
// check for debugger, just bail if so. We don't want the timeouts hitting
// when we're trying to track down an issue.
if (DebugUtil::BeingDebugged())
return;
-
+
NSThread* currentThread = [NSThread currentThread];
-
+
// Wait to be cancelled. If we are that means the test finished. If it hasn't,
// then we need to tell the layout script we timed out and start again.
NSDate* limitDate = [NSDate dateWithTimeIntervalSinceNow:timeout_];
@@ -381,26 +381,26 @@ void TestShell::TestFinished() {
void TestShell::WaitTestFinished() {
DCHECK(!test_is_pending_) << "cannot be used recursively";
-
+
test_is_pending_ = true;
-
+
// Create a watchdog thread which just sets a timer and
// kills the process if it times out. This catches really
- // bad hangs where the shell isn't coming back to the
- // message loop. If the watchdog is what catches a
+ // bad hangs where the shell isn't coming back to the
+ // message loop. If the watchdog is what catches a
// timeout, it can't do anything except terminate the test
// shell, which is unfortunate.
// Windows multiplies by 2.5, but that causes us to run for far, far too
// long. We use the passed value and let the scripts flag override
// the value as needed.
NSTimeInterval timeout_seconds = GetLayoutTestTimeoutInSeconds();
- WatchDogTarget* watchdog = [[[WatchDogTarget alloc]
+ WatchDogTarget* watchdog = [[[WatchDogTarget alloc]
initWithTimeout:timeout_seconds] autorelease];
NSThread* thread = [[NSThread alloc] initWithTarget:watchdog
- selector:@selector(run:)
+ selector:@selector(run:)
object:nil];
[thread start];
-
+
// TestFinished() will post a quit message to break this loop when the page
// finishes loading.
while (test_is_pending_)
@@ -444,7 +444,7 @@ WebWidget* TestShell::CreatePopupWidget(WebView* webview) {
DCHECK(!m_popupHost);
m_popupHost = WebWidgetHost::Create(NULL, delegate_.get());
// ShowWindow(popupWnd(), SW_SHOW);
-
+
return m_popupHost->webwidget();
}
@@ -492,7 +492,7 @@ void TestShell::ResizeSubViews() {
DCHECK(shell);
shell->ResetTestController();
- // ResetTestController may have closed the window we were holding on to.
+ // ResetTestController may have closed the window we were holding on to.
// Grab the first window again.
window = *(TestShell::windowList()->begin());
shell = window_map_.Get()[window];
@@ -536,7 +536,7 @@ void TestShell::LoadURLForFrame(const wchar_t* url,
const wchar_t* frame_name) {
if (!url)
return;
-
+
std::string url8 = WideToUTF8(url);
bool bIsSVGTest = strstr(url8.c_str(), "W3C-SVG-1.1") > 0;
@@ -567,12 +567,12 @@ bool TestShell::PromptForSaveFile(const wchar_t* prompt_title,
std::wstring* result)
{
NSSavePanel* save_panel = [NSSavePanel savePanel];
-
+
/* set up new attributes */
[save_panel setRequiredFileType:@"txt"];
[save_panel setMessage:
[NSString stringWithUTF8String:WideToUTF8(prompt_title).c_str()]];
-
+
/* display the NSSavePanel */
if ([save_panel runModalForDirectory:NSHomeDirectory() file:@""] ==
NSOKButton) {
diff --git a/webkit/tools/test_shell/test_shell_main.cc b/webkit/tools/test_shell/test_shell_main.cc
index 01afc6d..859fd5f 100644
--- a/webkit/tools/test_shell/test_shell_main.cc
+++ b/webkit/tools/test_shell/test_shell_main.cc
@@ -52,15 +52,15 @@ static int kStatsFileCounters = 200;
int main(int argc, char* argv[]) {
base::EnableTerminationOnHeapCorruption();
-
+
// Some tests may use base::Singleton<>, thus we need to instanciate
// the AtExitManager or else we will leak objects.
- base::AtExitManager at_exit_manager;
+ base::AtExitManager at_exit_manager;
TestShellPlatformDelegate::PreflightArgs(&argc, &argv);
CommandLine::Init(argc, argv);
const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess();
-
+
TestShellPlatformDelegate platform(parsed_command_line);
if (parsed_command_line.HasSwitch(test_shell::kStartupDialog))
@@ -100,9 +100,9 @@ int main(int argc, char* argv[]) {
base::TraceLog::StartTracing();
net::HttpCache::Mode cache_mode = net::HttpCache::NORMAL;
- bool playback_mode =
+ bool playback_mode =
parsed_command_line.HasSwitch(test_shell::kPlaybackMode);
- bool record_mode =
+ bool record_mode =
parsed_command_line.HasSwitch(test_shell::kRecordMode);
if (playback_mode)
diff --git a/webkit/tools/test_shell/test_shell_platform_delegate.h b/webkit/tools/test_shell/test_shell_platform_delegate.h
index 5be147a..19ffbd7 100644
--- a/webkit/tools/test_shell/test_shell_platform_delegate.h
+++ b/webkit/tools/test_shell/test_shell_platform_delegate.h
@@ -48,7 +48,7 @@ class TestShellPlatformDelegate {
// settings. Normally called by the destructor, but also called before
// abort() (example: test timeouts).
void AboutToExit();
-
+
// SetWindowPositionForRecording: if the platform's implementation of
// EventRecorder requires the window to be in a particular absolute position,
// make it so. This is called by TestShell after it creates the window.
diff --git a/webkit/tools/test_shell/test_shell_platform_delegate_gtk.cc b/webkit/tools/test_shell/test_shell_platform_delegate_gtk.cc
index 52b1d49..78dd552 100644
--- a/webkit/tools/test_shell/test_shell_platform_delegate_gtk.cc
+++ b/webkit/tools/test_shell/test_shell_platform_delegate_gtk.cc
@@ -10,7 +10,7 @@
#include "webkit/tools/test_shell/test_shell_platform_delegate.h"
void TestShellPlatformDelegate::PreflightArgs(int *argc, char ***argv) {
- gtk_init(argc, argv);
+ gtk_init(argc, argv);
}
void TestShellPlatformDelegate::SelectUnifiedTheme() {
diff --git a/webkit/tools/test_shell/test_shell_platform_delegate_mac.mm b/webkit/tools/test_shell/test_shell_platform_delegate_mac.mm
index 76e0757..0583f72 100644
--- a/webkit/tools/test_shell/test_shell_platform_delegate_mac.mm
+++ b/webkit/tools/test_shell/test_shell_platform_delegate_mac.mm
@@ -28,9 +28,9 @@ static void SetDefaultsToLayoutTestValues(void) {
// preferences that control appearance to match.
// (We want to do this as early as possible in application startup so
// the settings are in before any higher layers could cache values.)
-
+
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
-
+
const NSInteger kMinFontSizeCGSmoothes = 4;
const NSInteger kNoFontSmoothing = 0;
const NSInteger kBlueTintedAppearance = 1;
@@ -46,7 +46,7 @@ static void SetDefaultsToLayoutTestValues(void) {
forKey:@"AppleOtherHighlightColor"];
[defaults setObject:[NSArray arrayWithObject:@"en"]
forKey:@"AppleLanguages"];
-
+
// AppKit pulls scrollbar style from NSUserDefaults. HIToolbox uses
// CFPreferences, but AnyApplication, so we set it, force it to load, and
// then reset the pref to what it was (HIToolbox will cache what it loaded).
@@ -78,9 +78,9 @@ static void SetDefaultsToLayoutTestValues(void) {
static void ClearAnyDefaultsForLayoutTests(void) {
// Not running a test, clear the keys so the TestShell looks right to the
// running user.
-
+
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
-
+
[defaults removeObjectForKey:@"AppleAntiAliasingThreshold"];
[defaults removeObjectForKey:@"AppleFontSmoothing"];
[defaults removeObjectForKey:@"AppleAquaColorVariant"];
@@ -96,7 +96,7 @@ static void RestoreUsersColorProfile(void) {
// This is called from the unsafe signal handers, so doing just about anything
// isn't really safe. But since we're already gonna crash, we give it a try
// anyways... (and WebKit uses this strategy...)
-
+
if (gUsersColorProfile) {
CGDirectDisplayID displayID = CGMainDisplayID();
CMError error = CMSetProfileByAVID((UInt32)displayID, gUsersColorProfile);
@@ -127,7 +127,7 @@ static void InstallLayoutTestColorProfile(void) {
// we force the generic rgb color profile. This cases a change the user can
// see. We use the same basic method as WebKit for trying to make sure we
// get the profile back if we go down in flames.
-
+
// Save off the current
CGDirectDisplayID displayID = CGMainDisplayID();
CMProfileRef previousProfile;
@@ -137,7 +137,7 @@ static void InstallLayoutTestColorProfile(void) {
"pixmaps won't match. Error: " << (int)error;
return;
}
-
+
// Install the generic one
NSColorSpace *genericSpace = [NSColorSpace genericRGBColorSpace];
CMProfileRef genericProfile = (CMProfileRef)[genericSpace colorSyncProfile];
@@ -146,7 +146,7 @@ static void InstallLayoutTestColorProfile(void) {
"pixmaps won't match. Error: " << (int)error;
return;
}
-
+
// Save the starting profile, and hook in as best we can to make sure when
// we exit, it's restored (use atexit() so direct calls to exit() call us).
gUsersColorProfile = previousProfile;
@@ -173,13 +173,13 @@ static void InstallLayoutTestColorProfile(void) {
static void SwizzleAllMethods(Class imposter, Class original) {
unsigned int imposterMethodCount = 0;
Method* imposterMethods = class_copyMethodList(imposter, &imposterMethodCount);
-
+
unsigned int originalMethodCount = 0;
Method* originalMethods = class_copyMethodList(original, &originalMethodCount);
-
+
for (unsigned int i = 0; i < imposterMethodCount; i++) {
SEL imposterMethodName = method_getName(imposterMethods[i]);
-
+
// Attempt to add the method to the original class. If it fails, the method
// already exists and we should instead exchange the implementations.
if (class_addMethod(original,
@@ -188,7 +188,7 @@ static void SwizzleAllMethods(Class imposter, Class original) {
method_getTypeEncoding(originalMethods[i]))) {
continue;
}
-
+
unsigned int j = 0;
for (; j < originalMethodCount; j++) {
SEL originalMethodName = method_getName(originalMethods[j]);
@@ -196,13 +196,13 @@ static void SwizzleAllMethods(Class imposter, Class original) {
break;
}
}
-
+
// If class_addMethod failed above then the method must exist on the
// original class.
DCHECK(j < originalMethodCount) << "method wasn't found?";
method_exchangeImplementations(imposterMethods[i], originalMethods[j]);
}
-
+
if (imposterMethods) {
free(imposterMethods);
}
@@ -215,7 +215,7 @@ static void SwizzleAllMethods(Class imposter, Class original) {
static void SwizzleNSPasteboard(void) {
// We replace NSPaseboard w/ the shim (from WebKit) that avoids having
// sideeffects w/ whatever the user does at the same time.
-
+
Class imposterClass = objc_getClass("DumpRenderTreePasteboard");
Class originalClass = objc_getClass("NSPasteboard");
#if OBJC_API_VERSION == 0
@@ -270,7 +270,7 @@ void TestShellPlatformDelegate::SetWindowPositionForRecording(TestShell *) {
void TestShellPlatformDelegate::SelectUnifiedTheme() {
SetDefaultsToLayoutTestValues();
SwizzleNSPasteboard();
-
+
if (command_line_.HasSwitch(test_shell::kDumpPixels)) {
InstallLayoutTestColorProfile();
}
@@ -280,6 +280,6 @@ void TestShellPlatformDelegate::SuppressErrorReporting() {
// If we die during tests, we don't want to be spamming the user's crash
// reporter. Set our exception port to null.
task_set_exception_ports(mach_task_self(), EXC_MASK_ALL, MACH_PORT_NULL,
- EXCEPTION_DEFAULT, THREAD_STATE_NONE);
+ EXCEPTION_DEFAULT, THREAD_STATE_NONE);
}
diff --git a/webkit/tools/test_shell/test_shell_test.cc b/webkit/tools/test_shell/test_shell_test.cc
index 4b5a37e..1ce279a 100644
--- a/webkit/tools/test_shell/test_shell_test.cc
+++ b/webkit/tools/test_shell/test_shell_test.cc
@@ -10,7 +10,7 @@
#include "base/path_service.h"
#include "base/string_util.h"
-std::wstring TestShellTest::GetTestURL(std::wstring test_case_path,
+std::wstring TestShellTest::GetTestURL(std::wstring test_case_path,
const std::wstring& test_case) {
file_util::AppendToPath(&test_case_path, test_case);
return test_case_path;
@@ -33,7 +33,7 @@ void TestShellTest::TearDown() {
test_shell_->LoadURL(L"about:blank");
test_shell_->DestroyWindow(test_shell_->mainWnd());
LayoutTestController::ClearShell();
-
+
// Flush the MessageLoop of any residual tasks.
MessageLoop::current()->RunAllPending();
}
diff --git a/webkit/tools/test_shell/test_shell_test.h b/webkit/tools/test_shell/test_shell_test.h
index 6cff03b..137fc71 100644
--- a/webkit/tools/test_shell/test_shell_test.h
+++ b/webkit/tools/test_shell/test_shell_test.h
@@ -17,7 +17,7 @@
class TestShellTest : public testing::Test {
protected:
// Returns the path "test_case_path/test_case".
- std::wstring GetTestURL(std::wstring test_case_path,
+ std::wstring GetTestURL(std::wstring test_case_path,
const std::wstring& test_case);
virtual void SetUp();
@@ -27,7 +27,7 @@ class TestShellTest : public testing::Test {
virtual void CreateEmptyWindow();
static const char* kJavascriptDelayExitScript;
-
+
protected:
// Location of SOURCE_ROOT/webkit/data/
std::wstring data_dir_;
diff --git a/webkit/tools/test_shell/test_shell_webkit_init.h b/webkit/tools/test_shell/test_shell_webkit_init.h
index 75f7c4c..dd98b33 100644
--- a/webkit/tools/test_shell/test_shell_webkit_init.h
+++ b/webkit/tools/test_shell/test_shell_webkit_init.h
@@ -19,7 +19,7 @@ class TestShellWebKitInit : public webkit_glue::WebKitClientImpl {
public:
TestShellWebKitInit(bool layout_test_mode) {
WebKit::initialize(this);
- WebKit::setLayoutTestMode(layout_test_mode);
+ WebKit::setLayoutTestMode(layout_test_mode);
WebKit::registerURLSchemeAsLocal(
ASCIIToUTF16(webkit_glue::GetUIResourceProtocol()));
}
diff --git a/webkit/tools/test_shell/test_shell_win.cc b/webkit/tools/test_shell/test_shell_win.cc
index 045c8b8..c1d3ff1 100644
--- a/webkit/tools/test_shell/test_shell_win.cc
+++ b/webkit/tools/test_shell/test_shell_win.cc
@@ -244,7 +244,7 @@ bool TestShell::RunFileTest(const TestParams& params) {
// after we invoke StopLoading.
shell->ResetTestController();
- // ResetTestController may have closed the window we were holding on to.
+ // ResetTestController may have closed the window we were holding on to.
// Grab the first window again.
hwnd = *(TestShell::windowList()->begin());
shell = static_cast<TestShell*>(win_util::GetWindowUserData(hwnd));
diff --git a/webkit/tools/test_shell/test_webview_delegate_gtk.cc b/webkit/tools/test_shell/test_webview_delegate_gtk.cc
index c74b64f..8c9399c 100755
--- a/webkit/tools/test_shell/test_webview_delegate_gtk.cc
+++ b/webkit/tools/test_shell/test_webview_delegate_gtk.cc
@@ -122,7 +122,7 @@ void TestWebViewDelegate::CloseWidgetSoon(WebWidget* webwidget) {
}
}
-void TestWebViewDelegate::SetCursor(WebWidget* webwidget,
+void TestWebViewDelegate::SetCursor(WebWidget* webwidget,
const WebCursor& cursor) {
current_cursor_ = cursor;
GdkCursorType cursor_type = current_cursor_.GetCursorType();
@@ -194,7 +194,7 @@ void TestWebViewDelegate::GetRootWindowRect(WebWidget* webwidget,
}
}
-void TestWebViewDelegate::GetRootWindowResizerRect(WebWidget* webwidget,
+void TestWebViewDelegate::GetRootWindowResizerRect(WebWidget* webwidget,
gfx::Rect* out_rect) {
// Not necessary on Linux.
*out_rect = gfx::Rect();
diff --git a/webkit/tools/test_shell/test_webview_delegate_win.cc b/webkit/tools/test_shell/test_webview_delegate_win.cc
index e9fff70..b6935e8 100755
--- a/webkit/tools/test_shell/test_webview_delegate_win.cc
+++ b/webkit/tools/test_shell/test_webview_delegate_win.cc
@@ -124,7 +124,7 @@ void TestWebViewDelegate::GetRootWindowRect(WebWidget* webwidget,
}
}
-void TestWebViewDelegate::GetRootWindowResizerRect(WebWidget* webwidget,
+void TestWebViewDelegate::GetRootWindowResizerRect(WebWidget* webwidget,
gfx::Rect* out_rect) {
// Not necessary on Windows.
*out_rect = gfx::Rect();
diff --git a/webkit/tools/test_shell/webwidget_host_win.cc b/webkit/tools/test_shell/webwidget_host_win.cc
index b8430af..fc4be75 100644
--- a/webkit/tools/test_shell/webwidget_host_win.cc
+++ b/webkit/tools/test_shell/webwidget_host_win.cc
@@ -213,7 +213,7 @@ void WebWidgetHost::Paint() {
RECT r;
GetClientRect(view_, &r);
gfx::Rect client_rect(r);
-
+
// Allocate a canvas if necessary
if (!canvas_.get()) {
ResetScrollRect();
diff --git a/webkit/tools/webcore_unit_tests/BMPImageDecoder_unittest.cpp b/webkit/tools/webcore_unit_tests/BMPImageDecoder_unittest.cpp
index 763cf00..4d8b55a 100644
--- a/webkit/tools/webcore_unit_tests/BMPImageDecoder_unittest.cpp
+++ b/webkit/tools/webcore_unit_tests/BMPImageDecoder_unittest.cpp
@@ -1,10 +1,10 @@
// Copyright (c) 2008, Google Inc.
// All rights reserved.
-//
+//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
-//
+//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
@@ -14,7 +14,7 @@
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
-//
+//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
diff --git a/webkit/tools/webcore_unit_tests/GKURL_unittest.cpp b/webkit/tools/webcore_unit_tests/GKURL_unittest.cpp
index 683b6a2..3f84e8d 100644
--- a/webkit/tools/webcore_unit_tests/GKURL_unittest.cpp
+++ b/webkit/tools/webcore_unit_tests/GKURL_unittest.cpp
@@ -1,10 +1,10 @@
// Copyright (c) 2008, Google Inc.
// All rights reserved.
-//
+//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
-//
+//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
@@ -14,7 +14,7 @@
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
-//
+//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
@@ -358,7 +358,7 @@ TEST(GKURL, ReplaceInvalid) {
EXPECT_FALSE(gurl.isValid());
EXPECT_TRUE(gurl.isEmpty());
EXPECT_STREQ("", gurl.string().utf8().data());
-
+
gurl.setProtocol("http");
// GKURL will say that a URL with just a scheme is invalid, KURL will not.
#if USE(GOOGLEURL)
@@ -451,7 +451,7 @@ TEST(GKURL, Ref) {
cur = gurl;
cur.setRef("asdf");
EXPECT_STREQ("http://foo/bar#asdf", cur.string().utf8().data());
-
+
// Setting a ref to the empty string will set it to "#".
cur = WebCore::KURL("http://foo/bar");
cur.setRef("");
diff --git a/webkit/tools/webcore_unit_tests/ICOImageDecoder_unittest.cpp b/webkit/tools/webcore_unit_tests/ICOImageDecoder_unittest.cpp
index d49706a..3d6b0f9 100644
--- a/webkit/tools/webcore_unit_tests/ICOImageDecoder_unittest.cpp
+++ b/webkit/tools/webcore_unit_tests/ICOImageDecoder_unittest.cpp
@@ -1,10 +1,10 @@
// Copyright (c) 2008, Google Inc.
// All rights reserved.
-//
+//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
-//
+//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
@@ -14,7 +14,7 @@
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
-//
+//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
diff --git a/webkit/tools/webcore_unit_tests/TransparencyWin_unittest.cpp b/webkit/tools/webcore_unit_tests/TransparencyWin_unittest.cpp
index 46b955f..07366c8 100644
--- a/webkit/tools/webcore_unit_tests/TransparencyWin_unittest.cpp
+++ b/webkit/tools/webcore_unit_tests/TransparencyWin_unittest.cpp
@@ -1,10 +1,10 @@
/*
* Copyright (C) 2009 Google Inc. All rights reserved.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
- *
+ *
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
@@ -14,7 +14,7 @@
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
- *
+ *
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
@@ -117,7 +117,7 @@ TEST(TransparencyWin, NoLayer)
EXPECT_TRUE(IntSize(14, 12) == helper.m_layerSize);
EXPECT_TRUE(IntRect(1, 1, 14, 12) == helper.drawRect());
}
-
+
// Untransform is not allowed for NoLayer.
// ScaleTransform
@@ -168,7 +168,7 @@ TEST(TransparencyWin, WhiteLayer)
EXPECT_TRUE(IntSize(14, 12) == helper.m_layerSize);
EXPECT_TRUE(IntRect(0, 0, 14, 12) == helper.drawRect());
}
-
+
// ScaleTransform
src->context()->save();
src->context()->scale(FloatSize(2.0, 0.5));
@@ -251,7 +251,7 @@ TEST(TransparencyWin, OpaqueCompositeLayer)
EXPECT_TRUE(IntSize(14, 12) == helper.m_layerSize);
EXPECT_TRUE(IntRect(0, 0, 14, 12) == helper.drawRect());
}
-
+
// ScaleTransform
src->context()->save();
src->context()->scale(FloatSize(2.0, 0.5));
@@ -676,4 +676,4 @@ TEST(TransparencyWin, Text)
EXPECT_EQ(Color::transparent, getPixelAt(src->context(), 7, 0));
}
-} // namespace WebCore \ No newline at end of file
+} // namespace WebCore
diff --git a/webkit/tools/webcore_unit_tests/UniscribeHelper_unittest.cpp b/webkit/tools/webcore_unit_tests/UniscribeHelper_unittest.cpp
index 6410828..d61f90f 100644
--- a/webkit/tools/webcore_unit_tests/UniscribeHelper_unittest.cpp
+++ b/webkit/tools/webcore_unit_tests/UniscribeHelper_unittest.cpp
@@ -136,4 +136,4 @@ TEST_F(UniscribeTest, TooBig)
EXPECT_EQ(0, uniscribe.xToCharacter(0));
EXPECT_EQ(0, uniscribe.xToCharacter(1000));
}
-} \ No newline at end of file
+}
diff --git a/webkit/tools/webcore_unit_tests/XBMImageDecoder_unittest.cpp b/webkit/tools/webcore_unit_tests/XBMImageDecoder_unittest.cpp
index 1140813..0f34238 100644
--- a/webkit/tools/webcore_unit_tests/XBMImageDecoder_unittest.cpp
+++ b/webkit/tools/webcore_unit_tests/XBMImageDecoder_unittest.cpp
@@ -1,10 +1,10 @@
// Copyright (c) 2008, Google Inc.
// All rights reserved.
-//
+//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
-//
+//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
@@ -14,7 +14,7 @@
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
-//
+//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR