1、支持条形码下方显示Code。

2、优化扫条形码。
3、优化相机预览尺寸遍历策略、从而降低变形的可能性。
This commit is contained in:
jenly1314
2018-09-12 17:07:51 +08:00
parent cdb116200f
commit 06694d28a0
20 changed files with 463 additions and 49 deletions

View File

@@ -167,12 +167,10 @@ public class CaptureActivity extends Activity implements SurfaceHolder.Callback
handler = null;
lastResult = null;
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(this);
if (prefs.getBoolean(Preferences.KEY_DISABLE_AUTO_ORIENTATION, true)) {
setRequestedOrientation(getCurrentOrientation());
if (getResources().getConfiguration().orientation == Configuration.ORIENTATION_PORTRAIT) {
setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
} else {
setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE);
setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE);
}
resetStatusView();