Commit Graph

936 Commits

Author SHA1 Message Date
Kenny Root
0832a31d54 Change unistd.h to stddef.h to be correct
size_t should be defined through inclusion of stddef.h instead of unistd.h

Change-Id: Ieaadacfca1e1c44c2533ea95f73fc060c1519b52
2010-07-28 16:46:12 -07:00
Kenny Root
e8642c0e59 am 47cf709a: am 8c5d9430: Merge "Add unistd.h for size_t typedef to fix sim-eng" into gingerbread
Merge commit '47cf709aa3c07d2573340187edb5e11ea75824b1'

* commit '47cf709aa3c07d2573340187edb5e11ea75824b1':
  Add unistd.h for size_t typedef to fix sim-eng
2010-07-28 16:41:36 -07:00
Kenny Root
28282dc4e6 Merge "Add unistd.h for size_t typedef to fix sim-eng" into gingerbread 2010-07-28 16:37:20 -07:00
Mathias Agopian
bc5aac5d45 am 9362ea76: am 9f2a91bc: Merge "fix [2873058] Surface::dequeueBuffer blocks on last buffer, i.e. cannot dequeue all allocated buffers at once." into gingerbread
Merge commit '9362ea760f565389f5accce7e17476d05510ed59'

* commit '9362ea760f565389f5accce7e17476d05510ed59':
  fix [2873058] Surface::dequeueBuffer blocks on last buffer, i.e. cannot dequeue all allocated buffers at once.
2010-07-28 16:36:08 -07:00
Kenny Root
937cd1b707 Add unistd.h for size_t typedef to fix sim-eng
Change-Id: Ida4f1742547f39539b601f13182c722aa7cf863e
2010-07-28 16:31:24 -07:00
Mathias Agopian
edae28809a Merge "fix [2873058] Surface::dequeueBuffer blocks on last buffer, i.e. cannot dequeue all allocated buffers at once." into gingerbread 2010-07-28 16:30:56 -07:00
Christopher Tate
01d1669b89 am 1de9f490: am bae6fe24: Merge "Support streaming of compressed assets > 1 megabyte" into gingerbread
Merge commit '1de9f490b5c3f293b3748be3d4ccf3f78cdf460b'

* commit '1de9f490b5c3f293b3748be3d4ccf3f78cdf460b':
  Support streaming of compressed assets > 1 megabyte
2010-07-28 15:41:30 -07:00
Christopher Tate
46f28d328a Merge "Support streaming of compressed assets > 1 megabyte" into gingerbread 2010-07-28 15:36:48 -07:00
Christopher Tate
a45a8008c6 Support streaming of compressed assets > 1 megabyte
Compressed assets larger than one megabyte are now decompressed on demand
rather than being decompressed in their entirety and held in memory.  Reading
the data in order is relatively efficient, as is seeking forward in the stream.
Seeking backwards is supported, but requires reprocessing the compressed data
from the beginning, so is very inefficient.

In addition, the size limit on compressed assets has been eliminated.

Change-Id: I6e68247957e6c53e7e8ba70d12764695f1723bad
2010-07-28 15:33:28 -07:00
Jeff Brown
2ef6cdec33 am 9795a25d: am 6d0fec2d: Refactor input reader to support new device types more easily.
Merge commit '9795a25da060f9a7df87da8ab43fb1086d4322a5'

* commit '9795a25da060f9a7df87da8ab43fb1086d4322a5':
  Refactor input reader to support new device types more easily.
2010-07-28 14:27:55 -07:00
Jeff Brown
e57e895080 Refactor input reader to support new device types more easily.
Refactored the input reader so that each raw input protocol is handled
by a separate subclass of the new InputMapper type.  This way, behaviors
pertaining to keyboard, trackballs, touchscreens, switches and other
devices are clearly distinguished for improved maintainability.

Added partial support for describing capabilities of input devices
(incomplete and untested for now, will be fleshed out in later commits).

Simplified EventHub interface somewhat since InputReader is taking over
more of the work.

Cleaned up some of the interactions between InputManager and
WindowManagerService related to reading input state.

Fixed swiping finger from screen edge into display area.

Added logging of device information to 'dumpsys window'.

Change-Id: I17faffc33e3aec3a0f33f0b37e81a70609378612
2010-07-28 14:16:15 -07:00
Mathias Agopian
208cb07724 fix [2873058] Surface::dequeueBuffer blocks on last buffer, i.e. cannot dequeue all allocated buffers at once.
this situation happened when the last buffer needed to be resized
(or allocated, the first time). the assumption was that the buffer
was in use by SF itself as the current buffer (obviously, this
assumption made no sense when the buffer had never been allocated, btw).

the system would wait until some other buffer became the "front" buffer.

we fix this problem by entirely removing the requirement that the
buffer being resized cannot be the front buffer. instead, we just
allocate a new buffer and replace the front buffer by the new one.

the downside is that this uses more memory (an extra buffer) for a
brief amount of time while the old buffer is being reallocated and
before it has actually been replaced.

Change-Id: I022e4621209474ceb1c671b23deb4188eaaa7285
2010-07-27 20:11:35 -07:00
Brad Fitzpatrick
b8f4015c0a am 245cb784: am 84c924a6: Merge "Replace several IPCThreadState::get() lookups with one." into gingerbread
Merge commit '245cb7846c82f7c0840e13f0b994d356846b1678'

* commit '245cb7846c82f7c0840e13f0b994d356846b1678':
  Replace several IPCThreadState::get() lookups with one.
2010-07-27 14:04:14 -07:00
Brad Fitzpatrick
70081a1511 Replace several IPCThreadState::get() lookups with one.
Also, make StrictMode's ThreadLocal final.

Change-Id: I08d400ed254fa67bb7a3dae1227f205a54c00df0
2010-07-27 12:28:57 -07:00
Mathias Agopian
d671e2b957 am 1db0e88e: am 4782cdbb: Merge "Fix a memory corruption when writting Sensor into a parcel" into gingerbread
Merge commit '1db0e88e60ca4f99edff149fe2ab8499e749df47'

* commit '1db0e88e60ca4f99edff149fe2ab8499e749df47':
  Fix a memory corruption when writting Sensor into a parcel
2010-07-22 20:11:54 -07:00
Mathias Agopian
d03d9ced3f Fix a memory corruption when writting Sensor into a parcel
Change-Id: I03f703ae2224f43924031bfea4c68aa979bb9f05
2010-07-22 18:57:41 -07:00
Mathias Agopian
be48137beb move native services under services/
moved surfaceflinger, audioflinger, cameraservice

all native services should now reside in this location.

Change-Id: Icd7336f7289db35df9c8c1857a5122bb8a6f1c86
2010-07-22 15:28:19 -07:00
Mathias Agopian
267e73c675 am 1f2ec407: am 23e8de26: propagate sensor event rate properly
Merge commit '1f2ec4070aa9c999d41dc50a892a896e894c5710'

* commit '1f2ec4070aa9c999d41dc50a892a896e894c5710':
  propagate sensor event rate properly
2010-07-21 18:13:39 -07:00
Mathias Agopian
a7a3160daa resolved conflicts for merge of bc54e63c to master
Change-Id: I4245b15b4cda6963d735442c0c6a04a0477ff5e1
2010-07-21 18:10:22 -07:00
Mathias Agopian
e3c8234765 propagate sensor event rate properly
Change-Id: I32e67d30e4295285a6827956cc8161b2025d70bc
2010-07-21 16:09:39 -07:00
Mathias Agopian
a7352c9f4a new SensorService
remove old sensor service and implement SensorManager
on top of the new (native) SensorManger API.

Change-Id: Iddb77d498755da3e11646473a44d651f12f40281
2010-07-19 17:57:29 -07:00
Jamie Gennis
a9c979ad8f am 98f8e0cb: am ff7049ab: Remove some debug logging that I accidentally committed.
Merge commit '98f8e0cbaa19b4a045e6f201290e731ddfad67ba'

* commit '98f8e0cbaa19b4a045e6f201290e731ddfad67ba':
  Remove some debug logging that I accidentally committed.
2010-07-19 16:35:26 -07:00
Jamie Gennis
ac07cd613f Remove some debug logging that I accidentally committed.
Change-Id: Ib182455fad5e5b3f3f59b3ff24f59dcd7f638292
2010-07-19 16:09:26 -07:00
Jeff Brown
7853b8bed7 am 3994396b: am d3616592: Fix trackball down and movement bugs.
Merge commit '3994396b089c36f432a7af5d542ef594142dd09b'

* commit '3994396b089c36f432a7af5d542ef594142dd09b':
  Fix trackball down and movement bugs.
2010-07-16 17:56:15 -07:00
Jeff Brown
f26db0d6c5 Fix trackball down and movement bugs.
Bug: 2823788
Change-Id: Icb0c392b58f7e735614460b5eb87439cb73ac4f2
2010-07-16 17:46:03 -07:00
Jamie Gennis
3154334630 am 04b95313: am c8c79a65: Merge "Re-use existing Surface objects when reading them from parcels." into gingerbread
Merge commit '04b953132edb5482f0aa6d992f89e7016961528c'

