diff options
author | Evan Prodromou <evan@status.net> | 2009-09-29 17:26:09 -0400 |
---|---|---|
committer | Evan Prodromou <evan@status.net> | 2009-09-29 17:26:09 -0400 |
commit | 4298f28eaed04a1247a1e474844e91fbbc992013 (patch) | |
tree | 96eb2d2d506bbc9cf9a5d52c85298e82cab1cecd | |
parent | 89ac81c34464b2fc4f54b643d0d95d12bac765ab (diff) | |
parent | a68663588ee95915153ad1f927cf510e3d41a299 (diff) |
Merge branch '0.9.x' of git@gitorious.org:statusnet/mainline into 0.9.x
-rw-r--r-- | actions/api.php | 1 | ||||
-rw-r--r-- | plugins/PiwikAnalyticsPlugin.php | 20 | ||||
-rw-r--r-- | plugins/Realtime/RealtimePlugin.php | 3 | ||||
-rw-r--r-- | plugins/Realtime/realtimeupdate.js | 57 | ||||
-rw-r--r-- | theme/base/css/display.css | 2 |
5 files changed, 52 insertions, 31 deletions
diff --git a/actions/api.php b/actions/api.php index d570bb017..1bc90de11 100644 --- a/actions/api.php +++ b/actions/api.php @@ -160,6 +160,7 @@ class ApiAction extends Action static $bareauth = array('statuses/user_timeline', 'statuses/friends_timeline', + 'statuses/home_timeline', 'statuses/friends', 'statuses/replies', 'statuses/mentions', diff --git a/plugins/PiwikAnalyticsPlugin.php b/plugins/PiwikAnalyticsPlugin.php index 8191f5181..54faa0bdb 100644 --- a/plugins/PiwikAnalyticsPlugin.php +++ b/plugins/PiwikAnalyticsPlugin.php @@ -38,22 +38,16 @@ if (!defined('STATUSNET')) { * This plugin will spoot out the correct JavaScript spell to invoke * Piwik Analytics on a page. * - * To use this plugin please add the following three lines to your config.php + * To use this plugin add the following to your config.php * - * require_once('plugins/PiwikAnalyticsPlugin.php'); - * $pa = new PiwikAnalyticsPlugin("example.com/piwik/","id"); + * addPlugin('PiwikAnalytics', array('piwikroot' => 'example.com/piwik/', + * 'piwikId' => 'id')); * - * exchange example.com/piwik/ with the url to your piwik installation and - * make sure you don't forget the final / - * exchange id with the ID your statusnet installation has in your Piwik analytics + * Replace 'example.com/piwik/' with the URL to your Piwik installation and + * make sure you don't forget the final /. + * Replace 'id' with the ID your statusnet installation has in your Piwik + * analytics setup - for example '8'. * - * @category Plugin - * @package StatusNet - * @author Tobias Diekershoff <tobias.diekershoff@gmx.net> - * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 - * @link http://status.net/ - * - * @see Event */ class PiwikAnalyticsPlugin extends Plugin diff --git a/plugins/Realtime/RealtimePlugin.php b/plugins/Realtime/RealtimePlugin.php index e30c41156..0f0d0f9f4 100644 --- a/plugins/Realtime/RealtimePlugin.php +++ b/plugins/Realtime/RealtimePlugin.php @@ -216,8 +216,6 @@ class RealtimePlugin extends Plugin 'class' => 'user_in') : array('id' => $action->trimmed('action'))); - $action->elementStart('div', array('id' => 'header')); - // XXX hack to deal with JS that tries to get the // root url from page output @@ -230,7 +228,6 @@ class RealtimePlugin extends Plugin if (common_logged_in()) { $action->showNoticeForm(); } - $action->elementEnd('div'); $action->showContentBlock(); $action->elementEnd('body'); diff --git a/plugins/Realtime/realtimeupdate.js b/plugins/Realtime/realtimeupdate.js index 57fe0a843..4cd68a816 100644 --- a/plugins/Realtime/realtimeupdate.js +++ b/plugins/Realtime/realtimeupdate.js @@ -14,6 +14,18 @@ RealtimeUpdate = { RealtimeUpdate._replyurl = replyurl; RealtimeUpdate._favorurl = favorurl; RealtimeUpdate._deleteurl = deleteurl; + + $(window).blur(function() { + $('#notices_primary .notice').css({ + 'border-top-color':$('#notices_primary .notice:last').css('border-top-color'), + 'border-top-style':'dotted' + }); + + $('#notices_primary .notice:first').css({ + 'border-top-color':'#AAAAAA', + 'border-top-style':'solid' + }); + }); }, receive: function(data) @@ -27,7 +39,7 @@ RealtimeUpdate = { } var noticeItem = RealtimeUpdate.makeNoticeItem(data); - $("#notices_primary .notices").prepend(noticeItem, true); + $("#notices_primary .notices").prepend(noticeItem); $("#notices_primary .notice:first").css({display:"none"}); $("#notices_primary .notice:first").fadeIn(1000); NoticeReply(); @@ -113,35 +125,52 @@ RealtimeUpdate = { addPopup: function(url, timeline, iconurl) { - $('#site_nav_local_views .current a').append('<button id="realtime_timeline" title="Real-time pop window">↗</button>'); - + $('#content').prepend('<button id="realtime_timeline" title="Pop up in a window">Pop up</button>'); + $('#realtime_timeline').css({ - 'margin':'2px 0 0 11px', - 'background':'transparent url('+ iconurl + ') no-repeat 45% 45%', - 'text-indent':'-9999px', - 'width':'16px', - 'height':'16px', - 'padding':'0', + 'margin':'0 0 18px 0', + 'background':'transparent url('+ iconurl + ') no-repeat 0% 30%', + 'padding':'0 0 0 20px', 'display':'block', 'float':'right', 'border':'none', - 'cursor':'pointer' + 'cursor':'pointer', + 'color':$("a").css("color"), + 'font-weight':'bold', + 'font-size':'1em' }); - + $('#realtime_timeline').click(function() { window.open(url, timeline, 'toolbar=no,resizable=yes,scrollbars=yes,status=yes'); - + return false; }); }, initPopupWindow: function() { - window.resizeTo(575, 640); + window.resizeTo(500, 550); $('address').hide(); - $('#content').css({'width':'92%'}); + $('#content').css({'width':'93.5%'}); + + $('#form_notice').css({ + 'margin':'18px 0 18px 1.795%', + 'width':'93%', + 'max-width':'451px' + }); + + $('#form_notice label[for=notice_data-text], h1').css({'display': 'none'}); + + $('.notices li:first-child').css({'border-top-color':'transparent'}); + + $('#form_notice label[for="notice_data-attach"], #form_notice #notice_data-attach').css({'top':'0'}); + + $('#form_notice #notice_data-attach').css({ + 'left':'auto', + 'right':'0' + }); } } diff --git a/theme/base/css/display.css b/theme/base/css/display.css index 1f37a7637..7706fba48 100644 --- a/theme/base/css/display.css +++ b/theme/base/css/display.css @@ -484,7 +484,7 @@ height:16px; #form_notice .form_note { position:absolute; bottom:2px; -right:98px; +right:21.715%; z-index:9; } #form_notice .form_note dt { |