Lines 220-233
Link Here
|
220 |
|
220 |
|
221 |
/** Connects buttons to action. If the action supplies value for "iconBase" |
221 |
/** Connects buttons to action. If the action supplies value for "iconBase" |
222 |
* key from getValue(String) with a path to icons the methods setIcon, |
222 |
* key from getValue(String) with a path to icons the methods setIcon, |
223 |
* setPressedIcon, setDisabledIcon and setRolloverIcon will be called on the |
223 |
* setPressedIcon, setDisabledIcon, setRolloverIcon |
|
|
224 |
* setSelectedIcon, setRolloverSelectedIcon and SetDisabledSelectedIcon |
225 |
* will be called on the |
224 |
* button with loaded icons using the iconBase. E.g. if the value for "iconBase" |
226 |
* button with loaded icons using the iconBase. E.g. if the value for "iconBase" |
225 |
* will be "com/mycompany/myIcon.gif" following images will be tried "com/mycompany/myIcon.gif" |
227 |
* will be "com/mycompany/myIcon.gif" following images will be tried |
226 |
* for setIcon, "com/mycompany/myIcon_pressed.gif" for setPressedIcon, |
228 |
* "com/mycompany/myIcon.gif" for setIcon, |
227 |
* "com/mycompany/myIcon_disabled.gif" for setDisabledIcon and |
229 |
* "com/mycompany/myIcon_pressed.gif" for setPressedIcon, |
228 |
* "com/mycompany/myIcon_rollover.gif" for setRolloverIcon. SystemAction has |
230 |
* "com/mycompany/myIcon_disabled.gif" for setDisabledIcon, |
229 |
* special support for iconBase - please check {@link SystemAction#iconResource} |
231 |
* "com/mycompany/myIcon_rollover.gif" for setRolloverIcon, |
230 |
* for more details. |
232 |
* "com/mycompany/myIcon_selected.gif" for setSelectedIcon, |
|
|
233 |
* "com/mycompany/myIcon_rolloverSelected.gif" for setRolloverSelectedIcon and |
234 |
* "com/mycompany/myIcon_disabledSelected.gif" for setDisabledSelectedIcon. |
235 |
* SystemAction has special support for iconBase - please check |
236 |
* {@link SystemAction#iconResource} for more details. |
231 |
* You can supply an alternative implementation |
237 |
* You can supply an alternative implementation |
232 |
* for this method by implementing method |
238 |
* for this method by implementing method |
233 |
* {@link ButtonActionConnector#connect(AbstractButton, Action)} and |
239 |
* {@link ButtonActionConnector#connect(AbstractButton, Action)} and |
Lines 1025-1030
Link Here
|
1025 |
} else if (imgIcon != null) { |
1031 |
} else if (imgIcon != null) { |
1026 |
button.setDisabledIcon(ImageUtilities.createDisabledIcon(imgIcon)); |
1032 |
button.setDisabledIcon(ImageUtilities.createDisabledIcon(imgIcon)); |
1027 |
} |
1033 |
} |
|
|
1034 |
|
1035 |
ImageIcon sImgIcon = ImageUtilities.loadImageIcon(insertBeforeSuffix(b, "_selected"), true); // NOI18N |
1036 |
if (sImgIcon != null) { |
1037 |
button.setSelectedIcon(sImgIcon); |
1038 |
} |
1039 |
|
1040 |
sImgIcon = ImageUtilities.loadImageIcon(insertBeforeSuffix(b, "_rolloverSelected"), true); // NOI18N |
1041 |
if (sImgIcon != null) { |
1042 |
button.setRolloverSelectedIcon(sImgIcon); |
1043 |
} |
1044 |
|
1045 |
sImgIcon = ImageUtilities.loadImageIcon(insertBeforeSuffix(b, "_disabledSelected"), true); // NOI18N |
1046 |
if (sImgIcon != null) { |
1047 |
button.setDisabledSelectedIcon(sImgIcon); |
1048 |
} |
1028 |
} |
1049 |
} |
1029 |
} |
1050 |
} |
1030 |
|
1051 |
|