<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[BuddyPress][4668] trunk: Tweak the activity stream styling - remove faux-buttons and replace with links.</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg > ul, #logmsg > ol { margin-left: 0; margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://buddypress.trac.wordpress.org/changeset/4668">4668</a></dd>
<dt>Author</dt> <dd>johnjamesjacoby</dd>
<dt>Date</dt> <dd>2011-07-17 05:39:42 +0000 (Sun, 17 Jul 2011)</dd>
</dl>
<h3>Log Message</h3>
<pre>Tweak the activity stream styling - remove faux-buttons and replace with links. Fix bp_dtheme_new_activity_comment() so that it uses the activity/comment.php template rather than being hardcoded into the function.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkbpactivitybpactivitytemplatephp">trunk/bp-activity/bp-activity-template.php</a></li>
<li><a href="#trunkbpthemesbpdefault_incajaxphp">trunk/bp-themes/bp-default/_inc/ajax.php</a></li>
<li><a href="#trunkbpthemesbpdefault_inccssdefaultcss">trunk/bp-themes/bp-default/_inc/css/default.css</a></li>
<li><a href="#trunkbpthemesbpdefaultactivitycommentphp">trunk/bp-themes/bp-default/activity/comment.php</a></li>
<li><a href="#trunkbpthemesbpdefaultactivityentryphp">trunk/bp-themes/bp-default/activity/entry.php</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkbpactivitybpactivitytemplatephp"></a>
<div class="modfile"><h4>Modified: trunk/bp-activity/bp-activity-template.php (4667 => 4668)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-activity/bp-activity-template.php        2011-07-16 22:34:49 UTC (rev 4667)
+++ trunk/bp-activity/bp-activity-template.php        2011-07-17 05:39:42 UTC (rev 4668)
</span><span class="lines">@@ -707,13 +707,10 @@
</span><span class="cx">         
</span><span class="cx">                 // Insert the permalink
</span><span class="cx">                 if ( !bp_is_single_activity() )
</span><del>-                        $content .= apply_filters_ref_array( 'bp_activity_permalink', array( sprintf( ' about <a href="%1$s" class="view" title="%2$s">%3$s</a>', bp_activity_get_permalink( $activities_template->activity->id, $activities_template->activity ), esc_attr__( 'View Discussion', 'buddypress' ), $time_since ), &$activities_template->activity ) );
</del><ins>+                        $content = apply_filters_ref_array( 'bp_activity_permalink', array( sprintf( '%1$s <a href="%2$s" class="view" title="%3$s">%4$s</a>', $content, bp_activity_get_permalink( $activities_template->activity->id, $activities_template->activity ), esc_attr__( 'View Discussion', 'buddypress' ), $time_since ), &$activities_template->activity ) );
</ins><span class="cx">                 else
</span><span class="cx">                         $content .= $time_since;
</span><span class="cx">
</span><del>-                if ( is_user_logged_in() && bp_activity_can_comment() )
-                        $content .= sprintf( '<a href="%1$s" class="acomment-reply bp-primary-action" id="acomment-comment-%2$d">%3$s</a>', bp_get_activity_comment_link(), bp_get_activity_id(), sprintf( __( 'Reply (<span>%s</span>)', 'buddypress' ), bp_activity_get_comment_count() ) );
-
</del><span class="cx">                 return apply_filters( 'bp_insert_activity_meta', $content );
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkbpthemesbpdefault_incajaxphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-themes/bp-default/_inc/ajax.php (4667 => 4668)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-themes/bp-default/_inc/ajax.php        2011-07-16 22:34:49 UTC (rev 4667)
+++ trunk/bp-themes/bp-default/_inc/ajax.php        2011-07-17 05:39:42 UTC (rev 4668)
</span><span class="lines">@@ -177,7 +177,7 @@
</span><span class="cx"> function bp_dtheme_new_activity_comment() {
</span><span class="cx">         global $bp;
</span><span class="cx">
</span><del>-        /* Check the nonce */
</del><ins>+        // Check the nonce
</ins><span class="cx">         check_admin_referer( 'new_activity_comment', '_wpnonce_new_activity_comment' );
</span><span class="cx">
</span><span class="cx">         if ( !is_user_logged_in() ) {
</span><span class="lines">@@ -197,43 +197,36 @@
</span><span class="cx">
</span><span class="cx">         $comment_id = bp_activity_new_comment( array(
</span><span class="cx">                 'activity_id' => $_POST['form_id'],
</span><del>-                'content' => $_POST['content'],
-                'parent_id' => $_POST['comment_id']
-        ));
</del><ins>+                'content' => $_POST['content'],
+                'parent_id' => $_POST['comment_id']
+        ) );
</ins><span class="cx">
</span><span class="cx">         if ( !$comment_id ) {
</span><span class="cx">                 echo '-1<div id="message" class="error"><p>' . __( 'There was an error posting that reply, please try again.', 'buddypress' ) . '</p></div>';
</span><span class="cx">                 return false;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if ( bp_has_activities ( 'display_comments=stream&include=' . $comment_id ) ) : ?>
-                <?php while ( bp_activities() ) : bp_the_activity(); ?>
-                        <li id="acomment-<?php bp_activity_id() ?>">
-                                <div class="acomment-avatar">
-                                        <a href="<?php echo bp_core_get_userlink( bp_get_activity_user_id(), false, true ); ?>"><?php bp_activity_avatar( array( 'height' => 30, 'width' => 30 ) ); ?></a>
-                                </div>
</del><ins>+        global $activities_template;
</ins><span class="cx">
</span><del>-                                <div class="acomment-meta">
-                                        <?php
-                                        /* translators: 1: user profile link + username, 2: activity item permalink, 3: activity item timestamp */
-                                        printf( __( '%1$s replied <a href="%2$s">%3$s ago</a>', 'buddypress' ), bp_core_get_userlink( bp_get_activity_user_id() ), bp_get_activity_thread_permalink(), bp_core_time_since( bp_core_current_time() ) );
-                                        ?>
</del><ins>+        // Load the nem activity item into the $activities_template global
+        bp_has_activities( 'display_comments=stream&include=' . $comment_id );
</ins><span class="cx">
</span><del>-                                        <a class="acomment-reply bp-primary-action" href="#acomment-<?php bp_activity_id() ?>" id="acomment-reply-<?php echo esc_attr( $_POST['form_id'] ) ?>"><?php _e( 'Reply', 'buddypress' ); ?></a>
</del><ins>+        // Swap the current comment with the activity item we just loaded
+        $activities_template->activity->id = $activities_template->activities[0]->item_id;
+        $activities_template->activity->current_comment = $activities_template->activities[0];
</ins><span class="cx">
</span><del>-                                        <?php if ( bp_activity_user_can_delete() ) : ?>
-                                                <div class="acomment-options">
-                                                        <a href="<?php echo wp_nonce_url( bp_get_root_domain() . '/' . bp_get_activity_root_slug() . '/delete/' . bp_get_activity_id() . '?cid=' . $comment_id, 'bp_activity_delete_link' ) ?>" class="delete acomment-delete confirm bp-secondary-action" rel="nofollow"><?php _e( 'Delete', 'buddypress' ); ?></a>
-                                                </div>
-                                        <?php endif; ?>
-                                </div>
</del><ins>+        $template = locate_template( 'activity/comment.php', false, false );
</ins><span class="cx">
</span><del>-                                <div class="acomment-content">
-                                        <?php bp_activity_content_body(); ?>
-                                </div>
-                        </li>
-                <?php endwhile; ?>
-         <?php endif;
</del><ins>+        // Backward compatibility. In older versions of BP, the markup was
+        // generated in the PHP instead of a template. This ensures that
+        // older themes (which are not children of bp-default and won't
+        // have the new template) will still work.
+        if ( empty( $template ) )
+                $template = BP_PLUGIN_DIR . '/bp-themes/bp-default/activity/comment.php';
+
+        load_template( $template, false );
+
+        unset( $activities_template );
</ins><span class="cx"> }
</span><span class="cx"> add_action( 'wp_ajax_new_activity_comment', 'bp_dtheme_new_activity_comment' );
</span><span class="cx">
</span></span></pre></div>
<a id="trunkbpthemesbpdefault_inccssdefaultcss"></a>
<div class="modfile"><h4>Modified: trunk/bp-themes/bp-default/_inc/css/default.css (4667 => 4668)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-themes/bp-default/_inc/css/default.css        2011-07-16 22:34:49 UTC (rev 4667)
+++ trunk/bp-themes/bp-default/_inc/css/default.css        2011-07-17 05:39:42 UTC (rev 4668)
</span><span class="lines">@@ -762,11 +762,6 @@
</span><span class="cx"> div.comment-meta em {
</span><span class="cx">         font-style: normal;
</span><span class="cx"> }
</span><del>-a.bp-secondary-action:hover {
-        background: #059AE7;
-        border-color: #059AE7;
-        color: #fff;
-}
</del><span class="cx"> #reply-title {
</span><span class="cx">         margin-top: 0;
</span><span class="cx"> }
</span><span class="lines">@@ -1042,6 +1037,9 @@
</span><span class="cx"> /*--------------------------------------------------------------
</span><span class="cx"> 6.1 - Activity
</span><span class="cx"> --------------------------------------------------------------*/
</span><ins>+#activity-stream {
+        margin-top: -5px;
+}
</ins><span class="cx"> #item-body form#whats-new-form {
</span><span class="cx">         border-bottom: 1px solid #ddd;
</span><span class="cx">         margin: 20px 0 10px;
</span><span class="lines">@@ -1117,16 +1115,10 @@
</span><span class="cx">         padding: 15px 0 0 0;
</span><span class="cx">         position: relative;
</span><span class="cx"> }
</span><del>-.activity-list li.mini div.activity-meta {
-        margin: 0;
-}
-.activity-list li.mini div.activity-meta a {
-        padding: 3px 8px;
-}
</del><span class="cx"> .activity-list li.mini .activity-avatar img.avatar,
</span><span class="cx"> .activity-list li.mini .activity-avatar img.FB_profile_pic {
</span><span class="cx">         height: 20px;
</span><del>-        margin-left: 76px;
</del><ins>+        margin-left: 30px;
</ins><span class="cx">         width: 20px;
</span><span class="cx"> }
</span><span class="cx"> .activity-list li.activity_comment .activity-avatar img.avatar,
</span><span class="lines">@@ -1148,32 +1140,18 @@
</span><span class="cx">         position: relative;
</span><span class="cx"> }
</span><span class="cx"> .activity-list li.mini .activity-content p {
</span><del>-        float: left;
</del><span class="cx">         margin: 0;
</span><span class="cx"> }
</span><del>-.activity-list li .activity-meta {
-        position: absolute;
-        right: 0;
-        top: 0;
-}
-body.activity-permalink .activity-list .activity-meta {
-        right: 10px;
-        top: 18px;
-}
-body.activity-permalink .activity-list li.mini .activity-meta {
-        position: absolute;
-        right: 15px;
-}
</del><span class="cx"> .activity-list li.mini .activity-comments {
</span><del>-        clear: left;
</del><ins>+        clear: both;
</ins><span class="cx">         font-size: 12px;
</span><span class="cx">         margin-top: 30px;
</span><span class="cx"> }
</span><span class="cx"> .activity-list li .activity-inreplyto {
</span><span class="cx">         background: url( ../images/replyto_arrow.gif ) 7px 0 no-repeat;
</span><del>-        color: #888;
</del><ins>+        color: #bbb;
</ins><span class="cx">         font-size: 11px;
</span><del>-        margin-left: 70px;
</del><ins>+        margin-left: 0;
</ins><span class="cx">         margin-bottom: 15px;
</span><span class="cx">         padding-left: 25px;
</span><span class="cx"> }
</span><span class="lines">@@ -1229,7 +1207,7 @@
</span><span class="cx">         line-height: 220%;
</span><span class="cx"> }
</span><span class="cx"> .activity-header {
</span><del>-        margin-right: 130px;
</del><ins>+        margin-right: 20px;
</ins><span class="cx"> }
</span><span class="cx"> .activity-header a,
</span><span class="cx"> .comment-meta a,
</span><span class="lines">@@ -1242,20 +1220,14 @@
</span><span class="cx"> }
</span><span class="cx"> a.bp-secondary-action,
</span><span class="cx"> span.highlight {
</span><del>-        background: #ebf7ff;
-        border-bottom: 1px solid #a1dcfa;
-        border-right: 1px solid #a1dcfa;
-        -moz-border-radius: 4px;
-        -webkit-border-radius: 4px;
-        border-radius: 4px;
-        color: #059ae7;
</del><span class="cx">         font-size: 11px;
</span><del>-        padding: 3px 8px;
</del><ins>+        padding: 0;
+        margin-right: 10px;
</ins><span class="cx">         text-decoration: none;
</span><span class="cx"> }
</span><span class="cx"> .activity-list .activity-content .activity-inner,
</span><span class="cx"> .activity-list .activity-content blockquote {
</span><del>-        margin: 15px 0;
</del><ins>+        margin: 10px 10px 5px 0;
</ins><span class="cx">         overflow: hidden;
</span><span class="cx"> }
</span><span class="cx"> body.activity-permalink .activity-content .activity-inner,
</span><span class="lines">@@ -1276,6 +1248,7 @@
</span><span class="cx"> }
</span><span class="cx"> .activity-read-more {
</span><span class="cx">         margin-left: 1em;
</span><ins>+        white-space: nowrap;
</ins><span class="cx"> }
</span><span class="cx"> .activity-list li.load-more {
</span><span class="cx">         background: #f0f0f0 !important;
</span><span class="lines">@@ -1298,35 +1271,33 @@
</span><span class="cx"> 6.1.2 - Activity Comments
</span><span class="cx"> --------------------------------------------------------------*/
</span><span class="cx"> div.activity-meta {
</span><del>-        clear: left;
-        margin: 0 10px 20px 0;
</del><ins>+        float: left;
+        margin: 5px 0 10px 0;
+        clear: both;
</ins><span class="cx"> }
</span><ins>+div.activity-meta a {
+        color: #999;
+}
+div.activity-meta a:hover {
+        color: inherit;
+}
</ins><span class="cx"> a.bp-primary-action,
</span><span class="cx"> .comment-reply-link,
</span><span class="cx"> #reply-title small a {
</span><del>-        background: #fff9db;
-        border-bottom: 1px solid #ffe8c4;
-        -moz-border-radius: 4px;
-        -webkit-border-radius: 4px;
-        border-radius: 4px;
-        border-right: 1px solid #ffe8c4;
-        color: #ffa200;
</del><span class="cx">         font-size: 11px;
</span><del>-        padding: 3px 8px;
</del><ins>+        margin-right: 10px;
</ins><span class="cx">         text-decoration: none;
</span><span class="cx"> }
</span><span class="cx"> a.bp-primary-action:hover,
</span><span class="cx"> .comment-reply-link:hover,
</span><span class="cx"> #reply-title small a:hover {
</span><del>-        background: #f7740a;
-        border-color: #f7740a;
-        color: #fff;
</del><span class="cx"> }
</span><span class="cx"> div.activity-comments {
</span><span class="cx">         margin: 0 0 0 70px;
</span><span class="cx">         overflow: hidden; /* IE fix */
</span><span class="cx">         position: relative;
</span><span class="cx">         width: auto;
</span><ins>+        clear: both;
</ins><span class="cx"> }
</span><span class="cx"> body.activity-permalink div.activity-comments {
</span><span class="cx">         background: none;
</span><span class="lines">@@ -1346,7 +1317,7 @@
</span><span class="cx">         list-style: none;
</span><span class="cx"> }
</span><span class="cx"> div.activity-comments ul {
</span><del>-        clear: left;
</del><ins>+        clear: both;
</ins><span class="cx"> }
</span><span class="cx"> div.activity-comments ul li {
</span><span class="cx">         border-top: 2px solid #fff;
</span><span class="lines">@@ -1384,9 +1355,7 @@
</span><span class="cx"> }
</span><span class="cx"> div.activity-comments div.acomment-content {
</span><span class="cx">         font-size: 11px;
</span><del>-        margin-left: 39px;
-        margin-top: 5px;
-        margin-bottom: 10px;
</del><ins>+        margin: 5px 20px 0 40px;
</ins><span class="cx"> }
</span><span class="cx"> div.acomment-content .time-since,
</span><span class="cx"> div.acomment-content .activity-delete-link,
</span><span class="lines">@@ -1412,6 +1381,7 @@
</span><span class="cx"> }
</span><span class="cx"> div.activity-comments li form.ac-form {
</span><span class="cx">         margin-right: 15px;
</span><ins>+        clear: both;
</ins><span class="cx"> }
</span><span class="cx"> div.activity-comments form.root {
</span><span class="cx">         margin-left: 0;
</span><span class="lines">@@ -1459,9 +1429,15 @@
</span><span class="cx">         padding-left: 15px;
</span><span class="cx"> }
</span><span class="cx"> .acomment-options {
</span><del>-        float: right;
-        margin-right: 10px;
</del><ins>+        float: left;
+        margin: 5px 0 5px 40px;
</ins><span class="cx"> }
</span><ins>+.acomment-options a {
+        color: #999;
+}
+.acomment-options a:hover {
+        color: inherit;
+}
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> /*--------------------------------------------------------------
</span></span></pre></div>
<a id="trunkbpthemesbpdefaultactivitycommentphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-themes/bp-default/activity/comment.php (4667 => 4668)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-themes/bp-default/activity/comment.php        2011-07-16 22:34:49 UTC (rev 4667)
+++ trunk/bp-themes/bp-default/activity/comment.php        2011-07-17 05:39:42 UTC (rev 4668)
</span><span class="lines">@@ -26,23 +26,27 @@
</span><span class="cx">                 /* translators: 1: user profile link, 2: user name, 3: activity permalink, 3: activity timestamp */
</span><span class="cx">                 printf( __( '<a href="%1$s">%2$s</a> replied <a href="%3$s">%4$s</a>', 'buddypress' ), bp_get_activity_comment_user_link(), bp_get_activity_comment_name(), bp_get_activity_thread_permalink(), bp_get_activity_comment_date_recorded() );
</span><span class="cx">                 ?>
</span><ins>+        </div>
</ins><span class="cx">
</span><ins>+        <div class="acomment-content"><?php bp_activity_comment_content(); ?></div>
+
+        <div class="acomment-options">
+
</ins><span class="cx">                 <?php if ( is_user_logged_in() && bp_activity_can_comment_reply( bp_activity_current_comment() ) ) : ?>
</span><del>-                        <a href="#acomment-<?php bp_activity_comment_id(); ?>" class="acomment-reply bp-primary-action" id="acomment-reply-<?php bp_activity_id() ?>-from-<?php bp_activity_comment_id() ?>"><?php _e( 'Reply', 'buddypress' ); ?></a>
</del><ins>+
+                        <a href="#acomment-<?php bp_activity_comment_id(); ?>" class="acomment-reply bp-primary-action" id="acomment-reply-<?php bp_activity_id() ?>-from-<?php bp_activity_comment_id() ?>"><?php _e( 'Comment', 'buddypress' ); ?></a>
+
</ins><span class="cx">                 <?php endif; ?>
</span><span class="cx">
</span><span class="cx">                 <?php if ( bp_activity_user_can_delete() ) : ?>
</span><del>-                        <div class="acomment-options">
-                                <a href="<?php bp_activity_comment_delete_link(); ?>" class="delete acomment-delete confirm bp-secondary-action" rel="nofollow"><?php _e( 'Delete', 'buddypress' ); ?></a>
-                        </div>
</del><ins>+
+                        <a href="<?php bp_activity_comment_delete_link(); ?>" class="delete acomment-delete confirm bp-secondary-action" rel="nofollow"><?php _e( 'Delete', 'buddypress' ); ?></a>
+
</ins><span class="cx">                 <?php endif; ?>
</span><ins>+
</ins><span class="cx">         </div>
</span><span class="cx">
</span><del>-        <div class="acomment-content">
-                <?php bp_activity_comment_content(); ?>
-        </div>
-        
</del><span class="cx">         <?php bp_activity_recurse_comments( bp_activity_current_comment() ); ?>
</span><span class="cx"> </li>
</span><span class="cx">
</span><del>-<?php do_action( 'bp_after_activity_comment' ); ?>
</del><span class="cx">\ No newline at end of file
</span><ins>+<?php do_action( 'bp_after_activity_comment' ); ?>
</ins></span></pre></div>
<a id="trunkbpthemesbpdefaultactivityentryphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-themes/bp-default/activity/entry.php (4667 => 4668)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-themes/bp-default/activity/entry.php        2011-07-16 22:34:49 UTC (rev 4667)
+++ trunk/bp-themes/bp-default/activity/entry.php        2011-07-17 05:39:42 UTC (rev 4668)
</span><span class="lines">@@ -31,6 +31,15 @@
</span><span class="cx">
</span><span class="cx">                 </div>
</span><span class="cx">
</span><ins>+                <?php if ( 'activity_comment' == bp_get_activity_type() ) : ?>
+
+                        <div class="activity-inreplyto">
+                                <strong><?php _e( 'In reply to', 'buddypress' ); ?></strong> - <?php bp_activity_parent_content(); ?> &middot;
+                                <a href="<?php bp_activity_thread_permalink(); ?>" class="view" title="<?php _e( 'View Thread / Permalink', 'buddypress' ); ?>"><?php _e( 'View', 'buddypress' ); ?></a>
+                        </div>
+
+                <?php endif; ?>
+
</ins><span class="cx">                 <?php if ( bp_activity_has_content() ) : ?>
</span><span class="cx">
</span><span class="cx">                         <div class="activity-inner">
</span><span class="lines">@@ -43,58 +52,66 @@
</span><span class="cx">
</span><span class="cx">                 <?php do_action( 'bp_activity_entry_content' ); ?>
</span><span class="cx">
</span><del>-                <div class="activity-meta">
-                        <?php
-                                // Add the delete link if the user has permission on this item
-                                if ( bp_activity_user_can_delete() )
-                                        bp_activity_delete_link();
-                        ?>
</del><ins>+                <?php if ( is_user_logged_in() ) : ?>
</ins><span class="cx">
</span><del>-                        <?php if ( is_user_logged_in() && bp_activity_can_favorite() ) : ?>
-                                <?php if ( !bp_get_activity_is_favorite() ) : ?>
-                                        <a href="<?php bp_activity_favorite_link(); ?>" class="fav bp-secondary-action" title="<?php esc_attr_e( 'Mark as Favorite', 'buddypress' ); ?>"><?php _e( 'Favorite', 'buddypress' ) ?></a>
-                                <?php else : ?>
-                                        <a href="<?php bp_activity_unfavorite_link(); ?>" class="unfav bp-secondary-action" title="<?php esc_attr_e( 'Remove Favorite', 'buddypress' ); ?>"><?php _e( 'Remove Favorite', 'buddypress' ) ?></a>
</del><ins>+                        <div class="activity-meta">
+
+                                <?php if ( bp_activity_can_comment() ) : ?>
+
+                                        <a href="<?php bp_get_activity_comment_link(); ?>" class="acomment-reply bp-primary-action" id="acomment-comment-<?php bp_activity_id(); ?>"><?php printf( __( 'Comment (<span>%s</span>)', 'buddypress' ), bp_activity_get_comment_count() ); ?></a>
+
</ins><span class="cx">                                 <?php endif; ?>
</span><del>-                        <?php endif; ?>
</del><span class="cx">
</span><del>-                        <?php do_action( 'bp_activity_entry_meta' ); ?>
-                </div>
-        </div>
</del><ins>+                                <?php if ( bp_activity_can_favorite() ) : ?>
</ins><span class="cx">
</span><del>-        <?php if ( 'activity_comment' == bp_get_activity_type() ) : ?>
</del><ins>+                                        <?php if ( !bp_get_activity_is_favorite() ) : ?>
</ins><span class="cx">
</span><del>-                <div class="activity-inreplyto">
-                        <strong><?php _e( 'In reply to', 'buddypress' ); ?></strong> - <?php bp_activity_parent_content(); ?> &middot;
-                        <a href="<?php bp_activity_thread_permalink(); ?>" class="view" title="<?php _e( 'View Thread / Permalink', 'buddypress' ); ?>"><?php _e( 'View', 'buddypress' ); ?></a>
-                </div>
</del><ins>+                                                <a href="<?php bp_activity_favorite_link(); ?>" class="fav bp-secondary-action" title="<?php esc_attr_e( 'Mark as Favorite', 'buddypress' ); ?>"><?php _e( 'Favorite', 'buddypress' ) ?></a>
</ins><span class="cx">
</span><del>-        <?php endif; ?>
</del><ins>+                                        <?php else : ?>
</ins><span class="cx">
</span><ins>+                                                <a href="<?php bp_activity_unfavorite_link(); ?>" class="unfav bp-secondary-action" title="<?php esc_attr_e( 'Remove Favorite', 'buddypress' ); ?>"><?php _e( 'Remove Favorite', 'buddypress' ) ?></a>
+
+                                        <?php endif; ?>
+
+                                <?php endif; ?>
+
+                                <?php if ( bp_activity_user_can_delete() ) bp_activity_delete_link(); ?>
+
+                                <?php do_action( 'bp_activity_entry_meta' ); ?>
+
+                        </div>
+
+                <?php endif; ?>
+
+        </div>
+
</ins><span class="cx">         <?php do_action( 'bp_before_activity_entry_comments' ); ?>
</span><span class="cx">
</span><span class="cx">         <?php if ( bp_activity_can_comment() ) : ?>
</span><ins>+
</ins><span class="cx">                 <div class="activity-comments">
</span><span class="cx">                         
</span><span class="cx">                         <?php bp_activity_comments(); ?>
</span><span class="cx">
</span><span class="cx">                         <?php if ( is_user_logged_in() ) : ?>
</span><span class="cx">
</span><del>-                        <form action="<?php bp_activity_comment_form_action(); ?>" method="post" id="ac-form-<?php bp_activity_id(); ?>" class="ac-form"<?php bp_activity_comment_form_nojs_display(); ?>>
-                                <div class="ac-reply-avatar"><?php bp_loggedin_user_avatar( 'width=' . bp_core_avatar_thumb_width() . '&height=' . bp_core_avatar_thumb_height() ); ?></div>
-                                <div class="ac-reply-content">
-                                        <div class="ac-textarea">
-                                                <textarea id="ac-input-<?php bp_activity_id(); ?>" class="ac-input" name="ac_input_<?php bp_activity_id(); ?>"></textarea>
</del><ins>+                                <form action="<?php bp_activity_comment_form_action(); ?>" method="post" id="ac-form-<?php bp_activity_id(); ?>" class="ac-form"<?php bp_activity_comment_form_nojs_display(); ?>>
+                                        <div class="ac-reply-avatar"><?php bp_loggedin_user_avatar( 'width=' . BP_AVATAR_THUMB_WIDTH . '&height=' . BP_AVATAR_THUMB_HEIGHT ); ?></div>
+                                        <div class="ac-reply-content">
+                                                <div class="ac-textarea">
+                                                        <textarea id="ac-input-<?php bp_activity_id(); ?>" class="ac-input" name="ac_input_<?php bp_activity_id(); ?>"></textarea>
+                                                </div>
+                                                <input type="submit" name="ac_form_submit" value="<?php _e( 'Post', 'buddypress' ); ?> &rarr;" /> &nbsp; <?php _e( 'or press esc to cancel.', 'buddypress' ); ?>
+                                                <input type="hidden" name="comment_form_id" value="<?php bp_activity_id(); ?>" />
</ins><span class="cx">                                         </div>
</span><del>-                                        <input type="submit" name="ac_form_submit" value="<?php _e( 'Post', 'buddypress' ); ?> &rarr;" /> &nbsp; <?php _e( 'or press esc to cancel.', 'buddypress' ); ?>
-                                        <input type="hidden" name="comment_form_id" value="<?php bp_activity_id(); ?>" />
-                                </div>
</del><span class="cx">
</span><del>-                                <?php do_action( 'bp_activity_entry_comments' ); ?>
-                                <?php wp_nonce_field( 'new_activity_comment', '_wpnonce_new_activity_comment' ); ?>
</del><ins>+                                        <?php do_action( 'bp_activity_entry_comments' ); ?>
</ins><span class="cx">
</span><del>-                        </form>
</del><ins>+                                        <?php wp_nonce_field( 'new_activity_comment', '_wpnonce_new_activity_comment' ); ?>
</ins><span class="cx">
</span><ins>+                                </form>
+
</ins><span class="cx">                         <?php endif; ?>
</span><span class="cx">
</span><span class="cx">                 </div>
</span></span></pre>
</div>
</div>
</body>
</html>