Skip to:
Content

BuddyPress.org

Changeset 9709


Ignore:
Timestamp:
04/06/2015 10:03:24 PM (6 years ago)
Author:
dcavins
Message:

Add arguments to 'widget_title' filter.

Add $instance settings and $id_base to the arguments passed along with the
'widget_title' filter for BP core widgets.

Fixes #6222.

Location:
trunk/src
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-blogs/bp-blogs-widgets.php

    r9469 r9709  
    6161         *
    6262         * @since BuddyPress (2.2.0)
     63         * @since BuddyPress (2.3.0) Added 'instance' and 'id_base' to arguments passed to filter.
    6364         *
    64          * @param string $title The widget title.
     65         * @param string $title    The widget title.
     66         * @param array  $instance The settings for the particular instance of the widget.
     67         * @param string $id_base  Root ID for all widgets of this type.
    6568         */
    66         $title = apply_filters( 'widget_title', $instance['title'] );
     69        $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
    6770
    6871        echo $args['before_widget'];
  • trunk/src/bp-core/bp-core-widgets.php

    r9612 r9709  
    5656         *
    5757         * @since BuddyPress (1.9.0)
     58         * @since BuddyPress (2.3.0) Added 'instance' and 'id_base' to arguments passed to filter.
    5859         *
    59          * @param string $title The widget title.
     60         * @param string $title    The widget title.
     61         * @param array  $instance The settings for the particular instance of the widget.
     62         * @param string $id_base  Root ID for all widgets of this type.
    6063         */
    61         $title = apply_filters( 'widget_title', $title );
     64        $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
    6265
    6366        echo $args['before_widget'];
  • trunk/src/bp-friends/bp-friends-widgets.php

    r9458 r9709  
    8181         *
    8282         * @since BuddyPress (1.8.0)
     83         * @since BuddyPress (2.3.0) Added 'instance' and 'id_base' to arguments passed to filter.
    8384         *
    84          * @param string $title The widget title.
     85         * @param string $title    The widget title.
     86         * @param array  $instance The settings for the particular instance of the widget.
     87         * @param string $id_base  Root ID for all widgets of this type.
    8588         */
    86         $title = apply_filters( 'widget_title', $instance['title'] );
     89        $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
    8790
    8891        echo $before_widget;
  • trunk/src/bp-groups/bp-groups-widgets.php

    r9466 r9709  
    6565         *
    6666         * @since BuddyPress (1.8.0)
    67          *
    68          * @param string $value The widget title.
     67         * @since BuddyPress (2.3.0) Added 'instance' and 'id_base' to arguments passed to filter.
     68         *
     69         * @param string $title    The widget title.
     70         * @param array  $instance The settings for the particular instance of the widget.
     71         * @param string $id_base  Root ID for all widgets of this type.
    6972         */
    70         $title = apply_filters( 'widget_title', $instance['title'] );
     73        $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
    7174
    7275        echo $before_widget;
  • trunk/src/bp-members/bp-members-widgets.php

    r9526 r9709  
    6464         *
    6565         * @since BuddyPress (1.8.0)
     66         * @since BuddyPress (2.3.0) Added 'instance' and 'id_base' to arguments passed to filter.
    6667         *
    67          * @param string $value The widget title.
     68         * @param string $title    The widget title.
     69         * @param array  $instance The settings for the particular instance of the widget.
     70         * @param string $id_base  Root ID for all widgets of this type.
    6871         */
    69         $title = apply_filters( 'widget_title', $instance['title'] );
     72        $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
    7073
    7174        echo $before_widget;
     
    233236         *
    234237         * @since BuddyPress (1.8.0)
     238         * @since BuddyPress (2.3.0) Added 'instance' and 'id_base' to arguments passed to filter.
    235239         *
    236          * @param string $value The widget title.
     240         * @param string $title    The widget title.
     241         * @param array  $instance The settings for the particular instance of the widget.
     242         * @param string $id_base  Root ID for all widgets of this type.
    237243         */
    238         $title = apply_filters( 'widget_title', $instance['title'] );
     244        $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
    239245
    240246        echo $before_widget;
     
    346352         *
    347353         * @since BuddyPress (1.8.0)
     354         * @since BuddyPress (2.3.0) Added 'instance' and 'id_base' to arguments passed to filter.
    348355         *
    349          * @param string $value The widget title.
     356         * @param string $title    The widget title.
     357         * @param array  $instance The settings for the particular instance of the widget.
     358         * @param string $id_base  Root ID for all widgets of this type.
    350359         */
    351         $title = apply_filters( 'widget_title', $instance['title'] );
     360        $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
    352361
    353362        echo $before_widget;
  • trunk/src/bp-messages/bp-messages-widgets.php

    r9216 r9709  
    6868         *
    6969         * @since BuddyPress (1.9.0)
     70         * @since BuddyPress (2.3.0) Added 'instance' and 'id_base' to arguments passed to filter.
    7071         *
    71          * @param string $title The widget title.
     72         * @param string $title    The widget title.
     73         * @param array  $instance The settings for the particular instance of the widget.
     74         * @param string $id_base  Root ID for all widgets of this type.
    7275         */
    73         $title = apply_filters( 'widget_title', $title, $instance );
     76        $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
    7477
    7578        echo $before_widget;
Note: See TracChangeset for help on using the changeset viewer.