Plugin Directory

Changeset 511018


Ignore:
Timestamp:
02/27/2012 09:05:32 AM (14 years ago)
Author:
stresslimit
Message:

inital commit of drafts drawer feature, including some css & language fixes

Location:
editorial-calendar/branches/drafts_drawer
Files:
1 added
6 edited
1 moved

Legend:

Unmodified
Added
Removed
  • editorial-calendar/branches/drafts_drawer/edcal.css

    r475474 r511018  
    1414 *
    1515 ******************************************************************************/
    16  
     16
     17/*
     18Table of Contents
     19- Reset
     20- Loading section
     21- Top bar #topbar, including prev/next month arrows at left and Show Today at right
     22- Drafts Drawer
     23- the Calendar Content #calcont
     24  - day head container #dayheadcont [Monday, Tuesday etc]
     25  - edcal scrollable area #edcal_scrollable [the main calendar pane]
     26  - calendar #cal container
     27  - day label table head
     28  - row container .rowcont [absolutely positioned, top adjusted by js]
     29  - row inner .row [positioned relative, within the rowcont
     30  - days
     31  - posts
     32  - tooltip [new/edit posts popover]
     33- Screen options
     34- Feedback section [appears once after using the calendar 3 times]
     35*/
     36
     37/*.row .day:first-child, .dayheadcont .dayhead:first-child {
     38    margin-left:0 !important;
     39}
     40.rowcont { margin:0 !important; }
     41.day { float:left; }
     42*/
     43
     44
     45/* Reset & Utility */
     46
    1747html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td {
    1848    background: none repeat scroll 0 0 transparent;
     
    2252    padding: 0;
    2353}
    24 
    25 #edcal_scrollable {
    26     /* required settings */
    27     position:relative;
    28     overflow:hidden;
    29  
    30     /* This height will be reset with JavaScript */
    31     height: 100%;
    32     margin-top: 5px;
    33     margin-left: 4px;
    34     margin-right: 2px;
    35 }
     54.clearfix:before, .clearfix:after { content:'\0020'; display:block; height:0; visibility:hidden; }
     55.clearfix:after { clear:both; }
     56.clearfix { zoom:1; }
     57
     58
     59
     60/* Loading section */
     61
     62#loadingcont {
     63    position: relative;
     64}
     65
     66#loading, #draftsdrawer_loading {
     67    background-image: url('images/loading.gif');
     68    background-repeat: no-repeat;
     69    position: absolute;
     70    width: 43px;
     71    height: 43px;
     72    display: block;
     73    left: 20em;
     74    top: -1.5em;
     75}
     76
     77.loadingclass > .postlink, .tiploading, .loadingclass:hover > .postlink {
     78    background-image: url('images/loading_post.gif');
     79    background-position: top right;
     80    background-repeat: no-repeat;
     81    cursor: auto;
     82}
     83
     84
     85
     86/* Top bar */
     87
     88#topbar {
     89    margin-bottom: 1em;
     90    margin-top: 1em;
     91    height:2em;
     92}
     93#topbar .tablenav-pages a {
     94    font-weight:normal;
     95}
     96#topleft.tablenav-pages {
     97    float:left;
     98}
     99#nextmonth, #prevmonth {
     100    font-size:12px;
     101}
     102#topright button {
     103    margin-left: 2em;
     104    margin-right: 6px;
     105    text-decoration: none;
     106}
     107
     108
     109
     110/* Drafts Drawer */
     111
     112#draftsdrawer_cont {
     113    height:100%;
     114    float:right;
     115    display:none;
     116}
     117#draftsdrawer {
     118    font-family:"Lucida Grande",Verdana,Arial,"Bitstream Vera Sans",sans-serif;
     119    border:1px solid #dfdfdf;
     120    padding-bottom:1px;
     121    -moz-border-radius:4px;
     122    -webkit-border-radius:4px;
     123    -o-border-radius:4px;
     124    border-radius:4px;
     125}
     126#draftsdrawer .dayheadcont {  }
     127#draftsdrawer .dayhead { float:none; }
     128#draftsdrawer .day { border:0; }
     129#draftsdrawer .dayobj { height:auto; }
     130#draftsdrawer .postlist { top:7px; }
     131#draftsdrawer .posttime { display:none; }
     132#draftsdrawer_loading {
     133    position:relative;
     134    margin:2em 2em 0 2em;
     135    top:0;
     136    left:0;
     137}
     138
     139
     140/* Calendar container */
    36141
    37142#cal_cont, #edcal_scrollable {
     
    47152}
    48153
     154#cal_cont {
     155    border:1px solid #dfdfdf;
     156    padding-bottom:1px;
     157    -moz-border-radius:4px;
     158    -webkit-border-radius:4px;
     159    -o-border-radius:4px;
     160    border-radius:4px;
     161}
     162
     163#edcal_scrollable {
     164    /* required settings */
     165    position:relative;
     166    overflow:hidden;
     167
     168    /* This height will be reset with JavaScript */
     169    height: 100%;
     170    margin-top: 5px;
     171    margin-left: 4px;
     172    margin-right: 2px;
     173}
     174
    49175#cal {
    50176    position:absolute;
    51  
     177
    52178    /* this time we have very large space for the height */
    53179    height:100%;
     
    55181}
    56182
    57 .day {
    58     border: 1px solid #ccc; /* this will add to total height in IE. So, 100% + 2px */
    59     -moz-border-radius:3px;
    60     -webkit-border-radius:3px;
    61     -o-border-radius:3px;
    62     border-radius:3px;
    63     background: white;
    64 }
    65 
    66 .day.beforeToday {
    67     background: #ececec;
    68 /*    background: #f9f9f9;*/
    69 }
    70 
    71 .day.todayAndAfter {
    72     background: #fff;
    73 }
    74 
    75 .day.day-active {
    76     background-color: lightyellow;
    77 }
    78 
    79 .scrollHover {
    80     background: lightblue;
    81 }
    82 
    83 .row {
    84     height: 100%;
    85 }
    86 
    87 .dayobj {
    88     position: relative;
    89     width: 100%;
    90     height: 100%;
    91 }
    92 
    93 .firstOfMonth .dayobj {
    94     background-color: #eaf2fb;
    95     -moz-border-radius:2px;
    96     -webkit-border-radius:2px;
    97     -o-border-radius:2px;
    98     border-radius:2px;
    99 }
    100 
    101 .daylabel {
    102     position: absolute;
    103     top: 0px;
    104     right: 0px;
    105     left: 0px;
    106     font-weight:bold;
    107     text-align: right;
    108     padding-right: 10px;
    109     -moz-border-radius:2px 2px 0 0;
    110     -webkit-border-radius:2px 2px 0 0;
    111     -o-border-radius:2px 2px 0 0;
    112     border-radius:2px 2px 0 0;
    113 }
    114 
    115 .day.month-present .daylabel {
    116     border-bottom:1px solid #dfdfdf;
    117     background:#e9e9e9;
    118     background-image:-moz-linear-gradient(top,#f4f4f4,#e9e9e9);
    119     background-image:-o-linear-gradient(top,#f4f4f4,#e9e9e9);
    120     background-image:-webkit-gradient(linear,left top,left bottom,from(#f4f4f4),to(#e9e9e9));
    121     background-image:-webkit-linear-gradient(top,#f4f4f4,#e9e9e9);
    122     background-image:linear-gradient(top,#f4f4f4,#e9e9e9);
    123 }
    124 
    125 .daynewlink {
    126     position: absolute;
    127     top: 0px;
    128     left: 0px;
    129     display: none;
    130     padding-left: 0.5em;
    131     padding-right: 0.5em;
    132     text-decoration: none;
    133     font-size:10px;
    134     z-index: 10;
    135     overflow: hidden;
    136     height: 1.5em;
    137 }
    138 
    139 .day.today .daylabel {
    140     color: white;
    141 }
    142 
    143 .today .daynewlink {
    144     color: white;
    145 }
    146 
    147 .post {
    148     display: block;
    149     list-style-type: none;
    150     z-index: 10;
    151     margin-left: 2px;
    152     margin-right: 2px;
    153     font-size: 10px;
    154     padding: 0px;
    155 }
    156 
    157 .posttime {
    158     font-weight: bold;
    159 }
    160 
    161 .post.draggable .postlink {
    162     cursor: move;
    163 }
    164 
    165 .post .postactions {
    166     display: none;
    167 }
    168 
    169 .postactions a {
    170   text-decoration:none;
    171 }
    172 
    173 .post .postlink:hover {
    174     color: #d54e21;
    175     background-color: #f5f5f5;
    176 }
    177 
    178 .dayhead {
    179     text-align: left;
    180     text-indent: 5px;
    181     text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
    182     color: #000;
    183     line-height: 2.4em;
    184     min-width: 10em;
    185 }
    186 
    187 .dayheadcont {
     183
     184
     185/* Day label table head */
     186
     187.dayheadcont, .draftsdrawerheadcont {
    188188    position: relative;
    189189    height: 34px;
     
    205205}
    206206
     207.dayhead {
     208    text-align: left;
     209    text-indent: 5px;
     210    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
     211    color: #000;
     212    line-height: 2.4em;
     213    min-width: 10em;
     214    float:left;
     215}
     216
    207217.dayhead.firstday {
    208218    margin-left: 5px;
     
    212222}
    213223
    214 #cal_cont {
    215     border:1px solid #dfdfdf;
    216     padding-bottom:1px;
    217     -moz-border-radius:4px;
    218     -webkit-border-radius:4px;
    219     -o-border-radius:4px;
    220     border-radius:4px;
    221 }
    222 
    223 #topbar {
    224     margin-bottom: 1em;
     224
     225
     226/* Rows */
     227
     228.row {
     229    height: 100%;
     230}
     231
     232
     233
     234/* Days */
     235
     236.day {
     237    border: 1px solid #ccc; /* this will add to total height in IE. So, 100% + 2px */
     238    -moz-border-radius:3px;
     239    -webkit-border-radius:3px;
     240    -o-border-radius:3px;
     241    border-radius:3px;
     242    background: white;
     243}
     244
     245.day.beforeToday {
     246    background: #ececec;
     247/*    background: #f9f9f9;*/
     248}
     249
     250.day.todayAndAfter {
     251    background: #fff;
     252}
     253
     254.day.day-active {
     255    background-color: lightyellow;
     256}
     257
     258.scrollHover {
     259    background: lightblue;
     260}
     261
     262.dayobj {
     263    position: relative;
    225264    width: 100%;
    226     margin-top: 1em;
    227     position: relative;
    228     height: 2em;
    229 }
    230 
    231 #topleft {
     265    height: 100%;
     266}
     267
     268.firstOfMonth .dayobj {
     269    background-color: #eaf2fb;
     270    -moz-border-radius:2px;
     271    -webkit-border-radius:2px;
     272    -o-border-radius:2px;
     273    border-radius:2px;
     274}
     275
     276.daylabel {
    232277    position: absolute;
     278    top: 0px;
     279    right: 0px;
    233280    left: 0px;
    234     top: -14px;
    235     width: auto;
    236 }
    237 
    238 #topright {
     281    font-weight:bold;
     282    text-align: right;
     283    padding-right: 10px;
     284    -moz-border-radius:2px 2px 0 0;
     285    -webkit-border-radius:2px 2px 0 0;
     286    -o-border-radius:2px 2px 0 0;
     287    border-radius:2px 2px 0 0;
     288}
     289
     290.day.month-present .daylabel {
     291    border-bottom:1px solid #dfdfdf;
     292    background:#e9e9e9;
     293    background-image:-moz-linear-gradient(top,#f4f4f4,#e9e9e9);
     294    background-image:-o-linear-gradient(top,#f4f4f4,#e9e9e9);
     295    background-image:-webkit-gradient(linear,left top,left bottom,from(#f4f4f4),to(#e9e9e9));
     296    background-image:-webkit-linear-gradient(top,#f4f4f4,#e9e9e9);
     297    background-image:linear-gradient(top,#f4f4f4,#e9e9e9);
     298}
     299
     300.daynewlink {
    239301    position: absolute;
    240     right: 0px;
    241302    top: 0px;
    242     width: auto;
    243     text-align: right;
    244 }
    245 
    246 #moveToToday {
    247     margin-left: 2em;
    248     margin-right: 6px;
     303    left: 0px;
     304    display: none;
     305    padding-left: 0.5em;
     306    padding-right: 0.5em;
    249307    text-decoration: none;
     308    font-size:10px;
     309    z-index: 10;
     310    overflow: hidden;
     311    height: 1.5em;
     312}
     313
     314.day.today .daylabel {
     315    color: white;
     316}
     317
     318.today .daynewlink {
     319    color: white;
     320}
     321
     322
     323
     324/* Posts */
     325
     326.post {
     327    display: block;
     328    list-style-type: none;
     329    z-index: 10;
     330    margin-left: 2px;
     331    margin-right: 2px;
     332    font-size: 10px;
     333    padding: 0px;
     334}
     335
     336.post .titlewithauthor { display:none; }
     337.post .titlewithoutauthor { display:inline; }
     338.show-author .post .titlewithauthor { display:inline; }
     339.show-author .post .titlewithoutauthor { display:none; }
     340#draftsdrawer .post .titlewithauthor { display:inline; }
     341#draftsdrawer .post .titlewithoutauthor { display:none; }
     342
     343.posttime {
     344    font-weight: bold;
     345}
     346
     347.post.draggable .postlink {
     348    cursor: move;
     349}
     350
     351.post .postactions {
     352    display: none;
     353}
     354
     355.postactions a {
     356  text-decoration:none;
     357}
     358
     359.post .postlink:hover {
     360    color: #d54e21;
     361    background-color: #f5f5f5;
    250362}
    251363
     
    253365    color: #a4a4a4;
    254366    font-weight:normal;
    255 }
    256 
    257 #loadingcont {
    258     position: relative;
    259 }
    260 
    261 #loading {
    262     background-image: url('images/loading.gif');
    263     background-repeat: no-repeat;
    264     position: absolute;
    265     width: 43px;
    266     height: 43px;
    267     display: block;
    268     left: 20em;
    269     top: -1.5em;
    270 }
    271 
    272 .loadingclass > .postlink, .tiploading, .loadingclass:hover > .postlink {
    273     background-image: url('images/loading_post.gif');
    274     background-position: top right;
    275     background-repeat: no-repeat;
    276     cursor: auto;
    277367}
    278368
     
    290380    color: #21759B;
    291381}*/
     382
    292383
    293384
     
    350441}
    351442
    352 #edcal-title {
     443#edcal-title { /* not sure this is being used */
    353444    padding-top: 0.5em;
    354445    padding-bottom: 0.5em;
     
    404495
    405496
    406 #nextmonth, #prevmonth {
    407     /*padding: 0.5em;*/
    408     font-size:12px;
    409 }
     497
     498/* Screen Options */
    410499
    411500#edcal_weeks_pref {
     
    449538}
    450539
    451 
    452540.colorselected {
    453541    opacity: 1;
     
    458546    -webkit-border-radius: 4px;
    459547}
     548
     549#screen-meta #show-edcal-settings-link.show-settings {
     550    background-position: right -1px;
     551}
     552
     553#contextual-help-wrap {
     554    margin-left: 8px;
     555    padding: 0 0 10px;
     556}
     557
     558
     559
     560/* Feedback section */
    460561
    461562#feedbacksection {
     
    486587}
    487588
    488 #screen-meta #show-edcal-settings-link.show-settings {
    489     background-position: right -1px;
    490 }
    491 
    492 #contextual-help-wrap {
    493     margin-left: 8px;
    494     padding: 0 0 10px;
    495 }
    496 
  • editorial-calendar/branches/drafts_drawer/edcal.js

    r503862 r511018  
    210210
    211211    /*
     212     * Initializes the calendar
     213     */
     214    init: function() {
     215         if (jQuery('#edcal_scrollable').length === 0) {
     216             /*
     217              * This means we are on a page without the editorial
     218              * calendar
     219              */
     220             return;
     221         }
     222
     223        edcal.addFeedbackSection();
     224
     225        jQuery('#loading').hide();
     226
     227        jQuery('#edcal_scrollable').css('height', edcal.getCalHeight() + 'px');
     228        edcal.windowHeight = jQuery(window).height();
     229
     230        /*
     231         *  Add the days of the week
     232         */
     233        edcal.createDaysHeader();
     234
     235        /*
     236         * We start by initializting the scrollable.  We use this to manage the
     237         * scrolling of the calendar, but don't actually call it to animate the
     238         * scrolling.  We specify an easing here because the default is "swing"
     239         * and that has a conflict with JavaScript used in the BuddyPress plugin/
     240         *
     241         * This doesn't really change anything since the animation happens offscreen.
     242         */
     243        jQuery('#edcal_scrollable').scrollable({
     244                                    vertical: true,
     245                                    size: edcal.weeksPref,
     246                                    keyboard: false,
     247                                    keyboardSteps: 1,
     248                                    speed: 100,
     249                                    easing: 'linear'
     250                                    });
     251
     252        var api = jQuery('#edcal_scrollable').scrollable();
     253       
     254        api.getConf().keyboard = false;
     255
     256        /*
     257           When the user moves the calendar around we remember their
     258           date and save it in a cookie.  Then we read the cookie back
     259           when we reload so the calendar stays where the user left
     260           it last.
     261         */
     262        var curDate = jQuery.cookie('edcal_date');
     263
     264        if (curDate) {
     265            curDate = Date.parseExact(curDate, 'yyyy-dd-MM');
     266            edcal.output('Resetting to date from the edcal_Date cookie: ' + curDate);
     267        } else {
     268            curDate = Date.today();
     269        }
     270
     271        edcal.moveTo(curDate.clone());
     272       
     273        jQuery('#edcal_scrollable').bind('mousewheel', function(event, delta) {
     274            var dir = delta > 0 ? false : true, vel = Math.abs(delta);
     275            edcal.output(dir + ' at a velocity of ' + vel);
     276
     277            if (!edcal.isMoving && vel > 0.2) {
     278                edcal.move(1, dir);
     279            }
     280           
     281            return false;
     282        });
     283       
     284        /*
     285           We are handling all of our own events so we just cancel all events from
     286           the scrollable.
     287         */
     288        api.onBeforeSeek(function(evt, direction) {
     289            return false;
     290        });
     291
     292        /*
     293         * We also want to listen for a few other key events
     294         */
     295        jQuery(document).bind('keydown', function(evt) {
     296            //if (evt.altKey || evt.ctrlKey) { return; }
     297            //edcal.output("evt.altKey: " + evt.altKey);
     298            //edcal.output("evt.keyCode: " + evt.keyCode);
     299            //edcal.output("evt.ctrlKey: " + evt.ctrlKey);
     300           
     301            if (evt.keyCode === 27) { //escape key
     302                edcal.hideForm();
     303                return false;
     304            }
     305           
     306            if (jQuery('#tooltip').is(':visible')) {
     307                return;
     308            }
     309
     310            if ((evt.keyCode === 40 && !(evt.altKey || evt.ctrlKey))) {        // down arrow key
     311                edcal.move(1, true);
     312                return false;
     313            } else if ((evt.keyCode === 38 && !(evt.altKey || evt.ctrlKey))) { // up arrow key
     314                edcal.move(1, false);
     315                return false;
     316            } else if ((evt.keyCode === 34 && !(evt.altKey || evt.ctrlKey)) || //page down
     317                evt.keyCode === 40 && evt.ctrlKey) {                           // Ctrl+down down arrow
     318                edcal.move(edcal.weeksPref, true);
     319                return false;
     320            } else if ((evt.keyCode === 33 && !(evt.altKey || evt.ctrlKey)) || //page up
     321                evt.keyCode === 38 && evt.ctrlKey) {                           // Ctrl+up up arrow
     322                edcal.move(edcal.weeksPref, false);
     323                return false;
     324            }
     325        });
     326       
     327        edcal.getPosts(edcal.nextStartOfWeek(curDate).add(-3).weeks(),
     328                       edcal.nextStartOfWeek(curDate).add(edcal.weeksPref + 3).weeks());
     329       
     330        /*
     331           Now we bind the listeners for all of our links and the window
     332           resize.
     333         */
     334        jQuery('#moveToToday').click(function() {
     335            edcal.moveTo(Date.today());
     336            edcal.getPosts(edcal.nextStartOfWeek(Date.today()).add(-3).weeks(),
     337                           edcal.nextStartOfWeek(Date.today()).add(edcal.weeksPref + 3).weeks());
     338            return false;
     339        });
     340       
     341        jQuery('#prevmonth').click(function() {
     342            edcal.move(edcal.weeksPref, false);
     343            return false;
     344        });
     345
     346        jQuery('#nextmonth').click(function() {
     347            edcal.move(edcal.weeksPref, true);
     348            return false;
     349        });
     350       
     351        /*
     352           We used to listen to resize events so we could make the calendar the right size
     353           for the current window when it changed size, but this was causing a problem with
     354           WordPress 3.3 and it never worked properly because the scroll position was a little
     355           off so we are just skipping it.
     356         */
     357        /*function resizeWindow(e) {
     358            if (edcal.windowHeight != jQuery(window).height()) {
     359                jQuery('#edcal_scrollable').css('height', edcal.getCalHeight() + 'px');
     360                edcal.windowHeight = jQuery(window).height();
     361                edcal.savePosition();
     362            }
     363        }
     364        jQuery(window).bind('resize', resizeWindow);*/
     365
     366        jQuery('#newPostScheduleButton').live('click', function(evt) {
     367            // if the button is disabled, don't do anything
     368            if (jQuery(this).hasClass('disabled')) {
     369                return false;
     370            }
     371            // Otherwise,
     372            // make sure we can't make duplicate posts by clicking twice quickly
     373            jQuery(this).addClass('disabled');
     374            // and save the post
     375            return edcal.savePost(null, false, true);
     376        });
     377
     378        jQuery('#edcal-title-new-field').bind('keyup', function(evt) {
     379            if (jQuery('#edcal-title-new-field').val().length > 0 && jQuery('#edcal-time').val().length > 0) {
     380                jQuery('#newPostScheduleButton').removeClass('disabled');
     381            } else {
     382                jQuery('#newPostScheduleButton').addClass('disabled');
     383            }
     384
     385            if (evt.keyCode == 13) {    // enter key
     386                /*
     387                 * If the user presses enter we want to save the draft.
     388                 */
     389                return edcal.savePost(null, true);
     390            }
     391        });
     392
     393        jQuery('#edcal-status').bind('change', function(evt) {
     394            edcal.updatePublishButton();
     395        });
     396
     397        jQuery('#edcal_weeks_pref').live('keyup', function(evt) {
     398            if (jQuery('#edcal_weeks_pref').val().length > 0) {
     399                jQuery('#edcal_applyoptions').removeClass('disabled');
     400            } else {
     401                jQuery('#edcal_applyoptions').addClass('disabled');
     402            }
     403
     404            if (evt.keyCode == 13) {    // enter key
     405                edcal.saveOptions();
     406            }
     407
     408        });
     409
     410        edcal.savePosition();
     411
     412        edcal.addOptionsSection();
     413
     414        jQuery('#edcal-time').timePicker({
     415            show24Hours: edcal.timeFormat === 'H:i',
     416            separator: ':',
     417            step: 30
     418        });
     419
     420        jQuery('#showdraftsdrawer').click(function() {
     421            edcal.showhideDraftsDrawer( jQuery(this) );
     422        });
     423    },
     424
     425    /*
     426     * This function shows and hides the drafts drawer. Kind of clunky right now.
     427     * Inits [loads content] only once.
     428     */
     429    showhideDraftsDrawer: function( /*jQuery element*/ showhideElement ) {
     430        var drawerwidth = '13%';
     431        var drawerwidthmargin = '13.5%';
     432        /* tells us if the drafts have been loaded for the first time */
     433        if ( !showhideElement.hasClass('isLoaded') ) {
     434            showhideElement.addClass('isLoaded');
     435            edcal.setupDraftsdrawer();
     436        }
     437        if ( showhideElement.hasClass('showed') ) {
     438            // edcal.output('hiding draftsdrawer');
     439            showhideElement.removeClass('showed');
     440            jQuery('#cal_cont').css({ 'margin-right': '0' });
     441            jQuery('#draftsdrawer_cont').css({ display:'none', width:'0' });
     442            showhideElement.html(edcal.str_showdrafts);
     443        } else {
     444            // edcal.output('showing draftsdrawer');
     445            showhideElement.addClass('showed');
     446            jQuery('#cal_cont').css({ 'margin-right': drawerwidthmargin });
     447            jQuery('#draftsdrawer_cont').css({ display:'block', width:drawerwidth });
     448            showhideElement.html(edcal.str_hidedrafts);
     449        }
     450    },
     451
     452    /*
     453     * Sets up the drafts drawer.
     454     */
     455    setupDraftsdrawer: function() {
     456        jQuery('#draftsdrawer_loading').css({display:'block'});
     457        edcal.getPosts( '00000000', null, edcal.initDraftsdrawer );
     458    },
     459
     460    /*
     461     * Inits the drafts drawer, much like edcal.createRow()
     462     * We could paginate this but right now we're just loading them all.
     463     */
     464    initDraftsdrawer: function() {
     465        var newrow = '';
     466
     467        newrow += '<ul class="postlist">';
     468
     469        newrow += edcal.getPostItems( '00000000' );
     470
     471        newrow += '</ul>';
     472
     473        edcal.draggablePost('#row' + edcal._wDate.toString(edcal.internalDateFormat) + ' li.post');
     474
     475        jQuery('#draftsdrawer div.day').droppable({
     476            hoverClass: 'day-active',
     477            greedy: true,
     478            tolerance: 'pointer',
     479            drop: function(event, ui) {
     480                   // edcal.output('dropped ui.draggable.attr("id"): ' + ui.draggable.attr("id"));
     481                   // edcal.output('dropped on jQuery(this).attr("id"): ' + jQuery(this).attr("id"));
     482                   // edcal.output('ui.draggable.html(): ' + ui.draggable.html());
     483                   // var dayId = 'draftsdrawer';
     484                   var dayId = ui.draggable.parent().parent().parent().attr('id');
     485                   edcal.doDrop(dayId, ui.draggable.attr('id'), jQuery(this).attr('id'));
     486                }
     487            });
     488        jQuery('#unscheduled').append(newrow);
     489        jQuery('#draftsdrawer_loading').css({display:'none'});
     490    },
     491
     492    /*
    212493       This function aligns the grid in two directions.  There
    213494       is a vertical grid with a row of each week and a horizontal
     
    215496     */
    216497    alignGrid: function(/*string*/ gridid, /*int*/ cols, /*int*/ cellWidth, /*int*/ cellHeight, /*int*/ padding) {
     498        if ( jQuery(gridid).parent().attr('id')=='draftsdrawer' )
     499            return;
     500        // console.log(jQuery(gridid).parent().attr('id'));
    217501        var x = 0;
    218502        var y = 0;
    219503        var count = 1;
    220        
     504
    221505        jQuery(gridid).each(function() {
    222506            jQuery(this).css('position', 'relative');
     
    251535   
    252536                    count++;
    253                 }
     537                };
    254538            } else {
    255539                for (var i = children.length - 1; i > -1; i--) {
     
    270554   
    271555                    count++;
    272                 }
     556                };
    273557            }
    274558           
     
    334618         var daystyle;
    335619
    336          if (date.compareTo(Date.today()) === -1) {
     620         if (date.compareTo(Date.today()) == -1) {
    337621             /*
    338622              * Date is before today
     
    360644              */
    361645             monthstyle = 'month-present';
    362          } else if (date.compareTo(edcal.firstDayOfMonth) === 1) {
     646         } else if (date.compareTo(edcal.firstDayOfMonth) == 1) {
    363647             /*
    364648              * Then the date is after the current month
    365649              */
    366650             monthstyle = 'month-future';
    367          } else if (date.compareTo(edcal.firstDayOfNextMonth) === -1) {
     651         } else if (date.compareTo(edcal.firstDayOfNextMonth) == -1) {
    368652             /*
    369653              * Then the date is before the current month
     
    372656         }
    373657
    374          if (date.toString('dd') === '01') {
     658         if (date.toString('dd') == '01') {
    375659             /*
    376660              * This this date is the first day of the month
     
    439723                newrow += '<div class="daylabel">' + _date.toString('d');
    440724            }
    441 
    442725
    443726            newrow += '</div>';
     
    493776            tolerance: 'pointer',
    494777            drop: function(event, ui) {
    495                            //output('dropped ui.draggable.attr("id"): ' + ui.draggable.attr("id"));
    496                            //output('dropped on jQuery(this).attr("id"): ' + jQuery(this).attr("id"));
    497                            //output('ui.draggable.html(): ' + ui.draggable.html());
    498 
    499                            var dayId = ui.draggable.parent().parent().parent().attr('id');
    500 
    501                            edcal.doDrop(dayId, ui.draggable.attr('id'), jQuery(this).attr('id'));
    502                         }
     778                   // edcal.output('dropped ui.draggable.attr("id"): ' + ui.draggable.attr("id"));
     779                   // edcal.output('dropped on jQuery(this).attr("id"): ' + jQuery(this).attr("id"));
     780                   // edcal.output('ui.draggable.html(): ' + ui.draggable.html());
     781                   var dayId = ui.draggable.parent().parent().parent().attr('id');
     782                   // edcal.output('dayId: ' + dayId);
     783                   edcal.doDrop(dayId, ui.draggable.attr('id'), jQuery(this).attr('id'));
     784                }
    503785            });
    504786
     
    542824
    543825         // Step 3. Add the item to the new DOM parent
     826         // Step 3a. Check whether we dropped it on a day or on the Drafts Drawer
    544827         jQuery('#' + newDate + ' .postlist').append(edcal.createPostItem(post, newDate));
    545828
     
    594877     */
    595878    handleDrag: function(event, ui) {
    596          if (edcal.isMoving || edcal.isDragScrolling) {
     879         if (edcal.isMoving || edcal.isDragScrolling
     880             /*
     881                TODO: make sure that if we are on top of the drafts drawer
     882                we don't dragScroll.
     883             */
     884             ) {
    597885             return;
    598886         }
     
    653941          * significantly faster.  Especially on IE.
    654942          */
     943         // edcal.output('post.id: '+post.id+'\ndayobjId: '+dayobjId);
    655944         jQuery('#' + dayobjId + ' > div > ul').append(edcal.createPostItem(post, dayobjId));
    656945    },
     
    706995
    707996
    708 
    709 
    710997    /*
    711998     * Confirms if you want to delete the specified post
     
    7441031        var date = jQuery(this).parent().parent().attr('id');
    7451032
    746         var formattedtime = '10:00';
    747         if (edcal.timeFormat !== 'H:i' && edcal.timeFormat !== 'G:i') {
     1033        var formattedtime = edcal.defaultTime;
     1034        if (edcal.timeFormat !== 'H:i') {
    7481035            formattedtime += ' AM';
    7491036        }
     
    7891076
    7901077         if (!post.title || post.title === '') {
    791              return false;
     1078             return;
    7921079         }
    7931080
     
    8551142                        edcal.showError(edcal.checksum_error);
    8561143                    }
    857                     return false;
     1144                    return;
    8581145                }
    8591146
     
    8811168                    callback(res);
    8821169                }
    883                
    884                 return true;
    8851170            },
    8861171            error: function(xhr) {
     
    10401325     */
    10411326    findPostForId: function(/*string*/ dayobjId, /*string*/ postId) {
    1042         if (edcal.posts[dayobjId]) {
     1327         if (edcal.posts[dayobjId]) {
    10431328            for (var i = 0; i < edcal.posts[dayobjId].length; i++) {
    10441329                if (edcal.posts[dayobjId][i] &&
     
    10481333            }
    10491334        }
    1050          
    1051         return null;
    10521335    },
    10531336
     
    10601343                 if (edcal.posts[dayobjId][i] &&
    10611344                     'post-' + edcal.posts[dayobjId][i].id === postId) {
     1345                         edcal.output('(#' + postId+').remove()  -  post-'+edcal.posts[dayobjId][i].id);
    10621346                     edcal.posts[dayobjId][i] = null;
    10631347                     jQuery('#' + postId).remove();
     
    11921476         }
    11931477
    1194          if (edcal.authorPref) {
    1195              posttitle = sprintf(edcal.str_by, posttitle, '<span class="postauthor">' + post.author + '</span>');
    1196          }
     1478         posttitlewithauthor = sprintf(edcal.str_by, posttitle, '<span class="postauthor">' + post.author + '</span>');
    11971479
    11981480         var classString = '';
     
    12011483             return '<li onmouseover="edcal.showActionLinks(\'post-' + post.id + '\');" ' +
    12021484                 'onmouseout="edcal.hideActionLinks(\'post-' + post.id + '\');" ' +
    1203                  'id="post-' + post.id + '" class="post ' + post.status + ' ' + edcal.getPostEditableClass(post) + '"><div class="postlink ' + classString + '">' + posttitle + '</div>' +
     1485                 'id="post-' + post.id + '" class="post ' + post.status + ' ' + edcal.getPostEditableClass(post) + '"><div class="postlink ' + classString + '">' +
     1486                     '<span class="titlewithoutauthor">' + posttitle + '</span>' +
     1487                     '<span class="titlewithauthor">' + posttitlewithauthor + '</span>' +
     1488                   '</div>' +
    12041489                 '<div class="postactions">' +
    12051490                 '<a href="' + post.editlink + '">' + edcal.str_edit + '</a> | ' +
    12061491                 '<a href="#" onclick="edcal.editPost(' + post.id + '); return false;">' + edcal.str_quick_edit + '</a> | ' +
    12071492                 '<a href="' + post.dellink + '" onclick="return edcal.confirmDelete(\'' + post.title + '\');">' + edcal.str_del + '</a> | ' +
    1208                  '<a href="' + post.permalink + '">' + edcal.str_view + '</a>' +
     1493                 '<a href="' + post.permalink + '"' +
     1494                   // ' onclick="edcal.getPost('+post.id+',function(r){ edcal.output(r) }); return false;"' + // for debugging
     1495                 '>' + edcal.str_view + '</a>' +
    12091496                 '</div></li>';
    12101497         } else {
    12111498             return '<li onmouseover="edcal.showActionLinks(\'post-' + post.id + '\');" ' +
    12121499                 'onmouseout="edcal.hideActionLinks(\'post-' + post.id + '\');" ' +
    1213                  'id="post-' + post.id + '" class="post ' + post.status + ' ' + edcal.getPostEditableClass(post) + '"><div class="postlink ' + classString + '">' + posttitle + '</div>' +
     1500                 'id="post-' + post.id + '" class="post ' + post.status + ' ' + edcal.getPostEditableClass(post) + '"><div class="postlink ' + classString + '">' +
     1501                     '<span class="titlewithoutauthor">' + posttitle + '</span>' +
     1502                     '<span class="titlewithauthor">' + posttitlewithauthor + '</span>' +
     1503                   '</div>' +
    12141504                 '<div class="postactions">' +
    12151505                 '<a href="' + post.editlink + '">' + edcal.str_republish + '</a> | ' +
     
    15431833    savePosition: function() {
    15441834         var cal = jQuery('#edcal_scrollable');
     1835         var cal_cont = jQuery('#cal_cont');
    15451836         edcal.position = {
    15461837             top: cal.offset().top,
     
    15811872                               '}' +
    15821873                               '</style>');
     1874         jQuery('#draftsdrawer').css({height:cal_cont.height()});
     1875         jQuery('#draftsdrawer .postlist').css({height:cal.height()});
    15831876    },
    15841877
     
    16391932
    16401933    /*
    1641      * Initializes the calendar
    1642      */
    1643     init: function() {
    1644          if (jQuery('#edcal_scrollable').length === 0) {
    1645              /*
    1646               * This means we are on a page without the editorial
    1647               * calendar
    1648               */
    1649              return;
    1650          }
    1651 
    1652         edcal.addFeedbackSection();
    1653 
    1654         jQuery('#loading').hide();
    1655 
    1656         jQuery('#edcal_scrollable').css('height', edcal.getCalHeight() + 'px');
    1657         edcal.windowHeight = jQuery(window).height();
    1658 
    1659         /*
    1660          *  Add the days of the week
    1661          */
    1662         edcal.createDaysHeader();
    1663 
    1664         /*
    1665          * We start by initializting the scrollable.  We use this to manage the
    1666          * scrolling of the calendar, but don't actually call it to animate the
    1667          * scrolling.  We specify an easing here because the default is "swing"
    1668          * and that has a conflict with JavaScript used in the BuddyPress plugin/
    1669          *
    1670          * This doesn't really change anything since the animation happens offscreen.
    1671          */
    1672         jQuery('#edcal_scrollable').scrollable({
    1673                                     vertical: true,
    1674                                     size: edcal.weeksPref,
    1675                                     keyboard: false,
    1676                                     keyboardSteps: 1,
    1677                                     speed: 100,
    1678                                     easing: 'linear'
    1679                                     });
    1680 
    1681         var api = jQuery('#edcal_scrollable').scrollable();
    1682        
    1683         api.getConf().keyboard = false;
    1684 
    1685         /*
    1686            When the user moves the calendar around we remember their
    1687            date and save it in a cookie.  Then we read the cookie back
    1688            when we reload so the calendar stays where the user left
    1689            it last.
    1690          */
    1691         var curDate = jQuery.cookie('edcal_date');
    1692 
    1693         if (curDate) {
    1694             curDate = Date.parseExact(curDate, 'yyyy-dd-MM');
    1695             edcal.output('Resetting to date from the edcal_Date cookie: ' + curDate);
    1696         } else {
    1697             curDate = Date.today();
    1698         }
    1699 
    1700         edcal.moveTo(curDate.clone());
    1701        
    1702         jQuery('#edcal_scrollable').bind('mousewheel', function(event, delta) {
    1703             var dir = delta > 0 ? false : true, vel = Math.abs(delta);
    1704             edcal.output(dir + ' at a velocity of ' + vel);
    1705 
    1706             if (!edcal.isMoving && vel > 0.2) {
    1707                 edcal.move(1, dir);
    1708             }
    1709            
    1710             return false;
    1711         });
    1712        
    1713         /*
    1714            We are handling all of our own events so we just cancel all events from
    1715            the scrollable.
    1716          */
    1717         api.onBeforeSeek(function(evt, direction) {
    1718             return false;
    1719         });
    1720 
    1721         /*
    1722          * We also want to listen for a few other key events
    1723          */
    1724         jQuery(document).bind('keydown', function(evt) {
    1725             //if (evt.altKey || evt.ctrlKey) { return; }
    1726             //output("evt.altKey: " + evt.altKey);
    1727             //output("evt.keyCode: " + evt.keyCode);
    1728             //output("evt.ctrlKey: " + evt.ctrlKey);
    1729            
    1730             if (evt.keyCode === 27) { //escape key
    1731                 edcal.hideForm();
    1732                 return false;
    1733             }
    1734            
    1735             if (jQuery('#tooltip').is(':visible')) {
    1736                 return false;
    1737             }
    1738 
    1739             if ((evt.keyCode === 40 && !(evt.altKey || evt.ctrlKey))) {        // down arrow key
    1740                 edcal.move(1, true);
    1741                 return false;
    1742             } else if ((evt.keyCode === 38 && !(evt.altKey || evt.ctrlKey))) { // up arrow key
    1743                 edcal.move(1, false);
    1744                 return false;
    1745             } else if ((evt.keyCode === 34 && !(evt.altKey || evt.ctrlKey)) || //page down
    1746                 evt.keyCode === 40 && evt.ctrlKey) {                           // Ctrl+down down arrow
    1747                 edcal.move(edcal.weeksPref, true);
    1748                 return false;
    1749             } else if ((evt.keyCode === 33 && !(evt.altKey || evt.ctrlKey)) || //page up
    1750                 evt.keyCode === 38 && evt.ctrlKey) {                           // Ctrl+up up arrow
    1751                 edcal.move(edcal.weeksPref, false);
    1752                 return false;
    1753             }
    1754            
    1755             return true;
    1756         });
    1757        
    1758         edcal.getPosts(edcal.nextStartOfWeek(curDate).add(-3).weeks(),
    1759                        edcal.nextStartOfWeek(curDate).add(edcal.weeksPref + 3).weeks());
    1760        
    1761         /*
    1762            Now we bind the listeners for all of our links and the window
    1763            resize.
    1764          */
    1765         jQuery('#moveToToday').click(function() {
    1766             edcal.moveTo(Date.today());
    1767             edcal.getPosts(edcal.nextStartOfWeek(Date.today()).add(-3).weeks(),
    1768                            edcal.nextStartOfWeek(Date.today()).add(edcal.weeksPref + 3).weeks());
    1769             return false;
    1770         });
    1771        
    1772         jQuery('#prevmonth').click(function() {
    1773             edcal.move(edcal.weeksPref, false);
    1774             return false;
    1775         });
    1776 
    1777         jQuery('#nextmonth').click(function() {
    1778             edcal.move(edcal.weeksPref, true);
    1779             return false;
    1780         });
    1781        
    1782         /*
    1783            We used to listen to resize events so we could make the calendar the right size
    1784            for the current window when it changed size, but this was causing a problem with
    1785            WordPress 3.3 and it never worked properly because the scroll position was a little
    1786            off so we are just skipping it.
    1787          */
    1788         /*function resizeWindow(e) {
    1789             if (edcal.windowHeight != jQuery(window).height()) {
    1790                 jQuery('#edcal_scrollable').css('height', edcal.getCalHeight() + 'px');
    1791                 edcal.windowHeight = jQuery(window).height();
    1792                 edcal.savePosition();
    1793             }
    1794         }
    1795         jQuery(window).bind('resize', resizeWindow);*/
    1796 
    1797         jQuery('#newPostScheduleButton').live('click', function(evt) {
    1798             // if the button is disabled, don't do anything
    1799             if (jQuery(this).hasClass('disabled')) {
    1800                 return false;
    1801             }
    1802             // Otherwise,
    1803             // make sure we can't make duplicate posts by clicking twice quickly
    1804             jQuery(this).addClass('disabled');
    1805             // and save the post
    1806             return edcal.savePost(null, false, true);
    1807         });
    1808 
    1809         jQuery('#edcal-title-new-field').bind('keyup', function(evt) {
    1810             if (jQuery('#edcal-title-new-field').val().length > 0 && jQuery('#edcal-time').val().length > 0) {
    1811                 jQuery('#newPostScheduleButton').removeClass('disabled');
    1812             } else {
    1813                 jQuery('#newPostScheduleButton').addClass('disabled');
    1814             }
    1815 
    1816             if (evt.keyCode == 13) {    // enter key
    1817                 /*
    1818                  * If the user presses enter we want to save the draft.
    1819                  */
    1820                 return edcal.savePost(null, true);
    1821             }
    1822         });
    1823 
    1824         jQuery('#edcal-status').bind('change', function(evt) {
    1825             edcal.updatePublishButton();
    1826         });
    1827 
    1828         jQuery('#edcal_weeks_pref').live('keyup', function(evt) {
    1829             if (jQuery('#edcal_weeks_pref').val().length > 0) {
    1830                 jQuery('#edcal_applyoptions').removeClass('disabled');
    1831             } else {
    1832                 jQuery('#edcal_applyoptions').addClass('disabled');
    1833             }
    1834 
    1835             if (evt.keyCode == 13) {    // enter key
    1836                 edcal.saveOptions();
    1837             }
    1838 
    1839         });
    1840 
    1841         edcal.savePosition();
    1842 
    1843         edcal.addOptionsSection();
    1844 
    1845         jQuery('#edcal-time').timePicker({
    1846             show24Hours: edcal.timeFormat === 'H:i' || edcal.timeFormat === 'G:i',
    1847             separator: ':',
    1848             step: 30
    1849         });
    1850     },
    1851 
    1852     /*
    18531934       This function updates the text of te publish button in the quick
    18541935       edit dialog to match the current operation.
     
    18701951    changeDate: function(/*string*/ newdate, /*Post*/ post, /*function*/ callback) {
    18711952         edcal.output('Changing the date of "' + post.title + '" to ' + newdate);
    1872          var newdateFormatted = edcal.getDayFromDayId(newdate).toString(edcal.wp_dateFormat);
     1953         var move_to_drawer = newdate=='00000000';
     1954         var move_from_drawer = post.date=='00000000';
     1955         var newdateFormatted = move_to_drawer ? '0000-00-00' : edcal.getDayFromDayId(newdate).toString(edcal.wp_dateFormat);
     1956         // edcal.output('newdate='+newdate+'\nnewdateFormatted='+newdateFormatted);
     1957         var olddate = move_from_drawer ? post.date : edcal.getDayFromDayId(post.date).toString(edcal.wp_dateFormat);
    18731958
    18741959         var url = edcal.ajax_url() + '&action=edcal_changedate&postid=' + post.id +
    18751960             '&postStatus=' + post.status +
    1876              '&newdate=' + newdateFormatted + '&olddate=' + edcal.getDayFromDayId(post.date).toString(edcal.wp_dateFormat);
     1961             '&newdate=' + newdateFormatted + '&olddate=' + olddate;
    18771962
    18781963         jQuery('#post-' + post.id).addClass('loadingclass');
     
    18831968            processData: false,
    18841969            timeout: 100000,
     1970            // dataType: 'text',
    18851971            dataType: 'json',
    18861972            success: function(res) {
     1973                edcal.output('res.post.date='+res.post.date);
     1974                edcal.output(res.post);
     1975                // console.log(res.post);
    18871976                if (res.error) {
    18881977                    /*
     
    19001989                }
    19011990
    1902                 edcal.removePostItem(res.post.date, 'post-' + res.post.id);
    1903                 edcal.addPostItem(res.post, res.post.date);
    1904                 edcal.addPostItemDragAndToolltip(res.post.date);
     1991                // edcal.output(res.post.date);
     1992                // var container = newdateFormatted == '0000-00-00' ?
     1993
     1994                var removecont = move_to_drawer ? '00000000' : res.post.date;
     1995                var addcont = move_from_drawer ? newdate : removecont;
     1996                if ( res.post.date_gmt=='01011970' ) {
     1997                    // do somthing else
     1998                }
     1999
     2000                edcal.removePostItem(removecont, 'post-' + res.post.id);
     2001                // edcal.output('remove post from: '+removecont+', add post to: '+addcont);
     2002                edcal.addPostItem(res.post, addcont);
     2003                edcal.addPostItemDragAndToolltip(addcont);
    19052004
    19062005                if (callback) {
     
    19262025     */
    19272026    getPosts: function(/*Date*/ from, /*Date*/ to, /*function*/ callback) {
    1928          edcal.output('Getting posts from ' + from + ' to ' + to);
     2027         if ( !to )
     2028             to = '';
     2029         // edcal.output('Getting posts from ' + from + ' to ' + to);
    19292030
    19302031         var shouldGet = edcal.cacheDates[from];
     
    19362037              * it somewhat, but we could get much better about this.
    19372038              */
    1938              edcal.output('Using cached results for posts from ' + from.toString('dd-MMM-yyyy') + ' to ' + to.toString('dd-MMM-yyyy'));
     2039             // edcal.output('Using cached results for posts from ' + from.toString('dd-MMM-yyyy') + ' to ' + to.toString('dd-MMM-yyyy'));
    19392040
    19402041             if (callback) {
     
    19612062             dataType: 'text',
    19622063             success: function(res) {
     2064                // edcal.output(res);
    19632065                jQuery('#loading').hide();
    19642066                /*
     
    20002102                         */
    20012103                        post.date = post.date.replace(post.date.substring(2, 3), post.date.substring(2, 3).toUpperCase());
    2002 
     2104                        if ( from=='00000000' )
     2105                            post.date = from;
     2106
     2107                        // edcal.output(post.date + ', post-' + post.id);
    20032108                        edcal.removePostItem(post.date, 'post-' + post.id);
    20042109                        edcal.addPostItem(post, post.date);
     2110                        // edcal.output(post.id + ', ' + post.date);
    20052111                        postDates[postDates.length] = post.date;
    20062112                    }
     
    20182124                 */
    20192125                setTimeout(function() {
    2020                     edcal.output('Finished adding draggable support to ' + postDates.length + ' posts.');
     2126                    // edcal.output('Finished adding draggable support to ' + postDates.length + ' posts.');
    20212127                    jQuery.each(postDates, function(i, postDate) {
    20222128                        edcal.addPostItemDragAndToolltip(postDate);
     
    20922198            }
    20932199        });
    2094 
    2095         return true;
    2096     },
    2097 
    2098     /*
    2099        This function adds the scren options tab to the top of the screen.  I wish
     2200    },
     2201
     2202    /*
     2203       This function adds the screen options tab to the top of the screen.  I wish
    21002204       WordPress had a hook so I could provide this in PHP, but as of version 2.9.1
    21012205       they just have an internal loop for their own screen options tabs so we're
     
    21092213                   'onclick="edcal.toggleOptions(); return false;" ' +
    21102214                   'href="#" ' +
    2111                    'style="background-image: url(images/screen-options-right.gif); background-position: right 0px;">' + edcal.str_screenoptions + '</a>' +
     2215                   '>' +
     2216                   edcal.str_screenoptions +
     2217                   '</a>' +
    21122218             '</div>';
    21132219         
     
    21912297             jQuery('#screen-meta').show();
    21922298
    2193              jQuery('#show-edcal-settings-link').css('background-image', 'url(images/screen-options-right-up.gif)');
     2299             jQuery('#show-edcal-settings-link').addClass('screen-meta-active');
    21942300         } else {
    21952301             jQuery('#contextual-help-wrap').slideUp('fast');
     
    22022308             edcal.helpMeta = null;
    22032309
    2204              jQuery('#show-edcal-settings-link').css('background-image', 'url(images/screen-options-right.gif)');
     2310             jQuery('#show-edcal-settings-link').removeClass('screen-meta-active');
    22052311             jQuery('#contextual-help-link-wrap').css('visibility', '');
    22062312         }
  • editorial-calendar/branches/drafts_drawer/edcal.php

    r503856 r511018  
    1919Plugin Name: WordPress Editorial Calendar
    2020Description: The Editorial Calendar makes it possible to see all your posts and drag and drop them to manage your blog.
    21 Version: 1.8.6
     21Version: 1.8.5
    2222Author: Colin Vernon, Justin Evans, Joachim Kudish, Mary Vogt, and Zack Grossbart
    2323Author URI: http://www.zackgrossbart.com
     
    5151   
    5252    protected $supports_custom_types;
     53    protected $default_time;
    5354
    5455    function __construct() {
     
    6970         */
    7071        $this->supports_custom_types = function_exists('get_post_types') && function_exists('get_post_type_object');
     72
     73        /*
     74         * This is the default time that posts get created at, for now
     75         * we are using 10am, but this could become an option later.
     76         */
     77        $this->default_time = get_option("edcal_default_time") != "" ? get_option("edcal_default_time") : '10:00';       
    7178       
    7279        /*
     
    154161            update_option("edcal_count", $edcal_count);
    155162        }
    156        
    157163       
    158164        /*
     
    242248                edcal.timeFormat = "<?php echo(get_option("time_format")); ?>";
    243249                edcal.previewDateFormat = "MMMM d";
     250                edcal.defaultTime = "<?php echo $this->default_time; ?>";
    244251   
    245252                /*
     
    310317                edcal.str_weekserror = <?php echo($this->edcal_json_encode(__('The calendar can only show between 1 and 5 weeks at a time.', 'editorial-calendar'))) ?>;
    311318                edcal.str_weekstt = <?php echo($this->edcal_json_encode(__('Select the number of weeks for the calendar to show.', 'editorial-calendar'))) ?>;
     319
     320                edcal.str_showdrafts = <?php echo($this->edcal_json_encode(__('Show Drafts'))) ?>;
     321                edcal.str_hidedrafts = <?php echo($this->edcal_json_encode(__('Hide Drafts'))) ?>;
    312322   
    313323                edcal.str_feedbackmsg = <?php echo($this->edcal_json_encode(__('<div id="feedbacksection">' .
     
    358368        <div class="wrap">
    359369            <div class="icon32" id="icon-edit"><br/></div>
    360             <h2 id="edcal_main_title"><?php echo($this->edcal_get_posttype_multiplename()); ?><?php echo(__(' Calendar', 'editorial-calendar')); ?></h2>
     370            <h2 id="edcal_main_title"><?php echo sprintf( __('%1$s Calendar', 'editorial-calendar'), $this->edcal_get_posttype_multiplename() ) ?></h2>
    361371           
    362372            <div id="loadingcont">
     
    364374            </div>
    365375           
    366             <div id="topbar" class="tablenav">
    367                 <div id="topleft" class="tablenav-pages">
     376            <div id="topbar" class="tablenav clearfix">
     377                <div id="topleft" class="tablenav-pages alignleft">
    368378                    <h3>
    369379                        <a href="#" title="<?php echo(__('Jump back', 'editorial-calendar')) ?>" class="prev page-numbers" id="prevmonth">&laquo;</a>
    370380                        <span id="currentRange"></span>
    371381                        <a href="#" title="<?php echo(__('Skip ahead', 'editorial-calendar')) ?>" class="next page-numbers" id="nextmonth">&raquo;</a>
     382
     383                        <a class="save button" title="<?php echo(__('Scroll the calendar and make the today visible', 'editorial-calendar')) ?>" id="moveToToday"><?php echo(__('Show Today', 'editorial-calendar')) ?></a>
    372384                    </h3>
    373385                </div>
    374                
    375                 <div id="topright">
    376                     <button class="save button" title="<?php echo(__('Scroll the calendar and make the today visible', 'editorial-calendar')) ?>" id="moveToToday"><?php echo(__('Show Today', 'editorial-calendar')) ?></button>
     386
     387                <div id="topright" class="tablenav-pages alignright">
     388                    <a class="save button" title="<?php echo(__('Show unscheduled posts', 'editorial-calendar')) ?>" id="showdraftsdrawer"><?php echo(__('Show Drafts', 'editorial-calendar')) ?></a>
    377389                </div>
    378390            </div>
    379391           
    380             <div id="cal_cont">
     392            <div id="draftsdrawer_cont">
     393                <div id="draftsdrawer">
     394                    <div class="draftsdrawerheadcont"><div class="dayhead"><?php echo(__('Unscheduled Drafts', 'editorial-calendar')) ?></div></div>
     395                    <div class="day" id="00000000">
     396                        <div id="draftsdrawer_loading"></div>
     397                        <div id="unscheduled" class="dayobj"></div>
     398                    </div>
     399                </div>
     400            </div>
     401           
     402            <div id="cal_cont"<?php if ( get_option("edcal_author_pref") == 'true' ) echo ' class="show-author"'; ?>>
    381403                <div id="edcal_scrollable" class="edcal_scrollable vertical">
    382404                    <div id="cal"></div>
    383405                </div>
    384406            </div>
    385            
     407
    386408            <?php $this->edcal_edit_popup(); ?>
    387409           
     
    459481     * When we get a set of posts to populate the calendar we don't want
    460482     * to get all of the posts.  This filter allows us to specify the dates
    461      * we want.
     483     * we want. We also exclude posts that have not been set to a specific date.
    462484     */
    463485    function edcal_filter_where($where = '') {
    464486        global $edcal_startDate, $edcal_endDate;
    465         $where .= " AND post_date >= '" . $edcal_startDate . "' AND post_date < '" . $edcal_endDate . "'";
     487        if ( $edcal_startDate=='00000000' )
     488            $where .= " AND post_date_gmt LIKE '0000%'";
     489        else
     490            $where .= " AND post_date >= '" . $edcal_startDate . "' AND post_date < '" . $edcal_endDate . "' AND post_date_gmt NOT LIKE '0000%'";
    466491        return $where;
    467492    }
     
    520545        global $edcal_startDate, $edcal_endDate;
    521546       
    522         $edcal_startDate = isset($_GET['from'])?$_GET['from']:null;
    523         $edcal_endDate = isset($_GET['to'])?$_GET['to']:null;
     547        $edcal_startDate = isset($_GET['from']) ? $_GET['from'] : null;
     548        $edcal_endDate = isset($_GET['to']) ? $_GET['to'] : null;
    524549        global $post;
    525550        $args = array(
     
    528553            'post_parent' => null // any parent
    529554        );
    530        
     555
    531556        /*
    532557         * If we're in the specific post type case we need to add
     
    537562            $args['post_type'] = $post_type;
    538563        }
    539        
    540         add_filter('posts_where', array(&$this, 'edcal_filter_where'));
     564
     565        /*
     566         * We add a WHERE clause to filter by calendar date and/or by whether
     567         * or not the posts have been scheduled to a specific date:
     568         * WHERE `post_date_gmt` = '0000-00-00 00:00:00'
     569         */
     570
     571        add_filter( 'posts_where', array(&$this, 'edcal_filter_where' ));
    541572        $myposts = query_posts($args);
    542         remove_filter('posts_where', array(&$this, 'edcal_filter_where'));
    543        
     573        remove_filter( 'posts_where', array(&$this, 'edcal_filter_where' ));
     574
    544575        ?>[
    545576        <?php
     
    662693        } else if ($timeFormat == "g:i A") {
    663694            $timeFormat = "gA";
    664         } else if ($timeFormat == "H:i" || $timeFormat == "G:i") {
     695        } else if ($timeFormat == "H:i") {
    665696            $timeFormat = "H";
    666697        }
     
    668699        setup_postdata($post);
    669700       
    670         if (get_post_status() == 'auto-draft' ||
    671             get_post_status() == 'inherit') {
     701        if (get_post_status() == 'auto-draft' || get_post_status() == 'inherit' ) {
    672702            /*
    673703             * WordPress 3 added a new post status of auto-draft so
    674              * we want to hide them from the calendar
     704             * we want to hide them from the calendar.
     705             * We also want to hide posts with type 'inherit'
    675706             */
    676707            return;
     
    691722            $postTypeTitle = 'post';
    692723        }
     724
     725        $post_date_gmt = date('dmY',strtotime($post->post_date_gmt));
     726        if ( $post_date_gmt == '01011970' )
     727            $post_date_gmt = '00000000';
    693728        ?>
    694729            {
    695730                "date" : "<?php the_time('d') ?><?php the_time('m') ?><?php the_time('Y') ?>",
    696                 "time" : "<?php the_time() ?>",
    697                 "formattedtime" : "<?php $this->edcal_json_encode(the_time($timeFormat)); ?>",
    698                 "sticky" : "<?php echo(is_sticky($post->ID)); ?>",
    699                 "url" : "<?php $this->edcal_json_encode(the_permalink()); ?>",
    700                 "status" : "<?php echo(get_post_status()); ?>",
    701                 "title" : <?php echo($this->edcal_json_encode(get_the_title())); ?>,
    702                 "author" : <?php echo($this->edcal_json_encode(get_the_author())); ?>,
    703                 "type" : "<?php echo(get_post_type( $post )); ?>",
    704                 "typeTitle" : "<?php echo($postTypeTitle); ?>",
     731                "date_gmt" : "<?php echo $post_date_gmt; // we are not actually using this right now ?>",
     732                "time" : "<?php echo trim(get_the_time()) ?>",
     733                "formattedtime" : "<?php $this->edcal_json_encode(the_time($timeFormat)) ?>",
     734                "sticky" : "<?php echo is_sticky($post->ID) ?>",
     735                "url" : "<?php $this->edcal_json_encode(the_permalink()) ?>",
     736                "status" : "<?php echo get_post_status() ?>",
     737                "title" : <?php echo $this->edcal_json_encode(get_the_title()) ?>,
     738                "author" : <?php echo $this->edcal_json_encode(get_the_author()) ?>,
     739                "type" : "<?php echo get_post_type( $post ) ?>",
     740                "typeTitle" : "<?php echo $postTypeTitle ?>",
    705741   
    706742                <?php if ( current_user_can('edit_post', $post->ID) ) {?>
    707                 "editlink" : "<?php echo(get_edit_post_link($id)); ?>",
     743                "editlink" : "<?php echo get_edit_post_link($id) ?>",
    708744                <?php } ?>
    709745   
     
    712748                <?php } ?>
    713749   
    714                 "permalink" : "<?php echo(get_permalink($id)); ?>",
     750                "permalink" : "<?php echo get_permalink($id) ?>",
    715751                "id" : "<?php the_ID(); ?>"
    716752               
     
    730766     * when a user clicks the delete button, and allows the user to
    731767     * retain their position within the calendar without a page refresh.
    732      * It is not called unless the user has permission to delete the post
     768     * It is not called unless the user has permission to delete the post.
    733769     */
    734770    function edcal_deletepost() {
     
    868904    /*
    869905     * This is a helper function to create a new draft post on a specified date
    870      * or update an existing post
     906     * or update an existing post.
    871907     */
    872908    function edcal_savepost() {
     
    9941030        $edcal_oldDate = isset($_GET['olddate'])?$_GET['olddate']:null;
    9951031        $edcal_postStatus = isset($_GET['postStatus'])?$_GET['postStatus']:null;
    996        
     1032        $move_to_drawer = $edcal_newDate == '0000-00-00';
     1033        $move_from_drawer = $edcal_oldDate == '00000000';
     1034
     1035        global $post;
     1036        $args = array(
     1037            'posts_id' => $edcal_postid,
     1038        );
     1039        $post = get_post($edcal_postid);
     1040        setup_postdata($post);
     1041
     1042        /*
     1043         * Posts in WordPress have more than one date.  There is the GMT date,
     1044         * the date in the local time zone, the modified date in GMT and the
     1045         * modified date in the local time zone.  We update all of them.
     1046         */
     1047        if ( $move_from_drawer ) {
     1048            /*
     1049             * Set the date to 'unscheduled' [ie. 0], and while we're at it we
     1050             * add the default time so it won't be at midnight. We use this date
     1051             * further down in the concurrency check, and this will make the dates
     1052             * technically off by 10 hours, but it's still the same day. We only do
     1053             * this for posts that were created as drafts.  Works for now, but
     1054             * we would have to revamp this if we use an actual timestamp check.
     1055             */
     1056            $post->post_date = '0000-00-00 '.$this->default_time.':00';
     1057        } else if ( $move_to_drawer ) {
     1058            // echo ( "\r\npost->post_date_gmt=".$post->post_date_gmt);
     1059            $post->post_date_gmt = $post->post_date;
     1060        } else {
     1061            // set the scheduled time as our original time
     1062            $post->post_date_gmt = $post->post_date;
     1063        }
     1064// echo ( "\r\npost->post_date_gmt = $post->post_date_gmt \r\npost->post_date = $post->post_date");
     1065
     1066        /*
     1067         * Error-checking:
     1068         */
     1069        $error = false;
    9971070        if (!current_user_can('edit_post', $edcal_postid)) {
    9981071            /*
     
    10001073             * user has permission to edit posts.  Most of the time this
    10011074             * will never be run because you can't see the calendar unless
    1002              * you are at least an editor
     1075             * you are at least an editor.
    10031076             */
     1077            $error = EDCAL_PERMISSION_ERROR;
     1078        } else if ( date('Y-m-d', strtotime($post->post_date)) != date('Y-m-d', strtotime($edcal_oldDate)) ) {
     1079            /*
     1080             * We are doing optimistic concurrency checking on the dates.  If
     1081             * the user tries to move a post we want to make sure nobody else
     1082             * has moved that post since the page was last updated.  If the
     1083             * old date in the database doesn't match the old date from the
     1084             * browser then we return an error to the browser along with the
     1085             * updated post data.
     1086             */
     1087            $error = EDCAL_CONCURRENCY_ERROR;
     1088        }
     1089
     1090        if ( $error ) {
     1091            // die('error= '.$error);
    10041092            ?>
    10051093            {
    1006                 "error": <?php echo(EDCAL_PERMISSION_ERROR); ?>,
    1007             <?php
    1008            
    1009             global $post;
    1010             $args = array(
    1011                 'posts_id' => $edcal_postid,
    1012             );
    1013            
    1014             $post = get_post($edcal_postid);
    1015             ?>
     1094                "error": <?php echo $error; ?>,
    10161095                "post" :
    10171096            <?php
     
    10221101            die();
    10231102        }
    1024        
    1025         $post = get_post($edcal_postid, ARRAY_A);
    1026         setup_postdata($post);
    1027        
    1028         /*
    1029          * We are doing optimistic concurrency checking on the dates.  If
    1030          * the user tries to move a post we want to make sure nobody else
    1031          * has moved that post since the page was last updated.  If the
    1032          * old date in the database doesn't match the old date from the
    1033          * browser then we return an error to the browser along with the
    1034          * updated post data.
    1035          */
    1036          if (date('Y-m-d', strtotime($post['post_date'])) != date('Y-m-d', strtotime($edcal_oldDate))) {
    1037             ?> {
    1038                 "error": <?php echo(EDCAL_CONCURRENCY_ERROR); ?>,
    1039             <?php
    1040            
    1041             global $post;
    1042             $args = array(
    1043                 'posts_id' => $edcal_postid,
    1044             );
    1045            
    1046             $post = get_post($edcal_postid);
    1047             ?>
    1048                 "post" :
    1049             <?php
    1050                 $this->edcal_postJSON($post, false, true);
    1051             ?> }
    1052            
    1053             <?php
    1054             die();
    1055         }
    1056        
    1057         /*
    1058          * Posts in WordPress have more than one date.  There is the GMT date,
    1059          * the date in the local time zone, the modified date in GMT and the
    1060          * modified date in the local time zone.  We update all of them.
    1061          */
    1062         $post['post_date_gmt'] = $post['post_date'];
    1063        
     1103
     1104
     1105        /*
     1106         * No errors, so let's go create our new post parameters to update
     1107         */
     1108       
     1109        $updated_post = array();
     1110        $updated_post['ID'] = $edcal_postid;
     1111
     1112        if ( !$move_to_drawer ) {
     1113            $updated_post['post_date'] = $edcal_newDate . substr($post->post_date, strlen($edcal_newDate));
     1114        }
     1115
    10641116        /*
    10651117         * When a user creates a draft and never sets a date or publishes it
     
    10691121         * date out and leave the post as publish immediately.
    10701122         */
    1071         $needsEditDate = strpos($post['post_date_gmt'], "0000-00-00 00:00:00") === 0;
    1072        
    1073         $updated_post = array();
    1074         $updated_post['ID'] = $edcal_postid;
    1075         $updated_post['post_date'] = $edcal_newDate . substr($post['post_date'], strlen($edcal_newDate));
    1076         if ($needsEditDate != -1) {
    1077             $updated_post['edit_date'] = $edcal_newDate . substr($post['post_date'], strlen($edcal_newDate));
    1078         }
    1079        
     1123        $needsEditDate = preg_match( '/^0000/', $post->post_date_gmt );
     1124
     1125        if ( $needsEditDate ) {
     1126            // echo "\r\nneeds edit date\r\n";
     1127            $updated_post['edit_date'] = $edcal_newDate . substr($post->post_date, strlen($edcal_newDate));
     1128        }
     1129
     1130        if ( $move_to_drawer ) {
     1131            $updated_post['post_date_gmt'] = "0000-00-00 00:00:00";
     1132            $updated_post['edit_date'] = $post->post_date;
     1133        } else if ( $move_from_drawer ) {
     1134            $updated_post['post_date_gmt'] = get_gmt_from_date($post->post_date);
     1135            $updated_post['post_modified_gmt'] = get_gmt_from_date($post->post_date);
     1136        }
     1137
    10801138        /*
    10811139         * We need to make sure to use the GMT formatting for the date.
    10821140         */
    1083         $updated_post['post_date_gmt'] = get_gmt_from_date($updated_post['post_date']);
    1084         $updated_post['post_modified'] = $edcal_newDate . substr($post['post_modified'], strlen($edcal_newDate));
    1085         $updated_post['post_modified_gmt'] = get_gmt_from_date($updated_post['post_date']);
    1086        
    1087         if ($edcal_postStatus != $post['post_status']) {
     1141        if ( !$move_to_drawer ) {
     1142            $updated_post['post_date_gmt'] = get_gmt_from_date($updated_post['post_date']);
     1143            $updated_post['post_modified'] = $edcal_newDate . substr($post->post_modified, strlen($edcal_newDate));
     1144            $updated_post['post_modified_gmt'] = get_gmt_from_date($updated_post['post_date']);
     1145        }
     1146       
     1147        if ($edcal_postStatus != $post->post_status) {
    10881148            /*
    10891149             * We only want to update the post status if it has changed.
    10901150             * If the post status has changed that takes a few more steps
    10911151             */
    1092             wp_transition_post_status($edcal_postStatus, $post['post_status'], $post);
     1152            wp_transition_post_status($edcal_postStatus, $post->post_status, $post);
    10931153            $updated_post['post_status'] = $edcal_postStatus;
    10941154           
     
    11041164        }
    11051165       
     1166// die(var_dump($updated_post).'success!');
    11061167        /*
    11071168         * Now we finally update the post into the database
  • editorial-calendar/branches/drafts_drawer/languages/editorial-calendar-fr_FR.po

    r194972 r511018  
    1 # Translation of the WordPress plugin Editorial Calendar by stresslimitdesign.
    2 # Copyright (C) 2010
    3 # This file is distributed under the same license as the  package.
    4 # COLIN VERNON <[email protected]>, 2010.
    5 #
     1# Translation of WordPress Editorial Calendar in French (France)
     2# This file is distributed under the same license as the WordPress Editorial Calendar package.
    63msgid ""
    74msgstr ""
    8 "Project-Id-Version: \n"
    9 "Report-Msgid-Bugs-To: http://wordpress.org/tag/editorial-calendar\n"
    10 "POT-Creation-Date: 2010-01-14 20:13+0000\n"
    11 "PO-Revision-Date: 2010-01-18 10:08-0500\n"
    12 "Last-Translator: Zack Grossbart <[email protected]>\n"
    13 "Language-Team: LANGUAGE <[email protected]>\n"
     5"PO-Revision-Date: 2012-02-27 08:53:18+0000\n"
    146"MIME-Version: 1.0\n"
    15 "Content-Type: text/plain; charset=utf-8\n"
     7"Content-Type: text/plain; charset=UTF-8\n"
    168"Content-Transfer-Encoding: 8bit\n"
     9"Plural-Forms: nplurals=2; plural=n > 1;\n"
     10"X-Generator: GlotPress/0.1\n"
     11"Project-Id-Version: WordPress Editorial Calendar\n"
    1712
    18 #: edcal.php:60
     13msgid "%1$s Calendar"
     14msgstr "Calendrier des %1$s"
     15
    1916msgid "Calendar"
    2017msgstr "Calendrier"
    2118
    22 #: edcal.php:130
    23 #: edcal.php:277
    2419msgid "en-US"
    25 msgstr "fr_FR"
     20msgstr "fr-FR"
    2621
    27 #: edcal.php:138
    28 msgid "on"
    29 msgstr "le"
     22msgid "%1$s by %2$s"
     23msgstr "%1$s par %2$s"
    3024
    31 #: edcal.php:139
    32 msgid "by"
    33 msgstr "par"
     25msgid "New Post"
     26msgstr "Nouveau post"
    3427
    35 #: edcal.php:140
    36 msgid "at"
    37 msgstr "à"
    38 
    39 #: edcal.php:142
    40 msgid "Add a post"
    41 msgstr "Ajouter un post"
    42 
    43 #: edcal.php:144
    44 msgid "Sunday"
    45 msgstr "Dimanche"
    46 
    47 #: edcal.php:145
    48 msgid "Monday"
    49 msgstr "Lundi"
    50 
    51 #: edcal.php:146
    52 msgid "Tuesday"
    53 msgstr "Mardi"
    54 
    55 #: edcal.php:147
    56 msgid "Wednesday"
    57 msgstr "Mercredi"
    58 
    59 #: edcal.php:148
    60 msgid "Thursday"
    61 msgstr "Jeudi"
    62 
    63 #: edcal.php:149
    64 msgid "Friday"
    65 msgstr "Vendredi"
    66 
    67 #: edcal.php:150
    68 msgid "Saturday"
    69 msgstr "Samedi"
    70 
    71 #: edcal.php:152
    7228msgid " [DRAFT]"
    7329msgstr " [BROUILLON]"
    7430
    75 #: edcal.php:153
     31msgid " [PENDING]"
     32msgstr " [EN ATTENTE]"
     33
     34msgid " [STICKY]"
     35msgstr " [EN PRIORITÉ]"
     36
     37msgid " [DRAFT, STICKY]"
     38msgstr " [BROUILLON, STICKY]"
     39
     40msgid " [PENDING, STICKY]"
     41msgstr " [EN ATTENTE, EN PRIORITÉ]"
     42
    7643msgid "Edit"
    7744msgstr "Éditer"
    7845
    79 #: edcal.php:154
     46msgid "Quick Edit"
     47msgstr "Éditer rapide"
     48
    8049msgid "Delete"
    8150msgstr "Supprimer"
    8251
    83 #: edcal.php:155
    8452msgid "View"
    8553msgstr "Voir"
    8654
    87 #: edcal.php:156
    88 msgid "Republish"
    89 msgstr "Republier"
     55msgid "Status:"
     56msgstr "Statut :"
    9057
    91 #: edcal.php:157
    92 msgid "Status:"
    93 msgstr "Status :"
    94 
    95 #: edcal.php:158
    9658msgid "Cancel"
    9759msgstr "Annuler"
    9860
    99 #: edcal.php:159
    100 msgid "Post Title:"
    101 msgstr "Titre du post :"
     61msgid "Title"
     62msgstr "Titre"
    10263
    103 #: edcal.php:160
    104 msgid "Save Draft"
    105 msgstr "Enregistrer brouillon"
     64msgid "Content"
     65msgstr "Contenu"
    10666
    107 #: edcal.php:161
    108 msgid "Save and Edit Draft"
    109 msgstr "Enregistrer et éditer brouillon"
     67msgid "Add a new post on %s"
     68msgstr "Ajouter un article au %s"
    11069
    111 #: edcal.php:162
    112 msgid "Add a new post on "
    113 msgstr "Ajouter un nouveau post le "
     70msgid "New %s - "
     71msgstr "Nouveau %s - "
    11472
    115 #: edcal.php:164
    116 msgid "You are about to delete this post "
    117 msgstr "Vous allez supprimer le post '"
     73msgid "Update"
     74msgstr "Mettre à jour"
    11875
    119 #: edcal.php:165
    120 msgid "Press cancel to stop, OK to delete."
    121 msgstr "'. Cliquer sur annuler pour arrêter, OK pour supprimer"
     76msgid "Schedule"
     77msgstr "Horaire"
    12278
    123 #: edcal.php:167
     79msgid "Submit for Review"
     80msgstr "Soumettre pour revision"
     81
     82msgid "Save"
     83msgstr "Sauvegarder"
     84
     85msgid "Edit %1$s - %2$s"
     86msgstr "Éditer %1$s - %2$s"
     87
     88msgid "Scheduled"
     89msgstr "Planifié"
     90
     91msgid "You are about to delete the post \""
     92msgstr "Vous allez supprimer le post \""
     93
     94msgid "\". Press Cancel to stop, OK to delete."
     95msgstr "\". Cliquer OK pour confirmer."
     96
    12497msgid "Looks like someone else already moved this post."
    12598msgstr "Quelqu'un d'autre a déjà déplacé ce post."
    12699
    127 #: edcal.php:168
    128100msgid "You do not have permission to edit posts."
    129101msgstr "Vous n'avez pas les permissions d'éditer les posts."
    130102
    131 #: edcal.php:169
    132103msgid "Invalid checksum for post. This is commonly a cross-site scripting error."
    133 msgstr "Désolé, le post est corrompu, il se peut que ce soit une erreur de 'cross-site scripting' (XSS)."
     104msgstr "Désolé, les donnés de l'article sont corrompu, il se peut que ce soit une erreur de 'cross-site scripting' (XSS)."
    134105
    135 #: edcal.php:170
    136106msgid "There was an error contacting your blog."
    137107msgstr "Une erreur est survenue en contactant votre blog."
    138108
    139 #: edcal.php:172
    140109msgid "Screen Options"
    141110msgstr "Options d'affichage"
    142111
    143 #: edcal.php:173
    144 msgid "Calendar Options"
    145 msgstr "Options du calendrier"
     112msgid "Colors"
     113msgstr "Couleurs"
    146114
    147 #: edcal.php:174
     115msgid "Drafts: "
     116msgstr "Brouillons:"
     117
    148118msgid "Apply"
    149119msgstr "Appliquer"
    150120
    151 #: edcal.php:175
    152 msgid "Show "
    153 msgstr "Afficher "
     121msgid "Show on screen"
     122msgstr "Afficher"
    154123
    155 #: edcal.php:176
    156 msgid "weeks at a time"
     124msgid " weeks at a time"
    157125msgstr "semaines à la fois"
    158126
    159 #: edcal.php:177
     127msgid "Show in Calendar Cell"
     128msgstr "Afficher en calendrier"
     129
     130msgid "Author"
     131msgstr "Auteur"
     132
     133msgid "Status"
     134msgstr "Statut"
     135
     136msgid "Time of day"
     137msgstr "Heure"
     138
     139msgid "An error occurred while loading the calendar: "
     140msgstr "Il y a eu un erreur en chargement du calendrier : "
     141
    160142msgid "The calendar can only show between 1 and 5 weeks at a time."
    161143msgstr "Le calendrier ne peut afficher qu'une à cinq semaines à la fois."
    162144
    163 #: edcal.php:178
    164 msgid "Enter the number of weeks, between 1 and 5, for the calendar to show."
    165 msgstr "Entrer le nombre de semaines que le calendrier va afficher (entre 1 et 5)"
     145msgid "Select the number of weeks for the calendar to show."
     146msgstr "Sélectionner le nombre de semaines à afficher au calendrier."
    166147
    167 #: edcal.php:214
    168 msgid "Posts Calendar"
    169 msgstr "Calendrier de posts"
     148msgid "<h2>We're done</h2>We've finished collecting data.  Thank you for helping us make the calendar better."
     149msgstr "<h2>C'est tout !</h2>On a tout finit. Merci de nous aider à améliorer le calendrier."
    170150
    171 #: edcal.php:223
    172151msgid "Jump back"
    173152msgstr "Mois précédent"
    174153
    175 #: edcal.php:225
    176154msgid "Skip ahead"
    177155msgstr "Mois suivant"
    178156
    179 #: edcal.php:230
    180 msgid "Jump to today"
    181 msgstr "Retourner à aujourd'hui"
     157msgid "Scroll the calendar and make the today visible"
     158msgstr "Sauter à aujourd'hui"
    182159
    183 #: edcal.php:230
    184 msgid "Today"
    185 msgstr "Aujourd'hui"
     160msgid "Show Today"
     161msgstr "Voir aujourd'hui"
    186162
    187 #: edcal.php:361
    188 #: - this is the time format (12 hour or 24 hour)
    189 msgid "ga"
    190 msgstr "H"
     163msgid "Edit Post"
     164msgstr "Éditer l'article"
    191165
     166msgid "Time"
     167msgstr "Heure"
     168
     169msgid "Draft"
     170msgstr "Brouillon"
     171
     172msgid "Pending Review"
     173msgstr "En attente de relecture"
     174
     175msgid "Posts "
     176msgstr "Articles"
     177
     178msgid "Post "
     179msgstr "Article"
     180
     181msgid "Error in deleting..."
     182msgstr "Erreur en supprimant..."
     183
     184msgid "ltr"
     185msgstr "ltr"
  • editorial-calendar/branches/drafts_drawer/readme.txt

    r503465 r511018  
    44Requires at least: 2.8.5
    55Tested up to: 3.3.1
    6 Stable tag: 1.8.6
     6Stable tag: 1.8.5
    77
    88The Editorial Calendar makes it possible to see all your posts and drag and drop them to manage your blog.
     
    3131<h4>Make it better</h4>
    3232
    33 Thank you to everyone who has given us feedback and helped us improve this plugin.  If you have questions, problems, or ideas for new features please let us know at <a href="mailto:[email protected]">[email protected]</a>. 
     33Thank you to everyone who has given us feedback and helped us improve this plugin.  If you have questions, problems, or ideas for new features please let us know at <a href="mailto:[email protected]">[email protected]</a>.
     34
     35<h4>Translate it</h4>
     36
     37Again, thanks to all who have already helped make the plugin available in so many languages. If you would like to help us translate the plugin into your language, or if you use it in a language other than English already and would like to help us keep it up to date, please write to us at <a href="mailto:[email protected]">[email protected]</a>
    3438
    3539== Installation ==
     
    130134* Subscribers can't see the calendar.
    131135
    132 You can see how it looks for different usres on our <a href="http://www.zackgrossbart.com/extras/sandbox/wp-admin/edit.php?page=cal">Zack's WordPress Sandbox</a> with the following users:
     136You can see how it looks for different users on our <a href="http://www.zackgrossbart.com/extras/sandbox/wp-admin/edit.php?page=cal">Zack's WordPress Sandbox</a> with the following users:
    133137
    134138* edgar the Editor
     
    168172== Changelog ==
    169173
    170 = 1.9 =
    171 
    172 We are now filtering out all posts with a status of inherit from the calendar so we don't show additional revisions.
    173 
    174 = 1.8.6 =
    175 
    176 The calendar is now using the proper he_IL locale code for Hebrew instead of he.
     174= 2.0 =
     175
     176The calendar now has a new major feature, the "drafts drawer," a kind of post staging area where we make all posts that have not been scheduled available to drag onto the calendar. We can also now drag posts from the calendar back into the drafts drawer to "un-schedule" them.
     177
     178Moved around functions in the js and css to be a bit more readable, and added table of contents to css file.
     179
     180Updated css of Screen Options to be more core WordPress.
    177181
    178182= 1.8.5 =
     
    253257
    254258= 1.0 =
    255 * Fixed a scrolling issue that prevented cliking the action links on the last post if the individual day showed a scroll bar.
     259* Fixed a scrolling issue that prevented clicking the action links on the last post if the individual day showed a scroll bar.
    256260
    257261= 0.9 =
Note: See TracChangeset for help on using the changeset viewer.