]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Stylesheet event now removed of StatusNet-remnants
authorMikael Nordfeldth <mmn@hethane.se>
Tue, 17 Sep 2013 18:41:54 +0000 (20:41 +0200)
committerMikael Nordfeldth <mmn@hethane.se>
Mon, 23 Sep 2013 20:13:12 +0000 (22:13 +0200)
EVENTS.txt
lib/action.php
lib/uapplugin.php
plugins/Directory/DirectoryPlugin.php
plugins/MobileProfile/MobileProfilePlugin.php
plugins/ModPlus/ModPlusPlugin.php
plugins/OStatus/OStatusPlugin.php
plugins/Realtime/RealtimePlugin.php
plugins/ShareNotice/ShareNoticePlugin.php

index f97617bdb0b75f2a357c0624d4cb0ce75eeae498..1d5b610b2798d1602814981dbfe36d0154c2c2b1 100644 (file)
@@ -20,16 +20,10 @@ StartShowStyles: Showing Style links; good place to add UA style resets
 EndShowStyles: End showing Style links; good place to add custom styles
 - $action: the current action
 
-StartShowStatusNetStyles: Showing StatusNet Style links
+StartShowStylesheets: Showing stylesheet links
 - $action: the current action
 
-EndShowStatusNetStyles: End showing StatusNet Style links;  good place to add handheld or JavaScript dependant styles
-- $action: the current action
-
-StartShowLaconicaStyles: backwards compatibility; deprecated
-- $action: the current action
-
-EndShowLaconicaStyles: backwards compatibility; deprecated
+EndShowStylesheets: End showing stylesheet links;  good place to add handheld or JavaScript dependant styles
 - $action: the current action
 
 StartShowUAStyles: Showing custom User-Agent style links
index 4a76dff9e2b60f7931f452f7099074fb0c0ef3a3..72a83fed28acfadd26560e730c27e2d4baec90eb 100644 (file)
@@ -28,9 +28,7 @@
  * @link      http://status.net/
  */
 
-if (!defined('STATUSNET') && !defined('LACONICA')) {
-    exit(1);
-}
+if (!defined('GNUSOCIAL')) { exit(1); }
 
 require_once INSTALLDIR.'/lib/noticeform.php';
 require_once INSTALLDIR.'/lib/htmloutputter.php';
@@ -283,11 +281,9 @@ class Action extends HTMLOutputter // lawsuit
 
             // Use old name for StatusNet for compatibility on events
 
-            if (Event::handle('StartShowStatusNetStyles', array($this)) &&
-                Event::handle('StartShowLaconicaStyles', array($this))) {
+            if (Event::handle('StartShowStylesheets', array($this))) {
                 $this->primaryCssLink(null, 'screen, projection, tv, print');
-                Event::handle('EndShowStatusNetStyles', array($this));
-                Event::handle('EndShowLaconicaStyles', array($this));
+                Event::handle('EndShowStylesheets', array($this));
             }
 
             $this->cssLink(common_path('js/extlib/jquery-ui/css/smoothness/jquery-ui.css', StatusNet::isHTTPS()));
index 26d6a72d896c378a72315eadd0c98f71fdefb475..9a6aeab6624eabee067f29c05914f6ab92a58cd4 100644 (file)
@@ -28,7 +28,7 @@
  * @link      http://status.net/
  */
 
-if (!defined('STATUSNET') && !defined('LACONICA')) {
+if (!defined('STATUSNET')) {
     exit(1);
 }
 
@@ -65,7 +65,7 @@ abstract class UAPPlugin extends Plugin
      *
      * @return boolean hook flag
      */
-    function onEndShowStatusNetStyles($action)
+    public function onEndShowStylesheets(Action $action)
     {
         // XXX: allow override by theme
         $action->cssLink('css/uap.css', 'base', 'screen, projection, tv');
index 511b7eb561198930ec4b5bd5b9e43e55837151e3..a3cc01c935e14405a5a0800da46a7ac93dcd2580 100644 (file)
@@ -153,7 +153,7 @@ class DirectoryPlugin extends Plugin
      *
      * @return boolean hook flag
      */
-    function onEndShowStatusNetStyles($action)
+    public function onEndShowStylesheets(Action $action)
     {
         if (in_array(
             $action->trimmed('action'),
index 76d285ba27bf3e18257a1c4831ce89750ef8e492..0eb57035d1290155db75a2d90d11fd857ba5d372 100644 (file)
@@ -27,7 +27,7 @@
  * @link      http://status.net/
  */
 
-if (!defined('STATUSNET') && !defined('LACONICA')) {
+if (!defined('STATUSNET')) {
     exit(1);
 }
 
@@ -244,7 +244,7 @@ class MobileProfilePlugin extends WAP20Plugin
         }
     }
 
-    function onStartShowStatusNetStyles($action)
+    public function onStartShowStylesheets(Action $action)
     {
         if (!$this->serveMobile) {
             return true;
@@ -263,8 +263,7 @@ class MobileProfilePlugin extends WAP20Plugin
         }
 
         // Allow other plugins to load their styles.
-        Event::handle('EndShowStatusNetStyles', array($action));
-        Event::handle('EndShowLaconicaStyles', array($action));
+        Event::handle('EndShowStylesheets', array($action));
 
         return false;
     }
index d66ec6054a629724df0d7816bee66b96fdecc0e0..8d43f53b9a3f6849b55f0e774e79c5cb9d9cdaef 100644 (file)
@@ -57,7 +57,7 @@ class ModPlusPlugin extends Plugin
         return true;
     }
 
-    function onEndShowStatusNetStyles($action) {
+    public function onEndShowStylesheets(Action $action) {
         $action->cssLink($this->path('modplus.css'));
         return true;
     }
index d34535bdcbe1f5792aeb0dbb4bbbcc3daea53e4d..82e059c0faa31e66f9653213343ccba2a787f8be 100644 (file)
@@ -518,7 +518,7 @@ class OStatusPlugin extends Plugin
         return true;
     }
 
-    function onEndShowStatusNetStyles($action) {
+    public function onEndShowStylesheets(Action $action) {
         $action->cssLink($this->path('theme/base/css/ostatus.css'));
         return true;
     }
index 42a254ab0c844b51d15d0187e8a635bd002d8698..958716fa7621af0cf398e9f16f1263291da55b57 100644 (file)
@@ -27,7 +27,7 @@
  * @link      http://status.net/
  */
 
-if (!defined('STATUSNET') && !defined('LACONICA')) {
+if (!defined('STATUSNET')) {
     exit(1);
 }
 
@@ -140,7 +140,7 @@ class RealtimePlugin extends Plugin
         return true;
     }
 
-    function onEndShowStatusNetStyles($action)
+    public function onEndShowStylesheets(Action $action)
     {
         $action->cssLink(Plugin::staticPath('Realtime', 'realtimeupdate.css'),
                          null,
index 08362f7932c0b249e3232b8f0889294f305b4ce3..86ecfa88374d12b64baf4a4951c1ba6d324fc80f 100644 (file)
@@ -32,7 +32,7 @@ class ShareNoticePlugin extends Plugin
         array('StatusNet', array('baseurl' => 'http://identi.ca'))
     );
 
-    function onEndShowStatusNetStyles($action) {
+    public function onEndShowStylesheets(Action $action) {
         $action->cssLink($this->path('css/sharenotice.css'));
         return true;
     }