Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
10/23/2013 12:14:44 AM (11 years ago)
Author:
boonebgorges
Message:

Improve inline docs in bp-core. See #5022

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/bp-core-widgets.php

    r7450 r7457  
    11<?php
    22/**
    3  * BuddyPress Widgets
     3 * BuddyPress Core Component Widgets.
    44 *
    55 * @package BuddyPress
     
    1010if ( !defined( 'ABSPATH' ) ) exit;
    1111
    12 /* Register widgets for the core component */
     12/**
     13 * Register bp-core widgets.
     14 */
    1315function bp_core_register_widgets() {
    1416    add_action('widgets_init', create_function('', 'return register_widget("BP_Core_Login_Widget");') );
     
    2022
    2123/**
    22  * BuddyPress Login Widget
     24 * BuddyPress Login Widget.
    2325 *
    2426 * @since BuddyPress (1.9.0)
     
    140142}
    141143
    142 /*** MEMBERS WIDGET *****************/
    143 
     144/**
     145 * Members Widget.
     146 */
    144147class BP_Core_Members_Widget extends WP_Widget {
    145148
     149    /**
     150     * Constructor method.
     151     */
    146152    function __construct() {
    147153        $widget_ops = array(
     
    157163    }
    158164
     165    /**
     166     * Display the Members widget.
     167     *
     168     * @see WP_Widget::widget() for description of parameters.
     169     *
     170     * @param array $args Widget arguments.
     171     * @param array $instance Widget settings, as saved by the user.
     172     */
    159173    function widget( $args, $instance ) {
    160174
     
    227241    }
    228242
     243    /**
     244     * Update the Members widget options.
     245     *
     246     * @param array $new_instance The new instance options.
     247     * @param array $old_instance The old instance options.
     248     * @return array $instance The parsed options to be saved.
     249     */
    229250    function update( $new_instance, $old_instance ) {
    230251        $instance = $old_instance;
     
    238259    }
    239260
     261    /**
     262     * Output the Members widget options form.
     263     *
     264     * @param $instance Settings for this widget.
     265     */
    240266    function form( $instance ) {
    241267        $defaults = array(
     
    277303class BP_Core_Whos_Online_Widget extends WP_Widget {
    278304
     305    /**
     306     * Constructor method.
     307     */
    279308    function __construct() {
    280309        $widget_ops = array(
     
    285314    }
    286315
     316    /**
     317     * Display the Who's Online widget.
     318     *
     319     * @see WP_Widget::widget() for description of parameters.
     320     *
     321     * @param array $args Widget arguments.
     322     * @param array $instance Widget settings, as saved by the user.
     323     */
    287324    function widget($args, $instance) {
    288325
     
    316353    }
    317354
     355    /**
     356     * Update the Who's Online widget options.
     357     *
     358     * @param array $new_instance The new instance options.
     359     * @param array $old_instance The old instance options.
     360     * @return array $instance The parsed options to be saved.
     361     */
    318362    function update( $new_instance, $old_instance ) {
    319363        $instance = $old_instance;
     
    324368    }
    325369
     370    /**
     371     * Output the Who's Online widget options form.
     372     *
     373     * @param $instance Settings for this widget.
     374     */
    326375    function form( $instance ) {
    327376        $defaults = array(
     
    346395class BP_Core_Recently_Active_Widget extends WP_Widget {
    347396
     397    /**
     398     * Constructor method.
     399     */
    348400    function __construct() {
    349401        $widget_ops = array(
     
    354406    }
    355407
     408    /**
     409     * Display the Recently Active widget.
     410     *
     411     * @see WP_Widget::widget() for description of parameters.
     412     *
     413     * @param array $args Widget arguments.
     414     * @param array $instance Widget settings, as saved by the user.
     415     */
    356416    function widget( $args, $instance ) {
    357417
     
    385445    }
    386446
     447    /**
     448     * Update the Recently Active widget options.
     449     *
     450     * @param array $new_instance The new instance options.
     451     * @param array $old_instance The old instance options.
     452     * @return array $instance The parsed options to be saved.
     453     */
    387454    function update( $new_instance, $old_instance ) {
    388455        $instance = $old_instance;
     
    393460    }
    394461
     462    /**
     463     * Output the Recently Active widget options form.
     464     *
     465     * @param $instance Settings for this widget.
     466     */
    395467    function form( $instance ) {
    396468        $defaults = array(
     
    411483}
    412484
    413 /** Widget AJAX ******************/
    414 
     485/**
     486 * AJAX request handler for Members widgets.
     487 */
    415488function bp_core_ajax_widget_members() {
    416489
Note: See TracChangeset for help on using the changeset viewer.