99 Commits

Author SHA1 Message Date
Jeff Brown
9065504a63 Improve support for external keyboards.
Use Vendor ID, Product ID and optionally the Version to
locate keymaps and configuration files for external devices.

Moved virtual key definition parsing to native code so that
EventHub can identify touch screens with virtual keys and load
the appropriate key layout file.

Cleaned up a lot of old code in EventHub.

Fixed a regression in ViewRoot's fallback event handling.

Fixed a minor bug in FileMap that caused it to try to munmap
or close invalid handled when released if the attempt to map
the file failed.

Added a couple of new String8 conveniences for formatting strings.

Modified Tokenizer to fall back to open+read when mmap fails since
we can't mmap sysfs files as needed to open the virtual key
definition files in /sys/board_properties/.

Change-Id: I6ca5e5f9547619fd082ddac47e87ce185da69ee6
2010-12-02 16:01:32 -08:00
Jeff Brown
47e6b1b5ee Support non-orientation aware keyboards and other devices.
Fixed a bug with dpad keys on external keyboards being rotated
according to the display orientation by adding a new input device
configuration property called "keyboard.orientationAware".

Added a mechanism for overriding the key layout and key character
map in the input device configuration file using the new
"keyboard.layout" and "keyboard.characterMap" properties.

Also added "trackball.orientationAware", "touch.orientationAware" and
"touch.deviceType" configuration properties.

Rewrote the configuration property reading code in native code
so that it can be used by EventHub and other components.

Added basic support for installable idc, kl, and kcm files
in /data/system/devices.  However, there is no provision for
copying files there yet.

Disabled long-press character pickers on full keyboards so that
key repeating works as expected.

Change-Id: I1bd9f0c3d344421db444e7d271eb09bc8bab4791
2010-11-30 17:15:49 -08:00
Justin Ho
b6ac282eae Adding new ringtones and notifications
Change-Id: I2f59c1e5ef723e370165fc35c40a31df0ab0ee9f
2010-11-30 10:58:56 -08:00
Jeff Brown
d49c347921 Tweak key layouts.
Change-Id: I19777ec4e5d0a5485cfe2a44a15e2b0680557d08
2010-11-25 15:02:36 -08:00
Jeff Brown
42e514b0d1 Merge "Port Emulator keymaps." 2010-11-23 15:51:27 -08:00
Jeff Brown
061cf75884 Port Emulator keymaps.
Also added a validation tool for keymaps (not currently integrated
into the build system but getting there).

This change brings back Android.mk with the intent that it will
be used to validate keymaps in a later change.

Added some missing keys that are present on phones.

Bug: 3215210
Bug: 3225421
Change-Id: Id817c6e2215164616942c51a42752915d9ceacd3
2010-11-23 15:26:48 -08:00
Justin Ho
aff153d5a3 Adding new gingerbread notifications and ringtones to master
Change-Id: I5489606fa98dc78c0b864b95a98def41ce6d1f67
2010-11-22 09:33:21 -08:00
Jeff Brown
6b53e8daa6 Added support for full PC-style keyboards.
BREAKING CHANGE: Redesigned the key character map format to
accomodate full keyboards with more comprehensive suite of modifiers.
Old key character maps will not work anymore and must be updated.
The new format is plain text only and it not compiled to a binary
file (so the "kcm" tool will be removed in a subsequent check-in).

Added FULL keyboard type to support full PC-style keyboards.

Added SPECIAL_FUNCTION keyboard type to support special function
keypads that do not have any printable keys suitable for typing
and only have keys like HOME and POWER

Added a special VIRTUAL_KEYBOARD device id convention that maps
to a virtual keyboard with a fixed known layout.  This is designed
to work around issues injecting input events on devices whose
built-in keyboard does not have a useful key character map (ie.
when the built-in keyboard is a special function keyboard only.)

Modified several places where events were being synthesized
to use the virtual keyboard.

Removed support for the "qwerty" default layout.
The new default layout is "Generic".  For the most part "qwerty"
was being used as a backstop in case the built-in keyboard did
not have a key character map (probably because it was a special
function keypad) and the framework needed to be able to inject
key events anyways.  The latter issue is resolved by using the
special VIRTUAL_KEYBOARD device instead of BUILT_IN_KEYBOARD.

Added the concept of a key modifier behavior so that
MetaKeyKeyListener can distinguish between keyboards that use
chorded vs. toggled modifiers.

Wrote more robust key layout and key character map parsers
to enable support for new keyboard features and user installable
key maps.

Fixed a bug in InputReader generating key ups when keys
are released out of sequence.

Updated tons of documentation.

Currently QwertyKeyListener is being used for full keyboards
with autotext and capitalization disabled.  This mostly works
but causes some problems with character pickers, etc.
These issues will be resolved in subsequent changes.

