@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.

Rename "PanelEngine" to "MenuEngine"

Summary: Ref T11957.

Test Plan:
Grepped for "PanelEngine", renamed everything except "PanelEditEngine".

Grepped for these changed symbols:

```
ispanelengineconfigurable
getprofilepanelengine
setprofilepanelengine
setpanelengine
getpanelengine
PhabricatorProfilePanelEditEngine
```

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T11957

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

+45 -44
+6 -6
src/__phutil_library_map__.php
··· 3265 3265 'PhabricatorPeopleProfileController' => 'applications/people/controller/PhabricatorPeopleProfileController.php', 3266 3266 'PhabricatorPeopleProfileEditController' => 'applications/people/controller/PhabricatorPeopleProfileEditController.php', 3267 3267 'PhabricatorPeopleProfileManageController' => 'applications/people/controller/PhabricatorPeopleProfileManageController.php', 3268 - 'PhabricatorPeopleProfilePanelEngine' => 'applications/people/engine/PhabricatorPeopleProfilePanelEngine.php', 3268 + 'PhabricatorPeopleProfileMenuEngine' => 'applications/people/engine/PhabricatorPeopleProfileMenuEngine.php', 3269 3269 'PhabricatorPeopleProfilePictureController' => 'applications/people/controller/PhabricatorPeopleProfilePictureController.php', 3270 3270 'PhabricatorPeopleProfileViewController' => 'applications/people/controller/PhabricatorPeopleProfileViewController.php', 3271 3271 'PhabricatorPeopleQuery' => 'applications/people/query/PhabricatorPeopleQuery.php', ··· 3364 3364 'PhabricatorPolicyType' => 'applications/policy/constants/PhabricatorPolicyType.php', 3365 3365 'PhabricatorPonderApplication' => 'applications/ponder/application/PhabricatorPonderApplication.php', 3366 3366 'PhabricatorProfileMenuCollapsedSetting' => 'applications/settings/setting/PhabricatorProfileMenuCollapsedSetting.php', 3367 + 'PhabricatorProfileMenuEngine' => 'applications/search/engine/PhabricatorProfileMenuEngine.php', 3367 3368 'PhabricatorProfilePanel' => 'applications/search/profilepanel/PhabricatorProfilePanel.php', 3368 3369 'PhabricatorProfilePanelConfiguration' => 'applications/search/storage/PhabricatorProfilePanelConfiguration.php', 3369 3370 'PhabricatorProfilePanelConfigurationQuery' => 'applications/search/query/PhabricatorProfilePanelConfigurationQuery.php', ··· 3371 3372 'PhabricatorProfilePanelConfigurationTransactionQuery' => 'applications/search/query/PhabricatorProfilePanelConfigurationTransactionQuery.php', 3372 3373 'PhabricatorProfilePanelEditEngine' => 'applications/search/editor/PhabricatorProfilePanelEditEngine.php', 3373 3374 'PhabricatorProfilePanelEditor' => 'applications/search/editor/PhabricatorProfilePanelEditor.php', 3374 - 'PhabricatorProfilePanelEngine' => 'applications/search/engine/PhabricatorProfilePanelEngine.php', 3375 3375 'PhabricatorProfilePanelIconSet' => 'applications/search/profilepanel/PhabricatorProfilePanelIconSet.php', 3376 3376 'PhabricatorProfilePanelPHIDType' => 'applications/search/phidtype/PhabricatorProfilePanelPHIDType.php', 3377 3377 'PhabricatorProject' => 'applications/project/storage/PhabricatorProject.php', ··· 3452 3452 'PhabricatorProjectPanelController' => 'applications/project/controller/PhabricatorProjectPanelController.php', 3453 3453 'PhabricatorProjectPointsProfilePanel' => 'applications/project/profilepanel/PhabricatorProjectPointsProfilePanel.php', 3454 3454 'PhabricatorProjectProfileController' => 'applications/project/controller/PhabricatorProjectProfileController.php', 3455 - 'PhabricatorProjectProfilePanelEngine' => 'applications/project/engine/PhabricatorProjectProfilePanelEngine.php', 3455 + 'PhabricatorProjectProfileMenuEngine' => 'applications/project/engine/PhabricatorProjectProfileMenuEngine.php', 3456 3456 'PhabricatorProjectProjectHasMemberEdgeType' => 'applications/project/edge/PhabricatorProjectProjectHasMemberEdgeType.php', 3457 3457 'PhabricatorProjectProjectHasObjectEdgeType' => 'applications/project/edge/PhabricatorProjectProjectHasObjectEdgeType.php', 3458 3458 'PhabricatorProjectProjectPHIDType' => 'applications/project/phid/PhabricatorProjectProjectPHIDType.php', ··· 8331 8331 'PhabricatorPeopleProfileController' => 'PhabricatorPeopleController', 8332 8332 'PhabricatorPeopleProfileEditController' => 'PhabricatorPeopleProfileController', 8333 8333 'PhabricatorPeopleProfileManageController' => 'PhabricatorPeopleProfileController', 8334 - 'PhabricatorPeopleProfilePanelEngine' => 'PhabricatorProfilePanelEngine', 8334 + 'PhabricatorPeopleProfileMenuEngine' => 'PhabricatorProfileMenuEngine', 8335 8335 'PhabricatorPeopleProfilePictureController' => 'PhabricatorPeopleProfileController', 8336 8336 'PhabricatorPeopleProfileViewController' => 'PhabricatorPeopleProfileController', 8337 8337 'PhabricatorPeopleQuery' => 'PhabricatorCursorPagedPolicyAwareQuery', ··· 8450 8450 'PhabricatorPolicyType' => 'PhabricatorPolicyConstants', 8451 8451 'PhabricatorPonderApplication' => 'PhabricatorApplication', 8452 8452 'PhabricatorProfileMenuCollapsedSetting' => 'PhabricatorInternalSetting', 8453 + 'PhabricatorProfileMenuEngine' => 'Phobject', 8453 8454 'PhabricatorProfilePanel' => 'Phobject', 8454 8455 'PhabricatorProfilePanelConfiguration' => array( 8455 8456 'PhabricatorSearchDAO', ··· 8462 8463 'PhabricatorProfilePanelConfigurationTransactionQuery' => 'PhabricatorApplicationTransactionQuery', 8463 8464 'PhabricatorProfilePanelEditEngine' => 'PhabricatorEditEngine', 8464 8465 'PhabricatorProfilePanelEditor' => 'PhabricatorApplicationTransactionEditor', 8465 - 'PhabricatorProfilePanelEngine' => 'Phobject', 8466 8466 'PhabricatorProfilePanelIconSet' => 'PhabricatorIconSet', 8467 8467 'PhabricatorProfilePanelPHIDType' => 'PhabricatorPHIDType', 8468 8468 'PhabricatorProject' => array( ··· 8565 8565 'PhabricatorProjectPanelController' => 'PhabricatorProjectController', 8566 8566 'PhabricatorProjectPointsProfilePanel' => 'PhabricatorProfilePanel', 8567 8567 'PhabricatorProjectProfileController' => 'PhabricatorProjectController', 8568 - 'PhabricatorProjectProfilePanelEngine' => 'PhabricatorProfilePanelEngine', 8568 + 'PhabricatorProjectProfileMenuEngine' => 'PhabricatorProfileMenuEngine', 8569 8569 'PhabricatorProjectProjectHasMemberEdgeType' => 'PhabricatorEdgeType', 8570 8570 'PhabricatorProjectProjectHasObjectEdgeType' => 'PhabricatorEdgeType', 8571 8571 'PhabricatorProjectProjectPHIDType' => 'PhabricatorPHIDType',
+1 -1
src/applications/people/controller/PhabricatorPeopleProfileController.php
··· 36 36 if ($user) { 37 37 $viewer = $this->getViewer(); 38 38 39 - $engine = id(new PhabricatorPeopleProfilePanelEngine()) 39 + $engine = id(new PhabricatorPeopleProfileMenuEngine()) 40 40 ->setViewer($viewer) 41 41 ->setProfileObject($user); 42 42
+1 -1
src/applications/people/controller/PhabricatorPeopleProfileEditController.php
··· 85 85 $crumbs->setBorder(true); 86 86 87 87 $nav = $this->getProfileMenu(); 88 - $nav->selectFilter(PhabricatorPeopleProfilePanelEngine::PANEL_MANAGE); 88 + $nav->selectFilter(PhabricatorPeopleProfileMenuEngine::PANEL_MANAGE); 89 89 90 90 $header = id(new PHUIHeaderView()) 91 91 ->setHeader(pht('Edit Profile: %s', $user->getFullName()))
+1 -1
src/applications/people/controller/PhabricatorPeopleProfileManageController.php
··· 43 43 $name = $user->getUsername(); 44 44 45 45 $nav = $this->getProfileMenu(); 46 - $nav->selectFilter(PhabricatorPeopleProfilePanelEngine::PANEL_MANAGE); 46 + $nav->selectFilter(PhabricatorPeopleProfileMenuEngine::PANEL_MANAGE); 47 47 48 48 $timeline = $this->buildTransactionTimeline( 49 49 $user,
+1 -1
src/applications/people/controller/PhabricatorPeopleProfilePictureController.php
··· 256 256 $crumbs->setBorder(true); 257 257 258 258 $nav = $this->getProfileMenu(); 259 - $nav->selectFilter(PhabricatorPeopleProfilePanelEngine::PANEL_MANAGE); 259 + $nav->selectFilter(PhabricatorPeopleProfileMenuEngine::PANEL_MANAGE); 260 260 261 261 $header = id(new PHUIHeaderView()) 262 262 ->setHeader(pht('Edit Profile Picture'))
+1 -1
src/applications/people/controller/PhabricatorPeopleProfileViewController.php
··· 78 78 )); 79 79 80 80 $nav = $this->getProfileMenu(); 81 - $nav->selectFilter(PhabricatorPeopleProfilePanelEngine::PANEL_PROFILE); 81 + $nav->selectFilter(PhabricatorPeopleProfileMenuEngine::PANEL_PROFILE); 82 82 83 83 $crumbs = $this->buildApplicationCrumbs(); 84 84 $crumbs->setBorder(true);
+3 -3
src/applications/people/engine/PhabricatorPeopleProfilePanelEngine.php src/applications/people/engine/PhabricatorPeopleProfileMenuEngine.php
··· 1 1 <?php 2 2 3 - final class PhabricatorPeopleProfilePanelEngine 4 - extends PhabricatorProfilePanelEngine { 3 + final class PhabricatorPeopleProfileMenuEngine 4 + extends PhabricatorProfileMenuEngine { 5 5 6 6 const PANEL_PROFILE = 'people.profile'; 7 7 const PANEL_MANAGE = 'people.manage'; 8 8 9 - protected function isPanelEngineConfigurable() { 9 + protected function isMenuEngineConfigurable() { 10 10 return false; 11 11 } 12 12
+1 -1
src/applications/project/controller/PhabricatorProjectBoardViewController.php
··· 935 935 $set_default = $request->getBool('default'); 936 936 if ($set_default) { 937 937 $this 938 - ->getProfilePanelEngine() 938 + ->getProfileMenuEngine() 939 939 ->adjustDefault(PhabricatorProject::PANEL_WORKBOARD); 940 940 } 941 941
+11 -10
src/applications/project/controller/PhabricatorProjectController.php
··· 4 4 5 5 private $project; 6 6 private $profileMenu; 7 - private $profilePanelEngine; 7 + private $profileMenuEngine; 8 8 9 9 protected function setProject(PhabricatorProject $project) { 10 10 $this->project = $project; ··· 99 99 100 100 protected function getProfileMenu() { 101 101 if (!$this->profileMenu) { 102 - $engine = $this->getProfilePanelEngine(); 102 + $engine = $this->getProfileMenuEngine(); 103 103 if ($engine) { 104 104 $this->profileMenu = $engine->buildNavigation(); 105 105 } ··· 127 127 return $crumbs; 128 128 } 129 129 130 - protected function getProfilePanelEngine() { 131 - if (!$this->profilePanelEngine) { 130 + protected function getProfileMenuEngine() { 131 + if (!$this->profileMenuEngine) { 132 132 $viewer = $this->getViewer(); 133 133 $project = $this->getProject(); 134 134 if ($project) { 135 - $engine = id(new PhabricatorProjectProfilePanelEngine()) 135 + $engine = id(new PhabricatorProjectProfileMenuEngine()) 136 136 ->setViewer($viewer) 137 137 ->setController($this) 138 138 ->setProfileObject($project); 139 - $this->profilePanelEngine = $engine; 139 + $this->profileMenuEngine = $engine; 140 140 } 141 141 } 142 - return $this->profilePanelEngine; 142 + 143 + return $this->profileMenuEngine; 143 144 } 144 145 145 - protected function setProfilePanelEngine( 146 - PhabricatorProjectProfilePanelEngine $engine) { 147 - $this->profilePanelEngine = $engine; 146 + protected function setProfileMenuEngine( 147 + PhabricatorProjectProfileMenuEngine $engine) { 148 + $this->profileMenuEngine = $engine; 148 149 return $this; 149 150 } 150 151
+2 -2
src/applications/project/controller/PhabricatorProjectPanelController.php
··· 12 12 $viewer = $this->getViewer(); 13 13 $project = $this->getProject(); 14 14 15 - $engine = id(new PhabricatorProjectProfilePanelEngine()) 15 + $engine = id(new PhabricatorProjectProfileMenuEngine()) 16 16 ->setProfileObject($project) 17 17 ->setController($this); 18 18 19 - $this->setProfilePanelEngine($engine); 19 + $this->setProfileMenuEngine($engine); 20 20 21 21 return $engine->buildResponse(); 22 22 }
+1 -1
src/applications/project/controller/PhabricatorProjectViewController.php
··· 17 17 } 18 18 $project = $this->getProject(); 19 19 20 - $engine = $this->getProfilePanelEngine(); 20 + $engine = $this->getProfileMenuEngine(); 21 21 $default = $engine->getDefaultPanel(); 22 22 23 23 switch ($default->getBuiltinKey()) {
+3 -3
src/applications/project/engine/PhabricatorProjectProfilePanelEngine.php src/applications/project/engine/PhabricatorProjectProfileMenuEngine.php
··· 1 1 <?php 2 2 3 - final class PhabricatorProjectProfilePanelEngine 4 - extends PhabricatorProfilePanelEngine { 3 + final class PhabricatorProjectProfileMenuEngine 4 + extends PhabricatorProfileMenuEngine { 5 5 6 - protected function isPanelEngineConfigurable() { 6 + protected function isMenuEngineConfigurable() { 7 7 return true; 8 8 } 9 9
+7 -7
src/applications/search/editor/PhabricatorProfilePanelEditEngine.php
··· 5 5 6 6 const ENGINECONST = 'search.profilepanel'; 7 7 8 - private $panelEngine; 8 + private $menuEngine; 9 9 private $profileObject; 10 10 private $newPanelConfiguration; 11 11 private $isBuiltin; ··· 14 14 return false; 15 15 } 16 16 17 - public function setPanelEngine(PhabricatorProfilePanelEngine $engine) { 18 - $this->panelEngine = $engine; 17 + public function setMenuEngine(PhabricatorProfileMenuEngine $engine) { 18 + $this->menuEngine = $engine; 19 19 return $this; 20 20 } 21 21 22 - public function getPanelEngine() { 23 - return $this->panelEngine; 22 + public function getMenuEngine() { 23 + return $this->menuEngine; 24 24 } 25 25 26 26 public function setProfileObject($profile_object) { ··· 113 113 } 114 114 115 115 protected function getObjectCreateCancelURI($object) { 116 - return $this->getPanelEngine()->getConfigureURI(); 116 + return $this->getMenuEngine()->getConfigureURI(); 117 117 } 118 118 119 119 protected function getObjectViewURI($object) { 120 - return $this->getPanelEngine()->getConfigureURI(); 120 + return $this->getMenuEngine()->getConfigureURI(); 121 121 } 122 122 123 123 protected function buildCustomEditFields($object) {
+6 -6
src/applications/search/engine/PhabricatorProfilePanelEngine.php src/applications/search/engine/PhabricatorProfileMenuEngine.php
··· 1 1 <?php 2 2 3 - abstract class PhabricatorProfilePanelEngine extends Phobject { 3 + abstract class PhabricatorProfileMenuEngine extends Phobject { 4 4 5 5 private $viewer; 6 6 private $profileObject; ··· 49 49 50 50 abstract protected function getPanelURI($path); 51 51 52 - abstract protected function isPanelEngineConfigurable(); 52 + abstract protected function isMenuEngineConfigurable(); 53 53 54 54 public function buildResponse() { 55 55 $controller = $this->getController(); ··· 63 63 64 64 // If the engine is not configurable, don't respond to any of the editing 65 65 // or configuration routes. 66 - if (!$this->isPanelEngineConfigurable()) { 66 + if (!$this->isMenuEngineConfigurable()) { 67 67 switch ($panel_action) { 68 68 case 'view': 69 69 break; ··· 709 709 $controller = $this->getController(); 710 710 711 711 return id(new PhabricatorProfilePanelEditEngine()) 712 - ->setPanelEngine($this) 712 + ->setMenuEngine($this) 713 713 ->setProfileObject($object) 714 714 ->setNewPanelConfiguration($configuration) 715 715 ->setController($controller) ··· 722 722 $controller = $this->getController(); 723 723 724 724 return id(new PhabricatorProfilePanelEditEngine()) 725 - ->setPanelEngine($this) 725 + ->setMenuEngine($this) 726 726 ->setProfileObject($object) 727 727 ->setController($controller) 728 728 ->buildResponse(); ··· 753 753 754 754 return id(new PhabricatorProfilePanelEditEngine()) 755 755 ->setIsBuiltin(true) 756 - ->setPanelEngine($this) 756 + ->setMenuEngine($this) 757 757 ->setProfileObject($object) 758 758 ->setNewPanelConfiguration($configuration) 759 759 ->setController($controller)