Plugin Directory

Changeset 1361864


Ignore:
Timestamp:
03/01/2016 03:36:00 PM (10 years ago)
Author:
rfgoetz
Message:

5.34 - 3/1/2016

  1. FIXED: How plugin handles archive pages when using Category control options. (thanks to iamjatinkumar for reporting this!)
  2. UPDATED: timepicker.js updated to version 1.6.1 - http://trentrichardson.com/examples/timepicker/
  3. VALIDATED: Version 5.34 supports WordPress 4.4.2
Location:
wp-topbar/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • wp-topbar/trunk/lib/css/jquery-ui-timepicker-addon.css

    r1180497 r1361864  
    77.ui-tpicker-grid-label { background: none; border: none; margin: 0; padding: 0; }
    88.ui-timepicker-div .ui_tpicker_unit_hide{ display: none; }
     9
     10.ui-timepicker-div .ui_tpicker_time .ui_tpicker_time_input { background: none; color: inherit; border: none; outline: none; border-bottom: solid 1px #555; width: 95%; }
     11.ui-timepicker-div .ui_tpicker_time .ui_tpicker_time_input:focus { border-bottom-color: #aaa; }
    912
    1013.ui-timepicker-rtl{ direction: rtl; }
  • wp-topbar/trunk/lib/js/jquery-ui-timepicker-addon.js

    r1180497 r1361864  
    1 /*! jQuery Timepicker Addon - v1.5.3 - 2015-04-19
     1/*! jQuery Timepicker Addon - v1.6.1 - 2015-11-14
    22* http://trentrichardson.com/examples/timepicker
    33* Copyright (c) 2015 Trent Richardson; Licensed MIT
     
    2727jQuery(document).ready(function($) {
    2828
    29 
    3029    /*
    3130    * Lets not redefine timepicker, Prevent "Uncaught RangeError: Maximum call stack size exceeded"
     
    4140    $.extend($.ui, {
    4241        timepicker: {
    43             version: "1.5.3"
     42            version: "1.6.1"
    4443        }
    4544    });
     
    228227            for (i in overrides) {
    229228                if (overrides.hasOwnProperty(i)) {
    230                     fns[i] = opts[i] || null;
     229                    fns[i] = opts[i] || this._defaults[i] || null;
    231230                }
    232231            }
     
    405404            if ($dp.find("div.ui-timepicker-div").length === 0 && o.showTimepicker) {
    406405                var noDisplay = ' ui_tpicker_unit_hide',
    407                     html = '<div class="ui-timepicker-div' + (o.isRTL ? ' ui-timepicker-rtl' : '') + (o.oneLine && o.controlType === 'select' ? ' ui-timepicker-oneLine' : '') + '"><dl>' + '<dt class="ui_tpicker_time_label"' + ((o.showTime) ? '' : noDisplay) + '>' + o.timeText + '</dt>' +
    408                                 '<dd class="ui_tpicker_time '+ ((o.showTime) ? '' : noDisplay) + '"></dd>';
     406                    html = '<div class="ui-timepicker-div' + (o.isRTL ? ' ui-timepicker-rtl' : '') + (o.oneLine && o.controlType === 'select' ? ' ui-timepicker-oneLine' : '') + '"><dl>' + '<dt class="ui_tpicker_time_label' + ((o.showTime) ? '' : noDisplay) + '">' + o.timeText + '</dt>' +
     407                                '<dd class="ui_tpicker_time '+ ((o.showTime) ? '' : noDisplay) + '"><input class="ui_tpicker_time_input" ' + (o.timeInput ? '' : 'disabled') + '/></dd>';
    409408
    410409                // Create the markup
     
    543542                }
    544543
    545                 this.$timeObj = $tp.find('.ui_tpicker_time');
     544                this.$timeObj = $tp.find('.ui_tpicker_time_input');
     545                this.$timeObj.change(function () {
     546                    var timeFormat = tp_inst.inst.settings.timeFormat;
     547                    var parsedTime = $.datepicker.parseTime(timeFormat, this.value);
     548                    var update = new Date();
     549                    if (parsedTime) {
     550                        update.setHours(parsedTime.hour);
     551                        update.setMinutes(parsedTime.minute);
     552                        update.setSeconds(parsedTime.second);
     553                        $.datepicker._setTime(tp_inst.inst, update);
     554                    } else {
     555                        this.value = tp_inst.formattedTime;
     556                        this.blur();
     557                    }
     558                });
    546559
    547560                if (this.inst !== null) {
     
    881894            this.formattedTime = $.datepicker.formatTime(o.timeFormat, this, o);
    882895            if (this.$timeObj) {
     896                var sPos = this.$timeObj[0].selectionStart;
     897                var ePos = this.$timeObj[0].selectionEnd;
    883898                if (pickerTimeFormat === o.timeFormat) {
    884                     this.$timeObj.text(this.formattedTime + pickerTimeSuffix);
     899                    this.$timeObj.val(this.formattedTime + pickerTimeSuffix);
    885900                }
    886901                else {
    887                     this.$timeObj.text($.datepicker.formatTime(pickerTimeFormat, this, o) + pickerTimeSuffix);
    888                 }
     902                    this.$timeObj.val($.datepicker.formatTime(pickerTimeFormat, this, o) + pickerTimeSuffix);
     903                }
     904                this.$timeObj[0].setSelectionRange(sPos, ePos);
    889905            }
    890906
     
    15611577
    15621578    /*
    1563     * override "Today" button to also grab the time.
     1579    * override "Today" button to also grab the time and set it to input field.
    15641580    */
    15651581    $.datepicker._base_gotoToday = $.datepicker._gotoToday;
    15661582    $.datepicker._gotoToday = function (id) {
    1567         var inst = this._getInst($(id)[0]),
    1568             $dp = inst.dpDiv;
     1583        var inst = this._getInst($(id)[0]);
     1584        this._base_gotoToday(id);
    15691585        var tp_inst = this._get(inst, 'timepicker');
    1570         selectLocalTimezone(tp_inst);
     1586        var tzoffset = $.timepicker.timezoneOffsetNumber(tp_inst.timezone);
    15711587        var now = new Date();
     1588        now.setMinutes(now.getMinutes() + now.getTimezoneOffset() + tzoffset);
    15721589        this._setTime(inst, now);
    15731590        this._setDate(inst, now);
    1574         this._base_gotoToday(id);
     1591        tp_inst._onSelectHandler();
    15751592    };
    15761593
     
    22592276    * Keep up with the version
    22602277    */
    2261     $.timepicker.version = "1.5.3";
     2278    $.timepicker.version = "1.6.1";
    22622279
    22632280});
  • wp-topbar/trunk/readme.txt

    r1303092 r1361864  
    33Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YQQURY7VW2B2J
    44Tags: topbar, header bar,beforesite, heads up, fixed bar, link, heads up bar,attention, quick notice, bar, notification bar, popup, self promotion, toolbar, top of the page, plugin, important, message, php
    5 Requires at least: 3.2.1
    6 Tested up to: 4.4
    7 Stable tag: 5.33
     5Requires at least: 3.6
     6Tested up to: 4.4.2
     7Stable tag: 5.34
    88
    99Create MULTIPLE, ROTATABLE TopBars that will be shown at the top of your website.  TopBars are selected by a variety of options - includes scheduler!
     
    210210== Upgrade Notice ==
    211211
    212 = 5.33 =
    213 
    214 Minor fix to remove debug code.
     212= 5.34 =
     213
     214Fix to how plugin handles archive pages when using Category control options.
    215215
    216216
     
    225225
    226226== Changelog ==
     227
     228= 5.34 - 3/1/2016 =
     229
     2301. FIXED: How plugin handles archive pages when using Category control options. (thanks to iamjatinkumar for reporting this!)
     2312. UPDATED: timepicker.js updated to version 1.6.1 - http://trentrichardson.com/examples/timepicker/
     2323. VALIDATED: Version 5.34 supports WordPress 4.4.2
    227233
    228234= 5.33 - 12/08/2015 =
  • wp-topbar/trunk/wp-topbar.php

    r1305647 r1361864  
    55Plugin URI: http://wordpress.org/extend/plugins/wp-topbar/
    66Description:  Create MULTIPLE TopBars that will be shown at the top of your website.  TopBars are selected by a variety of options - includes scheduler, custom PHP, custom CSS and more!
    7 Version: 5.33
     7Version: 5.34
    88Author: Bob Goetz
    99Author URI: http://zwebify.com/wordpress-plugins/
     
    2828
    2929
    30 $WPTB_VERSION = "5.33";
     30$WPTB_VERSION = "5.34";
    3131$WPTB_DB_VERSION = "5.09";  // rev this only when the database structure changes -- also update below in TWO places!
    3232
     
    491491            }
    492492   
    493             if ( $wptbOptions['include_categories'] == 0 )
    494                 $category_id_found = true; 
     493            if ($wptbOptions['include_categories'] == 0)
     494                $category_id_found = true;
    495495            else {
    496496                $category_id_found = false;
    497                 if ( $wptbOptions['include_logic'] != 'page_only' ) {    //skip this logic if we are only checking pages
    498                     foreach((get_the_category($thePostID)) as $category) {
    499                         if ( in_array( $category->cat_ID, explode( ',', $wptbOptions['include_categories'] ) ) ) {
    500                             $category_id_found = true;
    501                             break;
     497                if ($wptbOptions['include_logic'] != 'page_only') {  //skip this logic if we are only checking pages
     498                    if ( is_single() ) {                             // single page
     499                        foreach ((get_the_category($thePostID)) as $category) {
     500                            if (in_array($category->cat_ID, explode(', ', $wptbOptions['include_categories']) )) {
     501                                $category_id_found = true;
     502                                break;
     503                            }
    502504                        }
    503505                    }
    504                     if ( $wptbOptions['invert_categories'] == 'yes' )
    505                          $category_id_found = ! $category_id_found;
     506                    else {                                          // archive page
     507                        $category = get_category( get_query_var( 'cat' ) );
     508                        if (in_array($category->cat_ID, explode(', ', $wptbOptions['include_categories']) ))
     509                                $category_id_found = true;
     510                    }
     511                if ($wptbOptions['invert_categories'] == 'yes') $category_id_found = ! $category_id_found;
    506512                }
    507513            }
     514           
    508515            // check the logic the user selected if not on debug page
    509516                   
Note: See TracChangeset for help on using the changeset viewer.