Change-Id: Ica48f6097a551141c215bc0d2c6f7b3fb634d354
2010-11-18 09:49:03 -08:00
Jeff Brown
b0418da0e7 Add plumbing for volume mute key.
Full support for the volume mute key will be implemented in a
later change.

Bug: 2912307
Change-Id: I98c27d6360f159c8b7447e04b45f442eff87b38a
2010-11-02 17:31:39 -07:00
Mike Lockwood
3f425a6be4 Add new WRITE_MEDIA_STORAGE permission to control write access to /data/media
BUG: 3113970

Change-Id: Idb56be76729dc560dee5f680225cf4050f2751d2
Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-10-29 19:16:45 -04:00
Jean-Baptiste Queru
045002e0fc am c6d813b0: Merge "Introduce a list of all the audio files" into gingerbread-plus-aosp
Merge commit 'c6d813b0c5c21ab4e8ff920d181c5a29b7bb9f22'

* commit 'c6d813b0c5c21ab4e8ff920d181c5a29b7bb9f22':
  Introduce a list of all the audio files
2010-10-24 05:29:10 -07:00
Jean-Baptiste Queru
38655c0088 Introduce a list of all the audio files
Change-Id: Id52870e4d491bf074d5aa6f77d749397710ff316
2010-10-22 18:56:52 -07:00
Jeff Brown
497a92cc5b Add keycodes and meta-key modifiers to support external keyboards.
Added new key maps for external keyboards.  These maps are intended to
be shared across devices by inheriting the "keyboards.mk" product
makefile as part of the device's product definition.

One of the trickier changes here was to unwind some code in
MetaKeyKeyListener that assumed that only the low 8 bits of the meta key
state were actually used.  The new code abandons bitshifts in favor
of simple conditionals that are probably easier to read anyways.
The special meta key state constants used by MetaKeyKeyListener
are now (@hide) defined in KeyEvent now so as to make it clearer that they
share the same code space even if those codes are not valid for KeyEvents.

The EventHub now takes care of detecting the appropriate key layout
map and key character map when the device is added and sets system
properties accordingly.  This avoids having duplicate code in
KeyCharacterMap to probe for the appropriate key character map
although the current probing mechanism has been preserved for legacy
reasons just in case.

Added support for tracking caps lock, num lock and scroll lock and
turning their corresponding LEDs on and off as needed.

The key character map format will need to be updated to correctly support
PC style external keyboard semantics related to modifier keys.
That will come in a later change so caps lock doesn't actually do
anything right now except turn the shiny LEDs on and off...

Added a list of symbolic key names to KeyEvent and improved the toString()
output for debug diagnosis.  Having this list in a central place in the
framework also allows us to remove it from Monkey so there is one less
thing to maintain when we add new keycodes.

Bug: 2912307
Change-Id: If8c25e8d50a7c29bbf5d663c94284f5f86de5da4
2010-10-15 16:00:07 -07:00
Dan Morrill
2b0fa71c1a am c6581a10: am 4e9751f0: Merge "Adding a feature to indicate that the device possesses low-latency audio. The specific criteria for low-latency audio are defined in the CDD, but since that hasn\'t yet been settled for Gingerbread, this change doesn\'t go into details
Merge commit 'c6581a1046b062d0e06e50e9b09e6c12a8e54efc'

* commit 'c6581a1046b062d0e06e50e9b09e6c12a8e54efc':
  Adding a feature to indicate that the device possesses low-latency audio.
2010-09-27 11:45:51 -07:00
Dan Morrill
898e1e8860 Adding a feature to indicate that the device possesses low-latency audio.
The specific criteria for low-latency audio are defined in the CDD, but since
that hasn't yet been settled for Gingerbread, this change doesn't go into
details. We can do a docs change later once GB CDD is final.

Change-Id: Ic5ad9d04e8ecd78c81b6f09439affec6bf8cb9b2
2010-09-26 17:28:30 -07:00
Steve Block
fe06c42b61 Merge "Remove superfluous Ahem.tff" 2010-09-24 03:32:14 -07:00
satok
407b82a8e0 am abdbb5c1: am 933fc94c: Merge "Use MOTOYA font for Japanese font" into gingerbread
Merge commit 'abdbb5c1e5144e11d72367f79816caaa1dc63f8d'

* commit 'abdbb5c1e5144e11d72367f79816caaa1dc63f8d':
  Use MOTOYA font for Japanese font
2010-09-24 01:41:50 -07:00
Steve Block
a2f5fad891 Remove superfluous Ahem.tff
This was added in https://mondrian.corp.google.com/changelist/13754-p9
and comes from the WebKit LayoutTests. It's no longer used anywhere so
is being removed. It will be added in external/webkit/LayoutTests when
it is required for the triaged LayoutTests.

