From ba3a484a655f93329463465d224dfc6ae6494434 Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Thu, 18 Jun 2009 00:12:53 -0700 Subject: [PATCH 1/2] order notices in a conversation --- actions/conversation.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/actions/conversation.php b/actions/conversation.php index 20c68986cb..d3fc5b6a9c 100644 --- a/actions/conversation.php +++ b/actions/conversation.php @@ -217,6 +217,8 @@ class ConversationTree extends NoticeList $this->out->elementStart('ol', array('class' => 'notices')); + sort($children); + foreach ($children as $child) { $this->showNoticePlus($child); } From 65b4cfbb54f5b44820dd02bb9c3c2ca98dbbd321 Mon Sep 17 00:00:00 2001 From: Robin Millette Date: Thu, 18 Jun 2009 06:02:12 -0400 Subject: [PATCH 2/2] Display more oembed info in attachment popup. --- lib/attachmentlist.php | 36 ++++++++++++++++++++++++++++++++++++ theme/base/css/display.css | 6 ++++++ 2 files changed, 42 insertions(+) diff --git a/lib/attachmentlist.php b/lib/attachmentlist.php index 45e4fa3196..a781c3092c 100644 --- a/lib/attachmentlist.php +++ b/lib/attachmentlist.php @@ -244,6 +244,42 @@ class AttachmentListItem extends Widget class Attachment extends AttachmentListItem { + function showLink() { + $this->out->elementStart('a', $this->linkAttr()); + $this->out->element('span', null, $this->linkTitle()); + $this->showRepresentation(); + $this->out->elementEnd('a'); + + if (empty($this->oembed->author_name) && empty($this->oembed->provider)) { + return; + } + + $this->out->elementStart('dl', 'oembed_info'); + + if (!empty($this->oembed->author_name)) { + $this->out->element('dt', null, _('Author:')); + + $this->out->elementStart('dd'); + if (empty($this->oembed->author_url)) { + $this->out->text($this->oembed->author_name); + } else { + $this->out->element('a', array('href' => $this->oembed->author_url), $this->oembed->author_name); + } + $this->out->elementEnd('dd'); + } + if (!empty($this->oembed->provider)) { + $this->out->element('dt', null, _('Provider:')); + $this->out->elementStart('dd'); + if (empty($this->oembed->provider_url)) { + $this->out->text($this->oembed->provider); + } else { + $this->out->element('a', array('href' => $this->oembed->provider_url), $this->oembed->provider); + } + $this->out->elementEnd('dd'); + } + $this->out->elementEnd('dl'); + } + function show() { $this->showNoticeAttachment(); } diff --git a/theme/base/css/display.css b/theme/base/css/display.css index 9e35d015d1..dd787f5e29 100644 --- a/theme/base/css/display.css +++ b/theme/base/css/display.css @@ -1276,3 +1276,9 @@ display:none; .guide { clear:both; } + +dl.oembed_info dt, +dl.oembed_info dd { +display: inline; +} +