Simple Delegation program (2)

        // continue constructor
        // create a listener and add it to each Button
        SimpleListener simple = 
                new SimpleListener(label);
        left.addActionListener(simple);
        right.addActionListener(simple);        
    }
}


Slide 40 ©Copyright 1997 Jan Newmarch