Bug: 3009858
Change-Id: I4b00b3f435fee9f8018052f4f8a5f3f67795437f
2010-09-23 19:05:36 +01:00
satok
9283f3cd6c Use MOTOYA font for Japanese font
Change-Id: I22c8cdf7f23f09c0cd7d3ffffaeed2a8eeb1fb54
2010-09-22 13:50:27 +09:00
Shin-ichiro Fukuda
dd62a056b8 DO NOT MERGE. MOTOYA Japanese fonts
These fonts were contributed by MOTOYA.
Cherry pick from Change-Id: I97879b4e163f6b547305da732c8604d1ac759df4

Change-Id: I97879b4e163f6b547305da732c8604d1ac759df4
2010-09-22 11:21:00 +09:00
Dan Morrill
5744bb4aa5 Adding new feature definitions for new sensors (barometer and gyroscope.)
Change-Id: Ic3a35c7b277921eaa5b05e3285b6aed5ed75bea6
2010-09-21 15:27:07 -07:00
Jean-Baptiste Queru
2a55db742e am 925f94b7: am 7869f08c: Merge "MOTOYA Japanese fonts"
Merge commit '925f94b788f5856025aa8218ee2e705c14f58281'

* commit '925f94b788f5856025aa8218ee2e705c14f58281':
  MOTOYA Japanese fonts
2010-09-21 10:45:09 -07:00
Jean-Baptiste Queru
925f94b788 am 7869f08c: Merge "MOTOYA Japanese fonts"
Merge commit '7869f08c55d774b0006c2260e87747ff5e0746f2' into gingerbread-plus-aosp

* commit '7869f08c55d774b0006c2260e87747ff5e0746f2':
  MOTOYA Japanese fonts
2010-09-21 10:21:37 -07:00
Shin-ichiro Fukuda
4234d40eae MOTOYA Japanese fonts
These fonts were contributed by MOTOYA.

Change-Id: I97879b4e163f6b547305da732c8604d1ac759df4
2010-09-17 15:45:23 +09:00
Jean-Baptiste Queru
3f6e7f4f71 Manage fonts like a true product definition
Change-Id: Ifc89c2fe9f4c2bb802dca34e9d53ae7176ff697c
2010-09-14 14:41:17 -07:00
Jean-Baptiste Queru
213fc950d4 Revert "Manage fonts like a true product definition"
This reverts commit 84d36a657d7954dc08f3ef9f057ff2526036e817.
2010-09-14 14:07:41 -07:00
Jean-Baptiste Queru
84d36a657d Manage fonts like a true product definition
Change-Id: I9635f087d69dd302e3c313073a537a8ed283bb68
2010-09-14 11:34:55 -07:00
Dianne Hackborn
6c82f673f6 am fd3f44b3: am e1aa82a4: Merge "Adding a feature denoting support for 5 or more fully independent multitouch pointers." into gingerbread
Merge commit 'fd3f44b38882c74c10aff0e238ee4ad9fcd8b724'

* commit 'fd3f44b38882c74c10aff0e238ee4ad9fcd8b724':
  Adding a feature denoting support for 5 or more fully
2010-09-03 15:14:57 -07:00
Dan Morrill
6993d3d136 Adding a feature denoting support for 5 or more fully
independent multitouch pointers.

Change-Id: I9997ed9c481dbd507e9eff70d8beb9e1140cca3f
2010-09-03 14:41:36 -07:00
Dan Morrill
1675062342 Adding features for new hardware, and creating a baseline list of required
hardware for the Tablet profile. This is very much subject to change.

Change-Id: Id0921b373cf610a7ec9ddd75dc020bf8b22a6911
2010-09-02 15:00:19 -07:00
Dianne Hackborn
8f5edc93b6 am 840f0fec: am d3efa392: Clean up some permissions.
Merge commit '840f0fecd87357cadf4b2a0ae96d30b457f89729'

* commit '840f0fecd87357cadf4b2a0ae96d30b457f89729':
  Clean up some permissions.
2010-09-01 22:55:04 -07:00
Dianne Hackborn
d3efa39244 Clean up some permissions.
Note that WRITE_OWNER_DATA and READ_OWNER_DATA don't actually appear
to be associated with anything or used by anyone, so they are just
deleted.

Also deprecate the activity API to go in the foreground.  I didn't
realize that was released in the SDK.  It needs to go away.

Change-Id: I96f53702c2c79e4999b6b2c498abb770bd27e03a
2010-09-01 21:19:40 -07:00
Hung-ying Tyan
f83d4f1779 resolved conflicts for merge of 3e4975a5 to master
Change-Id: Icd382fc43c8a1975801ab42eb184b633520149c7
2010-09-02 09:56:04 +08:00
Hung-ying Tyan
3424c02e6b Add software features for SIP and VOIP
and block SipService creation and SIP API if the feature is not available.

Change-Id: Icf780af1ac20dda4d8180cea3e5b20e21a8350bc
2010-09-02 08:10:13 +08:00
Dan Morrill
90324669f2 am 61f1cbdd: am a800a2ef: Merge "Adding a feature definition corresponding to support for Near-Field Communications (NFC)." into gingerbread
Merge commit '61f1cbdd71942433ce1515b614ec3d9c259ea037'

* commit '61f1cbdd71942433ce1515b614ec3d9c259ea037':
  Adding a feature definition corresponding to support for Near-Field
2010-09-01 17:03:33 -07:00
Dan Morrill
76437d3793 Adding a feature definition corresponding to support for Near-Field
Communications (NFC).

Change-Id: I32b1b949524bfd978f53e23e02d38dfba4a2ea9c
2010-09-01 14:42:23 -07:00
Chih-Chung Chang
1df11fc8f1 am cbbc035b: am de1057c4: Unhide new API for supporting multiple cameras.
Merge commit 'cbbc035b640790650d0e377a2d6291cc523a2a35'

* commit 'cbbc035b640790650d0e377a2d6291cc523a2a35':
  Unhide new API for supporting multiple cameras.
2010-06-27 20:54:36 -07:00
Chih-Chung Chang
de1057c4a6 Unhide new API for supporting multiple cameras.
Change-Id: I916a536c80330444a15986ba380205a6deed2390
2010-06-28 11:12:45 +08:00
Mike Lockwood
31ac8e9d56 Add new permission android.permission.ACCESS_USB to allow access to USB devices
Change-Id: Ib3dd573a5ef3950d20b21251fe7a3efad56b5c1f
Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-05-11 08:29:19 -04:00
Mike Reed
bc60d52750 final versions of these fonts from ascender, including GPOS 'mark' feature
Change-Id: I3e9faa83b19ac344e12cbda6d33405f040a34a9e
http://b/issue?id=2585430
2010-04-09 15:12:19 -04:00
Dave Sparks
bc6dffcf5d New lock/unlock sounds.
Change-Id: I464498b56d623d960e8a2de1f53bd5d4fcd3d69c
2010-03-24 19:02:49 -07:00
Mike Reed
e5efe212de refresh from ascender, w/ hints
Change-Id: I50e56741c5c808257f00bc274ea608f64b3a737f
2010-03-23 11:51:11 -04:00
Mike Reed
97be1549ce misc fixes, including 0xB0B8
Change-Id: I67ec767811e68500de7c5d57dcd1cb814b52f87d
2010-03-15 08:02:47 -04:00
Dan Morrill
50ab63f583 Adding definitions & APIs for features that are newly-optional in FroYo.
This also refactors the files containing the features so that they are more
modular. Note that this also changes data/etc/Android.mk so that
required_hardware.xml is NOT copied automatically for all devices
anymore. Accordingly, that file is removed.
2010-03-08 19:28:28 -08:00
Mike Reed
db4878433f initial add of Arabic, Hebrew and Thai fonts. 2010-03-02 11:25:44 -05:00
Daniel Sandler
0e9d2af2d6 New user interface sound effects:
- Low battery. (http://b/2320026)
 - Dock/undock events.
 - Keyguard lock/unlock events.

New system settings have been created to turn these on/off
and to specify the relevant sound files.

[Production notes: The provided low battery sound and dock
sounds were synthesized; the lock screen sounds are
processed samples of a ballpoint pen click mechanism.]

Bug: 2320026
Change-Id: I374285b0f94f59c7555bb8816580f5a8c802e90d
2010-02-12 23:26:12 -05:00
Ying Wang
4e208bd872 Merge "Support for product specific fallback font file." 2010-02-11 09:39:22 -08:00
Ying Wang
1c62afd03c Support for product specific fallback font file. 2010-02-09 13:15:10 -08:00
Eugene Koh
5e7a09fe46 Update DroidSansFallback typeface + preserve legacy version
Move the Droid Sans Fallback typeface from Eclair and earlier Android versions
to a new path in the tree, and update the mainline version to add 4,398 Hanzi
characters, which adds approximately ~0.5 MB to the system footprint.

If that additional size is problematic, implementors may elect to build instead
with the legacy version, which supports GB2312 for Simplified Chinese but lacks
the expanded character set.
2010-02-09 12:40:32 -08:00
Dianne Hackborn
9602d9adf4 Fix issue #2325782 Missing location features
Change-Id: I56a07438b5840f530f7508b1ef4904cea737a550
2009-12-14 11:00:40 -08:00