This method can take another component as its argument, and will then transfer focus to the component that follows in the focus traversal cycle.
该方法可以把另一个组件作为它的参数,然后把焦点传递给焦点遍历循环中紧接着的那个组件。
The existing focus model has been plagued by countless bugs and greatly lacks functionality, such as not being able to query which component currently has the focus.
现有的焦点模型非常令人头痛,因为它存在无数的错误,并且功能很少,比如不能查询当前哪个组件拥有焦点。
It can take a component as its argument, thus moving the focus up one traversal cycle to the component's traversal cycle.
它可以把一个组件作为它的参数,从而把焦点向上移动一个遍历循环到该组件的遍历循环。
As such, component interfaces and implementations come into focus when distinguishing granularity.
因为这样,在区分粒度时,需要关注组件接口和实现。
Which component gets the initial focus when the application is started?
当应用程序启动时哪个组件得到了初始的焦点呢?
All traversal operations start from the current focus owner or from another component virtually considered as the focus owner.
所有遍历操作都从当前的焦点所有者或从另一个被虚拟的认作焦点所有者的组件开始。
All key events are discarded until user interaction or code explicitly sets focus ownership to a particular component.
直到用户交互或代码明确地设置了焦点所有权为特殊的组件,才丢弃所有的键事件。
Although it makes sense for the next focus traversable visible component to get the initial focus, it really depends on the native focus manager.
虽然,下一个焦点可遍历的可见组件获取初始的焦点也是合理的,但这的确依赖于本机焦点管理器。
A component receives focus when a user or AT reader selects it, usually via keyboard controls.
当用户或AT阅读器选择组件时(通常是通过键盘控制装置),则组件接收焦点。
For example, when a component gets the focus, the opposite component is the component that loses the focus.
例如,当一个组件获得了焦点时,其对立组件就是那个失去该焦点的组件。
Each component in a focus traversal cycle has its own previous and next component.
焦点遍历循环中每个组件都有自己的上一个组件和下一个组件。
Typically, an assistive reader will present this name whenever a component receives focus.
通常,只要组件接收到焦点,辅助阅读器就会提供这个名称。
Additionally, categories can be selected in the tag cloud and that focus passed back to the discussion database component view.
此外,可以在标记云中选择类别,并将这个信息传回到讨论数据库组件视图中。
Given a particular component in a specific focus cycle root (think container), the methods return which component would be before it or after.
根据特定的焦点循环根(比如容器)中的某个组件,这两个方法将返回该组件之前或者之后的一个组件。
Install a focus listener on the component and look for the FOCUS_GAINED event.
而应该给组件安装一个焦点侦听器,并查找FOCUS_GAINED事件。
After you've defined your Tab order, you'll need to ensure each initial component will receive focus when its container is selected.
在定义了跳格顺序之后,您需要确保每个初始组件都在选中其容器时接收到焦点。
The opposite component in a focus change is simply the component that gets the opposite event.
焦点更改的对立组件只是个获取对立事件的组件。
This component is the focus of this article.
此组件是本文的重点。
The current focus owner is the component that has received a FOCUS_GAINED but no FOCUS_LOST event (see below for more on these events).
当前的焦点所有者是个已收到FOCUS_GAINED事件—但还未收到FOCUS_LOST事件的组件(有关这些事件的更多信息,请参阅下面的内容)。
Some window and component focus events have corresponding opposite events. These event sets include.
一些窗口和组件的焦点事件含有相应的对立事件。
FocusNextComponent transfers focus to the next component in the traversal cycle.
focusNextComponent在遍历循环中把焦点传递给下一个组件。
DownFocusCycle works the same way, but only where the component is the root of a focus traversal cycle.
downFocusCycle的处理方法相同,但只在组件是焦点遍历循环的根的情况下使用。
Determining the opposite component in a focus change.
确定焦点更改中的对立组件。
When focus enters that subcontainer, getDefaultComponent() needs to return the initial component that should get focus.
当焦点进入那个子容器时,getDefaultComponent()需要返回应该获得焦点的初始组件。
This will return null only when focus has been set to "no component."
这样,只有当焦点被设置成“无组件(no component)”时才会返回空。
Setting the property to true means that when focus moves back and forth, the focus will always stay within a component of the cycle within its focus cycle root.
将属性设置为true意味着当焦点来回转移时,这个焦点将一直呆在焦点循环根内的一个 循环组件之中。
Because Swing is built on top of the Abstract Window Toolkit (AWT), the management of component focus relies on the underlying focus management in the AWT.
由于Swing建立在抽象窗口工具包(awt)之上,对组件焦点的管理便依赖于awt中的底层焦点管理。
Listing 13 shows you how to add a roll-over effect to your component, so that the component shows a "focus" selection whenever a user rolls over the component.
清单13显示了如何为组件添加滚动效果,当用户滚动到该组件时,它将显示一个“焦点”选择?
You can use Shift-Tab to shift focus to the previous component in the TAB group.
用Shift -tab将焦点转到tab组的前一个组件。
The TextField has focus listeners to demonstrate the focus changes to and from the example component.
TextField 用焦点侦听者来演示焦点移动到该示例组件和从该组件移走时发生的变化。
应用推荐