add: discard record

This commit is contained in:
hyb1996
2017-07-11 12:12:54 +08:00
parent 768ac6ea4e
commit 14d2b4923c
4 changed files with 5 additions and 3 deletions

View File

@@ -99,7 +99,7 @@ public class Pref {
}
private static String getString(int id) {
return App.getResString(id);
return App.getApp().getString(id);
}
public static int getMaxTextLengthForCodeCompletion() {

View File

@@ -153,6 +153,7 @@ public class RecordNavigatorContent implements NavigatorContent, Recorder.OnStat
private void setState(int state) {
mStopRecord.setVisibility(state == Recorder.STATE_STOPPED ? View.GONE : View.VISIBLE);
mDiscardRecord.setVisibility(state == Recorder.STATE_STOPPED ? View.GONE : View.VISIBLE);
mStartOrPauseRecordIcon.setImageResource(state == Recorder.STATE_RECORDING ? R.drawable.ic_pause_white_24dp : R.drawable.ic_play_arrow_white_48dp);
//我知道这样写代码会被打 但我懒...
mStartOrPauseRecordText.setText(state == Recorder.STATE_RECORDING ? R.string.text_pause_record :