506 (dm.getRefreshRate() == DisplayMode.REFRESH_RATE_UNKNOWN &&
507 dm.getWidth() == mode.getWidth() &&
508 dm.getHeight() == mode.getHeight() &&
509 dm.getBitDepth() == mode.getBitDepth()))
510 {
511 return mode;
512 }
513 }
514 return null;
515 }
516
517 /*
518 * From the DisplayChangeListener interface.
519 * Called from Win32GraphicsEnvironment when the display settings have
520 * changed.
521 */
522 public void displayChanged() {
523 dynamicColorModel = null;
524 defaultConfig = null;
525 configs = null;
526 // pass on to all top-level windows on this display
527 topLevels.notifyListeners();
528 initScaleFactors();
529 }
530
531 /**
532 * Part of the DisplayChangedListener interface: devices
533 * do not need to react to this event
534 */
535 public void paletteChanged() {
536 }
537
538 /*
539 * Add a DisplayChangeListener to be notified when the display settings
540 * are changed. Typically, only top-level containers need to be added
541 * to Win32GraphicsDevice.
542 */
543 public void addDisplayChangedListener(DisplayChangedListener client) {
544 topLevels.add(client);
545 }
546
547 /*
548 * Remove a DisplayChangeListener from this Win32GraphicsDevice
|
506 (dm.getRefreshRate() == DisplayMode.REFRESH_RATE_UNKNOWN &&
507 dm.getWidth() == mode.getWidth() &&
508 dm.getHeight() == mode.getHeight() &&
509 dm.getBitDepth() == mode.getBitDepth()))
510 {
511 return mode;
512 }
513 }
514 return null;
515 }
516
517 /*
518 * From the DisplayChangeListener interface.
519 * Called from Win32GraphicsEnvironment when the display settings have
520 * changed.
521 */
522 public void displayChanged() {
523 dynamicColorModel = null;
524 defaultConfig = null;
525 configs = null;
526 initScaleFactors();
527 // pass on to all top-level windows on this display
528 topLevels.notifyListeners();
529 }
530
531 /**
532 * Part of the DisplayChangedListener interface: devices
533 * do not need to react to this event
534 */
535 public void paletteChanged() {
536 }
537
538 /*
539 * Add a DisplayChangeListener to be notified when the display settings
540 * are changed. Typically, only top-level containers need to be added
541 * to Win32GraphicsDevice.
542 */
543 public void addDisplayChangedListener(DisplayChangedListener client) {
544 topLevels.add(client);
545 }
546
547 /*
548 * Remove a DisplayChangeListener from this Win32GraphicsDevice
|