PluginProbe
CoolClock / 4.1
CoolClock v4.1
4.3.9 4.3.8 trunk 0.1 2.0 2.9.8 3.0 3.1 3.2 3.3 4.0 4.1 4.2 4.3.3 4.3.4 4.3.5 4.3.6 4.3.7
← All changes | includes/class-coolclock.php +35 -22 4.04.1 View file →
@@ -5,17 +5,17 @@
5 5 */
6 6
7 7 class CoolClock {
8 8
9 - static $plugin_version = '4.0';
9 + static $plugin_version = '4.0.99';
10 10
11 - static $script_version = '3.0.0';
11 + static $script_version = '3.1.0';
12 12
13 13 private static $plugin_url;
14 14
15 15 private static $plugin_basename;
16 16
17 - private static $min = '';
17 + private static $min = '.min';
18 18
19 19 static $add_script = false;
20 20
21 21 static $add_moreskins = false;
@@ -22,27 +22,28 @@
22 22
23 23 private static $done_excanvas = false;
24 24
25 25 static $defaults = array (
26 - 'skin' => 'swissRail',
27 - 'radius' => 100,
28 - 'noseconds' => false, // Hide seconds
29 - 'gmtoffset' => '', // GMT offset
30 - 'showdigital' => '', // Show digital time or date
31 - 'scale' => 'linear' // Define type of clock linear/logarithmic/log reversed
32 - );
26 + 'skin' => 'swissRail',
27 + 'radius' => 100,
28 + 'noseconds' => false, // Hide seconds
29 + 'gmtoffset' => '', // GMT offset
30 + 'showdigital' => '', // Show digital time or date
31 + 'scale' => 'linear', // Define type of clock linear/logarithmic/log reversed
32 + 'digitalcolor' => '#333'
33 + );
33 34
34 35 static $showdigital_options = array (
35 - '' => '',
36 - 'digital12' => 'showDigital'
37 - );
36 + '' => '',
37 + 'digital12' => 'showDigital'
38 + );
38 39
39 - static $advanced;
40 + static $advanced = false;
40 41
41 42 static $advanced_defaults = array (
42 - 'subtext' => '',
43 - 'align' => 'center'
44 - );
43 + 'subtext' => '',
44 + 'align' => 'center'
45 + );
45 46
46 47 static $default_skins = ['swissRail','chunkySwiss','chunkySwissOnBlack'];
47 48
48 49 static $more_skins = ['fancy','machine','simonbaird_com','classic','modern','simple','securephp','Tes2','Lev','Sand','Sun','Tor','Cold','Babosa','Tumb','Stone','Disc','watermelon','mister'];
@@ -51,12 +52,12 @@
51 52
52 53 static $advanced_skins_config = [];
53 54
54 55 static $clock_types = array (
55 - 'linear' => '',
56 - 'logClock' => 'logClock',
57 - 'logClockRev' => 'logClockRev'
58 - );
56 + 'linear' => '',
57 + 'logClock' => 'logClock',
58 + 'logClockRev' => 'logClockRev'
59 + );
59 60
60 61 /**
61 62 * MAIN
62 63 */
@@ -97,8 +98,20 @@
97 98 $output .= ':'.self::$clock_types[$scale];
98 99 else
99 100 $output .= ':';
100 101
102 + // set font
103 + if ( isset($font) )
104 + $output .= ':'.$font;
105 + else
106 + $output .= ':';
107 +
108 + // set font color
109 + if ( isset($digitalcolor) )
110 + $output .= ':'.$digitalcolor;
111 + else
112 + $output .= ':';
113 +
101 114 $output .= '"></canvas>';
102 115 $output .= ( $subtext ) ? '<div style="width:100%;text-align:center;padding-bottom:10px">' . $subtext . '</div></div>' : '</div>';
103 116
104 117 return $output;
@@ -144,9 +157,9 @@
144 157 self::$plugin_url = plugins_url( '/', $file );
145 158 self::$plugin_basename = plugin_basename( $file );
146 159
147 160 if ( defined('WP_DEBUG') && WP_DEBUG ) {
148 - self::$min = '.min';
161 + self::$min = '';
149 162 }
150 163 }
151 164
152 165 }