Commit e251b4e5 by pye52

无意义的优化~

parent 448007e8
...@@ -58,7 +58,6 @@ import com.google.gson.Gson; ...@@ -58,7 +58,6 @@ import com.google.gson.Gson;
import java.net.URI; import java.net.URI;
import java.net.URISyntaxException; import java.net.URISyntaxException;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale; import java.util.Locale;
import static android.os.Process.myPid; import static android.os.Process.myPid;
...@@ -148,7 +147,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe ...@@ -148,7 +147,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe
case PayOnlineState.SEND: case PayOnlineState.SEND:
message.setTextColor(getResources().getColor(R.color.pay_idle)); message.setTextColor(getResources().getColor(R.color.pay_idle));
message.setText(R.string.pay_wait); message.setText(R.string.pay_wait);
String time = payDateFormat.format(new Date()); String time = payDateFormat.format(System.currentTimeMillis());
String log = "支付进度: " + time + " - " + event.getMessage(); String log = "支付进度: " + time + " - " + event.getMessage();
LogUtils.file(TAG, log); LogUtils.file(TAG, log);
...@@ -381,7 +380,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe ...@@ -381,7 +380,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe
TTSHelper.speak(successMessage); TTSHelper.speak(successMessage);
qrCodeViewModel.scan(); qrCodeViewModel.scan();
String successTime = payDateFormat.format(new Date()); String successTime = payDateFormat.format(System.currentTimeMillis());
String successLog = "支付成功: " + successTime + " - " + successMessage; String successLog = "支付成功: " + successTime + " - " + successMessage;
LogUtils.file(TAG, successLog); LogUtils.file(TAG, successLog);
...@@ -399,7 +398,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe ...@@ -399,7 +398,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe
TTSHelper.speak(failedMessage); TTSHelper.speak(failedMessage);
qrCodeViewModel.scan(); qrCodeViewModel.scan();
String failedTime = payDateFormat.format(new Date()); String failedTime = payDateFormat.format(System.currentTimeMillis());
String failedLog = "支付失败: " + failedTime + " - " + failedMessage; String failedLog = "支付失败: " + failedTime + " - " + failedMessage;
LogUtils.file(TAG, failedLog); LogUtils.file(TAG, failedLog);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment