question = $question; return $this; } public function setUser($user) { $this->user = $user; return $this; } public function setHandles($handles) { $this->handles = $handles; return $this; } public function render() { require_celerity_resource('ponder-core-view-css'); $question = $this->question; $handles = $this->handles; $user = $this->user; $panel = id(new AphrontPanelView()) ->addClass("ponder-panel") ->setHeader($this->renderObjectLink().' '.$question->getTitle()); $contentview = new PonderCommentBodyView(); $contentview ->setTarget($question) ->setQuestion($question) ->setUser($user) ->setHandles($handles) ->setAction(PonderConstants::ASKED_LITERAL); $panel->appendChild($contentview); return $panel->render(); } private function renderObjectLink() { return phutil_render_tag( 'a', array('href' => '/Q' . $this->question->getID()), "Q". phutil_escape_html($this->question->getID()) ); } }