* commit '04b953132edb5482f0aa6d992f89e7016961528c':
  Re-use existing Surface objects when reading them from parcels.
2010-07-16 16:25:23 -07:00
Jeff Brown
e085084dc5 am 7b8df313: am 00ba8844: Fix individual pointer id up/down reporting.
Merge commit '7b8df313f714d6e8d536e0f8bbe5496fe9a6c26d'

* commit '7b8df313f714d6e8d536e0f8bbe5496fe9a6c26d':
  Fix individual pointer id up/down reporting.
2010-07-16 16:25:13 -07:00
Jamie Gennis
874da6e438 Merge "Re-use existing Surface objects when reading them from parcels." into gingerbread 2010-07-16 15:14:44 -07:00
Jeff Brown
3cf1c9b844 Fix individual pointer id up/down reporting.
Fix a minor threading bug in InputManager dump.

Change-Id: Ic2eecf7df5a8dc9f40561fcb03ebe58a2c073778
2010-07-16 15:11:24 -07:00
Jamie Gennis
aca4e22879 Re-use existing Surface objects when reading them from parcels.
This change adds a process-global cache of previously deserialized Surface
objects so that if a Surface object wrapping the same ISurface gets received
again the same Surface can be used.  This is important because the 'tail'
pointer in the SharedBufferClient is stored only on the client side, and needs
to be the same for all the Surface objects wrapping an ISurface instance.  This
solves the problem by making there only be one Surface object wrapping an
ISurface per process.

Change-Id: I4bf0b8787885c56277622fca053022d2bb638902
2010-07-16 13:03:15 -07:00
Jeff Brown
cfa6d98278 resolved conflicts for merge of f7adbe10 to master
Change-Id: I898a5e53b180adaee2337c0c0b9896c799d056e7
2010-07-16 10:06:33 -07:00
Dianne Hackborn
a2c4654c2f am 9c37e5ad: am 75a91389: Merge "Implement native key pre-dispatching to IMEs." into gingerbread
Merge commit '9c37e5add9d7678a29b4e0d1e178fe78a13db961'

* commit '9c37e5add9d7678a29b4e0d1e178fe78a13db961':
  Implement native key pre-dispatching to IMEs.
2010-07-16 09:12:29 -07:00
Jeff Brown
0a128e3cbe Fix bug with phantom input windows.
Add dumpsys integration for the native input dispatcher.
Add some InputDevice API stubs.
Add an appendFormat helper method to String8 for printf style
string formatting mainly for debugging purposes.
Use generic ArrayList<WindowState> everywhere in WindowManagerService
to eliminate unnecessary casts all over.

Change-Id: I9d1e3bd90eb7222d10620200477f11b7bfd25e44
2010-07-16 00:02:48 -07:00
Jeff Brown
1a15c6eaff resolved conflicts for merge of aca672ba to master
Change-Id: I7ae11fca0acdbf513a4870226d0d3e3cafbe9a08
2010-07-15 23:47:29 -07:00
Brad Fitzpatrick
e9f1a6478f am 3e5e21d4: am 1772c34e: Merge "StrictMode: gather and return violating stacks in Binder replies" into gingerbread
Merge commit '3e5e21d4dc74751e64d17379c5563ece39a7e35d'

* commit '3e5e21d4dc74751e64d17379c5563ece39a7e35d':
  StrictMode: gather and return violating stacks in Binder replies
2010-07-15 23:05:39 -07:00
Brad Fitzpatrick
721c4162c3 am cc52121c: am c4b204bd: Merge "More StrictMode work, keeping Binder & BlockGuard\'s thread-locals in-sync." into gingerbread
Merge commit 'cc52121c4f88e9feb8404937bcbfff6e73084666'

* commit 'cc52121c4f88e9feb8404937bcbfff6e73084666':
  More StrictMode work, keeping Binder & BlockGuard's thread-locals in-sync.
2010-07-15 23:05:35 -07:00
Dianne Hackborn
0e8852766d Implement native key pre-dispatching to IMEs.
This significantly re-works the native key dispatching code to
allow events to be pre-dispatched to the current IME before
being processed by native code.  It introduces one new public
API, which must be called after retrieving an event if the app
wishes for it to be pre-dispatched.

Currently the native code will only do pre-dispatching of
system keys, to avoid significant overhead for gaming input.
This should be improved to be smarted, filtering for only
keys that the IME is interested in.  Unfortunately IMEs don't
currently provide this information. :p

Change-Id: Ic1c7aeec8b348164957f2cd88119eb5bd85c2a9f
2010-07-15 22:05:33 -07:00
Jeff Brown
5c1ed84a2d Add support for new input sources.
Added several new coordinate values to MotionEvents to capture
touch major/minor area, tool major/minor area and orientation.

Renamed NDK input constants per convention.

Added InputDevice class in Java which will eventually provide
useful information about available input devices.

Added APIs for manufacturing new MotionEvent objects with multiple
pointers and all necessary coordinate data.

Fixed a bug in the input dispatcher where it could get stuck with
a pointer down forever.

Fixed a bug in the WindowManager where the input window list could
end up containing stale removed windows.

Fixed a bug in the WindowManager where the input channel was being
removed only after the final animation transition had taken place
which caused spurious WINDOW DIED log messages to be printed.

Change-Id: Ie55084da319b20aad29b28a0499b8dd98bb5da68
2010-07-15 18:32:33 -07:00
Brad Fitzpatrick
d36f4a5f13 StrictMode: gather and return violating stacks in Binder replies
Now, when Thread A has a strict mode policy in effect and does a
Binder call to Thread B (most likely in another process), the strict
mode policy is passed along, but with the GATHER penalty bit set which
overrides other policies and instead gathers all offending stack
traces to a threadlocal which are then written back in the Parcel's
reply header.

Change-Id: I7d4497032a0609b37b1a2a15855f5c929ba0584d
2010-07-15 13:18:05 -07:00
Brad Fitzpatrick
a877cd85b5 More StrictMode work, keeping Binder & BlockGuard's thread-locals in-sync.
Change-Id: Ia67cabcc17a73a0f15907ffea683d06bc41b90e5
2010-07-15 13:18:05 -07:00
Jeff Brown
a903001e3c am d1313da5: am eb6e0df1: Don\'t build framework tests for simulator target.
Merge commit 'd1313da5999e06be16e52527cfba443f66b333a1'

* commit 'd1313da5999e06be16e52527cfba443f66b333a1':
  Don't build framework tests for simulator target.
2010-07-15 10:24:10 -07:00
Jeff Brown
a50ee3ecb3 Don't build framework tests for simulator target.
Change-Id: I70f29c7eb307e4f3ec5702f4eb9d97b4342e2f36
2010-07-14 22:55:02 -07:00
Mathias Agopian
0204112e94 am 78983a91: am 4055b780: Merge "move native services under services/" into gingerbread
Merge commit '78983a9133d3dd3f08b1ec462a7e2f9e7bfa9e2f'

* commit '78983a9133d3dd3f08b1ec462a7e2f9e7bfa9e2f':
  move native services under services/
2010-07-14 18:48:58 -07:00
Mathias Agopian
81bac09fa6 move native services under services/
moved surfaceflinger, audioflinger, cameraservice

all native services should now reside in this location.

Change-Id: Iee42b83dd2a94c3bf5107ab0895fe2dfcd5337a8
2010-07-14 17:59:35 -07:00
Mathias Agopian
d10f9fbc39 am db386f2c: am c9a11088: Merge "first step at implementing the native sensor support" into gingerbread
Merge commit 'db386f2c263c6e9e4b825d4c9a320849f8f2c916'

* commit 'db386f2c263c6e9e4b825d4c9a320849f8f2c916':
  first step at implementing the native sensor support
2010-07-14 16:39:55 -07:00
Mathias Agopian
58736b5a19 am 98704f14: am 38eea8bf: Merge "Remove the YV16 format for simplicity\'s sake." into gingerbread
Merge commit '98704f14eaeef6c9bcb73fea162f4941dd9bbd87'

* commit '98704f14eaeef6c9bcb73fea162f4941dd9bbd87':
  Remove the YV16 format for simplicity's sake.
2010-07-14 16:39:42 -07:00
Mathias Agopian
e1ea0811de Merge "first step at implementing the native sensor support" into gingerbread 2010-07-14 16:32:04 -07:00
Mathias Agopian
48c3476371 Remove the YV16 format for simplicity's sake.
Change-Id: Iee03d100933ba0c67b13d51e0435be3b4cd953cf
2010-07-14 15:12:05 -07:00
Mathias Agopian
589ce85ee4 first step at implementing the native sensor support
in this commit:
- implemented the C stub
- implemented the binder interfaces involved
- implemented most of the C++ client side

missing:
- SensorManager cannot connect to the SensorServer yet
(because there is no SensorServer yet)

Change-Id: I75010cbeef31c98d6fa62fd5d388dcef87c2636b
2010-07-13 22:21:56 -07:00
Dianne Hackborn
66d3d8e488 am f8d9379b: am d76b67c3: IME events are now dispatched to native applications.
Merge commit 'f8d9379bd834573feca085284970cf686993c330'

