|
@@ -41,7 +41,7 @@ public class SelectPlayPop {
|
|
|
View view = LayoutInflater.from(ct).inflate(R.layout.pop_play_select, null);
|
|
View view = LayoutInflater.from(ct).inflate(R.layout.pop_play_select, null);
|
|
|
window.setContentView(view);
|
|
window.setContentView(view);
|
|
|
window.getContentView().measure(0, 0);
|
|
window.getContentView().measure(0, 0);
|
|
|
- int height = DisplayUtil.dip2px(ct, 270);
|
|
|
|
|
|
|
+ int height = DisplayUtil.dip2px(ct, 290);
|
|
|
window.setHeight(height);
|
|
window.setHeight(height);
|
|
|
window.setWidth(DisplayUtil.getSreechWidth(ct));
|
|
window.setWidth(DisplayUtil.getSreechWidth(ct));
|
|
|
initView(ct, window, view, model, onSureListener);
|
|
initView(ct, window, view, model, onSureListener);
|
|
@@ -79,10 +79,13 @@ public class SelectPlayPop {
|
|
|
String payStr = editable.toString();
|
|
String payStr = editable.toString();
|
|
|
double num = Double.valueOf(payStr);
|
|
double num = Double.valueOf(payStr);
|
|
|
payNumTv.setText(StringUtil.getMessage(R.string.new_select_pay) + " " + num);
|
|
payNumTv.setText(StringUtil.getMessage(R.string.new_select_pay) + " " + num);
|
|
|
- int position = payStr.length() - payStr.indexOf(".") - 1;
|
|
|
|
|
- LogUtil.i("position=" + position);
|
|
|
|
|
- if (position > 2) {
|
|
|
|
|
- payNumTv.setText(R.string.input_two_double);
|
|
|
|
|
|
|
+ int dd = payStr.indexOf(".");
|
|
|
|
|
+ int ll = payStr.length();
|
|
|
|
|
+ if (dd != -1) {
|
|
|
|
|
+ int position = ll - dd - 1;
|
|
|
|
|
+ if (position > 2) {
|
|
|
|
|
+ payNumTv.setText(R.string.input_two_double);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
|
|
|
|