Skip to:
Content

BuddyPress.org

Changeset 7941


Ignore:
Timestamp:
02/20/2014 08:32:44 PM (11 years ago)
Author:
boonebgorges
Message:

Don't shrink whats-new box if focusing away from window

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-templates/bp-legacy/js/buddypress.js

    r7740 r7941  
    5858    /* On blur, shrink if it's empty */
    5959    $whats_new.blur( function(){
    60         if (!this.value.match(/\S+/)) {
    61             this.value = "";
    62             jq("#whats-new-options").animate({
    63                 height:'40px'
    64             });
    65             jq("form#whats-new-form textarea").animate({
    66                 height:'20px'
    67             });
    68             jq("#aw-whats-new-submit").prop("disabled", true);
     60        if ( document.activeElement != this ) {
     61            if (!this.value.match(/\S+/)) {
     62                this.value = "";
     63                jq("#whats-new-options").animate({
     64                    height:'40px'
     65                });
     66                jq("form#whats-new-form textarea").animate({
     67                    height:'20px'
     68                });
     69                jq("#aw-whats-new-submit").prop("disabled", true);
     70            }
    6971        }
    7072    });
Note: See TracChangeset for help on using the changeset viewer.