* commit 'f8d9379bd834573feca085284970cf686993c330':
  IME events are now dispatched to native applications.
2010-07-13 19:50:36 -07:00
Dianne Hackborn
ce838a265d IME events are now dispatched to native applications.
And also:

- APIs to show and hide the IME, and control its interaction with the app.
- APIs to tell the app when its window resizes and needs to be redrawn.
- API to tell the app the content rectangle of its window (to layout
  around the IME or status bar).

There is still a problem with IME interaction -- we need a way for the
app to deliver events to the IME before it handles them, so that for
example the back key will close the IME instead of finishing the app.

Change-Id: I37b75fc2ec533750ef36ca3aedd2f0cc0b5813cd
2010-07-13 18:36:46 -07:00
Jeff Brown
94eed383c9 am 89ee578b: am fd035829: Add initial gamepad support.
Merge commit '89ee578b7053d27a50922f82feb94bf6054b330c'

* commit '89ee578b7053d27a50922f82feb94bf6054b330c':
  Add initial gamepad support.
2010-07-13 17:48:56 -07:00
Jeff Brown
8575a87b0d Add initial gamepad support.
Change-Id: I0439648f6eb5405f200e4223c915eb3a418b32b9
2010-07-13 17:04:57 -07:00
Brad Fitzpatrick
0c2aaca5d6 am 706623dd: am c0a7e690: Add Parcel::readExceptionCode() and Parcel::writeNoException()
Merge commit '706623ddb8314850c0551f0b66e24b5f0bd28620'

* commit '706623ddb8314850c0551f0b66e24b5f0bd28620':
  Add Parcel::readExceptionCode() and Parcel::writeNoException()
2010-07-13 15:57:20 -07:00
Brad Fitzpatrick
837a0d0fb2 Add Parcel::readExceptionCode() and Parcel::writeNoException()
Add native Parcel methods analogous to the Java versions.

Currently, these don't do much, but upcoming StrictMode work changes
the RPC calling conventions in some cases, so it's important that
everybody uses these consistently, rather than having a lot of code
trying to parse RPC responses out of Parcels themselves.

As a summary, the current convention that Java Binder services use is
to prepend the reply Parcel with an int32 signaling the exception
status:

     0: no exception
     -1: Security exception
     -2: Bad Parcelable
     -3: ...
     -4: ...
     -5: ...

... followed by Parceled String if the exception code is non-zero.

With an upcoming change, it'll be the case that a response Parcel can,
non-exceptionally return rich data in the header, and also return data
to the caller.  The important thing to note in this new case is that
the first int32 in the reply parcel *will not be zero*, so anybody
manually checking for it with reply.readInt32() will get false
negative failures.

Short summary: If you're calling into a Java service and manually
checking the exception status with reply.readInt32(), change it to
reply.readExceptionCode().

Change-Id: I23f9a0e53a8cfbbd9759242cfde16723641afe04
2010-07-13 15:45:18 -07:00
Eric Laurent
a0296eda48 am 66fa2b44: am 8e886be4: Merge "Modifications in audio effect engine state management." into gingerbread
Merge commit '66fa2b44cadf8694cc1b7e2aae1f8abaff4fc547'

* commit '66fa2b44cadf8694cc1b7e2aae1f8abaff4fc547':
  Modifications in audio effect engine state management.
2010-07-13 12:33:47 -07:00
Eric Laurent
70d8f430a6 Modifications in audio effect engine state management.
- Separate the updating of effect engine state from the process call in EffectModule so that the state
of all effects in the same effect chain is updated simultaneusly before all process functions are called.
- Added a mechanism for the effect engine to continue being called for processing after receiving the disable
commands untils it considers that the framework can stop calling the process function without causing
a glitch or loosing some effect tail.
- Updated test reverb and equalizer to support this new feature

Change-Id: Icb56ae2c84c076d4dbad6cf733b1a62f823febe7
2010-07-13 12:27:18 -07:00
Kenny Root
d441a0ca24 am ceb8465e: am 87bb1857: Merge changes I2337051b,I19b426cb into gingerbread
Merge commit 'ceb8465e974ba5fa971ffe1b5b74e94a1bd53f97'

* commit 'ceb8465e974ba5fa971ffe1b5b74e94a1bd53f97':
  Tweak ObbFile class
  Allow things that can install packages to set Obb paths
2010-07-12 11:22:45 -07:00
Kenny Root
9baa2c7a44 Merge changes I2337051b,I19b426cb into gingerbread
* changes:
  Tweak ObbFile class
  Allow things that can install packages to set Obb paths
