public abstract class FocusManager extends DefaultKeyboardFocusManager
java.awt.KeyboardFocusManagerおよびjava.awt.DefaultKeyboardFocusManagerに移行することを強く推奨します。
詳細は、「The Java Tutorial」の「How to Use the Focus Subsystem」および「Focus Specification」を参照してください。
| 修飾子と型 | フィールド | 説明 |
|---|---|---|
static String |
FOCUS_MANAGER_CLASS_PROPERTY |
このフィールドは現在使われていません。仕様が1.4 focus APIと互換性がないため使用しないことをお勧めします。
|
BACKWARD_TRAVERSAL_KEYS, DOWN_CYCLE_TRAVERSAL_KEYS, FORWARD_TRAVERSAL_KEYS, UP_CYCLE_TRAVERSAL_KEYS| コンストラクタ | 説明 |
|---|---|
FocusManager() |
| 修飾子と型 | メソッド | 説明 |
|---|---|---|
static void |
disableSwingFocusManager() |
非推奨。
1.4以降は、
KeyboardFocusManager.setDefaultFocusTraversalPolicy(FocusTraversalPolicy)に置き換えられています |
static FocusManager |
getCurrentManager() |
スレッドのコンテキストの呼出しに対して、現在の
KeyboardFocusManagerインスタンスを返します。 |
static boolean |
isFocusManagerEnabled() |
非推奨。
1.4以降は、
KeyboardFocusManager.getDefaultFocusTraversalPolicy()に置き換えられています。 |
static void |
setCurrentManager(FocusManager aFocusManager) |
スレッドのコンテキストの呼出しに対して、現在の
KeyboardFocusManagerインスタンスを設定します。 |
dequeueKeyEvents, discardKeyEvents, dispatchEvent, dispatchKeyEvent, downFocusCycle, enqueueKeyEvents, focusNextComponent, focusPreviousComponent, postProcessKeyEvent, processKeyEvent, upFocusCycleaddKeyEventDispatcher, addKeyEventPostProcessor, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, clearFocusOwner, clearGlobalFocusOwner, downFocusCycle, firePropertyChange, fireVetoableChange, focusNextComponent, focusPreviousComponent, getActiveWindow, getCurrentFocusCycleRoot, getCurrentKeyboardFocusManager, getDefaultFocusTraversalKeys, getDefaultFocusTraversalPolicy, getFocusedWindow, getFocusOwner, getGlobalActiveWindow, getGlobalCurrentFocusCycleRoot, getGlobalFocusedWindow, getGlobalFocusOwner, getGlobalPermanentFocusOwner, getKeyEventDispatchers, getKeyEventPostProcessors, getPermanentFocusOwner, getPropertyChangeListeners, getPropertyChangeListeners, getVetoableChangeListeners, getVetoableChangeListeners, redispatchEvent, removeKeyEventDispatcher, removeKeyEventPostProcessor, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener, setCurrentKeyboardFocusManager, setDefaultFocusTraversalKeys, setDefaultFocusTraversalPolicy, setGlobalActiveWindow, setGlobalCurrentFocusCycleRoot, setGlobalFocusedWindow, setGlobalFocusOwner, setGlobalPermanentFocusOwner, upFocusCyclepublic static final String FOCUS_MANAGER_CLASS_PROPERTY
KeyboardFocusManager.getCurrentKeyboardFocusManager()を使用して現在のFocusManagerを照会する必要があります。 詳細はフォーカスの仕様を参照してください。 public static FocusManager getCurrentManager()
KeyboardFocusManagerインスタンスを返します。KeyboardFocusManagersetCurrentManager(javax.swing.FocusManager)public static void setCurrentManager(FocusManager aFocusManager) throws SecurityException
KeyboardFocusManagerインスタンスを設定します。 nullが指定された場合、現在のKeyboardFocusManagerはDefaultKeyboardFocusManagerの新しいインスタンスに置き換えられます。
SecurityManagerがインストールされている場合、呼出し側スレッドは現在のKeyboardFocusManagerを置き換えるためにAWTPermission "replaceKeyboardFocusManager"によりアクセス権が許可されている必要があります。 このアクセス権が許可されていない場合、このメソッドはSecurityExceptionをスローして、現在のKeyboardFocusManagerは変更されません。
aFocusManager - このスレッドのコンテキストに対する新しいKeyboardFocusManagerSecurityException - 呼出し側スレッドに、現在のKeyboardFocusManagerを置き換えるために必要なアクセス権がない場合getCurrentManager(), DefaultKeyboardFocusManager@Deprecated public static void disableSwingFocusManager()
KeyboardFocusManager.setDefaultFocusTraversalPolicy(FocusTraversalPolicy)に置き換えられています。KeyboardFocusManagerのデフォルトのFocusTraversalPolicyをDefaultFocusTraversalPolicyに変更します。@Deprecated public static boolean isFocusManagerEnabled()
KeyboardFocusManager.getDefaultFocusTraversalPolicy()に置き換えられています。 disableSwingFocusManager()を呼び出したかどうかを返します。 バグまたは機能を送信
詳細なAPIリファレンスおよび開発者ドキュメントについては、Java SEのドキュメントを参照してください。 そのドキュメントには、概念的な概要、用語の定義、回避方法、有効なコード例などの、開発者を対象にしたより詳細な説明が含まれています。
Copyright © 1993, 2025, Oracle and/or its affiliates. All rights reserved. Use is subject to license terms. Documentation Redistribution Policyも参照してください。