Commit Graph

45 Commits

Author SHA1 Message Date
Éric Lemoine
ca332a3fef Minor fix to the generate-exports.py script
Now that we correctly export the ol.animation.*, ol.easing.* and ol.coordinate.* symbols we can make the generate-exports.py script work for more cases.
2013-05-09 22:46:08 +02:00
Éric Lemoine
aa5a571ab1 Always set CLOSURE_NO_DEPS to true 2013-04-30 09:25:09 +02:00
Tom Payne
baf8cc49a1 Avoid generating long lines in exports 2013-04-23 15:29:17 +02:00
Tom Payne
1d5431226e Use objectliterals.jsdoc instead of objectliterals.exports 2013-04-07 18:00:11 +02:00
Tom Payne
4d1ec1ff90 Remove (mostly unused) logger 2013-04-06 17:32:41 +02:00
Tom Payne
8073be7f3a Update examples URL to openlayers.github.io 2013-04-06 14:21:16 +02:00
Éric Lemoine
b87fcbb4c4 Move hosted examples loader our of build dir
The build dir is now empty, and therefore unexisting for Git.
2013-03-29 16:17:38 +01:00
Éric Lemoine
0ae47403ee Merge pull request #398 from elemoine/nestedoptions
Support nested options objects
2013-03-20 10:45:37 -07:00
Éric Lemoine
0b403c767a Fix goog.provide for object literals 2013-03-20 18:43:02 +01:00
Éric Lemoine
02d8d9e0bc Support nested options objects
This commit extends the generated Export constructors to support nested options objects. For example, this is now supported:

@exportObjectLiteralProperty ol.MapOptions.view ol.View|ol.View2DOptions|undefined

This specifies that the "view" property in the map options can reference an ol.View instance, an ol.View2DOptions literal object, or undefined. If the "view" property references an ol.View2DOptions literal object the ol.MapExport constructor will create an ol.View2DExport instance, and pass it to the parent constructor, ol.Map. In this way, extern types never cross the external/internal boundary. In other words, translations from non-renamed to renamed objects remain confined to the generated Export constructors.
2013-03-20 18:43:02 +01:00
Tim Schaub
462659a9fc Use index.html instead of example-list.html
The original decision to avoid index.html was because it only works with a build step.  Since we've all accepted a build step, the more sensible name is index.html.  Without this change, every hosted example has a link to http://openlayers.github.com/ol3/master/examples/example-list.html which 404s.
2013-03-19 12:17:00 -06:00
Éric Lemoine
392735c823 Merge pull request #384 from elemoine/optional
Exports fixes
2013-03-15 14:26:05 -07:00
Éric Lemoine
1f641c5933 Make the generated Export classes accept undefined
We have constructors, like ol.View2D and ol.control.Attribution, whose "options" argument is optional (opt_options). But currently, we cannot do "new ol.View2D()" in uncompiled code that uses an ol3 build compiled in advanced mode. This commit fixes that by changing the generated Export constructors.
2013-03-15 18:01:53 +01:00
Marc Jansen
92a358967f Restrict progressbar to fixed width.
As more and more examples will be processed with this script, the
progresbar would grow way too long. This commit makes the width of
the bar fixed. Every character in the bar now equals 5% progress,
regardless of the number of examples.
2013-03-15 11:43:50 +01:00
Marc Jansen
24d3c903fe Reformatted and gjslinted example-screenshot.js. 2013-03-15 11:40:55 +01:00
Marc Jansen
2b4545e221 Ignore fewer files and clip correctly. 2013-03-13 16:09:05 +01:00
Marc Jansen
3a863ddf3e Add a screenshot script for our examples.
This script is supposed to be executed via phantomjs. It will generate
screenshots of the html files in the directory specified by a commandline
option when these files are served through a webserver which can also be
specified. The screenshots will be saved in the passed directory.

Example usage:

    user@host:~/ol3/bin $ phantomjs example-screenshot.js \
                          http://localhost:8000/ol3/examples/ \
                          ../examples/

The above command will generate `*html.png` files in `tools/` for all html files
that are served through `http://localhost:8000/ol3/examples/`.

So if there is a file `my-humpty-example.html` inside of the relative folder
`../examples/` which is being served through the webserver so that
`http://localhost:8000/ol3/examples/my-humpty-example.html` is a valid and
reachable URL, this script will generate a screenshot and store it as
`../examples/my-humpty-example.html.png`.

The query string `?mode=raw` will be appended to the generated URL.

Known limitations:

