-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathconfig.php
38 lines (37 loc) · 1012 Bytes
/
config.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php
require_once INCLUDE_DIR . 'class.plugin.php';
class PreventAutoscrollPluginConfig extends PluginConfig {
// Provide compatibility function for versions of osTicket prior to
// translation support (v1.9.4)
function translate() {
if (! method_exists ( 'Plugin', 'translate' )) {
return array (
function ($x) {
return $x;
},
function ($x, $y, $n) {
return $n != 1 ? $y : $x;
}
);
}
return Plugin::translate ( 'prevent-autoscroll' );
}
/**
* Build an Admin settings page.
*
* {@inheritdoc}
*
* @see PluginConfig::getOptions()
*/
function getOptions() {
list ( $__, $_N ) = self::translate ();
return array (
'ri' => new SectionBreakField ( array (
'label' => $__ ( 'Configuration Unnecessary, simply disable the plugin to re-enable default auto-scroll.' )
) ),
't' => new SectionBreakField ( array (
'label' => $__ ( 'Source: https://github.com/clonemeagain/osticket-plugin-preventautoscroll' )
) )
);
}
}