public class JComboBox extends JComponent
Modifier | Constructor and Description |
---|---|
protected |
JComboBox(JtfObjectHandle handle,
Desktop desktop)
使用 JtfObjectHandle 创建新 JComboBox。
|
Modifier and Type | Method and Description |
---|---|
String |
getItem(int index)
返回指定索引处的项目。
|
int |
getItemCount()
获取 列表中项目的数量。
|
List<ItemIdentifier> |
getItems()
获取 所有已含项目的列表。
|
int |
getSelectedIndex()
获取 当前所选项目的索引。.
|
ItemIdentifier |
getSelectedItem()
获取 当前所选项目。
|
boolean |
isEditable()
获取 组合框是否可编辑。
|
void |
select(int itemIndex)
选择指定项目。
|
void |
select(ItemIdentifier item)
选择指定项目。
|
void |
select(String itemText)
选择指定项目。
|
getToolTipText
click, click, click, click, doubleClick, doubleClick, doubleClick, doubleClick, getAccessibleName, getAccessibleRole, getBackground, getCursor, getFont, getForeground, getHeight, getName, getNativeHandle, getWidth, isEnabled, isFocusable, isFocused, mouseMove, mouseMove, openContextMenu, openContextMenu, pressKeys, pressKeys, pressMouse, pressMouse, pressMouse, pressMouse, releaseKeys, releaseKeys, releaseMouse, releaseMouse, releaseMouse, releaseMouse, scrollIntoView, setFocus, typeKeys, typeKeys, typeKeys, typePasswordKeys, typePasswordKeys, typePasswordKeys
captureBitmap, captureBitmap, exists, exists, generateLocator, getChildren, getDynamicMethodList, getParent, getPropertyList, getRect, getRect, getText, getValue, highlightObject, highlightObject, highlightObject, invokeMethods, textCapture, textCapture, textClick, textClick, textClick, textClick, textClick, textClick, textExists, textExists, textExists, textExists, textExists, textRectangle, textRectangle, textRectangle, textRectangle, textRectangle, waitForChildDisappearance, waitForChildDisappearance, waitForDisappearance, waitForDisappearance, waitForObject, waitForObject, waitForProperty, waitForProperty
equals, exists, find, find, findAll, findAll, getCustomTypeName, getDesktop, getHandle, getLocator, getProperty, getTypeName, hashCode, imageClick, imageClick, imageClick, imageClick, imageClick, imageClick, imageClickFile, imageClickFile, imageClickFile, imageClickFile, imageClickFile, imageClickFile, imageExists, imageExists, imageExists, imageExistsFile, imageExistsFile, imageExistsFile, imageRectangle, imageRectangle, imageRectangle, imageRectangleFile, imageRectangleFile, imageRectangleFile, invoke, preventFinalLocator, setProperty, toString
protected JComboBox(JtfObjectHandle handle, Desktop desktop)
handle
- 可确定 JComboBox 的句柄desktop
- 此对象所在的桌面public String getItem(int index)
index
- 项目索引。. The value is zero-based.public void select(ItemIdentifier item)
item
- 可选择的项目的名称或索引public void select(String itemText)
itemText
- 可选择的项目的名称或索引public void select(int itemIndex)
itemIndex
- 可选择的项目的名称或索引public boolean isEditable()
public int getItemCount()
public List<ItemIdentifier> getItems()
public int getSelectedIndex()
public ItemIdentifier getSelectedItem()
Copyright 2009-2012 Micro Focus. All Rights Reserved.