forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create vector icon resource directory specific to Chrome.
BUG=626786 Review-Url: https://codereview.chromium.org/2610163003 Cr-Commit-Position: refs/heads/master@{#442183}
- Loading branch information
estade
authored and
Commit bot
committed
Jan 8, 2017
1 parent
197af4a
commit 8283cad
Showing
31 changed files
with
178 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
# Copyright 2017 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. | ||
|
||
action("aggregate_vector_icons") { | ||
visibility = [ ":*" ] | ||
|
||
script = "//ui/gfx/vector_icons/aggregate_vector_icons.py" | ||
|
||
icons = [ | ||
"browser_tools.icon", | ||
"browser_tools_error.icon", | ||
"browser_tools_update.icon", | ||
"navigate_back.1x.icon", | ||
"navigate_back.icon", | ||
"navigate_forward.1x.icon", | ||
"navigate_forward.icon", | ||
"navigate_home.1x.icon", | ||
"navigate_home.icon", | ||
"navigate_reload.1x.icon", | ||
"navigate_reload.icon", | ||
"navigate_stop.1x.icon", | ||
"navigate_stop.icon", | ||
] | ||
|
||
output_cc = "$target_gen_dir/vector_icons.cc" | ||
output_h = "$target_gen_dir/vector_icons.h" | ||
|
||
inputs = icons | ||
inputs += [ | ||
"vector_icons.cc.template", | ||
"vector_icons.h.template", | ||
] | ||
outputs = [ | ||
output_cc, | ||
output_h, | ||
] | ||
|
||
response_file_contents = rebase_path(icons, root_build_dir) | ||
|
||
args = [ | ||
"--working_directory=" + rebase_path("./"), | ||
"--file_list={{response_file_name}}", | ||
"--output_cc=" + rebase_path(output_cc, root_build_dir), | ||
"--output_h=" + rebase_path(output_h, root_build_dir), | ||
] | ||
} | ||
|
||
source_set("vector_icons") { | ||
sources = get_target_outputs(":aggregate_vector_icons") | ||
sources += [ "//ui/gfx/vector_icon_types.h" ] | ||
|
||
deps = [ | ||
":aggregate_vector_icons", | ||
"//base", | ||
"//skia", | ||
] | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
// Copyright 2017 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. | ||
|
||
// vector_icons.cc.template is used to generate vector_icons.cc. Edit the former | ||
// rather than the latter. | ||
|
||
#include "chrome/app/vector_icons/vector_icons.h" | ||
|
||
#include "base/logging.h" | ||
#include "ui/gfx/vector_icon_types.h" | ||
|
||
#define PATH_ELEMENT_TEMPLATE(path_name, ...) \ | ||
static gfx::PathElement path_name[] = {__VA_ARGS__}; | ||
|
||
#define VECTOR_ICON_TEMPLATE(icon_name, path_name, path_name_1x) \ | ||
const gfx::VectorIcon icon_name = { path_name , path_name_1x }; | ||
|
||
using namespace gfx; | ||
|
||
TEMPLATE_PLACEHOLDER |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// Copyright 2017 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. | ||
|
||
// vector_icons.h.template is used to generate vector_icons.h. Edit the former | ||
// rather than the latter. | ||
|
||
#ifndef CHROME_APP_VECTOR_ICONS_VECTOR_ICONS_H_ | ||
#define CHROME_APP_VECTOR_ICONS_VECTOR_ICONS_H_ | ||
|
||
namespace gfx { | ||
struct VectorIcon; | ||
} | ||
|
||
#define VECTOR_ICON_TEMPLATE_H(icon_name) \ | ||
extern const gfx::VectorIcon icon_name; | ||
|
||
TEMPLATE_PLACEHOLDER | ||
|
||
#endif // CHROME_APP_VECTOR_ICONS_VECTOR_ICONS_H_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.