WordPress.org

Plugin Directory

Changeset 614263


Ignore:
Timestamp:
10/18/12 21:45:11 (18 months ago)
Author:
automattic
Message:

Monster Widget Version 0.2

  • Create custom cache key for the Recent Posts widget.
  • Only add the Links widget when it has been registered.
  • Bump version number.
  • Update Changelog.
Location:
monster-widget/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • monster-widget/trunk/monster-widget.php

    r544586 r614263  
    33Plugin Name:       Monster Widget 
    44Description:       A widget that allows for quick and easy testing of multiple widgets. Not intended for production use. 
    5 Version:           0.1 
     5Version:           0.2 
    66Author:            Automattic 
    77Author URI:        http://automattic.com/ 
     
    7575            $_instance = ( isset( $widget[1] ) ) ? $widget[1] : null; 
    7676 
     77            // Override cache for the Recent Posts widget. 
     78            if ( 'WP_Widget_Recent_Posts' == $widget[0] ) 
     79                $args['widget_id'] = 'monster-widget-recent-posts-cache-' . self::$iterator; 
     80 
    7781            $args['before_widget'] = sprintf( 
    7882                $before_widget, 
     
    136140                'sortby'  => 'menu_order', 
    137141                'exclude' => '', 
    138             ) ), 
    139             array( 'WP_Widget_Links', array( 
    140                 'title'       => __( 'Links', 'monster-widget' ), 
    141                 'description' => 1, 
    142                 'name'        => 1, 
    143                 'rating'      => 1, 
    144                 'images'      => 1, 
    145142            ) ), 
    146143            array( 'WP_Widget_Meta', array( 
     
    184181        } 
    185182 
     183        global $wp_widget_factory; 
     184        $available_widgets = array_keys( $wp_widget_factory->widgets ); 
     185        if ( in_array( 'WP_Widget_Links', $available_widgets ) ) { 
     186            $widgets[] = array( 'WP_Widget_Links', array( 
     187                'title'       => __( 'Links', 'monster-widget' ), 
     188                'description' => 1, 
     189                'name'        => 1, 
     190                'rating'      => 1, 
     191                'images'      => 1, 
     192            ) ); 
     193        } 
     194 
    186195        return apply_filters( 'monster-widget-config', $widgets ); 
    187196    } 
  • monster-widget/trunk/readme.txt

    r544591 r614263  
    55License: GPLv2 or later 
    66Requires at least: 3.2.0 
    7 Tested up to: 3.4-beta4-20738 
     7Tested up to: 3.5-beta2-22252 
    88Stable tag: trunk 
    99 
     
    2828==Changelog== 
    2929 
     30= v0.2 - October 18th, 2012 = 
     31* Create custom cache key for the Recent Posts widget. 
     32* Only add the Links widget when it has been registered. 
     33* Bump version number. 
     34* Update Changelog. 
     35 
    3036= v0.1 - May 12th, 2012 = 
    31 * Original Release: 
     37* Original Release. 
    3238 
    3339==Installation== 
Note: See TracChangeset for help on using the changeset viewer.