home *** CD-ROM | disk | FTP | other *** search
- package javax.swing.plaf.basic;
-
- import java.beans.PropertyChangeEvent;
- import java.beans.PropertyChangeListener;
- import javax.swing.ListModel;
- import javax.swing.ListSelectionModel;
-
- public class BasicListUI$PropertyChangeHandler implements PropertyChangeListener {
- // $FF: synthetic field
- private final BasicListUI this$0;
-
- public BasicListUI$PropertyChangeHandler(BasicListUI var1) {
- this.this$0 = var1;
- }
-
- public void propertyChange(PropertyChangeEvent var1) {
- String var2 = var1.getPropertyName();
- if (var2.equals("model")) {
- ListModel var3 = (ListModel)var1.getOldValue();
- ListModel var4 = (ListModel)var1.getNewValue();
- if (var3 != null) {
- var3.removeListDataListener(this.this$0.listDataListener);
- }
-
- if (var4 != null) {
- var4.addListDataListener(this.this$0.listDataListener);
- }
-
- BasicListUI var10000 = this.this$0;
- var10000.updateLayoutStateNeeded |= 1;
- BasicListUI.access$0(this.this$0);
- } else if (var2.equals("selectionModel")) {
- ListSelectionModel var5 = (ListSelectionModel)var1.getOldValue();
- ListSelectionModel var6 = (ListSelectionModel)var1.getNewValue();
- if (var5 != null) {
- var5.removeListSelectionListener(this.this$0.listSelectionListener);
- }
-
- if (var6 != null) {
- var6.addListSelectionListener(this.this$0.listSelectionListener);
- }
-
- BasicListUI var7 = this.this$0;
- var7.updateLayoutStateNeeded |= 1;
- BasicListUI.access$0(this.this$0);
- } else if (var2.equals("cellRenderer")) {
- BasicListUI var8 = this.this$0;
- var8.updateLayoutStateNeeded |= 64;
- BasicListUI.access$0(this.this$0);
- } else if (var2.equals("font")) {
- BasicListUI var9 = this.this$0;
- var9.updateLayoutStateNeeded |= 4;
- BasicListUI.access$0(this.this$0);
- } else if (var2.equals("prototypeCellValue")) {
- BasicListUI var10 = this.this$0;
- var10.updateLayoutStateNeeded |= 32;
- BasicListUI.access$0(this.this$0);
- } else if (var2.equals("fixedCellHeight")) {
- BasicListUI var11 = this.this$0;
- var11.updateLayoutStateNeeded |= 16;
- BasicListUI.access$0(this.this$0);
- } else if (var2.equals("fixedCellWidth")) {
- BasicListUI var12 = this.this$0;
- var12.updateLayoutStateNeeded |= 8;
- BasicListUI.access$0(this.this$0);
- } else if (var2.equals("cellRenderer")) {
- BasicListUI var13 = this.this$0;
- var13.updateLayoutStateNeeded |= 64;
- BasicListUI.access$0(this.this$0);
- } else if (var2.equals("selectionForeground")) {
- this.this$0.list.repaint();
- } else if (var2.equals("selectionBackground")) {
- this.this$0.list.repaint();
- }
-
- }
- }
-