RedApparat / Fotoapparat

Making Camera for Android more friendly. 📸
Apache License 2.0
3.82k stars 405 forks source link

Make Size and Range serializable to pass device capabilities in Bundle #133

Closed ezaquarii closed 6 years ago

ezaquarii commented 6 years ago

Passing device capabilities in Bundle extras requires manual transformations, as types do not support neither Serializable nor Parcelable.

Implementing Parcelable is overkill, as those PODs are not used in any performance-critical code.

Make all Capabilities members serializable, so they can be passed into DialogFragment inside extras.

dmitry-zaitsev commented 6 years ago

Looks good, thanks for the effort 👍 Somehow didn't thought about making it Serializable from the beginning