@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Search and Replace calls to setShade

Summary: grep for setShade and update to setColor. Add deprecated warning.

Test Plan: Diffusion, Workboards, Maniphest, Project tags, tokenizer, uiexamples

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: Korvin, O14 ATC Monitoring

Differential Revision: https://secure.phabricator.com/D17995

authored by

Chad Little and committed by
chad
00400ae6 3a0a086a

+26 -20
+1 -1
src/applications/calendar/view/PHUIUserAvailabilityView.php
··· 29 29 30 30 $away_tag = id(new PHUITagView()) 31 31 ->setType(PHUITagView::TYPE_SHADE) 32 - ->setShade($color) 32 + ->setColor($color) 33 33 ->setName($name) 34 34 ->setDotColor($color); 35 35
+1 -1
src/applications/conpherence/controller/ConpherenceController.php
··· 71 71 if (strlen($data['topic'])) { 72 72 $topic = id(new PHUITagView()) 73 73 ->setName($data['topic']) 74 - ->setShade(PHUITagView::COLOR_VIOLET) 74 + ->setColor(PHUITagView::COLOR_VIOLET) 75 75 ->setType(PHUITagView::TYPE_SHADE) 76 76 ->addClass('conpherence-header-topic'); 77 77 $header->addTag($topic);
+1 -1
src/applications/differential/constants/DifferentialRevisionStatus.php
··· 65 65 $tag = id(new PHUITagView()) 66 66 ->setName($status_name) 67 67 ->setIcon(self::getRevisionStatusIcon($status)) 68 - ->setShade(self::getRevisionStatusColor($status)) 68 + ->setColor(self::getRevisionStatusColor($status)) 69 69 ->setType(PHUITagView::TYPE_SHADE); 70 70 71 71 return $tag;
+2 -2
src/applications/files/controller/PhabricatorFileInfoController.php
··· 44 44 if ($ttl !== null) { 45 45 $ttl_tag = id(new PHUITagView()) 46 46 ->setType(PHUITagView::TYPE_SHADE) 47 - ->setShade(PHUITagView::COLOR_YELLOW) 47 + ->setColor(PHUITagView::COLOR_YELLOW) 48 48 ->setName(pht('Temporary')); 49 49 $header->addTag($ttl_tag); 50 50 } ··· 53 53 if ($partial) { 54 54 $partial_tag = id(new PHUITagView()) 55 55 ->setType(PHUITagView::TYPE_SHADE) 56 - ->setShade(PHUITagView::COLOR_ORANGE) 56 + ->setColor(PHUITagView::COLOR_ORANGE) 57 57 ->setName(pht('Partial Upload')); 58 58 $header->addTag($partial_tag); 59 59 }
+1 -1
src/applications/harbormaster/view/HarbormasterUnitSummaryView.php
··· 56 56 57 57 $tag = id(new PHUITagView()) 58 58 ->setType(PHUITagView::TYPE_SHADE) 59 - ->setShade($tag_color) 59 + ->setColor($tag_color) 60 60 ->setIcon($tag_icon) 61 61 ->setName($tag_text); 62 62
+1 -1
src/applications/maniphest/constants/ManiphestTaskStatus.php
··· 97 97 ->setName($name) 98 98 ->setIcon($icon) 99 99 ->setType(PHUITagView::TYPE_SHADE) 100 - ->setShade($color); 100 + ->setColor($color); 101 101 102 102 return $tag; 103 103 }
+1 -1
src/applications/owners/engineextension/PhabricatorOwnersHovercardEngineExtension.php
··· 64 64 if ($package->isArchived()) { 65 65 $tag = id(new PHUITagView()) 66 66 ->setName(pht('Archived')) 67 - ->setShade(PHUITagView::COLOR_INDIGO) 67 + ->setColor(PHUITagView::COLOR_INDIGO) 68 68 ->setType(PHUITagView::TYPE_OBJECT); 69 69 $hovercard->addTag($tag); 70 70 }
+1 -1
src/applications/people/view/PhabricatorUserCardView.php
··· 85 85 ->setType(PHUITagView::TYPE_SHADE); 86 86 87 87 if ($tag_shade !== null) { 88 - $tag->setShade($tag_shade); 88 + $tag->setColor($tag_shade); 89 89 } 90 90 91 91 $body = array();
+1 -1
src/applications/project/controller/PhabricatorProjectBoardViewController.php
··· 331 331 332 332 $count_tag = id(new PHUITagView()) 333 333 ->setType(PHUITagView::TYPE_SHADE) 334 - ->setShade(PHUITagView::COLOR_BLUE) 334 + ->setColor(PHUITagView::COLOR_BLUE) 335 335 ->addSigil('column-points') 336 336 ->setName( 337 337 javelin_tag(
+1 -1
src/applications/project/query/PhabricatorProjectSearchEngine.php
··· 211 211 $options[$color] = array( 212 212 id(new PHUITagView()) 213 213 ->setType(PHUITagView::TYPE_SHADE) 214 - ->setShade($color) 214 + ->setColor($color) 215 215 ->setName($name), 216 216 ); 217 217 }
+1 -1
src/applications/project/view/ProjectBoardTaskCard.php
··· 100 100 if ($points !== null) { 101 101 $points_tag = id(new PHUITagView()) 102 102 ->setType(PHUITagView::TYPE_SHADE) 103 - ->setShade(PHUITagView::COLOR_GREY) 103 + ->setColor(PHUITagView::COLOR_GREY) 104 104 ->setSlimShady(true) 105 105 ->setName($points) 106 106 ->addClass('phui-workcard-points');
+1 -1
src/applications/search/query/PhabricatorFulltextToken.php
··· 64 64 65 65 $tag = id(new PHUITagView()) 66 66 ->setType(PHUITagView::TYPE_SHADE) 67 - ->setShade($shade) 67 + ->setColor($shade) 68 68 ->setName($token->getValue()); 69 69 70 70 if ($tip !== null) {
+2 -2
src/applications/uiexample/examples/PHUITagExample.php
··· 187 187 foreach ($outlines as $outline) { 188 188 $tags[] = id(new PHUITagView()) 189 189 ->setType(PHUITagView::TYPE_OUTLINE) 190 - ->setShade($outline) 190 + ->setColor($outline) 191 191 ->setName($outline); 192 192 $tags[] = hsprintf('&nbsp;'); 193 193 $tags[] = id(new PHUITagView()) 194 194 ->setType(PHUITagView::TYPE_OUTLINE) 195 - ->setShade($outline) 195 + ->setColor($outline) 196 196 ->setSlimShady(true) 197 197 ->setName($outline); 198 198 $tags[] = hsprintf('<br /><br />');
+2 -2
src/infrastructure/diff/view/PHUIDiffInlineCommentDetailView.php
··· 148 148 ->setType(PHUITagView::TYPE_SHADE) 149 149 ->setName(pht('Unsubmitted')) 150 150 ->setSlimShady(true) 151 - ->setShade(PHUITagView::COLOR_RED) 151 + ->setColor(PHUITagView::COLOR_RED) 152 152 ->addClass('mml inline-draft-text'); 153 153 } 154 154 ··· 383 383 ->setType(PHUITagView::TYPE_SHADE) 384 384 ->setName(pht('Author')) 385 385 ->setSlimShady(true) 386 - ->setShade(PHUITagView::COLOR_YELLOW) 386 + ->setColor(PHUITagView::COLOR_YELLOW) 387 387 ->addClass('mml'); 388 388 } 389 389 }
+1 -1
src/infrastructure/markup/rule/PhabricatorNavigationRemarkupRule.php
··· 60 60 61 61 $tag = id(new PHUITagView()) 62 62 ->setType(PHUITagView::TYPE_SHADE) 63 - ->setShade($item_color) 63 + ->setColor($item_color) 64 64 ->setName($item_name); 65 65 66 66 if ($item['icon']) {
+1 -1
src/view/phui/PHUIHeaderView.php
··· 131 131 $tag = id(new PHUITagView()) 132 132 ->setName($name) 133 133 ->setIcon($icon) 134 - ->setShade($color) 134 + ->setColor($color) 135 135 ->setType(PHUITagView::TYPE_SHADE); 136 136 137 137 return $this->addProperty(self::PROPERTY_STATUS, $tag);
+7 -1
src/view/phui/PHUITagView.php
··· 57 57 return $this; 58 58 } 59 59 60 - /* Deprecated, use setColor */ 60 + /** 61 + * This method has been deprecated, use @{method:setColor} instead. 62 + * 63 + * @deprecated 64 + */ 61 65 public function setShade($shade) { 66 + phlog( 67 + pht('Deprecated call to setShade(), use setColor() instead.')); 62 68 $this->color = $shade; 63 69 return $this; 64 70 }