Styling and minor improvements for items per page option

git-svn-id: https://develop.svn.wordpress.org/trunk@10872 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Ozz
2009-04-05 08:25:10 +00:00
parent 9b28447049
commit bd0313e3bc
8 changed files with 30 additions and 16 deletions

View File

@@ -108,7 +108,7 @@ columns = {
$.post(ajaxurl, {
action: 'hidden-columns',
hidden: hidden,
hiddencolumnsnonce: $('#hiddencolumnsnonce').val(),
screenoptionnonce: $('#screenoptionnonce').val(),
page: pagenow
});
}
@@ -118,13 +118,16 @@ $(document).ready(function(){columns.init();});
screenOptions = {
init : function() {
$('.screen-option').change(function() {
var option = $(this).map(function() { return this.id; }).get(), value = $(this).val();
screenOptions.save_screen_option(option, value);
});
$('.screen-option').submit(function() {
var option = $(this).map(function() { return this.id; }).get(), value = $(this).val();
$('.screen-per-page').change(function() {
var option = this.id, value = parseInt($(this).val());
if ( isNaN(value) ) {
$(this).val('');
return;
}
screenOptions.save_screen_option(option, value);
}).parents('form').submit(function(e) {
e.preventDefault();
return false;
});
},

File diff suppressed because one or more lines are too long