org.symbian.tools.wrttools.doc.WRTKit/html/WRTKit_SelectionList_Class-GUID-c3be7a8a-9028-4cec-a0c0-d355d0621b37.html
changeset 230 7848c135d915
equal deleted inserted replaced
229:716254ccbcc0 230:7848c135d915
       
     1 <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
       
     2 <html lang="en" xml:lang="en">
       
     3 <head>
       
     4 <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
       
     5 <meta name="copyright" content="(C) Copyright 2005" />
       
     6 <meta name="DC.rights.owner" content="(C) Copyright 2005" />
       
     7 <meta content="concept" name="DC.Type" />
       
     8 <meta name="DC.Title" content="WRTKit SelectionList Class" />
       
     9 <meta scheme="URI" name="DC.Relation" content="WRTKit_API_Reference-GUID-00e47c27-0a1a-443f-ae85-cf3381635170.html" />
       
    10 <meta content="XHTML" name="DC.Format" />
       
    11 <meta content="GUID-C3BE7A8A-9028-4CEC-A0C0-D355D0621B37" name="DC.Identifier" />
       
    12 <meta content="en" name="DC.Language" />
       
    13 <link href="commonltr.css" type="text/css" rel="stylesheet" />
       
    14 <title>
       
    15 WRTKit SelectionList Class</title>
       
    16 </head>
       
    17 <body id="GUID-C3BE7A8A-9028-4CEC-A0C0-D355D0621B37"><a name="GUID-C3BE7A8A-9028-4CEC-A0C0-D355D0621B37"><!-- --></a>
       
    18 
       
    19 
       
    20 
       
    21     <h1 class="topictitle1">
       
    22 WRTKit SelectionList Class</h1>
       
    23 
       
    24     <div>
       
    25 
       
    26         <div class="section"><h2 class="sectiontitle">
       
    27 Description</h2>
       
    28 
       
    29             
       
    30             <p>
       
    31 
       
    32                 The SelectionList class is an implementation of a selection control that displays
       
    33                 a list of options to the user. Options are displayed as radio buttons or checkboxes
       
    34                 depending on if the control is in single or multiple-selection mode. Selection lists
       
    35                 are useful in situations where the widget is used in pointer navigation mode or if
       
    36                 there is a small amount of options.
       
    37             </p>
       
    38 
       
    39             <div class="fignone" id="GUID-C3BE7A8A-9028-4CEC-A0C0-D355D0621B37__GUID-31AED89F-89DB-42A6-8261-14CC57E2C399"><a name="GUID-C3BE7A8A-9028-4CEC-A0C0-D355D0621B37__GUID-31AED89F-89DB-42A6-8261-14CC57E2C399"><!-- --></a><span class="figcap">Figure 1. 
       
    40 SelectionList controls</span>
       
    41 
       
    42                 
       
    43                 <br /><img src="SelectionList_Controls_Screenshot_1.png" /><br />
       
    44             </div>
       
    45 
       
    46         </div>
       
    47 
       
    48         <div class="section"><h2 class="sectiontitle">
       
    49 Inherits from</h2>
       
    50 
       
    51             
       
    52             <p>
       
    53 
       
    54                 <a href="WRTKit_SelectionControl_Class-GUID-35c4291f-dc3a-439c-890f-1d140864aca0.html">
       
    55 SelectionControl</a>
       
    56             </p>
       
    57 
       
    58         </div>
       
    59 
       
    60     </div>
       
    61 
       
    62     <div>
       
    63 <div class="familylinks">
       
    64 <div class="parentlink"><strong>Parent topic:</strong> <a href="WRTKit_API_Reference-GUID-00e47c27-0a1a-443f-ae85-cf3381635170.html">WRTKit API Reference</a></div>
       
    65 </div>
       
    66 </div>
       
    67 <div class="nested1" id="GUID-B74CEF09-2818-4AD5-9E57-66E0821AA0C6"><a name="GUID-B74CEF09-2818-4AD5-9E57-66E0821AA0C6"><!-- --></a>
       
    68 
       
    69         <h2 class="topictitle2">
       
    70 Constructor</h2>
       
    71 
       
    72         <div>
       
    73 
       
    74             <div class="section"><h3 class="sectiontitle">
       
    75 Syntax</h3>
       
    76 
       
    77                 
       
    78                 <pre>
       
    79 [SelectionList] new SelectionList(String id, String caption, Array options, Boolean multipleSelection, Array|Option selected)</pre>
       
    80 
       
    81             </div>
       
    82 
       
    83             <div class="section"><h3 class="sectiontitle">
       
    84 Description</h3>
       
    85 
       
    86                 
       
    87                 <p>
       
    88 
       
    89                     Creates a new instance of the SelectionList class.
       
    90                 </p>
       
    91 
       
    92             </div>
       
    93 
       
    94             <div class="section"><h3 class="sectiontitle">
       
    95 Arguments</h3>
       
    96 
       
    97                 
       
    98                 <br /><ul>
       
    99 
       
   100                     <li>
       
   101 
       
   102                         <p>
       
   103 id</p>
       
   104 
       
   105                         
       
   106 
       
   107                             <p>
       
   108 
       
   109                                 Unique identifier for the control. Can be retrieved using the id property defined
       
   110                                 in the UIElement class that this control inherits from. Useful for example to
       
   111                                 identify the source of an event in event callback functions or to apply a CSS
       
   112                                 rule to only this particular control. The identifier can be null, in which case
       
   113                                 no id will be set for the control.
       
   114                             </p>
       
   115 
       
   116                         
       
   117                     </li>
       
   118 
       
   119                     <li>
       
   120 
       
   121                         <p>
       
   122 caption</p>
       
   123 
       
   124                         
       
   125 
       
   126                             <p>
       
   127 
       
   128                                 The caption text for the control. A null caption can be used to hide the 
       
   129                                 caption area. The value is an XHTML string.
       
   130                             </p>
       
   131 
       
   132                         
       
   133                     </li>
       
   134 
       
   135                     <li>
       
   136 
       
   137                         <p>
       
   138 options</p>
       
   139 
       
   140                         
       
   141 
       
   142                             <p>
       
   143 
       
   144                                 An array of options that the selection list should display to the user.
       
   145                                 If the argument is omitted or null the control will not display any 
       
   146                                 options. The options can be set or changed later by calling setOptions().
       
   147                                 Options are objects with two properties: value and text. Use JavaScript
       
   148                                 object notation (JSON) to construct option objects, e.g.
       
   149                                 <samp class="codeph">
       
   150 { value: "value here", text: "Text for value goes here" }</samp>.
       
   151                                 The text value is an XHTML string.
       
   152                             </p>
       
   153 
       
   154                         
       
   155                     </li>
       
   156 
       
   157                     <li>
       
   158 
       
   159                         <p>
       
   160 multipleSelection</p>
       
   161 
       
   162                         
       
   163 
       
   164                             <p>
       
   165 
       
   166                                 The multipleSelection argument is a boolean flag that determines whether
       
   167                                 the control should be in multipleSelection mode or not. Use true to put
       
   168                                 the control in multiple selection mode and false to put it in single
       
   169                                 selection mode. If this argument is omitted the control will go to single
       
   170                                 selection mode by default.
       
   171                             </p>
       
   172 
       
   173                         
       
   174                     </li>
       
   175 
       
   176                     <li>
       
   177 
       
   178                         <p>
       
   179 selected</p>
       
   180 
       
   181                         
       
   182 
       
   183                             <p>
       
   184 
       
   185                                 The selected argument specifies which of the options should be selected at
       
   186                                 creation time. For multiple selection controls this should be given as an
       
   187                                 array of option objects with an empty array if no options should be selected.
       
   188                                 For single selection controls this should be the single option object that
       
   189                                 should be selected or null if no option should be selected. If the argument
       
   190                                 is omitted or null no options will be selected.
       
   191                             </p>
       
   192 
       
   193                         
       
   194                     </li>
       
   195 
       
   196                 </ul>
       
   197 
       
   198             </div>
       
   199 
       
   200             <div class="section"><h3 class="sectiontitle">
       
   201 Return value</h3>
       
   202 
       
   203                 
       
   204                 <p>
       
   205 
       
   206                     A new instance of the SelectionList class.
       
   207                 </p>
       
   208 
       
   209             </div>
       
   210 
       
   211         </div>
       
   212 
       
   213     </div>
       
   214 
       
   215 
       
   216 </body>
       
   217 </html>