<?php
/**
* StatusNet - the distributed open-source microblogging tool
- * Copyright (C) 2008, 2009, StatusNet, Inc.
+ * Copyright (C) 2008-2011, StatusNet, Inc.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
class AllAction extends ProfileAction
{
var $notice;
+ var $mode = 'conversation';
function isReadOnly($args)
{
{
parent::prepare($args);
- $stream = new ThreadingInboxNoticeStream($this->user, Profile::current());
+ $this->mode = $this->trimmed('mode', 'conversation');
+
+ if ($this->mode == 'stream') {
+ $stream = new InboxNoticeStream($this->user, Profile::current());
+ } else {
+ $stream = new ThreadingInboxNoticeStream($this->user, Profile::current());
+ }
$this->notice = $stream->getNotices(($this->page-1)*NOTICES_PER_PAGE,
NOTICES_PER_PAGE + 1);
$profile = $current_user->getProfile();
}
- $nl = new ThreadedNoticeList($this->notice, $this, $profile);
+ if ($this->mode == 'stream') {
+ $nl = new NoticeList($this->notice, $this);
+ } else {
+ $nl = new ThreadedNoticeList($this->notice, $this, $profile);
+ }
$cnt = $nl->show();