Commit 8d9c69e2 authored by dbeam's avatar dbeam Committed by Commit bot

Make .clang-format files smaller after clang-format roll

-style=Chromium now enables include sorting implicitly, so no need to
turn that on explicitly anymore. Likewise,
AllowShortFunctionsOnASingleLine now defaults to Empty.

Finally, all grit instructions in .js files are now in comments (when
they can be), so `JavaScriptQuotes: Leave` is no longer needed either.

No intended behavior change.

Based on https://crrev.com/2729033002/ by Nico <thakis@chromium.org>

BUG=567770
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation

Review-Url: https://codereview.chromium.org/2745303002
Cr-Commit-Position: refs/heads/master@{#457024}
parent dbc21818
......@@ -7,9 +7,6 @@ BasedOnStyle: Chromium
# 'int>>' if the file already contains at least one such instance.)
Standard: Cpp11
# TODO(thakis): Default this to true in -style=Chromium if we decide to keep it.
SortIncludes: true
# Make sure code like:
# IPC_BEGIN_MESSAGE_MAP()
# IPC_MESSAGE_HANDLER(WidgetHostViewHost_Update, OnUpdate)
......
# Please keep this file the same as ui/webui/resources/.clang-format.
BasedOnStyle: Chromium
# Renaming quotes in <include> and <if> break things.
# For normal JS code, please prefer ' to ".
JavaScriptQuotes: Leave
AllowShortFunctionsOnASingleLine: Empty
......@@ -8,7 +8,12 @@
try {
function initialize() {
// This include will be processed at build time by grit.
// Note: this <include> is not behind a single-line comment because the
// first line of the file is source code (so the first line would be
// skipped) instead of a licence header.
// clang-format off
<include src="../../../../third_party/dom_distiller_js/dist/js/domdistiller.js"/>
// clang-format on
}
window.setTimeout = function() {};
window.clearTimeout = function() {};
......
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Note: this <include> is not behind a single-line comment because the first
// line of the file is source code (so the first line would be skipped) instead
// of a licence header. Also, the result is used in an assignment.
// clang-format off
i18n.input.chrome.inputview.TranslationTable =
<include src="../../../../third_party/google_input_tools/src/chrome/os/inputview/_locales/en/messages.json">
// clang-format on
# Please keep this file the same as chrome/browser/resources/.clang-format.
BasedOnStyle: Chromium
# Renaming quotes in <include> and <if> break things.
# For normal JS code, please prefer ' to ".
JavaScriptQuotes: Leave
AllowShortFunctionsOnASingleLine: Empty
......@@ -5,4 +5,10 @@
// This file serves as a proxy to bring the included js file from /third_party
// into its correct location under the resources directory tree, whence it is
// delivered via a chrome://resources URL. See ../webui_resources.grd.
// Note: this <include> is not behind a single-line comment because the first
// line of the file is source code (so the first line would be skipped) instead
// of a licence header.
// clang-format off
<include src="../../../../third_party/analytics/google-analytics-bundle.js">
// clang-format on
......@@ -5,4 +5,10 @@
// This file serves as a proxy to bring the included js file from /third_party
// into its correct location under the resources directory tree, whence it is
// delivered via a chrome://resources URL. See ../webui_resources.grd.
// Note: this <include> is not behind a single-line comment because the first
// line of the file is source code (so the first line would be skipped) instead
// of a licence header.
// clang-format off
<include src="../../../../third_party/jstemplate/jstemplate_compiled.js">
// clang-format on
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment