When the AudioTrack callback notification size is relatively high (Which is the case on Sholes and over A2DP), it is likely that the end of tone is reached during the first callback. In this case, the AudioTrack is stopped before exiting the callback which causes 2 problems:
- 1: If the AudioFlinger thread is scheduled before we exit the ToneGenerator callback, the track can be stopped and reset before the data is actually marked as present in the buffer by the AudioTrack callback => no audio will be processed by AudioFlinger.
- 2: In this case, the data write index in the AudioTrack buffer is incremented after the track was reset by the AudioFlinger which leaves unplayed data in the buffer. This data will be played the next time the AudioTrack is started if not flushed in between.
The fix consists in adding an intermediate state to ToneGenerator state machine so that we exit the callback function when the stop condition is reached and stop the AudioTrack the next time we execute the callback.
* changes:
Fix bug 2129190 The context used by the status bar (i.e., the system context) was not properly initialized to have the right ApplicationInfo inside its PackageInfo. This eventually caused it to believe that it was running at 160dpi.
The context used by the status bar (i.e., the system context) was
not properly initialized to have the right ApplicationInfo inside
its PackageInfo. This eventually caused it to believe that it
was running at 160dpi.
Kudos to Dianne for figuring this out.
Merge commit '80d8ace484525f0272b8a56142ef838f5f4d38e4' into eclair-plus-aosp
* commit '80d8ace484525f0272b8a56142ef838f5f4d38e4':
Fix issue 2128896 The thumbnail generated after picture capture with max zoom is overlapped with previous thumbnail.
Merge commit 'dc884053ed0087c2d71038f4e3d35c12d7ec8348' into eclair-plus-aosp
* commit 'dc884053ed0087c2d71038f4e3d35c12d7ec8348':
New localization document and tutorial
this adds a parameter to the URL hash on all search queries.
the main motive is to allow searches from the blog to automatically open the blog tab.
Change-Id: Ib81896948e63e8173d521713496bb98065683ce7
Merge commit '20972da079adb6e53fe5f8758aa473d9d46a1b54' into eclair
* commit '20972da079adb6e53fe5f8758aa473d9d46a1b54':
New localization document and tutorial
* We now check for in-progress backups when asked to perform one, and don't
bother firing off another one concurrently (nor do we adjust the scheduling;
after all, someone asked to do a backup "now" and we're doing one, so we are
in line with expectations). We also defer backup passes while a restore is
in flight, and abort attempts to perform a restore during a backup pass.
* When a backup attempt fails, we now ask the transport how far in the future we
should put our retry. Previously we were simply not bothering to consult with
the transport, so we would wind up retrying backup while network connectivity
was known to be down, etc.
Change-Id: Ic7758010b74e06e90c50d46b7b0dd01b17af7c90
Merge commit '1a42cfac152faa98c2e3d9e9fd6889209de195fe' into eclair-plus-aosp
* commit '1a42cfac152faa98c2e3d9e9fd6889209de195fe':
Use LM_SECURE when auth && encrypt.
Merge commit '18b1e79a123b979d25bfa5d0b0ee5d0382dbd64b' into eclair-plus-aosp
* commit '18b1e79a123b979d25bfa5d0b0ee5d0382dbd64b':
Bluetooth API: Do not allow apps to programmatically make BT discoverable.
Instead add ACTION_REQUEST_DISCOVERABLE for the system to show a dialog to
adjust discoverable mode.
Also remove createBond(), removeBond() and cancelBondProcess(). The Settings
App already handles these automatically when connections require bonding.
Change-Id: I216154cd1b6de410de64ba91b07d7263ac03e8df
Merge commit 'cc89ef3d6e9b1f9be657c9158ad04b8de104434c' into eclair-plus-aosp
* commit 'cc89ef3d6e9b1f9be657c9158ad04b8de104434c':
Implement pause/resume for the RS thread.
Merge commit '0665ae22aa51183d6ff5fdd0abeee0344306e89d' into eclair-plus-aosp
* commit '0665ae22aa51183d6ff5fdd0abeee0344306e89d':
Fix 2101425: Camera crashes spontaneously in preview.
Merge commit '0808c961264cd4a9961ac4cb167208d7b1d14dbb' into eclair-plus-aosp
* commit '0808c961264cd4a9961ac4cb167208d7b1d14dbb':
Update layouts to show status (battery, alarm) info on pattern unlock screen. make buttons dark.
Merge commit '7d0bdfaf9adbdaee0b8979d3d23b5b7ecb8a90a9' into eclair-plus-aosp
* commit '7d0bdfaf9adbdaee0b8979d3d23b5b7ecb8a90a9':
Suppress the testPing as we moved the release test target to the userdebug. This test rely on a mock_media_player.so which build under the eng build
* changes:
Suppress the testPing as we moved the release test target to the userdebug. This test rely on a mock_media_player.so which build under the eng build
Merge commit '4579ed287a0f6fc32fbfefdd5c7cf69491fdae99' into eclair-plus-aosp
* commit '4579ed287a0f6fc32fbfefdd5c7cf69491fdae99':
Add "TYPE=" to type attribute when appropriate.
Merge commit 'd35db5ec8bd5ef07840fa84318284df04a69411c' into eclair-plus-aosp
* commit 'd35db5ec8bd5ef07840fa84318284df04a69411c':
Fix bug#2144742: guard against 0 length encoded string when attaching a 'from' address for MMS.
Merge commit '0d3999f788eb01baa8ba671878387761cbbbf861' into eclair-plus-aosp
* commit '0d3999f788eb01baa8ba671878387761cbbbf861':
Minor cleanup of profile and compile logging.