Sets the default icon of the authentication window to be the application logo.

cusax-fix
Yana Stamcheva 15 years ago
parent ff5a1b7693
commit 7fe1264c71

@ -1,6 +1,7 @@
# service gui
service.gui.SIP_COMMUNICATOR_LOGO=resources/images/logo/sc_logo16x16.png
service.gui.SIP_COMMUNICATOR_LOGO_45x45=resources/images/logo/sc_logo_45x45.png
service.gui.SIP_COMMUNICATOR_LOGO_64x64=resources/images/logo/sc_logo_64x64.png
service.gui.MAIN_WINDOW_BACKGROUND=
service.gui.AUTH_WINDOW_BACKGROUND=resources/images/impl/gui/common/passWindowBackground.png
service.gui.ABOUT_WINDOW_BACKGROUND=resources/images/impl/gui/common/aboutWindowBackground.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

@ -775,7 +775,8 @@ protected PasswordAuthentication getPasswordAuthentication()
else
{
AuthenticationWindow authWindow =
new AuthenticationWindow("host", true, null);
new AuthenticationWindow(
getRequestingHost(), true, null);
userCredentials = new UserCredentials();

@ -102,10 +102,7 @@ public AuthenticationWindow(String server,
this.server = server;
if(icon != null)
{
initIcon(icon);
}
initIcon(icon);
if(!isUserNameEditable)
this.uinValue = new JLabel();
@ -200,6 +197,11 @@ else if (uinValue instanceof JTextField)
*/
private void initIcon(ImageIcon icon)
{
// If an icon isn't provided set the application logo icon by default.
if (icon == null)
icon = UtilActivator.getResources()
.getImage("service.gui.SIP_COMMUNICATOR_LOGO_64x64");
JLabel iconLabel = new JLabel(icon);
iconLabel.setBorder(BorderFactory.createEmptyBorder(20, 20, 20, 20));

Loading…
Cancel
Save