<!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][5498] trunk/bp-activity: On activity admin edit screen, don't show move cursor for action/content metaboxes, and disable close/open toggle.</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/5498">5498</a></dd>
<dt>Author</dt> <dd>djpaul</dd>
<dt>Date</dt> <dd>2011-12-11 00:23:13 +0000 (Sun, 11 Dec 2011)</dd>
</dl>
<h3>Log Message</h3>
<pre>On activity admin edit screen, don't show move cursor for action/content metaboxes, and disable close/open toggle. See <a href="http://buddypress.trac.wordpress.org/ticket/3832">#3832</a></pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkbpactivityadmincssadmincss">trunk/bp-activity/admin/css/admin.css</a></li>
<li><a href="#trunkbpactivityadmincssadmindevcss">trunk/bp-activity/admin/css/admin.dev.css</a></li>
<li><a href="#trunkbpactivityadminjsadmindevjs">trunk/bp-activity/admin/js/admin.dev.js</a></li>
<li><a href="#trunkbpactivityadminjsadminjs">trunk/bp-activity/admin/js/admin.js</a></li>
<li><a href="#trunkbpactivitybpactivityadminphp">trunk/bp-activity/bp-activity-admin.php</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkbpactivityadmincssadmincss"></a>
<div class="modfile"><h4>Modified: trunk/bp-activity/admin/css/admin.css (5497 => 5498)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-activity/admin/css/admin.css        2011-12-10 23:31:10 UTC (rev 5497)
+++ trunk/bp-activity/admin/css/admin.css        2011-12-11 00:23:13 UTC (rev 5498)
</span><span class="lines">@@ -1 +1 @@
</span><del>-#wp-bp-activities-wrap{padding:5px 0;}#bp-activities{height:120px;}#bp-replyhead{font-size:1em;line-height:1.4em;margin:0;}#bp-replysubmit{margin:0;padding:0 0 3px;text-align:center;}#bp-replysubmit .error{color:red;line-height:21px;text-align:center;vertical-align:center;}#bp-replysubmit img.waiting{float:right;padding:4px 10px 0;vertical-align:top;}#bp-activities-form .column-response img{float:left;margin-right:10px;margin-top:1px;}#bp_activity_action div.inside,#bp_activity_content div.inside{line-height:0;}#bp_activity_action td.mceIframeContainer,#bp_activity_content td.mceIframeContainer{background-color:white;}#post-body #bp-activities-action_resize,#post-body #bp-activities-content_resize{position:inherit;margin-top:-2px;}#bp_activity_link input{width:99%;}#bp-activities-primaryid{margin-bottom:1em;}
</del><span class="cx">\ No newline at end of file
</span><ins>+#wp-bp-activities-wrap{padding:5px 0;}#bp-activities{height:120px;}#bp-replyhead{font-size:1em;line-height:1.4em;margin:0;}#bp-replysubmit{margin:0;padding:0 0 3px;text-align:center;}#bp-replysubmit .error{color:red;line-height:21px;text-align:center;vertical-align:center;}#bp-replysubmit img.waiting{float:right;padding:4px 10px 0;vertical-align:top;}#bp-activities-form .column-response img{float:left;margin-right:10px;margin-top:1px;}#bp_activity_action div.inside,#bp_activity_content div.inside{line-height:0;}#bp_activity_action h3,#bp_activity_content h3{cursor:auto;}#bp_activity_action td.mceIframeContainer,#bp_activity_content td.mceIframeContainer{background-color:white;}#post-body #bp-activities-action_resize,#post-body #bp-activities-content_resize{position:inherit;margin-top:-2px;}#bp_activity_link input{width:99%;}#bp-activities-primaryid{margin-bottom:1em;}
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkbpactivityadmincssadmindevcss"></a>
<div class="modfile"><h4>Modified: trunk/bp-activity/admin/css/admin.dev.css (5497 => 5498)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-activity/admin/css/admin.dev.css        2011-12-10 23:31:10 UTC (rev 5497)
+++ trunk/bp-activity/admin/css/admin.dev.css        2011-12-11 00:23:13 UTC (rev 5498)
</span><span class="lines">@@ -35,6 +35,10 @@
</span><span class="cx"> #bp_activity_content div.inside {
</span><span class="cx">         line-height: 0;
</span><span class="cx"> }
</span><ins>+#bp_activity_action h3,
+#bp_activity_content h3 {
+        cursor: auto;
+}
</ins><span class="cx"> #bp_activity_action td.mceIframeContainer,
</span><span class="cx"> #bp_activity_content td.mceIframeContainer {
</span><span class="cx">         background-color: white;
</span></span></pre></div>
<a id="trunkbpactivityadminjsadmindevjs"></a>
<div class="modfile"><h4>Modified: trunk/bp-activity/admin/js/admin.dev.js (5497 => 5498)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-activity/admin/js/admin.dev.js        2011-12-10 23:31:10 UTC (rev 5497)
+++ trunk/bp-activity/admin/js/admin.dev.js        2011-12-11 00:23:13 UTC (rev 5498)
</span><span class="lines">@@ -1,7 +1,7 @@
</span><span class="cx"> (function( $ ) {
</span><span class="cx">
</span><span class="cx"> /**
</span><del>- * Activity reply object for the admin screen
</del><ins>+ * Activity reply object for the activity index screen
</ins><span class="cx"> *
</span><span class="cx"> * @since 1.6
</span><span class="cx"> */
</span><span class="lines">@@ -156,6 +156,12 @@
</span><span class="cx">         }
</span><span class="cx"> };
</span><span class="cx">
</span><del>-// Create the Activity reply object after domready event
-$(document).ready( activityReply.init );
</del><ins>+$(document).ready( function () {
+        // Create the Activity reply object after domready event
+        activityReply.init();
+
+        // On the edit screen, unload the close/open toggle js for the action & content metaboxes
+        $( '#bp_activity_action h3, #bp_activity_content h3' ).unbind( 'click' );
+});
+
</ins><span class="cx"> })(jQuery);
</span><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkbpactivityadminjsadminjs"></a>
<div class="modfile"><h4>Modified: trunk/bp-activity/admin/js/admin.js (5497 => 5498)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-activity/admin/js/admin.js        2011-12-10 23:31:10 UTC (rev 5497)
+++ trunk/bp-activity/admin/js/admin.js        2011-12-11 00:23:13 UTC (rev 5498)
</span><span class="lines">@@ -1 +1 @@
</span><del>-(function(a){activityReply={init:function(){a(document).on("click",".row-actions a.reply",activityReply.open);a(document).on("click","#bp-activities-container a.cancel",activityReply.close);a(document).on("click","#bp-activities-container a.save",activityReply.send);a(document).on("keyup","#bp-activities:visible",function(b){if(27==b.which){activityReply.close()}})},open:function(c){var b=a("#bp-activities-container").hide();a(this).parents("tr").after(b);b.fadeIn("300");a("#bp-activities").focus();return false},close:function(b){a("#bp-activities-container").fadeOut("200",function(){a("#bp-activities").val("").blur();a("#bp-replysubmit .error").html("").hide();a("#bp-replysubmit .waiting").hide()});return false},send:function(c){a("#bp-replysubmit .error").hide();a(
"#bp-replysubmit .waiting").show();var b={};b["_ajax_nonce-bp-activity-admin-reply"]=a('#bp-activities-container input[name="_ajax_nonce-bp-activity-admin-reply"]').val();b.action="bp-activity-admin-reply";b.content=a("#bp-activities").val();b.parent_id=a("#bp-activities-container").prev().data("parent_id");b.root_id=a("#bp-activities-container").prev().data("root_id");a.ajax({data:b,type:"POST",url:ajaxurl,error:function(d){activityReply.error(d)},success:function(d){activityReply.show(d)}});return false},error:function(b){var c=b.statusText;a("#bp-replysubmit .waiting").hide();if(b.responseText){c=b.responseText.replace(/<.[^<>]*?>/g,"")}if(c){a("#bp-replysubmit .error").html(c).show()}},show:function(c){var d,e,b;if(typeof(c)=="string"){activityReply.error({responseText:c});return false}b=wpAjax.parseAjaxResponse(c);if(b.e
rrors){activityReply.error({responseText:wpAjax.broken});return false}b=b.responses[0];a("#bp-activities-container").fadeOut("200",function(){a("#bp-activities").val("").blur();a("#bp-replysubmit .error").html("").hide();a("#bp-replysubmit .waiting").hide();a("#bp-activities-container").before(b.data);e=a("#activity-"+b.id);d=e.closest(".widefat").css("backgroundColor");e.animate({backgroundColor:"#CEB"},300).animate({backgroundColor:d},300)})}};a(document).ready(activityReply.init)})(jQuery);
</del><span class="cx">\ No newline at end of file
</span><ins>+(function(a){activityReply={init:function(){a(document).on("click",".row-actions a.reply",activityReply.open);a(document).on("click","#bp-activities-container a.cancel",activityReply.close);a(document).on("click","#bp-activities-container a.save",activityReply.send);a(document).on("keyup","#bp-activities:visible",function(b){if(27==b.which){activityReply.close()}})},open:function(c){var b=a("#bp-activities-container").hide();a(this).parents("tr").after(b);b.fadeIn("300");a("#bp-activities").focus();return false},close:function(b){a("#bp-activities-container").fadeOut("200",function(){a("#bp-activities").val("").blur();a("#bp-replysubmit .error").html("").hide();a("#bp-replysubmit .waiting").hide()});return false},send:function(c){a("#bp-replysubmit .error").hide();a(
"#bp-replysubmit .waiting").show();var b={};b["_ajax_nonce-bp-activity-admin-reply"]=a('#bp-activities-container input[name="_ajax_nonce-bp-activity-admin-reply"]').val();b.action="bp-activity-admin-reply";b.content=a("#bp-activities").val();b.parent_id=a("#bp-activities-container").prev().data("parent_id");b.root_id=a("#bp-activities-container").prev().data("root_id");a.ajax({data:b,type:"POST",url:ajaxurl,error:function(d){activityReply.error(d)},success:function(d){activityReply.show(d)}});return false},error:function(b){var c=b.statusText;a("#bp-replysubmit .waiting").hide();if(b.responseText){c=b.responseText.replace(/<.[^<>]*?>/g,"")}if(c){a("#bp-replysubmit .error").html(c).show()}},show:function(c){var d,e,b;if(typeof(c)=="string"){activityReply.error({responseText:c});return false}b=wpAjax.parseAjaxResponse(c);if(b.e
rrors){activityReply.error({responseText:wpAjax.broken});return false}b=b.responses[0];a("#bp-activities-container").fadeOut("200",function(){a("#bp-activities").val("").blur();a("#bp-replysubmit .error").html("").hide();a("#bp-replysubmit .waiting").hide();a("#bp-activities-container").before(b.data);e=a("#activity-"+b.id);d=e.closest(".widefat").css("backgroundColor");e.animate({backgroundColor:"#CEB"},300).animate({backgroundColor:d},300)})}};a(document).ready(function(){activityReply.init();a("#bp_activity_action h3, #bp_activity_content h3").unbind("click")})})(jQuery);
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkbpactivitybpactivityadminphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-activity/bp-activity-admin.php (5497 => 5498)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-activity/bp-activity-admin.php        2011-12-10 23:31:10 UTC (rev 5497)
+++ trunk/bp-activity/bp-activity-admin.php        2011-12-11 00:23:13 UTC (rev 5498)
</span><span class="lines">@@ -213,9 +213,6 @@
</span><span class="cx">                 wp_enqueue_script( 'dashboard' );
</span><span class="cx">                 wp_enqueue_script( 'comment' );
</span><span class="cx">
</span><del>-                // Enqueue CSS
-                wp_enqueue_style( 'bp_activity_admin_css', BP_PLUGIN_URL . "bp-activity/admin/css/admin.{$dev}css", array(), '20111210' );
-
</del><span class="cx">         // Index screen
</span><span class="cx">         } else {
</span><span class="cx">                 // Create the Activity screen list table
</span><span class="lines">@@ -247,12 +244,12 @@
</span><span class="cx">                         '<p><strong>' . __( 'For more information:', 'buddypress' ) . '</strong></p>' .
</span><span class="cx">                         '<p>' . __( '<a href="http://buddypress.org/support/">Support Forums</a>', 'buddypress' ) . '</p>'
</span><span class="cx">                 );
</span><del>-
-                // Enqueue CSS and JavaScript
-                wp_enqueue_script( 'bp_activity_admin_js', BP_PLUGIN_URL . "bp-activity/admin/js/admin.{$dev}js", array( 'jquery', 'wp-ajax-response' ), '20111120' );
-                wp_enqueue_style( 'bp_activity_admin_css', BP_PLUGIN_URL . "bp-activity/admin/css/admin.{$dev}css", array(), '20111203' );
</del><span class="cx">         }
</span><span class="cx">
</span><ins>+        // Enqueue CSS and JavaScript
+        wp_enqueue_script( 'bp_activity_admin_js', BP_PLUGIN_URL . "bp-activity/admin/js/admin.{$dev}js", array( 'jquery', 'wp-ajax-response' ), '20111211', true );
+        wp_enqueue_style( 'bp_activity_admin_css', BP_PLUGIN_URL . "bp-activity/admin/css/admin.{$dev}css", array(), '20111211' );
+
</ins><span class="cx">         // Handle spam/un-spam/delete of activities
</span><span class="cx">         if ( $doaction && ! in_array( $doaction, array( '-1', 'edit', 'save', ) ) ) {
</span><span class="cx">
</span></span></pre>
</div>
</div>
</body>
</html>