mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-24 00:21:30 +00:00
upgrade Dojo to 1.6.1
This commit is contained in:
@@ -1,27 +1,80 @@
|
||||
/*
|
||||
Copyright (c) 2004-2010, The Dojo Foundation All Rights Reserved.
|
||||
Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved.
|
||||
Available via Academic Free License >= 2.1 OR the modified BSD license.
|
||||
see: http://dojotoolkit.org/license for details
|
||||
*/
|
||||
|
||||
|
||||
if(!dojo._hasResource["dijit._DialogMixin"]){
|
||||
dojo._hasResource["dijit._DialogMixin"]=true;
|
||||
if(!dojo._hasResource["dijit._DialogMixin"]){ //_hasResource checks added by build. Do not use _hasResource directly in your code.
|
||||
dojo._hasResource["dijit._DialogMixin"] = true;
|
||||
dojo.provide("dijit._DialogMixin");
|
||||
dojo.require("dijit._Widget");
|
||||
dojo.declare("dijit._DialogMixin",null,{attributeMap:dijit._Widget.prototype.attributeMap,execute:function(_1){
|
||||
},onCancel:function(){
|
||||
},onExecute:function(){
|
||||
},_onSubmit:function(){
|
||||
this.onExecute();
|
||||
this.execute(this.get("value"));
|
||||
},_getFocusItems:function(_2){
|
||||
var _3=dijit._getTabNavigable(dojo.byId(_2));
|
||||
this._firstFocusItem=_3.lowest||_3.first||_2;
|
||||
this._lastFocusItem=_3.last||_3.highest||this._firstFocusItem;
|
||||
if(dojo.isMoz&&this._firstFocusItem.tagName.toLowerCase()=="input"&&dojo.getNodeProp(this._firstFocusItem,"type").toLowerCase()=="file"){
|
||||
dojo.attr(_2,"tabIndex","0");
|
||||
this._firstFocusItem=_2;
|
||||
}
|
||||
}});
|
||||
|
||||
|
||||
dojo.declare("dijit._DialogMixin", null,
|
||||
{
|
||||
// summary:
|
||||
// This provides functions useful to Dialog and TooltipDialog
|
||||
|
||||
attributeMap: dijit._Widget.prototype.attributeMap,
|
||||
|
||||
execute: function(/*Object*/ formContents){
|
||||
// summary:
|
||||
// Callback when the user hits the submit button.
|
||||
// Override this method to handle Dialog execution.
|
||||
// description:
|
||||
// After the user has pressed the submit button, the Dialog
|
||||
// first calls onExecute() to notify the container to hide the
|
||||
// dialog and restore focus to wherever it used to be.
|
||||
//
|
||||
// *Then* this method is called.
|
||||
// type:
|
||||
// callback
|
||||
},
|
||||
|
||||
onCancel: function(){
|
||||
// summary:
|
||||
// Called when user has pressed the Dialog's cancel button, to notify container.
|
||||
// description:
|
||||
// Developer shouldn't override or connect to this method;
|
||||
// it's a private communication device between the TooltipDialog
|
||||
// and the thing that opened it (ex: `dijit.form.DropDownButton`)
|
||||
// type:
|
||||
// protected
|
||||
},
|
||||
|
||||
onExecute: function(){
|
||||
// summary:
|
||||
// Called when user has pressed the dialog's OK button, to notify container.
|
||||
// description:
|
||||
// Developer shouldn't override or connect to this method;
|
||||
// it's a private communication device between the TooltipDialog
|
||||
// and the thing that opened it (ex: `dijit.form.DropDownButton`)
|
||||
// type:
|
||||
// protected
|
||||
},
|
||||
|
||||
_onSubmit: function(){
|
||||
// summary:
|
||||
// Callback when user hits submit button
|
||||
// type:
|
||||
// protected
|
||||
this.onExecute(); // notify container that we are about to execute
|
||||
this.execute(this.get('value'));
|
||||
},
|
||||
|
||||
_getFocusItems: function(){
|
||||
// summary:
|
||||
// Finds focusable items in dialog,
|
||||
// and sets this._firstFocusItem and this._lastFocusItem
|
||||
// tags:
|
||||
// protected
|
||||
|
||||
var elems = dijit._getTabNavigable(this.containerNode);
|
||||
this._firstFocusItem = elems.lowest || elems.first || this.closeButtonNode || this.domNode;
|
||||
this._lastFocusItem = elems.last || elems.highest || this._firstFocusItem;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user