com.pietschy.command.delegate
Class DefaultRelatedWindowDiscriminator

java.lang.Object
  extended by com.pietschy.command.delegate.DefaultRelatedWindowDiscriminator
All Implemented Interfaces:
RelatedWindowDiscriminator

 class DefaultRelatedWindowDiscriminator
extends java.lang.Object
implements RelatedWindowDiscriminator

Default implementation of RelatedWindowDiscriminator. This implementation simply returns true if the focused window is the mediators window.


Constructor Summary
DefaultRelatedWindowDiscriminator()
           
 
Method Summary
 boolean isRelated(java.awt.Window parent, java.awt.Window focusedWindow)
          Invoked to check if the focused window should be considered for delegates.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultRelatedWindowDiscriminator

DefaultRelatedWindowDiscriminator()
Method Detail

isRelated

public boolean isRelated(java.awt.Window parent,
                         java.awt.Window focusedWindow)
Invoked to check if the focused window should be considered for delegates.

Specified by:
isRelated in interface RelatedWindowDiscriminator
Parameters:
parent - the window assosicated with the mediator.
focusedWindow - the currently focused window.
Returns:
true if the focused window contributes delegates the parent window, false otherwise.


Copyright © 2006 - 2007 Andrew Pietsch