276 Commits

Author SHA1 Message Date
Dianne Hackborn
10bedaaf3e am 7fc39b26: Merge change 25238 into eclair
Merge commit '7fc39b26fc4ec9df7d147ff34ebba90556cdb4da' into eclair-plus-aosp

* commit '7fc39b26fc4ec9df7d147ff34ebba90556cdb4da':
  Implement issue #1780928: Need support hiding nav keys.
2009-09-15 23:11:35 -07:00
Dianne Hackborn
93e462b79d Implement issue #1780928: Need support hiding nav keys.
This implements support for devices whose hardware can hide
their navigation keys.  It works much like the existing keyboardHidden
configuration, and for compatibility uses the same configuration
change bit.

Also add FLAG_TURN_ON_SCREEN for windows, which has the system
cause the screen to be turned on when the window is displayed.
Great fun when used with FLAG_SHOW_WHEN_LOCKED!

Change-Id: I0b867f19af85cfd8786a14cea194b34f7bdd9b7a
2009-09-15 22:50:40 -07:00
Jean-Baptiste Queru
3c193a4a8d merge from open-source master 2009-09-04 07:54:30 -07:00
Jean-Baptiste Queru
be8e36e32b merge from donut 2009-09-03 15:19:21 -07:00
Robert Greenwalt
1cfe4b2a75 am e8f605ff: Merge change 23761 into eclair
Merge commit 'e8f605ff44664d0ecc9a5a24886176ef447db2a9' into eclair-plus-aosp

* commit 'e8f605ff44664d0ecc9a5a24886176ef447db2a9':
  Fix compilation of add-resource tag.
2009-09-03 09:11:10 -07:00
Robert Greenwalt
93d7251699 Fix compilation of add-resource tag.
It used the wrong tag-type to find the end of itself.
2009-09-02 18:23:57 -07:00
Eric Fischer
7a797a02af am 66c70e13: Merge change 23529 into eclair
Merge commit '66c70e13d9f39cf82df8542fe53f2049d3f2062e' into eclair-plus-aosp

* commit '66c70e13d9f39cf82df8542fe53f2049d3f2062e':
  Make it an error to use a bare apostrophe in aapt, and adjust warnings/errors.
2009-09-02 11:19:19 -07:00
Kenny Root
44b283dc27 Fix %p vs %s typo in aapt message
When trying to print an xmltree or xmlstrings from aapt, the error
message if the resource didn't exist erroneously printed a pointer
instead of a string.

Change-Id: I317bbbdc1200e0f10922e80a36e41a22b2d50d0d
2009-09-01 19:07:48 -05:00
Eric Fischer
c87d25215c Make it an error to use a bare apostrophe in aapt, and adjust warnings/errors.
In practice, no one ever writes an apostrophe in an aapt string with the
intent of using it to quote whitespace -- they always mean to include a
literal apostrophe in the string and then are surprised when they find
the apostrophe missing.  Make this an error so that it is discovered
right away instead of waiting until late in QA or after the strings have
already been sent for translation.  (And fix a recently-introduced string
that has exactly this problem.)

Silence the warning about an empty span in a string, since this seems to
annoy people instead of finding any real problems.

Make the error about having a translated string with no base string into
a warning, since this is a big pain when making changes to an application
that has already had some translations done, and the dead translations
should be removed by a later translation import anyway.
2009-09-01 15:20:30 -07:00
Jean-Baptiste Queru
85a2c7f1ca merge from open-source master 2009-09-01 11:46:14 -07:00
Robert Greenwalt
832528f92c Fix replacement-after-add of resource files in overlay.
Aapt was adding/removing elements from a list an continuing to use a stale copy for future indexes.
This could cause incorrect subsequent processing.  Add an en resource and modify an es, for example.
Adding the en would cause the base fileset's es version to be moved in the list.  Using the old index
we'd then attempt to remove the old es version with the wrong index and then add the new es version
generating a "duplicate file" error.

bug: 2090015
2009-08-31 14:56:28 -07:00
Jean-Baptiste Queru
72b1f379d5 donut snapshot 2009-08-31 09:17:57 -07:00
Joe Onorato
56d8eeae6f applications are at level 2 2009-08-30 16:54:12 -07:00
Joe Onorato
1553c82e08 Add a flag (-G) to aapt to have it output the classes that shouldn't be obfuscated by ProGuard. 2009-08-30 16:51:29 -07:00
Dianne Hackborn
49237345d8 Add platform infrastructure for features.
This introduces a new mechanism to define features associated with
a platform, query the current device for the available features,
and enforce that apps requiring features that aren't available can't
be installed.

Also now allows uses-library to specify that a library is optional,
so the lack of such a library will not prevent the app from being
installed (but if it does exist it will be correctly linked into
the app).

Change-Id: I5b369b46cfa0b3d37c9e08fd14ef1098a978e67b
2009-08-27 21:51:00 -07:00
Dianne Hackborn
e5276a7474 Fix issue #2084148: Define the format for the auto focus preview for barcode scanning
Add new manifest/aapt support for specifying device features an application
requires.  The aapt badging now returns these (as well as uses-permission since
I need to look for those anyway); if an app doesn't explicitly request the
camera feature but does request the permission, then aapt will say that it has
requested both the basic camera feature as well as the autofocus feature.

