bioptionpane.html

来自「ajax 框价.是个好工具.javascript 矿家.可以用在任何平台.」· HTML 代码 · 共 984 行 · 第 1/3 页

HTML
984
字号
</thead><tbody><tr><td><code>oMessage</code></td><td><code class="type">Object</code></td><td class="optional-column"></td><td></td><td>The text or <code><a href="BiComponent.html">BiComponent</a></code> to show 								as a message inside the dialog</td></tr><tr><td><code>sCaption</code></td><td><code class="type">String</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td><code>Input</code></td><td>The caption text to show on the dialog window </td></tr><tr><td><code>sMessageType</code></td><td><code class="type">String</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td><code>question</code></td><td>The type of the message that is shown. This sets the image on the option pane if no other image is provided. Valid values are:<br>												<br>						                                  plain - No image<br>						                                  error - Shows a stop (x) image<br>						                                  information - Shows an image with an 'i' on<br>						                                  warning - Shows an image with an exclamation mark on<br>						                                  question - Show a question mark image</td></tr><tr><td><code>oImage</code></td><td><code class="type">						<code><a href="BiImage.html">BiImage</a></code>					</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td></td><td>The image to show on the option pane. If left out then the image defined by the <code><a href="#messageType">messageType</a></code> is used.</td></tr><tr><td><code>sDefaultValue</code></td><td><code class="type">String</code></td><td class="optional-column"></td><td></td><td>The default text to show on the text field</td></tr></tbody></table><h4>Return Type</h4><p><code class="type">					<code><a href="BiDialog.html">BiDialog</a></code>				</code></p><h3><a name="createMessageDialog"></a>createMessageDialog</h3><p>Creates a new <code><a href="BiDialog.html">BiDialog</a></code> with a option pane as the <code><a href="BiWindow.html#contentPane">contentPane</a></code> of the dialog window.<br>								<br>				 This dialog is used to show a simple message. The iamge can either be set using the option type or by setting using the image argument.<br>								<br>				 The <code><a href="BiDialog.html#dialogResult">returnValue</a></code> for the dialog reflects the button clicked. The values are:<br>								<br>				 ok - The "OK" button was clicked<br>				 cancel - The "Cancel" button was clicked<br>				 yes - The "Yes" button was clicked<br>				 no  - The "No" button was clicked</p><h4>Syntax</h4><pre class="method-syntax">BiOptionPane.createMessageDialog(<span class="methodArgument">oMessage</span> [, <span class="methodArgument">sCaption</span> [, <span class="methodArgument">sMessageType</span> [, <span class="methodArgument">oImage</span>]]])</pre><h4>Parameters</h4><table><thead><tr><td>Name</td><td>Type</td><td class="optional-header">Optional</td><td>Default</td><td>Descripton</td></tr></thead><tbody><tr><td><code>oMessage</code></td><td><code class="type">Object</code></td><td class="optional-column"></td><td></td><td>The text or <code><a href="BiComponent.html">BiComponent</a></code> to show 								as a message inside the dialog</td></tr><tr><td><code>sCaption</code></td><td><code class="type">String</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td></td><td>The caption text to show on the dialog window </td></tr><tr><td><code>sMessageType</code></td><td><code class="type">String</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td><code>information</code></td><td>The type of the message that is shown. This sets the image on the option pane if no other image is provided. Valid values are:<br>												<br>						                                  plain - No image<br>						                                  error - Shows a stop (x) image<br>						                                  information - Shows an image with an 'i' on<br>						                                  warning - Shows an image with an exclamation mark on<br>						                                  question - Show a question mark image</td></tr><tr><td><code>oImage</code></td><td><code class="type">						<code><a href="BiImage.html">BiImage</a></code>					</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td></td><td>The image to show on the option pane. If left out then the image defined by the <code><a href="#messageType">messageType</a></code> is used.</td></tr></tbody></table><h4>Return Type</h4><p><code class="type">					<code><a href="BiDialog.html">BiDialog</a></code>				</code></p><h3><a name="createOptionDialog"></a>createOptionDialog</h3><p>Creates a new <code><a href="BiDialog.html">BiDialog</a></code> with a option pane as the <code><a href="BiWindow.html#contentPane">contentPane</a></code> of the dialog window.<br>								<br>				 This dialog is used to show custom option buttons that the user can select between. The options argument should be used to define the buttons to use.<br>								<br>				 The <code><a href="BiDialog.html#dialogResult">returnValue</a></code> for the dialog reflects the button clicked. The value will be the object that the clicked button was created from.</p><h4>Syntax</h4><pre class="method-syntax">BiOptionPane.createOptionDialog(<span class="methodArgument">oMessage</span> [, <span class="methodArgument">sCaption</span> [, <span class="methodArgument">sMessageType</span>, <span class="methodArgument">sOptionType</span> [, <span class="methodArgument">oImage</span>, <span class="methodArgument">oOptions</span>, <span class="methodArgument">oInitialValue</span>]]])</pre><h4>Parameters</h4><table><thead><tr><td>Name</td><td>Type</td><td class="optional-header">Optional</td><td>Default</td><td>Descripton</td></tr></thead><tbody><tr><td><code>oMessage</code></td><td><code class="type">Object</code></td><td class="optional-column"></td><td></td><td>The text or <code><a href="BiComponent.html">BiComponent</a></code> to show 								as a message inside the dialog</td></tr><tr><td><code>sCaption</code></td><td><code class="type">String</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td></td><td>The caption text to show on the dialog window </td></tr><tr><td><code>sMessageType</code></td><td><code class="type">String</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td><code>information</code></td><td>The type of the message that is shown. This sets the image on the option pane if no other image is provided. Valid values are:<br>												<br>						                                  plain - No image<br>						                                  error - Shows a stop (x) image<br>						                                  information - Shows an image with an 'i' on<br>						                                  warning - Shows an image with an exclamation mark on<br>						                                  question - Show a question mark image</td></tr><tr><td><code>sOptionType</code></td><td><code class="type">String</code></td><td class="optional-column"></td><td></td><td>The option type describes what buttons to show on the optinon pane. 									This is ignored if the <code><a href="#options">options</a></code> are set. Valid values are:<br>												<br>						                                  default - Usually shows an "OK" button<br>						                                  yesno - Shows a "Yes" and a "No" button<br>						                                  yesnocancel - Shows three buttons with the text "Yes", "No" and "Cancel"<br>						                                  okcancel - Shows an "OK" and a "Cancel" button</td></tr><tr><td><code>oImage</code></td><td><code class="type">						<code><a href="BiImage.html">BiImage</a></code>					</code></td><td class="optional-column"><img src="check.png" alt="checked"></td><td></td><td>The image to show on the option pane. If left out then the image defined by the <code><a href="#messageType">messageType</a></code> is used.</td></tr><tr><td><code>oOptions</code></td><td><code class="type">Object[]</code></td><td class="optional-column"></td><td></td><td>This describes what options/buttons to show on the option pane. 									This is an array of objects and if the object is a                                  <code><a href="BiComponent.html">BiComponent</a></code> then it is added as                                  it is. If not, a new button is created where the text is taken                                  by using the <code>toString</code> method on the object.</td></tr><tr><td><code>oInitialValue</code></td><td><code class="type">Object</code></td><td class="optional-column"></td><td></td><td>This is used to define which of the options that should be treated 									as the default <code><a href="#acceptButton">acceptButton</a></code>					</td></tr></tbody></table><h4>Return Type</h4><p><code class="type">					<code><a href="BiDialog.html">BiDialog</a></code>				</code></p><h3><a name="getComponentFromObject"></a>getComponentFromObject</h3><p>Returns a component from the object. If the object is already a<code><a href="BiComponent.html">BiComponent</a></code> then it is returned as it is, otherwise a<code><a href="BiLabel.html">BiLabel</a></code> is created where the text on the label is the object <code>toString</code>.</p><h4>Syntax</h4><pre class="method-syntax">BiOptionPane.getComponentFromObject(<span class="methodArgument">o</span>)</pre><h4>Parameters</h4><table><thead><tr><td>Name</td><td>Type</td><td class="optional-header">Optional</td><td>Default</td><td>Descripton</td></tr></thead><tbody><tr><td><code>o</code></td><td><code class="type">Object</code></td><td class="optional-column"></td><td></td><td>The object that is used to return the component.</td></tr></tbody></table><h4>Return Type</h4><p><code class="type">					<code><a href="BiComponent.html">BiComponent</a></code>				</code></p><h3><a name="getImageFromOptionType"></a>getImageFromOptionType</h3><p>Returns the<code><a href="BiImage.html">BiImage</a></code> derived from the option type string argument. Valid values for the argument string are the same as for the <code><a href="#optionType">optionType</a></code> property.</p><h4>Syntax</h4><pre class="method-syntax">BiOptionPane.getImageFromOptionType(<span class="methodArgument">sOptionType</span>)</pre><h4>Parameters</h4><table><thead><tr><td>Name</td><td>Type</td><td class="optional-header">Optional</td><td>Default</td><td>Descripton</td></tr></thead><tbody><tr><td><code>sOptionType</code></td><td><code class="type">String</code></td><td class="optional-column"></td><td></td><td>The option type string that should define what image to 									return.</td></tr></tbody></table><h4>Return Type</h4><p><code class="type">					<code><a href="BiImage.html">BiImage</a></code>				</code></p></body></html>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?