Set an explicit height when drawing the dependent revision graph
Summary: See PHI1900. Recent changes to how commit graphs are drawn made the height automatic in most cases, but it fails in Differential because the element isn't initially visible so the computed height is 0. Just give them an explicit height so they show up again. Test Plan: Viewed graphs in Maniphest, Differential, and Diffusion; saw them all render properly. Differential Revision: https://secure.phabricator.com/D21481
This commit is contained in:
@@ -4,6 +4,7 @@ final class PHUIDiffGraphView extends Phobject {
|
||||
|
||||
private $isHead = true;
|
||||
private $isTail = true;
|
||||
private $height;
|
||||
|
||||
public function setIsHead($is_head) {
|
||||
$this->isHead = $is_head;
|
||||
@@ -23,6 +24,15 @@ final class PHUIDiffGraphView extends Phobject {
|
||||
return $this->isTail;
|
||||
}
|
||||
|
||||
public function setHeight($height) {
|
||||
$this->height = $height;
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getHeight() {
|
||||
return $this->height;
|
||||
}
|
||||
|
||||
public function renderRawGraph(array $parents) {
|
||||
// This keeps our accumulated information about each line of the
|
||||
// merge/branch graph.
|
||||
@@ -205,7 +215,7 @@ final class PHUIDiffGraphView extends Phobject {
|
||||
'diffusion-commit-graph',
|
||||
array(
|
||||
'count' => $count,
|
||||
'autoheight' => true,
|
||||
'height' => $this->getHeight(),
|
||||
));
|
||||
|
||||
return $graph;
|
||||
|
||||
Reference in New Issue
Block a user