예제 #1
0
 /*
  * (non-Javadoc)
  *
  * @see java.lang.Object#equals(java.lang.Object)
  */
 @Override
 public boolean equals(Object obj) {
   if (obj == this) {
     return true;
   }
   if (!(obj instanceof LayoutKey)) {
     return false;
   }
   LayoutKey other = (LayoutKey) obj;
   return (other.availWidth == this.availWidth)
       && (other.availHeight == this.availHeight)
       && (other.defaultOverflowX == this.defaultOverflowX)
       && (other.defaultOverflowY == this.defaultOverflowY)
       && (other.whitespace == this.whitespace)
       && (other.expandWidth == this.expandWidth)
       && (other.expandHeight == this.expandHeight)
       && (other.useDeclaredSize == this.useDeclaredSize)
       && (other.overrideNoWrap == this.overrideNoWrap)
       && Objects.equals(other.font, this.font)
       && Objects.equals(other.floatBoundsSource, this.floatBoundsSource);
 }
 /*
  * (non-Javadoc)
  *
  * @see org.lobobrowser.gui.WindowCallback#setStatus(org.lobobrowser.ua.
  * NavigatorFrame , java.lang.String)
  */
 @Override
 public void setStatus(NavigatorFrame frame, String value) {
   String actualStatus;
   synchronized (this) {
     if (!Objects.equals(this.status, value)) {
       this.status = value;
       actualStatus = value == null ? this.defaultStatus : value;
       final NavigatorWindowEvent event =
           new NavigatorWindowEvent(
               this, NavigatorEventType.STATUS_UPDATED, frame, actualStatus, RequestType.NONE);
       if (SwingUtilities.isEventDispatchThread()) {
         EVENT.fireEvent(event);
       } else {
         SwingUtilities.invokeLater(
             new Runnable() {
               @Override
               public void run() {
                 EVENT.fireEvent(event);
               }
             });
       }
     }
   }
 }