Changeset View
Changeset View
Standalone View
Standalone View
src/applications/differential/view/DifferentialChangesetListView.php
| Show First 20 Lines • Show All 140 Lines • ▼ Show 20 Lines | public function render() { | ||||
| $renderer = DifferentialChangesetParser::getDefaultRendererForViewer( | $renderer = DifferentialChangesetParser::getDefaultRendererForViewer( | ||||
| $viewer); | $viewer); | ||||
| $output = array(); | $output = array(); | ||||
| $ids = array(); | $ids = array(); | ||||
| foreach ($changesets as $key => $changeset) { | foreach ($changesets as $key => $changeset) { | ||||
| $file = $changeset->getFilename(); | $file = $changeset->getFilename(); | ||||
| $class = 'differential-changeset'; | |||||
| if (!$this->inlineURI) { | |||||
| $class .= ' differential-changeset-noneditable'; | |||||
| } | |||||
| $ref = $this->references[$key]; | $ref = $this->references[$key]; | ||||
| $detail = id(new DifferentialChangesetDetailView()) | $detail = id(new DifferentialChangesetDetailView()) | ||||
| ->setUser($viewer); | ->setUser($viewer); | ||||
| $uniq_id = 'diff-'.$changeset->getAnchorName(); | $uniq_id = 'diff-'.$changeset->getAnchorName(); | ||||
| $detail->setID($uniq_id); | $detail->setID($uniq_id); | ||||
| ▲ Show 20 Lines • Show All 52 Lines • ▼ Show 20 Lines | public function render() { | ||||
| } | } | ||||
| $this->requireResource('aphront-tooltip-css'); | $this->requireResource('aphront-tooltip-css'); | ||||
| $this->initBehavior( | $this->initBehavior( | ||||
| 'differential-populate', | 'differential-populate', | ||||
| array( | array( | ||||
| 'changesetViewIDs' => $ids, | 'changesetViewIDs' => $ids, | ||||
| 'inlineURI' => $this->inlineURI, | |||||
| 'pht' => array( | 'pht' => array( | ||||
| 'Open in Editor' => pht('Open in Editor'), | 'Open in Editor' => pht('Open in Editor'), | ||||
| 'Show All Context' => pht('Show All Context'), | 'Show All Context' => pht('Show All Context'), | ||||
| 'All Context Shown' => pht('All Context Shown'), | 'All Context Shown' => pht('All Context Shown'), | ||||
| "Can't Toggle Unloaded File" => pht("Can't Toggle Unloaded File"), | "Can't Toggle Unloaded File" => pht("Can't Toggle Unloaded File"), | ||||
| 'Expand File' => pht('Expand File'), | 'Expand File' => pht('Expand File'), | ||||
| 'Collapse File' => pht('Collapse File'), | 'Collapse File' => pht('Collapse File'), | ||||
| 'Browse in Diffusion' => pht('Browse in Diffusion'), | 'Browse in Diffusion' => pht('Browse in Diffusion'), | ||||
| Show All 12 Lines | public function render() { | ||||
| )); | )); | ||||
| $this->initBehavior('differential-comment-jump', array()); | $this->initBehavior('differential-comment-jump', array()); | ||||
| if ($this->inlineURI) { | if ($this->inlineURI) { | ||||
| Javelin::initBehavior('differential-edit-inline-comments', array( | Javelin::initBehavior('differential-edit-inline-comments', array( | ||||
| 'uri' => $this->inlineURI, | 'uri' => $this->inlineURI, | ||||
| 'stage' => 'differential-review-stage', | 'stage' => 'differential-review-stage', | ||||
| 'revealIcon' => hsprintf('%s', new PHUIDiffRevealIconView()), | |||||
| )); | )); | ||||
| } | } | ||||
| if ($this->header) { | if ($this->header) { | ||||
| $header = $this->header; | $header = $this->header; | ||||
| } else { | } else { | ||||
| $header = id(new PHUIHeaderView()) | $header = id(new PHUIHeaderView()) | ||||
| ->setHeader($this->getTitle()); | ->setHeader($this->getTitle()); | ||||
| ▲ Show 20 Lines • Show All 98 Lines • Show Last 20 Lines | |||||