Browse Source

计算器bug

e 6 years ago
parent
commit
f533a00d72

+ 3 - 2
app/src/main/java/com/kuxuan/moneynote/ui/weight/CaculatorLayout.java

284
 
284
 
285
                 }else {
285
                 }else {
286
 
286
 
287
-                    String sumStr = mNumText.getText().toString().trim();
287
+                    String sumStr = shownumtext;
288
                     double sumDouble = Double.parseDouble(sumStr);
288
                     double sumDouble = Double.parseDouble(sumStr);
289
-                    if(sumDouble==0){
289
+                    if(sumDouble<=0){
290
                         return;
290
                         return;
291
                     }
291
                     }
292
+
292
                     sum.complete();
293
                     sum.complete();
293
 
294
 
294
                 }
295
                 }