2024.8.23
Loading...
Searching...
No Matches
class.tpl.app.exit.php
Go to the documentation of this file.
1
<?php
2
/*
3
* Copyright (c) 2021-2024 Bearsampp
4
* License: GNU General Public License version 3 or later; see LICENSE.txt
5
* Author: bear
6
* Website: https://bearsampp.com
7
* Github: https://github.com/Bearsampp
8
*/
9
10
/**
11
* Class TplAppExit
12
*
13
* This class provides methods to handle the exit action within the Bearsampp application.
14
* It includes functionalities to process the exit action and generate the necessary action strings.
15
*/
16
class
TplAppExit
17
{
18
/**
19
* Constant representing the exit action.
20
*/
21
const
ACTION
=
'exit'
;
22
23
/**
24
* Processes the exit action and generates the necessary action strings.
25
*
26
* This method generates a multi-action string for the exit action, including the caption and glyph.
27
*
28
* @global object $bearsamppLang Provides language support for retrieving language-specific values.
29
*
30
* @return array An array containing the call string and the section content for the exit action.
31
*/
32
public
static
function
process
()
33
{
34
global
$bearsamppLang
;
35
36
return
TplApp::getActionMulti
(
37
self::ACTION,
38
null
,
39
array(
$bearsamppLang
->getValue(
Lang::QUIT
),
TplAestan::GLYPH_EXIT
),
40
false
,
41
get_called_class()
42
);
43
}
44
45
/**
46
* Generates the action string to execute the exit action.
47
*
48
* This method generates a run action string for the quit action and appends the exit action.
49
*
50
* @return string The generated action string for the exit action.
51
*/
52
public
static
function
getActionExit
()
53
{
54
return
TplApp::getActionRun
(
Action::QUIT
) . PHP_EOL .
'Action: exit'
;
55
}
56
}
$bearsamppLang
global $bearsamppLang
Definition
ajax.apache.php:16
Action\QUIT
const QUIT
Definition
class.action.php:37
Lang\QUIT
const QUIT
Definition
class.lang.php:63
TplAestan\GLYPH_EXIT
const GLYPH_EXIT
Definition
class.tpl.aestan.php:65
TplAppExit
Definition
class.tpl.app.exit.php:17
TplAppExit\getActionExit
static getActionExit()
Definition
class.tpl.app.exit.php:52
TplAppExit\ACTION
const ACTION
Definition
class.tpl.app.exit.php:21
TplAppExit\process
static process()
Definition
class.tpl.app.exit.php:32
TplApp\getActionMulti
static getActionMulti($action, $args=array(), $item=array(), $disabled=false, $class=false)
Definition
class.tpl.app.php:152
TplApp\getActionRun
static getActionRun($action, $args=array(), $item=array(), $waitUntilTerminated=true)
Definition
class.tpl.app.php:115
Bearsampp-development
sandbox
core
classes
tpls
app
class.tpl.app.exit.php
Generated by
1.11.0