private function canEditInlineComment(PhabricatorUser $user, DifferentialInlineComment $inline)
 {
     // Only the author may edit a comment.
     if ($inline->getAuthorPHID() != $user->getPHID()) {
         return false;
     }
     // Saved comments may not be edited.
     if ($inline->getCommentID()) {
         return false;
     }
     // Inline must be attached to the active revision.
     if ($inline->getRevisionID() != $this->revisionID) {
         return false;
     }
     return true;
 }
 private function renderInlineComment(DifferentialInlineComment $comment)
 {
     $user = $this->user;
     $edit = $user && $comment->getAuthorPHID() == $user->getPHID() && !$comment->getCommentID();
     $on_right = $this->isCommentOnRightSideWhenDisplayed($comment);
     return id(new DifferentialInlineCommentView())->setInlineComment($comment)->setOnRight($on_right)->setHandles($this->handles)->setMarkupEngine($this->markupEngine)->setEditable($edit)->render();
 }