Here's what you put in your manifest to say you need a camera but don't need
autofocus:

    <uses-permission android:name="android.permission.CAMERA" />
    <uses-feature android:name="android.hardware.camera" />
    <uses-feature android:name="android.hardware.camera.autofocus" android:required="false" />

Here's what will be seen from aapt:

uses-permission:'android.permission.CAMERA'
uses-feature:'android.hardware.camera'
uses-feature-not-required:'android.hardware.camera.autofocus'

Change-Id: I4dd19cee0486cc54771f5bf14fc9db0e892115d5
2009-08-27 16:28:44 -07:00
Dianne Hackborn
4a51c20ce6 I am getting tired of the java doc warnings, so fix them.
Change-Id: I2205eebae419eaf4a0992c9f5b7cd807eb843fe1
2009-08-24 17:37:32 -07:00
Kenny Root
841ce8b7b9 Fix bitmask in aapt's StringPool length construction
The StringPool indicates the length of a string with a 16-bit
integer. If the length of the string is greater than 0x7FFF,
it splits it into two 16-bit integers with the first one
having the high bit set.

The length calculation has a small bug that masks off the
19 bits instead of the first 15 bits as intended.
2009-08-21 15:23:45 -05:00
Suchi Amalapurapu
1b125980c5 Add aapt extensions to dump badging to print more info about activities, receivers and services
Fix issue with checking end tags. Earlier some boolean variables were being set once a new
tag is detected at the same level which causes some incorrect values to be overwritten.
we should be doing this when we detect the end tag.
2009-08-18 16:25:28 -07:00
Suchi Amalapurapu
6919f69281 am 75c49842: Add maxSdkVersion information in dump badging option
Merge commit '75c498426a17b47d445711bb9e36794b05876a56' into eclair

* commit '75c498426a17b47d445711bb9e36794b05876a56':
  Add maxSdkVersion information in dump badging option
2009-08-18 10:59:08 -07:00
Daniel Sandler
3547f859d4 aapt now attempts to process all assets even if some are malformed.
Previously aapt would bail out on the first broken image, making it difficult to compile a comprehensive list of broken images.  Now it will pre- and post-process all of them and report any and all errors (before exiting with an error code if any errors were encountered).

Bug: 2055485
2009-08-17 10:55:47 -04:00
Dianne Hackborn
64551b2e0e Fix aapt to be able to add configs from overlays.
Fixes a bug where any new configurations introduced in an overlay
would be half-way ignored (enough to result in a broken .apk).
2009-08-15 00:00:33 -07:00
Suchi Amalapurapu
75c498426a Add maxSdkVersion information in dump badging option 2009-08-14 15:13:09 -07:00
Dianne Hackborn
58c27a0a03 Allow overlays to add resources. 2009-08-13 13:36:00 -07:00
Jean-Baptiste Queru
a8675f67e3 donut snapshot 2009-07-29 14:25:07 -07:00
Android (Google) Code Review
a8339dfec9 am 9fc20b0e: Merge change 8126 into donut
Merge commit '9fc20b0e381b5fe00b7049ef357c839cd05a33bf'

* commit '9fc20b0e381b5fe00b7049ef357c839cd05a33bf':
  First pass at reworking screen density/size APIs.
2009-07-21 19:03:53 -07:00
Dianne Hackborn
c4db95c077 First pass at reworking screen density/size APIs.
This changes the names of the directories in aapt, to what you see
in the list of DpiTest resources.  Also adds a new "long" configuration
for wide screens, which the platform sets appropriate, and introduces
a new kind of resizeability for not large but significantly larger
than normal screens which may have compatibility issues.
2009-07-21 18:28:42 -07:00
Jean-Baptiste Queru
cf4550c319 donut snapshot 2009-07-21 11:16:54 -07:00
Android (Google) Code Review
469b4c67ad am aad0fcc9: Merge change 7783 into donut
Merge commit 'aad0fcc9619eb72c18a6afff48ebc9d4011f0f54'

* commit 'aad0fcc9619eb72c18a6afff48ebc9d4011f0f54':
  Add "nodpi" density, and expose a bunch of density-related APIs.
2009-07-19 20:28:49 -07:00
Dianne Hackborn
a53b828635 Add "nodpi" density, and expose a bunch of density-related APIs.
Also update the DpiTest app to use nodpi images, and try to have a mode
where it turns off compatibility though it's not quite working.
2009-07-17 16:59:08 -07:00
Marco Nelissen
dd93186420 Format aapt warnings the same way as other compiler warnings
('warning: ' instead of 'WARNING: ' or 'WARNING ')
2009-07-13 14:14:01 -07:00
Android (Google) Code Review
f6ff591dec am 72eb0aca: Merge change 5483 into donut
Merge commit '72eb0acad5cffc57ce5006f6deab29ee259e461e'

* commit '72eb0acad5cffc57ce5006f6deab29ee259e461e':
  Expand support for different screen sizes.