2010-07-12 11:18:34 -07:00
Kenny Root
fa59afb863 Tweak ObbFile class
* Move error messages around to clarify the errors.

* Add extra error check when reading a file.

* Seek to the end of a file when writing the signature so the users of
  the API don't have to remember to do it.

Change-Id: I2337051b9f9fa8147c5900237deec790dcd92436
2010-07-12 09:11:24 -07:00
Dianne Hackborn
47c320febd am b14f325a: am 289b9b62: Add ANativeWindow API for directly drawing to the surface bits.
Merge commit 'b14f325a0118ffce286155caaabaae149653462c'

* commit 'b14f325a0118ffce286155caaabaae149653462c':
  Add ANativeWindow API for directly drawing to the surface bits.
2010-07-09 17:05:23 -07:00
Dianne Hackborn
9147d11a5f Add ANativeWindow API for directly drawing to the surface bits.
Also other cleanup and fixes:

- We now properly set the default window format to 565.
- New APIs to set the window format and flags from native code.
- Tweaked glue for simpler handling of the "destroy" message.
- Um, other stuff.

Change-Id: Id7790a21a2fa9a19b91854d225324a7c1e7c6ade
2010-07-09 16:58:19 -07:00
Dianne Hackborn
895b3d0bdd am 49159f07: am 74bf59b4: Merge "Add new glue code for writing native apps." into gingerbread
Merge commit '49159f0748c704e53a7bd754f26113d9ab844a97'

* commit '49159f0748c704e53a7bd754f26113d9ab844a97':
  Add new glue code for writing native apps.
2010-07-08 19:10:17 -07:00
Kenny Root
8d3ee58899 am d481cdd4: am c9535de8: Merge "Add OBB file helper class" into gingerbread
Merge commit 'd481cdd4c0305f8afd857fe3ec3fbf189b744370'

* commit 'd481cdd4c0305f8afd857fe3ec3fbf189b744370':
  Add OBB file helper class
2010-07-08 19:08:57 -07:00
Jeff Brown
9aac262cb3 resolved conflicts for merge of 167449e5 to master
Change-Id: Ib448e69a726eb45b5c9099d2574e40b8345eee67
2010-07-08 19:01:13 -07:00
Dianne Hackborn
3c5d125ed7 Add new glue code for writing native apps.
This factors out the boiler-plate code from the sample
app to a common glue code that can be used for everyone
writing this style of app: a dedicated app thread that
takes care of waiting for events and processing them.

As part of doing this, ALooper has a new facility to allow
registration of fds that cause ALooper_pollOnce() to return
the fd that has data, allowing the app to drive the loop
without callbacks.  Hopefully this makes some people feel better. :)

Also do some other cleanup of the ALooper API, plus some
actual documentation.

Change-Id: Ic53bd56bdf627e3ba28a3c093faa06a92be522b8
2010-07-08 11:06:59 -07:00
Eric Laurent
7385d4c799 am b91881fd: am dacabf97: Merge "Added Visualizer effect." into gingerbread
Merge commit 'b91881fdd1608cc922f105ec552b5505da1fecb9'

* commit 'b91881fdd1608cc922f105ec552b5505da1fecb9':
  Added Visualizer effect.
2010-07-07 20:55:40 -07:00
Kenny Root
47ecb07ed4 Merge "Add OBB file helper class" into gingerbread 2010-07-07 18:14:13 -07:00
Chris Tate
9e1568cc2d Merge "More native input dispatch work." into gingerbread 2010-07-07 17:43:12 -07:00
Eric Laurent
b687191959 Merge "Added Visualizer effect." into gingerbread 2010-07-07 16:23:30 -07:00
Eric Laurent
873f21c820 Added Visualizer effect.
The visualizer enables application to retrieve part of the currently playing audio for visualization purpose.
It is not an audio recording interface and only returns partial and low quality audio content as a waveform or
a frequency representation (FFT).

