]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
* i18n review
authorSiebrand Mazeland <s.mazeland@xs4all.nl>
Fri, 1 Oct 2010 20:01:18 +0000 (22:01 +0200)
committerSiebrand Mazeland <s.mazeland@xs4all.nl>
Fri, 1 Oct 2010 20:01:18 +0000 (22:01 +0200)
* onPluginVersion

plugins/GroupFavorited/GroupFavoritedPlugin.php
plugins/GroupFavorited/groupfavoritedaction.php

index 68815530aa602f923c40af874805eb2010655ad9..27ce289c2e4f9242a87898490abe8886c751ab70 100644 (file)
@@ -76,4 +76,28 @@ class GroupFavoritedPlugin extends Plugin
                             $action_name == 'groupfavorited',
                             'nav_group_group');
     }
+
+    /**
+     * Provide plugin version information.
+     *
+     * This data is used when showing the version page.
+     *
+     * @param array &$versions array of version data arrays; see EVENTS.txt
+     *
+     * @return boolean hook value
+     */
+    function onPluginVersion(&$versions)
+    {
+        $url = 'http://status.net/wiki/Plugin:GroupFavorited';
+
+        $versions[] = array('name' => 'GroupFavorited',
+            'version' => STATUSNET_VERSION,
+            'author' => 'Brion Vibber',
+            'homepage' => $url,
+            'rawdescription' =>
+            // TRANS: Plugin description.
+            _m('This plugin adds a menu item for popular notices in groups.'));
+
+        return true;
+    }
 }
index 6803bea8d63b1255ee72a74221b54b57e8250735..dbd37abbcfb0d422c339e3e02e3e45348b2dfdf7 100644 (file)
@@ -32,27 +32,27 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
     exit(1);
 }
 
-
 class GroupFavoritedAction extends ShowgroupAction
 {
-
     /**
      * Title of the page
      *
      * @return string page title, with page number
      */
-
     function title()
     {
         if (!empty($this->group->fullname)) {
+            // @todo Create a core method to create this properly. i18n issue.
             $base = $this->group->fullname . ' (' . $this->group->nickname . ')';
         } else {
             $base = $this->group->nickname;
         }
 
         if ($this->page == 1) {
+            // TRANS: %s is a group name.
             return sprintf(_m('Popular posts in %s group'), $base);
         } else {
+            // TRANS: %1$s is a group name, %2$s is a group number.
             return sprintf(_m('Popular posts in %1$s group, page %2$d'),
                            $base,
                            $this->page);
@@ -66,7 +66,6 @@ class GroupFavoritedAction extends ShowgroupAction
      *
      * @return void
      */
-
     function showContent()
     {
         $groupId = intval($this->group->id);