Question: In Java version 1.2, Java components in the new Swing package, such as JButton and JList, utilized the EDM ( known as the Event Delegation


In Java version 1.2, Java components in the new Swing package, such as JButton and JList, utilized the EDM ( known as the Event Delegation Model) to respond to the user clicking a button or selecting an item from a list. Briefly explain the concept of the Event Delegation Model and how user-initiated events are handled by the GUI application. In other words, explain how a "listener" is connected with a GUI component and how its corresponding listener's abstract method works. (2 marks)1. A JRootPane, a JLayeredPane, and contentPane are hungry, so they walk into a bar, sit down at a table, and ask for a JMenuBar. The bartender asks "Is this some kind of joke"? The components assure him that they are hungry and want to order, so he hands the JMenuBar to the proper component. For one mark, which container component did he give the menu to? (1 mark)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