2009-06-29 16:37:17 -07:00
Dianne Hackborn
723738cfae Expand support for different screen sizes.
Applications can now declare that they support small, normal, or
large screens.  Resource selection can also be done based on these
sizes.  By default, pre-Donut apps are false for small and large,
and Donut or later apps are assumed to support all sizes.  In either
case they can use <supports-screens> in their manifest to declare
what they actually support.
2009-06-26 13:37:05 -07:00
Android (Google) Code Review
fc68623c03 am 1585bd24: Merge change 4828 into donut
Merge commit '1585bd24c10d16351f89e32dddbfa799f18db6bd'

* commit '1585bd24c10d16351f89e32dddbfa799f18db6bd':
  Report densities in badging, debugging for nine patch bug.
2009-06-19 16:44:07 -07:00
Dianne Hackborn
e17086ba34 Report densities in badging, debugging for nine patch bug.
The aapt tool now reports all available densities like it already did
for locales.  Also this includes more resource data output, which I
was using to examine bug #1867049 (which at this point I am unable to
reproduce).
2009-06-19 15:13:28 -07:00
Android (Google) Code Review
1b04076251 am 684a2edb: Merge change 3577 into donut
Merge commit '684a2edbe192a2a76684c5d6855773196d2e1a2e'

* commit '684a2edbe192a2a76684c5d6855773196d2e1a2e':
  Make aapt Error out when an overlay adds a string.
2009-06-10 15:32:56 -07:00
Android (Google) Code Review
684a2edbe1 Merge change 3577 into donut
* changes:
  Make aapt Error out when an overlay adds a string.
2009-06-10 12:36:45 -07:00
Robert Greenwalt
f878e2d80c Make aapt Error out when an overlay adds a string.
Final added check (I think) for 1585775 - not letting overlays add
resources.

	modified:   ResourceTable.cpp
	modified:   ResourceTable.h
2009-06-09 16:23:35 -07:00
Robert Greenwalt
641fa6c602 am fa5c7e1d: Catch when a file resource (non values) added in an overlay.
Merge commit 'fa5c7e1dfede7e26260789dd2de5175497e9659b'

* commit 'fa5c7e1dfede7e26260789dd2de5175497e9659b':
  Catch when a file resource (non values) added in an overlay.
2009-06-08 11:06:48 -07:00
Robert Greenwalt
fa5c7e1dfe Catch when a file resource (non values) added in an overlay.
File resources are assigned resource id's and if an overlay adds one
it renumbers things and breaks compatability.  Used to segfault
if you tried before, but now catches it and lets you know what file
caused the problem.
2009-06-08 09:10:29 -07:00
Robert Greenwalt
5f0a472cd4 am 1aa8170e: Add per-named-item overlay ability in res xml.
Merge commit '1aa8170e6a448afad86e5d62927d3b8ca4cd9707'

* commit '1aa8170e6a448afad86e5d62927d3b8ca4cd9707':
  Add per-named-item overlay ability in res xml.
2009-06-05 21:17:43 -07:00
Robert Greenwalt
1aa8170e6a Add per-named-item overlay ability in res xml.
Fixes 1899451.
Also errors out if you add a bag via an overlay (which would renumber
resources).  Note that you can still add elements within the bag as they are
not issued resource IDs.  So for example you can now modify the framework
themes.xml file without copying the entire file.

All bag types are now modifable except non-named bag types (how would you
address which element to replace?):
    array
    string_array
    integer_array
2009-06-05 16:09:24 -07:00
Mathias Agopian
55e3d60da5 break dependency on utils/ZipEntry.h and utils/ZipFile.h, get rid of inet_address.h and Socket.h which were not used 2009-06-05 14:56:35 -07:00
Mathias Agopian
3b4062eeb0 get rid of utils.h 2009-05-31 19:13:00 -07:00
The Android Open Source Project
bb59a9f428 Merge commit 'f479aa0900e9a85afdc78b1048684e37579ebf23'
Conflicts:
	api/current.xml
	core/res/res/values/public.xml
2009-05-20 22:41:10 -07:00
Dianne Hackborn
f479aa0900 Add padding to public.xml to avoid breaking from auto-merges. 2009-05-20 16:30:59 -07:00
Jean-Baptiste Queru
843ef36f7b donut snapshot 2009-05-20 11:28:04 -07:00
Android (Google) Code Review
f1f12f8cfc am 656a2726: Merge change 1910 into donut
Merge commit '656a2726ad977be194c3b8f4bf4ec3068bf3e1c9'

* commit '656a2726ad977be194c3b8f4bf4ec3068bf3e1c9':
  Update aapt badging for native code, configs, density, etc.
2009-05-18 23:56:07 -07:00
Dianne Hackborn
bb9ea30ea9 Update aapt badging for native code, configs, density, etc. 2009-05-18 15:22:00 -07:00
Dianne Hackborn
072e499a0e Merge commit 'refs/changes/39/1839/1' of ssh://hackbod@android-git.corp.google.com:29418/platform/frameworks/base into merge 2009-05-15 21:15:37 -07:00