Differential D19148 Diff 45879 src/applications/harbormaster/controller/HarbormasterBuildLogRenderController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/harbormaster/controller/HarbormasterBuildLogRenderController.php
| Show First 20 Lines • Show All 161 Lines • ▼ Show 20 Lines | foreach ($views as $view_key => $view) { | ||||
| } | } | ||||
| if ($anchor_key === null) { | if ($anchor_key === null) { | ||||
| throw new Exception( | throw new Exception( | ||||
| pht( | pht( | ||||
| 'Unable to find lines.')); | 'Unable to find lines.')); | ||||
| } | } | ||||
| if ($direction > 0) { | if ($view['direction'] > 0) { | ||||
| $slice_offset = $anchor_key; | $slice_offset = $anchor_key; | ||||
| } else { | } else { | ||||
| $slice_offset = max(0, $anchor_key - ($view['lines'] - 1)); | $slice_offset = max(0, $anchor_key - ($view['lines'] - 1)); | ||||
| } | } | ||||
| $slice_length = $view['lines']; | $slice_length = $view['lines']; | ||||
| $views[$view_key] += array( | $views[$view_key] += array( | ||||
| 'sliceKey' => $data_key, | 'sliceKey' => $data_key, | ||||
| ▲ Show 20 Lines • Show All 405 Lines • ▼ Show 20 Lines | $expand_up = javelin_tag( | ||||
| 'tailOffset' => $range['tail'], | 'tailOffset' => $range['tail'], | ||||
| 'head' => 4, | 'head' => 4, | ||||
| 'tail' => 0, | 'tail' => 0, | ||||
| ), | ), | ||||
| ), | ), | ||||
| $up_text); | $up_text); | ||||
| $mid_text = pht( | $mid_text = pht( | ||||
| 'Show More (%s bytes Hidden)', | 'Show More (%s Bytes)', | ||||
| new PhutilNumber($range['tail'] - $range['head'])); | new PhutilNumber($range['tail'] - $range['head'])); | ||||
| $expand_mid = javelin_tag( | $expand_mid = javelin_tag( | ||||
| 'a', | 'a', | ||||
| array( | array( | ||||
| 'sigil' => 'harbormaster-log-expand', | 'sigil' => 'harbormaster-log-expand', | ||||
| 'meta' => array( | 'meta' => array( | ||||
| 'headOffset' => $range['head'], | 'headOffset' => $range['head'], | ||||
| ▲ Show 20 Lines • Show All 68 Lines • Show Last 20 Lines | |||||