Close open cursors

Cursors which got created during any query, needs to be closed
finally. Otherwise it'll cause leak in resource and cursor window
allocation will fail.

Change-Id: I65ace2dc227e0a50c163faba13fdb0fbfa71bc6c
CRs-Fixed: 594264
Camera: Enable video stabilization setting

Can be used on most sony devices, might need conversion of the
parameters in the device specific camera wrapper.

Change-Id: I19ecadac8a0598fa6a89bd2f251e0d283c7f9b38

Conflicts:
	res/values/qcomstrings.xml
	src/com/android/camera/VideoMenu.java
Camera2: Do not issue autofocus cancel if preview stopped

942890667aa08cc3c1305d7ba64c1340df1219db introduced the option to not
issue autofocus cancel if the preview was stopped. Extend it to the case
where the preview is stopped because the camera was called as an intent
(ie from MMS client)

Change-Id: I30032d8375665ecf6be471bf480c1f118d25423b

Conflicts:
	src/com/android/camera/PhotoModule.java
camera: Add metadata-based ASD

 * New cameras use the metadata callback to report the
   detected scene mode. Add support for this.
 * The asdModes array must be set for this to work, which
   should contain the ordered list of possible scenes,
   corresponding to the camera_asd_values array.

Change-Id: I07279ae30a4cbedef02bec702252eb7e2abacd4a

Conflicts:
	res/values/cm_arrays.xml
	src/com/android/camera/AndroidCameraManagerImpl.java
	src/com/android/camera/PhotoModule.java
	src/com/android/camera/util/CameraUtil.java
Camera2: Fix burst mode, auto scene detect layout

* Prevent icons from stacking ontop of each other

Change-Id: I4a1c8ae360c7272bfa2833aaf64410a2778a7ff7
Camera: video stabilization setting - don't default enable

This partially reverts:
https://github.com/CyanogenMod/android_packages_apps_Camera2/commit/8dc898aec74fe96b9411872eef8748727166a021

Causing camcorder crash on HLTE and probably other devices.

Much safer for devices wishing this enabled by default to set this
in an overlay.

Change-Id: Iaae388023efe3773ae94f01c4774359a1157b8a2

Conflicts:
	res/values/qcomstrings.xml
camera: Histogram, ZSL burst mode, HDR-on-ZSL

 * Optional features available on newer sensors
 * Histogram needs to be made pretty

Change-Id: Ic46c1dfcc1de32acc22928a4431d3601b03ef513

Conflicts:
	res/values/config.xml
	src/com/android/camera/CameraSettings.java
	src/com/android/camera/PhotoMenu.java
	src/com/android/camera/PhotoModule.java
Fix initialization of new installations

Change I2615666bc1c929c0c045840fad1ece55fb0640af's upgrade scenario
only applied to installations coming specifically from version 5.
Devices with older versions or installing afresh would get invalid
initial data. Fixit

Change-Id: I170d9ef284c250767467695015bf4e57bc1454c2

Conflicts:
	src/com/android/camera/CameraSettings.java
Camera: remove fine/normal/superfine jpegquality and use always int

We use now a set of int values the user can exactly assign. Showing as
well the normal fine superfine as choice is just a duplicate. As well
we can get rid of the weird converts of the mixed values.

To take care that the user does not get into problems we updated the db
version and we make a convertion.

Change-Id: I2615666bc1c929c0c045840fad1ece55fb0640af

Conflicts:
	res/values/slim_arrays.xml
	src/com/android/camera/CameraSettings.java
	src/com/android/camera/PhotoModule.java
Addition to change 60677/3
Camera: Fix removal of histogram setting

Histogram is disabled by default in config.xml, so the code to filter unsupported modes is never executed
Remove histogram option completely when it's disabled in config.xml

Change-Id: Id47da14d7d3d268e70727d25ed8f4d431b80f6f1
Camera: Fix the removal of histogram setting fix

Regroup conditionals to fix the NPE.

Change-Id: If87e5287b75a8f43c1a34f234aa0a8c405f43891
Camera: Fix JPEG quality DB update

Change-Id: I4e43152d8a4a8ed689de086757bcabc17749f9c8

Conflicts:
	src/com/android/camera/CameraSettings.java
Camera2: Add 50MP, 37.5MP resolution entry

* Support for SuperZoom resolutions

Change-Id: I59dc102bc991c8f82b4827c9fa39da44d98cb8e9

Conflicts:
	res/values/cm_strings.xml
Workaround for removed AOSP strings

Commit aed65253fb207b952a29e416a02d5b9a0c492416 from CAF removed 2 AOSP strings.
This results in aapt warnings and TranslationTools thinks these strings are unused,
so we would have to remove them from all languages.

Move them from cm_extra back to original location so we don't have to remove
them from all languages to overcome the above issues

Also partially revert http://review.cyanogenmod.org/61312 to prevent future merge conflicts.

Change-Id: I7aec7699f73fd7cbe3fef053f2744ea3fdef3fa8
Camera: EL translations

Change-Id: I214894d8ee90dd9ede1e8999a73f36c913dd49f2

Conflicts:
	res/values-el/cm_strings.xml
	res/values-el/qcomstrings.xml
Camera2: NL translation

ps1: https://www.dropbox.com/s/wl1j0jb5gnrjyuy/Screenshot_2014-03-17-12-13-34.png
ps2/3: JPEG quality strings
ps5: Add 50MP, 37.5MP resolution entry

Change-Id: Id903977d04769b39f5c6d29846f8197ad09a7deb

Conflicts:
	res/values-nl/cm_strings.xml
Camera2: Remove now unused strings

Change-Id: I65e4384cdcc3778508f4e9a7815431fd17945e7a

Conflicts:
	res/values-de/qcomstrings.xml
Camera: Avoid animating cature with decoded jpeg in long shot

Decoding full jpeg image and animating capture
with that is causing lot of delays which effects
long shot stability.This change avoids that.

CRs-Fixed: 586568

Change-Id: I0133cc55e5efcc801dd9a98c289dec965aa35984

Conflicts:
	src/com/android/camera/PhotoModule.java
Camera: Add support for 4K camcorder

In case 4k is enabled,
 (a) set the preview resoultion same as video resolution.
 (b) set the preview format same as video format.

Change-Id: Iebc4c7d47ddca6e03a72f3af7b4660e93c9a1b8e

Conflicts:
	src/com/android/camera/VideoModule.java