From eec6791213ffb7817c90bed03493ff878f4f1656 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Wed, 14 Aug 2013 18:01:22 +0000 Subject: [PATCH] Silence some missing attribute settings warnings and fix warning about not loading app.js when it was already loaded --- etemplate/js/et2_extension_nextmatch.js | 18 ++++++++++++++++++ etemplate/js/et2_widget_tree.js | 2 +- etemplate/js/et2_widget_vfs.js | 1 + etemplate/js/etemplate2.js | 2 +- 4 files changed, 21 insertions(+), 2 deletions(-) diff --git a/etemplate/js/et2_extension_nextmatch.js b/etemplate/js/et2_extension_nextmatch.js index 35ba0a3620..61c28c82e9 100644 --- a/etemplate/js/et2_extension_nextmatch.js +++ b/etemplate/js/et2_extension_nextmatch.js @@ -1905,6 +1905,16 @@ et2_register_widget(et2_nextmatch_customfields, ['nextmatch-customfields']); */ var et2_nextmatch_sortheader = et2_nextmatch_header.extend(et2_INextmatchSortable, { + attributes: { + "sortmode": { + "name": "Sort order", + "type": "string", + "description": "Default sort order", + "translate": false + } + }, + legacyOptions: ['sortmode'], + /** * Constructor * @@ -1928,6 +1938,14 @@ var et2_nextmatch_sortheader = et2_nextmatch_header.extend(et2_INextmatchSortabl return false; }, + /** + * Wrapper to join up interface * framework + */ + set_sortmode: function(_mode) + { + this.setSortmode(_mode); + }, + /** * Function which implements the et2_INextmatchSortable function. */ diff --git a/etemplate/js/et2_widget_tree.js b/etemplate/js/et2_widget_tree.js index 0b8ca48ce4..744e3a5f5f 100644 --- a/etemplate/js/et2_widget_tree.js +++ b/etemplate/js/et2_widget_tree.js @@ -91,7 +91,7 @@ var et2_tree = et2_inputWidget.extend( "name": "Standard images", "type": "string", "default": "", - "descripton": "comma-separated names of icons for a leaf, closed and opend folder (default: leaf.gif,folderClosed.gif,folderOpen.gif), images with extension get loaded from image_path, just 'image' or 'appname/image' are allowed too" + "description": "comma-separated names of icons for a leaf, closed and opend folder (default: leaf.gif,folderClosed.gif,folderOpen.gif), images with extension get loaded from image_path, just 'image' or 'appname/image' are allowed too" } }, diff --git a/etemplate/js/et2_widget_vfs.js b/etemplate/js/et2_widget_vfs.js index dac43429af..9fe67ff2b5 100644 --- a/etemplate/js/et2_widget_vfs.js +++ b/etemplate/js/et2_widget_vfs.js @@ -236,6 +236,7 @@ var et2_vfsMime = et2_valueWidget.extend([et2_IDetachedDOM], "description": "Array of (stat) information about the file" }, "size": { + "name": "Icon size", "type": "integer", "description": "Size of icon / thumbnail, in pixels", "default": et2_no_init diff --git a/etemplate/js/etemplate2.js b/etemplate/js/etemplate2.js index af41fe7d04..e1f117520c 100644 --- a/etemplate/js/etemplate2.js +++ b/etemplate/js/etemplate2.js @@ -201,7 +201,7 @@ etemplate2.prototype.load = function(_name, _url, _data, _callback) { (function() { new app[appname]();}).call(); } - else + else if (typeof app[appname] !== "object") { egw.debug("warn", "Did not load '%s' JS object",appname); }