Skip to:
Content

BuddyPress.org

Changeset 2558


Ignore:
Timestamp:
02/03/2010 11:32:07 AM (14 years ago)
Author:
apeatling
Message:

Fixes #1755

Location:
trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-messages.php

    r2450 r2558  
    101101    global $bp;
    102102
    103     if ( $bp->current_component == $bp->messages->slug ) {
    104         $inbox_count = messages_get_unread_count();
    105         $inbox_display = ( $inbox_count ) ? ' style="display:inline;"' : ' style="display:none;"';
    106         $count_indicator = '&nbsp; <span' . $inbox_display . ' class="unread-count inbox-count">' . $inbox_count . '</span>';
    107     }
     103    if ( $count = messages_get_unread_count() )
     104        $name = sprintf( __('Messages <strong>(%s)</strong>', 'buddypress'), $count );
     105    else
     106        $name = __('Messages <strong></strong>', 'buddypress');
    108107
    109108    /* Add 'Messages' to the main navigation */
    110     bp_core_new_nav_item( array( 'name' => __('Messages', 'buddypress'), 'slug' => $bp->messages->slug, 'position' => 50, 'show_for_displayed_user' => false, 'screen_function' => 'messages_screen_inbox', 'default_subnav_slug' => 'inbox', 'item_css_id' => $bp->messages->id ) );
     109    bp_core_new_nav_item( array( 'name' => $name, 'slug' => $bp->messages->slug, 'position' => 50, 'show_for_displayed_user' => false, 'screen_function' => 'messages_screen_inbox', 'default_subnav_slug' => 'inbox', 'item_css_id' => $bp->messages->id ) );
    111110
    112111    $messages_link = $bp->loggedin_user->domain . $bp->messages->slug . '/';
  • trunk/bp-messages/bp-messages-classes.php

    r2502 r2558  
    161161        global $wpdb, $bp;
    162162
    163         $sql = $wpdb->prepare( "SELECT unread_count FROM {$bp->messages->table_name_recipients} WHERE user_id = %d AND is_deleted = 0", $bp->loggedin_user->id );
     163        $sql = $wpdb->prepare( "SELECT unread_count FROM {$bp->messages->table_name_recipients} WHERE user_id = %d AND is_deleted = 0 AND sender_only = 0", $bp->loggedin_user->id );
    164164
    165165        if ( !$unread_counts = $wpdb->get_results($sql) )
  • trunk/bp-themes/bp-default/_inc/css/default.css

    r2544 r2558  
    847847    }
    848848
     849    table.profile-fields { margin-bottom: 20px;}
     850
    849851    div#sidebar table {
    850852        margin: 0 -16px;
  • trunk/bp-themes/bp-default/_inc/global.js

    r2555 r2558  
    879879                    j('tr#m-' + j(this).attr('value') + ' td span.unread-count').html(unreadCount);
    880880                    j('tr#m-' + j(this).attr('value') + ' td span.unread-count').css('display', unreadCountDisplay);
    881                     var inboxcount = j('.inbox-count').html();
    882 
     881                    var inboxcount = j('a#user-messages strong').html().substr( 1, j('a#user-messages strong').html().length );
     882                    var inboxcount = inboxcount.substr( 0, inboxcount.length - 1 );
     883
     884                    if ( !inboxcount.length )
     885                        inboxcount = 0;
    883886                    if ( parseInt(inboxcount) == inboxCount ) {
    884                         j('.inbox-count').css('display', unreadCountDisplay);
    885                         j('.inbox-count').html(unreadCount);
     887                        j('a#user-messages strong').css('display', unreadCountDisplay);
     888                        j('a#user-messages strong').html( '(' + unreadCount + ')' );
    886889                    } else {
    887890                        if ( 'read' == currentClass )
    888                             j('.inbox-count').html(parseInt(inboxcount) + 1);
     891                            j('a#user-messages strong').html('(' + ( parseInt(inboxcount) + 1 ) + ')');
    889892                        else
    890                             j('.inbox-count').html(parseInt(inboxcount) - thread_count);
     893                            j('a#user-messages strong').html('(' + ( parseInt(inboxcount) - thread_count ) + ')');
    891894                    }
    892895
  • trunk/bp-themes/bp-default/members/single/profile/change-avatar.php

    r2386 r2558  
    1 <h3><?php _e( 'Change Avatar', 'buddypress' ) ?></h3>
     1<h4><?php _e( 'Change Avatar', 'buddypress' ) ?></h4>
    22
    33<?php do_action( 'bp_before_profile_avatar_upload_content' ) ?>
     
    3030        <?php if ( 'crop-image' == bp_get_avatar_admin_step() ) : ?>
    3131
    32             <h3><?php _e( 'Crop Your New Avatar', 'buddypress' ) ?></h3>
     32            <h5><?php _e( 'Crop Your New Avatar', 'buddypress' ) ?></h5>
    3333
    3434            <img src="<?php bp_avatar_to_crop() ?>" id="avatar-to-crop" class="avatar" alt="<?php _e( 'Avatar to crop', 'buddypress' ) ?>" />
  • trunk/bp-themes/bp-default/members/single/profile/edit.php

    r2170 r2558  
    77    <?php do_action( 'bp_before_profile_field_content' ) ?>
    88
    9         <h3><?php printf( __( "Editing '%s' Profile Group", "buddypress" ), bp_get_the_profile_group_name() ); ?></h3>
     9        <h4><?php printf( __( "Editing '%s' Profile Group", "buddypress" ), bp_get_the_profile_group_name() ); ?></h4>
    1010
    1111        <ul class="button-nav">
  • trunk/bp-themes/bp-default/members/single/profile/profile-loop.php

    r2284 r2558  
    1212
    1313                <div class="bp-widget <?php bp_the_profile_group_slug() ?>">
    14                     <h3><?php bp_the_profile_group_name() ?></h3>
     14                    <h4><?php bp_the_profile_group_name() ?></h4>
    1515
    1616                    <table class="profile-fields">
Note: See TracChangeset for help on using the changeset viewer.