forked from GNUsocial/gnu-social
Cleaning up Directory plugin lists
This commit is contained in:
parent
ad453785f0
commit
961031bc28
@ -37,7 +37,8 @@ class ProfileListItem extends Widget
|
|||||||
/** Action object using us. */
|
/** Action object using us. */
|
||||||
var $action = null;
|
var $action = null;
|
||||||
|
|
||||||
function __construct(Profile $target, HTMLOutputter $action)
|
// FIXME: Directory plugin sends a User_group here, but should send a Profile and handle User_group specifics itself
|
||||||
|
function __construct($target, HTMLOutputter $action)
|
||||||
{
|
{
|
||||||
parent::__construct($action);
|
parent::__construct($action);
|
||||||
|
|
||||||
|
@ -27,11 +27,7 @@
|
|||||||
* @link http://status.net/
|
* @link http://status.net/
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (!defined('STATUSNET')) {
|
if (!defined('GNUSOCIAL')) { exit(1); }
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
require_once INSTALLDIR . '/lib/subscriptionlist.php';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Widget to show a sortable list of subscriptions
|
* Widget to show a sortable list of subscriptions
|
||||||
@ -44,16 +40,6 @@ require_once INSTALLDIR . '/lib/subscriptionlist.php';
|
|||||||
*/
|
*/
|
||||||
class SortableGroupList extends SortableSubscriptionList
|
class SortableGroupList extends SortableSubscriptionList
|
||||||
{
|
{
|
||||||
/** Owner of this list */
|
|
||||||
var $owner = null;
|
|
||||||
|
|
||||||
function __construct($profile, $owner=null, $action=null)
|
|
||||||
{
|
|
||||||
parent::__construct($profile, $owner, $action);
|
|
||||||
|
|
||||||
$this->owner = $owner;
|
|
||||||
}
|
|
||||||
|
|
||||||
function startList()
|
function startList()
|
||||||
{
|
{
|
||||||
$this->out->elementStart('table', array('class' => 'profile_list xoxo'));
|
$this->out->elementStart('table', array('class' => 'profile_list xoxo'));
|
||||||
@ -119,25 +105,14 @@ class SortableGroupList extends SortableSubscriptionList
|
|||||||
$this->out->elementStart('tbody');
|
$this->out->elementStart('tbody');
|
||||||
}
|
}
|
||||||
|
|
||||||
function newListItem($profile, $odd)
|
function newListItem($profile)
|
||||||
{
|
{
|
||||||
return new SortableGroupListItem($profile, $this->owner, $this->action, $odd);
|
return new SortableGroupListItem($profile, $this->owner, $this->action);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
class SortableGroupListItem extends SortableSubscriptionListItem
|
class SortableGroupListItem extends SortableSubscriptionListItem
|
||||||
{
|
{
|
||||||
/** Owner of this list */
|
|
||||||
var $owner = null;
|
|
||||||
|
|
||||||
function __construct($profile, $owner, $action, $alt)
|
|
||||||
{
|
|
||||||
parent::__construct($profile, $owner, $action, $alt);
|
|
||||||
|
|
||||||
$this->alt = $alt; // is this row alternate?
|
|
||||||
$this->owner = $owner;
|
|
||||||
}
|
|
||||||
|
|
||||||
function showHomepage()
|
function showHomepage()
|
||||||
{
|
{
|
||||||
if (!empty($this->profile->homepage)) {
|
if (!empty($this->profile->homepage)) {
|
||||||
|
@ -40,16 +40,6 @@ if (!defined('GNUSOCIAL')) { exit(1); }
|
|||||||
*/
|
*/
|
||||||
class SortableSubscriptionList extends SubscriptionList
|
class SortableSubscriptionList extends SubscriptionList
|
||||||
{
|
{
|
||||||
/** Owner of this list */
|
|
||||||
var $owner = null;
|
|
||||||
|
|
||||||
function __construct($profile, $owner=null, $action=null)
|
|
||||||
{
|
|
||||||
parent::__construct($profile, $owner, $action);
|
|
||||||
|
|
||||||
$this->owner = $owner;
|
|
||||||
}
|
|
||||||
|
|
||||||
function startList()
|
function startList()
|
||||||
{
|
{
|
||||||
$this->out->elementStart('table', array('class' => 'profile_list xoxo'));
|
$this->out->elementStart('table', array('class' => 'profile_list xoxo'));
|
||||||
@ -132,16 +122,6 @@ class SortableSubscriptionList extends SubscriptionList
|
|||||||
|
|
||||||
class SortableSubscriptionListItem extends SubscriptionListItem
|
class SortableSubscriptionListItem extends SubscriptionListItem
|
||||||
{
|
{
|
||||||
/** Owner of this list */
|
|
||||||
var $owner = null;
|
|
||||||
|
|
||||||
function __construct($profile, $owner, $action)
|
|
||||||
{
|
|
||||||
parent::__construct($profile, $owner, $action);
|
|
||||||
|
|
||||||
$this->owner = $owner;
|
|
||||||
}
|
|
||||||
|
|
||||||
function startItem()
|
function startItem()
|
||||||
{
|
{
|
||||||
$attr = array(
|
$attr = array(
|
||||||
|
Loading…
Reference in New Issue
Block a user