code
stringlengths
24
2.07M
docstring
stringlengths
25
85.3k
func_name
stringlengths
1
92
language
stringclasses
1 value
repo
stringlengths
5
64
path
stringlengths
4
172
url
stringlengths
44
218
license
stringclasses
7 values
function styleSheetCallback(styleSheets, sourceURL, continuation, styleSheet) { if (progressMonitor.canceled) return; if (styleSheet) { styleSheet.sourceURL = sourceURL; styleSheets.push(styleSheet); } if (continuation) continuation(styleSheets); }
The reported CSS rule size is incorrect (parsed != original in WebKit), so use percentages instead, which gives a better approximation. @constructor @extends {WebInspector.AuditRule}
styleSheetCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/AuditRules.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/AuditRules.js
MIT
function allStylesCallback(error, styleSheetInfos) { if (progressMonitor.canceled) return; if (error || !styleSheetInfos || !styleSheetInfos.length) return evalCallback([]); var styleSheets = []; for (var i = 0; i < styleSheetInfos.length; ++i) { var info = styleSheetInfos[i]; WebInspector.CSSStyleSheet.createForId(info.styleSheetId, styleSheetCallback.bind(null, styleSheets, info.sourceURL, i == styleSheetInfos.length - 1 ? evalCallback : null)); } }
The reported CSS rule size is incorrect (parsed != original in WebKit), so use percentages instead, which gives a better approximation. @constructor @extends {WebInspector.AuditRule}
allStylesCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/AuditRules.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/AuditRules.js
MIT
function binarySearch(object, array, comparator) { var first = 0; var last = array.length - 1; while (first <= last) { var mid = (first + last) >> 1; var c = comparator(object, array[mid]); if (c > 0) first = mid + 1; else if (c < 0) last = mid - 1; else return mid; } // Return the nearest lesser index, "-1" means "0, "-2" means "1", etc. return -(first + 1); }
@param {*} object @param {Array.<*>} array @param {function(*, *)} comparator
binarySearch
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/BinarySearch.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/BinarySearch.js
MIT
function insertionIndexForObjectInListSortedByFunction(anObject, aList, aFunction) { var index = binarySearch(anObject, aList, aFunction); if (index < 0) // See binarySearch implementation. return -index - 1; else { // Return the first occurance of an item in the list. while (index > 0 && aFunction(anObject, aList[index - 1]) === 0) index--; return index; } }
@param {*} anObject @param {Array.<*>} aList @param {function(*, *)} aFunction
insertionIndexForObjectInListSortedByFunction
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/BinarySearch.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/BinarySearch.js
MIT
function didSetBreakpoint(breakpointId, locations) { if (breakpoint === this._breakpoint(breakpoint.uiSourceCodeId, breakpoint.lineNumber)) { if (!breakpointId) { if (breakpoint.uiBreakpoint) this._removeBreakpointFromUI(breakpoint.uiBreakpoint); this._removeBreakpointFromModel(breakpoint); return; } } else { if (breakpointId) this._debuggerModel.removeBreakpoint(breakpointId); return; } this._breakpointsByDebuggerId[breakpointId] = breakpoint; breakpoint._debuggerId = breakpointId; breakpoint._debuggerLocation = locations[0]; if (breakpoint._debuggerLocation) this._breakpointDebuggerLocationChanged(breakpoint); }
@this {WebInspector.BreakpointManager} @param {DebuggerAgent.BreakpointId} breakpointId @param {Array.<DebuggerAgent.Location>} locations
didSetBreakpoint
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/BreakpointManager.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/BreakpointManager.js
MIT
function serializePersistent(breakpoint) { if (breakpoint.persistent) serializedBreakpoints.push(breakpoint.serialize()); }
@this {WebInspector.BreakpointManager} @param {WebInspector.Breakpoint} breakpoint
serializePersistent
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/BreakpointManager.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/BreakpointManager.js
MIT
function resetBreakpoint(breakpoint) { this._removeBreakpointFromDebugger(breakpoint); delete breakpoint._materialized; }
@this {WebInspector.BreakpointManager} @param {WebInspector.Breakpoint} breakpoint
resetBreakpoint
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/BreakpointManager.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/BreakpointManager.js
MIT
function resetOrDeleteBreakpoint(breakpoint) { if (breakpoint.uiBreakpoint) this._removeBreakpointFromUI(breakpoint.uiBreakpoint); if (breakpoint.persistent) delete breakpoint._debuggerLocation; else { this._removeBreakpointFromModel(breakpoint); delete this._breakpointsByDebuggerId[breakpoint._debuggerId]; } }
@this {WebInspector.BreakpointManager} @param {WebInspector.Breakpoint} breakpoint
resetOrDeleteBreakpoint
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/BreakpointManager.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/BreakpointManager.js
MIT
function hueToRGB(p, q, h) { if (h < 0) h += 1; else if (h > 1) h -= 1; if ((h * 6) < 1) return p + (q - p) * h * 6; else if ((h * 2) < 1) return q; else if ((h * 3) < 2) return p + (q - p) * ((2 / 3) - h) * 6; else return p; }
@param {Array.<number>} hsl @return {Array.<number>}
hueToRGB
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/Color.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/Color.js
MIT
get message() { // force message formatting var formattedMessage = this.formattedMessage; return this._message; }
@constructor @extends {WebInspector.ConsoleMessage} @param {string} source @param {string} level @param {string} message @param {WebInspector.DebuggerPresentationModel.Linkifier} linkifier @param {string=} type @param {string=} url @param {number=} line @param {number=} repeatCount @param {Array.<RuntimeAgent.RemoteObject>=} parameters @param {ConsoleAgent.StackTrace=} stackTrace @param {WebInspector.Resource=} request
message
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleMessage.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleMessage.js
MIT
get formattedMessage() { if (!this._formattedMessage) this._formatMessage(); return this._formattedMessage; }
@constructor @extends {WebInspector.ConsoleMessage} @param {string} source @param {string} level @param {string} message @param {WebInspector.DebuggerPresentationModel.Linkifier} linkifier @param {string=} type @param {string=} url @param {number=} line @param {number=} repeatCount @param {Array.<RuntimeAgent.RemoteObject>=} parameters @param {ConsoleAgent.StackTrace=} stackTrace @param {WebInspector.Resource=} request
formattedMessage
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleMessage.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleMessage.js
MIT
function createDividerElement() { var dividerElement = document.createElement("div"); dividerElement.addStyleClass("scope-bar-divider"); this._filterBarElement.appendChild(dividerElement); }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
createDividerElement
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function createFilterElement(category, label) { var categoryElement = document.createElement("li"); categoryElement.category = category; categoryElement.className = category; categoryElement.addEventListener("click", updateFilterHandler, false); categoryElement.textContent = label; this._filterBarElement.appendChild(categoryElement); return categoryElement; }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
createFilterElement
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
get statusBarItems() { return [this._clearConsoleButton.element, this._contextSelectElement, this._filterBarElement]; }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
statusBarItems
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function unselectAll() { this.allElement.removeStyleClass("selected"); this.errorElement.removeStyleClass("selected"); this.warningElement.removeStyleClass("selected"); this.logElement.removeStyleClass("selected"); this.messagesElement.removeStyleClass("filter-all"); this.messagesElement.removeStyleClass("filter-errors"); this.messagesElement.removeStyleClass("filter-warnings"); this.messagesElement.removeStyleClass("filter-logs"); }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
unselectAll
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function scrollIntoView() { delete this._scrollIntoViewTimer; this.promptElement.scrollIntoView(true); }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
scrollIntoView
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function evaluated(result, wasThrown) { if (!result || wasThrown) { completionsReadyCallback([]); return; } function getCompletions(primitiveType) { var object; if (primitiveType === "string") object = new String(""); else if (primitiveType === "number") object = new Number(0); else if (primitiveType === "boolean") object = new Boolean(false); else object = this; var resultSet = {}; for (var o = object; o; o = o.__proto__) { try { var names = Object.getOwnPropertyNames(o); for (var i = 0; i < names.length; ++i) resultSet[names[i]] = true; } catch (e) { } } return resultSet; } if (result.type === "object" || result.type === "function") result.callFunctionJSON(getCompletions, undefined, receivedPropertyNames.bind(this)); else if (result.type === "string" || result.type === "number" || result.type === "boolean") this.evalInInspectedWindow("(" + getCompletions + ")(\"" + result.type + "\")", "completion", false, true, true, receivedPropertyNamesFromEval.bind(this)); }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
evaluated
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function getCompletions(primitiveType) { var object; if (primitiveType === "string") object = new String(""); else if (primitiveType === "number") object = new Number(0); else if (primitiveType === "boolean") object = new Boolean(false); else object = this; var resultSet = {}; for (var o = object; o; o = o.__proto__) { try { var names = Object.getOwnPropertyNames(o); for (var i = 0; i < names.length; ++i) resultSet[names[i]] = true; } catch (e) { } } return resultSet; }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
getCompletions
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function receivedPropertyNamesFromEval(notRelevant, wasThrown, result) { if (result && !wasThrown) receivedPropertyNames.call(this, result.value); else completionsReadyCallback([]); }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
receivedPropertyNamesFromEval
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function receivedPropertyNames(propertyNames) { RuntimeAgent.releaseObjectGroup("completion"); if (!propertyNames) { completionsReadyCallback([]); return; } var includeCommandLineAPI = (!dotNotation && !bracketNotation); if (includeCommandLineAPI) { const commandLineAPI = ["dir", "dirxml", "keys", "values", "profile", "profileEnd", "monitorEvents", "unmonitorEvents", "inspect", "copy", "clear"]; for (var i = 0; i < commandLineAPI.length; ++i) propertyNames[commandLineAPI[i]] = true; } this._reportCompletions(completionsReadyCallback, dotNotation, bracketNotation, expressionString, prefix, Object.keys(propertyNames)); }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
receivedPropertyNames
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function monitoringXHRItemAction() { WebInspector.settings.monitoringXHREnabled.set(!WebInspector.settings.monitoringXHREnabled.get()); }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
monitoringXHRItemAction
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function preserveLogItemAction() { WebInspector.settings.preserveConsoleLog.set(!WebInspector.settings.preserveConsoleLog.get()); }
@extends {WebInspector.View} @constructor @param {boolean} hideContextSelector
preserveLogItemAction
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function evalCallback(error, result, wasThrown) { if (error) { console.error(error); callback(null, false); return; } if (returnByValue) callback(null, wasThrown, wasThrown ? null : result); else callback(WebInspector.RemoteObject.fromPayload(result), wasThrown); }
@param {string} expression @param {string} objectGroup @param {boolean} includeCommandLineAPI @param {boolean} doNotPauseOnExceptions @param {boolean} returnByValue @param {function(?WebInspector.RemoteObject, boolean, RuntimeAgent.RemoteObject=)} callback
evalCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function printResult(result, wasThrown) { if (!result) return; if (!showResultOnly) { this.prompt.pushHistoryItem(text); WebInspector.settings.consoleHistory.set(this.prompt.historyData.slice(-30)); } this._appendConsoleMessage(new WebInspector.ConsoleCommandResult(result, wasThrown, commandMessage, this._linkifier)); }
@param {string} expression @param {string} objectGroup @param {boolean} includeCommandLineAPI @param {boolean} doNotPauseOnExceptions @param {boolean} returnByValue @param {function(?WebInspector.RemoteObject, boolean, RuntimeAgent.RemoteObject=)} callback
printResult
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function comparator(a, b) { if (a.size < b.size) return 1; if (a.size > b.size) return -1; return a.title.localeCompare(b.title); }
@param {string} expression @param {string} objectGroup @param {boolean} includeCommandLineAPI @param {boolean} doNotPauseOnExceptions @param {boolean} returnByValue @param {function(?WebInspector.RemoteObject, boolean, RuntimeAgent.RemoteObject=)} callback
comparator
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function callback(error, groups) { var titles = []; groups.sort(comparator); for (var i = 0; i < groups.length; ++i) { var suffix = groups[i].size > 0 ? " [" + groups[i].size + "]" : ""; titles.push(groups[i].title + suffix + (groups[i].documentURI ? " (" + groups[i].documentURI + ")" : "")); } var counter = 1; var previousTitle = null; for (var i = 0; i < titles.length; ++i) { var title = titles[i]; if (title === previousTitle) { counter++; continue; } if (previousTitle) WebInspector.log(counter > 1 ? counter + " x " + previousTitle : previousTitle); previousTitle = title; counter = 1; } WebInspector.log(counter > 1 ? counter + " x " + previousTitle : previousTitle); }
@param {string} expression @param {string} objectGroup @param {boolean} includeCommandLineAPI @param {boolean} doNotPauseOnExceptions @param {boolean} returnByValue @param {function(?WebInspector.RemoteObject, boolean, RuntimeAgent.RemoteObject=)} callback
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ConsoleView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ConsoleView.js
MIT
function maybeCallback() { if (scriptsLeft) return; var result = []; for (var i = 0; i < scripts.length; ++i) result = result.concat(results[scripts[i].scriptId]); callback(result); }
@param {string} query @param {boolean} caseSensitive @param {boolean} isRegex @param {function(Array.<WebInspector.ContentProvider.SearchMatch>)} callback
maybeCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ContentProviders.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ContentProviders.js
MIT
function searchCallback(script, searchMatches) { results[script.scriptId] = []; for (var i = 0; i < searchMatches.length; ++i) { var searchMatch = new WebInspector.ContentProvider.SearchMatch(searchMatches[i].lineNumber + script.lineOffset, searchMatches[i].lineContent); results[script.scriptId].push(searchMatch); } scriptsLeft--; maybeCallback.call(this); }
@param {WebInspector.Script} script @param {Array.<PageAgent.SearchMatch>} searchMatches
searchCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ContentProviders.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ContentProviders.js
MIT
function performSearch() { var regex = createSearchRegex(query, caseSensitive, isRegex); var result = []; var lineEndings = this._content.lineEndings(); for (var i = 0; i < lineEndings.length; ++i) { var lineStart = i > 0 ? lineEndings[i - 1] + 1 : 0; var lineEnd = lineEndings[i]; var lineContent = this._content.substring(lineStart, lineEnd); if (lineContent.length > 0 && lineContent.charAt(lineContent.length - 1) === "\r") lineContent = lineContent.substring(0, lineContent.length - 1) if (regex.exec(lineContent)) result.push(new WebInspector.ContentProvider.SearchMatch(i, lineContent)); } callback(result); }
@param {string} query @param {boolean} caseSensitive @param {boolean} isRegex @param {function(Array.<WebInspector.ContentProvider.SearchMatch>)} callback
performSearch
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ContentProviders.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ContentProviders.js
MIT
get selectedCookie() { var node = this._dataGrid.selectedNode; return node ? node.cookie : null; }
@constructor @extends {WebInspector.View} @param {function(PageAgent.Cookie)=} deleteCallback @param {function()=} refreshCallback
selectedCookie
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CookiesTable.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CookiesTable.js
MIT
function localeCompare(field, cookie1, cookie2) { return sortDirection * (cookie1[field] + "").localeCompare(cookie2[field] + "") }
@constructor @extends {WebInspector.View} @param {function(PageAgent.Cookie)=} deleteCallback @param {function()=} refreshCallback
localeCompare
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CookiesTable.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CookiesTable.js
MIT
function numberCompare(field, cookie1, cookie2) { return sortDirection * (cookie1[field] - cookie2[field]); }
@constructor @extends {WebInspector.View} @param {function(PageAgent.Cookie)=} deleteCallback @param {function()=} refreshCallback
numberCompare
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CookiesTable.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CookiesTable.js
MIT
function expiresCompare(cookie1, cookie2) { if (cookie1.session !== cookie2.session) return sortDirection * (cookie1.session ? 1 : -1); if (cookie1.session) return 0; return sortDirection * (cookie1.expires - cookie2.expires); }
@constructor @extends {WebInspector.View} @param {function(PageAgent.Cookie)=} deleteCallback @param {function()=} refreshCallback
expiresCompare
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CookiesTable.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CookiesTable.js
MIT
get data() { var data = {}; data.selector = this._data.selector; data.matches = this._data.matchCount; if (this._profileView.showTimeAsPercent.get()) data.time = Number(this._data.timePercent).toFixed(1) + "%"; else data.time = Number.secondsToString(this._data.time / 1000, true); return data; }
@constructor @extends WebInspector.DataGridNode @param {WebInspector.CSSSelectorProfileView} profileView
data
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
get rawData() { return this._data; }
@constructor @extends WebInspector.DataGridNode @param {WebInspector.CSSSelectorProfileView} profileView
rawData
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
get statusBarItems() { return [this.percentButton.element]; }
@constructor @extends WebInspector.View @param {CSSAgent.SelectorProfile} profile
statusBarItems
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
get profile() { return this._profile; }
@constructor @extends WebInspector.View @param {CSSAgent.SelectorProfile} profile
profile
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
set profile(profile) { this._profile = profile; }
@constructor @extends WebInspector.View @param {CSSAgent.SelectorProfile} profile
profile
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
function selectorComparator(a, b) { var result = b.rawData.selector.localeCompare(a.rawData.selector); return sortAscending ? -result : result; }
@constructor @extends WebInspector.View @param {CSSAgent.SelectorProfile} profile
selectorComparator
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
function sourceComparator(a, b) { var aRawData = a.rawData; var bRawData = b.rawData; var result = bRawData.url.localeCompare(aRawData.url); if (!result) result = bRawData.lineNumber - aRawData.lineNumber; return sortAscending ? -result : result; }
@constructor @extends WebInspector.View @param {CSSAgent.SelectorProfile} profile
sourceComparator
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
function timeComparator(a, b) { const result = b.rawData.time - a.rawData.time; return sortAscending ? -result : result; }
@constructor @extends WebInspector.View @param {CSSAgent.SelectorProfile} profile
timeComparator
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
function matchesComparator(a, b) { const result = b.rawData.matchCount - a.rawData.matchCount; return sortAscending ? -result : result; }
@constructor @extends WebInspector.View @param {CSSAgent.SelectorProfile} profile
matchesComparator
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSSelectorProfileView.js
MIT
function callback(userCallback, error, matchedPayload, pseudoPayload, inheritedPayload) { if (error) { if (userCallback) userCallback(null); return; } var result = {}; if (matchedPayload) result.matchedCSSRules = WebInspector.CSSStyleModel.parseRuleArrayPayload(matchedPayload); if (pseudoPayload) { result.pseudoElements = []; for (var i = 0; i < pseudoPayload.length; ++i) { var entryPayload = pseudoPayload[i]; result.pseudoElements.push({ pseudoId: entryPayload.pseudoId, rules: WebInspector.CSSStyleModel.parseRuleArrayPayload(entryPayload.rules) }); } } if (inheritedPayload) { result.inherited = []; for (var i = 0; i < inheritedPayload.length; ++i) { var entryPayload = inheritedPayload[i]; var entry = {}; if (entryPayload.inlineStyle) entry.inlineStyle = WebInspector.CSSStyleDeclaration.parsePayload(entryPayload.inlineStyle); if (entryPayload.matchedCSSRules) entry.matchedCSSRules = WebInspector.CSSStyleModel.parseRuleArrayPayload(entryPayload.matchedCSSRules); result.inherited.push(entry); } } if (userCallback) userCallback(result); }
@param {function(?*)} userCallback @param {?Protocol.Error} error @param {Array.<CSSAgent.CSSRule>=} matchedPayload @param {Array.<CSSAgent.PseudoIdRules>=} pseudoPayload @param {Array.<CSSAgent.InheritedStyleEntry>=} inheritedPayload
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function callback(userCallback, error, inlinePayload, attributesStylePayload) { if (error || !inlinePayload) userCallback(null, null); else userCallback(WebInspector.CSSStyleDeclaration.parsePayload(inlinePayload), attributesStylePayload ? WebInspector.CSSStyleDeclaration.parsePayload(attributesStylePayload) : null); }
@param {function(?WebInspector.CSSStyleDeclaration, ?WebInspector.CSSStyleDeclaration)} userCallback
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function checkAffectsCallback(nodeId, successCallback, rulePayload, selectedNodeIds) { if (!selectedNodeIds) return; var doesAffectSelectedNode = (selectedNodeIds.indexOf(nodeId) >= 0); var rule = WebInspector.CSSRule.parsePayload(rulePayload); successCallback(rule, doesAffectSelectedNode); }
@param {DOMAgent.NodeId} nodeId @param {function(WebInspector.CSSRule, boolean)} successCallback @param {*} rulePayload @param {?Array.<DOMAgent.NodeId>} selectedNodeIds
checkAffectsCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function callback(nodeId, successCallback, failureCallback, newSelector, error, rulePayload) { this._pendingCommandsMajorState.pop(); if (error) failureCallback(); else { WebInspector.domAgent.markUndoableState(); var ownerDocumentId = this._ownerDocumentId(nodeId); if (ownerDocumentId) WebInspector.domAgent.querySelectorAll(ownerDocumentId, newSelector, checkAffectsCallback.bind(this, nodeId, successCallback, rulePayload)); else failureCallback(); } }
@param {DOMAgent.NodeId} nodeId @param {function(WebInspector.CSSRule, boolean)} successCallback @param {function()} failureCallback @param {?Protocol.Error} error @param {string} newSelector @param {*=} rulePayload
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function checkAffectsCallback(nodeId, successCallback, rulePayload, selectedNodeIds) { if (!selectedNodeIds) return; var doesAffectSelectedNode = (selectedNodeIds.indexOf(nodeId) >= 0); var rule = WebInspector.CSSRule.parsePayload(rulePayload); successCallback(rule, doesAffectSelectedNode); }
@param {DOMAgent.NodeId} nodeId @param {string} selector @param {function(WebInspector.CSSRule, boolean)} successCallback @param {function()} failureCallback
checkAffectsCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function callback(successCallback, failureCallback, selector, error, rulePayload) { this._pendingCommandsMajorState.pop(); if (error) { // Invalid syntax for a selector failureCallback(); } else { WebInspector.domAgent.markUndoableState(); var ownerDocumentId = this._ownerDocumentId(nodeId); if (ownerDocumentId) WebInspector.domAgent.querySelectorAll(ownerDocumentId, selector, checkAffectsCallback.bind(this, nodeId, successCallback, rulePayload)); else failureCallback(); } }
@param {function(WebInspector.CSSRule, boolean)} successCallback @param {function()} failureCallback @param {string} selector @param {?Protocol.Error} error @param {?CSSAgent.CSSRule} rulePayload
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function callback(error) { this._pendingCommandsMajorState.pop(); if (!error && majorChange) WebInspector.domAgent.markUndoableState(); if (!error && userCallback) userCallback(error); }
@param {function(WebInspector.CSSRule, boolean)} successCallback @param {function()} failureCallback @param {string} selector @param {?Protocol.Error} error @param {?CSSAgent.CSSRule} rulePayload
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function enabledCallback(style) { if (userCallback) userCallback(style); }
Replaces "propertyName: propertyValue [!important];" in the stylesheet by an arbitrary propertyText. @param {string} propertyText @param {boolean} majorChange @param {boolean} overwrite @param {Function=} userCallback
enabledCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function callback(error, stylePayload) { WebInspector.cssModel._pendingCommandsMajorState.pop(); if (!error) { if (majorChange) WebInspector.domAgent.markUndoableState(); this.text = propertyText; var style = WebInspector.CSSStyleDeclaration.parsePayload(stylePayload); var newProperty = style.allProperties[this.index]; if (newProperty && this.disabled && !propertyText.match(/^\s*$/)) { newProperty.setDisabled(false, enabledCallback); return; } if (userCallback) userCallback(style); } else { if (userCallback) userCallback(null); } }
Replaces "propertyName: propertyValue [!important];" in the stylesheet by an arbitrary propertyText. @param {string} propertyText @param {boolean} majorChange @param {boolean} overwrite @param {Function=} userCallback
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function callback(error, stylePayload) { WebInspector.cssModel._pendingCommandsMajorState.pop(); if (error) { if (userCallback) userCallback(null); return; } WebInspector.domAgent.markUndoableState(); if (userCallback) { var style = WebInspector.CSSStyleDeclaration.parsePayload(stylePayload); userCallback(style); } }
@param {string} newValue @param {boolean} majorChange @param {boolean} overwrite @param {Function=} userCallback
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/CSSStyleModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/CSSStyleModel.js
MIT
function callback(error, success, transactionId) { if (error) { onError(error); return; } if (!success) { onError(WebInspector.UIString("Database not found.")); return; } WebInspector.DatabaseDispatcher._callbacks[transactionId] = {"onSuccess": onSuccess, "onError": onError}; }
@param {string} query @param {function(Array.<string>, Array.<*>)} onSuccess @param {function(DatabaseAgent.Error)} onError
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/Database.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/Database.js
MIT
function sortDataGrid() { var nodes = dataGrid.children.slice(); var sortColumnIdentifier = dataGrid.sortColumnIdentifier; var sortDirection = dataGrid.sortOrder === "ascending" ? 1 : -1; var columnIsNumeric = true; for (var i = 0; i < nodes.length; i++) { if (isNaN(Number(nodes[i].data[sortColumnIdentifier]))) columnIsNumeric = false; } function comparator(dataGridNode1, dataGridNode2) { var item1 = dataGridNode1.data[sortColumnIdentifier]; var item2 = dataGridNode2.data[sortColumnIdentifier]; var comparison; if (columnIsNumeric) { // Sort numbers based on comparing their values rather than a lexicographical comparison. var number1 = parseFloat(item1); var number2 = parseFloat(item2); comparison = number1 < number2 ? -1 : (number1 > number2 ? 1 : 0); } else comparison = item1 < item2 ? -1 : (item1 > item2 ? 1 : 0); return sortDirection * comparison; } nodes.sort(comparator); dataGrid.removeChildren(); for (var i = 0; i < nodes.length; i++) dataGrid.appendChild(nodes[i]); }
@param {Array.<string>} columnNames @param {Array.<string>} values
sortDataGrid
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
function comparator(dataGridNode1, dataGridNode2) { var item1 = dataGridNode1.data[sortColumnIdentifier]; var item2 = dataGridNode2.data[sortColumnIdentifier]; var comparison; if (columnIsNumeric) { // Sort numbers based on comparing their values rather than a lexicographical comparison. var number1 = parseFloat(item1); var number2 = parseFloat(item2); comparison = number1 < number2 ? -1 : (number1 > number2 ? 1 : 0); } else comparison = item1 < item2 ? -1 : (item1 > item2 ? 1 : 0); return sortDirection * comparison; }
@param {Array.<string>} columnNames @param {Array.<string>} values
comparator
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get refreshCallback() { return this._refreshCallback; }
@param {Array.<string>} columnNames @param {Array.<string>} values
refreshCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
set refreshCallback(refreshCallback) { this._refreshCallback = refreshCallback; }
@param {Array.<string>} columnNames @param {Array.<string>} values
refreshCallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
function moveToNextIfNeeded(wasChange) { if (!moveDirection) return; if (moveDirection === "forward") { if (currentEditingNode.isCreationNode && columnIdentifier === 0 && !wasChange) return; if (columnIdentifier === 0) return this._startEditingColumnOfDataGridNode(currentEditingNode, 1); var nextDataGridNode = currentEditingNode.traverseNextNode(true, null, true); if (nextDataGridNode) return this._startEditingColumnOfDataGridNode(nextDataGridNode, 0); if (currentEditingNode.isCreationNode && wasChange) { this.addCreationNode(false); return this._startEditingColumnOfDataGridNode(this.creationNode, 0); } return; } if (moveDirection === "backward") { if (columnIdentifier === 1) return this._startEditingColumnOfDataGridNode(currentEditingNode, 0); var nextDataGridNode = currentEditingNode.traversePreviousNode(true, null, true); if (nextDataGridNode) return this._startEditingColumnOfDataGridNode(nextDataGridNode, 1); return; } }
@param {Array.<string>} columnNames @param {Array.<string>} values
moveToNextIfNeeded
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get sortColumnIdentifier() { if (!this._sortColumnCell) return null; return this._sortColumnCell.columnIdentifier; }
@param {Array.<string>} columnNames @param {Array.<string>} values
sortColumnIdentifier
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get sortOrder() { if (!this._sortColumnCell || this._sortColumnCell.hasStyleClass("sort-ascending")) return "ascending"; if (this._sortColumnCell.hasStyleClass("sort-descending")) return "descending"; return null; }
@param {Array.<string>} columnNames @param {Array.<string>} values
sortOrder
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get headerTableBody() { if ("_headerTableBody" in this) return this._headerTableBody; this._headerTableBody = this._headerTable.getElementsByTagName("tbody")[0]; if (!this._headerTableBody) { this._headerTableBody = this.element.ownerDocument.createElement("tbody"); this._headerTable.insertBefore(this._headerTableBody, this._headerTable.tFoot); } return this._headerTableBody; }
@param {Array.<string>} columnNames @param {Array.<string>} values
headerTableBody
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get dataTableBody() { if ("_dataTableBody" in this) return this._dataTableBody; this._dataTableBody = this._dataTable.getElementsByTagName("tbody")[0]; if (!this._dataTableBody) { this._dataTableBody = this.element.ownerDocument.createElement("tbody"); this._dataTable.insertBefore(this._dataTableBody, this._dataTable.tFoot); } return this._dataTableBody; }
@param {Array.<string>} columnNames @param {Array.<string>} values
dataTableBody
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get element() { if (this._element) return this._element; if (!this.dataGrid) return null; this._element = document.createElement("tr"); this._element._dataGridNode = this; if (this.hasChildren) this._element.addStyleClass("parent"); if (this.expanded) this._element.addStyleClass("expanded"); if (this.selected) this._element.addStyleClass("selected"); if (this.revealed) this._element.addStyleClass("revealed"); this.createCells(); return this._element; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
element
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get data() { return this._data; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
data
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
set data(x) { this._data = x || {}; this.refresh(); }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
data
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get revealed() { if ("_revealed" in this) return this._revealed; var currentAncestor = this.parent; while (currentAncestor && !currentAncestor.root) { if (!currentAncestor.expanded) { this._revealed = false; return false; } currentAncestor = currentAncestor.parent; } this._revealed = true; return true; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
revealed
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
set hasChildren(x) { if (this._hasChildren === x) return; this._hasChildren = x; if (!this._element) return; if (this._hasChildren) { this._element.addStyleClass("parent"); if (this.expanded) this._element.addStyleClass("expanded"); } else { this._element.removeStyleClass("parent"); this._element.removeStyleClass("expanded"); } }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
hasChildren
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get hasChildren() { return this._hasChildren; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
hasChildren
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
set revealed(x) { if (this._revealed === x) return; this._revealed = x; if (this._element) { if (this._revealed) this._element.addStyleClass("revealed"); else this._element.removeStyleClass("revealed"); } for (var i = 0; i < this.children.length; ++i) this.children[i].revealed = x && this.expanded; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
revealed
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get depth() { if ("_depth" in this) return this._depth; if (this.parent && !this.parent.root) this._depth = this.parent.depth + 1; else this._depth = 0; return this._depth; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
depth
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get leftPadding() { if (typeof(this._leftPadding) === "number") return this._leftPadding; this._leftPadding = this.depth * this.dataGrid.indentWidth; return this._leftPadding; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
leftPadding
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get shouldRefreshChildren() { return this._shouldRefreshChildren; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
shouldRefreshChildren
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
set shouldRefreshChildren(x) { this._shouldRefreshChildren = x; if (x && this.expanded) this.expand(); }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
shouldRefreshChildren
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get selected() { return this._selected; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
selected
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
set selected(x) { if (x) this.select(); else this.deselect(); }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
selected
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
get expanded() { return this._expanded; }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
expanded
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
set expanded(x) { if (x) this.expand(); else this.collapse(); }
@constructor @extends {WebInspector.Object} @param {boolean=} hasChildren
expanded
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DataGrid.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DataGrid.js
MIT
function callback(error, result) { this._canSetScriptSource = result; }
@constructor @extends {DebuggerAgent.Location} @param {WebInspector.Script} script @param {number} lineNumber @param {number} columnNumber
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerModel.js
MIT
function didSetBreakpoint(error, breakpointId, locations) { if (callback) callback(error ? null : breakpointId, locations); }
@this {WebInspector.DebuggerModel} @param {?Protocol.Error} error @param {DebuggerAgent.BreakpointId} breakpointId @param {Array.<DebuggerAgent.Location>=} locations
didSetBreakpoint
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerModel.js
MIT
function didSetBreakpoint(error, breakpointId, actualLocation) { if (callback) callback(error ? null : breakpointId, [actualLocation]); }
@this {WebInspector.DebuggerModel} @param {?Protocol.Error} error @param {DebuggerAgent.BreakpointId} breakpointId @param {DebuggerAgent.Location} actualLocation
didSetBreakpoint
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerModel.js
MIT
function didEditScriptSource(error) { callback(error); if (error) return; var resource = WebInspector.resourceForURL(script.sourceURL); if (resource) resource.addRevision(newSource); uiSourceCode.contentChanged(newSource); if (WebInspector.debuggerModel.callFrames) this._debuggerPaused(); }
@this {WebInspector.DebuggerPresentationModel} @param {?Protocol.Error} error
didEditScriptSource
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
function updateLocation(uiLocation) { var presentationMessage = new WebInspector.PresentationConsoleMessage(uiLocation.uiSourceCode, uiLocation.lineNumber, message); this._presentationConsoleMessages.push(presentationMessage); this.dispatchEventToListeners(WebInspector.DebuggerPresentationModel.Events.ConsoleMessageAdded, presentationMessage); }
@param {WebInspector.ConsoleMessage} message @param {DebuggerAgent.Location} rawLocation
updateLocation
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
get paused() { return !!WebInspector.debuggerModel.debuggerPausedDetails; }
@param {WebInspector.UISourceCode} uiSourceCode @param {number} lineNumber @return {WebInspector.UIBreakpoint|undefined}
paused
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
set selectedCallFrame(callFrame) { if (this._executionLineLiveLocation) this._executionLineLiveLocation.dispose(); delete this._executionLineLiveLocation; this._selectedCallFrame = callFrame; if (!this._selectedCallFrame) return; this._scriptMapping.forceUpdateSourceMapping(callFrame._callFrame.location); this.dispatchEventToListeners(WebInspector.DebuggerPresentationModel.Events.CallFrameSelected, callFrame); function updateExecutionLine(uiLocation) { this.dispatchEventToListeners(WebInspector.DebuggerPresentationModel.Events.ExecutionLineChanged, uiLocation); } this._executionLineLiveLocation = this.createLiveLocation(callFrame._callFrame.location, updateExecutionLine.bind(this)); this._executionLineLiveLocation.init(); }
@param {WebInspector.UISourceCode} uiSourceCode @param {number} lineNumber @return {WebInspector.UIBreakpoint|undefined}
selectedCallFrame
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
function updateExecutionLine(uiLocation) { this.dispatchEventToListeners(WebInspector.DebuggerPresentationModel.Events.ExecutionLineChanged, uiLocation); }
@param {WebInspector.UISourceCode} uiSourceCode @param {number} lineNumber @return {WebInspector.UIBreakpoint|undefined}
updateExecutionLine
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
get selectedCallFrame() { return this._selectedCallFrame; }
@param {WebInspector.UISourceCode} uiSourceCode @param {number} lineNumber @return {WebInspector.UIBreakpoint|undefined}
selectedCallFrame
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
function didEvaluate(result, wasThrown) { if (returnByValue) callback(null, wasThrown, wasThrown ? null : result); else callback(WebInspector.RemoteObject.fromPayload(result), wasThrown); if (objectGroup === "console") this.dispatchEventToListeners(WebInspector.DebuggerPresentationModel.Events.ConsoleCommandEvaluatedInSelectedCallFrame); }
@param {?RuntimeAgent.RemoteObject} result @param {boolean} wasThrown
didEvaluate
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
function didEvaluateOnCallFrame(error, result, wasThrown) { if (error) { console.error(error); callback(null, false); return; } callback(result, wasThrown); }
@this {WebInspector.PresentationCallFrame} @param {?Protocol.Error} error @param {RuntimeAgent.RemoteObject} result @param {boolean=} wasThrown
didEvaluateOnCallFrame
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
function callback(error) { if (userCallback) userCallback(error); if (!error) this._presentationModel._updateBreakpointsAfterLiveEdit(uiSourceCode, oldContent || "", content); }
@this {WebInspector.DebuggerPresentationModelResourceBinding} @param {?string} error
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DebuggerPresentationModel.js
MIT
function mycallback(error, success) { if (!error) { delete this._attributesMap[name]; for (var i = 0; i < this._attributes.length; ++i) { if (this._attributes[i].name === name) { this._attributes.splice(i, 1); break; } } } WebInspector.domAgent._markRevision(this, callback)(error); }
@param {string} name @param {function(?Protocol.Error)=} callback
mycallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DOMAgent.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DOMAgent.js
MIT
function mycallback(error) { if (!error && callback) callback(this.children); }
@this {WebInspector.DOMNode} @param {?Protocol.Error} error
mycallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DOMAgent.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DOMAgent.js
MIT
function onDocumentAvailable(error, root) { if (!error) this._setDocument(root); for (var i = 0; i < this._pendingDocumentRequestCallbacks.length; ++i) { var callback = this._pendingDocumentRequestCallbacks[i]; if (callback) callback(this._document); } delete this._pendingDocumentRequestCallbacks; }
@this {WebInspector.DOMAgent} @param {?Protocol.Error} error @param {DOMAgent.Node} root
onDocumentAvailable
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DOMAgent.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DOMAgent.js
MIT
function callback(nodeId, error, attributes) { if (error) { console.error("Error during DOMAgent operation: " + error); return; } var node = this._idToDOMNode[nodeId]; if (node) { node._setAttributesPayload(attributes); this.dispatchEventToListeners(WebInspector.DOMAgent.Events.AttrModified, { node: node, name: "style" }); this.dispatchEventToListeners(WebInspector.DOMAgent.Events.StyleInvalidated, node); } }
@this {WebInspector.DOMAgent} @param {DOMAgent.NodeId} nodeId @param {?Protocol.Error} error @param {Array.<string>} attributes
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DOMAgent.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DOMAgent.js
MIT
function callback(error, searchId, resultsCount) { this._searchId = searchId; searchCallback(resultsCount); }
@param {?Protocol.Error} error @param {string} searchId @param {number} resultsCount
callback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DOMAgent.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DOMAgent.js
MIT
function mycallback(error, nodeIds) { if (error) { console.error(error); callback(null); return; } if (nodeIds.length != 1) return; callback(this._idToDOMNode[nodeIds[0]]); }
@param {?Protocol.Error} error @param {Array.<number>} nodeIds
mycallback
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DOMAgent.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DOMAgent.js
MIT
function wrapperFunction(error) { if (!error) this.markUndoableState(); if (callback) callback.apply(this, arguments); }
@param {WebInspector.DOMNode} node @param {function(?Protocol.Error)=} callback @return {function(?Protocol.Error)}
wrapperFunction
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/DOMAgent.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/DOMAgent.js
MIT
function selectNode(candidateFocusNode) { if (!candidateFocusNode) candidateFocusNode = inspectedRootDocument.body || inspectedRootDocument.documentElement; if (!candidateFocusNode) return; this.selectDOMNode(candidateFocusNode); if (this.treeOutline.selectedTreeElement) this.treeOutline.selectedTreeElement.expand(); }
@this {WebInspector.ElementsPanel} @param {WebInspector.DOMNode=} candidateFocusNode
selectNode
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ElementsPanel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ElementsPanel.js
MIT
function selectLastSelectedNode(nodeId) { if (this.selectedDOMNode()) { // Focused node has been explicitly set while reaching out for the last selected node. return; } var node = nodeId ? WebInspector.domAgent.nodeForId(nodeId) : null; selectNode.call(this, node); }
@this {WebInspector.ElementsPanel} @param {WebInspector.DOMNode=} candidateFocusNode
selectLastSelectedNode
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ElementsPanel.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ElementsPanel.js
MIT
function updateEntryShow(entry) { switch (entry.type) { case "added": entry.parent.insertBefore(entry.node, entry.nextSibling); break; case "changed": entry.node.textContent = entry.newText; break; } }
@constructor @extends {TreeElement} @param {boolean=} elementCloseTag
updateEntryShow
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ElementsTreeOutline.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ElementsTreeOutline.js
MIT
function updateEntryHide(entry) { switch (entry.type) { case "added": if (entry.node.parentElement) entry.node.parentElement.removeChild(entry.node); break; case "changed": entry.node.textContent = entry.oldText; break; } }
@constructor @extends {TreeElement} @param {boolean=} elementCloseTag
updateEntryHide
javascript
node-pinus/pinus
tools/pinus-admin-web/public/front/ElementsTreeOutline.js
https://github.com/node-pinus/pinus/blob/master/tools/pinus-admin-web/public/front/ElementsTreeOutline.js
MIT