本文整理匯總了Java中javax.swing.event.DocumentListener.changedUpdate方法的典型用法代碼示例。如果您正苦於以下問題:Java DocumentListener.changedUpdate方法的具體用法?Java DocumentListener.changedUpdate怎麽用?Java DocumentListener.changedUpdate使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類javax.swing.event.DocumentListener
的用法示例。
在下文中一共展示了DocumentListener.changedUpdate方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: changedUpdate
import javax.swing.event.DocumentListener; //導入方法依賴的package包/類
@Override
public void changedUpdate(DocumentEvent e) {
DocumentListener l = getDelegate();
if (l != null) {
l.changedUpdate(e);
}
}
示例2: changedUpdate
import javax.swing.event.DocumentListener; //導入方法依賴的package包/類
/**
* Implementation of DocumentListener's method fires all the added
* listeners according to their priority.
*/
public void changedUpdate(DocumentEvent evt) {
logEvent(evt, "changedUpdate");
// Fire the prioritized listeners
EventListener[][] listenersArray = getListenersArray();
// Attempt to fire to all listeners catching possible exception(s) and report first fired then
RuntimeException runtimeException = null;
for (int priority = listenersArray.length - 1; priority >= 0; priority--) {
logPriority(priority);
EventListener[] listeners = listenersArray[priority];
for (int i = listeners.length - 1; i >= 0; i--) {
DocumentListener l = (DocumentListener) listeners[i];
logListener(l);
try {
l.changedUpdate(evt);
} catch (RuntimeException ex) {
if (runtimeException == null) { // Only record first thrown
runtimeException = ex;
}
}
}
}
if (runtimeException != null) {
throw runtimeException; // Re-throw remembered exception
}
logEventEnd("changedUpdate");
}
示例3: changedUpdate
import javax.swing.event.DocumentListener; //導入方法依賴的package包/類
/** Gives notification that an attribute or set of attributes changed.
* @param ev event describing the action
*/
@Override public void changedUpdate(DocumentEvent ev) {
final DocumentListener l = docGet(ev);
if (l != null) {
l.changedUpdate(ev);
}
}
示例4: fireChangedUpdate
import javax.swing.event.DocumentListener; //導入方法依賴的package包/類
protected void fireChangedUpdate(final DocumentEvent event) {
lock.setCallingListeners(true);
try {
DocumentListener[] listeners = getDocumentListeners();
for (DocumentListener listener : listeners) {
listener.changedUpdate(event);
}
} finally {
lock.setCallingListeners(false);
}
}
示例5: fireDocumentEvent
import javax.swing.event.DocumentListener; //導入方法依賴的package包/類
public void fireDocumentEvent() {
for (DocumentListener l : documentListeners) {
l.changedUpdate(null);
}
}