From ca32f08966f1b51fcb19460f0996bb0c4048e6fe Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Sat, 3 Dec 2011 13:29:22 +0100 Subject: Update to MediaWiki 1.18.0 * also update ArchLinux skin to chagnes in MonoBook * Use only css to hide our menu bar when printing --- includes/profiler/ProfilerSimpleText.php | 54 ++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 includes/profiler/ProfilerSimpleText.php (limited to 'includes/profiler/ProfilerSimpleText.php') diff --git a/includes/profiler/ProfilerSimpleText.php b/includes/profiler/ProfilerSimpleText.php new file mode 100644 index 00000000..ef9049fa --- /dev/null +++ b/includes/profiler/ProfilerSimpleText.php @@ -0,0 +1,54 @@ + or \n"; + } + } + } + + /* dense is good */ + static function sort( $a, $b ) { + return $a['real'] < $b['real']; /* sort descending by time elapsed */ + } + + static function format( $item, $key, $totalReal ) { + $perc = $totalReal ? $item['real']/$totalReal*100 : 0; + self::$out .= sprintf( "%6.2f%% %3.6f %6d - %s\n", + $perc, $item['real'], $item['count'], $key ); + } +} -- cgit v1.2.3-54-g00ecf