Exemplo n.º 1
0
 function init()
 {
     if (wallow_is_mobile()) {
         return;
     }
     //Infinite Scroll
     add_theme_support('infinite-scroll', array('type' => 'click', 'container' => 'content', 'render' => array($this, 'infinite_scroll_render'), 'wrapper' => false));
     if (class_exists('The_Neverending_Home_Page')) {
         add_filter('infinite_scroll_results', array($this, 'infinite_scroll_encode'), 11, 1);
     }
     //Sharedaddy
     if (function_exists('sharing_display')) {
         remove_filter('the_content', 'sharing_display', 19);
         remove_filter('the_excerpt', 'sharing_display', 19);
         remove_action('wallow_hook_entry_before', 'wallow_I_like_it');
         add_action('wallow_hook_entry_bottom', array($this, 'sharedaddy'));
     }
     //Carousel
     if (class_exists('Jetpack_Carousel')) {
         remove_filter('post_gallery', 'wallow_gallery_shortcode', 10, 2);
         add_filter('wallow_option_wallow_thickbox', '__return_false');
     }
     //Likes
     if (class_exists('Jetpack_Likes')) {
         add_action('wallow_hook_entry_bottom', array($this, 'likes'));
         remove_filter('the_content', array(Jetpack_Likes::init(), 'post_likes'), 30, 1);
         add_filter('wallow_filter_likes', array(Jetpack_Likes::init(), 'post_likes'), 30, 1);
     }
 }
Exemplo n.º 2
0
function wallow_stylesheet()
{
    if (wallow_is_mobile()) {
        return;
    }
    // thickbox
    if (wallow_get_opt('wallow_thickbox')) {
        wp_enqueue_style('thickbox');
    }
    //normal view
    wp_enqueue_style('wallow_general-style', get_stylesheet_uri(), false, wallow_get_info('version'), 'screen');
    wallow_get_variants();
    //print style
    wp_enqueue_style('wallow_print-style', get_template_directory_uri() . '/css/print.css', false, wallow_get_info('version'), 'print');
    //google font
    if (wallow_get_opt('wallow_google_font_family')) {
        wp_enqueue_style('wallow_google-fonts', '//fonts.googleapis.com/css?family=' . urlencode(wallow_get_opt('wallow_google_font_family')));
    }
}