rem
stringlengths
0
126k
add
stringlengths
0
441k
context
stringlengths
15
136k
var searchRunning = false;
completion: function () { var searchRunning = false; // only until Firefox fixes https://bugzilla.mozilla.org/show_bug.cgi?id=510589 completion.location = function location(context) { if (!services.get("autoCompleteSearch")) return; context.anchored = false; ...
context.cancel = function () { if (searchRunning) { services.get("autoCompleteSearch").stopSearch(); searchRunning = false; } };
context.cancel = function () { services.get("autoCompleteSearch").stopSearch(); context.completions = []; };
completion: function () { var searchRunning = false; // only until Firefox fixes https://bugzilla.mozilla.org/show_bug.cgi?id=510589 completion.location = function location(context) { if (!services.get("autoCompleteSearch")) return; context.anchored = false; ...
searchRunning = false;
completion: function () { var searchRunning = false; // only until Firefox fixes https://bugzilla.mozilla.org/show_bug.cgi?id=510589 completion.location = function location(context) { if (!services.get("autoCompleteSearch")) return; context.anchored = false; ...
JavaScript.setCompleter(this.get, [function () config.autocommands]);
JavaScript.setCompleter(this.get, [function () Iterator(config.autocommands)]);
completion: function () { JavaScript.setCompleter(this.get, [function () config.autocommands]); completion.autocmdEvent = function autocmdEvent(context) { context.completions = config.autocommands; }; completion.macro = function macro(context) { context.title = ["Ma...
context.completions = config.autocommands;
context.completions = Iterator(config.autocommands);
completion: function () { JavaScript.setCompleter(this.get, [function () config.autocommands]); completion.autocmdEvent = function autocmdEvent(context) { context.completions = config.autocommands; }; completion.macro = function macro(context) { context.title = ["Ma...
let abbrevs = abbreviations.merged.filter(function (abbr) abbr.inModes(modes)); context.completions = [[abbr.lhs, abbr.rhs] for ([, abbr] in Iterator(abbrevs))];
let fn = modes ? function (abbr) abbr.inModes(modes) : util.identity; context.keys = { text: "lhs" , description: "rhs" }; context.completions = abbreviations.merged.filter(fn);
completion: function () { completion.abbreviation = function abbreviation(context, modes) { let abbrevs = abbreviations.merged.filter(function (abbr) abbr.inModes(modes)); context.completions = [[abbr.lhs, abbr.rhs] for ([, abbr] in Iterator(abbrevs))]; }; },
completion.history = function _history(context, maxItems) {
completion.history = function _history(context, args, maxItems) {
completion: function () { completion.domain = function (context) { context.anchored = false; context.compare = function (a, b) String.localeCompare(a.key, b.key); context.keys = { text: util.identity, description: util.identity, key: function (host) host.split(...
context.completions = config.dialogs;
context.completions = [[k, v[0]] for ([k, v] in Iterator(config.dialogs))];
completion: function () { completion.dialog = function dialog(context) { context.title = ["Dialog"]; context.completions = config.dialogs; }; completion.extension = function extension(context) { context.title = ["Extension"]; context.anchored = false;...
completion.macro = function macro(context) { context.title = ["Macro", "Keys"]; context.completions = [item for (item in events.getMacros())]; };
completion: function () { completion.autocmdEvent = function autocmdEvent(context) { context.completions = Iterator(config.autocommands); }; completion.macro = function macro(context) { context.title = ["Macro", "Keys"]; context.completions = [item for (item in ...
this.progressListener_ = this.installProgressListener();
function ComponentCollectorService() { // Exposing the wrappedJSObject property in this way allows callers // to access the native JS object, not just the xpconnect-wrapped // object. This allows access to the full ComponentCollectorService // API, not just the subset of the API exported via the // IComponentColle...
shrinksafe.tests.module.compress = function(source, stripConsole){
shrinksafe.tests.module.compress = function(source, stripConsole, escapeUnicode){
shrinksafe.tests.module.compress = function(source, stripConsole){ // summary: Shorthand to compress some String version of JS code return new String(Packages.org.dojotoolkit.shrinksafe.Compressor.compressScript(source, 0, 1, stripConsole)).toString();}
return new String(Packages.org.dojotoolkit.shrinksafe.Compressor.compressScript(source, 0, 1, stripConsole)).toString();
return new String(Packages.org.dojotoolkit.shrinksafe.Compressor.compressScript(source, 0, 1, escapeUnicode, stripConsole)).toString();
shrinksafe.tests.module.compress = function(source, stripConsole){ // summary: Shorthand to compress some String version of JS code return new String(Packages.org.dojotoolkit.shrinksafe.Compressor.compressScript(source, 0, 1, stripConsole)).toString();}
classes["sc-overflow-segment"] = this.isOverflowSegment;
computeClasses: function() { var classes = this._class_hash || {}; classes["sc-first-segment"] = this.isFirstSegment; classes["sc-middle-segment"] = this.isMiddleSegment; classes["sc-last-segment"] = this.isLastSegment; classes["sc-segment"] = YES; classes["fixed"] = this.width; this._cla...
classes["fixed"] = this.width;
computeClasses: function() { var classes = this._class_hash || {}; classes["sc-first-segment"] = this.isFirstSegment; classes["sc-middle-segment"] = this.isMiddleSegment; classes["sc-last-segment"] = this.isLastSegment; classes["sc-segment"] = YES; this._class_hash = classes; return class...
config.features.push(Dactyl.getPlatformFeature());
let os = services.get("runtime").OS; config.features.push(os == "WINNT" || os == "Darwin" ? os : "Unix");
config: function () { config.features.push(Dactyl.getPlatformFeature()); },
}
},
configSet: function(config){ TBRL.Config = config; window.localStorage.options = JSON.stringify(config); }
val instanceof Number){
val instanceof Number || val === null){
configUpdate: function(log){ function setter(key, def, target){ var val = def[key]; var res = typeof(val); if(Array.isArray(val)){ if(!(target[key])) target[key] = []; for(var i = 0, l = val.length; i < l; ++i){ setter(i, val, target[key]); } } else { ...
itemView.setIfChanged('content', attrs.content); itemView.setIfChanged('contentIndex', attrs.contentIndex); itemView.setIfChanged('parentView', attrs.parentView); itemView.setIfChanged('layerId', attrs.layerId); itemView.setIfChanged('isEnabled', attrs.isEnabled); itemView.setIfChanged('isSelected', attrs.isSelected); ...
itemView.setIfChanged(attrs);
configureItemView: function(itemView, attrs) { // set settings. Self explanatory. itemView.beginPropertyChanges(); itemView.setIfChanged('content', attrs.content); itemView.setIfChanged('contentIndex', attrs.contentIndex); itemView.setIfChanged('parentView', attrs.parentView); itemView.setIfChanged(...
return itemView;
configureItemView: function(itemView, attrs) { // set settings. Self explanatory. itemView.beginPropertyChanges(); itemView.setIfChanged(attrs); itemView.endPropertyChanges(); },
console.log("configuring");
configureItemView: function(itemView, attrs) { // set settings. Self explanatory. console.log("configuring"); itemView.beginPropertyChanges(); itemView.setIfChanged('content', attrs.content); itemView.setIfChanged('contentIndex', attrs.contentIndex); itemView.setIfChanged('parentView', attrs.paren...
console.log("configuring");
configureItemView: function(itemView, attrs) { // set settings. Self explanatory. itemView.beginPropertyChanges(); itemView.setIfChanged('content', attrs.content); itemView.setIfChanged('contentIndex', attrs.contentIndex); itemView.setIfChanged('parentView', attrs.parentView); itemView.setIfChanged(...
conn.onconnect = bind(this, 'cometSessionOnConnect');
conn.onconnect = bind(this, 'cometSessionOnConnect', conn);
this.connect = function() { this._state = net.interfaces.STATE.CONNECTING; var conn = new CometSession(); conn.onconnect = bind(this, 'cometSessionOnConnect'); conn.ondisconnect = bind(this, 'onDisconnect'); logger.debug('opening the connection'); this._opts.encoding = 'plain'; var url = this._opts.url; de...
var constructor = this._opts.constructor || window.WebSocket;
var constructor = this._opts.wsConstructor || window.WebSocket; logger.info('this._opts', this._opts);
this.connect = function() { var url = this._opts.url; var constructor = this._opts.constructor || window.WebSocket; var ws = new constructor(url); ws.onopen = bind(this, function() { this.onConnect(new Transport(ws)); }); ws.onclose = bind(this, function(code) { logger.debug('conn closed without opening, c...
contains: function (range, r) range.compareBoundaryPoints(range.START_TO_END, r) >= 0 && range.compareBoundaryPoints(range.END_TO_START, r) <= 0,
contains: function (range, r) { try { return range.compareBoundaryPoints(range.START_TO_END, r) >= 0 && range.compareBoundaryPoints(range.END_TO_START, r) <= 0; } catch (e) { dactyl.reportError(e, true); return false; } },
contains: function (range, r) range.compareBoundaryPoints(range.START_TO_END, r) >= 0 && range.compareBoundaryPoints(range.END_TO_START, r) <= 0,
this.get('content').addRangeObserver(null, this, this.rangeDidChange);
contentDidChange: function() { // setup range observer }.observes('content'),
this.reload();
contentDidChange: function() { if(this._SCCFP_contentRangeObserver) this._SCCFP_contentRangeObserver.destroy(); var content = this.get('content'); if(content) this._SCCFP_contentRangeObserver = content.addRangeObserver(null, this, this.contentIndicesDidChange); }.observes('content'),
contentDidChange: function(a, b, c, d,e) {
contentDidChange: function() {
contentDidChange: function(a, b, c, d,e) { if(this._cfp_contentRangeObserver) this._cfp_contentRangeObserver.destroy(); var content = this.get('content'); if(content) this._cfp_contentRangeObserver = content.addRangeObserver(null, this, this.contentIndicesDidChange); }.observes('content'),
var layout = this.computeLayout(); if (layout) this.adjust(layout); this._SCCFP_oldLength = length;
contentLengthDidChange: function() { var content = this.get('content'), length = content ? content.get('length') : 0, oldLength = this.get('length'), indexMap = this._indexMap; if(length < oldLength) { var i, view; for(i = length; i < oldLength; i++) { view = indexMap[i]; if...
a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);ab.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):e;if((this.length>1||cb.test(f))&&bb.test(a))e=e.reverse();return this.pushStack(e,a,R.call(arguments)...
a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);eb.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):e;if((this.length>1||gb.test(f))&&fb.test(a))e=e.reverse();return this.pushStack(e,a,R.call(arguments)...
d)},next:function(a){return c.nth(a,2,"nextSibling")},prev:function(a){return c.nth(a,2,"previousSibling")},nextAll:function(a){return c.dir(a,"nextSibling")},prevAll:function(a){return c.dir(a,"previousSibling")},nextUntil:function(a,b,d){return c.dir(a,"nextSibling",d)},prevUntil:function(a,b,d){return c.dir(a,"previ...
width = (f) ? f.width * scale : 0, height = (f) ? f.height * scale : 0,
width = 0, height = 0,
contentViewFrameDidChange: function(force) { var view = this.get('contentView'), f = (view) ? view.get('frame') : null, scale = this._scale, width = (f) ? f.width * scale : 0, height = (f) ? f.height * scale : 0, dim, dimWidth, dimHeight; width = view.get('calcu...
width = view.get('calculatedWidth') || f.width || 0; height = view.get('calculatedHeight') || f.height || 0;
if (view) { width = view.get('calculatedWidth') || f.width || 0; height = view.get('calculatedHeight') || f.height || 0; }
contentViewFrameDidChange: function(force) { var view = this.get('contentView'), f = (view) ? view.get('frame') : null, scale = this._scale, width = (f) ? f.width * scale : 0, height = (f) ? f.height * scale : 0, dim, dimWidth, dimHeight; width = view.get('calcu...
this.parserIndex = -1; this.statementIndex = 0;
doctest.Context = function (testSuite) { if (this === window) { throw('You forgot new!'); } this.parserIndex = -1; this.statementIndex = 0; this.testSuite = testSuite; this.lastExample = null; this.runner = null; this.timeout = 0; this.timeoutFunc = null;};
this.lastExample = null;
doctest.Context = function (testSuite) { if (this === window) { throw('You forgot new!'); } this.parserIndex = -1; this.statementIndex = 0; this.testSuite = testSuite; this.lastExample = null; this.runner = null; this.timeout = 0; this.timeoutFunc = null;};
this.timeout = 0; this.timeoutFunc = null;
doctest.Context = function (testSuite) { if (this === window) { throw('You forgot new!'); } this.parserIndex = -1; this.statementIndex = 0; this.testSuite = testSuite; this.lastExample = null; this.runner = null; this.timeout = 0; this.timeoutFunc = null;};
update(ctx, TBRL.createContext(query && document.querySelector(query)));
update(ctx, TBRL.createContext((query && document.querySelector(query)) || TBRL.getContextMenuTarget()));
contextMenus: function(req, sender, func) { func({}); var content = req.content; var ctx = {}; var query = null; switch (content.mediaType) { case 'video': ctx.onVideo = true; ctx.target = $N('video', { src: content.srcUrl }); query = 'video[src="'+content.srcU...
}, TBRL.createContext(document.querySelector('audio[src="'+content.srcUrl+'"]')));
}, TBRL.createContext(document.querySelector('audio[src="'+content.srcUrl+'"]') || TBRL.getContextMenuTarget()));
contextMenusAudio: function(req, sender, func) { func({}); var content = req.content; var ctx = update({ onVideo: true, contextMenu: true }, TBRL.createContext(document.querySelector('audio[src="'+content.srcUrl+'"]'))); TBRL.share(ctx, Extractors.Audio, true); },
}, TBRL.createContext());
}, TBRL.createContext(TBRL.getContextMenuTarget()));
contextMenusCapture: function(req, sender, func) { func({}); var content = req.content; var ctx = update({ contextMenu: true }, TBRL.createContext()); TBRL.share(ctx, Extractors["Photo - Capture"], true); }
}, TBRL.createContext(document.querySelector('img[src="'+content.srcUrl+'"]')));
}, TBRL.createContext(document.querySelector('img[src="'+content.srcUrl+'"]') || TBRL.getContextMenuTarget()));
contextMenusImage: function(req, sender, func) { func({}); var content = req.content; var ctx = update({ onImage: true, contextMenu: true }, TBRL.createContext(document.querySelector('img[src="'+content.srcUrl+'"]'))); var ext = Extractors.check(ctx).filter(function(m){ return /^Photo/.t...
}, TBRL.createContext(document.querySelector('a[href="'+content.linkUrl+'"]')));
}, TBRL.createContext(document.querySelector('a[href="'+content.linkUrl+'"]') || TBRL.getContextMenuTarget()));
contextMenusLink: function(req, sender, func) { func({}); var content = req.content; var ctx = update({ title: content.linkUrl, onLink: true, contextMenu: true }, TBRL.createContext(document.querySelector('a[href="'+content.linkUrl+'"]'))); ctx.link = ctx.target; var ext = Extractors....
}, TBRL.createContext());
}, TBRL.createContext(TBRL.getContextMenuTarget()));
contextMenusQuote: function(req, sender, func) { func({}); var content = req.content; var sel = createFlavoredString(window.getSelection()); var ctx = update({ contextMenu: true }, TBRL.createContext()); var ext = Extractors.check(ctx).filter(function(m){ return /^Quote/.test(m.name); }...
}, TBRL.createContext(document.querySelector('video[src="'+content.srcUrl+'"]')));
}, TBRL.createContext(document.querySelector('video[src="'+content.srcUrl+'"]') || TBRL.getContextMenuTarget()));
contextMenusVideo: function(req, sender, func) { func({}); var content = req.content; var ctx = update({ onVideo: true, contextMenu: true }, TBRL.createContext(document.querySelector('video[src="'+content.srcUrl+'"]'))); var ext = Extractors.check(ctx).filter(function(m){ return /^Video/...
this._updateUI();
convert: function () { //Logger.debug("convert:"); if (this._error) { return false; } var ctx = this; this._backend.query(this, function () { ctx._updateCandidates(ctx._predict()); }); return true; },
if (this._error) {
if (this.error) {
convert: function () { //Logger.debug("convert:"); if (this._error) { return false; } var ctx = this; // set error beforehand in case the query fails, and to prevent repeated queries this._error = {start: 0, end: ctx.input.length}; this._backend.query(this...
this._error = {start: 0, end: ctx.input.length};
this.error = {start: 0, end: ctx.input.length}; this.pending = [];
convert: function () { //Logger.debug("convert:"); if (this._error) { return false; } var ctx = this; // set error beforehand in case the query fails, and to prevent repeated queries this._error = {start: 0, end: ctx.input.length}; this._backend.query(this...
var newObj=editor.dom.create(tagname);editor.dom.setAttribs(newObj,args);if(tinymce.isIE){newObj.innerHTML=targetObj.innerHTML;targetObj.parentNode.replaceChild(newObj,targetObj);}else{editor.dom.replace(newObj,targetObj,true);} tagList=doc.getElementsByTagName(org_tagname);}
var newObj=editor.dom.create(tagname);editor.dom.setAttribs(newObj,args);editor.dom.replace(newObj,targetObj,true);tagList=doc.getElementsByTagName(org_tagname);}
function convertHtmlTagToDecoTag(doc,tagname){var tagList=doc.getElementsByTagName(tagname);var org_tagname=tagname;var args={};while(tagList.length){targetObj=tagList[0];args={};if(org_tagname=="font"){var size=targetObj.getAttribute("size");var color=targetObj.getAttribute("color");tagname='op:font';if(size&&color){i...
convertToForm : function(ps){ return { 'post[type]' : ps.type, 'post[one]' : getFlavor(ps, 'html') || ps.itemUrl, 'post[two]' : joinText([ (ps.item? ps.item.link(ps.pageUrl) : '') + (ps.author? ' (via ' + ps.author.link(ps.authorUrl) + ')' : ''), ps.description], '\n\n') }; }
convertToForm: function(ps) { return { title: ps.item, address: ps.pageUrl, embed_code: ps.body || '', description: joinText([ (ps.item ? ps.item.link(ps.pageUrl) : '') + (ps.author ? ' (via ' + ps.author.link(ps.authorUrl) + ')' : ''), '<p>' + escapeHTML(ps.description) + '</p>' ], '') }; }
convertToForm : function(ps){ return { 'post[type]' : ps.type, 'post[one]' : getFlavor(ps, 'html') || ps.itemUrl, 'post[two]' : joinText([ (ps.item? ps.item.link(ps.pageUrl) : '') + (ps.author? ' (via ' + ps.author.link(ps.authorUrl) + ')' : ''), ps.description], '\n\n') }; }
'post[one]' : getFlavor(ps.body, 'html') || ps.itemUrl,
'post[one]' : getFlavor(ps, 'html') || ps.itemUrl,
convertToForm : function(ps){ return { 'post[type]' : ps.type, 'post[one]' : getFlavor(ps.body, 'html') || ps.itemUrl, 'post[two]' : joinText([ (ps.item? ps.item.link(ps.pageUrl) : '') + (ps.author? ' (via ' + ps.author.link(ps.authorUrl) + ')' : ''), ps.description], '\n\n') }; ...
if(focusAnc[0] < anchorAnc[0]){ var t = focusAnc; focusAnc = anchorAnc; anchorAnc = t; t = focusOffset; focusOffset = anchorOffset; anchorOffset = t; }
function convertToHTMLString(src, safe){ var doc = src.ownerDocument || src.focusNode.ownerDocument; if(src.focusNode){ // common parent node search var current, anchorOffset = src.anchorOffset, focusOffset = src.focusOffset; var anchorAnc = [src.anchorNode]; current = src.anchorNode; co...
current = common; focusAnc.forEach(function(obj){ var children = $A(current.childNodes); for(var i = obj+1, len = children.length; i < len; i++){ current.removeChild(children[i]);
if(focusAnc[0] !== undefined){ if(focusAnc[0] < anchorAnc[0]){ var t = focusAnc; focusAnc = anchorAnc; anchorAnc = t; t = focusOffset; focusOffset = anchorOffset; anchorOffset = t;
function convertToHTMLString(src, safe){ var doc = src.ownerDocument || src.focusNode.ownerDocument; if(src.focusNode){ // common parent node search var current, anchorOffset = src.anchorOffset, focusOffset = src.focusOffset; var anchorAnc = [src.anchorNode]; current = src.anchorNode; co...
current = children[obj]; }); if(current.nodeType === Node.TEXT_NODE){ var val = current.textContent; if(val.length !== focusOffset){ current.parentNode.replaceChild($T(val.substring(0, focusOffset)), current);
current = common; focusAnc.forEach(function(obj){ var children = $A(current.childNodes); for(var i = obj+1, len = children.length; i < len; i++){ current.removeChild(children[i]); } current = children[obj]; }); if(current.nodeType === Node.TEXT_NODE){ var val = current.textContent; if(val.length !== focusOffset){ curre...
function convertToHTMLString(src, safe){ var doc = src.ownerDocument || src.focusNode.ownerDocument; if(src.focusNode){ // common parent node search var current, anchorOffset = src.anchorOffset, focusOffset = src.focusOffset; var anchorAnc = [src.anchorNode]; current = src.anchorNode; co...
} current = common; anchorAnc.forEach(function(obj){ var children = $A(current.childNodes); for(var i = 0, len = obj; i < len; i++){ current.removeChild(children[i]);
current = common; anchorAnc.forEach(function(obj){ var children = $A(current.childNodes); for(var i = 0, len = obj; i < len; i++){ current.removeChild(children[i]); } current = children[obj]; }); if(current.nodeType === Node.TEXT_NODE && anchorOffset){ current.parentNode.replaceChild($T(current.textContent.substring(an...
function convertToHTMLString(src, safe){ var doc = src.ownerDocument || src.focusNode.ownerDocument; if(src.focusNode){ // common parent node search var current, anchorOffset = src.anchorOffset, focusOffset = src.focusOffset; var anchorAnc = [src.anchorNode]; current = src.anchorNode; co...
current = children[obj]; }); if(current.nodeType === Node.TEXT_NODE && anchorOffset){ current.parentNode.replaceChild($T(current.textContent.substring(anchorOffset)), current);
} else { if(common.nodeType === Node.TEXT_NODE){ if(focusOffset < anchorOffset){ var t = focusOffset; focusOffset = anchorOffset; anchorOffset = t; } common = $T(common.textContent.substring(anchorOffset, focusOffset)); }
function convertToHTMLString(src, safe){ var doc = src.ownerDocument || src.focusNode.ownerDocument; if(src.focusNode){ // common parent node search var current, anchorOffset = src.anchorOffset, focusOffset = src.focusOffset; var anchorAnc = [src.anchorNode]; current = src.anchorNode; co...
return null;
convertToParams : function(form){ switch(form['post[type]']){ case 'regular': return { type : 'quote', item : form['post[one]'], body : form['post[two]'] } case 'photo': return { itemUrl : form.image, body : form['post[two...
print("copy");
fileUtil.copyDir = function(/*String*/srcDir, /*String*/destDir, /*RegExp*/regExpFilter, /*boolean?*/onlyCopyNew){ //summary: copies files from srcDir to destDir using the regExpFilter to determine if the //file should be copied. Returns a list file name strings of the destinations that were copied. var fileNames = fil...
descendant.prototype[m] = parent.prototype[m];
if (typeof descendant.prototype[m] == 'undefined') { descendant.prototype[m] = parent.prototype[m]; }
copyPrototype: function(descendant, parent) { var sConstructor = parent.toString(); var aMatch = sConstructor.match( /\s*function (.*)\(/ ); if ( aMatch != null ) { descendant.prototype[aMatch[1]] = parent; } for (var m in parent.prototype) { descendant.prototype[m] = parent.p...
},
}
copyTab: function (to, from) { if (!from) from = config.tabbrowser.mTabContainer.selectedItem; let tabState = services.get("sessionStore").getTabState(from); services.get("sessionStore").setTabState(to, tabState); },
equals(view.$('.count').size(), 0, 'should not have count') ;
ok(!cq.hasClass('has-count'), "should not have has-count class"); equals(countCQ.size(), 0, 'should not have count') ;
function count(view, cnt) { if (cnt === null) { equals(view.$('.count').size(), 0, 'should not have count') ; } else { var cq = view.$('.count'); equals(cq.size(), 1, 'should have count'); equals(cq.text(), cnt.toString(), 'should have count'); }}
var cq = view.$('.count'); equals(cq.size(), 1, 'should have count'); equals(cq.text(), cnt.toString(), 'should have count');
ok(cq.hasClass('has-count'), "should have has-count class"); equals(countCQ.size(), 1, 'should have count'); equals(countCQ.text(), cnt.toString(), 'should have count text');
function count(view, cnt) { if (cnt === null) { equals(view.$('.count').size(), 0, 'should not have count') ; } else { var cq = view.$('.count'); equals(cq.size(), 1, 'should have count'); equals(cq.text(), cnt.toString(), 'should have count'); }}
function CountCheckedRootLevels(field) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if ((TreeParents[field][i]==-1) && (TreeChecked[field][i]==1)) {count++;} } return count;
function CountCheckedRootLevels( field ) { var count = 0; for( var i = 0; i < TreeParents[field].length; i++ ) { if( ( TreeParents[field][i] == -1 ) && ( TreeChecked[field][i] == 1 ) ) { count++; }
function CountCheckedRootLevels(field) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if ((TreeParents[field][i]==-1) && (TreeChecked[field][i]==1)) {count++;} } return count; }
return( count ); }
function CountCheckedRootLevels(field) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if ((TreeParents[field][i]==-1) && (TreeChecked[field][i]==1)) {count++;} } return count; }
function CountChildren(field,node) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) {count++;} } return count;
function CountChildren( field, node ) { var count = 0; for( var i = 0; i < TreeParents[field].length; i++ ) { if( TreeParents[field][i] == node ) { count++; }
function CountChildren(field,node) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) {count++;} } return count; }
return( count ); }
function CountChildren(field,node) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if (TreeParents[field][i]==node) {count++;} } return count; }
function CountTickedChildren(field,node) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if ((TreeParents[field][i]==node) && (TreeChecked[field][i]==1)) {count++;} } return count;
function CountTickedChildren( field, node ) { var count = 0; for( var i = 0; i < TreeParents[field].length; i++ ) { if( ( TreeParents[field][i] == node ) && ( TreeChecked[field][i] == 1 ) ) { count++; }
function CountTickedChildren(field,node) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if ((TreeParents[field][i]==node) && (TreeChecked[field][i]==1)) {count++;} } return count; }
return( count ); }
function CountTickedChildren(field,node) { var count=0; var i=0; for (i=0;i<TreeParents[field].length;i++) { if ((TreeParents[field][i]==node) && (TreeChecked[field][i]==1)) {count++;} } return count; }
var bindingColumns = columnsByBindingType(bindingTypes[i], xsdTypes);
var bindingColumns = columnsByBindingType(bindingTypes[i].type, xsdTypes);
function countVariables(data, bindingTypes, xsdTypes){ var variables = new Array(); for (var i in bindingTypes) { var bindingColumns = columnsByBindingType(bindingTypes[i], xsdTypes); for (var j in bindingColumns) { var variable = { }; variable.variable = bindingColum...
variable.visType = bindingTypes[i].visType;
function countVariables(data, bindingTypes, xsdTypes){ var variables = new Array(); for (var i in bindingTypes) { var bindingColumns = columnsByBindingType(bindingTypes[i], xsdTypes); for (var j in bindingColumns) { var variable = { }; variable.variable = bindingColum...
var ret, idx, pool = SC.Set._pool, isObservable = this.isObservable;
var ret, idx, pool = SC.Set._pool, isObservable = this.isObservable, len;
create: function(items) { var ret, idx, pool = SC.Set._pool, isObservable = this.isObservable; if (!isObservable && items===undefined && pool.length>0) { return pool.pop(); } else { ret = SC.beget(this); if (isObservable) ret.initObservable(); if (items && items.isEnumerable && items.get(...
idx = items.get('length'); while(--idx>=0) ret.add(items.objectAt(idx));
len = items.get('length'); for(idx = 0; idx < len; idx++) ret.add(items.objectAt(idx));
create: function(items) { var ret, idx, pool = SC.Set._pool, isObservable = this.isObservable; if (!isObservable && items===undefined && pool.length>0) { return pool.pop(); } else { ret = SC.beget(this); if (isObservable) ret.initObservable(); if (items && items.isEnumerable && items.get(...
idx = items.length; while(--idx>=0) ret.add(items[idx]);
len = items.length; for(idx = 0; idx < len; idx++) ret.add(items[idx]);
create: function(items) { var ret, idx, pool = SC.Set._pool, isObservable = this.isObservable; if (!isObservable && items===undefined && pool.length>0) { return pool.pop(); } else { ret = SC.beget(this); if (isObservable) ret.initObservable(); if (items && items.isEnumerable && items.get(...
var el = doc.createElement(params.tag || 'div'); if(params.style) { $.style(el, params.style); } if(params.attrs) { for(attr in params.attrs) { el.setAttribute(attr, params.attrs[attr]);
var el = doc.createElement(params.tag || 'div'); if(params.style) { $.style(el, params.style); } if(params.attrs) { for(attr in params.attrs) { el.setAttribute(attr, params.attrs[attr]); }
$.create = function(params) { var doc = (params.win || window).document; if(!params) { params = 'div'; } if(typeof params == 'string') { return doc.createElement(params); } var el = doc.createElement(params.tag || 'div'); if(params.style) { $.style(el, params.style); } if(params.attrs) { for(attr in params.attrs) { ...
if(params['class'] || params['className']) { el.className = params['class'] || params['className']; } if(params.parent) { params.parent.appendChild(el); } if(params.html) { el.innerHTML = params.html; } if(params.text) { $.setText(el, params.text); } return el; }
$.create = function(params) { var doc = (params.win || window).document; if(!params) { params = 'div'; } if(typeof params == 'string') { return doc.createElement(params); } var el = doc.createElement(params.tag || 'div'); if(params.style) { $.style(el, params.style); } if(params.attrs) { for(attr in params.attrs) { ...
this._specializedRenderers = {};
create: function() { var result = SC.beget(this); result.baseTheme = this; // if we don't beget themes, the same instance would be shared between // all themes. this would be bad: imagine that we have two themes: // "Ace" and "Other." Each one has a "capsule" child theme. If they // didn't have thei...
tail = root,
tail = root;
SC._ChainObserver.createChain = function(rootObject, path, target, method, context) { // First we create the chain. var parts = path.split('.'), root = new SC._ChainObserver(parts[0]), tail = root, for(var i=1, l=parts.length; i<l; i++) { tail = tail.next = new SC._ChainObserver(parts[idx]) ; } // N...
tail = tail.next = new SC._ChainObserver(parts[idx]) ;
tail = tail.next = new SC._ChainObserver(parts[i]) ;
SC._ChainObserver.createChain = function(rootObject, path, target, method, context) { // First we create the chain. var parts = path.split('.'), root = new SC._ChainObserver(parts[0]), tail = root, for(var i=1, l=parts.length; i<l; i++) { tail = tail.next = new SC._ChainObserver(parts[idx]) ; } // N...
else attrs = SC.clone(attrs);
createChildView: function(view, attrs) { // attrs should always exist... if (!attrs) attrs = {} ; attrs.owner = attrs.parentView = this ; attrs.isVisibleInWindow = this.get('isVisibleInWindow'); if (!attrs.page) attrs.page = this.page ; // Now add this to the attributes and create. view = view.cr...
v.set("content", content);
v.bind('content', '.owner.content') ; } var vKey = v.get('contentValueKey') ; if (vKey && !v.get('value')) { v.bind('value', '.content.'+vKey) ;
createChildViews: function() { // keep array of keys so we can pass on key to child. var cv = SC.clone(this.get("childViews")); // add label if (this.labelView.isClass) { this.labelView = this.createChildView(this.labelView, { value: this.get("label") }); this.labelView.addObser...
this.rowLabelSizeDidChange();
createChildViews: function() { // keep array of keys so we can pass on key to child. var cv = SC.clone(this.get("childViews")); // add label if (this.labelView.isClass) { this.labelView = this.createChildView(this.labelView, { value: this.get("label") }); this.labelView.addObser...
if (!v.get("contentValueKey")) { v.set("contentValueKey", key); }
createChildViews: function() { // keep array of keys so we can pass on key to child. var cv = SC.clone(this.get("childViews")); var idx, len = cv.length, key, v, exampleRow = this.get("exampleRow"); // preprocess to handle templated rows (rows that use exampleRow to initialize) for (idx = 0; idx <...
v.set("content", content);
v.bind('content', '.owner.content') ;
createChildViews: function() { // keep array of keys so we can pass on key to child. var cv = SC.clone(this.get("childViews")); var idx, len = cv.length, key, v, exampleRow = this.get("exampleRow"); // preprocess to handle templated rows (rows that use exampleRow to initialize) for (idx = 0; idx <...
var idx, len = cv.length, key, v;
createChildViews: function() { // keep array of keys so we can pass on key to child. var cv = SC.clone(this.get("childViews")); var content = this.get("content"); sc_super(); // now, do the actual passing it var idx, len = cv.length, key, v; for (idx = 0; idx < len; idx++) { key = cv[id...
selection : createFlavoredString(window.getSelection()),
selection : (!!sel.raw)? sel : null,
createContext: function(target){ var ctx = update({ document :document, window : window, title : document.title, selection : createFlavoredString(window.getSelection()), target : target || TBRL.target || document.documentElement }, window.location); if(ctx.target){ ctx.link =...
selection : window.getSelection(),
selection : createFlavoredString(window.getSelection()),
createContext: function(target){ var ctx = update({ document :document, window : window, title : document.title, selection : window.getSelection(), target : target || TBRL.target || document.documentElement }, window.location); if(ctx.target){ ctx.link = $X('./ancestor-or-sel...
var res = src.textContent || src.toString(); res.flavors = { html : convertToHTMLString(src, true), }; return res;
return { raw : src.textContent || src.toString(), html : convertToHTMLString(src, true) };
function createFlavoredString(src){ var res = src.textContent || src.toString(); res.flavors = { html : convertToHTMLString(src, true), }; return res;}
if (outer != null) throw Components.results.NS_ERROR_NO_AGGREGATION; if (!clas.instance) clas.instance = new clas(); return clas.instance.QueryInterface(iid); }
if (outer != null) throw Components.results.NS_ERROR_NO_AGGREGATION; if (!Dactyl.instance) Dactyl.instance = new Dactyl(); return Dactyl.instance.QueryInterface(iid); }
createInstance: function (outer, iid) { if (outer != null) throw Components.results.NS_ERROR_NO_AGGREGATION; if (!clas.instance) clas.instance = new clas(); return clas.instance.QueryInterface(iid); }
factory.createInstance.apply(factory, arguments)
factory.createInstance.apply(factory, arguments);
createInstance: function (iids) { return let (factory = this.module.NSGetFactory(this.classID)) factory.createInstance.apply(factory, arguments) }
var room = $iq({to: room, type: "set"})
var roomiq = $iq({to: room, type: "set"})
createInstantRoom: function(room) { var room = $iq({to: room, type: "set"}) .c("query", {xmlns: Strophe.NS.MUC_OWNER}) .c("x", {xmlns: "jabber:x:data", type: "submit"}); return this._connection.sendIQ(room.tree(), ...
return this._connection.sendIQ(room.tree(),
return this._connection.sendIQ(roomiq.tree(),
createInstantRoom: function(room) { var room = $iq({to: room, type: "set"}) .c("query", {xmlns: Strophe.NS.MUC_OWNER}) .c("x", {xmlns: "jabber:x:data", type: "submit"}); return this._connection.sendIQ(room.tree(), ...
clone.setAttribute('title', cand.value);
createItem: function(cand){ var self = this; var clone = this.cloned.cloneNode(false); connect(clone, 'onclick', this, function(){ self.tags.injectCandidates(cand.value, true); this.hidePopup(); }); clone.appendChild($T(cand.value)); return clone; },
createRenderer: function() { var theme = this.get("theme");
createRenderer: function(theme) {
createRenderer: function() { var theme = this.get("theme"); var ret = theme.button(); this.updateRenderer(ret); // updating looks _exactly_ like normal stuff for us. return ret; },
if (style==="renderImage") ret = theme.image();
if (style==="renderImage") ret = theme.imageButton();
createRenderer: function(theme) { var ret, style = this.get('renderStyle'); if (style==="renderDefault") ret = theme.button(); if (style==="renderImage") ret = theme.image(); this.updateRenderer(ret); // updating looks _exactly_ like normal stuff for us. return ret; },
var ret = theme.button();
var ret, style = this.get('renderStyle'); if (style==="renderDefault") ret = theme.button(); if (style==="renderImage") ret = theme.image();
createRenderer: function(theme) { var ret = theme.button(); this.updateRenderer(ret); // updating looks _exactly_ like normal stuff for us. return ret; },
csp.createServer = function (connection_listener) { return new csp.Server().addListener('connection', connection_listener);
exports.createServer = function (connection_listener) { return new exports.Server().addListener('connection', connection_listener);
csp.createServer = function (connection_listener) { return new csp.Server().addListener('connection', connection_listener);};
lineSpan.appendChild(document.createTextNode(exampleLines[i]));
lineSpan.appendChild(document.createTextNode(doctest.rstrip(exampleLines[i])));
doctest.Example.prototype.createSpan = function () { var id = doctest.genID('example'); var span = document.createElement('span'); span.className = 'doctest-example'; span.setAttribute('id', id); this.htmlID = id; var exampleSpan = document.createElement('span'); exampleSpan.className = 'doctest-example-code'; ...
var xhr = new XMLHttpRequest(); xhr.open("GET", str, false); xhr.send(null); return xhr.responseXML;
var p = new DOMParser(); return p.parseFromString(str, "text/xml");
function createXML(str){ var xhr = new XMLHttpRequest(); xhr.open("GET", str, false); xhr.send(null); return xhr.responseXML;}
s.defaultView.getComputedStyle,Ka=c.support.cssFloat?"cssFloat":"styleFloat",la=function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return $(this,a,b,true,function(d,f,e){if(e===w)return c.curCSS(d,f);if(typeof e==="number"&&!ib.test(f))e+="px";c.style(d,f,e)})};c.extend({style:function(a,b,d){if(!a||a.nodeTyp...
function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return X(this,a,b,true,function(d,f,e){if(e===w)return c.curCSS(d,f);if(typeof e==="number"&&!kb.test(f))e+="px";c.style(d,f,e)})};c.extend({style:function(a,b,d){if(!a||a.nodeType===3||a.nodeType===8)return w;if((b==="width"||b==="height")&&parseFloat(d)<0)d...
s.defaultView.getComputedStyle,Ka=c.support.cssFloat?"cssFloat":"styleFloat",la=function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return $(this,a,b,true,function(d,f,e){if(e===w)return c.curCSS(d,f);if(typeof e==="number"&&!ib.test(f))e+="px";c.style(d,f,e)})};c.extend({style:function(a,b,d){if(!a||a.nodeTyp...
Element.Methods.cumulativeOffset = function(element) { var valueT = 0, valueL = 0; do { valueT += element.offsetTop || 0; valueL += element.offsetLeft || 0; if (element.offsetParent == document.body) if (Element.getStyle(element, 'position') == 'absolute') break; element = element.offsetParent; } while (element); re...
var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(...
Element.Methods.cumulativeOffset = function(element) { var valueT = 0, valueL = 0; do { valueT += element.offsetTop || 0; valueL += element.offsetLeft || 0; if (element.offsetParent == document.body) if (Element.getStyle(element, 'position') == 'absolute') break; element = element.of...
cumulativeScrollOffset: function(element) { var valueT = 0, valueL = 0; do { valueT += element.scrollTop || 0; valueL += element.scrollLeft || 0; element = element.parentNode; } while (element); return Element._returnOffset(valueL, valueT); },
var Prototype={Version:"1.6.1",Browser:(function(){var b=navigator.userAgent;var a=Object.prototype.toString.call(window.opera)=="[object Opera]";return{IE:!!window.attachEvent&&!a,Opera:a,WebKit:b.indexOf("AppleWebKit/")>-1,Gecko:b.indexOf("Gecko")>-1&&b.indexOf("KHTML")===-1,MobileSafari:/Apple.*Mobile.*Safari/.test(...
cumulativeScrollOffset: function(element) { var valueT = 0, valueL = 0; do { valueT += element.scrollTop || 0; valueL += element.scrollLeft || 0; element = element.parentNode; } while (element); return Element._returnOffset(valueL, valueT); },
b,d,f){return d+f*a},swing:function(a,b,d,f){return(-Math.cos(a*Math.PI)/2+0.5)*f+d}},timers:[],fx:function(a,b,d){this.options=b;this.elem=a;this.prop=d;if(!b.orig)b.orig={}}});c.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(c.fx.step[this.prop]||c.fx.step._default...
c.fx.step._default)(this);if((this.prop==="height"||this.prop==="width")&&this.elem.style)this.elem.style.display="block"},cur:function(a){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null))return this.elem[this.prop];return(a=parseFloat(c.css(this.elem,this.prop,a)))&&a>-10000?a:parseF...
b,d,f){return d+f*a},swing:function(a,b,d,f){return(-Math.cos(a*Math.PI)/2+0.5)*f+d}},timers:[],fx:function(a,b,d){this.options=b;this.elem=a;this.prop=d;if(!b.orig)b.orig={}}});c.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(c.fx.step[this.prop]||c.fx.step._default...
parseFloat(c.curCSS(a,"margin"+this,true))||0;else e-=parseFloat(c.curCSS(a,"border"+this+"Width",true))||0})}a.offsetWidth!==0?j():c.swap(a,mb,j);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&a.currentStyle){f=Ja.test(a.currentStyl...
"border"+this+"Width",true))||0})}a.offsetWidth!==0?i():c.swap(a,ob,i);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&a.currentStyle){f=Oa.test(a.currentStyle.filter||"")?parseFloat(RegExp.$1)/100+"":"";return f===""?"1":f}if(ha.test...
parseFloat(c.curCSS(a,"margin"+this,true))||0;else e-=parseFloat(c.curCSS(a,"border"+this+"Width",true))||0})}a.offsetWidth!==0?j():c.swap(a,mb,j);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&a.currentStyle){f=Ja.test(a.currentStyl...
return {'ids' : [id] }
return id;
currentChecked:function(){ var id = this.element.find("[type='radio']:checked").val(); if( id ){ return {'ids' : [id] } }else{ return null; } },