As phantomjs doesn't support WebGL (see e.g.
https://github.com/ariya/phantomjs/wiki/Supported-Web-Standards and
http://code.google.com/p/phantomjs/issues/detail?id=273) This won't render
OpenLayers maps rendered through the webglrenderer.

In parts based upon this gist: https://gist.github.com/crazy4groovy/3160121
2013-03-13 15:50:55 +01:00
Éric Lemoine
8ce86ac2c9 Add depswriter scripts
Copied from http://closure-library.googlecode.com/git/closure/bin/build/
2013-03-06 19:16:03 +01:00
Éric Lemoine
337fd11a05 Load the examples using PhantomJS
This commit adds a check-examples target to check that the hosted examples load without errors.
2013-03-03 19:46:09 +01:00
Tom Payne
3e420313a2 Only require things that start with a capital letter 2013-03-03 13:08:34 +01:00
Tom Payne
ad983a5e68 Add missing semicolon from exampleparser output 2013-01-03 11:52:26 +01:00
Tom Payne
874a311de2 Fix bug where all examples were assumed to be under version control 2013-01-03 11:31:31 +01:00
Frederic Junod
14f7b9a41e git-update-ghpages removed, bin/readme.md no longer necessary 2012-11-14 12:50:13 +01:00
Tom Payne
bf4e7bcb70 Work around broken operating systems 2012-11-09 11:45:58 +01:00
Tom Payne
bf231d0c41 Fold gh-update-pages into build.py
This also fixes a bug in gh-update-pages: gh-update-pages does not
handle file deletition, meaning that stale files are never removed.
2012-11-04 19:08:56 +01:00
Tom Payne
d30be0fb93 Merge bin/generate-requireall into build.py 2012-11-04 19:08:55 +01:00
Éric Lemoine
3e3b8d6f8b Use OpenLayers 2 examples index 2012-10-19 21:56:59 +02:00
Tom Payne
f120410d6d Add option to hook in scripts to index generator 2012-10-17 11:29:41 +02:00
Tom Payne
7f39f1d32d Add script to generate example index 2012-10-17 11:13:01 +02:00
Tom Payne
b45c2ca4bc Add optional argument to @exportSymbol 2012-10-15 19:11:51 +02:00
Tom Payne
9d253ab6bb Refactor exports and externs 2012-10-04 15:11:26 +02:00
Tom Payne
64d0954b69 Remove Type suffix in auto-generated namespaces, thanks @elemoine 2012-09-30 15:10:15 +02:00
Tom Payne
f9b791b2f5 Correct generation of externs for nested namespaces 2012-09-29 15:35:25 +02:00
Tom Payne
8387f74a7b Generate exports automatically from src/ol/exports.txt 2012-09-29 15:17:40 +02:00
Tom Payne
c7c93ce099 Consistent nomenclature 2012-09-29 14:42:12 +02:00
Tom Payne
9494321c91 Use a Python script to generate requireall.js
This is needed to work around platform variations in the sort command.
2012-09-29 12:31:31 +02:00
Tom Payne
71e42b2448 Refactor build system
This rather large commit refactors the build system to solve a number of
problems:
- Object literal types are now declared in just one place
- There are no more circular dependencies
- There is no need for concealed subclasses in build-standalone mode

When building in standalone mode, you need to include the source in
build/src/external.  This declares object literal types as externs so
that their properties are not renamed.

When building with the application, you need to include the source in
build/src/internal.  This declares object literal types as typedefs so
that their properties can be renamed and removed.

Note also that ol.MapOptions has been merged into ol.Map, with some
renaming.
2012-09-29 11:51:53 +02:00
Tom Payne
b6c06f4760 Generate externs and typedefs 2012-09-28 21:55:48 +02:00
Éric Lemoine
9d8155cf9f Move git-update-ghpages from tools to bin 2012-09-28 16:31:45 +02:00
Éric Lemoine
6cf964b3ae Remove old build files 2012-09-28 16:30:06 +02:00
Tom Payne
67105b0256 Don't discard Plovr version 2012-07-11 17:12:38 +02:00
Tim Schaub
795f8b854d Adding instructions for build utilities. 2012-06-23 14:10:25 +02:00
Tim Schaub
a1fcb4e065 Build with an arbitrary configuration. 2012-06-23 13:55:06 +02:00
Petr Pridal
e10a845058 Advanced compilation of the API with 'bin/ol api' 2012-06-22 01:32:29 +02:00
Tim Schaub
54b8ebacaf OS neutral dev tools. 2012-06-20 00:41:28 +02:00