From dedded529403b72bc00b373e8bdcc16da97cd73c Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Mon, 12 Sep 2011 13:34:37 +0200 Subject: [PATCH] [FIX] a few more existing jsdoc so jsdoc v3 does not blow up during parsing bzr revid: xmo@openerp.com-20110912113437-emv28eo9ct9n559g --- addons/web/static/src/js/chrome.js | 87 +++++++++++++++---- addons/web/static/src/js/form.js | 4 +- addons/web/static/src/js/list-editable.js | 3 +- addons/web/static/src/js/list.js | 18 ++-- addons/web/static/src/js/search.js | 12 +-- .../web_dashboard/static/src/js/dashboard.js | 3 +- 6 files changed, 98 insertions(+), 29 deletions(-) diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index d58dadac210..97621296382 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -5,7 +5,14 @@ openerp.web.chrome = function(openerp) { var QWeb = openerp.web.qweb; -openerp.web.Notification = openerp.web.Widget.extend({ +openerp.web.Notification = openerp.web.Widget.extend(/** @lends openerp.web.Notification# */{ + /** + * @constructs openerp.web.Notification + * @extends openerp.web.Widget + * + * @param parent + * @param element_id + */ init: function(parent, element_id) { this._super(parent, element_id); this.$element.notify({ @@ -27,9 +34,16 @@ openerp.web.Notification = openerp.web.Widget.extend({ } }); -openerp.web.Dialog = openerp.web.OldWidget.extend({ +openerp.web.Dialog = openerp.web.OldWidget.extend(/** @lends openerp.web.Dialog# */{ dialog_title: "", identifier_prefix: 'dialog', + /** + * @constructs openerp.web.Dialog + * @extends openerp.web.OldWidget + * + * @param parent + * @param dialog_options + */ init: function (parent, dialog_options) { var self = this; this._super(parent); @@ -118,8 +132,14 @@ openerp.web.Dialog = openerp.web.OldWidget.extend({ } }); -openerp.web.CrashManager = openerp.web.Dialog.extend({ +openerp.web.CrashManager = openerp.web.Dialog.extend(/** @lends openerp.web.CrashManager# */{ identifier_prefix: 'dialog_crash', + /** + * @constructs opener.web.CrashManager + * @extends openerp.web.Dialog + * + * @param parent + */ init: function(parent) { this._super(parent); this.session.on_rpc_error.add(this.on_rpc_error); @@ -154,7 +174,14 @@ openerp.web.CrashManager = openerp.web.Dialog.extend({ } }); -openerp.web.Loading = openerp.web.Widget.extend({ +openerp.web.Loading = openerp.web.Widget.extend(/** @lends openerp.web.Loading# */{ + /** + * @constructs openerp.web.Loading + * @extends openerp.web.Widget + * + * @param parent + * @param element_id + */ init: function(parent, element_id) { this._super(parent, element_id); this.count = 0; @@ -173,7 +200,15 @@ openerp.web.Loading = openerp.web.Widget.extend({ } }); -openerp.web.Database = openerp.web.Widget.extend({ +openerp.web.Database = openerp.web.Widget.extend(/** @lends openerp.web.Database# */{ + /** + * @constructs openerp.web.Database + * @extends openerp.web.Widget + * + * @param parent + * @param element_id + * @param option_id + */ init: function(parent, element_id, option_id) { this._super(parent, element_id); this.$option_id = $('#' + option_id); @@ -427,9 +462,15 @@ openerp.web.Database = openerp.web.Widget.extend({ } }); -openerp.web.Login = openerp.web.Widget.extend({ +openerp.web.Login = openerp.web.Widget.extend(/** @lends openerp.web.Login# */{ remember_creditentials: true, - + /** + * @constructs openerp.web.Login + * @extends openerp.web.Widget + * + * @param parent + * @param element_id + */ init: function(parent, element_id) { this._super(parent, element_id); this.has_local_storage = typeof(localStorage) != 'undefined'; @@ -527,9 +568,15 @@ openerp.web.Login = openerp.web.Widget.extend({ } }); -openerp.web.Header = openerp.web.Widget.extend({ +openerp.web.Header = openerp.web.Widget.extend(/** @lends openerp.web.Header# */{ template: "Header", identifier_prefix: 'oe-app-header-', + /** + * @constructs openerp.web.Header + * @extends openerp.web.Widget + * + * @param parent + */ init: function(parent) { this._super(parent); this.qs = "?" + jQuery.param.querystring(); @@ -711,7 +758,15 @@ openerp.web.Header = openerp.web.Widget.extend({ } }); -openerp.web.Menu = openerp.web.Widget.extend({ +openerp.web.Menu = openerp.web.Widget.extend(/** @lends openerp.web.Menu# */{ + /** + * @constructs openerp.web.Menu + * @extends openerp.web.Widget + * + * @param parent + * @param element_id + * @param secondary_menu_id + */ init: function(parent, element_id, secondary_menu_id) { this._super(parent, element_id); this.secondary_menu_id = secondary_menu_id; @@ -793,13 +848,13 @@ openerp.web.Menu = openerp.web.Widget.extend({ } }); -openerp.web.Homepage = openerp.web.Widget.extend({ -}); - -openerp.web.Preferences = openerp.web.Widget.extend({ -}); - -openerp.web.WebClient = openerp.web.Widget.extend({ +openerp.web.WebClient = openerp.web.Widget.extend(/** @lends openerp.web.WebClient */{ + /** + * @constructs openerp.web.WebClient + * @extends openerp.web.Widget + * + * @param element_id + */ init: function(element_id) { this._super(null, element_id); openerp.webclient = this; diff --git a/addons/web/static/src/js/form.js b/addons/web/static/src/js/form.js index 18947d1b788..4a60f25e3ae 100644 --- a/addons/web/static/src/js/form.js +++ b/addons/web/static/src/js/form.js @@ -12,7 +12,9 @@ openerp.web.FormView = openerp.web.View.extend( /** @lends openerp.web.FormView# searchable: false, template: "FormView", /** - * @constructs + * @constructs openerp.web.FormView + * @extends openerp.web.View + * * @param {openerp.web.Session} session the current openerp session * @param {String} element_id this view's root element id * @param {openerp.web.DataSet} dataset the dataset this view will work with diff --git a/addons/web/static/src/js/list-editable.js b/addons/web/static/src/js/list-editable.js index 7b41b22e2f7..bcf6d4edac2 100644 --- a/addons/web/static/src/js/list-editable.js +++ b/addons/web/static/src/js/list-editable.js @@ -1,5 +1,6 @@ /** - * @namespace handles editability case for lists, because it depends on form and forms already depends on lists it had to be split out + * handles editability case for lists, because it depends on form and forms already depends on lists it had to be split out + * @namespace */ openerp.web.list_editable = function (openerp) { var KEY_RETURN = 13, diff --git a/addons/web/static/src/js/list.js b/addons/web/static/src/js/list.js index 74f6d7b92e5..7ee762e06e5 100644 --- a/addons/web/static/src/js/list.js +++ b/addons/web/static/src/js/list.js @@ -27,7 +27,9 @@ openerp.web.ListView = openerp.web.View.extend( /** @lends openerp.web.ListView# * See constructor parameters and method documentations for information on * the default behaviors and possible options for the list view. * - * @constructs + * @constructs openerp.web.ListView + * @extends openerp.web.View + * * @param parent parent object * @param element_id the id of the DOM elements this view should link itself to * @param {openerp.web.DataSet} dataset the dataset the view should work with @@ -674,7 +676,9 @@ openerp.web.ListView.List = openerp.web.Class.extend( /** @lends openerp.web.Lis * Triggered when a row of the table is clicked, provides the index (in * the rows array) and id of the selected record to the handle function. * - * @constructs + * @constructs openerp.web.ListView.List + * @extends openerp.web.Class + * * @param {Object} opts display options, identical to those of :js:class:`openerp.web.ListView` */ init: function (group, opts) { @@ -879,7 +883,9 @@ openerp.web.ListView.Groups = openerp.web.Class.extend( /** @lends openerp.web.L * Provides events similar to those of * :js:class:`~openerp.web.ListView.List` * - * @constructs + * @constructs openerp.web.ListView.Groups + * @extends openerp.web.Class + * * @param {openerp.web.ListView} view * @param {Object} [options] * @param {Collection} [options.records] @@ -1265,8 +1271,9 @@ var Events = { }; var Record = openerp.web.Class.extend(/** @lends Record# */{ /** - * @constructs + * @constructs Record * @extends openerp.web.Class + * * @borrows Events#bind as this.bind * @borrows Events#trigger as this.trigger * @param {Object} [data] @@ -1332,8 +1339,9 @@ var Collection = openerp.web.Class.extend(/** @lends Collection# */{ * Using a "dumb" array of records makes synchronization between the * various serious * - * @constructs + * @constructs Collection * @extends openerp.web.Class + * * @borrows Events#bind as this.bind * @borrows Events#trigger as this.trigger * @param {Array} [records] records to initialize the collection with diff --git a/addons/web/static/src/js/search.js b/addons/web/static/src/js/search.js index 272e96b7d01..e82ab09b9e1 100644 --- a/addons/web/static/src/js/search.js +++ b/addons/web/static/src/js/search.js @@ -380,7 +380,9 @@ openerp.web.search.Invalid = openerp.web.Class.extend( /** @lends openerp.web.se * Exception thrown by search widgets when they hold invalid values, * which they can not return when asked. * - * @constructs + * @constructs openerp.web.search.Invalid + * @extends openerp.web.Class + * * @param field the name of the field holding an invalid value * @param value the invalid value * @param message validation failure message @@ -400,7 +402,7 @@ openerp.web.search.Widget = openerp.web.Widget.extend( /** @lends openerp.web.se /** * Root class of all search widgets * - * @constructs + * @constructs openerp.web.search.Widget * @extends openerp.web.Widget * * @param view the ancestor view of this widget @@ -494,7 +496,7 @@ openerp.web.search.Group = openerp.web.search.Widget.extend({ openerp.web.search.Input = openerp.web.search.Widget.extend( /** @lends openerp.web.search.Input# */{ /** - * @constructs + * @constructs openerp.web.search.Input * @extends openerp.web.search.Widget * * @param view @@ -566,7 +568,7 @@ openerp.web.search.Field = openerp.web.search.Input.extend( /** @lends openerp.w template: 'SearchView.field', default_operator: '=', /** - * @constructs + * @constructs openerp.web.search.Field * @extends openerp.web.search.Input * * @param view_section @@ -694,7 +696,7 @@ openerp.web.search.SelectionField = openerp.web.search.Field.extend(/** @lends o }); openerp.web.search.BooleanField = openerp.web.search.SelectionField.extend(/** @lends openerp.web.search.BooleanField# */{ /** - * @constructs + * @constructs openerp.web.search.BooleanField * @extends openerp.web.search.BooleanField */ init: function () { diff --git a/addons/web_dashboard/static/src/js/dashboard.js b/addons/web_dashboard/static/src/js/dashboard.js index 5662a88fc5b..854a3cd9195 100644 --- a/addons/web_dashboard/static/src/js/dashboard.js +++ b/addons/web_dashboard/static/src/js/dashboard.js @@ -379,8 +379,9 @@ openerp.web_dashboard.Widget = openerp.web.View.extend(/** @lends openerp.web_da * Initializes a "HomeWidget" client widget: handles the display of a given * res.widget objects in an OpenERP view (mainly a dashboard). * - * @constructs + * @constructs openerp.web_dashboard.Widget * @extends openerp.web.View + * * @param {Object} parent * @param {Object} options * @param {Number} options.widget_id