Merge branch '0.8.x' into 0.9.x
This commit is contained in:
commit
a68663588e
@ -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
|
||||
|
@ -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');
|
||||
|
@ -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'
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -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 {
|
||||
|
Loading…
Reference in New Issue
Block a user