Skip to:
Content

BuddyPress.org

Ticket #3354: 3354.02.patch

File 3354.02.patch, 3.5 KB (added by r-a-y, 14 years ago)
  • bp-core/bp-core-functions.php

    function bp_core_time_since( $older_date, $newer_date = false ) { 
    601601        $unknown_text   = apply_filters( 'bp_core_time_since_unknown_text',   __( 'sometime',  'buddypress' ) );
    602602        $right_now_text = apply_filters( 'bp_core_time_since_right_now_text', __( 'right now', 'buddypress' ) );
    603603        $ago_text       = apply_filters( 'bp_core_time_since_ago_text',       __( '%s ago',    'buddypress' ) );
    604        
     604
    605605        // array of time period chunks
    606606        $chunks = array(
    607607                array( 60 * 60 * 24 * 365 , __( 'year',   'buddypress' ), __( 'years',   'buddypress' ) ),
    function bp_core_time_since( $older_date, $newer_date = false ) { 
    632632        // Something went wrong with date calculation and we ended up with a negative date.
    633633        if ( 0 > $since ) {
    634634                $output = $unknown_text;
    635                
     635
    636636        /**
    637637         * We only want to output two chunks of time here, eg:
    638638         * x years, xx months
    function bp_embed_init() { 
    925925        if ( empty( $bp->embed ) )
    926926                $bp->embed = new BP_Embed();
    927927}
    928 add_action( 'bp_init', 'bp_embed_init' );
     928add_action( 'bp_init', 'bp_embed_init', 9 );
    929929
    930930/**
    931931 * When switching from single to multisite we need to copy blog options to
  • bp-themes/bp-default/_inc/global.js

    jq(document).ready( function() { 
    9191                                        var l = jq("ul#activity-stream li.new-update .activity-content .activity-inner p").html();
    9292                                        var v = jq("ul#activity-stream li.new-update .activity-content .activity-header p a.view").attr('href');
    9393
     94                                        var ltext = jq("ul#activity-stream li.new-update .activity-content .activity-inner p").text();
     95
     96                                        var u = '';
     97                                        if ( ltext != '' )
     98                                                u = l + '· ';
     99
     100                                        u += '<a href="' + v + '" rel="nofollow">' + BP_DTheme.view + '</a>';
     101
    94102                                        jq("div#latest-update").slideUp(300,function(){
    95                                                 jq("div#latest-update").html('"' + l + '" &middot; <a href="' + v + '" rel="nofollow">View</a>');
     103                                                jq("div#latest-update").html( u );
    96104                                                jq("div#latest-update").slideDown(300);
    97105                                        });
    98106                                }
  • bp-themes/bp-default/functions.php

    function bp_dtheme_enqueue_scripts() { 
    144144                'show_all_comments' => __( 'Show all comments for this thread', 'buddypress' ),
    145145                'show_all'          => __( 'Show all', 'buddypress' ),
    146146                'comments'          => __( 'comments', 'buddypress' ),
    147                 'close'             => __( 'Close', 'buddypress' )
     147                'close'             => __( 'Close', 'buddypress' ),
     148                'view'              => __( 'View', 'buddypress' )
    148149        );
    149150
    150151        wp_localize_script( 'dtheme-ajax-js', 'BP_DTheme', $params );
    if ( !function_exists( 'bp_dtheme_enqueue_styles' ) ) : 
    160161 * @since 1.3
    161162 */
    162163function bp_dtheme_enqueue_styles() {
    163        
     164
    164165        // Default CSS
    165166        wp_enqueue_style( 'bp-default-main',  get_template_directory_uri() . '/_inc/css/default.css', array(), BP_VERSION );
    166167
    if ( !function_exists( 'bp_dtheme_show_notice' ) ) : 
    515516 */
    516517function bp_dtheme_show_notice() {
    517518        global $pagenow;
    518        
     519
    519520        // Bail if bp-default theme was not just activated
    520521        if ( empty( $_GET['activated'] ) || ( 'themes.php' != $pagenow ) || !is_admin() )
    521522                return;
    522        
     523
    523524        ?>
    524525
    525526        <div id="message" class="updated fade">