Add eye icon to left menu button

Summary: Do we have an icon with 2x for the right menu?

Test Plan: {F26590}

Reviewers: chad

Reviewed By: chad

CC: aran

Maniphest Tasks: T1960

Differential Revision: https://secure.phabricator.com/D4101
This commit is contained in:
epriestley
2012-12-07 13:36:35 -08:00
parent 1c9d1d6ad1
commit 8cff6ea9cb
15 changed files with 134 additions and 23 deletions

View File

@@ -204,6 +204,16 @@ $sheets = array(
'gradient' => $generator->buildGradientSheet(),
);
list($err) = exec_manual('optipng');
if ($err) {
$have_optipng = false;
echo phutil_console_format(
"<bg:red> WARNING </bg> `optipng` not found in PATH.\n".
"Sprites will not be optimized! Install `optipng`!\n");
} else {
$have_optipng = true;
}
foreach ($sheets as $name => $sheet) {
$manifest_path = $root.'/resources/sprite/manifest/'.$name.'.json';
if (!$args->getArg('force')) {
@@ -226,7 +236,14 @@ foreach ($sheets as $name => $sheet) {
} else {
$sheet_name = "sprite-{$name}-X{$scale}.png";
}
$sheet->generateImage("{$webroot}/image/{$sheet_name}", $scale);
$full_path = "{$webroot}/image/{$sheet_name}";
$sheet->generateImage($full_path, $scale);
if ($have_optipng) {
echo "Optimizing...\n";
phutil_passthru('optipng -o7 -clobber %s', $full_path);
}
}
}