Examples of ContainerEvent


Examples of java.awt.event.ContainerEvent

                }
            }
            if (containerListener != null ||
                (eventMask & AWTEvent.CONTAINER_EVENT_MASK) != 0 ||
                Toolkit.enabledOnToolkit(AWTEvent.CONTAINER_EVENT_MASK)) {
                ContainerEvent e = new ContainerEvent(this,
                                                      ContainerEvent.COMPONENT_ADDED,
                                                      comp);
                dispatchEvent(e);
            }
            comp.createHierarchyEvents(HierarchyEvent.HIERARCHY_CHANGED, comp,
View Full Code Here

Examples of java.awt.event.ContainerEvent

    }
      }
            if (containerListener != null ||
                (eventMask & AWTEvent.CONTAINER_EVENT_MASK) != 0 ||
                Toolkit.enabledOnToolkit(AWTEvent.CONTAINER_EVENT_MASK)) {
                ContainerEvent e = new ContainerEvent(this,
                                     ContainerEvent.COMPONENT_ADDED,
                                     comp);
                dispatchEvent(e);
            }
View Full Code Here

Examples of java.awt.event.ContainerEvent

            invalidateIfValid();
            if (containerListener != null ||
                (eventMask & AWTEvent.CONTAINER_EVENT_MASK) != 0 ||
                Toolkit.enabledOnToolkit(AWTEvent.CONTAINER_EVENT_MASK)) {
                ContainerEvent e = new ContainerEvent(this,
                                     ContainerEvent.COMPONENT_REMOVED,
                                     comp);
                dispatchEvent(e);
            }
View Full Code Here

Examples of java.awt.event.ContainerEvent

    }
    comp.parent = null;
                if (containerListener != null ||
                   (eventMask & AWTEvent.CONTAINER_EVENT_MASK) != 0 ||
                    Toolkit.enabledOnToolkit(AWTEvent.CONTAINER_EVENT_MASK)) {
                    ContainerEvent e = new ContainerEvent(this,
                                     ContainerEvent.COMPONENT_REMOVED,
                                     comp);
                    dispatchEvent(e);
                }
View Full Code Here

Examples of java.awt.event.ContainerEvent

            if (layout != null) {
                layout.removeLayoutComponent(comp);
            }
            removeFromContainer(index);
            // container events are synchronous
            dispatchEvent(new ContainerEvent(this, ContainerEvent.COMPONENT_REMOVED, comp));
        } finally {
            toolkit.unlockAWT();
        }
    }
View Full Code Here

Examples of java.awt.event.ContainerEvent

            // calculated preferred/minimum sizes should be reset
            // because they depend on inherited font
            comp.resetDefaultSize();
            // container events are synchronous
            dispatchEvent(new ContainerEvent(this, ContainerEvent.COMPONENT_ADDED, comp));
        } finally {
            toolkit.unlockAWT();
        }
    }
View Full Code Here

Examples of java.awt.event.ContainerEvent

    }

    public void testToolBarContListener() {
        ContainerListener l = ui.createToolBarContListener();
        Border border = b.getBorder();
        ContainerEvent e = new ContainerEvent(toolBar, ContainerEvent.COMPONENT_ADDED, b);
        l.componentAdded(e);
        assertNotSame(border, b.getBorder());
        e = new ContainerEvent(toolBar, ContainerEvent.COMPONENT_REMOVED, b);
        l.componentRemoved(e);
        assertSame(border, b.getBorder());
    }
View Full Code Here

Examples of org.apache.catalina.ContainerEvent

    public void fireContainerEvent(String type, Object data) {

        if (listeners.size() < 1)
            return;

        ContainerEvent event = new ContainerEvent(this, type, data);
        // Note for each uses an iterator internally so this is safe
        for (ContainerListener listener : listeners) {
            listener.containerEvent(event);
        }
    }
View Full Code Here

Examples of org.apache.catalina.ContainerEvent

     */
    public void fireContainerEvent(String type, Object data) {

        if (listeners.size() < 1)
            return;
        ContainerEvent event = new ContainerEvent(this, type, data);
        ContainerListener list[] = new ContainerListener[0];
        synchronized (listeners) {
            list = (ContainerListener[]) listeners.toArray(list);
        }
        for (int i = 0; i < list.length; i++)
View Full Code Here

Examples of org.apache.catalina.ContainerEvent

     */
    public void fireContainerEvent(String type, Object data) {

        if (listeners.size() < 1)
            return;
        ContainerEvent event = new ContainerEvent(this, type, data);
        ContainerListener list[] = new ContainerListener[0];
        synchronized (listeners) {
            list = (ContainerListener[]) listeners.toArray(list);
        }
        for (int i = 0; i < list.length; i++)
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.