当前位置: 首页>>代码示例>>PHP>>正文


PHP QButton::__set方法代码示例

本文整理汇总了PHP中QButton::__set方法的典型用法代码示例。如果您正苦于以下问题:PHP QButton::__set方法的具体用法?PHP QButton::__set怎么用?PHP QButton::__set使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在QButton的用法示例。


在下文中一共展示了QButton::__set方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __set

 public function __set($strName, $mixValue)
 {
     switch ($strName) {
         case "StyleClass":
             // One of Bootstrap::ButtonDefault, ButtonPrimary, ButtonSuccess, ButtonInfo, ButtonWarning, ButtonDanger
             break;
         case "SizeClass":
             // One of Bootstrap::ButtonLarge, ButtonMedium, ButtonSmall, ButtonExtraSmall
             $this->SetStyleClass($mixValue);
             break;
         case "Glyph":
             // One of the glyph icons
             $this->strGlyph = QType::Cast($mixValue, QType::String);
             break;
         case "PrimaryButton":
             try {
                 $this->blnPrimaryButton = QType::Cast($mixValue, QType::Boolean);
                 $this->SetStyleClass(Bootstrap::ButtonPrimary);
                 break;
             } catch (\QInvalidCastException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         default:
             try {
                 parent::__set($strName, $mixValue);
             } catch (\QInvalidCastException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
             break;
     }
 }
开发者ID:alfhan,项目名称:plugin_bootstrap,代码行数:33,代码来源:Button.php

示例2: __set

 public function __set($strName, $mixValue)
 {
     switch ($strName) {
         case 'Disabled':
             try {
                 $this->blnDisabled = QType::Cast($mixValue, QType::Boolean);
                 if ($this->Rendered) {
                     $this->CallJqUiMethod('option', 'disabled', $this->blnDisabled);
                 }
                 break;
             } catch (QInvalidCastException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'Icons':
             $this->mixIcons = $mixValue;
             if ($this->Rendered) {
                 $this->CallJqUiMethod('option', 'icons', $mixValue);
             }
             break;
         case 'Label':
             try {
                 $this->strLabel = QType::Cast($mixValue, QType::String);
                 if ($this->Rendered) {
                     $this->CallJqUiMethod('option', 'label', $this->strLabel);
                 }
                 break;
             } catch (QInvalidCastException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'JqText':
             try {
                 $this->blnJqText = QType::Cast($mixValue, QType::Boolean);
                 if ($this->Rendered) {
                     $this->CallJqUiMethod('option', 'text', $this->blnJqText);
                 }
                 break;
             } catch (QInvalidCastException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'Enabled':
             $this->Disabled = !$mixValue;
             // Tie in standard QCubed functionality
             parent::__set($strName, $mixValue);
             break;
         default:
             try {
                 parent::__set($strName, $mixValue);
                 break;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
     }
 }
开发者ID:hiptc,项目名称:dle2wordpress,代码行数:57,代码来源:QJqButtonGen.class.php


注:本文中的QButton::__set方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。