Changeset 4450
- Timestamp:
- 06/04/2011 06:21:39 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-themes/bp-default/_inc/global.js
r4349 r4450 38 38 form.children().each( function() { 39 39 if ( jq.nodeName(this, "textarea") || jq.nodeName(this, "input") ) 40 jq(this). attr( 'disabled', 'disabled');40 jq(this).prop( 'disabled', true ); 41 41 }); 42 42 … … 45 45 /* Remove any errors */ 46 46 jq('div.error').remove(); 47 button. attr('disabled','disabled');47 button.prop('disabled', true); 48 48 49 49 /* Default POST values */ … … 71 71 form.children().each( function() { 72 72 if ( jq.nodeName(this, "textarea") || jq.nodeName(this, "input") ) 73 jq(this). attr( 'disabled', '');73 jq(this).prop( 'disabled', false ); 74 74 }); 75 75 … … 78 78 form.prepend( response.substr( 2, response.length ) ); 79 79 jq( 'form#' + form.attr('id') + ' div.error').hide().fadeIn( 200 ); 80 button. attr("disabled", '');80 button.prop("disabled", false); 81 81 } else { 82 82 if ( 0 == jq("ul.activity-list").length ) { … … 88 88 jq("ul.activity-list").prepend(response); 89 89 jq("ul.activity-list li:first").addClass('new-update'); 90 90 91 91 if ( 0 != jq("div#latest-update").length ) { 92 92 var l = jq("ul#activity-stream li.new-update .activity-content .activity-inner p").html(); 93 93 var v = jq("ul#activity-stream li.new-update .activity-content .activity-header p a.view").attr('href'); 94 94 95 95 jq("div#latest-update").slideUp(300,function(){ 96 96 jq("div#latest-update").html('"' + l + '" · <a href="' + v + '" rel="nofollow">View</a>'); … … 98 98 }); 99 99 } 100 100 101 101 jq("li.new-update").hide().slideDown( 300 ); 102 102 jq("li.new-update").removeClass( 'new-update' ); … … 104 104 105 105 /* Re-enable the submit button after 8 seconds. */ 106 setTimeout( function() { button. attr("disabled", ''); }, 8000 );106 setTimeout( function() { button.prop("disabled", false); }, 8000 ); 107 107 } 108 108 }); … … 371 371 if ( response[0] + response[1] == '-1' ) { 372 372 form.append( response.substr( 2, response.length ) ).hide().fadeIn( 200 ); 373 target. attr("disabled", '');373 target.prop("disabled", false); 374 374 } else { 375 375 form.fadeOut( 200, … … 393 393 394 394 /* Re-enable the submit button after 5 seconds. */ 395 setTimeout( function() { target. attr("disabled", ''); }, 5000 );395 setTimeout( function() { target.prop("disabled", false); }, 5000 ); 396 396 } 397 397 }); … … 644 644 var friend_id = jq(this).val(); 645 645 646 if ( jq(this). attr('checked') == true )646 if ( jq(this).prop('checked') == true ) 647 647 var friend_action = 'invite'; 648 648 else … … 696 696 jq('.ajax-loader').toggle(); 697 697 jq('#friend-list li#uid-' + friend_id).remove(); 698 jq('#invite-list input#f-' + friend_id). attr('checked', false);698 jq('#invite-list input#f-' + friend_id).prop('checked', false); 699 699 }); 700 700 … … 1076 1076 1077 1077 if ( null != jq.cookie('bp-activity-filter') && jq('#activity-filter-select').length ) 1078 jq('#activity-filter-select select option[value="' + jq.cookie('bp-activity-filter') + '"]'). attr( 'selected', 'selected');1078 jq('#activity-filter-select select option[value="' + jq.cookie('bp-activity-filter') + '"]').prop( 'selected', true ); 1079 1079 1080 1080 /* Activity Tab Set */ … … 1091 1091 jq(objects).each( function(i) { 1092 1092 if ( null != jq.cookie('bp-' + objects[i] + '-filter') && jq('li#' + objects[i] + '-order-select select').length ) 1093 jq('li#' + objects[i] + '-order-select select option[value="' + jq.cookie('bp-' + objects[i] + '-filter') + '"]'). attr( 'selected', 'selected');1093 jq('li#' + objects[i] + '-order-select select option[value="' + jq.cookie('bp-' + objects[i] + '-filter') + '"]').prop( 'selected', true ); 1094 1094 1095 1095 if ( null != jq.cookie('bp-' + objects[i] + '-scope') && jq('div.' + objects[i]).length ) { … … 1124 1124 jq('div.item-list-tabs li#' + object + '-' + scope + ', div.item-list-tabs#object-nav li.current').addClass('selected'); 1125 1125 jq('div.item-list-tabs li.selected').addClass('loading'); 1126 jq('div.item-list-tabs select option[value="' + filter + '"]'). attr( 'selected', 'selected');1126 jq('div.item-list-tabs select option[value="' + filter + '"]').prop( 'selected', true ); 1127 1127 1128 1128 if ( 'friends' == object ) … … 1166 1166 jq('li#activity-' + scope + ', div.item-list-tabs li.current').addClass('selected'); 1167 1167 jq('div#object-nav.item-list-tabs li.selected, div.activity-type-tabs li.selected').addClass('loading'); 1168 jq('#activity-filter-select select option[value="' + filter + '"]'). attr( 'selected', 'selected');1168 jq('#activity-filter-select select option[value="' + filter + '"]').prop( 'selected', true ); 1169 1169 1170 1170 /* Reload the activity stream based on the selection */
Note: See TracChangeset
for help on using the changeset viewer.