Program: 54674
Project: 54674
Buggy source:
@SuppressWarnings("String_Node_Str") private void openPopup(final MenuItem item){
  popup=new DecoratedPopupPanel(true,false,"String_Node_Str"){
{
      setWidget(item.getSubMenu());
      setPreviewingAllNativeEvents(true);
      item.getSubMenu().onShow();
    }
    @Override protected void onPreviewNativeEvent(    NativePreviewEvent event){
      if (!event.isCanceled()) {
        Event nativeEvent=event.getNativeEvent();
switch (nativeEvent.getTypeInt()) {
case Event.ONMOUSEDOWN:
          com.google.gwt.dom.client.Element target=nativeEvent.getTarget();
        Element parentMenuElement=item.getParentMenu().getElement();
      if (parentMenuElement.isOrHasChild(target)) {
        event.cancel();
        return;
      }
    super.onPreviewNativeEvent(event);
  if (event.isCanceled()) {
    selectItem(null);
  }
return;
}
}
super.onPreviewNativeEvent(event);
}
}
;
popup.setAnimationType(AnimationType.ONE_WAY_CORNER);
popup.setAnimationEnabled(isAnimationEnabled);
popup.setStyleName(STYLENAME_DEFAULT + "String_Node_Str");
String primaryStyleName=getStylePrimaryName();
if (!STYLENAME_DEFAULT.equals(primaryStyleName)) {
popup.addStyleName(primaryStyleName + "String_Node_Str");
}
popup.addPopupListener(this);
shownChildMenu=item.getSubMenu();
item.getSubMenu().parentMenu=this;
popup.setPopupPositionAndShow(new PopupPanel.PositionCallback(){
public void setPosition(int offsetWidth,int offsetHeight){
if (LocaleInfo.getCurrentLocale().isRTL()) {
if (vertical) {
popup.setPopupPosition(MenuBar.this.getAbsoluteLeft() - offsetWidth + 1,item.getAbsoluteTop());
}
 else {
popup.setPopupPosition(item.getAbsoluteLeft() + item.getOffsetWidth() - offsetWidth,MenuBar.this.getAbsoluteTop() + MenuBar.this.getOffsetHeight() - 1);
}
}
 else {
if (vertical) {
popup.setPopupPosition(MenuBar.this.getAbsoluteLeft() + MenuBar.this.getOffsetWidth() - 1,item.getAbsoluteTop());
}
 else {
popup.setPopupPosition(item.getAbsoluteLeft(),MenuBar.this.getAbsoluteTop() + MenuBar.this.getOffsetHeight() - 1);
}
}
}
}
);
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") private void openPopup(final MenuItem item){
  if (parentMenu != null && parentMenu.popup != null) {
    parentMenu.popup.setPreviewingAllNativeEvents(false);
  }
  popup=new DecoratedPopupPanel(true,false,"String_Node_Str"){
{
      setWidget(item.getSubMenu());
      setPreviewingAllNativeEvents(true);
      item.getSubMenu().onShow();
    }
    @Override protected void onPreviewNativeEvent(    NativePreviewEvent event){
      if (!event.isCanceled()) {
        Event nativeEvent=event.getNativeEvent();
switch (nativeEvent.getTypeInt()) {
case Event.ONMOUSEDOWN:
          com.google.gwt.dom.client.Element target=nativeEvent.getTarget();
        Element parentMenuElement=item.getParentMenu().getElement();
      if (parentMenuElement.isOrHasChild(target)) {
        event.cancel();
        return;
      }
    super.onPreviewNativeEvent(event);
  if (event.isCanceled()) {
    selectItem(null);
  }
return;
}
}
super.onPreviewNativeEvent(event);
}
}
;
popup.setAnimationType(AnimationType.ONE_WAY_CORNER);
popup.setAnimationEnabled(isAnimationEnabled);
popup.setStyleName(STYLENAME_DEFAULT + "String_Node_Str");
String primaryStyleName=getStylePrimaryName();
if (!STYLENAME_DEFAULT.equals(primaryStyleName)) {
popup.addStyleName(primaryStyleName + "String_Node_Str");
}
popup.addPopupListener(this);
shownChildMenu=item.getSubMenu();
item.getSubMenu().parentMenu=this;
popup.setPopupPositionAndShow(new PopupPanel.PositionCallback(){
public void setPosition(int offsetWidth,int offsetHeight){
if (LocaleInfo.getCurrentLocale().isRTL()) {
if (vertical) {
popup.setPopupPosition(MenuBar.this.getAbsoluteLeft() - offsetWidth + 1,item.getAbsoluteTop());
}
 else {
popup.setPopupPosition(item.getAbsoluteLeft() + item.getOffsetWidth() - offsetWidth,MenuBar.this.getAbsoluteTop() + MenuBar.this.getOffsetHeight() - 1);
}
}
 else {
if (vertical) {
popup.setPopupPosition(MenuBar.this.getAbsoluteLeft() + MenuBar.this.getOffsetWidth() - 1,item.getAbsoluteTop());
}
 else {
popup.setPopupPosition(item.getAbsoluteLeft(),MenuBar.this.getAbsoluteTop() + MenuBar.this.getOffsetHeight() - 1);
}
}
}
}
);
}