mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-25 14:41:50 +01:00
fixed space instead of tabs
This commit is contained in:
parent
a15e7d31b1
commit
28aab234a7
@ -359,32 +359,32 @@ var et2_DOMWidget = et2_widget.extend(et2_IDOMNode,
|
|||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set Actions on the widget
|
* Set Actions on the widget
|
||||||
*
|
|
||||||
* Each action is defined as an object:
|
|
||||||
*
|
*
|
||||||
* move: {
|
* Each action is defined as an object:
|
||||||
* type: "drop",
|
*
|
||||||
* acceptedTypes: "mail",
|
* move: {
|
||||||
* icon: "move",
|
* type: "drop",
|
||||||
* caption: "Move to"
|
* acceptedTypes: "mail",
|
||||||
* onExecute: javascript:mail_move"
|
* icon: "move",
|
||||||
* }
|
* caption: "Move to"
|
||||||
*
|
* onExecute: javascript:mail_move"
|
||||||
* This will turn the widget into a drop target for "mail" drag types. When "mail" drag types are dropped,
|
* }
|
||||||
* the global function mail_move(egwAction action, egwActionObject sender) will be called. The ID of the
|
*
|
||||||
* dragged "mail" will be in sender.id, some information about the sender will be in sender.context. The
|
* This will turn the widget into a drop target for "mail" drag types. When "mail" drag types are dropped,
|
||||||
|
* the global function mail_move(egwAction action, egwActionObject sender) will be called. The ID of the
|
||||||
|
* dragged "mail" will be in sender.id, some information about the sender will be in sender.context. The
|
||||||
* etemplate2 widget involved can typically be found in action.parent.data.widget, so your handler
|
* etemplate2 widget involved can typically be found in action.parent.data.widget, so your handler
|
||||||
* can operate in the widget context easily. The location varies depending on your action though. It
|
* can operate in the widget context easily. The location varies depending on your action though. It
|
||||||
* might be action.parent.parent.data.widget
|
* might be action.parent.parent.data.widget
|
||||||
*
|
*
|
||||||
* To customise how the actions are handled for a particular widget, override _link_actions(). It handles
|
* To customise how the actions are handled for a particular widget, override _link_actions(). It handles
|
||||||
* the more widget-specific parts.
|
* the more widget-specific parts.
|
||||||
*
|
*
|
||||||
* @param Object {ID: {attributes..}+} map of egw action information
|
* @param Object {ID: {attributes..}+} map of egw action information
|
||||||
* @see etemplate/inc/class.etemplate_widget_nextmatch->egw_actions()
|
* @see etemplate/inc/class.etemplate_widget_nextmatch->egw_actions()
|
||||||
*/
|
*/
|
||||||
set_actions: function(actions)
|
set_actions: function(actions)
|
||||||
{
|
{
|
||||||
if(this.id == "" || typeof this.id == "undefined")
|
if(this.id == "" || typeof this.id == "undefined")
|
||||||
{
|
{
|
||||||
@ -393,27 +393,27 @@ var et2_DOMWidget = et2_widget.extend(et2_IDOMNode,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Initialize the action manager and add some actions to it
|
// Initialize the action manager and add some actions to it
|
||||||
var gam = egw_getAppActionManager();
|
var gam = egw_getAppActionManager();
|
||||||
this._actionManager = gam.addAction("actionManager", this.id);
|
this._actionManager = gam.addAction("actionManager", this.id);
|
||||||
// ActionManager wants an array
|
// ActionManager wants an array
|
||||||
var parsed_actions = [];
|
var parsed_actions = [];
|
||||||
if(typeof actions == "object" && actions)
|
if(typeof actions == "object" && actions)
|
||||||
{
|
{
|
||||||
for(var key in actions)
|
for(var key in actions)
|
||||||
{
|
{
|
||||||
actions[key].id = key;
|
actions[key].id = key;
|
||||||
if(typeof actions[key].icon != "undefined" && actions[key].icon)
|
if(typeof actions[key].icon != "undefined" && actions[key].icon)
|
||||||
{
|
{
|
||||||
actions[key].iconUrl = this.egw().image(actions[key].icon);
|
actions[key].iconUrl = this.egw().image(actions[key].icon);
|
||||||
}
|
}
|
||||||
parsed_actions.push(actions[key]);
|
parsed_actions.push(actions[key]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
parsed_actions = actions;
|
parsed_actions = actions;
|
||||||
}
|
}
|
||||||
this._actionManager.updateActions(parsed_actions);
|
this._actionManager.updateActions(parsed_actions);
|
||||||
|
|
||||||
// Put a reference to the widget into the action stuff, so we can
|
// Put a reference to the widget into the action stuff, so we can
|
||||||
// easily get back to widget context from the action handler
|
// easily get back to widget context from the action handler
|
||||||
|
Loading…
Reference in New Issue
Block a user