@Override
 public void executeSelect() {
   if (getListView().getSelectionModel().getSelectedItem().isDefaultProject()) {
     GeoPlatformMessage.alertMessage(
         LayerModuleConstants.INSTANCE.GPProjectSearchPanel_alertDefaultProjectSelectedTitleText(),
         LayerModuleConstants.INSTANCE.GPProjectSearchPanel_alertDefaultProjectSelectedBodyText());
     getListView().getSelectionModel().deselectAll();
   } else if (!MementoModuleInjector.MainInjector.getInstance().getMementoSave().isEmpty()) {
     GeoPlatformMessage.confirmMessage(
         MementoPersistenceConstants.INSTANCE.MementoSaveCacheManager_unsavedOperationsText(),
         MementoPersistenceConstants.INSTANCE
             .MementoSaveCacheManager_unsavedOperationMessageText(),
         new Listener<MessageBoxEvent>() {
           @Override
           public void handleEvent(MessageBoxEvent be) {
             if (Dialog.YES.equals(be.getButtonClicked().getItemId())) {
               PeekCacheEvent peekCacheEvent = new PeekCacheEvent();
               LayerHandlerManager.fireEvent(peekCacheEvent);
             } else {
               GeoPlatformMessage.errorMessage(
                   LayerModuleConstants.INSTANCE
                       .ShareProjectPanel_shareVerifySaveOperationsTitleText(),
                   LayerModuleConstants.INSTANCE
                       .ShareProjectPanel_shareVerifySaveOperationsMessageText());
             }
           }
         });
   } else {
     selector.selectDefaultProject();
   }
 }
  final void manageUpdateGeometryCommandFailure(
      VectorFeature modifiedFeature, VectorFeature oldFeature, Throwable exception) {
    String errorMessage = "Error on WFS Update Geometry request";
    GeoPlatformMessage.errorMessage(
        "WFS Service Error", errorMessage + " - " + exception.getMessage());

    progressBar.hide();
    vector.removeFeature(modifiedFeature);
    vector.addFeature(oldFeature);

    bus.fireEvent(failedEvent);
  }
 private void execute(List<ModelData> modelDataList, String folderName) {
   List<GPLayerBean> layerList = generateLayerList(modelDataList);
   if (layerList.size() > 0) {
     createViewportEvent.setLayerList(generateLayerList(modelDataList));
     createViewportEvent.setViewportName(folderName);
     MapHandlerManager.fireEvent(createViewportEvent);
   } else {
     GeoPlatformMessage.errorMessage(
         LayerModuleConstants.INSTANCE.CreateFolderViewportAction_errorNoLayerTitleText(),
         LayerModuleConstants.INSTANCE.CreateFolderViewportAction_errorNoLayerBodyText());
   }
 }
 public void processRequest() {
   GeoPlatformMessage.confirmMessage(
       LayerModuleConstants.INSTANCE.DeleteRequestManager_confirmDeleteTitleText(),
       LayerModuleConstants.INSTANCE.DeleteRequestManager_confirmDeleteBodyText(),
       new Listener<MessageBoxEvent>() {
         @Override
         public void handleEvent(MessageBoxEvent be) {
           if (Dialog.YES.equals(be.getButtonClicked().getItemId())) {
             for (GPBeanTreeModel model :
                 DeleteRequestManager.this.tree.getSelectionModel().getSelectedItems()) {
               DeleteRequestManager.this.deleteFolder.deleteRequest(model);
             }
           }
         }
       });
 }
  @Override
  protected void showConfirmMessage(final VectorFeature feature, final Vector vector) {
    final VectorFeature selectedFeature = getSelectedFeature();

    GeoPlatformMessage.confirmMessage(
        "Line Feature Status",
        "The Geometry Linear Ring Feature is changed. Do you want " + "to apply the changes?",
        new Listener<MessageBoxEvent>() {

          @Override
          public void handleEvent(MessageBoxEvent be) {
            if (Dialog.YES.equals(be.getButtonClicked().getItemId())) {
              manageUpdatedFeature(feature, selectedFeature);
            } else {
              vector.removeFeature(feature);
              vector.addFeature(selectedFeature);
            }
          }
        });
  }
  @Override
  public void showConfirmMessage(final VectorFeature feature, final Vector vector) {

    final VectorFeature selectedFeature = getSelectedFeaure();

    GeoPlatformMessage.confirmMessage(
        "Polygon Feature Status",
        "The Geometry Polygon Feature is changed. Do you want to apply the changes?",
        new Listener<MessageBoxEvent>() {

          @Override
          public void handleEvent(MessageBoxEvent be) {
            if (Dialog.YES.equals(be.getButtonClicked().getItemId())) {
              Dispatcher.forwardEvent(MapWidgetEvents.UPDATE_POLYGON_GEOMETRY, feature);
            } else {
              vector.removeFeature(feature);
              vector.addFeature(selectedFeature);
            }
          }
        });
  }
 @Override
 public void displayErrorMessage() {
   GeoPlatformMessage.alertMessage(
       GeocodingModuleConstants.INSTANCE.ReverseGeoCoderGoogleWidget_infoMessageTitleText(),
       GeocodingModuleConstants.INSTANCE.ReverseGeoCoderGoogleWidget_errorBodyText());
 }
 @Override
 public void unregisterChild() {
   GeoPlatformMessage.infoMessage(
       GeocodingModuleConstants.INSTANCE.ReverseGeoCoderGoogleWidget_infoMessageTitleText(),
       GeocodingModuleConstants.INSTANCE.ReverseGeoCoderGoogleWidget_unregisterChildBodyText());
 }
 /** Confirm Expand Operation on the Folder Element. */
 private void confirmExpandingMessage() {
   GeoPlatformMessage.confirmMessage(
       LayerModuleConstants.INSTANCE.CreateFolderViewportAction_confirmExpandTitleText(),
       LayerModuleConstants.INSTANCE.CreateFolderViewportAction_confirmExpandBodyText(),
       this.message);
 }