Page MenuHomePhabricator

D8305.diff
No OneTemporary

D8305.diff

Index: src/applications/diffusion/controller/DiffusionBrowseFileController.php
===================================================================
--- src/applications/diffusion/controller/DiffusionBrowseFileController.php
+++ src/applications/diffusion/controller/DiffusionBrowseFileController.php
@@ -871,15 +871,23 @@
}
private function buildBinaryCorpus($file_uri, $data) {
- $properties = new PHUIPropertyListView();
- $size = strlen($data);
- $properties->addTextContent(
- pht(
- 'This is a binary file. It is %s byte(s) in length.',
- new PhutilNumber($size)));
+ $size = new PhutilNumber(strlen($data));
+ $text = pht('This is a binary file. It is %s byte(s) in length.', $size);
+ $text = id(new PHUIBoxView())
+ ->addPadding(PHUI::PADDING_LARGE)
+ ->appendChild($text);
+
+ $file = $this->renderFileButton($file_uri);
+ $header = id(new PHUIHeaderView())
+ ->setHeader(pht('Details'))
+ ->addActionLink($file);
+
+ $box = id(new PHUIObjectBoxView())
+ ->setHeader($header)
+ ->appendChild($text);
- return $properties;
+ return $box;
}
private function buildBeforeResponse($before) {

File Metadata

Mime Type
text/plain
Expires
Fri, Oct 25, 7:33 AM (3 w, 4 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6720430
Default Alt Text
D8305.diff (1 KB)

Event Timeline