Add smart_threading user setting
This commit is contained in:
parent
81c3ddd1fb
commit
2336fa9d74
|
@ -303,6 +303,7 @@ function settings_post(App $a) {
|
||||||
$infinite_scroll = x($_POST, 'infinite_scroll') ? intval($_POST['infinite_scroll']) : 0;
|
$infinite_scroll = x($_POST, 'infinite_scroll') ? intval($_POST['infinite_scroll']) : 0;
|
||||||
$no_auto_update = x($_POST, 'no_auto_update') ? intval($_POST['no_auto_update']) : 0;
|
$no_auto_update = x($_POST, 'no_auto_update') ? intval($_POST['no_auto_update']) : 0;
|
||||||
$bandwidth_saver = x($_POST, 'bandwidth_saver') ? intval($_POST['bandwidth_saver']) : 0;
|
$bandwidth_saver = x($_POST, 'bandwidth_saver') ? intval($_POST['bandwidth_saver']) : 0;
|
||||||
|
$smart_threading = x($_POST, 'smart_threading') ? intval($_POST['smart_threading']) : 0;
|
||||||
$nowarn_insecure = x($_POST, 'nowarn_insecure') ? intval($_POST['nowarn_insecure']) : 0;
|
$nowarn_insecure = x($_POST, 'nowarn_insecure') ? intval($_POST['nowarn_insecure']) : 0;
|
||||||
$browser_update = x($_POST, 'browser_update') ? intval($_POST['browser_update']) : 0;
|
$browser_update = x($_POST, 'browser_update') ? intval($_POST['browser_update']) : 0;
|
||||||
if ($browser_update != -1) {
|
if ($browser_update != -1) {
|
||||||
|
@ -335,6 +336,7 @@ function settings_post(App $a) {
|
||||||
PConfig::set(local_user(), 'system', 'infinite_scroll' , $infinite_scroll);
|
PConfig::set(local_user(), 'system', 'infinite_scroll' , $infinite_scroll);
|
||||||
PConfig::set(local_user(), 'system', 'no_auto_update' , $no_auto_update);
|
PConfig::set(local_user(), 'system', 'no_auto_update' , $no_auto_update);
|
||||||
PConfig::set(local_user(), 'system', 'bandwidth_saver' , $bandwidth_saver);
|
PConfig::set(local_user(), 'system', 'bandwidth_saver' , $bandwidth_saver);
|
||||||
|
PConfig::set(local_user(), 'system', 'smart_threading' , $smart_threading);
|
||||||
|
|
||||||
if ($theme == $a->user['theme']) {
|
if ($theme == $a->user['theme']) {
|
||||||
// call theme_post only if theme has not been changed
|
// call theme_post only if theme has not been changed
|
||||||
|
@ -989,6 +991,7 @@ function settings_content(App $a) {
|
||||||
$infinite_scroll = PConfig::get(local_user(), 'system', 'infinite_scroll', 0);
|
$infinite_scroll = PConfig::get(local_user(), 'system', 'infinite_scroll', 0);
|
||||||
$no_auto_update = PConfig::get(local_user(), 'system', 'no_auto_update', 0);
|
$no_auto_update = PConfig::get(local_user(), 'system', 'no_auto_update', 0);
|
||||||
$bandwidth_saver = PConfig::get(local_user(), 'system', 'bandwidth_saver', 0);
|
$bandwidth_saver = PConfig::get(local_user(), 'system', 'bandwidth_saver', 0);
|
||||||
|
$smart_threading = PConfig::get(local_user(), 'system', 'smart_threading', 0);
|
||||||
|
|
||||||
$theme_config = "";
|
$theme_config = "";
|
||||||
if (($themeconfigfile = get_theme_config_file($theme_selected)) != null) {
|
if (($themeconfigfile = get_theme_config_file($theme_selected)) != null) {
|
||||||
|
@ -1017,6 +1020,7 @@ function settings_content(App $a) {
|
||||||
'$infinite_scroll' => array('infinite_scroll', t("Infinite scroll"), $infinite_scroll, ''),
|
'$infinite_scroll' => array('infinite_scroll', t("Infinite scroll"), $infinite_scroll, ''),
|
||||||
'$no_auto_update' => array('no_auto_update', t("Automatic updates only at the top of the network page"), $no_auto_update, t('When disabled, the network page is updated all the time, which could be confusing while reading.')),
|
'$no_auto_update' => array('no_auto_update', t("Automatic updates only at the top of the network page"), $no_auto_update, t('When disabled, the network page is updated all the time, which could be confusing while reading.')),
|
||||||
'$bandwidth_saver' => array('bandwidth_saver', t('Bandwith Saver Mode'), $bandwidth_saver, t('When enabled, embedded content is not displayed on automatic updates, they only show on page reload.')),
|
'$bandwidth_saver' => array('bandwidth_saver', t('Bandwith Saver Mode'), $bandwidth_saver, t('When enabled, embedded content is not displayed on automatic updates, they only show on page reload.')),
|
||||||
|
'$smart_threading' => array('smart_threading', t('Smart Threading'), $smart_threading, t('When enabled, suppress extraneous thread indentation while keeping it where it matters. Only works if threading is available and enabled.')),
|
||||||
|
|
||||||
'$d_tset' => t('General Theme Settings'),
|
'$d_tset' => t('General Theme Settings'),
|
||||||
'$d_ctset' => t('Custom Theme Settings'),
|
'$d_ctset' => t('Custom Theme Settings'),
|
||||||
|
|
|
@ -20,6 +20,7 @@
|
||||||
{{include file="field_checkbox.tpl" field=$noinfo}}
|
{{include file="field_checkbox.tpl" field=$noinfo}}
|
||||||
{{include file="field_checkbox.tpl" field=$infinite_scroll}}
|
{{include file="field_checkbox.tpl" field=$infinite_scroll}}
|
||||||
{{include file="field_checkbox.tpl" field=$bandwidth_saver}}
|
{{include file="field_checkbox.tpl" field=$bandwidth_saver}}
|
||||||
|
{{include file="field_checkbox.tpl" field=$smart_threading}}
|
||||||
<h2>{{$calendar_title}}</h2>
|
<h2>{{$calendar_title}}</h2>
|
||||||
{{include file="field_select.tpl" field=$first_day_of_week}}
|
{{include file="field_select.tpl" field=$first_day_of_week}}
|
||||||
|
|
||||||
|
|
|
@ -75,6 +75,7 @@
|
||||||
{{include file="field_checkbox.tpl" field=$noinfo}}
|
{{include file="field_checkbox.tpl" field=$noinfo}}
|
||||||
{{include file="field_checkbox.tpl" field=$infinite_scroll}}
|
{{include file="field_checkbox.tpl" field=$infinite_scroll}}
|
||||||
{{include file="field_checkbox.tpl" field=$bandwidth_saver}}
|
{{include file="field_checkbox.tpl" field=$bandwidth_saver}}
|
||||||
|
{{include file="field_checkbox.tpl" field=$smart_threading}}
|
||||||
|
|
||||||
<div class="form-group pull-right settings-submit-wrapper" >
|
<div class="form-group pull-right settings-submit-wrapper" >
|
||||||
<button type="submit" name="submit" class="btn btn-primary" value="{{$submit|escape:'html'}}">{{$submit}}</button>
|
<button type="submit" name="submit" class="btn btn-primary" value="{{$submit|escape:'html'}}">{{$submit}}</button>
|
||||||
|
|
Loading…
Reference in a new issue