working on enhancements
This commit is contained in:
parent
18e74f459c
commit
ed8231a193
|
@ -192,12 +192,13 @@ class ComicPressAddonCore extends ComicPressAddon {
|
||||||
* Set up the admin interface and meta boxes.
|
* Set up the admin interface and meta boxes.
|
||||||
*/
|
*/
|
||||||
function setup_admin_interface() {
|
function setup_admin_interface() {
|
||||||
global $plugin_page;
|
global $plugin_page, $pagenow, $post;
|
||||||
|
|
||||||
add_theme_page(__("ComicPress Core", 'comicpress'), __('ComicPress Core', 'comicpress'), 'edit_themes', 'comicpress/render_admin', array(&$this, 'render_admin'));
|
add_theme_page(__("ComicPress Core", 'comicpress'), __('ComicPress Core', 'comicpress'), 'edit_themes', 'comicpress/render_admin', array(&$this, 'render_admin'));
|
||||||
add_theme_page(__("Edit Partials", 'comicpress'), __('Edit Partials', 'comicpress'), 'edit_themes', 'comicpress/edit_partials', array(&$this, 'render_edit_partials'));
|
add_theme_page(__("Edit Partials", 'comicpress'), __('Edit Partials', 'comicpress'), 'edit_themes', 'comicpress/edit_partials', array(&$this, 'render_edit_partials'));
|
||||||
|
|
||||||
if (isset($_REQUEST['post'])) {
|
if (strpos($page, "edit") === 0) {
|
||||||
|
var_dump($post);
|
||||||
add_meta_box("comic-image-ordering", __("Comic Image Ordering", 'comicpress'), array(&$this, 'render_comic_image_ordering'), "post", "normal", "low");
|
add_meta_box("comic-image-ordering", __("Comic Image Ordering", 'comicpress'), array(&$this, 'render_comic_image_ordering'), "post", "normal", "low");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -205,6 +206,10 @@ class ComicPressAddonCore extends ComicPressAddon {
|
||||||
wp_enqueue_style('cp-admin', get_stylesheet_directory_uri() . '/css/cp-admin.css');
|
wp_enqueue_style('cp-admin', get_stylesheet_directory_uri() . '/css/cp-admin.css');
|
||||||
wp_enqueue_script('cp-admin', get_stylesheet_directory_uri() . '/js/Storyline.js', array('jquery', 'jquery-ui-sortable'));
|
wp_enqueue_script('cp-admin', get_stylesheet_directory_uri() . '/js/Storyline.js', array('jquery', 'jquery-ui-sortable'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (strpos($pagenow, "media-upload") === 0) {
|
||||||
|
wp_enqueue_script('cp-media', get_stylesheet_directory_uri() . '/js/MediaUpload.js', array('jquery'));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
jQuery(function() {
|
||||||
|
jQuery('.media-item').each(function() {
|
||||||
|
var item = this;
|
||||||
|
jQuery('.savesend', item).each(function() {
|
||||||
|
|
||||||
|
});
|
||||||
|
jQuery('input[name*=comic_image_type]', item).bind('change', function() {
|
||||||
|
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
});
|
Loading…
Reference in New Issue