blob: 8fd879bc57a25c01869c6522ed35d27edfae2644 (
plain)
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
|
<?php
class RatingList extends TPage
{
function list1_oncallback($sender, $param)
{
$newRating = ($sender->Rating + $sender->SelectedIndex+1)/2;
$sender->Rating = $newRating;
$sender->Caption = "Rating : ".$newRating;
$sender->Enabled=false;
}
function list2_oncallback($sender, $param)
{
}
function button1_clicked($sender, $param)
{
$this->list1->Enabled = true;
}
function button2_clicked($sender, $param)
{
$this->list1->Enabled=false;
}
function button5_clicked($sender, $param)
{
$this->list1->SelectedIndex=3;
}
}
?>
|