code stringlengths 1 2.08M | language stringclasses 1
value |
|---|---|
/**
* @class Ext.Action
* <p>An Action is a piece of reusable functionality that can be abstracted out of any particular component so that it
* can be usefully shared among multiple components. Actions let you share handlers, configuration options and UI
* updates across any components that support the Action inte... | JavaScript |
/**
* @class Ext.Template
* <p>Represents an HTML fragment template. Templates may be {@link #compile precompiled}
* for greater performance.</p>
* An instance of this class may be created by passing to the constructor either
* a single argument, or multiple arguments:
* <div class="mdetail-params"><ul>
* <li><b... | JavaScript |
/**
* @class Ext.window.Window
* @extends Ext.panel.Panel
* <p>A specialized panel intended for use as an application window. Windows are floated, {@link #resizable}, and
* {@link #draggable} by default. Windows can be {@link #maximizable maximized} to fill the viewport,
* restored to their prior size, and can b... | JavaScript |
/**
* @class Ext.window.MessageBox
* @extends Ext.window.Window
Utility class for generating different styles of message boxes. The singleton instance, `Ext.Msg` can also be used.
Note that a MessageBox is asynchronous. Unlike a regular JavaScript `alert` (which will halt
browser execution), showing a MessageBox w... | JavaScript |
/**
* @class Ext.Window
* @ignore
*/
Ext.Window.override({
/**
* Anchors this window to another element and realigns it when the window is resized or scrolled.
* @param {Mixed} element The element to align to.
* @param {String} position The position to align to (see {@link Ext.core.Element#alignTo... | JavaScript |
/**
* @class Ext.Shadow
* Simple class that can provide a shadow effect for any element. Note that the element MUST be absolutely positioned,
* and the shadow does not provide any shimming. This should be used only in simple cases -- for more advanced
* functionality that can also provide the same shadow effect, ... | JavaScript |
/**
* @class Ext.button.Button
* @extends Ext.Component
Create simple buttons with this component. Customisations include {@link #config-iconAlign aligned}
{@link #config-iconCls icons}, {@link #config-menu dropdown menus}, {@link #config-tooltip tooltips}
and {@link #config-scale sizing options}. Specify a {@link #... | JavaScript |
/**
* @class Ext.button.Cycle
* @extends Ext.button.Split
* A specialized SplitButton that contains a menu of {@link Ext.menu.CheckItem} elements. The button automatically
* cycles through each menu item on click, raising the button's {@link #change} event (or calling the button's
* {@link #changeHandler} functio... | JavaScript |
/**
* @class Ext.button.Split
* @extends Ext.button.Button
* A split button that provides a built-in dropdown arrow that can fire an event separately from the default
* click event of the button. Typically this would be used to display a dropdown menu that provides additional
* options to the primary button actio... | JavaScript |
/**
* @class Ext.panel.Table
* @extends Ext.panel.Panel
* @xtype tablepanel
* @private
* @author Nicolas Ferrero
* TablePanel is a private class and the basis of both TreePanel and GridPanel.
*
* TablePanel aggregates:
*
* - a Selection Model
* - a View
* - a Store
* - Scrollers
* - Ext.grid.header.C... | JavaScript |
/**
* @class Ext.panel.Tool
* @extends Ext.Component
This class is used to display small visual icons in the header of a panel. There are a set of
25 icons that can be specified by using the {@link #type} config. The {@link #handler} config
can be used to provide a function that will respond to any click events. In ... | JavaScript |
/**
* @class Ext.panel.Proxy
* @extends Object
* A custom drag proxy implementation specific to {@link Ext.panel.Panel}s. This class
* is primarily used internally for the Panel's drag drop implementation, and
* should never need to be created directly.
* @constructor
* @param panel The {@link Ext.panel.Panel} t... | JavaScript |
/**
* @class Ext.panel.Header
* @extends Ext.container.Container
* Simple header class which is used for on {@link Ext.panel.Panel} and {@link Ext.window.Window}
* @xtype header
*/
Ext.define('Ext.panel.Header', {
extend: 'Ext.container.Container',
uses: ['Ext.panel.Tool', 'Ext.draw.Component', 'Ext.util.C... | JavaScript |
/**
* @class Ext.panel.AbstractPanel
* @extends Ext.container.Container
* <p>A base class which provides methods common to Panel classes across the Sencha product range.</p>
* <p>Please refer to sub class's documentation</p>
* @constructor
* @param {Object} config The config object
*/
Ext.define('Ext.panel.Abstr... | JavaScript |
/**
* @class Ext.panel.Panel
* @extends Ext.panel.AbstractPanel
* <p>Panel is a container that has specific functionality and structural components that make
* it the perfect building block for application-oriented user interfaces.</p>
* <p>Panels are, by virtue of their inheritance from {@link Ext.container.Conta... | JavaScript |
// private - DD implementation for Panels
Ext.define('Ext.panel.DD', {
extend: 'Ext.dd.DragSource',
requires: ['Ext.panel.Proxy'],
constructor : function(panel, cfg){
this.panel = panel;
this.dragData = {panel: panel};
this.proxy = Ext.create('Ext.panel.Proxy', panel, cfg);
... | JavaScript |
/**
* @class Ext.tip.Tip
* @extends Ext.panel.Panel
* This is the base class for {@link Ext.tip.QuickTip} and {@link Ext.tip.ToolTip} that provides the basic layout and
* positioning that all tip-based classes require. This class can be used directly for simple, statically-positioned
* tips that are displayed prog... | JavaScript |
/**
* @class Ext.tip.QuickTip
* @extends Ext.tip.ToolTip
* A specialized tooltip class for tooltips that can be specified in markup and automatically managed by the global
* {@link Ext.tip.QuickTipManager} instance. See the QuickTipManager class header for additional usage details and examples.
* @constructor
* ... | JavaScript |
/**
* @class Ext.tip.ToolTip
* @extends Ext.tip.Tip
*
* ToolTip is a {@link Ext.tip.Tip} implementation that handles the common case of displaying a
* tooltip when hovering over a certain element or elements on the page. It allows fine-grained
* control over the tooltip's alignment relative to the target element... | JavaScript |
/**
* @class Ext.tip.QuickTipManager
* <p>Provides attractive and customizable tooltips for any element. The QuickTips
* singleton is used to configure and manage tooltips globally for multiple elements
* in a generic manner. To create individual tooltips with maximum customizability,
* you should consider either... | JavaScript |
/**
* @class Ext.JSON
* Modified version of Douglas Crockford"s json.js that doesn"t
* mess with the Object prototype
* http://www.json.org/js.html
* @singleton
*/
Ext.JSON = new(function() {
var useHasOwn = !! {}.hasOwnProperty,
isNative = function() {
var useNative = null;
return functi... | JavaScript |
/**
* @class Ext.is
*
* Determines information about the current platform the application is running on.
*
* @singleton
*/
Ext.is = {
init : function(navigator) {
var platforms = this.platforms,
ln = platforms.length,
i, platform;
navigator = navigator || window.navi... | JavaScript |
/**
* @author Jacky Nguyen <jacky@sencha.com>
* @docauthor Jacky Nguyen <jacky@sencha.com>
* @class Ext.Class
*
* Handles class creation throughout the whole framework. Note that most of the time {@link Ext#define Ext.define} should
* be used instead, since it's a higher level wrapper that aliases to {@link Ext.... | JavaScript |
/**
* @author Jacky Nguyen <jacky@sencha.com>
* @docauthor Jacky Nguyen <jacky@sencha.com>
* @class Ext.ClassManager
Ext.ClassManager manages all classes and handles mapping from string class name to
actual class objects throughout the whole framework. It is not generally accessed directly, rather through
these con... | JavaScript |
/**
* @author Jacky Nguyen <jacky@sencha.com>
* @docauthor Jacky Nguyen <jacky@sencha.com>
* @class Ext.Base
*
* The root of all classes created with {@link Ext#define}
* All prototype and static members of this class are inherited by any other class
*
*/
(function(flexSetter) {
var Base = Ext.Base = function(... | JavaScript |
/**
* @author Jacky Nguyen <jacky@sencha.com>
* @docauthor Jacky Nguyen <jacky@sencha.com>
* @class Ext.Loader
*
Ext.Loader is the heart of the new dynamic dependency loading capability in Ext JS 4+. It is most commonly used
via the {@link Ext#require} shorthand. Ext.Loader supports both asynchronous and synchrono... | JavaScript |
/**
* @class Ext.EventObject
Just as {@link Ext.core.Element} wraps around a native DOM node, Ext.EventObject
wraps the browser's native event-object normalizing cross-browser differences,
such as which mouse button is clicked, keys pressed, mechanisms to stop
event-propagation along with a method to prevent default ... | JavaScript |
/**
* @class Ext.Number
*
* A collection of useful static methods to deal with numbers
* @singleton
*/
(function() {
var isToFixedBroken = (0.9).toFixed() !== '1';
Ext.Number = {
/**
* Checks whether or not the current number is within a desired range. If the number is already within the
* range ... | JavaScript |
/**
* @author Jacky Nguyen <jacky@sencha.com>
* @docauthor Jacky Nguyen <jacky@sencha.com>
* @class Ext.Object
*
* A collection of useful static methods to deal with objects
*
* @singleton
*/
(function() {
var ExtObject = Ext.Object = {
/**
* Convert a `name` - `value` pair to an array of objects wi... | JavaScript |
/**
* @author Jacky Nguyen <jacky@sencha.com>
* @docauthor Jacky Nguyen <jacky@sencha.com>
* @class Ext.Array
*
* A set of useful static methods to deal with arrays; provide missing methods for older browsers.
* @singleton
* @markdown
*/
(function() {
var arrayPrototype = Array.prototype,
slice = ... | JavaScript |
/**
* @class Ext.Function
*
* A collection of useful static methods to deal with function callbacks
* @singleton
*/
Ext.Function = {
/**
* A very commonly used method throughout the framework. It acts as a wrapper around another method
* which originally accepts 2 arguments for <code>name</code> an... | JavaScript |
/**
* @class Ext.Date
* A set of useful static methods to deal with date
* Note that if Ext.Date is required and loaded, it will copy all methods / properties to
* this object for convenience
*
* The date parsing and formatting syntax contains a subset of
* <a href="http://www.php.net/date">PHP's date() function... | JavaScript |
/**
* @class Ext.Error
* @private
* @extends Error
A wrapper class for the native JavaScript Error object that adds a few useful capabilities for handling
errors in an Ext application. When you use Ext.Error to {@link #raise} an error from within any class that
uses the Ext 4 class system, the Error class can autom... | JavaScript |
/**
* @class Ext.String
*
* A collection of useful static methods to deal with strings
* @singleton
*/
Ext.String = {
trimRegex: /^[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u2028\u2029\u202f\u205f\u3000]+|[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u18... | JavaScript |
/**
* @class Ext
The Ext namespace (global object) encapsulates all classes, singletons, and utility methods provided by Sencha's libraries.</p>
Most user interface Components are at a lower level of nesting in the namespace, but many common utility functions are provided
as direct properties of the Ext namespace.... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.core.Element.addMethods({
/**
* Initializes a {@link Ext.dd.DD} drag drop object for this element.
* @param {String} group The group the DD object is member of
* @param {Object} config The DD config object
* @param {Object} overrides An object containing me... | JavaScript |
/**
* @class Ext.core.Element
*/
(function(){
var doc = document,
isCSS1 = doc.compatMode == "CSS1Compat",
ELEMENT = Ext.core.Element,
fly = function(el){
if (!_fly) {
_fly = new Ext.core.Element.Flyweight();
}
_fly.dom = el;
... | JavaScript |
/**
* @class Ext.core.DomHelper
* <p>The DomHelper class provides a layer of abstraction from DOM and transparently supports creating
* elements via DOM or using HTML fragments. It also has the ability to create HTML fragment templates
* from your DOM building code.</p>
*
* <p><b><u>DomHelper element specificatio... | JavaScript |
/**
* @class Ext.CompositeElement
* @extends Ext.CompositeElementLite
* <p>This class encapsulates a <i>collection</i> of DOM elements, providing methods to filter
* members, or to perform collective actions upon the whole set.</p>
* <p>Although they are not listed, this class supports all of the methods of {@link... | JavaScript |
/**
* @class Ext.core.Element
*/
(function(){
var ELEMENT = Ext.core.Element,
LEFT = "left",
RIGHT = "right",
TOP = "top",
BOTTOM = "bottom",
POSITION = "position",
STATIC = "static",
RELATIVE = "relative",
AUTO = "auto",
ZINDEX = "z-index";
Ext.override(Ext.core.Element, {
/... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.core.Element.addMethods({
/**
* Monitors this Element for the mouse leaving. Calls the function after the specified delay only if
* the mouse was not moved back into the Element within the delay. If the mouse <i>was</i> moved
* back in, the function is not cal... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.applyIf(Ext.core.Element, {
unitRe: /\d+(px|em|%|en|ex|pt|in|cm|mm|pc)$/i,
camelRe: /(-[a-z])/gi,
opacityRe: /alpha\(opacity=(.*)\)/i,
cssRe: /([a-z0-9-]+)\s*:\s*([^;\s]+(?:\s*[^;\s]+)*);?/gi,
propertyCache: {},
defaultUnit : "px",
borders: {l: 'border-... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.core.Element.addMethods({
/**
* Convenience method for constructing a KeyMap
* @param {Number/Array/Object/String} key Either a string with the keys to listen for, the numeric key code, array of key codes or an object with the following options:
* <code>{key: (n... | JavaScript |
/*
* This is code is also distributed under MIT license for use
* with jQuery and prototype JavaScript libraries.
*/
/**
* @class Ext.DomQuery
Provides high performance selector/xpath processing by compiling queries into reusable functions. New pseudo classes and matchers can be plugged. It works on HTML and XML do... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.core.Element.addMethods({
/**
* Looks at this node and then at parent nodes for a match of the passed simple selector (e.g. div.some-class or span:first-child)
* @param {String} selector The simple selector to test
* @param {Number/Mixed} maxDepth (optional) The... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.core.Element.addMethods(
function() {
var VISIBILITY = "visibility",
DISPLAY = "display",
HIDDEN = "hidden",
NONE = "none",
XMASKED = Ext.baseCSSPrefix + "masked",
XMAS... | JavaScript |
/**
* @class Ext.core.Element
*/
/**
* Visibility mode constant for use with {@link #setVisibilityMode}. Use visibility to hide element
* @static
* @type Number
*/
Ext.core.Element.VISIBILITY = 1;
/**
* Visibility mode constant for use with {@link #setVisibilityMode}. Use display to hide element
* @static
* @t... | JavaScript |
/**
* @class Ext.core.Element
*/
(function(){
Ext.core.Element.boxMarkup = '<div class="{0}-tl"><div class="{0}-tr"><div class="{0}-tc"></div></div></div><div class="{0}-ml"><div class="{0}-mr"><div class="{0}-mc"></div></div></div><div class="{0}-bl"><div class="{0}-br"><div class="{0}-bc"></div></div></div>';
... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.core.Element.addMethods({
/**
* Gets the x,y coordinates specified by the anchor position on the element.
* @param {String} anchor (optional) The specified anchor position (defaults to "c"). See {@link #alignTo}
* for details on supported anchor positions.
... | JavaScript |
/**
* @class Ext.CompositeElementLite
*/
Ext.apply(Ext.CompositeElementLite.prototype, {
addElements : function(els, root){
if(!els){
return this;
}
if(typeof els == "string"){
els = Ext.core.Element.selectorFunction(els, root);
}
var yels = this.ele... | JavaScript |
/**
* @class Ext.core.Element
* <p>Encapsulates a DOM element, adding simple DOM manipulation facilities, normalizing for browser differences.</p>
* <p>All instances of this class inherit the methods of {@link Ext.fx.Anim} making visual effects easily available to all DOM elements.</p>
* <p>Note that the events doc... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.core.Element.addMethods({
/**
* Appends the passed element(s) to this element
* @param {String/HTMLElement/Array/Element/CompositeElement} el
* @return {Ext.core.Element} this
*/
appendChild : function(el) {
return Ext.get(el).appendTo(this);
... | JavaScript |
/**
* @class Ext.CompositeElementLite
* <p>This class encapsulates a <i>collection</i> of DOM elements, providing methods to filter
* members, or to perform collective actions upon the whole set.</p>
* <p>Although they are not listed, this class supports all of the methods of {@link Ext.core.Element} and
* {@link ... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.override(Ext.core.Element, {
/**
* Returns true if this element is scrollable.
* @return {Boolean}
*/
isScrollable : function(){
var dom = this.dom;
return dom.scrollHeight > dom.clientHeight || dom.scrollWidth > dom.clientWidth;
},
... | JavaScript |
/**
* @class Ext.core.Element
*/
Ext.applyIf(Ext.core.Element.prototype, {
// @private override base Ext.util.Animate mixin for animate for backwards compatibility
animate: function(config) {
var me = this;
if (!me.id) {
me = Ext.get(me.dom);
}
if (Ext.fx.Manager.ha... | JavaScript |
/**
* @class Ext.EventManager
* Registers event handlers that want to receive a normalized EventObject instead of the standard browser event and provides
* several useful events directly.
* See {@link Ext.EventObject} for more details on normalized event objects.
* @singleton
*/
Ext.EventManager = {
// -----... | JavaScript |
/**
* @class Ext
* @singleton
*/
(function() {
var global = this,
objectPrototype = Object.prototype,
toString = Object.prototype.toString,
enumerables = true,
enumerablesTest = { toString: 1 },
i;
if (typeof Ext === 'undefined') {
global.Ext = {};
}
... | JavaScript |
/**
* @author Jacky Nguyen <jacky@sencha.com>
* @docauthor Jacky Nguyen <jacky@sencha.com>
* @class Ext.Version
*
* A utility class that wrap around a string version number and provide convenient
* method to perform comparison. See also: {@link Ext.Version#compare compare}. Example:
var version = new Ext.Ver... | JavaScript |
/**
* @class Ext.util.TaskRunner
* Provides the ability to execute one or more arbitrary tasks in a multithreaded
* manner. Generally, you can use the singleton {@link Ext.TaskManager} instead, but
* if needed, you can create separate instances of TaskRunner. Any number of
* separate tasks can be started at any ... | JavaScript |
/**
* @class Ext.util.Format
This class is a centralized place for formatting functions inside the library. It includes
functions to format various different types of data, such as text, dates and numeric values.
__Localization__
This class contains several options for localization. These can be set once the library... | JavaScript |
/**
* @class Ext.util.DelayedTask
*
* The DelayedTask class provides a convenient way to "buffer" the execution of a method,
* performing setTimeout where a new timeout cancels the old timeout. When called, the
* task will wait the specified time period before executing. If durng that time period,
* the task is ... | JavaScript |
Ext.require('Ext.util.DelayedTask', function() {
Ext.util.Event = Ext.extend(Object, (function() {
function createBuffered(handler, listener, o, scope) {
listener.task = new Ext.util.DelayedTask();
return function() {
listener.task.delay(o.buffer, handler, scope, Ext... | JavaScript |
Ext.define('Sample.Musician', {
extend: 'Sample.Person',
statics: {
clone: function(musician) {
return new this({
name: musician.getName(),
height: musician.getHeight(),
isCool: musician.getIsCool(),
gender: musician.getGender(... | JavaScript |
Ext.define('Sample.ability.CanComposeSongs', {
canComposeSongs: true,
composeSongs: function() {
alert(this.getName() + " is composing songs");
return this;
}
}); | JavaScript |
Ext.define('Sample.ability.CanPlayGuitar', {
canPlayGuitar: true,
playGuitar: function() {
alert(this.getName() + " is playing guitar");
return this;
}
}); | JavaScript |
Ext.define('Sample.ability.CanSing', {
config: {
knownSongs: ['Yesterday', 'Happy New Year', 'Jingle Bells']
},
canSing: true,
sing: function(songName) {
if (!Ext.Array.contains(this.getKnownSongs(), songName)) {
alert("Sorry! I can't sing " + songName);
}
e... | JavaScript |
Ext.define('Sample.deadlock.D', {
extend: 'Sample.deadlock.E'
}); | JavaScript |
Ext.define('Sample.deadlock.B', {
extend: 'Sample.deadlock.C'
}); | JavaScript |
Ext.define('Sample.deadlock.C', {
extend: 'Sample.deadlock.D'
}); | JavaScript |
Ext.define('Sample.deadlock.E', {
extend: 'Sample.deadlock.A'
}); | JavaScript |
Ext.define('Sample.deadlock.A', {
extend: 'Sample.deadlock.B'
}); | JavaScript |
Ext.define('Sample.Person', {
uses: 'Sample.Gun',
statics: {
averageIQ: 100
},
config: {
name: 'Unknown',
gender: 'unknown',
isCool: false,
height: 5.8
},
constructor: function(config) {
this.initConfig(config);
return this;
},
... | JavaScript |
Ext.define('Sample.Developer', {
extend: 'Sample.Person',
statics: {
averageIQ: 120
},
config: {
languages: ['JavaScript', 'C++', 'Python']
},
constructor: function(config) {
this.isGeek = true;
// Apply a method from the parent class' prototype
return... | JavaScript |
Ext.define('Sample.Gun', {
}); | JavaScript |
Ext.define('Sample.notdeadlock.B', {
extend: 'Sample.notdeadlock.C',
uses: 'Sample.notdeadlock.A'
});
| JavaScript |
Ext.define('Sample.notdeadlock.C', {
uses: 'Sample.notdeadlock.A'
});
| JavaScript |
Ext.define('Sample.notdeadlock.A', {
extend: 'Sample.notdeadlock.B'
}); | JavaScript |
Ext.define('Sample.HumanResource', {
requires: 'Sample.Developer',
singleton: true,
developers: [],
recruit: function(developer) {
if (!developer.canCode('JavaScript')) {
alert(developer.getName() + " doesn't know JavaScript, no point recruiting!");
}
else {
... | JavaScript |
Ext.define('Sample.CoolGuy', {
extend: 'Sample.Person',
mixins: {
guitar: 'Sample.ability.CanPlayGuitar',
sing: 'Sample.ability.CanSing'
},
constructor: function() {
this.config.knownSongs.push("Love Me or Die");
return this.callParent(arguments);
},
sing: fun... | JavaScript |
Ext.define('Sample.CTO', {
extend: 'Sample.Developer',
statics: {
averageIQ: 140
},
constructor: function(config) {
this.callParent(arguments);
this.isSuperGeek = true;
},
hireNewDeveloperLike: function(developer) {
return developer.clone();
},
clone:... | JavaScript |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
| JavaScript |
Ext.Loader.setConfig({enabled: true});
Ext.Loader.require_backup = Ext.Loader.require;
Ext.Loader.require = Ext.require = function(requiredClasses, fn, scope) {
fn.call(scope);
}; | JavaScript |
describe("Ext.JSON", function() {
var nativeJson;
beforeEach(function() {
nativeJson = Ext.USE_NATIVE_JSON;
Ext.USE_NATIVE_JSON = false;
});
afterEach(function() {
Ext.USE_NATIVE_JSON = nativeJson;
});
describe("encode", function() {
var encode = Ext.JSON.enco... | JavaScript |
describe("Ext.Support", function() {
describe("Ext.is", function() {
var platform = {
detect: function(navigatorObject) {
var result = [];
Ext.is.init(navigatorObject);
if (Ext.is.Desktop) {
result.push('Desktop');
}
if (Ext.is.Tablet) {
result.push('Tablet');
}
if... | JavaScript |
describe("Ext.Class", function() {
var cls, emptyFn = function(){};
beforeEach(function() {
window.My = {
awesome: {
Class: function(){console.log(11)},
Class1: function(){console.log(12)},
Class2: function(){console.log(13)}
},
... | JavaScript |
describe("Ext.ClassManager", function() {
var manager = Ext.ClassManager,
cls, emptyFn = function(){};
beforeEach(function() {
manager.enableNamespaceParseCache = false;
window.My = {
awesome: {
Class: function(){console.log(11);},
Class1: f... | JavaScript |
describe("Ext.Number", function(){
var Number = Ext.Number;
describe("constraining a number", function(){
describe("integers", function(){
describe("if the number is within the constaints", function(){
it("should leave the number alone if it is equal to the min and the m... | JavaScript |
describe("Ext.Object", function(){
describe("getKeys", function(){
var getKeys = Ext.Object.getKeys;
it("should return an empty array for a null value", function(){
expect(getKeys(null)).toEqual([]);
});
it("should return an empty array for an empty object", function(){... | JavaScript |
describe("Ext.Array", function() {
var array;
describe("Ext.Array.indexOf", function() {
var indexOf = Ext.Array.indexOf;
describe("without from argument", function() {
beforeEach(function() {
array = [1, 2, 3, 4, 5, 6];
});
afterEach(functi... | JavaScript |
describe("Ext.Function", function() {
describe("bind", function() {
var fn,
bind;
beforeEach(function() {
fn = jasmine.createSpy("bindSpy");
});
it("should return a function if a function is passed as first argument", function() {
bind = Ext.Func... | JavaScript |
describe("Ext.Error", function() {
var global,
consoleWarningMsg = 'An uncaught error was raised with the following data:';
beforeEach(function() {
global = Ext.global;
// mock the console to avoid logging to the real console during the tests
Ext.global = {
console... | JavaScript |
describe("Ext.String", function() {
describe("ellipsis", function() {
var ellipsis = Ext.String.ellipsis,
shortString = "A short string",
longString = "A somewhat longer string";
it("should keep short strings intact", function() {
expect(ellipsis(shortS... | JavaScript |
describe("Ext.core.Element.static", function() {
var proto = Ext.core.Element,
el, testEl,
input, testInputEl,
child1, child2, child3;
beforeEach(function() {
testEl = Ext.getBody().createChild({
id : 'ExtElementHelper',
style : 'position:absol... | JavaScript |
describe("Ext.core.Element.traversal", function() {
var proto = Ext.core.Element,
el, testEl,
input, testInputEl,
child1, child2, child3, child4, child5;
beforeEach(function() {
testEl = Ext.getBody().createChild({
id : 'ExtElementHelper',
cls ... | JavaScript |
describe("Ext.core.Element", function() {
var domEl,
element;
afterEach(function() {
if (element) {
element.remove();
}
if (domEl && domEl.parentNode === document.body) {
document.body.removeChild(domEl);
}
});
describe("inst... | JavaScript |
describe("Ext.core.Element.insertion", function() {
var proto = Ext.core.Element.prototype,
el, testEl,
span, testSpanEl,
child1, child2, child3;
beforeEach(function() {
testEl = Ext.getBody().createChild({
id: 'ExtElementHelper',
children: [
... | JavaScript |
describe("Ext.EventManager", function() {
var element,
elementWithId,
elementWithoutId;
beforeEach(function() {
// add global variable in whitelist
addGlobal("id");
addGlobal("ExtSandbox1");
element = document.body;
elementWithId = document.c... | JavaScript |
describe("Ext", function() {
describe("Ext.apply", function() {
var origin, o;
beforeEach(function() {
origin = {
name: 'value',
something: 'cool',
items: [1,2,3],
method: function() {
this.myMethodCall... | JavaScript |
describe("Ext.Version", function() {
var version = new Ext.Version("1.2.3beta");
describe("toString", function() {
it("should cast to string", function() {
expect(version+"").toBe("1.2.3beta");
});
});
describe("getMajor", function() {
it("should return 1", function() {
expect(version.getMajo... | JavaScript |
describe("Ext.Date", function() {
var dateSave,
dateValue = 0,
increment = 3;
beforeEach(function() {
dateSave = Date;
Date = function() {
return {
getTime: function() {
},
valueOf: function() {
... | JavaScript |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.