Thread Rating:
  • 340 Vote(s) - 2.73 Average
  • 1
  • 2
  • 3
  • 4
  • 5
拡張クラスのローカルオプションについて
12-11-2012, 09:15 AM,
#6
RE: 拡張クラスのローカルオプションについて
ん?
オーバーライドできないって・・・。

あれ?
できるな。

いや、これでいいんです。これで。

あれぇ・・・?

Code:
{define-class public MyTextField {inherits TextField}
  {constructor public {default ...}
    {construct-super {splice ...}}
  }
  {nonlocal-option public enabled?:bool
    {if not enabled? then
        set self.value = "無効"
     else
        set  self.value = ""
    }
  }
  {local-option public editable?:bool
    {if not editable? then
        set self.value = "編集不可"
     else
        set  self.value = ""
    }
  }
}
{def tf = {MyTextField}}
{CheckButton
    label = "enabled?",
    value = true,
    {on ValueChanged at chkb:CheckButton do
        set tf.enabled? = chkb.value
    }
}
{CheckButton
    label = "editable?",
    value = true,
    {on ValueChanged at chkb:CheckButton do
        set tf.editable? = chkb.value
    }
}
{value tf}


Messages In This Thread
RE: 拡張クラスのローカルオプションについて - by umemura - 12-11-2012, 09:15 AM
Forum Jump:


Users browsing this thread:
1 Guest(s)

MyBB SQL Error

MyBB has experienced an internal SQL error and cannot continue.

SQL Error:
1017 - Can't find file: 'mybb_threadviews' (errno: 2)
Query:
INSERT INTO mybb_threadviews (tid) VALUES('183')