78 |
public void put(KeyStroke keystroke, Object value) |
public void put(KeyStroke keystroke, Object value) |
79 |
{ |
{ |
80 |
super.put(keystroke, value); |
super.put(keystroke, value); |
81 |
// FIXME: Notify component. |
if (component != null) |
82 |
|
component.updateComponentInputMap(this); |
83 |
} |
} |
84 |
|
|
85 |
/** |
/** |
88 |
public void clear() |
public void clear() |
89 |
{ |
{ |
90 |
super.clear(); |
super.clear(); |
91 |
// FIXME: Notify component. |
if (component != null) |
92 |
|
component.updateComponentInputMap(this); |
93 |
} |
} |
94 |
|
|
95 |
/** |
/** |
100 |
public void remove(KeyStroke keystroke) |
public void remove(KeyStroke keystroke) |
101 |
{ |
{ |
102 |
super.remove(keystroke); |
super.remove(keystroke); |
103 |
// FIXME: Notify component. |
if (component != null) |
104 |
|
component.updateComponentInputMap(this); |
105 |
} |
} |
106 |
|
|
107 |
/** |
/** |
114 |
*/ |
*/ |
115 |
public void setParent(InputMap parentMap) |
public void setParent(InputMap parentMap) |
116 |
{ |
{ |
117 |
if (! (parentMap instanceof ComponentInputMap)) |
if (parentMap != null && !(parentMap instanceof ComponentInputMap)) |
118 |
throw new IllegalArgumentException(); |
throw new IllegalArgumentException("ComponentInputMaps can only have " + |
119 |
|
"ComponentInputMaps for parents"); |
120 |
if (((ComponentInputMap) parentMap).getComponent() != component) |
|
121 |
throw new IllegalArgumentException(); |
if (parentMap != null && |
122 |
|
((ComponentInputMap) parentMap).getComponent() != component) |
123 |
|
throw new |
124 |
|
IllegalArgumentException("ComponentInputMaps' parents must " + |
125 |
|
"be associated with the same JComponents"); |
126 |
|
|
127 |
super.setParent(parentMap); |
super.setParent(parentMap); |
128 |
// FIXME: Notify component. |
if (component != null) |
129 |
|
component.updateComponentInputMap(this); |
130 |
} |
} |
131 |
|
|
132 |
/** |
/** |