From 076cc6ed7ef87a9981c7f4d1e7df00b24b403da6 Mon Sep 17 00:00:00 2001 From: Chad Little Date: Fri, 6 Mar 2015 17:03:18 -0800 Subject: [PATCH] Change setErrorView to setInfoView in PHUIObjectBoxView Summary: Renames the method in PHUIObjectBoxView to match the new PHUIInfoView class. Test Plan: grepped codebase. Went to Calendar and tried a new status. Reviewers: btrahan, epriestley Reviewed By: epriestley Subscribers: Korvin, epriestley Differential Revision: https://secure.phabricator.com/D12005 --- src/applications/almanac/controller/AlmanacController.php | 2 +- .../controller/config/PhabricatorAuthListController.php | 2 +- .../controller/PhabricatorCalendarViewController.php | 2 +- .../config/controller/PhabricatorConfigEditController.php | 2 +- .../controller/PhabricatorDashboardManageController.php | 2 +- .../controller/DifferentialDiffViewController.php | 2 +- .../controller/DifferentialRevisionViewController.php | 4 ++-- .../differential/view/DifferentialAddCommentView.php | 4 ++-- .../diffusion/controller/DiffusionCommitController.php | 4 ++-- .../diffusion/controller/DiffusionExternalController.php | 2 +- .../query/LegalpadDocumentSignatureSearchEngine.php | 2 +- .../maniphest/controller/ManiphestReportController.php | 2 +- .../controller/ManiphestTaskDetailController.php | 2 +- .../controller/PhabricatorPeopleInviteSendController.php | 2 +- .../phortune/controller/PhortuneCartViewController.php | 2 +- src/view/phui/PHUIObjectBoxView.php | 8 ++++---- src/view/phui/calendar/PHUICalendarMonthView.php | 4 ++-- 17 files changed, 24 insertions(+), 24 deletions(-) diff --git a/src/applications/almanac/controller/AlmanacController.php b/src/applications/almanac/controller/AlmanacController.php index 826bd2793c..df410a254b 100644 --- a/src/applications/almanac/controller/AlmanacController.php +++ b/src/applications/almanac/controller/AlmanacController.php @@ -195,7 +195,7 @@ abstract class AlmanacController array($message, ' ', $doc_link), )); - $box->setErrorView($error_view); + $box->setInfoView($error_view); } } diff --git a/src/applications/auth/controller/config/PhabricatorAuthListController.php b/src/applications/auth/controller/config/PhabricatorAuthListController.php index 52be9e4d88..6af9d69492 100644 --- a/src/applications/auth/controller/config/PhabricatorAuthListController.php +++ b/src/applications/auth/controller/config/PhabricatorAuthListController.php @@ -161,7 +161,7 @@ final class PhabricatorAuthListController $list->setFlush(true); $list = id(new PHUIObjectBoxView()) ->setHeader($header) - ->setErrorView($warning) + ->setInfoView($warning) ->appendChild($list); return $this->buildApplicationPage( diff --git a/src/applications/calendar/controller/PhabricatorCalendarViewController.php b/src/applications/calendar/controller/PhabricatorCalendarViewController.php index d45749b1e2..58ac47af5a 100644 --- a/src/applications/calendar/controller/PhabricatorCalendarViewController.php +++ b/src/applications/calendar/controller/PhabricatorCalendarViewController.php @@ -42,7 +42,7 @@ final class PhabricatorCalendarViewController $month_view->setUser($user); $month_view->setHolidays($holidays); if ($this->getNoticeView()) { - $month_view->setErrorView($this->getNoticeView()); + $month_view->setInfoView($this->getNoticeView()); } $phids = mpull($statuses, 'getUserPHID'); diff --git a/src/applications/config/controller/PhabricatorConfigEditController.php b/src/applications/config/controller/PhabricatorConfigEditController.php index 0d98baeea6..f3360b3496 100644 --- a/src/applications/config/controller/PhabricatorConfigEditController.php +++ b/src/applications/config/controller/PhabricatorConfigEditController.php @@ -202,7 +202,7 @@ final class PhabricatorConfigEditController ->setForm($form); if ($error_view) { - $form_box->setErrorView($error_view); + $form_box->setInfoView($error_view); } $crumbs = $this->buildApplicationCrumbs(); diff --git a/src/applications/dashboard/controller/PhabricatorDashboardManageController.php b/src/applications/dashboard/controller/PhabricatorDashboardManageController.php index c7986f78f5..41028fac61 100644 --- a/src/applications/dashboard/controller/PhabricatorDashboardManageController.php +++ b/src/applications/dashboard/controller/PhabricatorDashboardManageController.php @@ -55,7 +55,7 @@ final class PhabricatorDashboardManageController 'You do not have permission to edit this dashboard. If you want to '. 'make changes, make a copy first.'); - $box->setErrorView( + $box->setInfoView( id(new PHUIInfoView()) ->setSeverity(PHUIInfoView::SEVERITY_NOTICE) ->setErrors(array($no_edit))); diff --git a/src/applications/differential/controller/DifferentialDiffViewController.php b/src/applications/differential/controller/DifferentialDiffViewController.php index a241e03a02..d521c54385 100644 --- a/src/applications/differential/controller/DifferentialDiffViewController.php +++ b/src/applications/differential/controller/DifferentialDiffViewController.php @@ -129,7 +129,7 @@ final class DifferentialDiffViewController extends DifferentialController { $prop_box = id(new PHUIObjectBoxView()) ->setHeader($property_head) ->addPropertyList($property_view) - ->setErrorView($error_view); + ->setInfoView($error_view); return $this->buildApplicationPage( array( diff --git a/src/applications/differential/controller/DifferentialRevisionViewController.php b/src/applications/differential/controller/DifferentialRevisionViewController.php index d8c6b7b383..543c574d58 100644 --- a/src/applications/differential/controller/DifferentialRevisionViewController.php +++ b/src/applications/differential/controller/DifferentialRevisionViewController.php @@ -261,7 +261,7 @@ final class DifferentialRevisionViewController extends DifferentialController { $revision_warnings = id(new PHUIInfoView()) ->setSeverity(PHUIInfoView::SEVERITY_WARNING) ->setErrors($revision_warnings); - $revision_detail_box->setErrorView($revision_warnings); + $revision_detail_box->setInfoView($revision_warnings); } $comment_view = $this->buildTransactions( @@ -389,7 +389,7 @@ final class DifferentialRevisionViewController extends DifferentialController { $review_warnings_panel = id(new PHUIInfoView()) ->setSeverity(PHUIInfoView::SEVERITY_WARNING) ->setErrors($review_warnings); - $comment_form->setErrorView($review_warnings_panel); + $comment_form->setInfoView($review_warnings_panel); } $comment_form->setActions($this->getRevisionCommentActions($revision)); diff --git a/src/applications/differential/view/DifferentialAddCommentView.php b/src/applications/differential/view/DifferentialAddCommentView.php index e11cc9539e..cc84d6034a 100644 --- a/src/applications/differential/view/DifferentialAddCommentView.php +++ b/src/applications/differential/view/DifferentialAddCommentView.php @@ -10,7 +10,7 @@ final class DifferentialAddCommentView extends AphrontView { private $ccs = array(); private $errorView; - public function setErrorView(PHUIInfoView $error_view) { + public function setInfoView(PHUIInfoView $error_view) { $this->errorView = $error_view; return $this; } @@ -188,7 +188,7 @@ final class DifferentialAddCommentView extends AphrontView { ->appendChild($form); if ($this->errorView) { - $comment_box->setErrorView($this->errorView); + $comment_box->setInfoView($this->errorView); } return array($comment_box, $preview); diff --git a/src/applications/diffusion/controller/DiffusionCommitController.php b/src/applications/diffusion/controller/DiffusionCommitController.php index d55fdfbdf4..95b64dea3d 100644 --- a/src/applications/diffusion/controller/DiffusionCommitController.php +++ b/src/applications/diffusion/controller/DiffusionCommitController.php @@ -257,7 +257,7 @@ final class DiffusionCommitController extends DiffusionController { ->appendChild( pht('This commit is very large. Load each file individually.')); - $change_panel->setErrorView($warning_view); + $change_panel->setInfoView($warning_view); $header->addActionLink($button); } @@ -920,7 +920,7 @@ final class DiffusionCommitController extends DiffusionController { $panel->setHeaderText(pht('Merged Changes')); $panel->appendChild($history_table); if ($caption) { - $panel->setErrorView($caption); + $panel->setInfoView($caption); } return $panel; diff --git a/src/applications/diffusion/controller/DiffusionExternalController.php b/src/applications/diffusion/controller/DiffusionExternalController.php index 228cc53e3e..c48553842f 100644 --- a/src/applications/diffusion/controller/DiffusionExternalController.php +++ b/src/applications/diffusion/controller/DiffusionExternalController.php @@ -131,7 +131,7 @@ final class DiffusionExternalController extends DiffusionController { $content = new PHUIObjectBoxView(); $content->setHeaderText(pht('Multiple Matching Commits')); - $content->setErrorView($caption); + $content->setInfoView($caption); $content->appendChild($table); } diff --git a/src/applications/legalpad/query/LegalpadDocumentSignatureSearchEngine.php b/src/applications/legalpad/query/LegalpadDocumentSignatureSearchEngine.php index 5f79d4de0f..c878d92ce4 100644 --- a/src/applications/legalpad/query/LegalpadDocumentSignatureSearchEngine.php +++ b/src/applications/legalpad/query/LegalpadDocumentSignatureSearchEngine.php @@ -301,7 +301,7 @@ final class LegalpadDocumentSignatureSearchEngine 'NOTE: You can only see your own signatures and signatures on '. 'documents you have permission to edit.'), )); - $box->setErrorView($policy_notice); + $box->setInfoView($policy_notice); } return $box; diff --git a/src/applications/maniphest/controller/ManiphestReportController.php b/src/applications/maniphest/controller/ManiphestReportController.php index a3115a1e10..2fd0d90873 100644 --- a/src/applications/maniphest/controller/ManiphestReportController.php +++ b/src/applications/maniphest/controller/ManiphestReportController.php @@ -270,7 +270,7 @@ final class ManiphestReportController extends ManiphestController { $panel = new PHUIObjectBoxView(); $panel->setHeaderText($header); if ($caption) { - $panel->setErrorView($caption); + $panel->setInfoView($caption); } $panel->appendChild($table); diff --git a/src/applications/maniphest/controller/ManiphestTaskDetailController.php b/src/applications/maniphest/controller/ManiphestTaskDetailController.php index 32a71c1b28..26bd81e01c 100644 --- a/src/applications/maniphest/controller/ManiphestTaskDetailController.php +++ b/src/applications/maniphest/controller/ManiphestTaskDetailController.php @@ -351,7 +351,7 @@ final class ManiphestTaskDetailController extends ManiphestController { ->addPropertyList($properties); if ($info_view) { - $object_box->setErrorView($info_view); + $object_box->setInfoView($info_view); } if ($description) { diff --git a/src/applications/people/controller/PhabricatorPeopleInviteSendController.php b/src/applications/people/controller/PhabricatorPeopleInviteSendController.php index d9e7f6366c..2d00177877 100644 --- a/src/applications/people/controller/PhabricatorPeopleInviteSendController.php +++ b/src/applications/people/controller/PhabricatorPeopleInviteSendController.php @@ -158,7 +158,7 @@ final class PhabricatorPeopleInviteSendController } $confirm_box = id(new PHUIObjectBoxView()) - ->setErrorView( + ->setInfoView( id(new PHUIInfoView()) ->setErrors($confirm_errors) ->setSeverity($severity)) diff --git a/src/applications/phortune/controller/PhortuneCartViewController.php b/src/applications/phortune/controller/PhortuneCartViewController.php index 45d90a3a62..da17d3b706 100644 --- a/src/applications/phortune/controller/PhortuneCartViewController.php +++ b/src/applications/phortune/controller/PhortuneCartViewController.php @@ -123,7 +123,7 @@ final class PhortuneCartViewController if ($errors) { $cart_box->setFormErrors($errors); } else if ($error_view) { - $cart_box->setErrorView($error_view); + $cart_box->setInfoView($error_view); } $charges = id(new PhortuneChargeQuery()) diff --git a/src/view/phui/PHUIObjectBoxView.php b/src/view/phui/PHUIObjectBoxView.php index 270a0441a1..a282d928b3 100644 --- a/src/view/phui/PHUIObjectBoxView.php +++ b/src/view/phui/PHUIObjectBoxView.php @@ -6,7 +6,7 @@ final class PHUIObjectBoxView extends AphrontView { private $headerColor; private $formErrors = null; private $formSaved = false; - private $errorView; + private $infoView; private $form; private $validationException; private $header; @@ -113,8 +113,8 @@ final class PHUIObjectBoxView extends AphrontView { return $this; } - public function setErrorView(PHUIInfoView $view) { - $this->errorView = $view; + public function setInfoView(PHUIInfoView $view) { + $this->infoView = $view; return $this; } @@ -269,7 +269,7 @@ final class PHUIObjectBoxView extends AphrontView { ->appendChild( array( $header, - $this->errorView, + $this->infoView, $this->formErrors, $this->formSaved, $exception_errors, diff --git a/src/view/phui/calendar/PHUICalendarMonthView.php b/src/view/phui/calendar/PHUICalendarMonthView.php index 71ed6e67dc..b69128e5e8 100644 --- a/src/view/phui/calendar/PHUICalendarMonthView.php +++ b/src/view/phui/calendar/PHUICalendarMonthView.php @@ -29,7 +29,7 @@ final class PHUICalendarMonthView extends AphrontView { return $this; } - public function setErrorView(PHUIInfoView $error) { + public function setInfoView(PHUIInfoView $error) { $this->error = $error; return $this; } @@ -192,7 +192,7 @@ final class PHUICalendarMonthView extends AphrontView { ->setHeader($this->renderCalendarHeader($first)) ->appendChild($table); if ($this->error) { - $box->setErrorView($this->error); + $box->setInfoView($this->error); }