Corretti cast funzionali
git-svn-id: svn://10.65.10.50/trunk@387 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
		
							parent
							
								
									3617cccc6a
								
							
						
					
					
						commit
						8a2c77f75c
					
				| @ -373,7 +373,7 @@ word Pagamento::recalc_rate(int row, bool is_perc_modified, | |||||||
|   if (new_value != NULL) |   if (new_value != NULL) | ||||||
|     {      |     {      | ||||||
|       newv = new_value;                        |       newv = new_value;                        | ||||||
|       rmax = is_perc_modified? real(100.0) : (_tpr == 0 ? _firstr : _secndr); |       rmax = is_perc_modified? (real) 100.0 : (_tpr == 0 ? _firstr : _secndr); | ||||||
|       if (newv > rmax) return P_RSUM; |       if (newv > rmax) return P_RSUM; | ||||||
|     }                                                    |     }                                                    | ||||||
|    |    | ||||||
| @ -479,8 +479,8 @@ word Pagamento::recalc_rate(int row, bool is_perc_modified, | |||||||
| 			  for(int j = row+1; j < srate.items(); j++) | 			  for(int j = row+1; j < srate.items(); j++) | ||||||
| 			    _rate.add(NULL,j);  | 			    _rate.add(NULL,j);  | ||||||
| 			   | 			   | ||||||
| 			  TToken_string& trt = add_rata(is_perc_modified? remainder : real(0.0),  | 			  TToken_string& trt = add_rata(is_perc_modified ? remainder : (real) 0.0, | ||||||
| 							oldscad, oldtype); | 																			oldscad, oldtype); | ||||||
| 			  if (!is_perc_modified) trt.add(remainder.string(),4); | 			  if (!is_perc_modified) trt.add(remainder.string(),4); | ||||||
| 			  if (_inited) | 			  if (_inited) | ||||||
| 			    {  | 			    {  | ||||||
| @ -619,7 +619,10 @@ word Pagamento::recalc_rate(int row, bool is_perc_modified, | |||||||
| 		if (rdiff == 2) rdiff = 1; | 		if (rdiff == 2) rdiff = 1; | ||||||
| 		_rdiff = FALSE; | 		_rdiff = FALSE; | ||||||
| 	      } | 	      } | ||||||
| 	    rsum    += is_perc_modified ? perc_rata(i) : tpay_rata(i);   | 				if (is_perc_modified) | ||||||
|  | 					rsum    += perc_rata(i); | ||||||
|  | 				else | ||||||
|  | 					rsum    += tpay_rata(i);   | ||||||
| 	     | 	     | ||||||
| 	    lastdate = data_rata(i); | 	    lastdate = data_rata(i); | ||||||
| 	    oldtype  = tipo_rata(i); | 	    oldtype  = tipo_rata(i); | ||||||
| @ -691,7 +694,7 @@ bool Pagamento::read(TTable* t, TTable* r) | |||||||
|       tt->add((const char*)d);   |       tt->add((const char*)d);   | ||||||
|       tt->add("");                          |       tt->add("");                          | ||||||
|       tt->add(r->get("S1")); |       tt->add(r->get("S1")); | ||||||
|       _slicer.add(real(r->get("R0"))); |       _slicer.add((real)r->get("R0")); | ||||||
|       _rate.add(tt); |       _rate.add(tt); | ||||||
|     } |     } | ||||||
|    |    | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user