aboutsummaryrefslogtreecommitdiffstats
path: root/view
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2018-09-26 15:02:20 +0200
committerMario Vavti <mario@mariovavti.com>2018-09-26 15:02:20 +0200
commit9bc76b425948e7a6118e7749a3eb7c08c447bab3 (patch)
tree9e8e932e6c7266d3a8220bc7fb24dffc3e85d8ed /view
parent9948bb3f2aa3bf3efa68623b87ba854fb59b4926 (diff)
downloadvolse-hubzilla-9bc76b425948e7a6118e7749a3eb7c08c447bab3.tar.gz
volse-hubzilla-9bc76b425948e7a6118e7749a3eb7c08c447bab3.tar.bz2
volse-hubzilla-9bc76b425948e7a6118e7749a3eb7c08c447bab3.zip
appification of the pdl editor and move advanced_theming to theme settings where it belongs
Diffstat (limited to 'view')
-rw-r--r--view/theme/redbasic/php/config.php6
-rw-r--r--view/theme/redbasic/tpl/theme_settings.tpl1
-rwxr-xr-xview/tpl/settings_display.tpl6
3 files changed, 5 insertions, 8 deletions
diff --git a/view/theme/redbasic/php/config.php b/view/theme/redbasic/php/config.php
index ae926d07b..d9d46c8f4 100644
--- a/view/theme/redbasic/php/config.php
+++ b/view/theme/redbasic/php/config.php
@@ -54,6 +54,7 @@ class RedbasicConfig {
$arr['converse_width']=get_pconfig(local_channel(),"redbasic","converse_width");
$arr['top_photo']=get_pconfig(local_channel(),"redbasic","top_photo");
$arr['reply_photo']=get_pconfig(local_channel(),"redbasic","reply_photo");
+ $arr['advanced_theming'] = get_pconfig(local_channel(), 'redbasic', 'advanced_theming');
return $this->form($arr);
}
@@ -80,15 +81,15 @@ class RedbasicConfig {
set_pconfig(local_channel(), 'redbasic', 'converse_width', $_POST['redbasic_converse_width']);
set_pconfig(local_channel(), 'redbasic', 'top_photo', $_POST['redbasic_top_photo']);
set_pconfig(local_channel(), 'redbasic', 'reply_photo', $_POST['redbasic_reply_photo']);
+ set_pconfig(local_channel(), 'redbasic', 'advanced_theming', $_POST['redbasic_advanced_theming']);
}
}
function form($arr) {
- if(get_pconfig(local_channel(), 'system', 'advanced_theming'))
+ if(get_pconfig(local_channel(), 'redbasic', 'advanced_theming'))
$expert = 1;
-
$o .= replace_macros(get_markup_template('theme_settings.tpl'), array(
'$submit' => t('Submit'),
'$baseurl' => z_root(),
@@ -112,6 +113,7 @@ class RedbasicConfig {
'$converse_width' => array('redbasic_converse_width',t('Set maximum width of content region in pixel'),$arr['converse_width'], t('Leave empty for default width')),
'$top_photo' => array('redbasic_top_photo', t('Set size of conversation author photo'), $arr['top_photo']),
'$reply_photo' => array('redbasic_reply_photo', t('Set size of followup author photos'), $arr['reply_photo']),
+ '$advanced_theming' => ['redbasic_advanced_theming', t('Show more custom theme settings'), $arr['advanced_theming'], '', [t('No'), t('Yes')]]
));
return $o;
diff --git a/view/theme/redbasic/tpl/theme_settings.tpl b/view/theme/redbasic/tpl/theme_settings.tpl
index 7c552b49e..cc403f0a7 100644
--- a/view/theme/redbasic/tpl/theme_settings.tpl
+++ b/view/theme/redbasic/tpl/theme_settings.tpl
@@ -1,6 +1,7 @@
{{include file="field_checkbox.tpl" field=$narrow_navbar}}
{{include file="field_input.tpl" field=$converse_width}}
{{include file="field_input.tpl" field=$font_size}}
+{{include file="field_checkbox.tpl" field=$advanced_theming}}
{{if $expert}}
{{include file="field_colorinput.tpl" field=$nav_bg}}
{{include file="field_colorinput.tpl" field=$nav_icon_colour}}
diff --git a/view/tpl/settings_display.tpl b/view/tpl/settings_display.tpl
index ee0e137b5..f96e7f84c 100755
--- a/view/tpl/settings_display.tpl
+++ b/view/tpl/settings_display.tpl
@@ -69,12 +69,6 @@
{{include file="field_checkbox.tpl" field=$preload_images}}
{{include file="field_checkbox.tpl" field=$manual_update}}
{{include file="field_checkbox.tpl" field=$start_menu}}
- {{include file="field_checkbox.tpl" field=$advanced_theming}}
- {{if $expert}}
- <div class="form-group">
- <a class="btn btn-outline-secondary "href="pdledit">{{$layout_editor}}</a>
- </div>
- {{/if}}
<div class="settings-submit-wrapper" >
<button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button>
</div>