public class BlockingLayerUI2 extends LayerUI<JComponent>
setAcceptAction(Action)acceptEvent(MouseEvent, JLayer)| Modifier and Type | Field and Description |
|---|---|
static String |
ACCEPT_ICON_PROPERTY |
protected Action |
acceptAction
Action to be treated when click on icon
|
protected BufferedImage |
acceptIcon
Icon when you can click
|
static String |
BLOCK_ICON_PROPERTY |
protected BufferedImage |
blockIcon
Icon when you can not click
|
protected Color |
blockingColor
Optinal color to put fill background when blocking
|
static String |
CAN_CLICK_PROPERTY |
protected boolean |
canClick
Internal state to known when we can accept click
|
| Constructor and Description |
|---|
BlockingLayerUI2() |
addPropertyChangeListener, addPropertyChangeListener, doLayout, eventDispatched, firePropertyChange, getBaseline, getBaselineResizeBehavior, getMaximumSize, getMinimumSize, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, paintImmediately, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, removePropertyChangeListener, removePropertyChangeListener, updateUIcontains, createUI, getAccessibleChild, getAccessibleChildrenCount, updatepublic static final String CAN_CLICK_PROPERTY
public static final String ACCEPT_ICON_PROPERTY
public static final String BLOCK_ICON_PROPERTY
protected Action acceptAction
protected BufferedImage blockIcon
protected BufferedImage acceptIcon
protected Color blockingColor
protected boolean canClick
public void setAcceptAction(Action acceptAction)
public void setAcceptIcon(ImageIcon acceptIcon)
public void setBlockIcon(ImageIcon blockIcon)
public void setCanClick(boolean canClick)
public void setDirty(boolean dirty)
public void applyPropertyChange(PropertyChangeEvent evt, JLayer<? extends JComponent> l)
applyPropertyChange in class LayerUI<JComponent>public void setBlockingColor(Color blockingColor)
public void setBlockIcon(BufferedImage blockIcon)
public BufferedImage getBlockIcon()
protected BufferedImage getAcceptIcon()
public boolean isCanClick()
public BlockingLayerUI2 clone()
protected void processKeyEvent(KeyEvent e, JLayer<? extends JComponent> l)
processKeyEvent in class LayerUI<JComponent>protected void processMouseMotionEvent(MouseEvent e, JLayer<? extends JComponent> l)
processMouseMotionEvent in class LayerUI<JComponent>protected void processMouseWheelEvent(MouseWheelEvent e, JLayer<? extends JComponent> l)
processMouseWheelEvent in class LayerUI<JComponent>protected void processMouseEvent(MouseEvent e, JLayer<? extends JComponent> l)
processMouseEvent in class LayerUI<JComponent>public void installUI(JComponent c)
installUI in class LayerUI<JComponent>public void uninstallUI(JComponent c)
uninstallUI in class LayerUI<JComponent>public void paint(Graphics g, JComponent c)
paint in class LayerUI<JComponent>protected void acceptEvent(MouseEvent e, JLayer<? extends JComponent> l)
protected BufferedImage getCurrentIcon()
protected BufferedImage prepareIcon(ImageIcon image)
protected void updateCanClickState(JLayer<JComponent> l, MouseEvent e)
Copyright © 2008–2015 CodeLutin. All rights reserved.