Ignore:
Timestamp:
07/01/13 03:34:23 (12 years ago)
Author:
hendrikvanantwerpen
Message:

Fixed deploy script.
Fix for ... in ... complaints by jshint.
Fix a typo.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Dev/trunk/src/client/qed-client/widgets/Selector.js

    r443 r472  
    5757            if ( this.selectedActions !== null ) {
    5858                for (var actionName in this.selectedActions) {
    59                     action = this.selectedActions[actionName];
    60                     actions[actionName] = {
    61                         callback: action.callback &&
    62                                 lang.hitch(this,this._onSelectedAction,
    63                                         action.callback),
    64                         properties: {
    65                             blockButton: true,
    66                             label: action.title || actionName,
    67                             icon: action.icon,
    68                             tooltip: action.description
    69                         }
    70 
    71                     };
     59                    if ( this.selectedActions.hasOwnProperty(actionName) ) {
     60                        action = this.selectedActions[actionName];
     61                        actions[actionName] = {
     62                            callback: action.callback &&
     63                                    lang.hitch(this,this._onSelectedAction,
     64                                            action.callback),
     65                            properties: {
     66                                blockButton: true,
     67                                label: action.title || actionName,
     68                                icon: action.icon,
     69                                tooltip: action.description
     70                            }
     71
     72                        };
     73                    }
    7274                }
    7375            }
     
    180182            if (this.itemActions) {
    181183                for (var actionName in this.itemActions) {
    182                     action = this.itemActions[actionName];
    183                     actions[actionName] = {
    184                         callback: action.callback && lang.partial(action.callback,item),
    185                         properties: {
    186                             blockButton: false,
    187                             showLabel: false,
    188                             icon: action.icon + " black",
    189                             tooltip: action.description
    190                         }
    191                     };
     184                    if ( this.itemActions.hasOwnProperty(actionName) ) {
     185                        action = this.itemActions[actionName];
     186                        actions[actionName] = {
     187                            callback: action.callback && lang.partial(action.callback,item),
     188                            properties: {
     189                                blockButton: false,
     190                                showLabel: false,
     191                                icon: action.icon + " black",
     192                                tooltip: action.description
     193                            }
     194                        };
     195                    }
    192196                }
    193197            }
Note: See TracChangeset for help on using the changeset viewer.