mirror of git://gcc.gnu.org/git/gcc.git
AbstractAction.java: Reformated.
2004-01-23 Michael Koch <konqueror@gmx.de> * javax/swing/AbstractAction.java: Reformated. From-SVN: r76424
This commit is contained in:
parent
f0bf056e74
commit
f1184d57e2
|
|
@ -1,3 +1,7 @@
|
||||||
|
2004-01-23 Michael Koch <konqueror@gmx.de>
|
||||||
|
|
||||||
|
* javax/swing/AbstractAction.java: Reformated.
|
||||||
|
|
||||||
2004-01-23 Michael Koch <konqueror@gmx.de>
|
2004-01-23 Michael Koch <konqueror@gmx.de>
|
||||||
|
|
||||||
* java/text/CollationElementIterator.java:
|
* java/text/CollationElementIterator.java:
|
||||||
|
|
|
||||||
|
|
@ -75,99 +75,124 @@ public abstract class AbstractAction
|
||||||
/**
|
/**
|
||||||
* Constructor AbstractAction
|
* Constructor AbstractAction
|
||||||
*/
|
*/
|
||||||
public AbstractAction() {
|
public AbstractAction()
|
||||||
|
{
|
||||||
this(""); // TODO: default name
|
this(""); // TODO: default name
|
||||||
} // AbstractAction()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Constructor AbstractAction
|
* Constructor AbstractAction
|
||||||
|
*
|
||||||
* @param name TODO
|
* @param name TODO
|
||||||
*/
|
*/
|
||||||
public AbstractAction(String name) {
|
public AbstractAction(String name)
|
||||||
|
{
|
||||||
this(name, null); // TODO: default icon??
|
this(name, null); // TODO: default icon??
|
||||||
} // AbstractAction()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Constructor AbstractAction
|
* Constructor AbstractAction
|
||||||
|
*
|
||||||
* @param name TODO
|
* @param name TODO
|
||||||
* @param icon TODO
|
* @param icon TODO
|
||||||
*/
|
*/
|
||||||
public AbstractAction(String name, Icon icon) {
|
public AbstractAction(String name, Icon icon)
|
||||||
|
{
|
||||||
putValue(NAME, name);
|
putValue(NAME, name);
|
||||||
putValue(SMALL_ICON, icon);
|
putValue(SMALL_ICON, icon);
|
||||||
} // AbstractAction()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* readObject
|
* readObject
|
||||||
* @param stream TODO
|
*
|
||||||
|
* @param stream the stream to read from
|
||||||
|
*
|
||||||
* @exception ClassNotFoundException TODO
|
* @exception ClassNotFoundException TODO
|
||||||
* @exception IOException TODO
|
* @exception IOException if an error occurs
|
||||||
*/
|
*/
|
||||||
private void readObject(ObjectInputStream stream)
|
private void readObject(ObjectInputStream stream)
|
||||||
throws ClassNotFoundException, IOException {
|
throws ClassNotFoundException, IOException
|
||||||
|
{
|
||||||
// TODO
|
// TODO
|
||||||
} // readObject()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* writeObject
|
* writeObject
|
||||||
* @param stream TODO
|
*
|
||||||
* @exception IOException TODO
|
* @param stream the stream to write to
|
||||||
|
*
|
||||||
|
* @exception IOException if an error occurs
|
||||||
*/
|
*/
|
||||||
private void writeObject(ObjectOutputStream stream) throws IOException {
|
private void writeObject(ObjectOutputStream stream) throws IOException
|
||||||
|
{
|
||||||
// TODO
|
// TODO
|
||||||
} // writeObject()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* clone
|
* clone
|
||||||
|
*
|
||||||
|
* @return Object
|
||||||
|
*
|
||||||
* @exception CloneNotSupportedException TODO
|
* @exception CloneNotSupportedException TODO
|
||||||
* @returns Object
|
|
||||||
*/
|
*/
|
||||||
protected Object clone() throws CloneNotSupportedException {
|
protected Object clone() throws CloneNotSupportedException
|
||||||
// What to do??
|
{
|
||||||
return null;
|
AbstractAction copy = (AbstractAction) super.clone();
|
||||||
} // clone()
|
copy.store = (HashMap) store.clone();
|
||||||
|
return copy;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* getValue
|
* Returns a value for a given key from the built-in store.
|
||||||
* @param key TODO
|
*
|
||||||
* @returns Object
|
* @param key the key to get the value for
|
||||||
|
*
|
||||||
|
* @return Object
|
||||||
*/
|
*/
|
||||||
public Object getValue(String key) {
|
public Object getValue(String key)
|
||||||
|
{
|
||||||
return store.get(key);
|
return store.get(key);
|
||||||
} // getValue()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* putValue
|
* Puts a key/value pair into the built-in store.
|
||||||
* @param key TODO
|
*
|
||||||
* @param value TODO
|
* @param key the key
|
||||||
|
* @param value the value
|
||||||
*/
|
*/
|
||||||
public void putValue(String key, Object value) {
|
public void putValue(String key, Object value)
|
||||||
|
{
|
||||||
store.put(key, value);
|
store.put(key, value);
|
||||||
} // putValue()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* isEnabled
|
* isEnabled
|
||||||
* @returns boolean
|
*
|
||||||
|
* @return boolean
|
||||||
*/
|
*/
|
||||||
public boolean isEnabled() {
|
public boolean isEnabled()
|
||||||
|
{
|
||||||
return enabled;
|
return enabled;
|
||||||
} // isEnabled()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* setEnabled
|
* setEnabled
|
||||||
|
*
|
||||||
* @param enabled TODO
|
* @param enabled TODO
|
||||||
*/
|
*/
|
||||||
public void setEnabled(boolean enabled) {
|
public void setEnabled(boolean enabled)
|
||||||
|
{
|
||||||
this.enabled = enabled;
|
this.enabled = enabled;
|
||||||
} // setEnabled()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* getKeys
|
* getKeys
|
||||||
* @returns Object[]
|
* @returns Object[]
|
||||||
*/
|
*/
|
||||||
public Object[] getKeys() {
|
public Object[] getKeys()
|
||||||
|
{
|
||||||
return store.keySet().toArray();
|
return store.keySet().toArray();
|
||||||
} // getKeys()
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* firePropertyChange
|
* firePropertyChange
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue