本文整理汇总了PHP中Button::Text方法的典型用法代码示例。如果您正苦于以下问题:PHP Button::Text方法的具体用法?PHP Button::Text怎么用?PHP Button::Text使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Button
的用法示例。
在下文中一共展示了Button::Text方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: InitButton
/**
* InitButton
*
* @param mixed $Name
* @param mixed $Group
* @param int $T
* @param int $L
* @param int $W
* @param int $H
* @param bool $BStyle
* @param string $Text
* @param int $Expire
* @access public
* @return void
*/
public function InitButton($Name, $Group, $T = 0, $L = 0, $W = 1, $H = 1, $BStyle = null, $Text = '', $Expire = 0)
{
$OldButton = ButtonManager::getButtonForKey($this->UCID, $Name);
if (get_class($OldButton) == 'Button') {
$Button = $OldButton;
} else {
$Button = new Button($this->UCID, $Name, $Group);
}
$Button->T($T)->L($L)->W($W)->H($H);
$Button->BStyle($BStyle);
if (is_array($Text)) {
$Button->Text($Text[0]);
$this->bTexts[$Name] = $Text;
} else {
$Button->Text($Text);
$this->bTexts[$Name][0] = $Text;
}
$Button->Send();
$this->bState[$Name]['ID'] = 0;
$this->bState[$Name]['timestamp'] = time() - 1;
$this->bState[$Name]['expire'] = -1;
$this->bState[$Name]['override'] = false;
if ($Expire > 0) {
$this->bState[$Name]['expire'] = time() + $Expire;
}
}
示例2: OSD
public function OSD($iUCID, $sPName, $sTime, $sΔ)
{
$bName = new Button($iUCID, 'PName', 'FOM');
$bName->L(40)->T(166)->W(40)->H(8);
$bName->BStyle |= ISB_DARK + ISB_RIGHT;
$bName->Text($sPName)->send();
$bTime = new Button($iUCID, 'STime', 'FOM');
$bTime->L(40)->T(174)->W(40)->H(8);
$bTime->BStyle |= ISB_DARK + ISB_RIGHT;
$bTime->Text($sTime)->send();
$bΔ = new Button($iUCID, 'Delta', 'FOM');
$bΔ->L(40)->T(182)->W(40)->H(8);
$bΔ->BStyle |= ISB_DARK + ISB_RIGHT;
$bΔ->Text($sΔ)->send();
$this->createTimer('OSR', 10, Timer::CLOSE, array($iUCID));
}