aboutsummaryrefslogtreecommitdiffstats
path: root/eclipse/scripts
Commit message (Collapse)AuthorAgeFilesLines
* New Template Wizard supportTor Norbye2012-05-221-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This changeset adds several new templates, to create a new project, a new activity, a new custom view, etc. More importantly, it contains support for these wizards (and the corresponding code generation) to be driven by templates. A wizard contains metadata which provides a name, description and icon for the template, as well as a list of parameters, along with type and constraint metadata for those parameters. When a wizard is created for this template, it automatically adds UI elements to input the parameters and to validate the input. Parameters can also specify their default values as templated expressions using the other variables on the page, so in the New Blank Activity wizard for example, editing the activity name automatically updates the suggested layout name, by repeatedly evaluating a template expression to compute a layout name from an activity name. There's a recipe file for each template which states what actions to take to create the template. In addition to obviously copying resources (such as icons and jar files) and instantiating templates (to rewrite text using variables and FreeMarker logic), it can also merge XML contents (to for example insert activity registration metadata into the manifest file, or add string definitions to the strings.xml file), and it can cause files to be opened when the template is created. Tne new wizards also use JFace's decorator support to provide help and to mark text fields that contain errors, when one or more of the page fields do not validate, as well as to show tip text along the bottom of the page. One example of this is that it explains what a "package name" is when the package field has focus. This changeset also contains a "Template Development Wizard" which lets you point to a local directory containing a template definition, and run a test wizard from there. This is useful for developing, debugging and testing templates. Change-Id: I08e7d2464a1ef00d09517f0154c42681249a7ff6
* Manifest merge for ADT.Xavier Ducrohet2012-05-211-1/+1
| | | | Change-Id: I635098594605af497a8b7d244e502385b8f34d1e
* SDK Manager: display options menu when invoked from IDE.Raphael Moll2012-05-171-1/+1
| | | | Change-Id: I03c75be4d624f841c6f4c0ba93b0951bc8da8850
* Replace current complex delta visitor by pattern based ones.Xavier Ducrohet2012-05-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | The build system relies on several different delta visitor that detect file changes to detect that needs to be rebuilt but the implementation of those files is based on going through folders recursively while keeping states. This is complex and prone to errors. The new mechanism is simply based on glob-pattern, relative to the project root. A set of predefined patterns stored in ChangedFileSet instance allow quick reuse. ChangeFileSetHelper stores those as well as allow creating others that are based on a project config (such as the output folder). This first CL replace the previous delta visitors in the PostCompilerBuilder. Replacing the ones in the PreCompilerBuilder will require a bit more work so I prefer splitting it in another CL. The code that runs the pattern recognition is coming from Ant and is stored in external/ant-glob. This is not all of Ant but a subset of the classes for our need. This CL does include a simple set of tests for the extracted Ant classes. Change-Id: I2ad1b116ffb29c9f4195d863d04f8812e87a31ca
* Move kxml2 to prebuilts/miscJean-Baptiste Queru2012-04-301-2/+2
| | | | Change-Id: I3a939238911ae7c09bb75b27e1ce623777cd4e18
* SDK: build 'monitor' tool and package it in the SDK.Raphael Moll2012-04-236-271/+0
| | | | | | | | | | | | | | | Fixed with Siva to use the 'ant' builder from Eclipse's baseBuilder jars. Changed to use: - the new external/eclipse-basebuilder for the basebuilder jars. - the rcp deltapack, located prebuilts/eclipse. - monitor scripts are now in sdk/monitor. - configuration is now in out/host/eclipse/rcp/build/configuration and doesn't change any existing repos. Requires change I7ab027ff6 from build.git Change-Id: I72fff09231fc9b3031c10eb42ff821c55af9b5d5
* Update paths to use Eclipse 3.7.2.Siva Velusamy2012-04-191-3/+3
| | | | Change-Id: Ie01a2d1f71b1a2edfbdad717de3e7e252b9f4fe2
* fix create_all_symblinks with new location of http-client.Xavier Ducrohet2012-04-161-6/+6
| | | | Change-Id: I0313091219aa80cd1c97b796c4444a875db5311d
* Merge "minor update to error output of create_all_symlinks."Xavier Ducrohet2012-04-051-1/+2
|\
| * minor update to error output of create_all_symlinks.Xavier Ducrohet2012-04-051-1/+2
| | | | | | | | Change-Id: I1b3a1a02c8b4113b06f339e6148cd3f47e648a29
* | Add support for the WindowBuilder Property SheetTor Norbye2012-04-051-1/+1
|/ | | | | | This reverts commit 27dac06bfc4297dc9a018edc534f44ecf96cd724. Change-Id: I6708bd4091f0cb677484669479357d479b9db5fa
* SDK: fix jfreechart path in create_all_symlinks.Raphael Moll2012-04-041-3/+3
| | | | Change-Id: Ic63510a3d6350a555ebe414ee044e45100b91da2
* Revert "Add support for the WindowBuilder Property Sheet"Tor Norbye2012-04-031-1/+1
| | | | This reverts commit a7621238bf0202419677380ee3a268142358df83.
* Add support for the WindowBuilder Property SheetTor Norbye2012-04-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The WindowBuilder propertysheet has been extracted and added as a library in external/eclipse-windowbuilder/. This changeset removes the old propertysheet code (which used the builtin Eclipse property sheet page), and replaces it with the WindowBuilder one, along with new code to aggregate the properties into some categories, as well as tagging some of the properties as advanced. (This was computed by running the same analysis scripts used to produce the most-frequent attributes (sdk/attribute_stats) and instead computing which attributes are used very infrequently or not at all in some representative sample code.) The WindowBuilder propertysheet gives us the following new features: - Highlighting (bold) of important attributes - Masking (and when included, shown in gray italic) of advanced attributes - "Complex" attributes with nesting, used to for example aggregate all the layout parameters into a single node, and the margin layout attributes within those - Tooltips over the attribute names, not values, so they never obscure content In addition, this changeset adds custom implementations of properties, property editors and property dialogs for the core Android property types (XML strings, flags and booleans), which adds the following new features: - Preview rendering of color and image resources inline - Display of -default- attributes (those not specified in XML) using the layoutlib facility getDefaultProperties() to render the implied attributes. For example, if you look at a Button, it will show you that the implied value of "Text Color Link" is "@android:color/holo_blue_light" even though it is not set. NOTE: This only happens for attributes that were actually queried by the widget during rendering. Attributes that are not used by the widget have no (displayed) value. Thus, EditText-specific attributes in a TextView are not shown when a non-EditText TextView is selected. - Evaluation of the attributes. In the above example, in addition to showing @android:color/holo_blue_light, it will chase down the value of this to for example render a blue square next to the value. For drawables it will render a thumbnail, and for String resources it will display the actual value in parentheses. - Field completion in text fields, completing all resource strings (@string, @android:string, etc), as well as flag values. Enum values are chosen in a dropdown. - Checkbox support for boolean values, allowing you to click through the three values true, false and null. - Our custom version of the Property Sheet Page allows you to expand/collapse all properties, and it also has an option letting you switch between Alphabetical Sort (where all attributes are in a flat table, sorted alphabetically by property value), or hierarchical sorted "by category". Currently the categories are simply the defining views, plus 2 more (layout parameters and deprecated attributes). When we get more metadata, it would be nice to switch these to more logical categories, such as "text", "scrolling", "focus", etc. (There is some preliminary support for this in the code, but since the defining-view categories seem to work better those are used instead right now.) Change-Id: Ie4959a3a2c36c083dcc1ba19a70f24b33739fe2f
* Add base pluginSiva Velusamy2012-03-301-20/+20
| | | | | | | | | | | | Add a plugin that is contains libraries and other utilities common to both ADT/Eclipse plugins and RCP applications like monitor. Currently, it contains: - libraries: common, sdkstats, androidprefs & sdklib. - prebuilts: guava Change-Id: I982a6897fa73c5ba8c282bc2fba4b1e66b4e2ecd
* Merge "Move tools and ADT to 19."Xavier Ducrohet2012-03-291-0/+1
|\
| * Move tools and ADT to 19.Xavier Ducrohet2012-03-291-0/+1
| | | | | | | | Change-Id: I3906416a7b5a4bf7b7e2f86ee3155c22d93a3c2b
* | rcp: Add missing preferences and menu items.Siva Velusamy2012-03-291-9/+12
|/ | | | | | | The monitor RCP was missing a bunch of menu items & preferences. This CL adds a subset of those. Change-Id: I7b3f71f4423145f777bfea97ba98a6e19a0d480b
* Turn off warnings in the command-line RCP monitor buildSiva Velusamy2012-03-261-0/+1
| | | | | | Patterned after Changeset Id469ad9d6f8357bb331f38562bb0aaa253849f4b Change-Id: Ieaf240d40abfde95bbedd6d7d028e52316d25361
* Merge "Update setup_eclipse script to download CDT."Raphaƫl Moll2012-03-261-1/+10
|\
| * Update setup_eclipse script to download CDT.Siva Velusamy2012-03-211-1/+10
| | | | | | | | Change-Id: I082b8a21fba98979664427b0a8e140d5a8e3b0df
* | Fix build: Entirely disable the SDK Monitor RCP.Raphael Moll2012-03-231-39/+39
| | | | | | | | | | | | Apparently removing from the SDK build it not enough. Change-Id: I3aee0ee0eb05d83ea91d3ad75493185c5d756e38
* | Build Monitor RCP as part of SDK (Mac, Linux and Win)Raphael Moll2012-03-214-28/+179
|/ | | | | | | | | | | | | | | | This adds a new SDK/tools/monitor[.bat] wrapper as well as SDK/tools/lib/monitor-x86[_64]/ directories that contain the actual RCP application. The monitor shell wrappers + bat have not been properly tested yet. The goal of this CL is just to build the RCP. In a following CL we'll adjust the wrapper and the actual binary location in the SDK. Cross-dependency: Requires build.git change Ifb31e2e3. Change-Id: I7afbd63badfb81fd5d3d899de672e02525a49bc2
* Merge "API check hooked up to lint"Tor Norbye2012-01-271-1/+0
|\
| * API check hooked up to lintTor Norbye2012-01-271-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This checkin hooks up the API check to lint, such that class references, method calls and field access are checked with the database and generates warnings if the project min SDK is lower than that required by the API. It also checks layout references to ensure that the widgets are supported by the minimum API. NOTE: There's no flow analysis to avoid classes that are deliberately accessing later APIs (and where the referencing class is loaded conditionally). Therefore, for now the lint check is disabled by default; enable with "lint --check NewApi". Change-Id: Ia3160f81b45b5baed3caa46cdffe56735ebedd44
* | Move the tools/ADT to r17Xavier Ducrohet2012-01-271-2/+2
|/ | | | Change-Id: I4989ce98d4c6a600ca075ee919e5a0e1a40a4497
* Merge "rcp: support per platform builds."Siva Velusamy2012-01-263-51/+66
|\
| * rcp: support per platform builds.Siva Velusamy2012-01-263-51/+66
| | | | | | | | | | | | | | | | The ant script now takes an option that controls which platforms to build the RCP for. If no option is given, the RCP is built for all platforms. Change-Id: I433ae41cd65af820e2d21f25f1324844512a63da
* | gltrace: manage texture image state changesSiva Velusamy2012-01-241-1/+2
|/ | | | | | | | | | | | | | | | | | Texture Data is provided via glTexImage2D. Parts of a created texture may then be updated using glTexSubImage2D. This patch adds a GL state variable that maintains a path to the current texture image for each texture. This patch also includes a few other misc. changes: - Duration minimap: do not create back buffer image of size 0. In such a case, just don't draw anything. - In the function trace view, selecting a particular item in the table doesn't also scroll it into view on Mac. Add a setTopIndex to fix this. - add Guava is a dependency - Apply the state transformations in a separate Eclipse job. Change-Id: I53f5a0438217d9d086b844f7d333306f7c9fbccd
* rcp: update build script to point to prebuilts/eclipseSiva Velusamy2012-01-121-4/+4
| | | | Change-Id: I64bd4569d939cf561364f4073dc88744f64588be
* Lint Java source supportTor Norbye2012-01-091-0/+1
| | | | | | | | | | | | | | | | | This changeset adds Java AST support to Lint. There are new interfaces for Java parser and specialized Java detectors. Java detectors can either visit a full parse tree, or they can register interest in specific methods, or Android resource references, or specific AST node types -- or a combination of these. They will then be invoked during an AST visit with the relevant info. This changeset also rewrites the existing detectors that were using String-based pattern checking on Java files to using real AST traversal instead (and it removes the custom Eclipse-specific unused resource detector since the plain one now does the same AST-based analysis that the Eclipse one did.) Change-Id: I4d85f8b785bf41a88dbb29e7017b9c0f588880bc
* Update SDK codebase to JDK 6Tor Norbye2011-12-211-2/+2
| | | | | | | | | | | | | | | | | | | | | This changeset makes the SDK codebase compile with source=1.6 (which means it also requires JDK 6). This means that methods implementing an interface requires @Override's. It also means we can start using APIs like the ArrayDeque class and methods like String#isEmpty(). This changeset looks big but the change is trivial: it's basically adding @Override in all the places that need it, along with some other automatic Eclipse cleanup in certain files (such as reordering imports where they were incorrectly ordered (because older versions of Eclipse didn't always handle inner classes right)), as well as cleaning up trailing whitespace and removing some $NON-NLS-1$ markers on lines where there aren't any string literals anymore. This changeset also sets the source and target JDK level to 6 in the Eclipse compiler .settings file, and synchronizes this file to all the other Eclipse SDK projects. Change-Id: I6a9585aa44c3dee9a5c00739ab22fbdbcb9f8275
* rcp: remove unnecessary plugins.Siva Velusamy2011-12-211-1/+0
| | | | | | | DDMS & TraceView do not depend on JDT anymore, so all those dependencies can be removed from the RCP product definition. Change-Id: If09a4d1c4bf8acb69669713a5052a607f9137663
* Merge "rcp: create monitor plugin & build scripts"Siva Velusamy2011-12-124-15/+180
|\
| * rcp: create monitor plugin & build scriptsSiva Velusamy2011-12-084-15/+180
| | | | | | | | | | | | | | | | | | | | | | | | | | The monitor plugin defines the entry point for the monitor RCP application, and also defines the monitor.product product configuration. The build scripts in eclipse/scripts/rcp show how to build the RCP app from the command line. Currently, these are not built on the build server. That will happen once we figure out where to put the prebuilts. Change-Id: Idc96b2c011dba55c0d6792e916193017df6ce1c1
* | Add the Guava library to the toolsTor Norbye2011-12-051-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | This changeset adds the Guava library to ADT and lint. (It is also a prerequisite for the Lombok AST library which is added by a later CL.) This changeset also uses the library in a few simple ways: It replaces some custom I/O and collections code with calls into the equivalent Guava methods, and it also adds the @Beta annotation on the various "API" classes which are not yet stable. Change-Id: I2f50febfa075c32818404e888578a2e1e447d408
* | Add Java Classfile supportTor Norbye2011-12-051-0/+2
|/ | | | Change-Id: Ifcc1d88dabb07dc05b2e5c934743ad52f9b6dc1d
* SDK: run lunch sdk-eng as part of create_all_symlinks.Raphael2011-11-231-0/+8
| | | | | | | | | When I open a new shell/terminal, I often forget to run envsetup and lunch sdk-eng, and then create_all_symlinks nicely cleans out for me... This runs lunch sdk-eng, but only if TARGET_PLATFORM is not set. Change-Id: I1d955682827c13f6f53ae25af4293edc38bc1d76
* GLTrace initial implementationSiva Velusamy2011-11-141-1/+1
| | | | | | | | This initial implementation provides two basic features: 1. Connect to the device and retrieve a trace. 2. Open a trace file and display the list of GL calls in a table. Change-Id: Ib594f0606b1276f6fbdcc0d7a1dae9034617cfab
* SDK: Switch to Eclipse 3.6.2 RCP+CDT for build_serverRaphael2011-11-083-14/+6
| | | | Change-Id: I3fab918d5d9ed96d753410cfe3cf58a06788a058
* SDK: simplify create_all_symlinks script.Raphael2011-11-0810-420/+173
| | | | | | | | | | | | Merge all scripts into a single one so that we have just one call to make instead of 8 of them. Edits: - Disable things that won't build under cygwin - Added missing lint-api & lint-client. - Fix missing ddms prebuilts. Change-Id: I1dd74cc804438c353e8c9dce82c0513a8c04a3da
* Move tools and adt to 16Xavier Ducrohet2011-10-281-0/+6
| | | | Change-Id: I79ae1bff5086146cc60b4496f4b0464ffd642651
* Static analyzerTor Norbye2011-10-201-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This changeset adds a static analyzer, "lint", which looks for various potential bugs in Android projects. It has 3 parts: (1) A library which performs the actual static checks. This library is standalone: it does not depend on Eclipse. (Technically the library has two halves: an API half, for use by third party developers to write additional detectors, and an actual implementation of a bunch of built-in checks.) (2) A command line driver, "lint", which runs the static checks and emits any warnings to standard out. This can be thought of as a replacement for the layoutopt tool. (3) Eclipse integration. Lint errors are added to the Problems view as well as shown as editor annotations. There's an options panel for controlling which detectors are enabled. There's also a quickfix for disabling errors directly within the editor and a marker resolution for disabling them via the Problems view. The static checks are run on an XML file right after it has been saved. (This is optional via a toggle on the same preference page as the detector list.) The static checks are also run when you export an APK, and if any fatal errors are found the export is abandoned. (This is also optional via an option). Finally you can run a full lint through the Android Tools menu, and there's also an action to clear all the lint markers there. There's also a new indicator on the layout editor which shows whether there are lint errors on the associated file, and when clicked brings up a dialog listing the specific errors. This changeset also includes a number of checks: * An accessibility detector which warns about images missing contentDescriptions * A drawable selector detector which warns about state lists where not all states are reachable (e.g. it is not the case that only the last item in the list omits a state qualifier) * A detector finding duplicate ids, not just in the current layout but across included layouts (transitively) as well * All the layoutopt ones ported to Java + DOM * Unit tests for the above. The focus here is on getting the infrastructure in place, and it currently focuses on XML resource files and analyzing them efficiently. See the comment in XmlVisitor for details on that. Change-Id: Ic5f5f37d92bfb96ff901b959aaac24db33552ff7
* Fix ADT buildRaphael2011-10-041-1/+1
| | | | Change-Id: If0411f65bb523e5b26d53c620df666937f8467ca
* Fix buildTor Norbye2011-10-041-0/+4
| | | | Change-Id: Ie4e5dcc64ba8e341f2229dce77b07effbe9443ba
* Add create dependencies script for gldebugger.Siva Velusamy2011-09-065-92/+76
| | | | | | | | | | | | Move common code from ddms & hierarchy viewer scripts into common_setup.sh, and reuse the same code in create_gldebugger_symlinks. The script copies/soft-links all required dependencies into the libs folder. Update gldebugger project meta data to pick up dependencies from the libs folder. Change-Id: I0c9ccaf01ee43168f6b94bf85b2f42b5fc08ffec
* Pull View Rules API into a separate libraryTor Norbye2011-08-151-1/+1
| | | | | | | | | | | | This changeset pulls out the API classes from the plugin sources and into a separate standalone .jar library. The library depends on the common.jar library. With the separate view API it should be possible to build designtime helpers (view rules) for custom views to improve editing behavior in the layout editor. Change-Id: I20bb511668de2fe52910e5fe0bbd3ec2a18b5a08
* Add Apache Http-Client library files to ADT.Raphael Moll2011-08-113-16/+32
| | | | | | | This is a follow up to Change I084d78dd from prebuilt.git to add the files required by sdklib to ADT. Change-Id: I651ddf8f6dec480843c5bccd7d3296227b262937
* Make the plugin build script for for Mac OSXTor Norbye2011-08-092-4/+19
| | | | | | | | | The build_server script used to build the plugin zip file was Linux specific. This changeset tweaks the scripts such that they will also run on Mac OSX. It also adds various .gitignore filters such that the temporary files created by the build script are ignored by git. Change-Id: I77cfe6bfb65be86c11beb50bcab9c345433b5a8e
* Asset Studio wizardTor Norbye2011-07-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | This is an initial integration of the Android Asset Studio into Eclipse, as a New Asset wizard. It uses the Java port of the Android Asset Studio to generate the assets: https://code.google.com/a/google.com/p/android-asset-studio-java/ It only supports launcher icons, and some of the configurable parameters (file, shape, crop). To run it, put the AssetStudioLib.jar file into the the adt libs directory. There's a new "Asset Set" wizard in the New wizard, which will open up a two page wizard; the first page lets you select the project (which it attempts to pick up from context), as well as the type of asset to create, and the asset output name. In the second page there are the various widgets to tweak the code generator, and a preview area on the right which updates as you tweak the various controls. The main remaining work is to support additional asset types as they are added to the assetstudio generator library. Change-Id: I2e556337f8e5c3bc09e84b35a342ba05110abebc