Merge branch 'dev' into 3.8RC
This commit is contained in:
commit
f0cdbd0f52
@ -350,7 +350,8 @@ class Apps {
|
||||
'Permission Categories' => t('Permission Categories'),
|
||||
'Premium Channel' => t('Premium Channel'),
|
||||
'Public Stream' => t('Public Stream'),
|
||||
'My Chatrooms' => t('My Chatrooms')
|
||||
'My Chatrooms' => t('My Chatrooms'),
|
||||
'Channel Export' => t('Channel Export')
|
||||
);
|
||||
|
||||
if(array_key_exists('name',$arr)) {
|
||||
|
2
boot.php
2
boot.php
@ -50,7 +50,7 @@ require_once('include/attach.php');
|
||||
require_once('include/bbcode.php');
|
||||
|
||||
define ( 'PLATFORM_NAME', 'hubzilla' );
|
||||
define ( 'STD_VERSION', '3.8RC1.1' );
|
||||
define ( 'STD_VERSION', '3.9.1' );
|
||||
define ( 'ZOT_REVISION', '6.0a' );
|
||||
|
||||
|
||||
|
@ -2602,8 +2602,6 @@ function channel_remove($channel_id, $local = true, $unset_session = false) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
$r = q("select id from item where uid = %d", intval($channel_id));
|
||||
if($r) {
|
||||
foreach($r as $rv) {
|
||||
@ -2611,7 +2609,6 @@ function channel_remove($channel_id, $local = true, $unset_session = false) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
q("delete from abook where abook_xchan = '%s' and abook_self = 1 ",
|
||||
dbesc($channel['channel_hash'])
|
||||
);
|
||||
|
@ -38,6 +38,15 @@ function js_strings() {
|
||||
// using the defaults set below if left untranslated, empty strings if
|
||||
// translated to "NONE" and the corresponding language strings
|
||||
// if translated to anything else
|
||||
'minutes' => tt('%d minutes', '%d minutes', '%d'),
|
||||
'hours' => tt('about %d hours', 'about %d hours', '%d'),
|
||||
'days' => tt('%d days', '%d days', '%d'),
|
||||
'months' => tt('%d months', '%d months', '%d'),
|
||||
'years' => tt('%d years', '%d years', '%d'),
|
||||
|
||||
// get plural function code
|
||||
'plural_func' => tf(),
|
||||
|
||||
'$t01' => ((t('timeago.prefixAgo') == 'timeago.prefixAgo') ? '' : ((t('timeago.prefixAgo') == 'NONE') ? '' : t('timeago.prefixAgo'))),
|
||||
'$t02' => ((t('timeago.prefixFromNow') == 'timeago.prefixFromNow') ? '' : ((t('timeago.prefixFromNow') == 'NONE') ? '' : t('timeago.prefixFromNow'))),
|
||||
'$t03' => ((t('timeago.suffixAgo') == 'timeago.suffixAgo') ? 'ago' : ((t('timeago.suffixAgo') == 'NONE') ? '' : t('timeago.suffixAgo'))),
|
||||
@ -46,15 +55,15 @@ function js_strings() {
|
||||
// translatable main strings for jquery.timeago
|
||||
'$t05' => t('less than a minute'),
|
||||
'$t06' => t('about a minute'),
|
||||
'$t07' => t('%d minutes'),
|
||||
'$t07' => ta('%d minutes'),
|
||||
'$t08' => t('about an hour'),
|
||||
'$t09' => t('about %d hours'),
|
||||
'$t09' => ta('about %d hours'),
|
||||
'$t10' => t('a day'),
|
||||
'$t11' => t('%d days'),
|
||||
'$t11' => ta('%d days'),
|
||||
'$t12' => t('about a month'),
|
||||
'$t13' => t('%d months'),
|
||||
'$t13' => ta('%d months'),
|
||||
'$t14' => t('about a year'),
|
||||
'$t15' => t('%d years'),
|
||||
'$t15' => ta('%d years'),
|
||||
'$t16' => t(' '), // wordSeparator
|
||||
'$t17' => ((t('timeago.numbers') != 'timeago.numbers') ? t('timeago.numbers') : '[]'),
|
||||
|
||||
|
@ -254,6 +254,34 @@ function tt($singular, $plural, $count, $ctx = ''){
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Return slash separated string of plurals translation forms
|
||||
*
|
||||
* @param string $k key in translations array
|
||||
* @return string
|
||||
*/
|
||||
function ta($k){
|
||||
|
||||
$t = App::$strings[$k];
|
||||
if (is_array($t))
|
||||
$t = implode("/", $t);
|
||||
return ($t == "" ? $k : $t);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Return string_plural_select_xx function code
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function tf() {
|
||||
|
||||
$r = "";
|
||||
$lang = str_replace('-', '_', App::$language);
|
||||
if(function_exists("string_plural_select_".$lang))
|
||||
$r = trim(shell_exec("sed -n '5p' view/".$lang."/hstrings.php | grep 'return' | tr -d '$'"));
|
||||
return ($r != "" ? $r : "return 0;");
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Provide a fallback which will not collide with a function defined in
|
||||
* any language file.
|
||||
|
@ -44,25 +44,28 @@ $(document).ready(function() {
|
||||
$(document).on('click', '.conversation-settings-link', getConversationSettings);
|
||||
$(document).on('click', '#settings_module_ajax_submit', postConversationSettings);
|
||||
|
||||
jQuery.timeago.settings.strings = {
|
||||
prefixAgo : aStr['t01'],
|
||||
prefixFromNow : aStr['t02'],
|
||||
suffixAgo : aStr['t03'],
|
||||
suffixFromNow : aStr['t04'],
|
||||
seconds : aStr['t05'],
|
||||
minute : aStr['t06'],
|
||||
minutes : aStr['t07'],
|
||||
hour : aStr['t08'],
|
||||
hours : aStr['t09'],
|
||||
day : aStr['t10'],
|
||||
days : aStr['t11'],
|
||||
month : aStr['t12'],
|
||||
months : aStr['t13'],
|
||||
year : aStr['t14'],
|
||||
years : aStr['t15'],
|
||||
wordSeparator : aStr['t16'],
|
||||
numbers : aStr['t17'],
|
||||
};
|
||||
var tf = new Function('n', aStr['plural_func']);
|
||||
|
||||
jQuery.timeago.settings.strings = {
|
||||
prefixAgo : aStr['t01'],
|
||||
prefixFromNow : aStr['t02'],
|
||||
suffixAgo : aStr['t03'],
|
||||
suffixFromNow : aStr['t04'],
|
||||
seconds : aStr['t05'],
|
||||
minute : aStr['t06'],
|
||||
minutes : function(value){return aStr['t07'].split("/")[tf(value)];},
|
||||
hour : aStr['t08'],
|
||||
hours : function(value){return aStr['t09'].split("/")[tf(value)];},
|
||||
day : aStr['t10'],
|
||||
days : function(value){return aStr['t11'].split("/")[tf(value)];},
|
||||
month : aStr['t12'],
|
||||
months : function(value){return aStr['t13'].split("/")[tf(value)];},
|
||||
year : aStr['t14'],
|
||||
years : function(value){return aStr['t15'].split("/")[tf(value)];},
|
||||
wordSeparator : aStr['t16'],
|
||||
numbers : aStr['t17'],
|
||||
};
|
||||
|
||||
|
||||
//mod_mail only
|
||||
$(".mail-conv-detail .autotime").timeago();
|
||||
|
24472
view/ru/hmessages.po
24472
view/ru/hmessages.po
File diff suppressed because it is too large
Load Diff
5413
view/ru/hstrings.php
5413
view/ru/hstrings.php
File diff suppressed because it is too large
Load Diff
@ -34,7 +34,7 @@
|
||||
'name_ok1' : "{{$name_ok1}}",
|
||||
'name_ok2' : "{{$name_ok2}}",
|
||||
|
||||
|
||||
'plural_func' : "{{$plural_func}}",
|
||||
|
||||
't01' : "{{$t01}}",
|
||||
't02' : "{{$t02}}",
|
||||
|
Reference in New Issue
Block a user