diff options
author | Mario Sanchez Prada <mario@endlessm.com> | 2015-09-16 18:42:09 +0100 |
---|---|---|
committer | Mario Sanchez Prada <mario@endlessm.com> | 2015-09-16 18:42:09 +0100 |
commit | 2eae43fed2b86aff76523e6e6e8e8ef7b9de1173 (patch) | |
tree | 083b8f1c2772378ca8e7a597a021518d250aba8d | |
parent | bcf429e0d05fc36e9fbc4900d00cc3fdd9a390f8 (diff) |
Update documentation relative to the creation of the WebHelper object
Suggest creating it in vfunc_startup instead of in vfunc_dbus_register,
to avoid race conditions that might lead to disaster.
[endlessm/eos-shell#5749]
-rw-r--r-- | webhelper/webhelper_private/common.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/webhelper/webhelper_private/common.js b/webhelper/webhelper_private/common.js index 4a93d53..9925c97 100644 --- a/webhelper/webhelper_private/common.js +++ b/webhelper/webhelper_private/common.js @@ -79,11 +79,11 @@ const WH2_DBUS_MAIN_PROGRAM_INTERFACE = '\ * Constructor parameters: * props - a dictionary of construction properties and values (default {}) * - * The application class for your web application should create <WebHelper> in - * its *vfunc_dbus_register()* implementation, with appropriate - * <well-known-name> and <connection> parameters. - * After that, you can do further setup on it, such as defining web actions, in - * your *vfunc_startup()* implementation. + * The application class for your web application should create <WebHelper> after + * registering itself in the session bus (i.e. not inside *vfunc_dbus_register()*), + * with appropriate <well-known-name> and <connection> parameters. + * A good place to do this would be in your *vfunc_startup()* implementation, where + * you can also do further setup on it, such as defining web actions. * * There is no need to set up specially any web views that you create, unlike * WebKit1 where you must set up <Application.web_actions_handler()>. |