OSDN Git Service

Fix for invalidated resolutions via upgrade
authorI-Jong Lin <ijonglin@google.com>
Thu, 11 Jun 2015 00:10:30 +0000 (17:10 -0700)
committerI-Jong Lin <ijonglin@google.com>
Thu, 11 Jun 2015 00:10:30 +0000 (17:10 -0700)
commit8d8b329da25456adb5ee45e0450680654114e125
tree2198043b62cfd251bd7b2e8177993d517e414c29
parente2323c537f0ec4966ad58251a14e1437071ae085
Fix for invalidated resolutions via upgrade

Bug: 21758681

There was a upgrade bug where an valid resolution of the
previous version of the Camera App could then be invalidated
the subsequent version of the Camera App.  If there were no
other valid resolutions of the same aspect ratio available
to the app, the current Camera App would choose (0,0) as its
default size and then write this value into the saved settings.

This fix allows the current Camera App to consider other resolutions
not of aspect ratio as a fallback resolution setting.  Also, if
an invalid resolution valid has been saved to the settings, it
also ignores it and then resaves a valid resolution value to the
settings.

Change-Id: I08f19d1ee6491619e92697897b73e4fd33a19a00
src/com/android/camera/settings/ResolutionSetting.java
src/com/android/camera/settings/ResolutionUtil.java