| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
| |
We cannot switch eos-virtual-school to WebKit2-4.0 because of regressions,
but we already committed to using WebHelper2 to localize it. This adds a
version of WebHelper2 that is compatible with WebKit2-3.0.
[endlessm/eos-sdk#3430]
|
|
|
|
|
|
|
|
| |
This adds a local:// URI scheme available to applications using WebHelper
which behaves just like the file:// URI scheme only with fewer security
restrictions.
[endlessm/eos-shell#2309]
|
|
|
|
|
|
|
|
| |
I did not realize that the constructor returned from
Gio.DBus.makeProxyWrapper did a synchronous DBus call unless you passed
it a callback. It should be used asynchronously.
[endlessm/eos-sdk#3296]
|
|
|
|
|
|
|
|
|
|
|
|
| |
Whitespace between words and tags doesn't matter to HTML. Indeed, the
text in a translatable element may be formatted any way over any number
of lines, so we normalize all consecutive whitespace to be just one space
character and strip whitespace from the beginning and end of the strings.
This is so that translators are not confronted with strange newlines and
whitespace on Transifex.
[endlessm/eos-sdk#3291]
|
|
|
|
|
|
| |
This fixes the test suite on my BRIX.
[endlessm/eos-sdk#291]
|
|
|
|
|
|
|
|
|
| |
Instead of starting an idle function when a webview page is created that
waits until the bus connection object is ready before exporting an object
on it, we save all page IDs that we haven't registered yet and instead
register them all at once when the bus is ready.
[endlessm/eos-sdk#291]
|
|
|
|
|
|
|
|
|
| |
This exposes the function set by webhelper.set_ngettext() to the client-
side Javascript as a ngettext() function, defined on the global window
object. This allows apps to translate messages that need to be separated
into singular and plural, just like the C ngettext() function.
[endlessm/eos-sdk#291]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This exposes the function set by webhelper.set_gettext() to the client-
side Javascript as a gettext() function, defined on the global window
object. This allows apps to translate messages that are generated
at runtime, not just messages in static HTML.
Some often-used JavaScriptCore operations can be turned into separate
functions, which we can put in a separate source file. This is in
anticipation of the next commit where we will define another function
property of the global object.
[endlessm/eos-sdk#291]
|
|
|
|
|
|
|
|
|
|
|
| |
This allows communicating with the host program through URIs of the
form webhelper://action?param=value¶m2=value2. Actions can be
defined on the WebHelper object and given a callback in Javascript.
Unfortunately we have to use a private C library to register the URI
scheme, because of https://bugs.webkit.org/show_bug.cgi?id=116672
[endlessm/eos-sdk#291]
|
|
|
|
|
|
|
|
|
|
|
| |
This adds a new Javascript module, WebHelper2. It's the WebKit2 analogue
to WebHelper. It offers a facility for calling gettext() on the contents
of DOM elements in your web page.
It accomplishes this using an extension module that's loaded into
WebKit's web process.
[endlessm/eos-sdk#291]
|
|
|
|
|
|
| |
In the interest of consolidating the makefiles for readability.
[endlessm/eos-sdk#291]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We now provide a new m4 module eos-coverage.m4, which is installed
into the system aclocal directory. This macro provides three
new commands for SDK consumers to use:
EOS_COVERAGE_REPORT([languages]) - Enables a "coverage report".
The first argument is a space separated list of unquoted
languages to collect coverage information for. Valid values
at the moment are "c" and "js". For each language specified,
the macro will check for support for collecting coverage and
enable reporting accordingly. Raw coverage output goes in
$(abs_top_builddir)/_coverage/output/$language accordingly.
The macro then checks to see if a coverage reporter, either
genhtml, or cobertura, is available and enables them. A reporter
must be installed and available for coverage reports to be
generated.
The coverage-genhtml is enabled if lcov is installed and available.
This is generally used by developers themselves as it creates a
self-contained report.
The coverage-covertura is enabled if a program called
lcov-result-merger is installed and a python module called
lcov_cobertura are installed. lcov-result-merger can be
installed from Node Package Manager. lcov_cobertura
can be installed from PyPI.
lcov-result-merger is necessary because each test suite is run
in a separate subprocess and so there will be multiple entries
per source file in the coverage.lcov file generated by gjs.
lcov_cobertura doesn't handle that properly and so the
results need to be merged together properly.
JavaScript Coverage Details
===========================
A variable called EOS_JS_COVERAGE_FILES should be defined
containing a list of all javascript files to be considered
a "part of" the coverage report, before EOS_COVERAGE_RULES
are substituted. For example:
EOS_JS_COVERAGE_FILES = $(SRCS)
@EOS_COVERAGE_RULES@
AM_JS_LOG_FLAGS += @EOS_COVERAGE_JS_LOG_FLAGS@
C/C++ Coverage Details
======================
Certain additions also need to be made for Makefiles where
coverage reporting is enabled on a C project:
@EOS_COVERAGE_RULES@
AM_CFLAGS += @EOS_C_COVERAGE_CFLAGS@
AM_LDFLAGS += @EOS_C_COVERAGE_LDFLAGS@
If a target's CFLAGS is overridden and AM_CFLAGS is not used,
then @EOS_C_COVERAGE_CFLAGS@ must be added to its CFLAGS.
Blacklisting patterns
=====================
If a path should not appear in the coverage report, then it can
be blacklisted by adding a glob expression to
EOS_COVERAGE_BLACKLIST_PATTERNS.
Clean rules
===========
A clean-coverage target is added to the dependencies for
the clean-local target automatically by EOS_COVERAGE_RULES.
[endlessm/eos-shell#2264]
|
|
|
|
|
|
| |
Added a publicly available calculated font size property. This allows Endless applications to perform actions based on the calculated font size of an EosWindow. In particular, the WebHelper application now uses the property to update the 'default-font-size' property of a WebSettings object.
[endlessm/eos-sdk#484]
|
|
|
|
|
|
| |
A few formatting improvements
[endlessm/eos-sdk#310]
|
|
|
|
|
|
| |
Previously, it wasn't imported
[endlessm/eos-sdk#310]
|
|
|
|
|
|
|
| |
In case the name of the web action is URIencoded, make sure to URIdecode
it before looking it up in the dictionary of defined web actions.
[endlessm/eos-sdk#310]
|
|
|
|
|
|
|
|
|
| |
- Replace _webActions with define_web_action() method and another
define_web_actions() method for the Endless.js overrides file
- Replace _translationFunction with set_translation_function() and
get_translation_function()
[endlessm/eos-sdk#310]
|
|
|
|
|
|
|
|
| |
This adds the infrastructure for autogenerating HTML documentation from a
Javascript module using NaturalDocs, and then adds documentation comments
to webhelper.js.
[endlessm/eos-sdk#302]
|
|
|
|
|
|
|
|
| |
Previously, the translation was such that it did a dummy translation,
italicizing the text to be translated. Now it looks for a translationFunction
property on the app object, and calls that on the text.
[endlessm/eos-sdk#290]
|
|
|
|
|
|
|
| |
- Move normal URI test to the top
- Throw an exception if a nonexistent web action is called.
[endlessm/eos-sdk#290]
|
|
|
|
|
|
|
|
| |
Also, since the functions will likely be translated into C in the
future, give_them_underscored_names insteadOfCamelCase, in order to
avoid API changes.
[endlessm/eos-sdk#290]
|
|
WebHelper is now importable using
const WebHelper = imports.webhelper;
[endlessm/eos-sdk#289]
|