Removed temporary hack made in MediaPlayer for animated wall papers based on audio visualization (snoop() method.

This commit also includes a change in AudioEffect class:
 - the enable()/disable() methods have been replaced bya more standard setEnabled() method.
 - some fixes in javadoc

Change-Id: Id092a1340e9e38dae68646ade7be054e3a36980e
2010-07-07 11:00:28 -07:00
Kenny Root
b94a9a668f Add OBB file helper class
ObbFile is a binary blob that will be used in packaging large files
with smaller APKs.

Change-Id: Ib1594346cfa2f49113de6565af77c24efbd89d63
2010-07-07 09:57:50 -07:00
Dianne Hackborn
747f65e77a am e24901d3: am 68267415: Add new native Looper API.
Merge commit 'e24901d3adb28fff72821d4e8e2ccc25b2184550'

* commit 'e24901d3adb28fff72821d4e8e2ccc25b2184550':
  Add new native Looper API.
2010-07-07 09:14:57 -07:00
Jeff Brown
f16c26dec9 More native input dispatch work.
Removed old input dispatch code.
Refactored the policy callbacks.
Pushed a tiny bit of the power manager state down to native.
Fixed long press on MENU.
Made the virtual key detection and cancelation a bit more precise.

Change-Id: I5d8c1062f7ea0ab3b54c6fadb058c4d5f5a9e02e
2010-07-03 19:23:01 -07:00
Dianne Hackborn
efa1085066 Add new native Looper API.
This allows us to avoid exposing the file descriptor of
the event queue; instead, you attach an event queue to
a looper.  This will also should allow native apps to be
written without the need for a separate thread, by attaching
the event queue to the main thread's looper and scheduling
their own messages there.

Change-Id: I38489282635895ae2cbfacb88599c1b1cad9b239
2010-07-02 18:57:02 -07:00
Mathias Agopian
a59a90b6be am 377e2352: am 7f8edbd9: Merge "remove unused YUV formats" into gingerbread
Merge commit '377e2352574c3cad1f64d222974afd93e821cff1'

* commit '377e2352574c3cad1f64d222974afd93e821cff1':
  remove unused YUV formats
2010-07-01 21:34:05 -07:00
Mathias Agopian
1764c73b55 remove unused YUV formats
Change-Id: Ie84616f842c7e0329d68e67e65a65d510558004b
2010-07-01 21:17:56 -07:00
Dianne Hackborn
ed2b843c91 am 177c405a: am c6e1d880: Merge "Introduce official public NativeWindow type." into gingerbread
Merge commit '177c405a242e811b1010bd8382b5807ab8df31a8'

* commit '177c405a242e811b1010bd8382b5807ab8df31a8':
  Introduce official public NativeWindow type.
2010-06-30 16:11:21 -07:00
Mathias Agopian
41360867a3 am e341a0b5: am 30fe6fa0: Merge "fix live wallpapers on Droid" into gingerbread
Merge commit 'e341a0b5e9a1e30a020970a69c58c34f902ea06f'

* commit 'e341a0b5e9a1e30a020970a69c58c34f902ea06f':
  fix live wallpapers on Droid
2010-06-30 16:05:37 -07:00
Dianne Hackborn
e12e3d7692 Merge "Introduce official public NativeWindow type." into gingerbread 2010-06-30 16:05:30 -07:00
Mathias Agopian
05dedd17ec Merge "fix live wallpapers on Droid" into gingerbread 2010-06-30 15:59:02 -07:00
Jeff Brown
ac18906a2e am 0c2df984: am d8ae2885: Merge "Fix injection of specially intercepted keys like HOME." into gingerbread
Merge commit '0c2df98425c8fa4ce092eebea80ae197547f6a86'

* commit '0c2df98425c8fa4ce092eebea80ae197547f6a86':
  Fix injection of specially intercepted keys like HOME.
2010-06-30 15:48:50 -07:00
Dianne Hackborn
b2007c4b89 resolved conflicts for merge of 7f6c6e8f to master
Change-Id: Id9dddb78c51f16ff8c4b60339421c94fde506db2
2010-06-30 15:44:58 -07:00
Mathias Agopian
a8f3e4e53c fix live wallpapers on Droid
On omap3 h/w we force opaque formats to RGB_565 instead of RGBX_8888
because the GL driver doesn't support it. RGBX_8888 is always remapped
to RGBA_8888.

Change-Id: I0bfabeb98c8d3a399079e6797cf2a0ee95915324
2010-06-30 15:43:47 -07:00
Dianne Hackborn
4b5e91e482 Introduce official public NativeWindow type.
Not yet hooked up to anything in the NDK, but requires renaming
the existing android_native_window_t type everywhere.

Change-Id: Iffee6ea39c93b8b34e20fb69e4d2c7c837e5ea2e
2010-06-30 15:32:04 -07:00
Jeff Brown
c393eb6cf5 Fix injection of specially intercepted keys like HOME.
This change mainly unwinds a premature optimization in the
dispatch pipeline.
To test HOME injection, run 'adb shell input keyevent 3'.

Change-Id: I1c4b7377c205da7c898014b8b07fc6dc1d46e4dd
2010-06-30 14:41:59 -07:00
Dianne Hackborn
189ed23c10 Implement default key handling for native code.
The native code now maintains a list of all keys that may use
default handling.  If the app finishes one of these keys
without handling it, the key will be passed back off to Java
for default treatment.

Change-Id: I6a842a0d728eeafa4de7142fae573f8c11099e18
2010-06-30 10:49:40 -07:00
Chris Tate
751ba60979 am af4a2d1f: am ddcb543a: Merge "Fix native input dispatch in the emulator." into gingerbread
Merge commit 'af4a2d1f52c7d54408db341781399d2886de72c1'

* commit 'af4a2d1f52c7d54408db341781399d2886de72c1':
  Fix native input dispatch in the emulator.
2010-06-29 17:06:31 -07:00
Chris Tate
d5d7b97b52 Merge "Fix native input dispatch in the emulator." into gingerbread 2010-06-29 17:01:04 -07:00
Jeff Brown
4036f7f2b4 Fix native input dispatch in the emulator.
Set a default orientation of ROTATION_0.
Added some more careful checks based on whether we have valid
absolute axis information from the driver.
Reset key repeating during configuration changes since the keyboard
device may have been removed.

Change-Id: I685960828acffcb17595fc5683309e8064a76714
2010-06-29 16:52:21 -07:00
Mathias Agopian
31649617ba am 33df868b: am 1eb442ee: Merge "remove a hack that was used only used on h/w we no longer support." into gingerbread
Merge commit '33df868bb35726d250c8a6d0ebd8c84749ffd51f'

* commit '33df868bb35726d250c8a6d0ebd8c84749ffd51f':
  remove a hack that was used only used on h/w we no longer support.
2010-06-29 15:36:53 -07:00
Mathias Agopian
c8df407af6 Merge "remove a hack that was used only used on h/w we no longer support." into gingerbread 2010-06-29 15:33:36 -07:00
Mathias Agopian
5d8f41cab1 remove a hack that was used only used on h/w we no longer support.
this should fix the opal build.

Change-Id: I43d7633696fea5be6bc834293a832d22f6bdfc61
2010-06-29 15:31:58 -07:00
Dianne Hackborn
3fc3eee094 am b5f05d00: am 0934fbb6: Merge "Update native activity & event APIs to follow correct conventions." into gingerbread
Merge commit 'b5f05d0018d72531e40c2afadfee90e9bc0c8893'

* commit 'b5f05d0018d72531e40c2afadfee90e9bc0c8893':
  Update native activity & event APIs to follow correct conventions.
2010-06-29 12:21:16 -07:00
Dianne Hackborn
9c7f8186ae Update native activity & event APIs to follow correct conventions.
Change-Id: Ie64fb3a9c68bc9c117fa5621b75d1f609e304e0e
2010-06-29 10:43:54 -07:00
Mathias Agopian
85af31f368 am 5d31a452: am f0562b4b: Merge changes I93dfc4c8,I781953d6 into gingerbread
Merge commit '5d31a4523bf5d1d3e3b5aa51043a1551d7aa56d7'

* commit '5d31a4523bf5d1d3e3b5aa51043a1551d7aa56d7':
  fix[2798925] Gingerbread TOT not booting
  Revert "Revert "fix [2793164] Spam 2x/second with TOT master in SurfaceFlinger""
2010-06-28 20:06:21 -07:00
Mathias Agopian
f8e79cc372 Merge changes I93dfc4c8,I781953d6 into gingerbread
* changes:
  fix[2798925] Gingerbread TOT not booting
  Revert "Revert "fix [2793164] Spam 2x/second with TOT master in SurfaceFlinger""
2010-06-28 20:01:58 -07:00
Mathias Agopian
05650aec9f fix[2798925] Gingerbread TOT not booting
Fixed a typo where checking against the wrong constant caused GL_TEXTURE_EXTERNAL_OES
to be used with a regular texture, which some GL driver will choke on.

Change-Id: I93dfc4c8fa674433bbb678eee31954e9a8d0cb4b
2010-06-28 19:54:17 -07:00
Chris Tate
1f0c9ea984 am 96725326: am 31e0ffe8: Merge "Native input event dispatching." into gingerbread
Merge commit '96725326149687168937cf62f75364cf9cc3e96b'

* commit '96725326149687168937cf62f75364cf9cc3e96b':
  Native input event dispatching.
2010-06-28 19:16:42 -07:00
Jeff Brown
50de30a523 Native input event dispatching.
Target identification is now fully native.
Fixed a couple of minor issues related to input injection.
Native input enabled by default, can be disabled by setting
WindowManagerPolicy.ENABLE_NATIVE_INPUT_DISPATCH to false.

Change-Id: I7edf66ed3e987cc9306ad4743ac57a116af452ff
2010-06-28 19:10:54 -07:00