Revision 968 org.gvsig.tools/library/trunk/org.gvsig.tools/org.gvsig.tools.dynform/org.gvsig.tools.dynform.impl/src/main/java/org/gvsig/tools/dynform/impl/DefaultJDynFormSet.java

View differences:

DefaultJDynFormSet.java
589 589
	}
590 590

  
591 591
	public void addActionToPopupMenu(DataType tipo, String name, Action action) {
592
		if(this.form==null){
593
			this.actionsBuffer.add(new ActionStore(tipo, name, action));
594
		}else{
595
			this.form.addActionToPopupMenu(tipo, name, action);
592
		try {
593
			if(this.form==null){
594
				this.actionsBuffer.add(new ActionStore(tipo, name, action));
595
			}else{
596
				this.form.addActionToPopupMenu(tipo, name, action);
597
			}
598
		} catch( Exception ex) {
599
			String s = (tipo==null)? "(null)" : tipo.getName();
600
			logger.warn("Can't add popup menu '"+name+"' to the fields of type '"+s+"' of the form.", ex);
596 601
		}
597 602
	}
598 603

  
599 604
	public void addSeparatorToPopupMenu(DataType tipo) {
600
		if(this.form==null){
601
			this.actionsBuffer.add(new ActionStore(tipo));
602
		}else{
603
			this.form.addSeparatorToPopupMenu(tipo);
605
		try {
606
			if(this.form==null){
607
				this.actionsBuffer.add(new ActionStore(tipo));
608
			}else{
609
				this.form.addSeparatorToPopupMenu(tipo);
610
			}
611
		} catch( Exception ex) {
612
			String s = (tipo==null)? "(null)" : tipo.getName();
613
			logger.warn("Can't add separator to the popup menu to the fields of type '"+s+"' of the form.", ex);
604 614
		}
605
		
615

  
606 616
	}		
607 617
	
608 618

  

Also available in: Unified diff