108 MouseListener, MouseMotionListener, WindowListener, WindowFocusListener, |
108 MouseListener, MouseMotionListener, WindowListener, WindowFocusListener, |
109 WindowStateListener, ActionListener, ItemListener, AdjustmentListener, |
109 WindowStateListener, ActionListener, ItemListener, AdjustmentListener, |
110 TextListener, InputMethodListener, HierarchyListener, |
110 TextListener, InputMethodListener, HierarchyListener, |
111 HierarchyBoundsListener, MouseWheelListener { |
111 HierarchyBoundsListener, MouseWheelListener { |
112 |
112 |
113 protected final EventListener a, b; |
113 /** |
|
114 * A variable in the event chain (listener-a) |
|
115 */ |
|
116 protected final EventListener a; |
|
117 |
|
118 /** |
|
119 * A variable in the event chain (listener-b) |
|
120 */ |
|
121 protected final EventListener b; |
114 |
122 |
115 /** |
123 /** |
116 * Creates an event multicaster instance which chains listener-a |
124 * Creates an event multicaster instance which chains listener-a |
117 * with listener-b. Input parameters <code>a</code> and <code>b</code> |
125 * with listener-b. Input parameters <code>a</code> and <code>b</code> |
118 * should not be <code>null</code>, though implementations may vary in |
126 * should not be <code>null</code>, though implementations may vary in |
535 /** |
543 /** |
536 * Adds component-listener-a with component-listener-b and |
544 * Adds component-listener-a with component-listener-b and |
537 * returns the resulting multicast listener. |
545 * returns the resulting multicast listener. |
538 * @param a component-listener-a |
546 * @param a component-listener-a |
539 * @param b component-listener-b |
547 * @param b component-listener-b |
|
548 * @return the resulting listener |
540 */ |
549 */ |
541 public static ComponentListener add(ComponentListener a, ComponentListener b) { |
550 public static ComponentListener add(ComponentListener a, ComponentListener b) { |
542 return (ComponentListener)addInternal(a, b); |
551 return (ComponentListener)addInternal(a, b); |
543 } |
552 } |
544 |
553 |
545 /** |
554 /** |
546 * Adds container-listener-a with container-listener-b and |
555 * Adds container-listener-a with container-listener-b and |
547 * returns the resulting multicast listener. |
556 * returns the resulting multicast listener. |
548 * @param a container-listener-a |
557 * @param a container-listener-a |
549 * @param b container-listener-b |
558 * @param b container-listener-b |
|
559 * @return the resulting listener |
550 */ |
560 */ |
551 public static ContainerListener add(ContainerListener a, ContainerListener b) { |
561 public static ContainerListener add(ContainerListener a, ContainerListener b) { |
552 return (ContainerListener)addInternal(a, b); |
562 return (ContainerListener)addInternal(a, b); |
553 } |
563 } |
554 |
564 |
555 /** |
565 /** |
556 * Adds focus-listener-a with focus-listener-b and |
566 * Adds focus-listener-a with focus-listener-b and |
557 * returns the resulting multicast listener. |
567 * returns the resulting multicast listener. |
558 * @param a focus-listener-a |
568 * @param a focus-listener-a |
559 * @param b focus-listener-b |
569 * @param b focus-listener-b |
|
570 * @return the resulting listener |
560 */ |
571 */ |
561 public static FocusListener add(FocusListener a, FocusListener b) { |
572 public static FocusListener add(FocusListener a, FocusListener b) { |
562 return (FocusListener)addInternal(a, b); |
573 return (FocusListener)addInternal(a, b); |
563 } |
574 } |
564 |
575 |
565 /** |
576 /** |
566 * Adds key-listener-a with key-listener-b and |
577 * Adds key-listener-a with key-listener-b and |
567 * returns the resulting multicast listener. |
578 * returns the resulting multicast listener. |
568 * @param a key-listener-a |
579 * @param a key-listener-a |
569 * @param b key-listener-b |
580 * @param b key-listener-b |
|
581 * @return the resulting listener |
570 */ |
582 */ |
571 public static KeyListener add(KeyListener a, KeyListener b) { |
583 public static KeyListener add(KeyListener a, KeyListener b) { |
572 return (KeyListener)addInternal(a, b); |
584 return (KeyListener)addInternal(a, b); |
573 } |
585 } |
574 |
586 |
575 /** |
587 /** |
576 * Adds mouse-listener-a with mouse-listener-b and |
588 * Adds mouse-listener-a with mouse-listener-b and |
577 * returns the resulting multicast listener. |
589 * returns the resulting multicast listener. |
578 * @param a mouse-listener-a |
590 * @param a mouse-listener-a |
579 * @param b mouse-listener-b |
591 * @param b mouse-listener-b |
|
592 * @return the resulting listener |
580 */ |
593 */ |
581 public static MouseListener add(MouseListener a, MouseListener b) { |
594 public static MouseListener add(MouseListener a, MouseListener b) { |
582 return (MouseListener)addInternal(a, b); |
595 return (MouseListener)addInternal(a, b); |
583 } |
596 } |
584 |
597 |
585 /** |
598 /** |
586 * Adds mouse-motion-listener-a with mouse-motion-listener-b and |
599 * Adds mouse-motion-listener-a with mouse-motion-listener-b and |
587 * returns the resulting multicast listener. |
600 * returns the resulting multicast listener. |
588 * @param a mouse-motion-listener-a |
601 * @param a mouse-motion-listener-a |
589 * @param b mouse-motion-listener-b |
602 * @param b mouse-motion-listener-b |
|
603 * @return the resulting listener |
590 */ |
604 */ |
591 public static MouseMotionListener add(MouseMotionListener a, MouseMotionListener b) { |
605 public static MouseMotionListener add(MouseMotionListener a, MouseMotionListener b) { |
592 return (MouseMotionListener)addInternal(a, b); |
606 return (MouseMotionListener)addInternal(a, b); |
593 } |
607 } |
594 |
608 |
595 /** |
609 /** |
596 * Adds window-listener-a with window-listener-b and |
610 * Adds window-listener-a with window-listener-b and |
597 * returns the resulting multicast listener. |
611 * returns the resulting multicast listener. |
598 * @param a window-listener-a |
612 * @param a window-listener-a |
599 * @param b window-listener-b |
613 * @param b window-listener-b |
|
614 * @return the resulting listener |
600 */ |
615 */ |
601 public static WindowListener add(WindowListener a, WindowListener b) { |
616 public static WindowListener add(WindowListener a, WindowListener b) { |
602 return (WindowListener)addInternal(a, b); |
617 return (WindowListener)addInternal(a, b); |
603 } |
618 } |
604 |
619 |
605 /** |
620 /** |
606 * Adds window-state-listener-a with window-state-listener-b |
621 * Adds window-state-listener-a with window-state-listener-b |
607 * and returns the resulting multicast listener. |
622 * and returns the resulting multicast listener. |
608 * @param a window-state-listener-a |
623 * @param a window-state-listener-a |
609 * @param b window-state-listener-b |
624 * @param b window-state-listener-b |
|
625 * @return the resulting listener |
610 * @since 1.4 |
626 * @since 1.4 |
611 */ |
627 */ |
612 @SuppressWarnings("overloads") |
628 @SuppressWarnings("overloads") |
613 public static WindowStateListener add(WindowStateListener a, |
629 public static WindowStateListener add(WindowStateListener a, |
614 WindowStateListener b) { |
630 WindowStateListener b) { |
652 /** |
671 /** |
653 * Adds adjustment-listener-a with adjustment-listener-b and |
672 * Adds adjustment-listener-a with adjustment-listener-b and |
654 * returns the resulting multicast listener. |
673 * returns the resulting multicast listener. |
655 * @param a adjustment-listener-a |
674 * @param a adjustment-listener-a |
656 * @param b adjustment-listener-b |
675 * @param b adjustment-listener-b |
|
676 * @return the resulting listener |
657 */ |
677 */ |
658 @SuppressWarnings("overloads") |
678 @SuppressWarnings("overloads") |
659 public static AdjustmentListener add(AdjustmentListener a, AdjustmentListener b) { |
679 public static AdjustmentListener add(AdjustmentListener a, AdjustmentListener b) { |
660 return (AdjustmentListener)addInternal(a, b); |
680 return (AdjustmentListener)addInternal(a, b); |
661 } |
681 } |
|
682 |
|
683 /** |
|
684 * Adds text-listener-a with text-listener-b and |
|
685 * returns the resulting multicast listener. |
|
686 * |
|
687 * @param a text-listener-a |
|
688 * @param b text-listener-b |
|
689 * @return the resulting listener |
|
690 */ |
662 @SuppressWarnings("overloads") |
691 @SuppressWarnings("overloads") |
663 public static TextListener add(TextListener a, TextListener b) { |
692 public static TextListener add(TextListener a, TextListener b) { |
664 return (TextListener)addInternal(a, b); |
693 return (TextListener)addInternal(a, b); |
665 } |
694 } |
666 |
695 |
667 /** |
696 /** |
668 * Adds input-method-listener-a with input-method-listener-b and |
697 * Adds input-method-listener-a with input-method-listener-b and |
669 * returns the resulting multicast listener. |
698 * returns the resulting multicast listener. |
670 * @param a input-method-listener-a |
699 * @param a input-method-listener-a |
671 * @param b input-method-listener-b |
700 * @param b input-method-listener-b |
|
701 * @return the resulting listener |
672 */ |
702 */ |
673 public static InputMethodListener add(InputMethodListener a, InputMethodListener b) { |
703 public static InputMethodListener add(InputMethodListener a, InputMethodListener b) { |
674 return (InputMethodListener)addInternal(a, b); |
704 return (InputMethodListener)addInternal(a, b); |
675 } |
705 } |
676 |
706 |
677 /** |
707 /** |
678 * Adds hierarchy-listener-a with hierarchy-listener-b and |
708 * Adds hierarchy-listener-a with hierarchy-listener-b and |
679 * returns the resulting multicast listener. |
709 * returns the resulting multicast listener. |
680 * @param a hierarchy-listener-a |
710 * @param a hierarchy-listener-a |
681 * @param b hierarchy-listener-b |
711 * @param b hierarchy-listener-b |
|
712 * @return the resulting listener |
682 * @since 1.3 |
713 * @since 1.3 |
683 */ |
714 */ |
684 @SuppressWarnings("overloads") |
715 @SuppressWarnings("overloads") |
685 public static HierarchyListener add(HierarchyListener a, HierarchyListener b) { |
716 public static HierarchyListener add(HierarchyListener a, HierarchyListener b) { |
686 return (HierarchyListener)addInternal(a, b); |
717 return (HierarchyListener)addInternal(a, b); |
713 /** |
746 /** |
714 * Removes the old component-listener from component-listener-l and |
747 * Removes the old component-listener from component-listener-l and |
715 * returns the resulting multicast listener. |
748 * returns the resulting multicast listener. |
716 * @param l component-listener-l |
749 * @param l component-listener-l |
717 * @param oldl the component-listener being removed |
750 * @param oldl the component-listener being removed |
|
751 * @return the resulting listener |
718 */ |
752 */ |
719 public static ComponentListener remove(ComponentListener l, ComponentListener oldl) { |
753 public static ComponentListener remove(ComponentListener l, ComponentListener oldl) { |
720 return (ComponentListener) removeInternal(l, oldl); |
754 return (ComponentListener) removeInternal(l, oldl); |
721 } |
755 } |
722 |
756 |
723 /** |
757 /** |
724 * Removes the old container-listener from container-listener-l and |
758 * Removes the old container-listener from container-listener-l and |
725 * returns the resulting multicast listener. |
759 * returns the resulting multicast listener. |
726 * @param l container-listener-l |
760 * @param l container-listener-l |
727 * @param oldl the container-listener being removed |
761 * @param oldl the container-listener being removed |
|
762 * @return the resulting listener |
728 */ |
763 */ |
729 public static ContainerListener remove(ContainerListener l, ContainerListener oldl) { |
764 public static ContainerListener remove(ContainerListener l, ContainerListener oldl) { |
730 return (ContainerListener) removeInternal(l, oldl); |
765 return (ContainerListener) removeInternal(l, oldl); |
731 } |
766 } |
732 |
767 |
733 /** |
768 /** |
734 * Removes the old focus-listener from focus-listener-l and |
769 * Removes the old focus-listener from focus-listener-l and |
735 * returns the resulting multicast listener. |
770 * returns the resulting multicast listener. |
736 * @param l focus-listener-l |
771 * @param l focus-listener-l |
737 * @param oldl the focus-listener being removed |
772 * @param oldl the focus-listener being removed |
|
773 * @return the resulting listener |
738 */ |
774 */ |
739 public static FocusListener remove(FocusListener l, FocusListener oldl) { |
775 public static FocusListener remove(FocusListener l, FocusListener oldl) { |
740 return (FocusListener) removeInternal(l, oldl); |
776 return (FocusListener) removeInternal(l, oldl); |
741 } |
777 } |
742 |
778 |
743 /** |
779 /** |
744 * Removes the old key-listener from key-listener-l and |
780 * Removes the old key-listener from key-listener-l and |
745 * returns the resulting multicast listener. |
781 * returns the resulting multicast listener. |
746 * @param l key-listener-l |
782 * @param l key-listener-l |
747 * @param oldl the key-listener being removed |
783 * @param oldl the key-listener being removed |
|
784 * @return the resulting listener |
748 */ |
785 */ |
749 public static KeyListener remove(KeyListener l, KeyListener oldl) { |
786 public static KeyListener remove(KeyListener l, KeyListener oldl) { |
750 return (KeyListener) removeInternal(l, oldl); |
787 return (KeyListener) removeInternal(l, oldl); |
751 } |
788 } |
752 |
789 |
753 /** |
790 /** |
754 * Removes the old mouse-listener from mouse-listener-l and |
791 * Removes the old mouse-listener from mouse-listener-l and |
755 * returns the resulting multicast listener. |
792 * returns the resulting multicast listener. |
756 * @param l mouse-listener-l |
793 * @param l mouse-listener-l |
757 * @param oldl the mouse-listener being removed |
794 * @param oldl the mouse-listener being removed |
|
795 * @return the resulting listener |
758 */ |
796 */ |
759 public static MouseListener remove(MouseListener l, MouseListener oldl) { |
797 public static MouseListener remove(MouseListener l, MouseListener oldl) { |
760 return (MouseListener) removeInternal(l, oldl); |
798 return (MouseListener) removeInternal(l, oldl); |
761 } |
799 } |
762 |
800 |
763 /** |
801 /** |
764 * Removes the old mouse-motion-listener from mouse-motion-listener-l |
802 * Removes the old mouse-motion-listener from mouse-motion-listener-l |
765 * and returns the resulting multicast listener. |
803 * and returns the resulting multicast listener. |
766 * @param l mouse-motion-listener-l |
804 * @param l mouse-motion-listener-l |
767 * @param oldl the mouse-motion-listener being removed |
805 * @param oldl the mouse-motion-listener being removed |
|
806 * @return the resulting listener |
768 */ |
807 */ |
769 public static MouseMotionListener remove(MouseMotionListener l, MouseMotionListener oldl) { |
808 public static MouseMotionListener remove(MouseMotionListener l, MouseMotionListener oldl) { |
770 return (MouseMotionListener) removeInternal(l, oldl); |
809 return (MouseMotionListener) removeInternal(l, oldl); |
771 } |
810 } |
772 |
811 |
773 /** |
812 /** |
774 * Removes the old window-listener from window-listener-l and |
813 * Removes the old window-listener from window-listener-l and |
775 * returns the resulting multicast listener. |
814 * returns the resulting multicast listener. |
776 * @param l window-listener-l |
815 * @param l window-listener-l |
777 * @param oldl the window-listener being removed |
816 * @param oldl the window-listener being removed |
|
817 * @return the resulting listener |
778 */ |
818 */ |
779 public static WindowListener remove(WindowListener l, WindowListener oldl) { |
819 public static WindowListener remove(WindowListener l, WindowListener oldl) { |
780 return (WindowListener) removeInternal(l, oldl); |
820 return (WindowListener) removeInternal(l, oldl); |
781 } |
821 } |
782 |
822 |
783 /** |
823 /** |
784 * Removes the old window-state-listener from window-state-listener-l |
824 * Removes the old window-state-listener from window-state-listener-l |
785 * and returns the resulting multicast listener. |
825 * and returns the resulting multicast listener. |
786 * @param l window-state-listener-l |
826 * @param l window-state-listener-l |
787 * @param oldl the window-state-listener being removed |
827 * @param oldl the window-state-listener being removed |
|
828 * @return the resulting listener |
788 * @since 1.4 |
829 * @since 1.4 |
789 */ |
830 */ |
790 @SuppressWarnings("overloads") |
831 @SuppressWarnings("overloads") |
791 public static WindowStateListener remove(WindowStateListener l, |
832 public static WindowStateListener remove(WindowStateListener l, |
792 WindowStateListener oldl) { |
833 WindowStateListener oldl) { |
830 /** |
874 /** |
831 * Removes the old adjustment-listener from adjustment-listener-l and |
875 * Removes the old adjustment-listener from adjustment-listener-l and |
832 * returns the resulting multicast listener. |
876 * returns the resulting multicast listener. |
833 * @param l adjustment-listener-l |
877 * @param l adjustment-listener-l |
834 * @param oldl the adjustment-listener being removed |
878 * @param oldl the adjustment-listener being removed |
|
879 * @return the resulting listener |
835 */ |
880 */ |
836 @SuppressWarnings("overloads") |
881 @SuppressWarnings("overloads") |
837 public static AdjustmentListener remove(AdjustmentListener l, AdjustmentListener oldl) { |
882 public static AdjustmentListener remove(AdjustmentListener l, AdjustmentListener oldl) { |
838 return (AdjustmentListener) removeInternal(l, oldl); |
883 return (AdjustmentListener) removeInternal(l, oldl); |
839 } |
884 } |
|
885 |
|
886 /** |
|
887 * Removes the old text-listener from text-listener-l and |
|
888 * returns the resulting multicast listener. |
|
889 * |
|
890 * @param l text-listener-l |
|
891 * @param oldl the text-listener being removed |
|
892 * @return the resulting listener |
|
893 */ |
840 @SuppressWarnings("overloads") |
894 @SuppressWarnings("overloads") |
841 public static TextListener remove(TextListener l, TextListener oldl) { |
895 public static TextListener remove(TextListener l, TextListener oldl) { |
842 return (TextListener) removeInternal(l, oldl); |
896 return (TextListener) removeInternal(l, oldl); |
843 } |
897 } |
844 |
898 |
845 /** |
899 /** |
846 * Removes the old input-method-listener from input-method-listener-l and |
900 * Removes the old input-method-listener from input-method-listener-l and |
847 * returns the resulting multicast listener. |
901 * returns the resulting multicast listener. |
848 * @param l input-method-listener-l |
902 * @param l input-method-listener-l |
849 * @param oldl the input-method-listener being removed |
903 * @param oldl the input-method-listener being removed |
|
904 * @return the resulting listener |
850 */ |
905 */ |
851 public static InputMethodListener remove(InputMethodListener l, InputMethodListener oldl) { |
906 public static InputMethodListener remove(InputMethodListener l, InputMethodListener oldl) { |
852 return (InputMethodListener) removeInternal(l, oldl); |
907 return (InputMethodListener) removeInternal(l, oldl); |
853 } |
908 } |
854 |
909 |
855 /** |
910 /** |
856 * Removes the old hierarchy-listener from hierarchy-listener-l and |
911 * Removes the old hierarchy-listener from hierarchy-listener-l and |
857 * returns the resulting multicast listener. |
912 * returns the resulting multicast listener. |
858 * @param l hierarchy-listener-l |
913 * @param l hierarchy-listener-l |
859 * @param oldl the hierarchy-listener being removed |
914 * @param oldl the hierarchy-listener being removed |
|
915 * @return the resulting listener |
860 * @since 1.3 |
916 * @since 1.3 |
861 */ |
917 */ |
862 @SuppressWarnings("overloads") |
918 @SuppressWarnings("overloads") |
863 public static HierarchyListener remove(HierarchyListener l, HierarchyListener oldl) { |
919 public static HierarchyListener remove(HierarchyListener l, HierarchyListener oldl) { |
864 return (HierarchyListener) removeInternal(l, oldl); |
920 return (HierarchyListener) removeInternal(l, oldl); |