Андрей (andy) wrote in changelog,
Андрей
andy
changelog

[livejournal] r18484: LJSUP-8100 (No links and pictures for sh...

Committer: ailyin
LJSUP-8100 (No links and pictures for sharing (S1))
U   trunk/cgi-bin/LJ/Talk.pm
Modified: trunk/cgi-bin/LJ/Talk.pm
===================================================================
--- trunk/cgi-bin/LJ/Talk.pm	2011-03-05 11:13:47 UTC (rev 18483)
+++ trunk/cgi-bin/LJ/Talk.pm	2011-03-09 07:59:48 UTC (rev 18484)
@@ -1,20 +1,19 @@
 package LJ::Talk;
 use strict;
 
+use Captcha::reCAPTCHA;
+use Carp qw(croak);
+use MIME::Words;
+
+use LJ::Comment;
 use LJ::Constants;
+use LJ::Event::JournalNewComment;
+use LJ::EventLogRecord::NewComment;
+use LJ::OpenID
 use LJ::RateLimit qw//;
-use Class::Autouse qw(
-                      LJ::Event::JournalNewComment
-                      LJ::Event::UserNewComment
-                      LJ::Comment
-                      LJ::EventLogRecord::NewComment
-                      Captcha::reCAPTCHA
-                      LJ::OpenID
-                      );
-use MIME::Words;
-use Carp qw(croak);
+use LJ::Share;
+use LJ::Talk::Author;
 use LJ::TimeUtil;
-use LJ::Talk::Author;
 
 use constant PACK_FORMAT => "NNNNC"; ## $talkid, $parenttalkid, $poster, $time, $state 
 
@@ -154,8 +153,14 @@
                 .attachButton(jQuery('a:last')[0]);
             </script>|
             if $entry->security eq 'public';
-     }
+    }
 
+    if ( LJ::is_enabled('sharing') && $entry->is_public ) {
+        LJ::Share->request_resources;
+        push @linkele, $mlink->( '#', 'share' )
+                     . LJ::Share->render_js( { 'entry' => $entry } );
+    }
+
     if ($remote && $remote->can_use_esn) {
         my $img_key = $remote->has_subscription(journal => $u, event => "JournalNewComment", arg1 => $itemid, require_active => 1) ?
             "track_active" : "track";

Tags: andy, livejournal, pm
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments