Camera: Add Burst mode

Change-Id: I867e26a359ae11b82637d9d239a49679b7e0eb76
Camera: Add indicator icon for burst mode

* Patchset places burst mode indicator next to auto-scene detect
  if active.

Change-Id: Iba3f89490221b16dcce2531962f84752c00b1eef
Camera2: Dummy strings to prevent aapt warnings [translation]

Change-Id: I34acca6b33c29c640c0f8bebbf741613244aa06c
Camera: Disable Camera Launcher when both Front and Back sensors are not detected

Instead of checking only back sensor, this change checks both Front and Back sensors
at the time of first time boot up and then if no sensors are present, disable all
camera activities/CameraLauncher.

Ported from http://review.evervolv.com/#/c/8926/

Change-Id: Ic9ebd3140caa8df079fe01553d62e96207f2e159
Camera: Powerkey shutter (2/2)

Ported from cm-10.1

Including cm-10.1 camera commit:
aa4ae80a41fbab763891c5ef6d67a9e5b4bb981b Don't mess around with pref local ID for power shutter initialization.

Includes http://review.cyanogenmod.org/56986
PS2: Make Camera2 a privileged app
PS5: Sign with platform certificate instead of making it a privileged app.
PS6: Add write permission to PREVENT_POWER_KEY
PS7: Move PREVENT_POWER_KEY permission to CameraActivity
PS8: Revert to PS5

Signed-off-by: Michael Bestas <mikeioannina@gmail.com>
Change-Id: I0992baa558eefd306d00fbece59cb5c512d9448b
Camera: Cleanup hardware key handling

* Fix power shutter behaviour in camcorder mode
* Disable volume change while in panorama mode, volume buttons should only
handle camera operations while in the camera
* Add camera/power/volume key shutter handling in panorama mode

On devices with a hardware camera key:
* Disable power & volume shutter features
* Volume buttons control the zoom

On devices without a hardware camera key:
* When power shutter is disabled, volume buttons control the shutter (like AOSP)
* When power shutter is enabled, volume buttons control the zoom

Change-Id: I141946d5b6f5aec8b1e9a9f99270d30295596079
Camera: Handle keys only while in app

Thanks to Lars Greiss (SlimRoms)

Change-Id: I63f757d25260fba4683f494f8b4daf178a2b4e13
Camera: fix crash on screen off-on on preview screen

Some Camera HALs don't like stopPreview being called with
setPreviewTexture set to null.

Problem occurs on:
 - Acer A700 (Tegra 3) - always
 - Samsung I9082 (Broadcom) - sometimes

Change-Id: Ifd5375d69ef9851a058d2385bf2ee9c89e85bae0
Merge "Camera2: Dummy strings to prevent aapt warnings [translation]" into cm-11.0
Merge "Camera: Powerkey shutter (2/2)" into cm-11.0
Merge "Camera: Cleanup hardware key handling" into cm-11.0
Merge "Camera: Handle keys only while in app" into cm-11.0
Camera: Fix saturation, contrast, sharpness parameters

* Old-style QCOM HALs use <setting>-max, new style HALs use
  max-<setting> for these parameters.

Change-Id: I3b0dbd04f072cb69d09c44b5b3af1097560205b3
Camera2: RU translation

PS1: Restored strings that are marked as translatable again,
     translated some more error messages.
PS2: Translated Storage configuration option.

Change-Id: I93c897ada51ea60bd5a2f52799709b4269d8287b
Camera2: CA translations

Change to Transifex

Change-Id: I94e5dc1e9943643c8699697c86b97d0b2e844118
Signed-off-by: arnau <arnaullv@gmail.com>
Camera2: actually fix ArrayAdapter on MoreSettingsPopup

Like CAF already discovered googles attempt to handle the
ArrayAdapter listview does not work as expected if the scroll view
is larger then the screen. CAF tried to fix it with this commit on landscape
view

https://github.com/SlimRoms/packages_apps_Camera2/commit/c5b0bfcf2340f02ca65ad3d8c08b5c7d74776ea1

which is only a dirty workaround fix for the actual root cause and only works
on landscape partly and if the complete layout is loaded new completly not.

Whatever to fix it we need to override and set getItemViewType(int)
and getViewTypeCount() to actually allow to handle propper two row
layouts like it is needed in MoreSettingsPopup (either checkbox layout
or menu layout). The actual detection which type of preference
we need is handled in getItemViewType.

Change-Id: I6b48ca83daa5f10a7783dfa29c63e9c0bc562167
Camera2: fix possible NPE on configurationchange

Step to reproduce:
- open camera from lockscreen
- during it opens turn your phone
- result: crash

Due that the camera is in middle of the initialization mParameters
is null at this point. Just check against null to prevend the crash.
The correct resizing happens so or so during the ongoing initialization

Thanks TJKV from xda for the report

Change-Id: I0aab385172d7ff571adf525004305fd3b34d499c
Camera2: add option to prevend autofocus cancel if preview stopped

There are camera HALs which cannot handle the autofocus cancel call if the preview
stopped in startPreview(). Add an option for this HAL's to do not cancel autofocus in this cases.

Change-Id: I0767cc7279405d17afc0b00120cb43e5bb309220
Camera2: tweak volume key zoom and cleanup

- cleanup unused code
- cleanup codestyle
- add more zoom steps for smother zooming
- show zoom circle indicator during zoom

Change-Id: I5214fc2620a0c5167bfdc8e85f7115966c3b8bcf
Camera2: Modify AOSP EL translations

Modify the AOSP image size translations like I did in all previous android
versions, the current greek translation does not sound right and it's not used
in any other products (cameras, etc.) in it's current form.

PS2: Trigger Cid

Change-Id: I675fc72eb11fdb267b01faebeea15f9aced5f4ec