mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-30 01:10:58 +01:00
Rename a constant
Summary: Rename `DifferentialChangesetParser::WHITESPACE_IGNORE_FORCE` to `DifferentialChangesetParser::WHITESPACE_IGNORE_ALL` to better reflect reality. Test Plan: Viewed a diff with various settings for the "Whitespace changes" option. Reviewers: #blessed_reviewers, epriestley Reviewed By: #blessed_reviewers, epriestley Subscribers: epriestley Differential Revision: https://secure.phabricator.com/D11730
This commit is contained in:
parent
84b0c8e6db
commit
d66cbff298
2 changed files with 8 additions and 8 deletions
|
@ -106,7 +106,7 @@ final class DifferentialChangesetParser {
|
|||
const WHITESPACE_SHOW_ALL = 'show-all';
|
||||
const WHITESPACE_IGNORE_TRAILING = 'ignore-trailing';
|
||||
const WHITESPACE_IGNORE_MOST = 'ignore-most';
|
||||
const WHITESPACE_IGNORE_FORCE = 'ignore-force';
|
||||
const WHITESPACE_IGNORE_ALL = 'ignore-all';
|
||||
|
||||
public function setOldLines(array $lines) {
|
||||
$this->old = $lines;
|
||||
|
@ -493,7 +493,7 @@ final class DifferentialChangesetParser {
|
|||
switch ($whitespace_mode) {
|
||||
case self::WHITESPACE_SHOW_ALL:
|
||||
case self::WHITESPACE_IGNORE_TRAILING:
|
||||
case self::WHITESPACE_IGNORE_FORCE:
|
||||
case self::WHITESPACE_IGNORE_ALL:
|
||||
break;
|
||||
default:
|
||||
$whitespace_mode = self::WHITESPACE_IGNORE_MOST;
|
||||
|
@ -537,9 +537,9 @@ final class DifferentialChangesetParser {
|
|||
$changeset = $this->changeset;
|
||||
|
||||
$ignore_all = (($whitespace_mode == self::WHITESPACE_IGNORE_MOST) ||
|
||||
($whitespace_mode == self::WHITESPACE_IGNORE_FORCE));
|
||||
($whitespace_mode == self::WHITESPACE_IGNORE_ALL));
|
||||
|
||||
$force_ignore = ($whitespace_mode == self::WHITESPACE_IGNORE_FORCE);
|
||||
$force_ignore = ($whitespace_mode == self::WHITESPACE_IGNORE_ALL);
|
||||
|
||||
if (!$force_ignore) {
|
||||
if ($ignore_all && $changeset->getWhitespaceMatters()) {
|
||||
|
|
|
@ -205,11 +205,11 @@ final class DifferentialRevisionUpdateHistoryView extends AphrontView {
|
|||
));
|
||||
|
||||
$options = array(
|
||||
DifferentialChangesetParser::WHITESPACE_IGNORE_FORCE => 'Ignore All',
|
||||
DifferentialChangesetParser::WHITESPACE_IGNORE_MOST => 'Ignore Most',
|
||||
DifferentialChangesetParser::WHITESPACE_IGNORE_ALL => pht('Ignore All'),
|
||||
DifferentialChangesetParser::WHITESPACE_IGNORE_MOST => pht('Ignore Most'),
|
||||
DifferentialChangesetParser::WHITESPACE_IGNORE_TRAILING =>
|
||||
'Ignore Trailing',
|
||||
DifferentialChangesetParser::WHITESPACE_SHOW_ALL => 'Show All',
|
||||
pht('Ignore Trailing'),
|
||||
DifferentialChangesetParser::WHITESPACE_SHOW_ALL => pht('Show All'),
|
||||
);
|
||||
|
||||
foreach ($options as $value => $label) {
|
||||
|
|
Loading…
Reference in a new issue