|
|
@ -34,6 +34,7 @@ public class LockIcon extends ImageIcon { |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
public void paintIcon(Component c, Graphics g, int x, int y) { |
|
|
|
public void paintIcon(Component c, Graphics g, int x, int y) { |
|
|
|
if (mainImage != null) { |
|
|
|
if (mainImage != null) { |
|
|
|
g.drawImage(mainImage, x, y, c); |
|
|
|
g.drawImage(mainImage, x, y, c); |
|
|
@ -48,6 +49,7 @@ public class LockIcon extends ImageIcon { |
|
|
|
* |
|
|
|
* |
|
|
|
* @param image the image |
|
|
|
* @param image the image |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
|
|
|
|
@Override |
|
|
|
protected void loadImage(Image image) { |
|
|
|
protected void loadImage(Image image) { |
|
|
|
synchronized (tracker) { |
|
|
|
synchronized (tracker) { |
|
|
|
tracker.addImage(image, 0); |
|
|
|
tracker.addImage(image, 0); |
|
|
@ -55,6 +57,7 @@ public class LockIcon extends ImageIcon { |
|
|
|
tracker.waitForID(0, 0); |
|
|
|
tracker.waitForID(0, 0); |
|
|
|
} catch (InterruptedException e) { |
|
|
|
} catch (InterruptedException e) { |
|
|
|
FineLoggerFactory.getLogger().error(e.getMessage(), e); |
|
|
|
FineLoggerFactory.getLogger().error(e.getMessage(), e); |
|
|
|
|
|
|
|
Thread.currentThread().interrupt(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
loadStatus = tracker.statusID(0, false); |
|
|
|
loadStatus = tracker.statusID(0, false); |
|
|
@ -70,6 +73,7 @@ public class LockIcon extends ImageIcon { |
|
|
|
* |
|
|
|
* |
|
|
|
* @return the <code>Image</code> object for this <code>ImageIcon</code> |
|
|
|
* @return the <code>Image</code> object for this <code>ImageIcon</code> |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
|
|
|
|
@Override |
|
|
|
public Image getImage() { |
|
|
|
public Image getImage() { |
|
|
|
return mainImage; |
|
|
|
return mainImage; |
|
|
|
} |
|
|
|
} |
|
|
@ -85,6 +89,7 @@ public class LockIcon extends ImageIcon { |
|
|
|
* |
|
|
|
* |
|
|
|
* @return the width in pixels of this icon |
|
|
|
* @return the width in pixels of this icon |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
|
|
|
|
@Override |
|
|
|
public int getIconWidth() { |
|
|
|
public int getIconWidth() { |
|
|
|
return width; |
|
|
|
return width; |
|
|
|
} |
|
|
|
} |
|
|
@ -94,6 +99,7 @@ public class LockIcon extends ImageIcon { |
|
|
|
* |
|
|
|
* |
|
|
|
* @return the height in pixels of this icon |
|
|
|
* @return the height in pixels of this icon |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
|
|
|
|
@Override |
|
|
|
public int getIconHeight() { |
|
|
|
public int getIconHeight() { |
|
|
|
return height; |
|
|
|
return height; |
|
|
|
} |
|
|
|
} |
|
|
|