Browse Source

show experimental and unsupported theme status on theme admin page

pull/49/merge
friendica 10 years ago
parent
commit
5f7858a688
  1. 9
      include/plugin.php
  2. 6
      mod/admin.php
  3. 2
      view/admin_plugins.tpl
  4. 0
      view/theme/clean/unsupported
  5. 0
      view/theme/darkness/unsupported
  6. 0
      view/theme/darkzero-NS/unsupported
  7. 0
      view/theme/easterbunny/unsupported
  8. 0
      view/theme/ghost/unsupported
  9. 0
      view/theme/goldenrod/unsupported
  10. 0
      view/theme/loozah/unsupported
  11. 0
      view/theme/shady/unsupported

9
include/plugin.php

@ -225,9 +225,16 @@ function get_theme_info($theme){
'description' => "",
'author' => array(),
'maintainer' => array(),
'version' => ""
'version' => "",
'experimental' => false,
'unsupported' => false
);
if(file_exists("view/theme/$theme/experimental"))
$info['experimental'] = true;
if(file_exists("view/theme/$theme/unsupported"))
$info['unsupported'] = true;
if (!is_file("view/theme/$theme/theme.php")) return $info;
$f = file_get_contents("view/theme/$theme/theme.php");

6
mod/admin.php

@ -711,7 +711,7 @@ function admin_page_themes(&$a){
return; // NOTREACHED
}
// display plugin details
// display theme details
require_once('library/markdown.php');
if (theme_status($themes,$theme)) {
@ -769,7 +769,9 @@ function admin_page_themes(&$a){
'$submit' => t('Submit'),
'$baseurl' => $a->get_baseurl(),
'$function' => 'themes',
'$plugins' => $xthemes
'$plugins' => $xthemes,
'$experimental' => t('[Experimental]'),
'$unsupported' => t('[Unsupported]')
));
}

2
view/admin_plugins.tpl

@ -6,6 +6,8 @@
<li class='plugin $p.1'>
<a class='toggleplugin' href='$baseurl/admin/$function/$p.0?a=t' title="{{if $p.1==on }}Disable{{ else }}Enable{{ endif }}" ><span class='icon $p.1'></span></a>
<a href='$baseurl/admin/$function/$p.0'><span class='name'>$p.2.name</span></a> - <span class="version">$p.2.version</span>
{{ if $p.2.experimental }} $experimental {{ endif }}{{ if $p.2.unsupported }} $unsupported {{ endif }}
<div class='desc'>$p.2.description</div>
</li>
{{ endfor }}

0
view/theme/clean/unsupported

0
view/theme/darkness/unsupported

0
view/theme/darkzero-NS/unsupported

0
view/theme/easterbunny/unsupported

0
view/theme/ghost/unsupported

0
view/theme/goldenrod/unsupported

0
view/theme/loozah/unsupported

0
view/theme/shady/unsupported

Loading…
Cancel
Save