Showing preview only (3,474K chars total). Download the full file or copy to clipboard to get everything.
Repository: wuchangming/spy-debugger
Branch: master
Commit: 03d787151159
Files: 282
Total size: 3.3 MB
Directory structure:
gitextract_3l34r8z6/
├── .babelrc
├── .github/
│ └── FUNDING.yml
├── .gitignore
├── .travis.yml
├── LICENSE
├── README.md
├── README_EN.md
├── buildin_modules/
│ └── weinre/
│ ├── .npmignore
│ ├── LICENSE
│ ├── NOTICE
│ ├── README.md
│ ├── build-info.txt
│ ├── interfaces/
│ │ ├── WeinreClientCommands.idl
│ │ ├── WeinreClientEvents.idl
│ │ ├── WeinreExtraClientCommands.idl
│ │ ├── WeinreExtraTargetEvents.idl
│ │ ├── WeinreTargetCommands.idl
│ │ └── WeinreTargetEvents.idl
│ ├── lib/
│ │ ├── Channel.js
│ │ ├── HttpChannelHandler.js
│ │ ├── MessageQueue.js
│ │ ├── channelManager.js
│ │ ├── cli.js
│ │ ├── dumpingHandler.js
│ │ ├── extensionManager.js
│ │ ├── jsonBodyParser.js
│ │ ├── messageHandler.js
│ │ ├── service/
│ │ │ ├── WeinreClientCommands.js
│ │ │ └── WeinreTargetCommands.js
│ │ ├── serviceManager.js
│ │ ├── utils.js
│ │ └── weinre.js
│ ├── package.json
│ ├── web/
│ │ ├── client/
│ │ │ ├── ApplicationCacheItemsView.js
│ │ │ ├── AuditCategories.js
│ │ │ ├── AuditFormatters.js
│ │ │ ├── AuditLauncherView.js
│ │ │ ├── AuditResultView.js
│ │ │ ├── AuditRules.js
│ │ │ ├── AuditsPanel.js
│ │ │ ├── BottomUpProfileDataGridTree.js
│ │ │ ├── Breakpoint.js
│ │ │ ├── BreakpointManager.js
│ │ │ ├── BreakpointsSidebarPane.js
│ │ │ ├── CSSCompletions.js
│ │ │ ├── CSSKeywordCompletions.js
│ │ │ ├── CSSStyleModel.js
│ │ │ ├── CallStackSidebarPane.js
│ │ │ ├── Checkbox.js
│ │ │ ├── Color.js
│ │ │ ├── ConsolePanel.js
│ │ │ ├── ConsoleView.js
│ │ │ ├── ContextMenu.js
│ │ │ ├── CookieItemsView.js
│ │ │ ├── CookieParser.js
│ │ │ ├── CookiesTable.js
│ │ │ ├── DOMAgent.js
│ │ │ ├── DOMStorage.js
│ │ │ ├── DOMStorageItemsView.js
│ │ │ ├── DOMSyntaxHighlighter.js
│ │ │ ├── DataGrid.js
│ │ │ ├── Database.js
│ │ │ ├── DatabaseQueryView.js
│ │ │ ├── DatabaseTableView.js
│ │ │ ├── DebuggerModel.js
│ │ │ ├── DetailedHeapshotView.js
│ │ │ ├── Drawer.js
│ │ │ ├── ElementsPanel.js
│ │ │ ├── ElementsTreeOutline.js
│ │ │ ├── EventListenersSidebarPane.js
│ │ │ ├── ExtensionAPI.js
│ │ │ ├── ExtensionAPISchema.json
│ │ │ ├── ExtensionAuditCategory.js
│ │ │ ├── ExtensionCommon.js
│ │ │ ├── ExtensionPanel.js
│ │ │ ├── ExtensionRegistryStub.js
│ │ │ ├── ExtensionServer.js
│ │ │ ├── FontView.js
│ │ │ ├── GoToLineDialog.js
│ │ │ ├── HAREntry.js
│ │ │ ├── HeapSnapshot.js
│ │ │ ├── HeapSnapshotView.js
│ │ │ ├── HelpScreen.js
│ │ │ ├── ImageView.js
│ │ │ ├── InjectedFakeWorker.js
│ │ │ ├── InspectorBackendStub.js
│ │ │ ├── InspectorBackendStub.qrc
│ │ │ ├── InspectorFrontendHostStub.js
│ │ │ ├── KeyboardShortcut.js
│ │ │ ├── MetricsSidebarPane.js
│ │ │ ├── NetworkItemView.js
│ │ │ ├── NetworkManager.js
│ │ │ ├── NetworkPanel.js
│ │ │ ├── Object.js
│ │ │ ├── ObjectPropertiesSection.js
│ │ │ ├── Panel.js
│ │ │ ├── PanelEnablerView.js
│ │ │ ├── Placard.js
│ │ │ ├── PleaseWaitMessage.js
│ │ │ ├── Popover.js
│ │ │ ├── ProfileDataGridTree.js
│ │ │ ├── ProfileView.js
│ │ │ ├── ProfilesPanel.js
│ │ │ ├── PropertiesSection.js
│ │ │ ├── PropertiesSidebarPane.js
│ │ │ ├── RemoteObject.js
│ │ │ ├── Resource.js
│ │ │ ├── ResourceCategory.js
│ │ │ ├── ResourceCookiesView.js
│ │ │ ├── ResourceHeadersView.js
│ │ │ ├── ResourceTimingView.js
│ │ │ ├── ResourceTreeModel.js
│ │ │ ├── ResourceView.js
│ │ │ ├── ResourcesPanel.js
│ │ │ ├── ScopeChainSidebarPane.js
│ │ │ ├── Script.js
│ │ │ ├── ScriptFormatter.js
│ │ │ ├── ScriptFormatterWorker.js
│ │ │ ├── ScriptsPanel.js
│ │ │ ├── Section.js
│ │ │ ├── Settings.js
│ │ │ ├── ShortcutsHelp.js
│ │ │ ├── ShowMoreDataGridNode.js
│ │ │ ├── SidebarPane.js
│ │ │ ├── SidebarTreeElement.js
│ │ │ ├── SourceCSSTokenizer.js
│ │ │ ├── SourceCSSTokenizer.re2js
│ │ │ ├── SourceFrame.js
│ │ │ ├── SourceFrameContent.js
│ │ │ ├── SourceHTMLTokenizer.js
│ │ │ ├── SourceHTMLTokenizer.re2js
│ │ │ ├── SourceJavaScriptTokenizer.js
│ │ │ ├── SourceJavaScriptTokenizer.re2js
│ │ │ ├── SourceTokenizer.js
│ │ │ ├── StatusBarButton.js
│ │ │ ├── StylesSidebarPane.js
│ │ │ ├── SummaryBar.js
│ │ │ ├── TabbedPane.js
│ │ │ ├── TestController.js
│ │ │ ├── TextEditorHighlighter.js
│ │ │ ├── TextEditorModel.js
│ │ │ ├── TextPrompt.js
│ │ │ ├── TextViewer.js
│ │ │ ├── TimelineAgent.js
│ │ │ ├── TimelineGrid.js
│ │ │ ├── TimelineOverviewPane.js
│ │ │ ├── TimelinePanel.js
│ │ │ ├── TopDownProfileDataGridTree.js
│ │ │ ├── UglifyJS/
│ │ │ │ ├── parse-js.js
│ │ │ │ └── process.js
│ │ │ ├── View.js
│ │ │ ├── WatchExpressionsSidebarPane.js
│ │ │ ├── WebKit.qrc
│ │ │ ├── WelcomeView.js
│ │ │ ├── WorkersSidebarPane.js
│ │ │ ├── audits.css
│ │ │ ├── goToLineDialog.css
│ │ │ ├── heapProfiler.css
│ │ │ ├── helpScreen.css
│ │ │ ├── index.html
│ │ │ ├── inspector.css
│ │ │ ├── inspector.html
│ │ │ ├── inspector.js
│ │ │ ├── inspectorSyntaxHighlight.css
│ │ │ ├── networkPanel.css
│ │ │ ├── nls/
│ │ │ │ └── English.lproj/
│ │ │ │ └── localizedStrings.js
│ │ │ ├── popover.css
│ │ │ ├── textViewer.css
│ │ │ ├── treeoutline.js
│ │ │ ├── utilities.js
│ │ │ ├── web-inspector-API.js
│ │ │ └── weinre/
│ │ │ ├── browser-support-check.js
│ │ │ ├── client.css
│ │ │ └── hacks.js
│ │ ├── demo/
│ │ │ ├── split.html
│ │ │ ├── weinre-demo-min.html
│ │ │ ├── weinre-demo-strict.html
│ │ │ ├── weinre-demo-strict.js
│ │ │ ├── weinre-demo.css
│ │ │ ├── weinre-demo.html
│ │ │ └── weinre-demo.js
│ │ ├── doc/
│ │ │ ├── Building.html
│ │ │ ├── ChangeLog.html
│ │ │ ├── Home.html
│ │ │ ├── Installing.html
│ │ │ ├── License.html
│ │ │ ├── MultiUser.html
│ │ │ ├── Running.html
│ │ │ ├── Security.html
│ │ │ ├── UserInterface.html
│ │ │ ├── build-info.txt
│ │ │ ├── css/
│ │ │ │ └── main.css
│ │ │ ├── index.html
│ │ │ └── scripts/
│ │ │ └── main.js
│ │ ├── index.html
│ │ ├── index.js
│ │ ├── interfaces/
│ │ │ ├── InjectedScriptHost.json
│ │ │ ├── Inspector.json
│ │ │ ├── InspectorFrontendHost.json
│ │ │ ├── WeinreClientCommands.json
│ │ │ ├── WeinreClientEvents.json
│ │ │ ├── WeinreExtraClientCommands.json
│ │ │ ├── WeinreExtraTargetEvents.json
│ │ │ ├── WeinreTargetCommands.json
│ │ │ ├── WeinreTargetEvents.json
│ │ │ ├── all-json-idls-min.js
│ │ │ ├── all-json-idls.js
│ │ │ ├── interfaces.css
│ │ │ ├── interfaces.html
│ │ │ └── interfaces.js
│ │ ├── modjewel.js
│ │ ├── target/
│ │ │ ├── target-script-min.js
│ │ │ └── target-script.js
│ │ ├── tests/
│ │ │ ├── element-highlighter.html
│ │ │ └── index.html
│ │ ├── versions.js
│ │ └── weinre/
│ │ ├── client/
│ │ │ ├── Client.amd.js
│ │ │ ├── ConnectorList.amd.js
│ │ │ ├── DOMTemplates.amd.js
│ │ │ ├── ExtensionRegistryImpl.amd.js
│ │ │ ├── InspectorBackendImpl.amd.js
│ │ │ ├── InspectorFrontendHostImpl.amd.js
│ │ │ ├── RemotePanel.amd.js
│ │ │ ├── WeinreClientEventsImpl.amd.js
│ │ │ └── WeinreExtraTargetEventsImpl.amd.js
│ │ ├── common/
│ │ │ ├── Binding.amd.js
│ │ │ ├── Callback.amd.js
│ │ │ ├── Debug.amd.js
│ │ │ ├── EventListeners.amd.js
│ │ │ ├── Ex.amd.js
│ │ │ ├── HookLib.amd.js
│ │ │ ├── IDGenerator.amd.js
│ │ │ ├── IDLTools.amd.js
│ │ │ ├── MessageDispatcher.amd.js
│ │ │ ├── MethodNamer.amd.js
│ │ │ ├── StackTrace.amd.js
│ │ │ ├── WebSocketXhr.amd.js
│ │ │ └── Weinre.amd.js
│ │ └── target/
│ │ ├── BrowserHacks.amd.js
│ │ ├── CSSStore.amd.js
│ │ ├── CheckForProblems.amd.js
│ │ ├── Console.amd.js
│ │ ├── ElementHighlighter.amd.js
│ │ ├── ElementHighlighterDivs2.amd.js
│ │ ├── HookSites.amd.js
│ │ ├── InjectedScript.js
│ │ ├── InjectedScriptHostImpl.amd.js
│ │ ├── NetworkRequest.amd.js
│ │ ├── NodeStore.amd.js
│ │ ├── SqlStepper.amd.js
│ │ ├── Target.amd.js
│ │ ├── Timeline.amd.js
│ │ ├── WeinreExtraClientCommandsImpl.amd.js
│ │ ├── WeinreTargetEventsImpl.amd.js
│ │ ├── WiCSSImpl.amd.js
│ │ ├── WiConsoleImpl.amd.js
│ │ ├── WiDOMImpl.amd.js
│ │ ├── WiDOMStorageImpl.amd.js
│ │ ├── WiDatabaseImpl.amd.js
│ │ ├── WiInspectorImpl.amd.js
│ │ └── WiRuntimeImpl.amd.js
│ └── weinre
├── lib/
│ ├── config/
│ │ └── config.js
│ ├── index.js
│ ├── proxy/
│ │ ├── externalChildProcess.js
│ │ └── spyProxy.js
│ ├── scripts/
│ │ └── postinstall.js
│ ├── util/
│ │ ├── htmlUtil.js
│ │ └── httpUtil.js
│ └── weinre/
│ └── weinreDelegate.js
├── package.json
├── src/
│ ├── config/
│ │ └── config.js
│ ├── index.js
│ ├── proxy/
│ │ ├── externalChildProcess.js
│ │ └── spyProxy.js
│ ├── util/
│ │ ├── htmlUtil.js
│ │ └── httpUtil.js
│ └── weinre/
│ └── weinreDelegate.js
├── template/
│ ├── anyproxy_index.html
│ ├── inject.js.template.html
│ └── wrap.html
└── test/
└── index.js
================================================
FILE CONTENTS
================================================
================================================
FILE: .babelrc
================================================
{
"presets": ["es2015"],
"plugins": ["transform-async-to-generator"]
}
================================================
FILE: .github/FUNDING.yml
================================================
# These are supported funding model platforms
github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: spy-debugger
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
================================================
FILE: .gitignore
================================================
# Logs
logs
*.log
# Runtime data
pids
*.pid
*.seed
# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov
# Coverage directory used by tools like istanbul
coverage
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt
# node-waf configuration
.lock-wscript
# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release
# Dependency directory
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git
node_modules
#Dev
dev
================================================
FILE: .travis.yml
================================================
before_install:
- npm install babel-cli babel-preset-es2015 mocha
language: node_js
node_js:
- "6"
- "8"
- "10"
================================================
FILE: LICENSE
================================================
The MIT License (MIT)
Copyright (c) 2016 wuchangming
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
================================================
FILE: README.md
================================================
关于spy-debugger
==========
一站式页面调试、抓包工具。远程调试任何手机浏览器页面,任何手机移动端webview(如:微信,HybridApp等)。支持HTTP/HTTPS,无需USB连接设备。
[](https://www.npmjs.com/package/spy-debugger)
[](https://www.npmjs.com/package/spy-debugger)
[](https://travis-ci.org/wuchangming/spy-debugger)
Language: [English](README_EN.md)
特性
------------
>
1、页面调试+抓包
2、[操作简单](#三分钟上手),无需USB连接设备
3、**支持HTTPS**。
4、`spy-debugger`内部集成了[`weinre`](http://people.apache.org/~pmuellr/weinre/docs/latest/)、[`node-mitmproxy`](https://github.com/wuchangming/node-mitmproxy)、[`AnyProxy`](https://github.com/alibaba/anyproxy)。
5、自动忽略原生App发起的https请求,只拦截webview发起的https请求。对使用了SSL pinning技术的原生App不造成任何影响。【PS:由于 `iOS 15` 调整代理协议,`iOS 15` 已无法检测请求是否浏览器发起】
6、可以配合其它代理工具一起使用(默认使用AnyProxy) [(设置外部代理)](#设置外部代理默认使用anyproxy)
使用案例
------------
#### 页面编辑模式
>
启动命令:`spy-debugger -w true`
<img src="demo/img/spy-debugger-w.gif" width="300px" />
#### weiner页面调试界面
>
<img src="demo/img/demo.png" width="600px" />
#### anyproxy抓包界面
>
<img src="demo/img/AnyProxy.png" width="600px" />
安装
------------
Windows 下
```
npm install spy-debugger -g
```
Mac 下
```
sudo npm install spy-debugger -g
```
## 三分钟上手
>
第一步:手机和PC保持在同一网络下(比如同时连到一个Wi-Fi下)
>
第二步:命令行输入`spy-debugger`,按命令行提示用浏览器打开相应地址。
>
第三步:设置手机的HTTP代理,代理IP地址设置为PC的IP地址,端口为`spy-debugger`的启动端口(默认端口:9888)。
- Android设置代理步骤:`设置 - WLAN - 长按选中网络 - 修改网络 - 高级 - 代理设置 - 手动`
- iOS设置代理步骤:`设置 - 无线局域网 - 选中网络 - HTTP代理手动`
>
第四步:手机安装证书。**注:手机必须先设置完代理后再通过(非微信)手机浏览器访问`http://s.xxx`[`(地址二维码)`](demo/img/QRCodeForCert.png)安装证书**(手机首次调试需要安装证书,已安装了证书的手机无需重复安装)。[iOS新安装的证书需要手动打开证书信任](https://github.com/wuchangming/spy-debugger/issues/42)
>
第五步:用手机浏览器访问你要调试的页面即可。
自定义选项
------------
#### 端口
>
(默认端口:9888)
```
spy-debugger -p 8888
```
#### 设置外部代理(默认使用AnyProxy)
>
```
spy-debugger -e http://127.0.0.1:8888
```
spy-debugger内置AnyProxy提供抓包功能,但是也可通过设置外部代理和其它抓包代理工具一起使用,如:Charles、Fiddler。
#### 设置页面内容为可编辑模式
>
该功能使页面内容修改更加直观方便。
(默认: false)
```
spy-debugger -w true
```
内部实现原理:在需要调试的页面内注入代码:`document.body.contentEditable=true`。暂不支持使用了iscroll框架的页面。
#### 是否允许weinre监控iframe加载的页面
>
(默认: false)
```
spy-debugger -i true
```
#### 是否只拦截浏览器发起的https请求 【PS:由于 `iOS 15` 调整代理协议,已无法检测请求是否浏览器发起】
>
(默认: false)
```
spy-debugger -b true
```
有些浏览器发出的connect请求没有正确的携带userAgent,这个判断有时候会出错,如**UC浏览器**。这个时候需要设置为false。大多数情况建议启用默认配置:true,由于目前大量App应用自身(非WebView)发出的请求会使用到SSL pinning技术,自定义的证书将不能通过app的证书校验。
#### 是否允许HTTP缓存
>
(默认: false)
```
spy-debugger -c true
```
更多
------------
- 修复`weinre`在`node.js` V7版本会崩溃的bug
- 对`weinre`在页面`document ready`事件前,无法打印console.log日志进行了增强修复。
- 增强`weinre`打印未捕获异常(Uncaught Exceptions)功能。
- `spy-debugger`原理是集成了`weinre`,简化了`weinre`需要给每个调试的页面添加js代码。`spy-debugger`原理是拦截所有html页面请求注入`weinre`所需要的js代码。让页面调试更加方便。
================================================
FILE: README_EN.md
================================================
About spy-debugger
==========
Spy-debugger is one-stop pages inspection and debugger proxy. Spy-debugger can inspect and debugger all the mobile end browers and webview HTML page within the request of HTTP and HTTPS, such as Wechat, Facebook, HybridApp and so on.
[](https://www.npmjs.com/package/spy-debugger)
[](https://www.npmjs.com/package/spy-debugger)
[](https://travis-ci.org/wuchangming/spy-debugger)
语言: [中文](./README.md)
Functions
------------
1、HTML page inspection + debugger
2、[Easy to use](#only-3-mins-to-set-up)
3、**Support HTTPS**
4、`spy-debugger` integrated [`weinre`](http://people.apache.org/~pmuellr/weinre/docs/latest/)、[`node-mitmproxy`](https://github.com/wuchangming/node-mitmproxy)、[`AnyProxy`](https://github.com/alibaba/anyproxy)
5、`spy-debugger` automately overlooks the HTTPS requests from native App, and it only intercepts the HTTPS requests from webview. It will not cause any impacts to the native App that used SSL pinning.
6、`spy-debugger` can be better to use other debugger proxies such as Charles. the default debugger proxy in `spy-debugger` is AnyProxy.[(Set up the exterior proxy)](#set-up-the-exterior-proxy-default-proxy-anyproxy)
Demo
------------
#### Page inspection
<img src="demo/img/demo.png" width="650px" />
#### Debugger
<img src="demo/img/AnyProxy.png" width="650px" />
Install
------------
Windows
```
npm install spy-debugger -g
```
Mac
```
sudo npm install spy-debugger -g
```
## Only 3 mins to set up
Step 1: The mobile and PC must be under the same network (both of devices connect same Wi-Fi)
Step 2: Input `spy-debugger` in the command line and input the address on the brower according the command line's tip.
Step 3: Set up proxy on the mobile device. The proxy IP address must be same to the PC device. the port must be `spy-debugger`'s start port(default port: 9888).
Step 4: Install certification to your mobile phone. **note: moblie device must be set up well the proxy first and browe `http://spydebugger.com/cert` by the default brower on the phone.[`(QR code)`](demo/img/QRCodeForCert.png)Install certification**(Only the first time need to install it.)
Step 5: Use any installed browers on the mobile device to open the web page that you want to debugger or inspect.
Manual Options
------------
#### Port
(Default Port: 9888)
```
spy-debugger -p 8888
```
#### Set up the exterior proxy (default proxy AnyProxy)
```
spy-debugger -e http://127.0.0.1:8888
```
spy-debugger supply AnyProxy as default proxy, but you can only set up the exterior proxy to instead of the default proxy such as Charles, Fiddler.
#### whether weinre watch iframe load page
(default: false)
```
spy-debugger -i true
```
#### whether intercept the HTTPS requests from the brower.【not working in iOS 15】
(default: false)
```
spy-debugger -b true
```
There are some browers that send the connect request with incorrected userAgent. Sometimes this would cause error. such as **UC brower**. In this case, `spy-debugger -b false` can fix this error. In most cases we suggest using the default value `true`. Now there are many native Apps send request with SSL pinning. Manual certification will not pass native app certification.
#### whether allow HTTP cache
(default: false)
```
spy-debugger -c true
```
More
------------
`spy-debugger` integrated `weinre`,simplified that `weinre` needs to add javascript code to each page. `spy-debugger` intercepted the javascript code that need inject to `weinre` when the HTML page send the requests. it can make inspection and debugger easier to use.
================================================
FILE: buildin_modules/weinre/.npmignore
================================================
.DS_Store
.git*
Makefile
test/
================================================
FILE: buildin_modules/weinre/LICENSE
================================================
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
==============================================================
This product also include the following software:
==============================================================
------------------------------------------
WebKit Web Inspector
http://webkit.org
------------------------------------------
Copyright (C) 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserved.
Copyright (C) 2007, 2008 Matt Lilek (pe...@gmail.com).
Copyright (C) 2008, 2009 Anthony Ricaud <ri...@webkit.org>
Copyright (C) 2008 Nokia Inc. All rights reserved.
Copyright (C) 2009 IBM Corp. All rights reserved.
Copyright (C) 2009, 2010, 2011 Google Inc. All rights reserved.
Copyright (C) 2009, 2010 Joseph Pecoraro
Copyright (C) 2009 280 North Inc. All Rights Reserved.
Copyright (C) 2010 Nikita Vasilyev. All rights reserved.
Note that although WebKit in general contains both BSD and LGPL
licensed code, the WebKit Web Inspector code is all BSD licensed
with no LGPL code.
The wording of the license comments in the source files is not consistent,
but corresponds to traditional BSD licenses. The license in some files also
include one of the following conditions:
* Neither the name of Google Inc. nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
* Neither the name of Apple Computer, Inc. ("Apple") nor the names of
its contributors may be used to endorse or promote products derived
from this software without specific prior written permission.
* Neither the name of IBM Corp. nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
------------------------------------------
UglifyJS
https://github.com/mishoo/UglifyJS
------------------------------------------
Note that UglifyJS is shipped with WebKit Web Inspector.
Author: Mihai Bazon
<mihai.bazon@gmail.com>
http://mihai.bazon.net/blog
Distributed under the BSD license:
Copyright 2010 (c) Mihai Bazon <mihai.bazon@gmail.com>
Based on parse-js (http://marijn.haverbeke.nl/parse-js/).
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
* Redistributions of source code must retain the above
copyright notice, this list of conditions and the following
disclaimer.
* Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials
provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER “AS IS” AND ANY
EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
SUCH DAMAGE.
------------------------------------------
coffee-script 1.2.0 via npmjs.org
https://github.com/jashkenas/coffee-script
------------------------------------------
Copyright (c) 2011 Jeremy Ashkenas
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
------------------------------------------
express 2.5.7 via npmjs.org
https://github.com/visionmedia/express
------------------------------------------
(The MIT License)
Copyright (c) 2009-2011 TJ Holowaychuk <tj@vision-media.ca>
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
------------------------------------------
connect 1.8.5 via npmjs.org
https://github.com/senchalabs/connect
------------------------------------------
(The MIT License)
Copyright (c) 2010 Sencha Inc.
Copyright (c) 2011 LearnBoost
Copyright (c) 2011 TJ Holowaychuk
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
------------------------------------------
formidable 1.0.9 via npmjs.org
https://github.com/felixge/node-formidable
------------------------------------------
According to the Readme.md file in the Formidable library:
"Formidable is licensed under the MIT license."
------------------------------------------
mime 1.2.5 via npmjs.org
https://github.com/bentomas/node-mime
------------------------------------------
Copyright (c) 2010 Benjamin Thomas, Robert Kieffer
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
------------------------------------------
mkdirp 0.0.7 via npmjs.org
https://github.com/substack/node-mkdirp
------------------------------------------
Copyright 2010 James Halliday (mail@substack.net)
This project is free software released under the MIT/X11 license:
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
------------------------------------------
qs 0.4.2 via npmjs.org
https://github.com/visionmedia/node-querystring
------------------------------------------
(The MIT License)
Copyright (c) 2010 TJ Holowaychuk <tj@vision-media.ca>
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
------------------------------------------
nopt 1.0.10 via npmjs.org
https://github.com/isaacs/nopt
------------------------------------------
Copyright 2009, 2010, 2011 Isaac Z. Schlueter.
All rights reserved.
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
------------------------------------------
abbrev 1.0.3 via npmjs.org
https://github.com/isaacs/abbrev-js
------------------------------------------
Copyright 2009, 2010, 2011 Isaac Z. Schlueter.
All rights reserved.
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
------------------------------------------
underscore 1.3.1 via npmjs.org
https://github.com/documentcloud/underscore
------------------------------------------
Copyright (c) 2009-2012 Jeremy Ashkenas, DocumentCloud
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
================================================
FILE: buildin_modules/weinre/NOTICE
================================================
Apache Cordova weinre
Copyright 2012 The Apache Software Foundation
This product includes software developed at
The Apache Software Foundation (http://www.apache.org/).
================================================
FILE: buildin_modules/weinre/README.md
================================================
<!--
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
-->
weinre is WEb INspector REmote.
Pronounced like the word "winery".
Or maybe like the word "weiner".
Who knows, really.
weinre is a debugger for web pages,
like FireBug (for FireFox) and Web Inspector (for WebKit-based browsers),
except it's designed to work remotely, and in particular,
to allow you debug web pages on a mobile device such as a phone.
For more information on weinre:
[http://people.apache.org/~pmuellr/weinre/](http://people.apache.org/~pmuellr/weinre/)
running
-------
For more information about running weinre, you can start the server
and browse the documentation online.
Start the server with the following command
node weinre
This will start the server, and display a message with the URL to the
server. Browse to that URL in your web browser, and then click on
'documentation' link, which will display weinre's online documentation.
From there click on the 'Running' page to get more information about
running weinre.
source
------
Follow the link for more information at the top of this file
for instructions on obtaining source.
If you're reading this file as part of the source distribution of weinre,
you will need to run a 'build' before being able to run weinre. See the
`README.md` file in the root directory of the weinre source distribution
for more information.
================================================
FILE: buildin_modules/weinre/build-info.txt
================================================
weinre build 2.0.0-pre-IXE4AG4O by wuchangming
git: 746a5817d014acdda673115e2ee458ec6c9b7673 fix(console): fixed chrome bug, add ArrowUp, ArrowDown, ArrowRight
================================================
FILE: buildin_modules/weinre/interfaces/WeinreClientCommands.idl
================================================
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
// messages from the client to the server
module weinre {
interface WeinreClientCommands {
void registerClient(out string clientId);
void getTargets(out Object[] targets);
void getClients(out Object[] clients);
void connectTarget(in string clientId, in string targetId);
void disconnectTarget(in string clientId);
void getExtensions(out string[] extensions)
void logDebug( in string message );
void logInfo( in string message );
void logWarning( in string message );
void logError( in string message );
};
}
================================================
FILE: buildin_modules/weinre/interfaces/WeinreClientEvents.idl
================================================
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
// messages from the server to the client
module weinre {
interface WeinreClientEvents {
void clientRegistered(Object client);
void targetRegistered(Object target);
void clientUnregistered(string clientId);
void targetUnregistered(string targetId);
void connectionCreated(string clientId, string targetId);
void connectionDestroyed(string clientId, string targetId);
void sendCallback(string callbackId, Object result);
void serverProperties(Object properties);
};
}
================================================
FILE: buildin_modules/weinre/interfaces/WeinreExtraClientCommands.idl
================================================
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
// extra messages from the client to the target
module weinre {
interface WeinreExtraClientCommands {
void getDatabases(out Object[] databaseRecords);
};
}
================================================
FILE: buildin_modules/weinre/interfaces/WeinreExtraTargetEvents.idl
================================================
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
// extra messages from the target to the client
module weinre {
interface WeinreExtraTargetEvents {
void databaseOpened(in Object databaseRecord);
};
}
================================================
FILE: buildin_modules/weinre/interfaces/WeinreTargetCommands.idl
================================================
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
// messages from the target to the server
module weinre {
interface WeinreTargetCommands {
void registerTarget(int url, out string targetId);
void sendClientCallback(string callbackId, Object args);
void logDebug( in string message );
void logInfo( in string message );
void logWarning( in string message );
void logError( in string message );
};
}
================================================
FILE: buildin_modules/weinre/interfaces/WeinreTargetEvents.idl
================================================
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
// messages from the server to the target
module weinre {
interface WeinreTargetEvents {
void connectionCreated(string clientId, string targetId);
void connectionDestroyed(string clientId, string targetId);
void sendCallback(string callbackId, Object result);
};
}
================================================
FILE: buildin_modules/weinre/lib/Channel.js
================================================
// Generated by CoffeeScript 1.8.0
var AnonymousId, Channel, MessageQueue, channelManager, genJSON, messageHandler, parseJSON, utils, _,
__slice = [].slice;
_ = require('underscore');
utils = require('./utils');
channelManager = require('./channelManager');
messageHandler = require('./messageHandler');
MessageQueue = require('./MessageQueue');
AnonymousId = 'anonymous';
module.exports = utils.registerClass(Channel = (function() {
function Channel(pathPrefix, id, remoteAddress, isClient) {
var prefix;
this.pathPrefix = pathPrefix;
this.id = id;
this.remoteAddress = remoteAddress;
this.isClient = isClient;
prefix = this.isClient ? 'c-' : 't-';
this.name = "" + prefix + (utils.getNextSequenceNumber());
this.messageQueue = new MessageQueue;
this.isClosed = false;
this.connections = [];
this.isTarget = !this.isClient;
this.readTimeout = utils.options.readTimeout * 1000;
if (!this.id) {
this.id = AnonymousId;
}
this.description = {
channel: this.name,
id: this.id,
hostName: this.remoteAddress,
remoteAddress: this.remoteAddress
};
this.updateLastRead();
channelManager.created(this);
}
Channel.prototype.close = function() {
if (this.isClosed) {
return;
}
channelManager.destroyed(this);
this.isClosed = true;
return this.messageQueue.shutdown();
};
Channel.prototype.sendCallback = function() {
var args, callbackId, intfName;
intfName = arguments[0], callbackId = arguments[1], args = 3 <= arguments.length ? __slice.call(arguments, 2) : [];
if (!callbackId) {
return;
}
args.unshift(callbackId);
return this.sendMessage.apply(this, [intfName, 'sendCallback'].concat(__slice.call(args)));
};
Channel.prototype.sendMessage = function() {
var args, intfName, message, method;
intfName = arguments[0], method = arguments[1], args = 3 <= arguments.length ? __slice.call(arguments, 2) : [];
message = genJSON({
"interface": intfName,
method: method,
args: args
});
return this.messageQueue.push(message);
};
Channel.prototype.handleMessages = function(messages) {
var message, _i, _len, _results;
_results = [];
for (_i = 0, _len = messages.length; _i < _len; _i++) {
message = messages[_i];
message = parseJSON(message);
if (!message) {
continue;
}
_results.push(messageHandler.handleMessage(this, message));
}
return _results;
};
Channel.prototype.getMessages = function(callback) {
this.updateLastRead();
if (this.isClosed) {
return callback.call(null, null);
}
return this.messageQueue.pullAll(this.readTimeout, callback);
};
Channel.prototype.updateLastRead = function() {
return this.lastRead = (new Date).valueOf();
};
Channel.prototype.toString = function() {
var connections;
connections = _.map(this.connections, function(val) {
return val.name;
}).join(',');
return "Channel(" + this.name + ", closed:" + this.isClosed + ", connections:[" + connections + "])";
};
return Channel;
})());
parseJSON = function(message) {
var e;
try {
return JSON.parse(message);
} catch (_error) {
e = _error;
return null;
}
};
genJSON = function(message) {
var e;
try {
return JSON.stringify(message);
} catch (_error) {
e = _error;
return null;
}
};
================================================
FILE: buildin_modules/weinre/lib/HttpChannelHandler.js
================================================
// Generated by CoffeeScript 1.8.0
var Channel, HttpChannelHandler, channelManager, handleCreate, handleError, handleGet, handleOptions, handlePost, setCORSHeaders, setCacheHeaders, utils, _;
_ = require('underscore');
utils = require('./utils');
Channel = require('./Channel');
channelManager = require('./channelManager');
module.exports = utils.registerClass(HttpChannelHandler = (function() {
function HttpChannelHandler(pathPrefix) {
this.pathPrefix = pathPrefix;
if (this.pathPrefix === '/ws/client') {
this.isClient = true;
} else if (this.pathPrefix === '/ws/target') {
this.isClient = false;
} else {
utils.pitch("invalid pathPrefix: " + this.pathPrefix);
}
this.isTarget = !this.isClient;
}
HttpChannelHandler.prototype.handle = function(request, response, uri) {
var channelName, parts;
setCORSHeaders(request, response);
setCacheHeaders(request, response);
if (uri[0] !== '/') {
return handleError(request, response, 404);
}
if (uri === '/') {
if (request.method === 'OPTIONS') {
return handleOptions(request, response);
}
if (request.method === 'POST') {
return handleCreate(this.pathPrefix, this.isClient, request, response);
}
return handleError(request, response, 405);
}
parts = uri.split('/');
if (parts.length > 2) {
return handleError(request, response, 404);
}
channelName = parts[1];
if (request.method === 'OPTIONS') {
return handleOptions(request, response);
}
if (request.method === 'GET') {
return handleGet(request, response, channelName);
}
if (request.method === 'POST') {
return handlePost(request, response, channelName);
}
return handleError(request, response, 405);
};
return HttpChannelHandler;
})());
handleCreate = function(pathPrefix, isClient, request, response) {
var channel, id, remoteAddress, _ref, _ref1;
id = (_ref = request.body) != null ? _ref.id : void 0;
remoteAddress = ((_ref1 = request.connection) != null ? _ref1.remoteAddress : void 0) || "";
channel = new Channel(pathPrefix, id, remoteAddress, isClient);
response.contentType('application/json');
return response.send(JSON.stringify({
channel: channel.name,
id: channel.id
}));
};
handleGet = function(request, response, channelName) {
var channel, remoteAddress, _ref;
remoteAddress = ((_ref = request.connection) != null ? _ref.remoteAddress : void 0) || "";
channel = channelManager.getChannel(channelName, remoteAddress);
if (!channel) {
return handleError(request, response, 404);
}
return channel.getMessages((function(_this) {
return function(messages) {
if (channel.isClosed) {
return handleError(request, response, 404);
}
if (!messages) {
return handleError(request, response, 404);
}
response.contentType('application/json');
return response.send(JSON.stringify(messages));
};
})(this));
};
handlePost = function(request, response, channelName) {
var channel, remoteAddress, _ref;
remoteAddress = ((_ref = request.connection) != null ? _ref.remoteAddress : void 0) || "";
channel = channelManager.getChannel(channelName, remoteAddress);
if (!channel) {
return handleError(request, response, 404);
}
channel.handleMessages(request.body);
return response.send('');
};
handleOptions = function(request, response) {
return response.send('');
};
handleError = function(request, response, status) {
return response.send(status);
};
setCORSHeaders = function(request, response) {
var origin;
origin = request.header('Origin');
if (!origin) {
return;
}
response.header('Access-Control-Allow-Origin', origin);
response.header('Access-Control-Max-Age', '600');
return response.header('Access-Control-Allow-Methods', 'GET, POST');
};
setCacheHeaders = function(request, response) {
response.header('Pragma', 'no-cache');
response.header('Expires', '0');
response.header('Cache-Control', 'no-cache');
return response.header('Cache-Control', 'no-store');
};
================================================
FILE: buildin_modules/weinre/lib/MessageQueue.js
================================================
// Generated by CoffeeScript 1.8.0
var MessageQueue, utils, _;
_ = require('underscore');
utils = require('./utils');
module.exports = utils.registerClass(MessageQueue = (function() {
function MessageQueue() {
this.messages = [];
this.closed = false;
this.callback = null;
this.timer = null;
_.bindAll(this, '_timerExpired', '_updated');
}
MessageQueue.prototype.shutdown = function() {
if (this.closed) {
return;
}
this.closed = true;
if (this.timer) {
clearTimeout(this.timer);
}
if (this.callback) {
this.callback.call(null, this.messages);
}
this.callback = null;
this.messages = null;
return this.timer = null;
};
MessageQueue.prototype.push = function(message) {
if (this.closed) {
return;
}
this.messages.push(message);
return process.nextTick(this._updated);
};
MessageQueue.prototype.pullAll = function(timeout, callback) {
if (this.closed) {
return callback.call(null, null);
}
if (this.callback) {
return callback.call(null, []);
}
if (this.messages.length) {
callback.call(null, this.messages);
this.messages = [];
return;
}
this.callback = callback;
return this.timer = setTimeout(this._timerExpired, timeout);
};
MessageQueue.prototype._timerExpired = function() {
return this._updated();
};
MessageQueue.prototype._updated = function() {
var callback, messages;
if (this.closed) {
return;
}
if (!this.callback) {
return;
}
callback = this.callback;
messages = this.messages;
if (this.timer) {
clearTimeout(this.timer);
}
this.callback = null;
this.messages = [];
this.timer = null;
return callback.call(null, messages);
};
return MessageQueue;
})());
================================================
FILE: buildin_modules/weinre/lib/channelManager.js
================================================
// Generated by CoffeeScript 1.8.0
var ChannelManager, WeinreClientEvents, WeinreTargetEvents, channelManager, serviceManager, utils, _;
_ = require('underscore');
utils = require('./utils');
serviceManager = require('./serviceManager');
WeinreClientEvents = null;
WeinreTargetEvents = null;
channelManager = null;
utils.registerClass(ChannelManager = (function() {
function ChannelManager() {
this.channels = {};
}
ChannelManager.prototype.initialize = function() {
WeinreClientEvents = serviceManager.get('WeinreClientEvents');
WeinreTargetEvents = serviceManager.get('WeinreTargetEvents');
if (!WeinreClientEvents) {
utils.exit('WeinreClientEvents service not registered');
}
if (!WeinreTargetEvents) {
return utils.exit('WeinreTargetEvents service not registered');
}
};
ChannelManager.prototype.created = function(channel) {
return this.channels[channel.name] = channel;
};
ChannelManager.prototype.destroyed = function(channel) {
var clients, connection, _i, _j, _len, _len1, _ref, _ref1;
if (channel.isClient) {
_ref = channel.connections;
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
connection = _ref[_i];
this.disconnectChannels(channel, connection);
}
} else {
_ref1 = channel.connections;
for (_j = 0, _len1 = _ref1.length; _j < _len1; _j++) {
connection = _ref1[_j];
this.disconnectChannels(connection, channel);
}
}
clients = this.getClientChannels(channel.id);
if (channel.isClient) {
WeinreClientEvents.clientUnregistered(clients, channel.name);
} else {
WeinreClientEvents.targetUnregistered(clients, channel.name);
}
return delete this.channels[channel.name];
};
ChannelManager.prototype.getChannel = function(name, remoteAddress) {
var channel;
if (!_.has(this.channels, name)) {
return null;
}
channel = this.channels[name];
if (!channel) {
return null;
}
return channel;
};
ChannelManager.prototype.connectChannels = function(client, target) {
var clients;
if (client.isClosed || target.isClosed) {
return;
}
if (client.connections.length) {
this.disconnectChannels(client, client.connections[0]);
}
client.connections.push(target);
target.connections.push(client);
clients = this.getClientChannels(client.id);
WeinreClientEvents.connectionCreated(clients, client.name, target.name);
return WeinreTargetEvents.connectionCreated(target, client.name, target.name);
};
ChannelManager.prototype.disconnectChannels = function(client, target) {
var clients;
clients = this.getClientChannels(client.id);
WeinreClientEvents.connectionDestroyed(clients, client.name, target.name);
WeinreTargetEvents.connectionDestroyed(target, client.name, target.name);
client.connections = _.without(client.connections, target);
return target.connections = _.without(target.connections, client);
};
ChannelManager.prototype.getChannels = function(id) {
if (id != null) {
return _.filter(this.channels, function(item) {
return item.id === id;
});
} else {
return _.values(this.channels);
}
};
ChannelManager.prototype.getClientChannels = function(id) {
return _.filter(this.channels, function(item) {
return item.isClient && item.id === id;
});
};
ChannelManager.prototype.getTargetChannels = function(id) {
return _.filter(this.channels, function(item) {
return item.isTarget && item.id === id;
});
};
return ChannelManager;
})());
module.exports = new ChannelManager;
================================================
FILE: buildin_modules/weinre/lib/cli.js
================================================
// Generated by CoffeeScript 1.8.0
var fs, getDotWeinreServerProperties, getTildeReplacement, nopt, optionDefaults, path, printHelp, printNoptError, replaceTilde, utils, weinre, _;
fs = require('fs');
path = require('path');
_ = require('underscore');
nopt = require('nopt');
utils = require('./utils');
weinre = require('./weinre');
optionDefaults = {
httpPort: 8080,
boundHost: 'localhost',
verbose: false,
debug: false,
readTimeout: 5
};
exports.run = function() {
var args, knownOpts, opts, parsedOpts, shortHands;
knownOpts = {
httpPort: Number,
boundHost: String,
verbose: Boolean,
debug: Boolean,
readTimeout: Number,
deathTimeout: Number,
help: Boolean
};
shortHands = {
'?': ['--help'],
'h': ['--help']
};
nopt.invalidHandler = printNoptError;
parsedOpts = nopt(knownOpts, shortHands, process.argv, 2);
if (parsedOpts.help) {
printHelp();
}
args = parsedOpts.argv.remain;
if (args.length !== 0) {
printHelp();
}
delete parsedOpts.argv;
opts = _.extend({}, optionDefaults, getDotWeinreServerProperties(), parsedOpts);
if (opts.deathTimeout == null) {
opts.deathTimeout = 3 * opts.readTimeout;
}
utils.setOptions(opts);
return weinre.run(opts);
};
printNoptError = function(key, val, types) {
return utils.exit("error with option '" + key + "', value '" + val + "'");
};
printHelp = function() {
var version;
version = weinre.getVersion();
console.error("usage: " + utils.Program + " [options]\nversion: " + version + "\n\noptions:\n --httpPort port to run the http server on default: " + optionDefaults.httpPort + "\n --boundHost ip address to bind the server to default: " + optionDefaults.boundHost + "\n --verbose print more diagnostics default: " + optionDefaults.verbose + "\n --debug print even more diagnostics default: " + optionDefaults.debug + "\n --readTimeout seconds to wait for a client message default: " + optionDefaults.readTimeout + "\n --deathTimeout seconds to wait to kill client default: 3*readTimeout\n\n--boundHost can be an ip address, hostname, or -all-, where -all-\nmeans binding to all ip address on the current machine'\n\nfor more info see: http://people.apache.org/~pmuellr/weinre/");
return process.exit();
};
getDotWeinreServerProperties = function() {
var contents, fileName, key, line, lines, match, properties, val, _i, _len;
properties = {};
fileName = replaceTilde('~/.weinre/server.properties');
if (!utils.fileExistsSync(fileName)) {
return properties;
}
contents = fs.readFileSync(fileName, 'utf8');
lines = contents.split('\n');
for (_i = 0, _len = lines.length; _i < _len; _i++) {
line = lines[_i];
line = line.replace(/#.*/, '');
match = line.match(/\s*(\w+)\s*:\s*(.+)\s*/);
if (!match) {
continue;
}
key = utils.trim(match[1]);
val = utils.trim(match[2]);
properties[key] = val;
}
return properties;
};
replaceTilde = function(fileName) {
return fileName.replace('~', getTildeReplacement());
};
getTildeReplacement = function() {
return process.env["HOME"] || process.env["USERPROFILE"] || '.';
};
================================================
FILE: buildin_modules/weinre/lib/dumpingHandler.js
================================================
// Generated by CoffeeScript 1.8.0
var dumpResponse, dumpingHandler, enhance, utils, _;
_ = require('underscore');
utils = require('./utils');
dumpingHandler = function(request, response, uri) {
var element, originalSend, _i, _len, _ref, _results;
originalSend = response.send;
response.send = function(body) {
return dumpResponse(originalSend, body, request, response, uri);
};
if (request.method !== 'POST') {
return;
}
utils.logVerbose('--------------------------------------------------');
utils.logVerbose("" + request.method + " " + uri + " [request]");
if (_.isArray(request.body)) {
_ref = request.body;
_results = [];
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
element = _ref[_i];
_results.push(utils.logVerbose(" " + (enhance(JSON.parse(element)))));
}
return _results;
} else {
return utils.logVerbose(" " + (enhance(request.body)));
}
};
dumpResponse = function(originalSend, body, request, response, uri) {
var e, element, _i, _len, _ref, _results;
originalSend.call(response, body);
if ((_ref = request.method) !== 'GET' && _ref !== 'POST') {
return;
}
try {
body = JSON.parse(body);
} catch (_error) {
e = _error;
return;
}
if (_.isArray(body) && (body.length === 0)) {
return;
}
utils.logVerbose('--------------------------------------------------');
utils.logVerbose("" + request.method + " " + uri + " " + response.statusCode + " [response]");
if (_.isArray(body)) {
_results = [];
for (_i = 0, _len = body.length; _i < _len; _i++) {
element = body[_i];
_results.push(utils.logVerbose(" " + (enhance(JSON.parse(element)))));
}
return _results;
} else {
return utils.logVerbose(" " + (enhance(body)));
}
};
enhance = function(object) {
var args, signature;
if (!object["interface"] || !object.method || !object.args) {
return JSON.stringify(object);
}
signature = "" + object["interface"] + "." + object.method;
args = JSON.stringify(object.args);
if (args.length > 500) {
args = "" + (args.substr(0, 50)) + "...";
}
return "" + signature + "(" + args + ")";
};
module.exports = dumpingHandler;
================================================
FILE: buildin_modules/weinre/lib/extensionManager.js
================================================
// Generated by CoffeeScript 1.8.0
var ExtensionManager, utils;
utils = require('./utils');
utils.registerClass(ExtensionManager = (function() {
function ExtensionManager() {
this.extensions = [];
}
return ExtensionManager;
})());
module.exports = new ExtensionManager;
================================================
FILE: buildin_modules/weinre/lib/jsonBodyParser.js
================================================
// Generated by CoffeeScript 1.8.0
var jsonBodyParser, parseBodyAsJSON;
jsonBodyParser = function() {
return function(request, response, next) {
return parseBodyAsJSON(request, response, next);
};
};
parseBodyAsJSON = function(request, response, next) {
var buffer;
if (request.body) {
return next();
}
request.body = {};
if (request.method !== 'POST') {
return next();
}
request.setEncoding('utf8');
buffer = '';
request.on('data', function(chunk) {
return buffer += chunk;
});
return request.on('end', function() {
var e;
if ('' === buffer) {
return next();
}
try {
request.body = JSON.parse(buffer);
return next();
} catch (_error) {
e = _error;
return next(e);
}
});
};
module.exports = jsonBodyParser;
================================================
FILE: buildin_modules/weinre/lib/messageHandler.js
================================================
// Generated by CoffeeScript 1.8.0
var MessageHandler, channelManager, serviceManager, utils,
__slice = [].slice;
utils = require('./utils');
channelManager = require('./channelManager');
serviceManager = require('./serviceManager');
utils.registerClass(MessageHandler = (function() {
function MessageHandler() {}
MessageHandler.prototype.handleMessage = function(channel, message) {
return this._serviceMethodInvoker(channel, message["interface"], message.method, message.args);
};
MessageHandler.prototype._serviceMethodInvoker = function(channel, intfName, method, args) {
var e, methodSignature, service;
methodSignature = "" + intfName + "." + method + "()";
service = serviceManager.get(intfName);
if (!service) {
return this._redirectToConnections(channel, intfName, method, args);
}
args = args.slice();
args.unshift(channel);
try {
return service[method].apply(service, args);
} catch (_error) {
e = _error;
utils.log("error running service method " + methodSignature + ": " + e);
return utils.log("stack:\n" + e.stack);
}
};
MessageHandler.prototype._redirectToConnections = function(channel, intfName, method, args) {
var connection, _i, _len, _ref, _results;
_ref = channel.connections;
_results = [];
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
connection = _ref[_i];
_results.push(connection.sendMessage.apply(connection, [intfName, method].concat(__slice.call(args))));
}
return _results;
};
return MessageHandler;
})());
module.exports = new MessageHandler;
================================================
FILE: buildin_modules/weinre/lib/service/WeinreClientCommands.js
================================================
// Generated by CoffeeScript 1.8.0
var WeinreClientCommands, WeinreClientEvents, channelManager, extensionManager, serviceManager, utils, weinre, _,
__hasProp = {}.hasOwnProperty;
_ = require('underscore');
weinre = require('../weinre');
utils = require('../utils');
channelManager = require('../channelManager');
serviceManager = require('../serviceManager');
extensionManager = require('../extensionManager');
WeinreClientEvents = serviceManager.get('WeinreClientEvents');
module.exports = utils.registerClass(WeinreClientCommands = (function() {
function WeinreClientCommands() {}
WeinreClientCommands.prototype.registerClient = function(channel, callbackId) {
var clients, key, options, val, _ref;
if (callbackId) {
WeinreClientEvents.sendCallback(channel, callbackId, channel.description);
}
options = _.extend({}, utils.options);
for (key in options) {
if (!__hasProp.call(options, key)) continue;
val = options[key];
if ((_ref = typeof val) === 'number' || _ref === 'boolean') {
options[key] = "" + val;
}
}
options.version = weinre.getVersion();
WeinreClientEvents.serverProperties(channel, options);
clients = channelManager.getClientChannels(channel.id);
return WeinreClientEvents.clientRegistered(clients, channel.description);
};
WeinreClientCommands.prototype.getTargets = function(channel, callbackId) {
var channels, result;
channels = channelManager.getTargetChannels(channel.id);
result = _.pluck(channels, 'description');
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId, [result]);
}
};
WeinreClientCommands.prototype.getClients = function(channel, callbackId) {
var channels, result;
channels = channelManager.getClientChannels(channel.id);
result = _.pluck(channels, 'description');
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId, [result]);
}
};
WeinreClientCommands.prototype.getExtensions = function(channel, callbackId) {
var extension, result;
result = (function() {
var _i, _len, _ref, _results;
_ref = extensionManager.extensions;
_results = [];
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
extension = _ref[_i];
_results.push({
startPage: "extensions/" + extension + "/extension.html"
});
}
return _results;
})();
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId, [result]);
}
};
WeinreClientCommands.prototype.connectTarget = function(channel, clientName, targetName, callbackId) {
var client, target;
client = channelManager.getChannel(clientName);
if (!client) {
return;
}
target = channelManager.getChannel(targetName);
if (!target) {
return;
}
channelManager.connectChannels(client, target);
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId);
}
};
WeinreClientCommands.prototype.disconnectTarget = function(channel, clientName, callbackId) {
var client, target;
client = connectionManager.getClient(clientName);
if (!client) {
return;
}
target = client.getConnectedTarget();
if (!target) {
return;
}
connectionManager.disconnect(client, target);
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId);
}
};
WeinreClientCommands.prototype.logDebug = function(channel, message, callbackId) {
utils.logVerbose("client " + channel.name + ": " + message);
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId);
}
};
WeinreClientCommands.prototype.logInfo = function(channel, message, callbackId) {
utils.log("client " + channel.name + ": " + message);
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId);
}
};
WeinreClientCommands.prototype.logWarning = function(channel, message, callbackId) {
utils.log("client " + channel.name + ": " + message);
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId);
}
};
WeinreClientCommands.prototype.logError = function(channel, message, callbackId) {
utils.log("client " + channel.name + ": " + message);
if (callbackId) {
return WeinreClientEvents.sendCallback(channel, callbackId);
}
};
return WeinreClientCommands;
})());
================================================
FILE: buildin_modules/weinre/lib/service/WeinreTargetCommands.js
================================================
// Generated by CoffeeScript 1.8.0
var WeinreClientEvents, WeinreTargetCommands, WeinreTargetEvents, channelManager, getCallbackChannel, serviceManager, utils;
utils = require('../utils');
channelManager = require('../channelManager');
serviceManager = require('../serviceManager');
WeinreClientEvents = serviceManager.get('WeinreClientEvents');
WeinreTargetEvents = serviceManager.get('WeinreTargetEvents');
module.exports = utils.registerClass(WeinreTargetCommands = (function() {
function WeinreTargetCommands() {}
WeinreTargetCommands.prototype.registerTarget = function(channel, url, callbackId) {
var clients;
channel.description.url = url;
clients = channelManager.getClientChannels(channel.id);
WeinreClientEvents.targetRegistered(clients, channel.description);
if (callbackId) {
return WeinreTargetEvents.sendCallback(channel, callbackId, channel.description);
}
};
WeinreTargetCommands.prototype.sendClientCallback = function(channel, clientCallbackId, args, callbackId) {
var callbackChannel;
callbackChannel = getCallbackChannel(clientCallbackId);
if (!callbackChannel) {
return main.warn("" + this.constructor.name + ".sendClientCallback() sent with invalid callbackId: " + clientCallbackId);
}
callbackChannel = channelManager.getChannel(callbackChannel);
if (!callbackChannel) {
return main.warn("" + this.constructor.name + ".sendClientCallback() unable to find channel : " + clientCallbackId);
}
WeinreClientEvents.sendCallback(callbackChannel, clientCallbackId, args);
if (callbackId) {
return WeinreTargetEvents.sendCallback(channel, callbackId, description);
}
};
WeinreTargetCommands.prototype.logDebug = function(channel, message, callbackId) {
utils.logVerbose("target " + channel.name + ": " + message);
if (callbackId) {
return WeinreTargetEvents.sendCallback(channel, callbackId, description);
}
};
WeinreTargetCommands.prototype.logInfo = function(channel, message, callbackId) {
utils.log("target " + channel.name + ": " + message);
if (callbackId) {
return WeinreTargetEvents.sendCallback(channel, callbackId, description);
}
};
WeinreTargetCommands.prototype.logWarning = function(channel, message, callbackId) {
utils.log("target " + channel.name + ": " + message);
if (callbackId) {
return WeinreTargetEvents.sendCallback(channel, callbackId, description);
}
};
WeinreTargetCommands.prototype.logError = function(channel, message, callbackId) {
utils.log("target " + channel.name + ": " + message);
if (callbackId) {
return WeinreTargetEvents.sendCallback(channel, callbackId, description);
}
};
return WeinreTargetCommands;
})());
getCallbackChannel = function(callbackId) {
callbackId = callbackId.toString();
return callbackId.split('::')[0];
};
================================================
FILE: buildin_modules/weinre/lib/serviceManager.js
================================================
// Generated by CoffeeScript 1.8.0
var ServiceManager, Services, fs, getMethodProxy, getServiceInterface, path, utils, _,
__slice = [].slice;
path = require('path');
fs = require('fs');
_ = require('underscore');
utils = require('./utils');
Services = {};
utils.registerClass(ServiceManager = (function() {
function ServiceManager() {
this.services = {};
}
ServiceManager.prototype.get = function(name) {
if (_.has(this.services, name)) {
return this.services[name];
}
return null;
};
ServiceManager.prototype.registerLocalClass = function(name) {
var e, serviceClass;
serviceClass = null;
try {
serviceClass = require("./service/" + name);
} catch (_error) {
e = _error;
utils.log("local service class not found: " + name);
throw e;
}
return this.services[name] = new serviceClass;
};
ServiceManager.prototype.registerProxyClass = function(name) {
var intf, method, service, _i, _len, _ref;
intf = getServiceInterface(name);
if (!intf) {
utils.exit("proxy service class not found: " + name);
}
if (intf.name !== name) {
utils.exit("proxy interface '" + intf.name + "' loaded when '" + name + "' requested");
}
service = {};
_ref = intf.methods;
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
method = _ref[_i];
service[method.name] = getMethodProxy(name, method.name);
}
return this.services[name] = service;
};
return ServiceManager;
})());
getMethodProxy = function(intfName, methodName) {
return function() {
var args, channel, channels, _i, _len, _results;
channels = arguments[0], args = 2 <= arguments.length ? __slice.call(arguments, 1) : [];
if (!_.isArray(channels)) {
channels = [channels];
}
_results = [];
for (_i = 0, _len = channels.length; _i < _len; _i++) {
channel = channels[_i];
_results.push(channel.sendMessage.apply(channel, [intfName, methodName].concat(__slice.call(args))));
}
return _results;
};
};
getServiceInterface = function(name) {
var contents, fileName, jsonName, serviceInterface;
jsonName = "" + name + ".json";
fileName = path.join(utils.options.staticWebDir, 'interfaces', jsonName);
if (!utils.fileExistsSync(fileName)) {
return null;
}
contents = fs.readFileSync(fileName, 'utf8');
serviceInterface = JSON.parse(contents);
return serviceInterface.interfaces[0];
};
module.exports = new ServiceManager;
================================================
FILE: buildin_modules/weinre/lib/utils.js
================================================
// Generated by CoffeeScript 1.8.0
var Program, SequenceNumber, SequenceNumberMax, fs, log, path, utils,
__hasProp = {}.hasOwnProperty;
fs = require('fs');
path = require('path');
utils = exports;
utils.Program = Program = path.basename(process.argv[1]);
SequenceNumberMax = 100 * 1024 * 1024;
SequenceNumber = 0;
utils.getNextSequenceNumber = function(g) {
SequenceNumber++;
if (SequenceNumber > SequenceNumberMax) {
SequenceNumber = 0;
}
return SequenceNumber;
};
utils.trim = function(string) {
return string.replace(/(^\s+)|(\s+$)/g, '');
};
utils.log = log = function(message) {
var date, time;
date = new Date();
time = date.toISOString();
return console.log("" + time + " " + Program + ": " + message);
};
utils.logVerbose = function(message) {
var _ref;
if (!(utils != null ? (_ref = utils.options) != null ? _ref.verbose : void 0 : void 0)) {
return;
}
return log(message);
};
utils.logDebug = function(message) {
var _ref;
if (!(utils != null ? (_ref = utils.options) != null ? _ref.debug : void 0 : void 0)) {
return;
}
return log(message);
};
utils.exit = function(message) {
log(message);
return process.exit(1);
};
utils.pitch = function(message) {
log(message);
throw message;
};
utils.setOptions = function(options) {
return utils.options = options;
};
utils.ensureInteger = function(value, message) {
var newValue;
newValue = parseInt(value);
if (isNaN(newValue)) {
utils.exit("" + message + ": '" + value + "'");
}
return newValue;
};
utils.ensureString = function(value, message) {
if (typeof value !== 'string') {
utils.exit("" + message + ": '" + value + "'");
}
return value;
};
utils.ensureBoolean = function(value, message) {
var newValue, uValue;
uValue = value.toString().toUpperCase();
newValue = null;
switch (uValue) {
case 'TRUE':
newValue = true;
break;
case 'FALSE':
newValue = false;
}
if (typeof newValue !== 'boolean') {
utils.exit("" + message + ": '" + value + "'");
}
return newValue;
};
utils.setNamesForClass = function(aClass) {
var key, val, _ref, _results;
for (key in aClass) {
if (!__hasProp.call(aClass, key)) continue;
val = aClass[key];
if (typeof val === "function") {
val.signature = "" + aClass.name + "::" + key;
val.displayName = val.signature;
val.name = val.signature;
}
}
_ref = aClass.prototype;
_results = [];
for (key in _ref) {
if (!__hasProp.call(_ref, key)) continue;
val = _ref[key];
if (typeof val === "function") {
val.signature = "" + aClass.name + "." + key;
val.displayName = val.signature;
_results.push(val.name = val.signature);
} else {
_results.push(void 0);
}
}
return _results;
};
utils.registerClass = function(aClass) {
utils.setNamesForClass(aClass);
return aClass;
};
utils.alignLeft = function(string, length) {
while (string.length < length) {
string = "" + string + " ";
}
return string;
};
utils.alignRight = function(string, length) {
while (string.length < length) {
string = " " + string;
}
return string;
};
utils.fileExistsSync = function(name) {
if (fs.existsSync) {
return fs.existsSync(name);
}
return path.existsSync(name);
};
Error.prepareStackTrace = function(error, structuredStackTrace) {
var callSite, file, func, funcName, line, longestFile, longestLine, result, _i, _j, _len, _len1;
result = [];
result.push("---------------------------------------------------------");
result.push("error: " + error);
result.push("---------------------------------------------------------");
result.push("stack: ");
longestFile = 0;
longestLine = 0;
for (_i = 0, _len = structuredStackTrace.length; _i < _len; _i++) {
callSite = structuredStackTrace[_i];
file = callSite.getFileName();
line = callSite.getLineNumber();
file = path.basename(file);
line = "" + line;
if (file.length > longestFile) {
longestFile = file.length;
}
if (line.length > longestLine) {
longestLine = line.length;
}
}
for (_j = 0, _len1 = structuredStackTrace.length; _j < _len1; _j++) {
callSite = structuredStackTrace[_j];
func = callSite.getFunction();
file = callSite.getFileName();
line = callSite.getLineNumber();
file = path.basename(file);
line = "" + line;
file = utils.alignRight(file, longestFile);
line = utils.alignLeft(line, longestLine);
if (func) {
funcName = func.displayName || func.name || callSite.getFunctionName();
}
callSite.getMethodName();
'???';
if (funcName === "Module._compile") {
result.pop();
result.pop();
break;
}
result.push(" " + file + ":" + line + " - " + funcName + "()");
}
return result.join("\n");
};
================================================
FILE: buildin_modules/weinre/lib/weinre.js
================================================
// Generated by CoffeeScript 1.8.0
var HttpChannelHandler, Version, channelManager, checkForDeath, checkHost, deathTimeout, dns, dumpingHandler, express, fs, getStaticWebDir, getVersion, jsonBodyParser, net, path, processOptions, run2, serviceManager, startDeathWatcher, startServer, utils, _;
fs = require('fs');
net = require('net');
dns = require('dns');
path = require('path');
_ = require('underscore');
express = require('express');
utils = require('./utils');
jsonBodyParser = require('./jsonBodyParser');
HttpChannelHandler = require('./HttpChannelHandler');
dumpingHandler = require('./dumpingHandler');
channelManager = require('./channelManager');
serviceManager = require('./serviceManager');
exports.run = function(options) {
return processOptions(options, run2);
};
run2 = function() {
var options;
options = utils.options;
serviceManager.registerProxyClass('WeinreClientEvents');
serviceManager.registerProxyClass('WeinreTargetEvents');
serviceManager.registerLocalClass('WeinreClientCommands');
serviceManager.registerLocalClass('WeinreTargetCommands');
startDeathWatcher(options.deathTimeout);
return startServer();
};
processOptions = function(options, cb) {
var name, nameLen, names, reducer, _i, _len;
options.httpPort = utils.ensureInteger(options.httpPort, 'the value of the option httpPort is not a number');
options.boundHost = utils.ensureString(options.boundHost, 'the value of the option boundHost is not a string');
options.verbose = utils.ensureBoolean(options.verbose, 'the value of the option verbose is not a boolean');
options.debug = utils.ensureBoolean(options.debug, 'the value of the option debug is not a boolean');
options.readTimeout = utils.ensureInteger(options.readTimeout, 'the value of the option readTimeout is not a number');
options.deathTimeout = utils.ensureInteger(options.deathTimeout, 'the value of the option deathTimeout is not a number');
if (options.debug) {
options.verbose = true;
}
options.staticWebDir = getStaticWebDir();
utils.logVerbose("pid: " + process.pid);
utils.logVerbose("version: " + (getVersion()));
utils.logVerbose("node versions:");
names = _.keys(process.versions);
reducer = function(memo, name) {
return Math.max(memo, name.length);
};
nameLen = _.reduce(names, reducer, 0);
for (_i = 0, _len = names.length; _i < _len; _i++) {
name = names[_i];
utils.logVerbose(" " + (utils.alignLeft(name, nameLen)) + ": " + process.versions[name]);
}
utils.logVerbose("options:");
utils.logVerbose(" httpPort: " + options.httpPort);
utils.logVerbose(" boundHost: " + options.boundHost);
utils.logVerbose(" verbose: " + options.verbose);
utils.logVerbose(" debug: " + options.debug);
utils.logVerbose(" readTimeout: " + options.readTimeout);
utils.logVerbose(" deathTimeout: " + options.deathTimeout);
utils.setOptions(options);
return checkHost(options.boundHost, function(err) {
if (err) {
utils.exit("unable to resolve boundHost address: " + options.boundHost);
}
return cb();
});
};
checkHost = function(hostName, cb) {
if (hostName === '-all-') {
return cb();
}
if (hostName === 'localhost') {
return cb();
}
if (net.isIP(hostName)) {
return cb();
}
return dns.lookup(hostName, cb);
};
deathTimeout = null;
startDeathWatcher = function(timeout) {
deathTimeout = utils.options.deathTimeout * 1000;
return setInterval(checkForDeath, 1000);
};
checkForDeath = function() {
var channel, now, _i, _len, _ref, _results;
now = (new Date).valueOf();
_ref = channelManager.getChannels();
_results = [];
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
channel = _ref[_i];
if (now - channel.lastRead > deathTimeout) {
_results.push(channel.close());
} else {
_results.push(void 0);
}
}
return _results;
};
startServer = function() {
var app, clientHandler, favIcon, options, staticCacheOptions, targetHandler;
options = utils.options;
clientHandler = new HttpChannelHandler('/ws/client');
targetHandler = new HttpChannelHandler('/ws/target');
channelManager.initialize();
favIcon = "" + options.staticWebDir + "/images/weinre-icon-32x32.png";
staticCacheOptions = {
maxObjects: 500,
maxLength: 32 * 1024 * 1024
};
app = express();
app.on('error', function(error) {
return utils.exit("error running server: " + error);
});
app.use(express.favicon(favIcon));
app.use(jsonBodyParser());
app.all(/^\/ws\/client(.*)/, function(request, response, next) {
var uri;
uri = request.params[0];
if (uri === '') {
uri = '/';
}
if (options.debug) {
dumpingHandler(request, response, uri);
}
return clientHandler.handle(request, response, uri);
});
app.all(/^\/ws\/target(.*)/, function(request, response, next) {
var uri;
uri = request.params[0];
if (uri === '') {
uri = '/';
}
if (options.debug) {
dumpingHandler(request, response, uri);
}
return targetHandler.handle(request, response, uri);
});
app.use(express.errorHandler({
dumpExceptions: true
}));
// app.use(express.staticCache(staticCacheOptions));
app.use(express["static"](options.staticWebDir));
if (options.boundHost === '-all-') {
return app.listen(options.httpPort);
} else {
return app.listen(options.httpPort, options.boundHost);
}
};
getStaticWebDir = function() {
var webDir;
webDir = path.normalize(path.join(__dirname, '../web'));
if (utils.fileExistsSync(webDir)) {
return webDir;
}
return utils.exit('unable to find static files to serve in #{webDir}; did you do a build?');
};
Version = null;
getVersion = exports.getVersion = function() {
var json, packageJsonName, values;
if (Version) {
return Version;
}
packageJsonName = path.join(path.dirname(fs.realpathSync(__filename)), '../package.json');
json = fs.readFileSync(packageJsonName, 'utf8');
values = JSON.parse(json);
Version = values.version;
return Version;
};
================================================
FILE: buildin_modules/weinre/package.json
================================================
{
"name": "weinre",
"description": "WEb INspector REmote",
"author": "apache.org",
"version": "2.0.0-pre-IXE4AG4O",
"tags": [ "debug"],
"licenses":
[
{
"type": "Apache 2.0",
"url": "http://www.apache.org/licenses/LICENSE-2.0"
}
],
"engines":
{
"node": ">=0.6.0"
},
"directories":
{
"lib" : "./lib"
},
"dependencies":
{
"express": "2.5.x",
"nopt": "3.0.x",
"underscore": "1.7.x"
},
"devDependencies":
{
"coffee-script": "1.8.x"
},
"main" : "./lib/weinre",
"bin":
{
"weinre": "./weinre"
},
"homepage": "http://people.apache.org/~pmuellr/weinre/",
"bugs": "https://issues.apache.org/jira/secure/IssueNavigator!executeAdvanced.jspa?jqlQuery=project%3DCB+and+component%3Dweinre&runQuery=true&clear=true",
"repository":
{
"type": "git",
"url": "https://git-wip-us.apache.org/repos/asf/cordova-weinre.git"
}
}
================================================
FILE: buildin_modules/weinre/web/client/ApplicationCacheItemsView.js
================================================
/*
* Copyright (C) 2010 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
* THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.ApplicationCacheItemsView = function(treeElement, appcacheDomain)
{
WebInspector.View.call(this);
this.element.addStyleClass("storage-view");
this.element.addStyleClass("table");
// FIXME: Delete Button semantics are not yet defined.
// FIXME: Needs better tooltip. (Localized)
this.deleteButton = new WebInspector.StatusBarButton(WebInspector.UIString("Delete"), "delete-storage-status-bar-item");
this.deleteButton.visible = false;
this.deleteButton.addEventListener("click", this._deleteButtonClicked.bind(this), false);
// FIXME: Refresh Button semantics are not yet defined.
// FIXME: Needs better tooltip. (Localized)
this.refreshButton = new WebInspector.StatusBarButton(WebInspector.UIString("Refresh"), "refresh-storage-status-bar-item");
this.refreshButton.addEventListener("click", this._refreshButtonClicked.bind(this), false);
if (Preferences.onlineDetectionEnabled) {
this.connectivityIcon = document.createElement("img");
this.connectivityIcon.className = "storage-application-cache-connectivity-icon";
this.connectivityIcon.src = "";
this.connectivityMessage = document.createElement("span");
this.connectivityMessage.className = "storage-application-cache-connectivity";
this.connectivityMessage.textContent = "";
}
this.divider = document.createElement("span");
this.divider.className = "status-bar-item status-bar-divider";
this.statusIcon = document.createElement("img");
this.statusIcon.className = "storage-application-cache-status-icon";
this.statusIcon.src = "";
this.statusMessage = document.createElement("span");
this.statusMessage.className = "storage-application-cache-status";
this.statusMessage.textContent = "";
this._treeElement = treeElement;
this._appcacheDomain = appcacheDomain;
this._emptyMsgElement = document.createElement("div");
this._emptyMsgElement.className = "storage-empty-view";
this._emptyMsgElement.textContent = WebInspector.UIString("No Application Cache information available.");
this.element.appendChild(this._emptyMsgElement);
this.updateStatus(applicationCache.UNCACHED);
}
WebInspector.ApplicationCacheItemsView.prototype = {
get statusBarItems()
{
if (Preferences.onlineDetectionEnabled) {
return [
this.refreshButton.element, this.deleteButton.element,
this.connectivityIcon, this.connectivityMessage, this.divider,
this.statusIcon, this.statusMessage
];
} else {
return [
this.refreshButton.element, this.deleteButton.element, this.divider,
this.statusIcon, this.statusMessage
];
}
},
show: function(parentElement)
{
WebInspector.View.prototype.show.call(this, parentElement);
this.updateNetworkState(navigator.onLine);
this._update();
},
hide: function()
{
WebInspector.View.prototype.hide.call(this);
this.deleteButton.visible = false;
},
updateStatus: function(status)
{
var statusInformation = {};
statusInformation[applicationCache.UNCACHED] = { src: "Images/warningOrangeDot.png", text: "UNCACHED" };
statusInformation[applicationCache.IDLE] = { src: "Images/warningOrangeDot.png", text: "IDLE" };
statusInformation[applicationCache.CHECKING] = { src: "Images/successGreenDot.png", text: "CHECKING" };
statusInformation[applicationCache.DOWNLOADING] = { src: "Images/successGreenDot.png", text: "DOWNLOADING" };
statusInformation[applicationCache.UPDATEREADY] = { src: "Images/successGreenDot.png", text: "UPDATEREADY" };
statusInformation[applicationCache.OBSOLETE] = { src: "Images/errorRedDot.png", text: "OBSOLETE" };
var info = statusInformation[status];
if (!info) {
console.error("Unknown Application Cache Status was Not Handled: %d", status);
return;
}
this.statusIcon.src = info.src;
this.statusMessage.textContent = info.text;
},
updateNetworkState: function(isNowOnline)
{
if (Preferences.onlineDetectionEnabled) {
if (isNowOnline) {
this.connectivityIcon.src = "Images/successGreenDot.png";
this.connectivityMessage.textContent = WebInspector.UIString("Online");
} else {
this.connectivityIcon.src = "Images/errorRedDot.png";
this.connectivityMessage.textContent = WebInspector.UIString("Offline");
}
}
},
_update: function()
{
WebInspector.ApplicationCacheDispatcher.getApplicationCachesAsync(this._updateCallback.bind(this));
},
_updateCallback: function(applicationCaches)
{
// FIXME: applicationCaches is just one cache.
// FIXME: are these variables needed anywhere else?
this._manifest = applicationCaches.manifest;
this._creationTime = applicationCaches.creationTime;
this._updateTime = applicationCaches.updateTime;
this._size = applicationCaches.size;
this._resources = applicationCaches.resources;
var lastPathComponent = applicationCaches.lastPathComponent;
if (!this._manifest) {
this._emptyMsgElement.removeStyleClass("hidden");
this.deleteButton.visible = false;
if (this._dataGrid)
this._dataGrid.element.addStyleClass("hidden");
return;
}
if (!this._dataGrid)
this._createDataGrid();
this._populateDataGrid();
this._dataGrid.autoSizeColumns(20, 80);
this._dataGrid.element.removeStyleClass("hidden");
this._emptyMsgElement.addStyleClass("hidden");
this.deleteButton.visible = true;
var totalSizeString = Number.bytesToString(this._size);
this._treeElement.subtitle = WebInspector.UIString("%s (%s)", lastPathComponent, totalSizeString);
// FIXME: For Chrome, put creationTime and updateTime somewhere.
// NOTE: localizedString has not yet been added.
// WebInspector.UIString("(%s) Created: %s Updated: %s", this._size, this._creationTime, this._updateTime);
},
_createDataGrid: function()
{
var columns = { 0: {}, 1: {}, 2: {} };
columns[0].title = WebInspector.UIString("Resource");
columns[0].sort = "ascending";
columns[0].sortable = true;
columns[1].title = WebInspector.UIString("Type");
columns[1].sortable = true;
columns[2].title = WebInspector.UIString("Size");
columns[2].aligned = "right";
columns[2].sortable = true;
this._dataGrid = new WebInspector.DataGrid(columns);
this.element.appendChild(this._dataGrid.element);
this._dataGrid.addEventListener("sorting changed", this._populateDataGrid, this);
this._dataGrid.updateWidths();
},
_populateDataGrid: function()
{
var selectedResource = this._dataGrid.selectedNode ? this._dataGrid.selectedNode.resource : null;
var sortDirection = this._dataGrid.sortOrder === "ascending" ? 1 : -1;
function numberCompare(field, resource1, resource2)
{
return sortDirection * (resource1[field] - resource2[field]);
}
function localeCompare(field, resource1, resource2)
{
return sortDirection * (resource1[field] + "").localeCompare(resource2[field] + "")
}
var comparator;
switch (parseInt(this._dataGrid.sortColumnIdentifier)) {
case 0: comparator = localeCompare.bind(this, "name"); break;
case 1: comparator = localeCompare.bind(this, "type"); break;
case 2: comparator = numberCompare.bind(this, "size"); break;
default: localeCompare.bind(this, "resource"); // FIXME: comparator = ?
}
this._resources.sort(comparator);
this._dataGrid.removeChildren();
var nodeToSelect;
for (var i = 0; i < this._resources.length; ++i) {
var data = {};
var resource = this._resources[i];
data[0] = resource.name;
data[1] = resource.type;
data[2] = Number.bytesToString(resource.size);
var node = new WebInspector.DataGridNode(data);
node.resource = resource;
node.selectable = true;
this._dataGrid.appendChild(node);
if (resource === selectedResource) {
nodeToSelect = node;
nodeToSelect.selected = true;
}
}
if (!nodeToSelect)
this._dataGrid.children[0].selected = true;
},
resize: function()
{
if (this._dataGrid)
this._dataGrid.updateWidths();
},
_deleteButtonClicked: function(event)
{
if (!this._dataGrid || !this._dataGrid.selectedNode)
return;
// FIXME: Delete Button semantics are not yet defined. (Delete a single, or all?)
this._deleteCallback(this._dataGrid.selectedNode);
},
_deleteCallback: function(node)
{
// FIXME: Should we delete a single (selected) resource or all resources?
// InspectorBackend.deleteCachedResource(...)
// this._update();
},
_refreshButtonClicked: function(event)
{
// FIXME: Is this a refresh button or a re-fetch manifest button?
// this._update();
}
}
WebInspector.ApplicationCacheItemsView.prototype.__proto__ = WebInspector.View.prototype;
================================================
FILE: buildin_modules/weinre/web/client/AuditCategories.js
================================================
/*
* Copyright (C) 2010 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.AuditCategories.PagePerformance = function() {
WebInspector.AuditCategory.call(this, WebInspector.AuditCategories.PagePerformance.AuditCategoryName);
}
WebInspector.AuditCategories.PagePerformance.AuditCategoryName = "Web Page Performance";
WebInspector.AuditCategories.PagePerformance.prototype = {
initialize: function()
{
this.addRule(new WebInspector.AuditRules.UnusedCssRule(), WebInspector.AuditRule.Severity.Warning);
this.addRule(new WebInspector.AuditRules.CssInHeadRule(), WebInspector.AuditRule.Severity.Severe);
this.addRule(new WebInspector.AuditRules.StylesScriptsOrderRule(), WebInspector.AuditRule.Severity.Severe);
}
}
WebInspector.AuditCategories.PagePerformance.prototype.__proto__ = WebInspector.AuditCategory.prototype;
WebInspector.AuditCategories.NetworkUtilization = function() {
WebInspector.AuditCategory.call(this, WebInspector.AuditCategories.NetworkUtilization.AuditCategoryName);
}
WebInspector.AuditCategories.NetworkUtilization.AuditCategoryName = "Network Utilization";
WebInspector.AuditCategories.NetworkUtilization.prototype = {
initialize: function()
{
this.addRule(new WebInspector.AuditRules.GzipRule(), WebInspector.AuditRule.Severity.Severe);
this.addRule(new WebInspector.AuditRules.ImageDimensionsRule(), WebInspector.AuditRule.Severity.Warning);
this.addRule(new WebInspector.AuditRules.CookieSizeRule(400), WebInspector.AuditRule.Severity.Warning);
this.addRule(new WebInspector.AuditRules.StaticCookielessRule(5), WebInspector.AuditRule.Severity.Warning);
this.addRule(new WebInspector.AuditRules.CombineJsResourcesRule(2), WebInspector.AuditRule.Severity.Severe);
this.addRule(new WebInspector.AuditRules.CombineCssResourcesRule(2), WebInspector.AuditRule.Severity.Severe);
this.addRule(new WebInspector.AuditRules.MinimizeDnsLookupsRule(4), WebInspector.AuditRule.Severity.Warning);
this.addRule(new WebInspector.AuditRules.ParallelizeDownloadRule(4, 10, 0.5), WebInspector.AuditRule.Severity.Warning);
this.addRule(new WebInspector.AuditRules.BrowserCacheControlRule(), WebInspector.AuditRule.Severity.Severe);
this.addRule(new WebInspector.AuditRules.ProxyCacheControlRule(), WebInspector.AuditRule.Severity.Warning);
}
}
WebInspector.AuditCategories.NetworkUtilization.prototype.__proto__ = WebInspector.AuditCategory.prototype;
================================================
FILE: buildin_modules/weinre/web/client/AuditFormatters.js
================================================
/*
* Copyright (C) 2010 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.applyFormatters = function(value)
{
var formatter;
var type = typeof value;
var args;
switch (type) {
case "string":
case "boolean":
case "number":
formatter = WebInspector.AuditFormatters.text;
args = [ value.toString() ];
break;
case "object":
if (value instanceof Array) {
formatter = WebInspector.AuditFormatters.concat;
args = value;
} else if (value.type && value.arguments) {
formatter = WebInspector.AuditFormatters[value.type];
args = value.arguments;
}
}
if (!formatter)
throw "Invalid value or formatter: " + type + JSON.stringify(value);
return formatter.apply(null, args);
}
WebInspector.AuditFormatters = {
text: function(text)
{
return document.createTextNode(text);
},
snippet: function(snippetText)
{
var div = document.createElement("div");
div.innerText = snippetText;
div.className = "source-code";
return div;
},
concat: function()
{
var parent = document.createElement("span");
for (var arg = 0; arg < arguments.length; ++arg)
parent.appendChild(WebInspector.applyFormatters(arguments[arg]));
return parent;
},
url: function(url, displayText, allowExternalNavigation)
{
var a = document.createElement("a");
a.href = url;
a.title = url;
a.textContent = displayText || url;
if (allowExternalNavigation)
a.target = "_blank";
return a;
}
};
================================================
FILE: buildin_modules/weinre/web/client/AuditLauncherView.js
================================================
/*
* Copyright (C) 2011 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.AuditLauncherView = function(runnerCallback)
{
WebInspector.View.call(this);
this._runnerCallback = runnerCallback;
this._categoryIdPrefix = "audit-category-item-";
this._auditRunning = false;
this.element.addStyleClass("audit-launcher-view");
this._contentElement = document.createElement("div");
this._contentElement.className = "audit-launcher-view-content";
this.element.appendChild(this._contentElement);
this._boundCategoryClickListener = this._categoryClicked.bind(this);
this._resetResourceCount();
this._sortedCategories = [];
this._headerElement = document.createElement("h1");
this._headerElement.className = "no-audits";
this._headerElement.textContent = WebInspector.UIString("No audits to run");
this._contentElement.appendChild(this._headerElement);
WebInspector.networkManager.addEventListener(WebInspector.NetworkManager.EventTypes.ResourceStarted, this._onResourceStarted, this);
WebInspector.networkManager.addEventListener(WebInspector.NetworkManager.EventTypes.ResourceFinished, this._onResourceFinished, this);
}
WebInspector.AuditLauncherView.prototype = {
_resetResourceCount: function()
{
this._loadedResources = 0;
this._totalResources = 0;
},
_onResourceStarted: function(event)
{
var resource = event.data;
// Ignore long-living WebSockets for the sake of progress indicator, as we won't be waiting them anyway.
if (resource.type === WebInspector.Resource.Type.WebSocket)
return;
++this._totalResources;
this._updateResourceProgress();
},
_onResourceFinished: function(event)
{
var resource = event.data;
// See resorceStarted for details.
if (resource.type === WebInspector.Resource.Type.WebSocket)
return;
++this._loadedResources;
this._updateResourceProgress();
},
addCategory: function(category)
{
if (!this._sortedCategories.length)
this._createLauncherUI();
var categoryElement = this._createCategoryElement(category.displayName, category.id);
category._checkboxElement = categoryElement.firstChild;
if (this._selectAllCheckboxElement.checked) {
category._checkboxElement.checked = true;
++this._currentCategoriesCount;
}
function compareCategories(a, b)
{
var aTitle = a.displayName || "";
var bTitle = b.displayName || "";
return aTitle.localeCompare(bTitle);
}
var insertBefore = insertionIndexForObjectInListSortedByFunction(category, this._sortedCategories, compareCategories);
this._categoriesElement.insertBefore(categoryElement, this._categoriesElement.children[insertBefore] || null);
this._sortedCategories.splice(insertBefore, 0, category);
this._updateButton();
},
_setAuditRunning: function(auditRunning)
{
if (this._auditRunning === auditRunning)
return;
this._auditRunning = auditRunning;
this._updateButton();
this._updateResourceProgress();
},
_launchButtonClicked: function(event)
{
var catIds = [];
var childNodes = this._categoriesElement.childNodes;
for (var category = 0; category < this._sortedCategories.length; ++category) {
if (this._sortedCategories[category]._checkboxElement.checked)
catIds.push(this._sortedCategories[category].id);
}
this._setAuditRunning(true);
this._runnerCallback(catIds, this._auditPresentStateElement.checked, this._setAuditRunning.bind(this, false));
},
_selectAllClicked: function(checkCategories)
{
var childNodes = this._categoriesElement.childNodes;
for (var i = 0, length = childNodes.length; i < length; ++i)
childNodes[i].firstChild.checked = checkCategories;
this._currentCategoriesCount = checkCategories ? this._sortedCategories.length : 0;
this._updateButton();
},
_categoryClicked: function(event)
{
this._currentCategoriesCount += event.target.checked ? 1 : -1;
this._selectAllCheckboxElement.checked = this._currentCategoriesCount === this._sortedCategories.length;
this._updateButton();
},
_createCategoryElement: function(title, id)
{
var labelElement = document.createElement("label");
labelElement.id = this._categoryIdPrefix + id;
var element = document.createElement("input");
element.type = "checkbox";
if (id !== "")
element.addEventListener("click", this._boundCategoryClickListener, false);
labelElement.appendChild(element);
labelElement.appendChild(document.createTextNode(title));
return labelElement;
},
_createLauncherUI: function()
{
this._headerElement = document.createElement("h1");
this._headerElement.textContent = WebInspector.UIString("Select audits to run");
for (var child = 0; child < this._contentElement.children.length; ++child)
this._contentElement.removeChild(this._contentElement.children[child]);
this._contentElement.appendChild(this._headerElement);
function handleSelectAllClick(event)
{
this._selectAllClicked(event.target.checked);
}
var categoryElement = this._createCategoryElement(WebInspector.UIString("Select All"), "");
categoryElement.id = "audit-launcher-selectall";
this._selectAllCheckboxElement = categoryElement.firstChild;
this._selectAllCheckboxElement.checked = true;
this._selectAllCheckboxElement.addEventListener("click", handleSelectAllClick.bind(this), false);
this._contentElement.appendChild(categoryElement);
this._categoriesElement = document.createElement("div");
this._categoriesElement.className = "audit-categories-container";
this._contentElement.appendChild(this._categoriesElement);
this._currentCategoriesCount = 0;
var flexibleSpaceElement = document.createElement("div");
flexibleSpaceElement.className = "flexible-space";
this._contentElement.appendChild(flexibleSpaceElement);
this._buttonContainerElement = document.createElement("div");
this._buttonContainerElement.className = "button-container";
var labelElement = document.createElement("label");
this._auditPresentStateElement = document.createElement("input");
this._auditPresentStateElement.name = "audit-mode";
this._auditPresentStateElement.type = "radio";
this._auditPresentStateElement.checked = true;
this._auditPresentStateLabelElement = document.createTextNode(WebInspector.UIString("Audit Present State"));
labelElement.appendChild(this._auditPresentStateElement);
labelElement.appendChild(this._auditPresentStateLabelElement);
this._buttonContainerElement.appendChild(labelElement);
labelElement = document.createElement("label");
this.auditReloadedStateElement = document.createElement("input");
this.auditReloadedStateElement.name = "audit-mode";
this.auditReloadedStateElement.type = "radio";
labelElement.appendChild(this.auditReloadedStateElement);
labelElement.appendChild(document.createTextNode("Reload Page and Audit on Load"));
this._buttonContainerElement.appendChild(labelElement);
this._launchButton = document.createElement("button");
this._launchButton.type = "button";
this._launchButton.textContent = WebInspector.UIString("Run");
this._launchButton.addEventListener("click", this._launchButtonClicked.bind(this), false);
this._buttonContainerElement.appendChild(this._launchButton);
this._resourceProgressContainer = document.createElement("span");
this._resourceProgressContainer.className = "resource-progress";
var resourceProgressImage = document.createElement("img");
this._resourceProgressContainer.appendChild(resourceProgressImage);
this._resourceProgressTextElement = document.createElement("span");
this._resourceProgressContainer.appendChild(this._resourceProgressTextElement);
this._buttonContainerElement.appendChild(this._resourceProgressContainer);
this._contentElement.appendChild(this._buttonContainerElement);
this._selectAllClicked(this._selectAllCheckboxElement.checked);
this._updateButton();
this._updateResourceProgress();
},
_updateResourceProgress: function()
{
if (!this._resourceProgressContainer)
return;
if (!this._auditRunning) {
this._resetResourceCount();
this._resourceProgressContainer.addStyleClass("hidden");
} else
this._resourceProgressContainer.removeStyleClass("hidden");
this._resourceProgressTextElement.textContent = WebInspector.UIString("Loading (%d of %d)", this._loadedResources, this._totalResources);
},
_updateButton: function()
{
this._launchButton.disabled = !this._currentCategoriesCount || this._auditRunning;
}
}
WebInspector.AuditLauncherView.prototype.__proto__ = WebInspector.View.prototype;
================================================
FILE: buildin_modules/weinre/web/client/AuditResultView.js
================================================
/*
* Copyright (C) 2009 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.AuditResultView = function(categoryResults)
{
WebInspector.View.call(this);
this.element.className = "audit-result-view";
function categorySorter(a, b) {
return (a.title || "").localeCompare(b.title || "");
}
categoryResults.sort(categorySorter);
for (var i = 0; i < categoryResults.length; ++i)
this.element.appendChild(new WebInspector.AuditCategoryResultPane(categoryResults[i]).element);
}
WebInspector.AuditResultView.prototype.__proto__ = WebInspector.View.prototype;
WebInspector.AuditCategoryResultPane = function(categoryResult)
{
WebInspector.SidebarPane.call(this, categoryResult.title);
var treeOutlineElement = document.createElement("ol");
this.bodyElement.addStyleClass("audit-result-tree");
this.bodyElement.appendChild(treeOutlineElement);
this._treeOutline = new TreeOutline(treeOutlineElement);
this._treeOutline.expandTreeElementsWhenArrowing = true;
function ruleSorter(a, b)
{
var result = WebInspector.AuditRule.SeverityOrder[a.severity || 0] - WebInspector.AuditRule.SeverityOrder[b.severity || 0];
if (!result)
result = (a.value || "").localeCompare(b.value || "");
return result;
}
categoryResult.ruleResults.sort(ruleSorter);
for (var i = 0; i < categoryResult.ruleResults.length; ++i) {
var ruleResult = categoryResult.ruleResults[i];
var treeElement = this._appendResult(this._treeOutline, ruleResult);
treeElement.listItemElement.addStyleClass("audit-result");
if (ruleResult.severity) {
var severityElement = document.createElement("img");
severityElement.className = "severity-" + ruleResult.severity;
treeElement.listItemElement.appendChild(severityElement);
}
}
this.expand();
}
WebInspector.AuditCategoryResultPane.prototype = {
_appendResult: function(parentTreeElement, result)
{
var title = "";
if (typeof result.value === "string") {
title = result.value;
if (result.violationCount)
title = String.sprintf("%s (%d)", title, result.violationCount);
}
var treeElement = new TreeElement(null, null, !!result.children);
treeElement.titleHTML = title;
parentTreeElement.appendChild(treeElement);
if (result.className)
treeElement.listItemElement.addStyleClass(result.className);
if (typeof result.value !== "string")
treeElement.listItemElement.appendChild(WebInspector.applyFormatters(result.value));
if (result.children) {
for (var i = 0; i < result.children.length; ++i)
this._appendResult(treeElement, result.children[i]);
}
if (result.expanded) {
treeElement.listItemElement.removeStyleClass("parent");
treeElement.listItemElement.addStyleClass("parent-expanded");
treeElement.expand();
}
return treeElement;
}
}
WebInspector.AuditCategoryResultPane.prototype.__proto__ = WebInspector.SidebarPane.prototype;
================================================
FILE: buildin_modules/weinre/web/client/AuditRules.js
================================================
/*
* Copyright (C) 2010 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.AuditRules.IPAddressRegexp = /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/;
WebInspector.AuditRules.CacheableResponseCodes =
{
200: true,
203: true,
206: true,
300: true,
301: true,
410: true,
304: true // Underlying resource is cacheable
}
WebInspector.AuditRules.getDomainToResourcesMap = function(resources, types, needFullResources)
{
var domainToResourcesMap = {};
for (var i = 0, size = resources.length; i < size; ++i) {
var resource = resources[i];
if (types && types.indexOf(resource.type) === -1)
continue;
var parsedURL = resource.url.asParsedURL();
if (!parsedURL)
continue;
var domain = parsedURL.host;
var domainResources = domainToResourcesMap[domain];
if (domainResources === undefined) {
domainResources = [];
domainToResourcesMap[domain] = domainResources;
}
domainResources.push(needFullResources ? resource : resource.url);
}
return domainToResourcesMap;
}
WebInspector.AuditRules.evaluateInTargetWindow = function(func, args, callback)
{
InspectorBackend.evaluateOnSelf(func.toString(), args, callback);
}
WebInspector.AuditRules.GzipRule = function()
{
WebInspector.AuditRule.call(this, "network-gzip", "Enable gzip compression");
}
WebInspector.AuditRules.GzipRule.prototype = {
doRun: function(resources, result, callback)
{
var totalSavings = 0;
var compressedSize = 0;
var candidateSize = 0;
var summary = result.addChild("", true);
for (var i = 0, length = resources.length; i < length; ++i) {
var resource = resources[i];
if (this._shouldCompress(resource)) {
var size = resource.resourceSize;
candidateSize += size;
if (this._isCompressed(resource)) {
compressedSize += size;
continue;
}
var savings = 2 * size / 3;
totalSavings += savings;
summary.addChild(String.sprintf("%s could save ~%s", WebInspector.AuditRuleResult.linkifyDisplayName(resource.url), Number.bytesToString(savings)));
result.violationCount++;
}
}
if (!totalSavings)
return callback(null);
summary.value = String.sprintf("Compressing the following resources with gzip could reduce their transfer size by about two thirds (~%s):", Number.bytesToString(totalSavings));
callback(result);
},
_isCompressed: function(resource)
{
var encoding = resource.responseHeaders["Content-Encoding"];
return encoding === "gzip" || encoding === "deflate";
},
_shouldCompress: function(resource)
{
return WebInspector.Resource.Type.isTextType(resource.type) && resource.domain && resource.resourceSize !== undefined && resource.resourceSize > 150;
}
}
WebInspector.AuditRules.GzipRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.CombineExternalResourcesRule = function(id, name, type, resourceTypeName, allowedPerDomain)
{
WebInspector.AuditRule.call(this, id, name);
this._type = type;
this._resourceTypeName = resourceTypeName;
this._allowedPerDomain = allowedPerDomain;
}
WebInspector.AuditRules.CombineExternalResourcesRule.prototype = {
doRun: function(resources, result, callback)
{
var domainToResourcesMap = WebInspector.AuditRules.getDomainToResourcesMap(resources, [this._type]);
var penalizedResourceCount = 0;
// TODO: refactor according to the chosen i18n approach
var summary = result.addChild("", true);
for (var domain in domainToResourcesMap) {
var domainResources = domainToResourcesMap[domain];
var extraResourceCount = domainResources.length - this._allowedPerDomain;
if (extraResourceCount <= 0)
continue;
penalizedResourceCount += extraResourceCount - 1;
summary.addChild(String.sprintf("%d %s resources served from %s.", domainResources.length, this._resourceTypeName, WebInspector.AuditRuleResult.resourceDomain(domain)));
result.violationCount += domainResources.length;
}
if (!penalizedResourceCount)
return callback(null);
summary.value = "There are multiple resources served from same domain. Consider combining them into as few files as possible.";
callback(result);
}
}
WebInspector.AuditRules.CombineExternalResourcesRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.CombineJsResourcesRule = function(allowedPerDomain) {
WebInspector.AuditRules.CombineExternalResourcesRule.call(this, "page-externaljs", "Combine external JavaScript", WebInspector.Resource.Type.Script, "JavaScript", allowedPerDomain);
}
WebInspector.AuditRules.CombineJsResourcesRule.prototype.__proto__ = WebInspector.AuditRules.CombineExternalResourcesRule.prototype;
WebInspector.AuditRules.CombineCssResourcesRule = function(allowedPerDomain) {
WebInspector.AuditRules.CombineExternalResourcesRule.call(this, "page-externalcss", "Combine external CSS", WebInspector.Resource.Type.Stylesheet, "CSS", allowedPerDomain);
}
WebInspector.AuditRules.CombineCssResourcesRule.prototype.__proto__ = WebInspector.AuditRules.CombineExternalResourcesRule.prototype;
WebInspector.AuditRules.MinimizeDnsLookupsRule = function(hostCountThreshold) {
WebInspector.AuditRule.call(this, "network-minimizelookups", "Minimize DNS lookups");
this._hostCountThreshold = hostCountThreshold;
}
WebInspector.AuditRules.MinimizeDnsLookupsRule.prototype = {
doRun: function(resources, result, callback)
{
var summary = result.addChild("");
var domainToResourcesMap = WebInspector.AuditRules.getDomainToResourcesMap(resources, undefined);
for (var domain in domainToResourcesMap) {
if (domainToResourcesMap[domain].length > 1)
continue;
var parsedURL = domain.asParsedURL();
if (!parsedURL)
continue;
if (!parsedURL.host.search(WebInspector.AuditRules.IPAddressRegexp))
continue; // an IP address
summary.addSnippet(match[2]);
result.violationCount++;
}
if (!summary.children || summary.children.length <= this._hostCountThreshold)
return callback(null);
summary.value = "The following domains only serve one resource each. If possible, avoid the extra DNS lookups by serving these resources from existing domains.";
callback(result);
}
}
WebInspector.AuditRules.MinimizeDnsLookupsRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.ParallelizeDownloadRule = function(optimalHostnameCount, minRequestThreshold, minBalanceThreshold)
{
WebInspector.AuditRule.call(this, "network-parallelizehosts", "Parallelize downloads across hostnames");
this._optimalHostnameCount = optimalHostnameCount;
this._minRequestThreshold = minRequestThreshold;
this._minBalanceThreshold = minBalanceThreshold;
}
WebInspector.AuditRules.ParallelizeDownloadRule.prototype = {
doRun: function(resources, result, callback)
{
function hostSorter(a, b)
{
var aCount = domainToResourcesMap[a].length;
var bCount = domainToResourcesMap[b].length;
return (aCount < bCount) ? 1 : (aCount == bCount) ? 0 : -1;
}
var domainToResourcesMap = WebInspector.AuditRules.getDomainToResourcesMap(
resources,
[WebInspector.Resource.Type.Stylesheet, WebInspector.Resource.Type.Image],
true);
var hosts = [];
for (var url in domainToResourcesMap)
hosts.push(url);
if (!hosts.length)
return callback(null); // no hosts (local file or something)
hosts.sort(hostSorter);
var optimalHostnameCount = this._optimalHostnameCount;
if (hosts.length > optimalHostnameCount)
hosts.splice(optimalHostnameCount);
var busiestHostResourceCount = domainToResourcesMap[hosts[0]].length;
var resourceCountAboveThreshold = busiestHostResourceCount - this._minRequestThreshold;
if (resourceCountAboveThreshold <= 0)
return callback(null);
var avgResourcesPerHost = 0;
for (var i = 0, size = hosts.length; i < size; ++i)
avgResourcesPerHost += domainToResourcesMap[hosts[i]].length;
// Assume optimal parallelization.
avgResourcesPerHost /= optimalHostnameCount;
avgResourcesPerHost = Math.max(avgResourcesPerHost, 1);
var pctAboveAvg = (resourceCountAboveThreshold / avgResourcesPerHost) - 1.0;
var minBalanceThreshold = this._minBalanceThreshold;
if (pctAboveAvg < minBalanceThreshold)
return callback(null);
var resourcesOnBusiestHost = domainToResourcesMap[hosts[0]];
var entry = result.addChild(String.sprintf("This page makes %d parallelizable requests to %s. Increase download parallelization by distributing the following requests across multiple hostnames.", busiestHostResourceCount, hosts[0]), true);
for (var i = 0; i < resourcesOnBusiestHost.length; ++i)
entry.addURL(resourcesOnBusiestHost[i].url);
result.violationCount = resourcesOnBusiestHost.length;
callback(result);
}
}
WebInspector.AuditRules.ParallelizeDownloadRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
// The reported CSS rule size is incorrect (parsed != original in WebKit),
// so use percentages instead, which gives a better approximation.
WebInspector.AuditRules.UnusedCssRule = function()
{
WebInspector.AuditRule.call(this, "page-unusedcss", "Remove unused CSS rules");
}
WebInspector.AuditRules.UnusedCssRule.prototype = {
doRun: function(resources, result, callback)
{
var self = this;
function evalCallback(styleSheets) {
if (!styleSheets.length)
return callback(null);
var pseudoSelectorRegexp = /:hover|:link|:active|:visited|:focus|:before|:after/;
var selectors = [];
var testedSelectors = {};
for (var i = 0; i < styleSheets.length; ++i) {
var styleSheet = styleSheets[i];
for (var curRule = 0; curRule < styleSheet.rules.length; ++curRule) {
var selectorText = styleSheet.rules[curRule].selectorText;
if (selectorText.match(pseudoSelectorRegexp) || testedSelectors[selectorText])
continue;
selectors.push(selectorText);
testedSelectors[selectorText] = 1;
}
}
function selectorsCallback(callback, styleSheets, testedSelectors, foundSelectors)
{
var inlineBlockOrdinal = 0;
var totalStylesheetSize = 0;
var totalUnusedStylesheetSize = 0;
var summary;
for (var i = 0; i < styleSheets.length; ++i) {
var styleSheet = styleSheets[i];
var stylesheetSize = 0;
var unusedStylesheetSize = 0;
var unusedRules = [];
for (var curRule = 0; curRule < styleSheet.rules.length; ++curRule) {
var rule = styleSheet.rules[curRule];
// Exact computation whenever source ranges are available.
var textLength = (rule.selectorRange && rule.style.properties.endOffset) ? rule.style.properties.endOffset - rule.selectorRange.start + 1 : 0;
if (!textLength && rule.style.cssText)
textLength = rule.style.cssText.length + rule.selectorText.length;
stylesheetSize += textLength;
if (!testedSelectors[rule.selectorText] || foundSelectors[rule.selectorText])
continue;
unusedStylesheetSize += textLength;
unusedRules.push(rule.selectorText);
}
totalStylesheetSize += stylesheetSize;
totalUnusedStylesheetSize += unusedStylesheetSize;
if (!unusedRules.length)
continue;
var resource = WebInspector.resourceForURL(styleSheet.sourceURL);
var isInlineBlock = resource && resource.type == WebInspector.Resource.Type.Document;
var url = !isInlineBlock ? WebInspector.AuditRuleResult.linkifyDisplayName(styleSheet.sourceURL) : String.sprintf("Inline block #%d", ++inlineBlockOrdinal);
var pctUnused = Math.round(100 * unusedStylesheetSize / stylesheetSize);
if (!summary)
summary = result.addChild("", true);
var entry = summary.addChild(String.sprintf("%s: %s (%d%%) is not used by the current page.", url, Number.bytesToString(unusedStylesheetSize), pctUnused));
for (var j = 0; j < unusedRules.length; ++j)
entry.addSnippet(unusedRules[j]);
result.violationCount += unusedRules.length;
}
if (!totalUnusedStylesheetSize)
return callback(null);
var totalUnusedPercent = Math.round(100 * totalUnusedStylesheetSize / totalStylesheetSize);
summary.value = String.sprintf("%s (%d%%) of CSS is not used by the current page.", Number.bytesToString(totalUnusedStylesheetSize), totalUnusedPercent);
callback(result);
}
function routine(selectorArray)
{
var result = {};
for (var i = 0; i < selectorArray.length; ++i) {
try {
if (document.querySelector(selectorArray[i]))
result[selectorArray[i]] = true;
} catch(e) {
// Ignore and mark as unused.
}
}
return result;
}
WebInspector.AuditRules.evaluateInTargetWindow(routine, [selectors], selectorsCallback.bind(null, callback, styleSheets, testedSelectors));
}
function styleSheetCallback(styleSheets, continuation, styleSheet)
{
if (styleSheet)
styleSheets.push(styleSheet);
if (continuation)
continuation(styleSheets);
}
function allStylesCallback(styleSheetIds)
{
if (!styleSheetIds || !styleSheetIds.length)
return evalCallback([]);
var styleSheets = [];
for (var i = 0; i < styleSheetIds.length; ++i)
WebInspector.CSSStyleSheet.createForId(styleSheetIds[i], styleSheetCallback.bind(null, styleSheets, i == styleSheetIds.length - 1 ? evalCallback : null));
}
InspectorBackend.getAllStyles(allStylesCallback);
}
}
WebInspector.AuditRules.UnusedCssRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.CacheControlRule = function(id, name)
{
WebInspector.AuditRule.call(this, id, name);
}
WebInspector.AuditRules.CacheControlRule.MillisPerMonth = 1000 * 60 * 60 * 24 * 30;
WebInspector.AuditRules.CacheControlRule.prototype = {
doRun: function(resources, result, callback)
{
var cacheableAndNonCacheableResources = this._cacheableAndNonCacheableResources(resources);
if (cacheableAndNonCacheableResources[0].length)
this.runChecks(cacheableAndNonCacheableResources[0], result);
this.handleNonCacheableResources(cacheableAndNonCacheableResources[1], result);
callback(result);
},
handleNonCacheableResources: function()
{
},
_cacheableAndNonCacheableResources: function(resources)
{
var processedResources = [[], []];
for (var i = 0; i < resources.length; ++i) {
var resource = resources[i];
if (!this.isCacheableResource(resource))
continue;
if (this._isExplicitlyNonCacheable(resource))
processedResources[1].push(resource);
else
processedResources[0].push(resource);
}
return processedResources;
},
execCheck: function(messageText, resourceCheckFunction, resources, result)
{
var resourceCount = resources.length;
var urls = [];
for (var i = 0; i < resourceCount; ++i) {
if (resourceCheckFunction.call(this, resources[i]))
urls.push(resources[i].url);
}
if (urls.length) {
var entry = result.addChild(messageText, true);
entry.addURLs(urls);
result.violationCount += urls.length;
}
},
freshnessLifetimeGreaterThan: function(resource, timeMs)
{
var dateHeader = this.responseHeader(resource, "Date");
if (!dateHeader)
return false;
var dateHeaderMs = Date.parse(dateHeader);
if (isNaN(dateHeaderMs))
return false;
var freshnessLifetimeMs;
var maxAgeMatch = this.responseHeaderMatch(resource, "Cache-Control", "max-age=(\\d+)");
if (maxAgeMatch)
freshnessLifetimeMs = (maxAgeMatch[1]) ? 1000 * maxAgeMatch[1] : 0;
else {
var expiresHeader = this.responseHeader(resource, "Expires");
if (expiresHeader) {
var expDate = Date.parse(expiresHeader);
if (!isNaN(expDate))
freshnessLifetimeMs = expDate - dateHeaderMs;
}
}
return (isNaN(freshnessLifetimeMs)) ? false : freshnessLifetimeMs > timeMs;
},
responseHeader: function(resource, header)
{
return resource.responseHeaders[header];
},
hasResponseHeader: function(resource, header)
{
return resource.responseHeaders[header] !== undefined;
},
isCompressible: function(resource)
{
return WebInspector.Resource.Type.isTextType(resource.type);
},
isPubliclyCacheable: function(resource)
{
if (this._isExplicitlyNonCacheable(resource))
return false;
if (this.responseHeaderMatch(resource, "Cache-Control", "public"))
return true;
return resource.url.indexOf("?") == -1 && !this.responseHeaderMatch(resource, "Cache-Control", "private");
},
responseHeaderMatch: function(resource, header, regexp)
{
return resource.responseHeaders[header]
? resource.responseHeaders[header].match(new RegExp(regexp, "im"))
: undefined;
},
hasExplicitExpiration: function(resource)
{
return this.hasResponseHeader(resource, "Date") &&
(this.hasResponseHeader(resource, "Expires") || this.responseHeaderMatch(resource, "Cache-Control", "max-age"));
},
_isExplicitlyNonCacheable: function(resource)
{
var hasExplicitExp = this.hasExplicitExpiration(resource);
return this.responseHeaderMatch(resource, "Cache-Control", "(no-cache|no-store|must-revalidate)") ||
this.responseHeaderMatch(resource, "Pragma", "no-cache") ||
(hasExplicitExp && !this.freshnessLifetimeGreaterThan(resource, 0)) ||
(!hasExplicitExp && resource.url && resource.url.indexOf("?") >= 0) ||
(!hasExplicitExp && !this.isCacheableResource(resource));
},
isCacheableResource: function(resource)
{
return resource.statusCode !== undefined && WebInspector.AuditRules.CacheableResponseCodes[resource.statusCode];
}
}
WebInspector.AuditRules.CacheControlRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.BrowserCacheControlRule = function()
{
WebInspector.AuditRules.CacheControlRule.call(this, "http-browsercache", "Leverage browser caching");
}
WebInspector.AuditRules.BrowserCacheControlRule.prototype = {
handleNonCacheableResources: function(resources, result)
{
if (resources.length) {
var entry = result.addChild("The following resources are explicitly non-cacheable. Consider making them cacheable if possible:", true);
result.violationCount += resources.length;
for (var i = 0; i < resources.length; ++i)
entry.addURL(resources[i].url);
}
},
runChecks: function(resources, result, callback)
{
this.execCheck("The following resources are missing a cache expiration. Resources that do not specify an expiration may not be cached by browsers:",
this._missingExpirationCheck, resources, result);
this.execCheck("The following resources specify a \"Vary\" header that disables caching in most versions of Internet Explorer:",
this._varyCheck, resources, result);
this.execCheck("The following cacheable resources have a short freshness lifetime:",
this._oneMonthExpirationCheck, resources, result);
// Unable to implement the favicon check due to the WebKit limitations.
this.execCheck("To further improve cache hit rate, specify an expiration one year in the future for the following cacheable resources:",
this._oneYearExpirationCheck, resources, result);
},
_missingExpirationCheck: function(resource)
{
return this.isCacheableResource(resource) && !this.hasResponseHeader(resource, "Set-Cookie") && !this.hasExplicitExpiration(resource);
},
_varyCheck: function(resource)
{
var varyHeader = this.responseHeader(resource, "Vary");
if (varyHeader) {
varyHeader = varyHeader.replace(/User-Agent/gi, "");
varyHeader = varyHeader.replace(/Accept-Encoding/gi, "");
varyHeader = varyHeader.replace(/[, ]*/g, "");
}
return varyHeader && varyHeader.length && this.isCacheableResource(resource) && this.freshnessLifetimeGreaterThan(resource, 0);
},
_oneMonthExpirationCheck: function(resource)
{
return this.isCacheableResource(resource) &&
!this.hasResponseHeader(resource, "Set-Cookie") &&
!this.freshnessLifetimeGreaterThan(resource, WebInspector.AuditRules.CacheControlRule.MillisPerMonth) &&
this.freshnessLifetimeGreaterThan(resource, 0);
},
_oneYearExpirationCheck: function(resource)
{
return this.isCacheableResource(resource) &&
!this.hasResponseHeader(resource, "Set-Cookie") &&
!this.freshnessLifetimeGreaterThan(resource, 11 * WebInspector.AuditRules.CacheControlRule.MillisPerMonth) &&
this.freshnessLifetimeGreaterThan(resource, WebInspector.AuditRules.CacheControlRule.MillisPerMonth);
}
}
WebInspector.AuditRules.BrowserCacheControlRule.prototype.__proto__ = WebInspector.AuditRules.CacheControlRule.prototype;
WebInspector.AuditRules.ProxyCacheControlRule = function() {
WebInspector.AuditRules.CacheControlRule.call(this, "http-proxycache", "Leverage proxy caching");
}
WebInspector.AuditRules.ProxyCacheControlRule.prototype = {
runChecks: function(resources, result, callback)
{
this.execCheck("Resources with a \"?\" in the URL are not cached by most proxy caching servers:",
this._questionMarkCheck, resources, result);
this.execCheck("Consider adding a \"Cache-Control: public\" header to the following resources:",
this._publicCachingCheck, resources, result);
this.execCheck("The following publicly cacheable resources contain a Set-Cookie header. This security vulnerability can cause cookies to be shared by multiple users.",
this._setCookieCacheableCheck, resources, result);
},
_questionMarkCheck: function(resource)
{
return resource.url.indexOf("?") >= 0 && !this.hasResponseHeader(resource, "Set-Cookie") && this.isPubliclyCacheable(resource);
},
_publicCachingCheck: function(resource)
{
return this.isCacheableResource(resource) &&
!this.isCompressible(resource) &&
!this.responseHeaderMatch(resource, "Cache-Control", "public") &&
!this.hasResponseHeader(resource, "Set-Cookie");
},
_setCookieCacheableCheck: function(resource)
{
return this.hasResponseHeader(resource, "Set-Cookie") && this.isPubliclyCacheable(resource);
}
}
WebInspector.AuditRules.ProxyCacheControlRule.prototype.__proto__ = WebInspector.AuditRules.CacheControlRule.prototype;
WebInspector.AuditRules.ImageDimensionsRule = function()
{
WebInspector.AuditRule.call(this, "page-imagedims", "Specify image dimensions");
}
WebInspector.AuditRules.ImageDimensionsRule.prototype = {
doRun: function(resources, result, callback)
{
function doneCallback(context)
{
var map = context.urlToNoDimensionCount;
for (var url in map) {
var entry = entry || result.addChild("A width and height should be specified for all images in order to speed up page display. The following image(s) are missing a width and/or height:", true);
var value = WebInspector.AuditRuleResult.linkifyDisplayName(url);
if (map[url] > 1)
value += String.sprintf(" (%d uses)", map[url]);
entry.addChild(value);
result.violationCount++;
}
callback(entry ? result : null);
}
function imageStylesReady(imageId, context, styles)
{
--context.imagesLeft;
var node = WebInspector.domAgent.nodeForId(imageId);
var src = node.getAttribute("src");
if (!src.asParsedURL()) {
for (var frameOwnerCandidate = node; frameOwnerCandidate; frameOwnerCandidate = frameOwnerCandidate.parentNode) {
if (frameOwnerCandidate.documentURL) {
var completeSrc = WebInspector.completeURL(frameOwnerCandidate.documentURL, src);
break;
}
}
}
if (completeSrc)
src = completeSrc;
var computedStyle = styles.computedStyle;
if (computedStyle.getPropertyValue("position") === "absolute") {
if (!context.imagesLeft)
doneCallback(context);
return;
}
var widthFound = "width" in styles.styleAttributes;
var heightFound = "height" in styles.styleAttributes;
for (var i = styles.matchedCSSRules.length - 1; i >= 0 && !(widthFound && heightFound); --i) {
var style = styles.matchedCSSRules[i].style;
if (style.getPropertyValue("width") !== "")
widthFound = true;
if (style.getPropertyValue("height") !== "")
heightFound = true;
}
if (!widthFound || !heightFound) {
if (src in context.urlToNoDimensionCount)
++context.urlToNoDimensionCount[src];
else
context.urlToNoDimensionCount[src] = 1;
}
if (!context.imagesLeft)
doneCallback(context);
}
function receivedImages(imageIds)
{
if (!imageIds || !imageIds.length)
return callback(null);
var context = {imagesLeft: imageIds.length, urlToNoDimensionCount: {}};
for (var i = imageIds.length - 1; i >= 0; --i)
WebInspector.cssModel.getStylesAsync(imageIds[i], imageStylesReady.bind(this, imageIds[i], context));
}
function pushImageNodes()
{
var nodeIds = [];
var nodes = document.getElementsByTagName("img");
for (var i = 0; i < nodes.length; ++i) {
if (!nodes[i].src)
continue;
var nodeId = this.getNodeId(nodes[i]);
nodeIds.push(nodeId);
}
return nodeIds;
}
WebInspector.AuditRules.evaluateInTargetWindow(pushImageNodes, [], receivedImages);
}
}
WebInspector.AuditRules.ImageDimensionsRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.CssInHeadRule = function()
{
WebInspector.AuditRule.call(this, "page-cssinhead", "Put CSS in the document head");
}
WebInspector.AuditRules.CssInHeadRule.prototype = {
doRun: function(resources, result, callback)
{
function evalCallback(evalResult)
{
if (!evalResult)
return callback(null);
var summary = result.addChild("");
var outputMessages = [];
for (var url in evalResult) {
var urlViolations = evalResult[url];
if (urlViolations[0]) {
result.addChild(String.sprintf("%s style block(s) in the %s body should be moved to the document head.", urlViolations[0], WebInspector.AuditRuleResult.linkifyDisplayName(url)));
result.violationCount += urlViolations[0];
}
for (var i = 0; i < urlViolations[1].length; ++i)
result.addChild(String.sprintf("Link node %s should be moved to the document head in %s", WebInspector.AuditRuleResult.linkifyDisplayName(urlViolations[1][i]), WebInspector.AuditRuleResult.linkifyDisplayName(url)));
result.violationCount += urlViolations[1].length;
}
summary.value = String.sprintf("CSS in the document body adversely impacts rendering performance.");
callback(result);
}
function routine()
{
function allViews() {
var views = [document.defaultView];
var curView = 0;
while (curView < views.length) {
var view = views[curView];
var frames = view.frames;
for (var i = 0; i < frames.length; ++i) {
if (frames[i] !== view)
views.push(frames[i]);
}
++curView;
}
return views;
}
var views = allViews();
var urlToViolationsArray = {};
var found = false;
for (var i = 0; i < views.length; ++i) {
var view = views[i];
if (!view.document)
continue;
var inlineStyles = view.document.querySelectorAll("body style");
var inlineStylesheets = view.document.querySelectorAll("body link[rel~='stylesheet'][href]");
if (!inlineStyles.length && !inlineStylesheets.length)
continue;
found = true;
var inlineStylesheetHrefs = [];
for (var j = 0; j < inlineStylesheets.length; ++j)
inlineStylesheetHrefs.push(inlineStylesheets[j].href);
urlToViolationsArray[view.location.href] = [inlineStyles.length, inlineStylesheetHrefs];
}
return found ? urlToViolationsArray : null;
}
WebInspector.AuditRules.evaluateInTargetWindow(routine, [], evalCallback);
}
}
WebInspector.AuditRules.CssInHeadRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.StylesScriptsOrderRule = function()
{
WebInspector.AuditRule.call(this, "page-stylescriptorder", "Optimize the order of styles and scripts");
}
WebInspector.AuditRules.StylesScriptsOrderRule.prototype = {
doRun: function(resources, result, callback)
{
function evalCallback(resultValue)
{
if (!resultValue)
return callback(null);
var lateCssUrls = resultValue[0];
var cssBeforeInlineCount = resultValue[1];
var entry = result.addChild("The following external CSS files were included after an external JavaScript file in the document head. To ensure CSS files are downloaded in parallel, always include external CSS before external JavaScript.", true);
entry.addURLs(lateCssUrls);
result.violationCount += lateCssUrls.length;
if (cssBeforeInlineCount) {
result.addChild(String.sprintf(" %d inline script block%s found in the head between an external CSS file and another resource. To allow parallel downloading, move the inline script before the external CSS file, or after the next resource.", cssBeforeInlineCount, cssBeforeInlineCount > 1 ? "s were" : " was"));
result.violationCount += cssBeforeInlineCount;
}
callback(result);
}
function routine()
{
var lateStyles = document.querySelectorAll("head script[src] ~ link[rel~='stylesheet'][href]");
var cssBeforeInlineCount = document.querySelectorAll("head link[rel~='stylesheet'][href] ~ script:not([src])").length;
if (!lateStyles.length && !cssBeforeInlineCount)
return null;
var lateStyleUrls = [];
for (var i = 0; i < lateStyles.length; ++i)
lateStyleUrls.push(lateStyles[i].href);
return [ lateStyleUrls, cssBeforeInlineCount ];
}
WebInspector.AuditRules.evaluateInTargetWindow(routine, [], evalCallback.bind(this));
}
}
WebInspector.AuditRules.StylesScriptsOrderRule.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.CookieRuleBase = function(id, name)
{
WebInspector.AuditRule.call(this, id, name);
}
WebInspector.AuditRules.CookieRuleBase.prototype = {
doRun: function(resources, result, callback)
{
var self = this;
function resultCallback(receivedCookies, isAdvanced) {
self.processCookies(isAdvanced ? receivedCookies : [], resources, result);
callback(result);
}
WebInspector.Cookies.getCookiesAsync(resultCallback);
},
mapResourceCookies: function(resourcesByDomain, allCookies, callback)
{
for (var i = 0; i < allCookies.length; ++i) {
for (var resourceDomain in resourcesByDomain) {
if (WebInspector.Cookies.cookieDomainMatchesResourceDomain(allCookies[i].domain, resourceDomain))
this._callbackForResourceCookiePairs(resourcesByDomain[resourceDomain], allCookies[i], callback);
}
}
},
_callbackForResourceCookiePairs: function(resources, cookie, callback)
{
if (!resources)
return;
for (var i = 0; i < resources.length; ++i) {
if (WebInspector.Cookies.cookieMatchesResourceURL(cookie, resources[i].url))
callback(resources[i], cookie);
}
}
}
WebInspector.AuditRules.CookieRuleBase.prototype.__proto__ = WebInspector.AuditRule.prototype;
WebInspector.AuditRules.CookieSizeRule = function(avgBytesThreshold)
{
WebInspector.AuditRules.CookieRuleBase.call(this, "http-cookiesize", "Minimize cookie size");
this._avgBytesThreshold = avgBytesThreshold;
this._maxBytesThreshold = 1000;
}
WebInspector.AuditRules.CookieSizeRule.prototype = {
_average: function(cookieArray)
{
var total = 0;
for (var i = 0; i < cookieArray.length; ++i)
total += cookieArray[i].size;
return cookieArray.length ? Math.round(total / cookieArray.length) : 0;
},
_max: function(cookieArray)
{
var result = 0;
for (var i = 0; i < cookieArray.length; ++i)
result = Math.max(cookieArray[i].size, result);
return result;
},
processCookies: function(allCookies, resources, result)
{
function maxSizeSorter(a, b)
{
return b.maxCookieSize - a.maxCookieSize;
}
function avgSizeSorter(a, b)
{
return b.avgCookieSize - a.avgCookieSize;
}
var cookiesPerResourceDomain = {};
function collectorCallback(resource, cookie)
{
var cookies = cookiesPerResourceDomain[resource.domain];
if (!cookies) {
cookies = [];
cookiesPerResourceDomain[resource.domain] = cookies;
}
cookies.push(cookie);
}
if (!allCookies.length)
return;
var sortedCookieSizes = [];
var domainToResourcesMap = WebInspector.AuditRules.getDomainToResourcesMap(resources,
null,
true);
var matchingResourceData = {};
this.mapResourceCookies(domainToResourcesMap, allCookies, collectorCallback.bind(this));
for (var resourceDomain in cookiesPerResourceDomain) {
var cookies = cookiesPerResourceDomain[resourceDomain];
sortedCookieSizes.push({
domain: resourceDomain,
avgCookieSize: this._average(cookies),
maxCookieSize: this._max(cookies)
});
}
var avgAllCookiesSize = this._average(allCookies);
var hugeCookieDomains = [];
sortedCookieSizes.sort(maxSizeSorter);
for (var i = 0, len = sortedCookieSizes.length; i < len; ++i) {
var maxCookieSize = sortedCookieSizes[i].maxCookieSize;
if (maxCookieSize > this._maxBytesThreshold)
hugeCookieDomains.push(WebInspector.AuditRuleResult.resourceDomain(sortedCookieSizes[i].domain) + ": " + Number.bytesToString(maxCookieSize));
}
var bigAvgCookieDomains = [];
sortedCookieSizes.sort(avgSizeSorter);
for (var i = 0, len = sortedCookieSizes.length; i < len; ++i) {
var domain = sortedCookieSizes[i].domain;
var avgCookieSize = sortedCookieSizes[i].avgCookieSize;
if (avgCookieSize > this._avgBytesThreshold && avgCookieSize < this._maxBytesThreshold)
bigAvgCookieDomains.push(WebInspector.AuditRuleResult.resourceDomain(domain) + ": " + Number.bytesToString(avgCookieSize));
}
result.addChild(String.sprintf("The average cookie size for all requests on this page is %s", Number.bytesToString(avgAllCookiesSize)));
var message;
if (hugeCookieDomains.length) {
var entry = result.addChild("The following domains have a cookie size in excess of 1KB. This is harmful because requests with cookies larger than 1KB typically cannot fit into a single network packet.", true);
entry.addURLs(hugeCookieDomains);
result.violationCount += hugeCookieDomains.length;
}
if (bigAvgCookieDomains.length) {
var entry = result.addChild(String.sprintf("The following domains have an average cookie size in excess of %d bytes. Reducing the size of cookies for these domains can reduce the time it takes to send requests.", this._avgBytesThreshold), true);
entry.addURLs(bigAvgCookieDomains);
result.violationCount += bigAvgCookieDomains.length;
}
}
}
WebInspector.AuditRules.CookieSizeRule.prototype.__proto__ = WebInspector.AuditRules.CookieRuleBase.prototype;
WebInspector.AuditRules.StaticCookielessRule = function(minResources)
{
WebInspector.AuditRules.CookieRuleBase.call(this, "http-staticcookieless", "Serve static content from a cookieless domain");
this._minResources = minResources;
}
WebInspector.AuditRules.StaticCookielessRule.prototype = {
processCookies: function(allCookies, resources, result)
{
var domainToResourcesMap = WebInspector.AuditRules.getDomainToResourcesMap(resources,
[WebInspector.Resource.Type.Stylesheet,
WebInspector.Resource.Type.Image],
true);
var totalStaticResources = 0;
for (var domain in domainToResourcesMap)
totalStaticResources += domainToResourcesMap[domain].length;
if (totalStaticResources < this._minResources)
return;
var matchingResourceData = {};
this.mapResourceCookies(domainToResourcesMap, allCookies, this._collectorCallback.bind(this, matchingResourceData));
var badUrls = [];
var cookieBytes = 0;
for (var url in matchingResourceData) {
badUrls.push(url);
cookieBytes += matchingResourceData[url]
}
if (badUrls.length < this._minResources)
return;
var entry = result.addChild(String.sprintf("%s of cookies were sent with the following static resources. Serve these static resources from a domain that does not set cookies:", Number.bytesToString(cookieBytes)), true);
entry.addURLs(badUrls);
result.violationCount = badUrls.length;
},
_collectorCallback: function(matchingResourceData, resource, cookie)
{
matchingResourceData[resource.url] = (matchingResourceData[resource.url] || 0) + cookie.size;
}
}
WebInspector.AuditRules.StaticCookielessRule.prototype.__proto__ = WebInspector.AuditRules.CookieRuleBase.prototype;
================================================
FILE: buildin_modules/weinre/web/client/AuditsPanel.js
================================================
/*
* Copyright (C) 2011 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.AuditsPanel = function()
{
WebInspector.Panel.call(this, "audits");
this.createSidebar();
this.auditsTreeElement = new WebInspector.SidebarSectionTreeElement("", {}, true);
this.sidebarTree.appendChild(this.auditsTreeElement);
this.auditsTreeElement.listItemElement.addStyleClass("hidden");
this.auditsTreeElement.expand();
this.auditsItemTreeElement = new WebInspector.AuditsSidebarTreeElement();
this.auditsTreeElement.appendChild(this.auditsItemTreeElement);
this.auditResultsTreeElement = new WebInspector.SidebarSectionTreeElement(WebInspector.UIString("RESULTS"), {}, true);
this.sidebarTree.appendChild(this.auditResultsTreeElement);
this.auditResultsTreeElement.expand();
this.clearResultsButton = new WebInspector.StatusBarButton(WebInspector.UIString("Clear audit results."), "clear-status-bar-item");
this.clearResultsButton.addEventListener("click", this._clearButtonClicked.bind(this), false);
this.viewsContainerElement = document.createElement("div");
this.viewsContainerElement.id = "audit-views";
this.element.appendChild(this.viewsContainerElement);
this._constructCategories();
this._launcherView = new WebInspector.AuditLauncherView(this.initiateAudit.bind(this));
for (id in this.categoriesById)
this._launcherView.addCategory(this.categoriesById[id]);
}
WebInspector.AuditsPanel.prototype = {
get toolbarItemLabel()
{
return WebInspector.UIString("Audits");
},
get statusBarItems()
{
return [this.clearResultsButton.element];
},
get mainResourceLoadTime()
{
return this._mainResourceLoadTime;
},
set mainResourceLoadTime(x)
{
this._mainResourceLoadTime = x;
this._didMainResourceLoad();
},
get mainResourceDOMContentTime()
{
return this._mainResourceDOMContentTime;
},
set mainResourceDOMContentTime(x)
{
this._mainResourceDOMContentTime = x;
},
get categoriesById()
{
return this._auditCategoriesById;
},
addCategory: function(category)
{
this.categoriesById[category.id] = category;
this._launcherView.addCategory(category);
},
getCategory: function(id)
{
return this.categoriesById[id];
},
_constructCategories: function()
{
this._auditCategoriesById = {};
for (var categoryCtorID in WebInspector.AuditCategories) {
var auditCategory = new WebInspector.AuditCategories[categoryCtorID]();
auditCategory._id = categoryCtorID;
this.categoriesById[categoryCtorID] = auditCategory;
}
},
_executeAudit: function(categories, resultCallback)
{
var resources = WebInspector.networkResources;
var rulesRemaining = 0;
for (var i = 0; i < categories.length; ++i)
rulesRemaining += categories[i].ruleCount;
var results = [];
var mainResourceURL = WebInspector.mainResource.url;
function ruleResultReadyCallback(categoryResult, ruleResult)
{
if (ruleResult && ruleResult.children)
categoryResult.addRuleResult(ruleResult);
--rulesRemaining;
if (!rulesRemaining && resultCallback)
resultCallback(mainResourceURL, results);
}
if (!rulesRemaining) {
resultCallback(mainResourceURL, results);
return;
}
for (var i = 0; i < categories.length; ++i) {
var category = categories[i];
var result = new WebInspector.AuditCategoryResult(category);
results.push(result);
category.run(resources, ruleResultReadyCallback.bind(null, result));
}
},
_auditFinishedCallback: function(launcherCallback, mainResourceURL, results)
{
var children = this.auditResultsTreeElement.children;
var ordinal = 1;
for (var i = 0; i < children.length; ++i) {
if (children[i].mainResourceURL === mainResourceURL)
ordinal++;
}
var resultTreeElement = new WebInspector.AuditResultSidebarTreeElement(results, mainResourceURL, ordinal);
this.auditResultsTreeElement.appendChild(resultTreeElement);
resultTreeElement.reveal();
resultTreeElement.select();
if (launcherCallback)
launcherCallback();
},
initiateAudit: function(categoryIds, runImmediately, launcherCallback)
{
if (!categoryIds || !categoryIds.length)
return;
var categories = [];
for (var i = 0; i < categoryIds.length; ++i)
categories.push(this.categoriesById[categoryIds[i]]);
function initiateAuditCallback(categories, launcherCallback)
{
this._executeAudit(categories, this._auditFinishedCallback.bind(this, launcherCallback));
}
if (runImmediately)
initiateAuditCallback.call(this, categories, launcherCallback);
else
this._reloadResources(initiateAuditCallback.bind(this, categories, launcherCallback));
},
_reloadResources: function(callback)
{
this._pageReloadCallback = callback;
InspectorBackend.reloadPage(false);
},
_didMainResourceLoad: function()
{
if (this._pageReloadCallback) {
var callback = this._pageReloadCallback;
delete this._pageReloadCallback;
callback();
}
},
showResults: function(categoryResults)
{
if (!categoryResults._resultView)
categoryResults._resultView = new WebInspector.AuditResultView(categoryResults);
this.visibleView = categoryResults._resultView;
},
showLauncherView: function()
{
this.visibleView = this._launcherView;
},
get visibleView()
{
return this._visibleView;
},
set visibleView(x)
{
if (this._visibleView === x)
return;
if (this._visibleView)
this._visibleView.hide();
this._visibleView = x;
if (x)
x.show(this.viewsContainerElement);
},
attach: function()
{
WebInspector.Panel.prototype.attach.call(this);
this.auditsItemTreeElement.select();
},
updateMainViewWidth: function(width)
{
this.viewsContainerElement.style.left = width + "px";
},
_clearButtonClicked: function()
{
this.auditsItemTreeElement.reveal();
this.auditsItemTreeElement.select();
this.auditResultsTreeElement.removeChildren();
}
}
WebInspector.AuditsPanel.prototype.__proto__ = WebInspector.Panel.prototype;
WebInspector.AuditCategory = function(displayName)
{
this._displayName = displayName;
this._rules = [];
}
WebInspector.AuditCategory.prototype = {
get id()
{
// this._id value is injected at construction time.
return this._id;
},
get displayName()
{
return this._displayName;
},
get ruleCount()
{
this._ensureInitialized();
return this._rules.length;
},
addRule: function(rule, severity)
{
rule.severity = severity;
this._rules.push(rule);
},
run: function(resources, callback)
{
this._ensureInitialized();
for (var i = 0; i < this._rules.length; ++i)
this._rules[i].run(resources, callback);
},
_ensureInitialized: function()
{
if (!this._initialized) {
if ("initialize" in this)
this.initialize();
this._initialized = true;
}
}
}
WebInspector.AuditRule = function(id, displayName)
{
this._id = id;
this._displayName = displayName;
}
WebInspector.AuditRule.Severity = {
Info: "info",
Warning: "warning",
Severe: "severe"
}
WebInspector.AuditRule.SeverityOrder = {
"info": 3,
"warning": 2,
"severe": 1
}
WebInspector.AuditRule.prototype = {
get id()
{
return this._id;
},
get displayName()
{
return this._displayName;
},
set severity(severity)
{
this._severity = severity;
},
run: function(resources, callback)
{
var result = new WebInspector.AuditRuleResult(this.displayName);
result.severity = this._severity;
this.doRun(resources, result, callback);
},
doRun: function(resources, result, callback)
{
throw new Error("doRun() not implemented");
}
}
WebInspector.AuditCategoryResult = function(category)
{
this.title = category.displayName;
this.ruleResults = [];
}
WebInspector.AuditCategoryResult.prototype = {
addRuleResult: function(ruleResult)
{
this.ruleResults.push(ruleResult);
}
}
WebInspector.AuditRuleResult = function(value, expanded, className)
{
this.value = value;
this.className = className;
this.expanded = expanded;
this.violationCount = 0;
}
WebInspector.AuditRuleResult.linkifyDisplayName = function(url)
{
return WebInspector.linkifyURL(url, WebInspector.displayNameForURL(url));
}
WebInspector.AuditRuleResult.resourceDomain = function(domain)
{
return domain || WebInspector.UIString("[empty domain]");
}
WebInspector.AuditRuleResult.prototype = {
addChild: function(value, expanded, className)
{
if (!this.children)
this.children = [];
var entry = new WebInspector.AuditRuleResult(value, expanded, className);
this.children.push(entry);
return entry;
},
addURL: function(url)
{
return this.addChild(WebInspector.AuditRuleResult.linkifyDisplayName(url));
},
addURLs: function(urls)
{
for (var i = 0; i < urls.length; ++i)
this.addURL(urls[i]);
},
addSnippet: function(snippet)
{
return this.addChild(snippet, false, "source-code");
}
}
WebInspector.AuditsSidebarTreeElement = function()
{
this.small = false;
WebInspector.SidebarTreeElement.call(this, "audits-sidebar-tree-item", WebInspector.UIString("Audits"), "", null, false);
}
WebInspector.AuditsSidebarTreeElement.prototype = {
onattach: function()
{
WebInspector.SidebarTreeElement.prototype.onattach.call(this);
},
onselect: function()
{
WebInspector.panels.audits.showLauncherView();
},
get selectable()
{
return true;
},
refresh: function()
{
this.refreshTitles();
}
}
WebInspector.AuditsSidebarTreeElement.prototype.__proto__ = WebInspector.SidebarTreeElement.prototype;
WebInspector.AuditResultSidebarTreeElement = function(results, mainResourceURL, ordinal)
{
this.results = results;
this.mainResourceURL = mainResourceURL;
WebInspector.SidebarTreeElement.call(this, "audit-result-sidebar-tree-item", String.sprintf("%s (%d)", mainResourceURL, ordinal), "", {}, false);
}
WebInspector.AuditResultSidebarTreeElement.prototype = {
onselect: function()
{
WebInspector.panels.audits.showResults(this.results);
},
get selectable()
{
return true;
}
}
WebInspector.AuditResultSidebarTreeElement.prototype.__proto__ = WebInspector.SidebarTreeElement.prototype;
// Contributed audit rules should go into this namespace.
WebInspector.AuditRules = {};
// Contributed audit categories should go into this namespace.
WebInspector.AuditCategories = {};
================================================
FILE: buildin_modules/weinre/web/client/BottomUpProfileDataGridTree.js
================================================
/*
* Copyright (C) 2009 280 North Inc. All Rights Reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
// Bottom Up Profiling shows the entire callstack backwards:
// The root node is a representation of each individual function called, and each child of that node represents
// a reverse-callstack showing how many of those calls came from it. So, unlike top-down, the statistics in
// each child still represent the root node. We have to be particularly careful of recursion with this mode
// because a root node can represent itself AND an ancestor.
WebInspector.BottomUpProfileDataGridNode = function(/*ProfileView*/ profileView, /*ProfileNode*/ profileNode, /*BottomUpProfileDataGridTree*/ owningTree)
{
WebInspector.ProfileDataGridNode.call(this, profileView, profileNode, owningTree, this._willHaveChildren(profileNode));
this._remainingNodeInfos = [];
}
WebInspector.BottomUpProfileDataGridNode.prototype = {
_takePropertiesFromProfileDataGridNode: function(/*ProfileDataGridNode*/ profileDataGridNode)
{
this._save();
this.selfTime = profileDataGridNode.selfTime;
this.totalTime = profileDataGridNode.totalTime;
this.numberOfCalls = profileDataGridNode.numberOfCalls;
},
// When focusing, we keep just the members of the callstack.
_keepOnlyChild: function(/*ProfileDataGridNode*/ child)
{
this._save();
this.removeChildren();
this.appendChild(child);
},
_exclude: function(aCallUID)
{
if (this._remainingNodeInfos)
this._populate();
this._save();
var children = this.children;
var index = this.children.length;
while (index--)
children[index]._exclude(aCallUID);
var child = this.childrenByCallUID[aCallUID];
if (child)
this._merge(child, true);
},
_restore: function()
{
WebInspector.ProfileDataGridNode.prototype._restore();
if (!this.children.length)
this.hasChildren = this._willHaveChildren();
},
_merge: function(/*ProfileDataGridNode*/ child, /*Boolean*/ shouldAbsorb)
{
this.selfTime -= child.selfTime;
WebInspector.ProfileDataGridNode.prototype._merge.call(this, child, shouldAbsorb);
},
_sharedPopulate: function()
{
var remainingNodeInfos = this._remainingNodeInfos;
var count = remainingNodeInfos.length;
for (var index = 0; index < count; ++index) {
var nodeInfo = remainingNodeInfos[index];
var ancestor = nodeInfo.ancestor;
var focusNode = nodeInfo.focusNode;
var child = this.findChild(ancestor);
// If we already have this child, then merge the data together.
if (child) {
var totalTimeAccountedFor = nodeInfo.totalTimeAccountedFor;
child.selfTime += focusNode.selfTime;
child.numberOfCalls += focusNode.numberOfCalls;
if (!totalTimeAccountedFor)
child.totalTime += focusNode.totalTime;
} else {
// If not, add it as a true ancestor.
// In heavy mode, we take our visual identity from ancestor node...
var child = new WebInspector.BottomUpProfileDataGridNode(this.profileView, ancestor, this.tree);
if (ancestor !== focusNode) {
// but the actual statistics from the "root" node (bottom of the callstack).
child.selfTime = focusNode.selfTime;
child.totalTime = focusNode.totalTime;
child.numberOfCalls = focusNode.numberOfCalls;
}
this.appendChild(child);
}
var parent = ancestor.parent;
if (parent && parent.parent) {
nodeInfo.ancestor = parent;
child._remainingNodeInfos.push(nodeInfo);
}
}
delete this._remainingNodeInfos;
},
_willHaveChildren: function(profileNode)
{
profileNode = profileNode || this.profileNode;
// In bottom up mode, our parents are our children since we display an inverted tree.
// However, we don't want to show the very top parent since it is redundant.
return !!(profileNode.parent && profileNode.parent.parent);
}
}
WebInspector.BottomUpProfileDataGridNode.prototype.__proto__ = WebInspector.ProfileDataGridNode.prototype;
WebInspector.BottomUpProfileDataGridTree = function(/*ProfileView*/ aProfileView, /*ProfileNode*/ aProfileNode)
{
WebInspector.ProfileDataGridTree.call(this, aProfileView, aProfileNode);
// Iterate each node in pre-order.
var profileNodeUIDs = 0;
var profileNodeGroups = [[], [aProfileNode]];
var visitedProfileNodesForCallUID = {};
this._remainingNodeInfos = [];
for (var profileNodeGroupIndex = 0; profileNodeGroupIndex < profileNodeGroups.length; ++profileNodeGroupIndex) {
var parentProfileNodes = profileNodeGroups[profileNodeGroupIndex];
var profileNodes = profileNodeGroups[++profileNodeGroupIndex];
var count = profileNodes.length;
for (var index = 0; index < count; ++index) {
var profileNode = profileNodes[index];
if (!profileNode.UID)
profileNode.UID = ++profileNodeUIDs;
if (profileNode.head && profileNode !== profileNode.head) {
// The total time of this ancestor is accounted for if we're in any form of recursive cycle.
var visitedNodes = visitedProfileNodesForCallUID[profileNode.callUID];
var totalTimeAccountedFor = false;
if (!visitedNodes) {
visitedNodes = {}
visitedProfileNodesForCallUID[profileNode.callUID] = visitedNodes;
} else {
// The total time for this node has already been accounted for iff one of it's parents has already been visited.
// We can do this check in this style because we are traversing the tree in pre-order.
var parentCount = parentProfileNodes.length;
for (var parentIndex = 0; parentIndex < parentCount; ++parentIndex) {
if (visitedNodes[parentProfileNodes[parentIndex].UID]) {
totalTimeAccountedFor = true;
break;
}
}
}
visitedNodes[profileNode.UID] = true;
this._remainingNodeInfos.push({ ancestor:profileNode, focusNode:profileNode, totalTimeAccountedFor:totalTimeAccountedFor });
}
var children = profileNode.children;
if (children.length) {
profileNodeGroups.push(parentProfileNodes.concat([profileNode]))
profileNodeGroups.push(children);
}
}
}
// Populate the top level nodes.
WebInspector.BottomUpProfileDataGridNode.prototype._populate.call(this);
return this;
}
WebInspector.BottomUpProfileDataGridTree.prototype = {
// When focusing, we keep the entire callstack up to this ancestor.
focus: function(/*ProfileDataGridNode*/ profileDataGridNode)
{
if (!profileDataGridNode)
return;
this._save();
var currentNode = profileDataGridNode;
var focusNode = profileDataGridNode;
while (currentNode.parent && (currentNode instanceof WebInspector.ProfileDataGridNode)) {
currentNode._takePropertiesFromProfileDataGridNode(profileDataGridNode);
focusNode = currentNode;
currentNode = currentNode.parent;
if (currentNode instanceof WebInspector.ProfileDataGridNode)
currentNode._keepOnlyChild(focusNode);
}
this.children = [focusNode];
this.totalTime = profileDataGridNode.totalTime;
},
exclude: function(/*ProfileDataGridNode*/ profileDataGridNode)
{
if (!profileDataGridNode)
return;
this._save();
var excludedCallUID = profileDataGridNode.callUID;
var excludedTopLevelChild = this.childrenByCallUID[excludedCallUID];
// If we have a top level node that is excluded, get rid of it completely (not keeping children),
// since bottom up data relies entirely on the root node.
if (excludedTopLevelChild)
this.children.remove(excludedTopLevelChild);
var children = this.children;
var count = children.length;
for (var index = 0; index < count; ++index)
children[index]._exclude(excludedCallUID);
if (this.lastComparator)
this.sort(this.lastComparator, true);
},
_sharedPopulate: WebInspector.BottomUpProfileDataGridNode.prototype._sharedPopulate
}
WebInspector.BottomUpProfileDataGridTree.prototype.__proto__ = WebInspector.ProfileDataGridTree.prototype;
================================================
FILE: buildin_modules/weinre/web/client/Breakpoint.js
================================================
/*
* Copyright (C) 2008 Apple Inc. All Rights Reserved.
* Copyright (C) 2010 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.Breakpoint = function(id, url, sourceID, lineNumber, columnNumber, condition, enabled)
{
this.id = id;
this.url = url;
this.sourceID = sourceID;
this.lineNumber = lineNumber;
this.columnNumber = columnNumber;
this.condition = condition;
this.enabled = enabled;
this.locations = [];
}
WebInspector.Breakpoint.prototype = {
addLocation: function(sourceID, lineNumber, columnNumber)
{
this.locations.push({ sourceID: sourceID, lineNumber: lineNumber, columnNumber: columnNumber });
}
}
================================================
FILE: buildin_modules/weinre/web/client/BreakpointManager.js
================================================
/*
* Copyright (C) 2010 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
WebInspector.BreakpointManager = function()
{
this._stickyBreakpoints = {};
var breakpoints = WebInspector.settings.findSettingForAllProjects("nativeBreakpoints");
for (var projectId in breakpoints)
this._stickyBreakpoints[projectId] = this._validateBreakpoints(breakpoints[projectId]);
this._breakpoints = {};
this._domBreakpointsRestored = false;
WebInspector.settings.addEventListener(WebInspector.Settings.Events.ProjectChanged, this._projectChanged, this);
WebInspector.debuggerModel.addEventListener(WebInspector.DebuggerModel.Events.DebuggerPaused, this._debuggerPaused, this);
WebInspector.debuggerModel.addEventListener(WebInspector.DebuggerModel.Events.DebuggerResumed, this._debuggerResumed, this);
}
WebInspector.BreakpointManager.BreakpointTypes = {
DOM: "DOM",
EventListener: "EventListener",
XHR: "XHR"
}
WebInspector.BreakpointManager.Events = {
DOMBreakpointAdded: "dom-breakpoint-added",
EventListenerBreakpointAdded: "event-listener-breakpoint-added",
XHRBreakpointAdded: "xhr-breakpoint-added",
ProjectChanged: "project-changed"
}
WebInspector.BreakpointManager.prototype = {
createDOMBreakpoint: function(nodeId, type)
{
this._createDOMBreakpoint(nodeId, type, true, false);
},
_createDOMBreakpoint: function(nodeId, type, enabled, restored)
{
gitextract_3l34r8z6/
├── .babelrc
├── .github/
│ └── FUNDING.yml
├── .gitignore
├── .travis.yml
├── LICENSE
├── README.md
├── README_EN.md
├── buildin_modules/
│ └── weinre/
│ ├── .npmignore
│ ├── LICENSE
│ ├── NOTICE
│ ├── README.md
│ ├── build-info.txt
│ ├── interfaces/
│ │ ├── WeinreClientCommands.idl
│ │ ├── WeinreClientEvents.idl
│ │ ├── WeinreExtraClientCommands.idl
│ │ ├── WeinreExtraTargetEvents.idl
│ │ ├── WeinreTargetCommands.idl
│ │ └── WeinreTargetEvents.idl
│ ├── lib/
│ │ ├── Channel.js
│ │ ├── HttpChannelHandler.js
│ │ ├── MessageQueue.js
│ │ ├── channelManager.js
│ │ ├── cli.js
│ │ ├── dumpingHandler.js
│ │ ├── extensionManager.js
│ │ ├── jsonBodyParser.js
│ │ ├── messageHandler.js
│ │ ├── service/
│ │ │ ├── WeinreClientCommands.js
│ │ │ └── WeinreTargetCommands.js
│ │ ├── serviceManager.js
│ │ ├── utils.js
│ │ └── weinre.js
│ ├── package.json
│ ├── web/
│ │ ├── client/
│ │ │ ├── ApplicationCacheItemsView.js
│ │ │ ├── AuditCategories.js
│ │ │ ├── AuditFormatters.js
│ │ │ ├── AuditLauncherView.js
│ │ │ ├── AuditResultView.js
│ │ │ ├── AuditRules.js
│ │ │ ├── AuditsPanel.js
│ │ │ ├── BottomUpProfileDataGridTree.js
│ │ │ ├── Breakpoint.js
│ │ │ ├── BreakpointManager.js
│ │ │ ├── BreakpointsSidebarPane.js
│ │ │ ├── CSSCompletions.js
│ │ │ ├── CSSKeywordCompletions.js
│ │ │ ├── CSSStyleModel.js
│ │ │ ├── CallStackSidebarPane.js
│ │ │ ├── Checkbox.js
│ │ │ ├── Color.js
│ │ │ ├── ConsolePanel.js
│ │ │ ├── ConsoleView.js
│ │ │ ├── ContextMenu.js
│ │ │ ├── CookieItemsView.js
│ │ │ ├── CookieParser.js
│ │ │ ├── CookiesTable.js
│ │ │ ├── DOMAgent.js
│ │ │ ├── DOMStorage.js
│ │ │ ├── DOMStorageItemsView.js
│ │ │ ├── DOMSyntaxHighlighter.js
│ │ │ ├── DataGrid.js
│ │ │ ├── Database.js
│ │ │ ├── DatabaseQueryView.js
│ │ │ ├── DatabaseTableView.js
│ │ │ ├── DebuggerModel.js
│ │ │ ├── DetailedHeapshotView.js
│ │ │ ├── Drawer.js
│ │ │ ├── ElementsPanel.js
│ │ │ ├── ElementsTreeOutline.js
│ │ │ ├── EventListenersSidebarPane.js
│ │ │ ├── ExtensionAPI.js
│ │ │ ├── ExtensionAPISchema.json
│ │ │ ├── ExtensionAuditCategory.js
│ │ │ ├── ExtensionCommon.js
│ │ │ ├── ExtensionPanel.js
│ │ │ ├── ExtensionRegistryStub.js
│ │ │ ├── ExtensionServer.js
│ │ │ ├── FontView.js
│ │ │ ├── GoToLineDialog.js
│ │ │ ├── HAREntry.js
│ │ │ ├── HeapSnapshot.js
│ │ │ ├── HeapSnapshotView.js
│ │ │ ├── HelpScreen.js
│ │ │ ├── ImageView.js
│ │ │ ├── InjectedFakeWorker.js
│ │ │ ├── InspectorBackendStub.js
│ │ │ ├── InspectorBackendStub.qrc
│ │ │ ├── InspectorFrontendHostStub.js
│ │ │ ├── KeyboardShortcut.js
│ │ │ ├── MetricsSidebarPane.js
│ │ │ ├── NetworkItemView.js
│ │ │ ├── NetworkManager.js
│ │ │ ├── NetworkPanel.js
│ │ │ ├── Object.js
│ │ │ ├── ObjectPropertiesSection.js
│ │ │ ├── Panel.js
│ │ │ ├── PanelEnablerView.js
│ │ │ ├── Placard.js
│ │ │ ├── PleaseWaitMessage.js
│ │ │ ├── Popover.js
│ │ │ ├── ProfileDataGridTree.js
│ │ │ ├── ProfileView.js
│ │ │ ├── ProfilesPanel.js
│ │ │ ├── PropertiesSection.js
│ │ │ ├── PropertiesSidebarPane.js
│ │ │ ├── RemoteObject.js
│ │ │ ├── Resource.js
│ │ │ ├── ResourceCategory.js
│ │ │ ├── ResourceCookiesView.js
│ │ │ ├── ResourceHeadersView.js
│ │ │ ├── ResourceTimingView.js
│ │ │ ├── ResourceTreeModel.js
│ │ │ ├── ResourceView.js
│ │ │ ├── ResourcesPanel.js
│ │ │ ├── ScopeChainSidebarPane.js
│ │ │ ├── Script.js
│ │ │ ├── ScriptFormatter.js
│ │ │ ├── ScriptFormatterWorker.js
│ │ │ ├── ScriptsPanel.js
│ │ │ ├── Section.js
│ │ │ ├── Settings.js
│ │ │ ├── ShortcutsHelp.js
│ │ │ ├── ShowMoreDataGridNode.js
│ │ │ ├── SidebarPane.js
│ │ │ ├── SidebarTreeElement.js
│ │ │ ├── SourceCSSTokenizer.js
│ │ │ ├── SourceCSSTokenizer.re2js
│ │ │ ├── SourceFrame.js
│ │ │ ├── SourceFrameContent.js
│ │ │ ├── SourceHTMLTokenizer.js
│ │ │ ├── SourceHTMLTokenizer.re2js
│ │ │ ├── SourceJavaScriptTokenizer.js
│ │ │ ├── SourceJavaScriptTokenizer.re2js
│ │ │ ├── SourceTokenizer.js
│ │ │ ├── StatusBarButton.js
│ │ │ ├── StylesSidebarPane.js
│ │ │ ├── SummaryBar.js
│ │ │ ├── TabbedPane.js
│ │ │ ├── TestController.js
│ │ │ ├── TextEditorHighlighter.js
│ │ │ ├── TextEditorModel.js
│ │ │ ├── TextPrompt.js
│ │ │ ├── TextViewer.js
│ │ │ ├── TimelineAgent.js
│ │ │ ├── TimelineGrid.js
│ │ │ ├── TimelineOverviewPane.js
│ │ │ ├── TimelinePanel.js
│ │ │ ├── TopDownProfileDataGridTree.js
│ │ │ ├── UglifyJS/
│ │ │ │ ├── parse-js.js
│ │ │ │ └── process.js
│ │ │ ├── View.js
│ │ │ ├── WatchExpressionsSidebarPane.js
│ │ │ ├── WebKit.qrc
│ │ │ ├── WelcomeView.js
│ │ │ ├── WorkersSidebarPane.js
│ │ │ ├── audits.css
│ │ │ ├── goToLineDialog.css
│ │ │ ├── heapProfiler.css
│ │ │ ├── helpScreen.css
│ │ │ ├── index.html
│ │ │ ├── inspector.css
│ │ │ ├── inspector.html
│ │ │ ├── inspector.js
│ │ │ ├── inspectorSyntaxHighlight.css
│ │ │ ├── networkPanel.css
│ │ │ ├── nls/
│ │ │ │ └── English.lproj/
│ │ │ │ └── localizedStrings.js
│ │ │ ├── popover.css
│ │ │ ├── textViewer.css
│ │ │ ├── treeoutline.js
│ │ │ ├── utilities.js
│ │ │ ├── web-inspector-API.js
│ │ │ └── weinre/
│ │ │ ├── browser-support-check.js
│ │ │ ├── client.css
│ │ │ └── hacks.js
│ │ ├── demo/
│ │ │ ├── split.html
│ │ │ ├── weinre-demo-min.html
│ │ │ ├── weinre-demo-strict.html
│ │ │ ├── weinre-demo-strict.js
│ │ │ ├── weinre-demo.css
│ │ │ ├── weinre-demo.html
│ │ │ └── weinre-demo.js
│ │ ├── doc/
│ │ │ ├── Building.html
│ │ │ ├── ChangeLog.html
│ │ │ ├── Home.html
│ │ │ ├── Installing.html
│ │ │ ├── License.html
│ │ │ ├── MultiUser.html
│ │ │ ├── Running.html
│ │ │ ├── Security.html
│ │ │ ├── UserInterface.html
│ │ │ ├── build-info.txt
│ │ │ ├── css/
│ │ │ │ └── main.css
│ │ │ ├── index.html
│ │ │ └── scripts/
│ │ │ └── main.js
│ │ ├── index.html
│ │ ├── index.js
│ │ ├── interfaces/
│ │ │ ├── InjectedScriptHost.json
│ │ │ ├── Inspector.json
│ │ │ ├── InspectorFrontendHost.json
│ │ │ ├── WeinreClientCommands.json
│ │ │ ├── WeinreClientEvents.json
│ │ │ ├── WeinreExtraClientCommands.json
│ │ │ ├── WeinreExtraTargetEvents.json
│ │ │ ├── WeinreTargetCommands.json
│ │ │ ├── WeinreTargetEvents.json
│ │ │ ├── all-json-idls-min.js
│ │ │ ├── all-json-idls.js
│ │ │ ├── interfaces.css
│ │ │ ├── interfaces.html
│ │ │ └── interfaces.js
│ │ ├── modjewel.js
│ │ ├── target/
│ │ │ ├── target-script-min.js
│ │ │ └── target-script.js
│ │ ├── tests/
│ │ │ ├── element-highlighter.html
│ │ │ └── index.html
│ │ ├── versions.js
│ │ └── weinre/
│ │ ├── client/
│ │ │ ├── Client.amd.js
│ │ │ ├── ConnectorList.amd.js
│ │ │ ├── DOMTemplates.amd.js
│ │ │ ├── ExtensionRegistryImpl.amd.js
│ │ │ ├── InspectorBackendImpl.amd.js
│ │ │ ├── InspectorFrontendHostImpl.amd.js
│ │ │ ├── RemotePanel.amd.js
│ │ │ ├── WeinreClientEventsImpl.amd.js
│ │ │ └── WeinreExtraTargetEventsImpl.amd.js
│ │ ├── common/
│ │ │ ├── Binding.amd.js
│ │ │ ├── Callback.amd.js
│ │ │ ├── Debug.amd.js
│ │ │ ├── EventListeners.amd.js
│ │ │ ├── Ex.amd.js
│ │ │ ├── HookLib.amd.js
│ │ │ ├── IDGenerator.amd.js
│ │ │ ├── IDLTools.amd.js
│ │ │ ├── MessageDispatcher.amd.js
│ │ │ ├── MethodNamer.amd.js
│ │ │ ├── StackTrace.amd.js
│ │ │ ├── WebSocketXhr.amd.js
│ │ │ └── Weinre.amd.js
│ │ └── target/
│ │ ├── BrowserHacks.amd.js
│ │ ├── CSSStore.amd.js
│ │ ├── CheckForProblems.amd.js
│ │ ├── Console.amd.js
│ │ ├── ElementHighlighter.amd.js
│ │ ├── ElementHighlighterDivs2.amd.js
│ │ ├── HookSites.amd.js
│ │ ├── InjectedScript.js
│ │ ├── InjectedScriptHostImpl.amd.js
│ │ ├── NetworkRequest.amd.js
│ │ ├── NodeStore.amd.js
│ │ ├── SqlStepper.amd.js
│ │ ├── Target.amd.js
│ │ ├── Timeline.amd.js
│ │ ├── WeinreExtraClientCommandsImpl.amd.js
│ │ ├── WeinreTargetEventsImpl.amd.js
│ │ ├── WiCSSImpl.amd.js
│ │ ├── WiConsoleImpl.amd.js
│ │ ├── WiDOMImpl.amd.js
│ │ ├── WiDOMStorageImpl.amd.js
│ │ ├── WiDatabaseImpl.amd.js
│ │ ├── WiInspectorImpl.amd.js
│ │ └── WiRuntimeImpl.amd.js
│ └── weinre
├── lib/
│ ├── config/
│ │ └── config.js
│ ├── index.js
│ ├── proxy/
│ │ ├── externalChildProcess.js
│ │ └── spyProxy.js
│ ├── scripts/
│ │ └── postinstall.js
│ ├── util/
│ │ ├── htmlUtil.js
│ │ └── httpUtil.js
│ └── weinre/
│ └── weinreDelegate.js
├── package.json
├── src/
│ ├── config/
│ │ └── config.js
│ ├── index.js
│ ├── proxy/
│ │ ├── externalChildProcess.js
│ │ └── spyProxy.js
│ ├── util/
│ │ ├── htmlUtil.js
│ │ └── httpUtil.js
│ └── weinre/
│ └── weinreDelegate.js
├── template/
│ ├── anyproxy_index.html
│ ├── inject.js.template.html
│ └── wrap.html
└── test/
└── index.js
SYMBOL INDEX (1022 symbols across 157 files)
FILE: buildin_modules/weinre/lib/Channel.js
function Channel (line 18) | function Channel(pathPrefix, id, remoteAddress, isClient) {
FILE: buildin_modules/weinre/lib/HttpChannelHandler.js
function HttpChannelHandler (line 13) | function HttpChannelHandler(pathPrefix) {
FILE: buildin_modules/weinre/lib/MessageQueue.js
function MessageQueue (line 9) | function MessageQueue() {
FILE: buildin_modules/weinre/lib/channelManager.js
function ChannelManager (line 17) | function ChannelManager() {
FILE: buildin_modules/weinre/lib/extensionManager.js
function ExtensionManager (line 7) | function ExtensionManager() {
FILE: buildin_modules/weinre/lib/messageHandler.js
function MessageHandler (line 12) | function MessageHandler() {}
FILE: buildin_modules/weinre/lib/service/WeinreClientCommands.js
function WeinreClientCommands (line 20) | function WeinreClientCommands() {}
FILE: buildin_modules/weinre/lib/service/WeinreTargetCommands.js
function WeinreTargetCommands (line 15) | function WeinreTargetCommands() {}
FILE: buildin_modules/weinre/lib/serviceManager.js
function ServiceManager (line 16) | function ServiceManager() {
FILE: buildin_modules/weinre/web/client/ApplicationCacheItemsView.js
method statusBarItems (line 75) | get statusBarItems()
function numberCompare (line 200) | function numberCompare(field, resource1, resource2)
function localeCompare (line 204) | function localeCompare(field, resource1, resource2)
FILE: buildin_modules/weinre/web/client/AuditLauncherView.js
function compareCategories (line 97) | function compareCategories(a, b)
function handleSelectAllClick (line 172) | function handleSelectAllClick(event)
FILE: buildin_modules/weinre/web/client/AuditResultView.js
function categorySorter (line 36) | function categorySorter(a, b) {
function ruleSorter (line 57) | function ruleSorter(a, b)
FILE: buildin_modules/weinre/web/client/AuditRules.js
function hostSorter (line 213) | function hostSorter(a, b)
function evalCallback (line 281) | function evalCallback(styleSheets) {
function styleSheetCallback (line 369) | function styleSheetCallback(styleSheets, continuation, styleSheet)
function allStylesCallback (line 377) | function allStylesCallback(styleSheetIds)
function doneCallback (line 642) | function doneCallback(context)
function imageStylesReady (line 656) | function imageStylesReady(imageId, context, styles)
function receivedImages (line 702) | function receivedImages(imageIds)
function pushImageNodes (line 711) | function pushImageNodes()
function evalCallback (line 739) | function evalCallback(evalResult)
function routine (line 761) | function routine()
function evalCallback (line 815) | function evalCallback(resultValue)
function routine (line 834) | function routine()
function resultCallback (line 863) | function resultCallback(receivedCookies, isAdvanced) {
function maxSizeSorter (line 920) | function maxSizeSorter(a, b)
function avgSizeSorter (line 925) | function avgSizeSorter(a, b)
function collectorCallback (line 932) | function collectorCallback(resource, cookie)
FILE: buildin_modules/weinre/web/client/AuditsPanel.js
method toolbarItemLabel (line 63) | get toolbarItemLabel()
method statusBarItems (line 68) | get statusBarItems()
method mainResourceLoadTime (line 73) | get mainResourceLoadTime()
method mainResourceLoadTime (line 78) | set mainResourceLoadTime(x)
method mainResourceDOMContentTime (line 84) | get mainResourceDOMContentTime()
method mainResourceDOMContentTime (line 89) | set mainResourceDOMContentTime(x)
method categoriesById (line 94) | get categoriesById()
function ruleResultReadyCallback (line 131) | function ruleResultReadyCallback(categoryResult, ruleResult)
function initiateAuditCallback (line 181) | function initiateAuditCallback(categories, launcherCallback)
method visibleView (line 220) | get visibleView()
method visibleView (line 225) | set visibleView(x)
method id (line 270) | get id()
method displayName (line 276) | get displayName()
method ruleCount (line 281) | get ruleCount()
method id (line 330) | get id()
method displayName (line 335) | get displayName()
method severity (line 340) | set severity(severity)
method selectable (line 434) | get selectable()
method selectable (line 462) | get selectable()
FILE: buildin_modules/weinre/web/client/BreakpointManager.js
function didPushNodeByPathToFrontend (line 217) | function didPushNodeByPathToFrontend(path, nodeId)
method enabled (line 406) | get enabled()
method enabled (line 411) | set enabled(enabled)
method hit (line 418) | get hit()
method hit (line 423) | set hit(hit)
function append (line 486) | function append(a, b)
method eventName (line 532) | get eventName()
FILE: buildin_modules/weinre/web/client/BreakpointsSidebarPane.js
function didGetSourceLine (line 226) | function didGetSourceLine(text)
function addButtonClicked (line 332) | function addButtonClicked(event)
method element (line 416) | get element()
FILE: buildin_modules/weinre/web/client/CSSStyleModel.js
function callback (line 46) | function callback(userCallback, payload)
function callback (line 91) | function callback(userCallback, stylePayload)
function callback (line 104) | function callback(userCallback, stylePayload)
function checkAffectsCallback (line 117) | function checkAffectsCallback(nodeId, successCallback, rulePayload, sele...
function callback (line 125) | function callback(nodeId, successCallback, failureCallback, newSelector,...
function checkAffectsCallback (line 138) | function checkAffectsCallback(nodeId, successCallback, rulePayload, sele...
function callback (line 146) | function callback(successCallback, failureCallback, selector, rulePayload)
function callback (line 163) | function callback(href, content)
function callback (line 174) | function callback(success)
method allProperties (line 230) | get allProperties()
function callback (line 338) | function callback(userCallback, payload)
method isUserAgent (line 378) | get isUserAgent()
method isUser (line 383) | get isUser()
method isViaInspector (line 388) | get isViaInspector()
method isRegular (line 393) | get isRegular()
method propertyText (line 421) | get propertyText()
method isLive (line 431) | get isLive()
method active (line 436) | get active()
method styleBased (line 441) | get styleBased()
method inactive (line 446) | get inactive()
method disabled (line 451) | get disabled()
function enabledCallback (line 459) | function enabledCallback(style)
function callback (line 467) | function callback(stylePayload)
function callback (line 507) | function callback(stylePayload)
function callback (line 544) | function callback(styleSheetPayload)
function callback (line 562) | function callback(styleSheetPayload)
FILE: buildin_modules/weinre/web/client/CallStackSidebarPane.js
method selectedCallFrame (line 91) | get selectedCallFrame()
method selectedCallFrame (line 96) | set selectedCallFrame(x)
FILE: buildin_modules/weinre/web/client/Checkbox.js
method checked (line 40) | set checked(checked)
method checked (line 45) | get checked()
function listenerWrapper (line 52) | function listenerWrapper(event)
FILE: buildin_modules/weinre/web/client/Color.js
method shorthex (line 37) | get shorthex()
method hex (line 54) | get hex()
method hex (line 62) | set hex(x)
method rgb (line 67) | get rgb()
method rgb (line 82) | set rgb(x)
method hsl (line 87) | get hsl()
method hsl (line 96) | set hsl(x)
method nickname (line 101) | get nickname()
method nickname (line 109) | set nickname(x)
method rgba (line 114) | get rgba()
method rgba (line 119) | set rgba(x)
method hsla (line 124) | get hsla()
method hsla (line 129) | set hsla(x)
function hueToRGB (line 252) | function hueToRGB(p, q, h) {
FILE: buildin_modules/weinre/web/client/ConsolePanel.js
method toolbarItemLabel (line 35) | get toolbarItemLabel()
FILE: buildin_modules/weinre/web/client/ConsoleView.js
function createDividerElement (line 65) | function createDividerElement() {
function createFilterElement (line 72) | function createFilterElement(category, label) {
function unselectAll (line 172) | function unselectAll()
function scrollIntoView (line 262) | function scrollIntoView()
function moveBackIfOutside (line 436) | function moveBackIfOutside()
function evalCallback (line 526) | function evalCallback(result)
function printResult (line 551) | function printResult(result)
function printNode (line 593) | function printNode(nodeId)
function consoleFormatWrapper (line 829) | function consoleFormatWrapper(force)
function append (line 843) | function append(a, b)
FILE: buildin_modules/weinre/web/client/CookieItemsView.js
method statusBarItems (line 53) | get statusBarItems()
function populateResourcesForDocuments (line 116) | function populateResourcesForDocuments(resource)
FILE: buildin_modules/weinre/web/client/CookieParser.js
method cookies (line 43) | get cookies()
method httpOnly (line 163) | get httpOnly()
method secure (line 168) | get secure()
method session (line 173) | get session()
method path (line 180) | get path()
method domain (line 185) | get domain()
method attributes (line 196) | get attributes()
FILE: buildin_modules/weinre/web/client/CookiesTable.js
method selectedCookie (line 92) | get selectedCookie()
function localeCompare (line 144) | function localeCompare(field, cookie1, cookie2)
function numberCompare (line 149) | function numberCompare(field, cookie1, cookie2)
function expiresCompare (line 154) | function expiresCompare(cookie1, cookie2)
FILE: buildin_modules/weinre/web/client/DOMAgent.js
method nodeValue (line 96) | get nodeValue() {
method nodeValue (line 100) | set nodeValue(value) {
method document (line 279) | get document()
method Node (line 284) | get Node()
method Element (line 289) | get Element()
method domWindow (line 307) | get domWindow()
function mycallback (line 319) | function mycallback() {
function mycallback (line 507) | function mycallback(applicationCaches)
function mycallback (line 535) | function mycallback(cookies, cookiesString)
FILE: buildin_modules/weinre/web/client/DOMStorage.js
method id (line 37) | get id()
method domain (line 42) | get domain()
method isLocalStorage (line 47) | get isLocalStorage()
FILE: buildin_modules/weinre/web/client/DOMStorageItemsView.js
method statusBarItems (line 44) | get statusBarItems()
FILE: buildin_modules/weinre/web/client/DataGrid.js
function moveToNextIfNeeded (line 217) | function moveToNextIfNeeded(wasChange) {
method sortColumnIdentifier (line 275) | get sortColumnIdentifier()
method sortOrder (line 282) | get sortOrder()
method headerTableBody (line 291) | get headerTableBody()
method dataTableBody (line 305) | get dataTableBody()
method scrollContainer (line 496) | get scrollContainer()
function comparatorWrapper (line 680) | function comparatorWrapper(a, b)
method element (line 1004) | get element()
method data (line 1036) | get data()
method data (line 1041) | set data(x)
method revealed (line 1047) | get revealed()
method hasChildren (line 1066) | set hasChildren(x)
method hasChildren (line 1089) | get hasChildren()
method revealed (line 1094) | set revealed(x)
method depth (line 1112) | get depth()
method shouldRefreshChildren (line 1123) | get shouldRefreshChildren()
method shouldRefreshChildren (line 1128) | set shouldRefreshChildren(x)
method selected (line 1135) | get selected()
method selected (line 1140) | set selected(x)
method expanded (line 1148) | get expanded()
method expanded (line 1153) | set expanded(x)
FILE: buildin_modules/weinre/web/client/Database.js
method id (line 38) | get id()
method name (line 43) | get name()
method name (line 48) | set name(x)
method version (line 53) | get version()
method version (line 58) | set version(x)
method domain (line 63) | get domain()
method domain (line 68) | set domain(x)
method displayDomain (line 73) | get displayDomain()
function sortingCallback (line 80) | function sortingCallback(names)
function callback (line 89) | function callback(success, transactionId)
FILE: buildin_modules/weinre/web/client/DatabaseQueryView.js
function moveBackIfOutside (line 53) | function moveBackIfOutside()
function accumulateMatches (line 70) | function accumulateMatches(textArray)
function tableNamesCallback (line 86) | function tableNamesCallback(tableNames)
function moveBackIfOutside (line 111) | function moveBackIfOutside()
FILE: buildin_modules/weinre/web/client/DatabaseTableView.js
method statusBarItems (line 47) | get statusBarItems()
FILE: buildin_modules/weinre/web/client/DebuggerModel.js
function didSetBreakpoint (line 81) | function didSetBreakpoint(breakpointsPushedToBackend, breakpointId, loca...
function didSetBreakpoint (line 97) | function didSetBreakpoint(breakpointId, actualLineNumber, actualColumnNu...
method breakpoints (line 155) | get breakpoints()
function didEditScriptSource (line 213) | function didEditScriptSource(success, newBodyOrErrorMessage, callFrames)
method callFrames (line 269) | get callFrames()
function match (line 291) | function match(location)
FILE: buildin_modules/weinre/web/client/DetailedHeapshotView.js
method profile (line 42) | get profile()
method profile (line 47) | set profile(profile)
method buttonTooltip (line 61) | get buttonTooltip()
method buttonStyle (line 66) | get buttonStyle()
method welcomeMessage (line 76) | get welcomeMessage()
FILE: buildin_modules/weinre/web/client/Drawer.js
method visibleView (line 48) | get visibleView()
method visibleView (line 53) | set visibleView(x)
method savedHeight (line 77) | get savedHeight()
function animationFinished (line 123) | function animationFinished()
function animationFinished (line 180) | function animationFinished()
method currentPanelCounters (line 255) | set currentPanelCounters(x)
function animationFinished (line 289) | function animationFinished()
FILE: buildin_modules/weinre/web/client/ElementsPanel.js
method toolbarItemLabel (line 116) | get toolbarItemLabel()
method statusBarItems (line 121) | get statusBarItems()
method defaultFocusedElement (line 126) | get defaultFocusedElement()
function selectNode (line 190) | function selectNode(candidateFocusNode)
function selectLastSelectedNode (line 203) | function selectLastSelectedNode(nodeId)
method rootDOMNode (line 353) | get rootDOMNode()
method rootDOMNode (line 358) | set rootDOMNode(x)
method focusedDOMNode (line 363) | get focusedDOMNode()
method focusedDOMNode (line 368) | set focusedDOMNode(x)
function selectCrumbFunction (line 537) | function selectCrumbFunction(event)
function crumbsAreSmallerThanContainer (line 744) | function crumbsAreSmallerThanContainer()
function makeCrumbsSmaller (line 760) | function makeCrumbsSmaller(shrinkingFunction, direction, significantCrumb)
function coalesceCollapsedCrumbs (line 820) | function coalesceCollapsedCrumbs()
function compact (line 871) | function compact(crumb)
function collapse (line 878) | function collapse(crumb, dontCoalesce)
function compactDimmed (line 888) | function compactDimmed(crumb)
function collapseDimmed (line 894) | function collapseDimmed(crumb)
FILE: buildin_modules/weinre/web/client/ElementsTreeOutline.js
method rootDOMNode (line 49) | get rootDOMNode()
method rootDOMNode (line 54) | set rootDOMNode(x)
method isXMLMimeType (line 66) | get isXMLMimeType()
method focusedDOMNode (line 76) | get focusedDOMNode()
method focusedDOMNode (line 81) | set focusedDOMNode(x)
method editing (line 100) | get editing()
method suppressRevealAndSelect (line 170) | set suppressRevealAndSelect(x)
function focusElement (line 269) | function focusElement()
method hovered (line 336) | get hovered()
method hovered (line 341) | set hovered(x)
method expandedChildrenLimit (line 358) | get expandedChildrenLimit()
method expandedChildrenLimit (line 363) | set expandedChildrenLimit(x)
method expandedChildCount (line 373) | get expandedChildCount()
function setTooltip (line 403) | function setTooltip(properties)
function updateChildrenOfNode (line 513) | function updateChildrenOfNode(node)
function handlerFunction (line 767) | function handlerFunction(nodeId, breakType)
function removeZeroWidthSpaceRecursive (line 856) | function removeZeroWidthSpaceRecursive(node)
function keyupListener (line 915) | function keyupListener(event)
function editingComitted (line 921) | function editingComitted(element, newTagName)
function editingCancelled (line 927) | function editingCancelled()
function commit (line 967) | function commit()
function dispose (line 973) | function dispose()
function moveToNextAttributeIfNeeded (line 1043) | function moveToNextAttributeIfNeeded()
function regenerateStyledAttribute (line 1058) | function regenerateStyledAttribute(name, value)
function cancel (line 1110) | function cancel()
function moveToNextAttributeIfNeeded (line 1120) | function moveToNextAttributeIfNeeded()
function changeTagNameCallback (line 1143) | function changeTagNameCallback(nodeId)
function removeNodeCallback (line 1377) | function removeNodeCallback(removedNodeId)
function selectNode (line 1397) | function selectNode(nodeId)
function commitChange (line 1413) | function commitChange(value)
FILE: buildin_modules/weinre/web/client/EventListenersSidebarPane.js
function callback (line 68) | function callback(nodeId, eventListeners) {
function updateWithNodeObject (line 182) | function updateWithNodeObject(nodeObject)
FILE: buildin_modules/weinre/web/client/ExtensionAPI.js
function EventSinkImpl (line 40) | function EventSinkImpl(type, customDispatch)
function InspectorExtensionAPI (line 88) | function InspectorExtensionAPI()
function Resources (line 105) | function Resources()
function callbackWrapper (line 119) | function callbackWrapper(result)
function ResourceImpl (line 137) | function ResourceImpl(id)
function callbackWrapper (line 145) | function callbackWrapper(response)
function Panels (line 153) | function Panels()
function PanelImpl (line 182) | function PanelImpl(id)
function PanelWithSidebarImpl (line 187) | function PanelWithSidebarImpl(id)
function callbackWrapper (line 203) | function callbackWrapper()
function callbackWrapper (line 219) | function callbackWrapper()
function ElementsPanel (line 229) | function ElementsPanel()
function ExtensionPanel (line 236) | function ExtensionPanel(id)
function ExtensionSidebarPaneImpl (line 242) | function ExtensionSidebarPaneImpl(id)
function WatchExpressionSidebarPaneImpl (line 254) | function WatchExpressionSidebarPaneImpl(id)
function WatchExpressionSidebarPane (line 274) | function WatchExpressionSidebarPane(id)
function Audits (line 280) | function Audits()
function AuditCategoryImpl (line 293) | function AuditCategoryImpl(id)
function AuditResultImpl (line 309) | function AuditResultImpl(id)
method Severity (line 352) | get Severity()
function AuditResultNode (line 366) | function AuditResultNode(contents)
function InspectedWindow (line 382) | function InspectedWindow()
function callbackWrapper (line 397) | function callbackWrapper(result)
function ExtensionServerClient (line 408) | function ExtensionServerClient()
function expandURL (line 468) | function expandURL(url)
function bind (line 480) | function bind(func, thisObject)
function populateInterfaceClass (line 486) | function populateInterfaceClass(interface, implementation)
function declareInterfaceClass (line 497) | function declareInterfaceClass(implConstructor)
FILE: buildin_modules/weinre/web/client/ExtensionAuditCategory.js
method id (line 40) | get id()
method displayName (line 45) | get displayName()
method ruleCount (line 50) | get ruleCount()
method complete (line 72) | get complete()
FILE: buildin_modules/weinre/web/client/ExtensionPanel.js
method defaultFocusedElement (line 39) | get defaultFocusedElement()
FILE: buildin_modules/weinre/web/client/ExtensionServer.js
function callback (line 266) | function callback(resultPayload)
function onContentAvailable (line 314) | function onContentAvailable(content, encoded)
function makeStatus (line 445) | function makeStatus(code)
FILE: buildin_modules/weinre/web/client/HeapSnapshot.js
method hasStringName (line 61) | get hasStringName()
method isElement (line 68) | get isElement()
method isHidden (line 73) | get isHidden()
method isInternal (line 78) | get isInternal()
method isShortcut (line 83) | get isShortcut()
method name (line 88) | get name()
method node (line 96) | get node()
method nodeIndex (line 101) | get nodeIndex()
method rawEdges (line 106) | get rawEdges()
method type (line 131) | get type()
method _hasStringName (line 136) | get _hasStringName()
method _name (line 141) | get _name()
method _nameOrIndex (line 146) | get _nameOrIndex()
method index (line 173) | get index()
method index (line 178) | set index(newIndex)
method item (line 183) | get item()
method className (line 202) | get className()
method edges (line 221) | get edges()
method edgesCount (line 226) | get edgesCount()
method id (line 231) | get id()
method instancesCount (line 236) | get instancesCount()
method isHidden (line 241) | get isHidden()
method isRoot (line 246) | get isRoot()
method name (line 251) | get name()
method rawEdges (line 256) | get rawEdges()
method retainedSize (line 262) | get retainedSize()
method retainers (line 267) | get retainers()
method selfSize (line 272) | get selfSize()
method type (line 277) | get type()
method _nodes (line 287) | get _nodes()
method _nextNodeIndex (line 297) | get _nextNodeIndex()
method index (line 324) | get index()
method index (line 329) | set index(newIndex)
method item (line 334) | get item()
method allNodes (line 398) | get allNodes()
method nodesCount (line 403) | get nodesCount()
method rootNode (line 420) | get rootNode()
method totalSize (line 425) | get totalSize()
method idsMap (line 430) | get idsMap()
method isEmpty (line 591) | get isEmpty()
method item (line 605) | get item()
method lastComparator (line 611) | get lastComparator()
method length (line 616) | get length()
function sortByEdgeFieldName (line 655) | function sortByEdgeFieldName(ascending, indexA, indexB)
function sortByNodeField (line 668) | function sortByNodeField(fieldName, ascending, indexA, indexB)
function sortByEdgeAndNode (line 683) | function sortByEdgeAndNode(indexA, indexB) {
function sortByNodeAndEdge (line 690) | function sortByNodeAndEdge(indexA, indexB) {
function sortByNodeAndNode (line 697) | function sortByNodeAndNode(indexA, indexB) {
function sortByNodeField (line 735) | function sortByNodeField(fieldName, ascending, indexA, indexB)
function sortByComparator (line 748) | function sortByComparator(indexA, indexB) {
method _lastEdgeIter (line 823) | get _lastEdgeIter()
method _lastEdge (line 828) | get _lastEdge()
FILE: buildin_modules/weinre/web/client/HeapSnapshotView.js
function profileCallback (line 99) | function profileCallback(profile)
function resetCompleted (line 115) | function resetCompleted()
method statusBarItems (line 123) | get statusBarItems()
method profile (line 128) | get profile()
method profile (line 133) | set profile(profile)
function matchesQuery (line 223) | function matchesQuery(heapSnapshotDataGridNode)
function resetCompleted (line 300) | function resetCompleted() {
method _isShowingAsPercent (line 366) | get _isShowingAsPercent()
function mergeRetainers (line 426) | function mergeRetainers(entry, item)
function profileLoaded (line 441) | function profileLoaded(profile)
method showAsPercent (line 581) | get showAsPercent()
method showAsPercent (line 586) | set showAsPercent(x)
method _hasRetainers (line 650) | get _hasRetainers()
method _parent (line 655) | get _parent()
function appendDiffEntry (line 663) | function appendDiffEntry(baseItem, snapshotItem)
method countPercent (line 747) | get countPercent()
method sizePercent (line 752) | get sizePercent()
method countDeltaPercent (line 757) | get countDeltaPercent()
method sizeDeltaPercent (line 768) | get sizeDeltaPercent()
method data (line 779) | get data()
function appendListEntry (line 882) | function appendListEntry(baseItem, snapshotItem)
method sizePercent (line 944) | get sizePercent()
method sizeDeltaPercent (line 949) | get sizeDeltaPercent()
method buttonTooltip (line 1001) | get buttonTooltip()
method buttonStyle (line 1006) | get buttonStyle()
method welcomeMessage (line 1016) | get welcomeMessage()
FILE: buildin_modules/weinre/web/client/ImageView.js
function onImageLoad (line 75) | function onImageLoad()
FILE: buildin_modules/weinre/web/client/InjectedFakeWorker.js
function onmessageGetter (line 44) | function onmessageGetter()
function onmessageSetter (line 48) | function onmessageSetter(callback)
function FakeWorker (line 59) | function FakeWorker(worker, url)
function onmessageGetter (line 140) | function onmessageGetter()
function onmessageSetter (line 145) | function onmessageSetter(callback)
function URL (line 252) | function URL(url)
function emptyIfNull (line 263) | function emptyIfNull(str)
function normalizePort (line 308) | function normalizePort(schema, port)
function DOMCoreException (line 322) | function DOMCoreException(name, code)
function bind (line 335) | function bind(func, thisObject)
function noop (line 341) | function noop()
FILE: buildin_modules/weinre/web/client/KeyboardShortcut.js
method CtrlOrMeta (line 44) | get CtrlOrMeta()
FILE: buildin_modules/weinre/web/client/MetricsSidebarPane.js
function createBoxPartElement (line 70) | function createBoxPartElement(style, name, side, suffix)
function setEnabledValueCallback (line 218) | function setEnabledValueCallback(context, style)
FILE: buildin_modules/weinre/web/client/NetworkManager.js
function callbackWrapper (line 56) | function callbackWrapper(success, content)
FILE: buildin_modules/weinre/web/client/NetworkPanel.js
method toolbarItemLabel (line 89) | get toolbarItemLabel()
method statusBarItems (line 94) | get statusBarItems()
function createFilterElement (line 345) | function createFilterElement(category, label)
function unselectAll (line 446) | function unselectAll()
method calculator (line 581) | get calculator()
method calculator (line 586) | set calculator(x)
method mainResourceLoadTime (line 630) | set mainResourceLoadTime(x)
method mainResourceDOMContentTime (line 640) | set mainResourceDOMContentTime(x)
method searchableViews (line 667) | get searchableViews()
method resources (line 771) | get resources()
method boundarySpan (line 1116) | get boundarySpan()
method selectable (line 1401) | get selectable()
method selectable (line 1727) | get selectable()
FILE: buildin_modules/weinre/web/client/Object.js
function stopPropagation (line 67) | function stopPropagation()
function preventDefault (line 72) | function preventDefault()
FILE: buildin_modules/weinre/web/client/ObjectPropertiesSection.js
function selectNode (line 209) | function selectNode(nodeId)
function revealElement (line 216) | function revealElement()
FILE: buildin_modules/weinre/web/client/Panel.js
method toolbarItem (line 44) | get toolbarItem()
method name (line 75) | get name()
method defaultFocusedElement (line 113) | get defaultFocusedElement()
function updateMatchesCount (line 162) | function updateMatchesCount()
function updateMatchesCountSoon (line 168) | function updateMatchesCountSoon()
function finishedCallback (line 176) | function finishedCallback(view, searchMatches)
function processChunk (line 204) | function processChunk()
FILE: buildin_modules/weinre/web/client/PanelEnablerView.js
function enableOption (line 48) | function enableOption(text, checked) {
method alwaysEnabled (line 97) | get alwaysEnabled() {
FILE: buildin_modules/weinre/web/client/Placard.js
method title (line 47) | get title()
method title (line 52) | set title(x)
method subtitle (line 60) | get subtitle()
method subtitle (line 65) | set subtitle(x)
method selected (line 73) | get selected()
method selected (line 78) | set selected(x)
FILE: buildin_modules/weinre/web/client/PleaseWaitMessage.js
method instance (line 60) | get instance()
function doAction (line 93) | function doAction()
FILE: buildin_modules/weinre/web/client/Popover.js
function doHide (line 182) | function doHide()
FILE: buildin_modules/weinre/web/client/ProfileDataGridTree.js
method data (line 49) | get data()
method averageTime (line 185) | get averageTime()
method averagePercent (line 190) | get averagePercent()
method selfPercent (line 195) | get selfPercent()
method totalPercent (line 200) | get totalPercent()
method _parent (line 205) | get _parent()
method expanded (line 312) | get expanded()
FILE: buildin_modules/weinre/web/client/ProfileView.js
function profileCallback (line 84) | function profileCallback(profile)
method statusBarItems (line 101) | get statusBarItems()
method profile (line 106) | get profile()
method profile (line 111) | set profile(profile)
method bottomUpProfileDataGridTree (line 116) | get bottomUpProfileDataGridTree()
method topDownProfileDataGridTree (line 123) | get topDownProfileDataGridTree()
method currentTree (line 130) | get currentTree()
method currentTree (line 135) | set currentTree(tree)
method topDownTree (line 141) | get topDownTree()
method bottomUpTree (line 151) | get bottomUpTree()
function matchesQuery (line 263) | function matchesQuery(/*ProfileDataGridNode*/ profileDataGridNode)
method buttonTooltip (line 581) | get buttonTooltip()
method buttonStyle (line 586) | get buttonStyle()
method welcomeMessage (line 601) | get welcomeMessage()
FILE: buildin_modules/weinre/web/client/ProfilesPanel.js
method buttonTooltip (line 37) | get buttonTooltip()
method buttonStyle (line 42) | get buttonStyle()
method buttonCaption (line 47) | get buttonCaption()
method id (line 52) | get id()
method name (line 57) | get name()
method welcomeMessage (line 73) | get welcomeMessage()
method toolbarItemLabel (line 131) | get toolbarItemLabel()
method statusBarItems (line 136) | get statusBarItems()
function doParse (line 451) | function doParse()
method searchableViews (line 524) | get searchableViews()
function populateCallback (line 607) | function populateCallback(profileHeaders) {
method mainTitle (line 749) | get mainTitle()
method mainTitle (line 758) | set mainTitle(x)
method searchMatches (line 764) | set searchMatches(matches)
FILE: buildin_modules/weinre/web/client/PropertiesSidebarPane.js
function callback (line 45) | function callback(prototypes)
FILE: buildin_modules/weinre/web/client/RemoteObject.js
function mycallback (line 51) | function mycallback(object)
method objectId (line 79) | get objectId()
method type (line 84) | get type()
method description (line 89) | get description()
method hasChildren (line 94) | get hasChildren()
function remoteObjectBinder (line 115) | function remoteObjectBinder(properties)
method description (line 157) | get description()
method type (line 170) | get type()
method hasChildren (line 179) | get hasChildren()
function buildProperty (line 191) | function buildProperty(propName)
FILE: buildin_modules/weinre/web/client/Resource.js
method url (line 105) | get url()
method url (line 110) | set url(x)
method documentURL (line 137) | get documentURL()
method documentURL (line 142) | set documentURL(x)
method displayName (line 147) | get displayName()
method displayDomain (line 161) | get displayDomain()
method startTime (line 169) | get startTime()
method startTime (line 174) | set startTime(x)
method responseReceivedTime (line 179) | get responseReceivedTime()
method responseReceivedTime (line 184) | set responseReceivedTime(x)
method endTime (line 189) | get endTime()
method endTime (line 194) | set endTime(x)
method duration (line 207) | get duration()
method latency (line 214) | get latency()
method receiveDuration (line 221) | get receiveDuration()
method resourceSize (line 228) | get resourceSize()
method resourceSize (line 233) | set resourceSize(x)
method transferSize (line 238) | get transferSize()
method expectedContentLength (line 257) | get expectedContentLength()
method expectedContentLength (line 262) | set expectedContentLength(x)
method finished (line 267) | get finished()
method finished (line 272) | set finished(x)
method failed (line 287) | get failed()
method failed (line 292) | set failed(x)
method category (line 297) | get category()
method category (line 302) | set category(x)
method cached (line 307) | get cached()
method cached (line 312) | set cached(x)
method timing (line 319) | get timing()
method timing (line 324) | set timing(x)
method mimeType (line 337) | get mimeType()
method mimeType (line 342) | set mimeType(x)
method type (line 347) | get type()
method type (line 352) | set type(x)
method requestHeaders (line 388) | get requestHeaders()
method requestHeaders (line 393) | set requestHeaders(x)
method sortedRequestHeaders (line 402) | get sortedRequestHeaders()
method requestCookies (line 420) | get requestCookies()
method requestFormData (line 427) | get requestFormData()
method requestFormData (line 432) | set requestFormData(x)
method responseHeaders (line 438) | get responseHeaders()
method responseHeaders (line 443) | set responseHeaders(x)
method sortedResponseHeaders (line 454) | get sortedResponseHeaders()
method responseCookies (line 472) | get responseCookies()
method queryParameters (line 479) | get queryParameters()
method formParameters (line 490) | get formParameters()
function parseNameValue (line 505) | function parseNameValue(pair)
method errors (line 537) | get errors()
method errors (line 542) | set errors(x)
method warnings (line 548) | get warnings()
method warnings (line 553) | set warnings(x)
method content (line 617) | get content()
method contentTimestamp (line 622) | get contentTimestamp()
function finished (line 650) | function finished()
function callback (line 674) | function callback(content)
method baseRevision (line 682) | get baseRevision()
function onResourceContent (line 707) | function onResourceContent()
function onResourceContent (line 735) | function onResourceContent(data)
FILE: buildin_modules/weinre/web/client/ResourceTimingView.js
function addRow (line 77) | function addRow(title, className, start, end, color)
FILE: buildin_modules/weinre/web/client/ResourceTreeModel.js
function callback (line 117) | function callback(resource)
FILE: buildin_modules/weinre/web/client/ResourceView.js
function contentLoaded (line 140) | function contentLoaded(text)
FILE: buildin_modules/weinre/web/client/ResourcesPanel.js
method toolbarItemLabel (line 80) | get toolbarItemLabel()
method statusBarItems (line 85) | get statusBarItems()
function callback (line 371) | function callback(baseContent)
function tableNamesCallback (line 514) | function tableNamesCallback(tableNames)
function comparator (line 580) | function comparator(dataGridNode1, dataGridNode2)
method searchableViews (line 653) | get searchableViews()
function isAncestor (line 692) | function isAncestor(ancestor, object)
function getParent (line 698) | function getParent(object)
function callback (line 714) | function callback(resourceTreeElement)
function callback (line 723) | function callback(resourceTreeElement)
method titleText (line 814) | get titleText()
method titleText (line 819) | set titleText(titleText)
method itemURL (line 848) | get itemURL()
method itemURL (line 886) | get itemURL()
method displayName (line 910) | get displayName()
method hovered (line 936) | set hovered(hovered)
method itemURL (line 959) | get itemURL()
method itemURL (line 1087) | get itemURL()
function tableNamesCallback (line 1109) | function tableNamesCallback(tableNames)
method itemURL (line 1129) | get itemURL()
method itemURL (line 1149) | get itemURL()
method itemURL (line 1169) | get itemURL()
method itemURL (line 1189) | get itemURL()
FILE: buildin_modules/weinre/web/client/ScopeChainSidebarPane.js
method propertyIdentifier (line 129) | get propertyIdentifier()
method propertyPath (line 138) | get propertyPath()
FILE: buildin_modules/weinre/web/client/Script.js
method startingLine (line 63) | get startingLine()
method linesCount (line 68) | get linesCount()
function extractSourceLine (line 79) | function extractSourceLine()
function didRequestSource (line 90) | function didRequestSource()
method source (line 98) | get source()
method source (line 105) | set source(source)
function didGetScriptSource (line 118) | function didGetScriptSource(source)
FILE: buildin_modules/weinre/web/client/ScriptFormatter.js
function didFormatChunks (line 76) | function didFormatChunks()
function addChunk (line 98) | function addChunk(start, end, isScript)
function didFormat (line 133) | function didFormat(formattedSource, mapping)
FILE: buildin_modules/weinre/web/client/ScriptFormatterWorker.js
function beautify (line 41) | function beautify(source)
function buildMapping (line 53) | function buildMapping(source, formattedSource)
function loadModule (line 72) | function loadModule(src)
function require (line 83) | function require()
FILE: buildin_modules/weinre/web/client/ScriptsPanel.js
method toolbarItemLabel (line 202) | get toolbarItemLabel()
method statusBarItems (line 207) | get statusBarItems()
method defaultFocusedElement (line 212) | get defaultFocusedElement()
method paused (line 217) | get paused()
method breakpointsActivated (line 238) | get breakpointsActivated()
function updatingCallbackWrapper (line 357) | function updatingCallbackWrapper(result)
method visibleView (line 440) | get visibleView()
method visibleView (line 445) | set visibleView(x)
function optionCompare (line 619) | function optionCompare(a, b)
function callback (line 738) | function callback(pauseOnExceptionsState)
function finishedCallback (line 999) | function finishedCallback(view, searchMatches)
function didRequestSource (line 1065) | function didRequestSource(source)
FILE: buildin_modules/weinre/web/client/Section.js
method title (line 57) | get title()
method title (line 62) | set title(x)
method subtitle (line 75) | get subtitle()
method subtitle (line 80) | set subtitle(x)
method subtitleAsTextForTest (line 88) | get subtitleAsTextForTest()
method expanded (line 100) | get expanded()
method expanded (line 105) | set expanded(x)
method populated (line 113) | get populated()
method populated (line 118) | set populated(x)
method nextSibling (line 127) | get nextSibling()
method previousSibling (line 137) | get previousSibling()
FILE: buildin_modules/weinre/web/client/Settings.js
method projectId (line 110) | get projectId()
FILE: buildin_modules/weinre/web/client/ShortcutsHelp.js
function compareSections (line 62) | function compareSections(a, b)
function renderLabel (line 148) | function renderLabel(label)
method _height (line 155) | get _height()
FILE: buildin_modules/weinre/web/client/ShowMoreDataGridNode.js
function populate (line 33) | function populate(count)
FILE: buildin_modules/weinre/web/client/SidebarPane.js
method title (line 52) | get title()
method title (line 57) | set title(x)
method growbarVisible (line 65) | get growbarVisible()
method growbarVisible (line 70) | set growbarVisible(x)
method expanded (line 88) | get expanded()
method expanded (line 93) | set expanded(x)
FILE: buildin_modules/weinre/web/client/SidebarTreeElement.js
method smallChildren (line 34) | get smallChildren()
method smallChildren (line 39) | set smallChildren(x)
method small (line 100) | get small()
method small (line 105) | set small(x)
method mainTitle (line 117) | get mainTitle()
method mainTitle (line 122) | set mainTitle(x)
method subtitle (line 128) | get subtitle()
method subtitle (line 133) | set subtitle(x)
method bubbleText (line 139) | get bubbleText()
method bubbleText (line 144) | set bubbleText(x)
FILE: buildin_modules/weinre/web/client/SourceFrame.js
method textModel (line 141) | get textModel()
method scrollTop (line 146) | get scrollTop()
method scrollTop (line 151) | set scrollTop(scrollTop)
function doFindSearchMatches (line 256) | function doFindSearchMatches(query)
function addDecorations (line 391) | function addDecorations(textViewer, lines, className)
function removeDecorations (line 403) | function removeDecorations(textViewer, lines, className)
function addConditionalBreakpoint (line 558) | function addConditionalBreakpoint()
function removeBreakpoint (line 572) | function removeBreakpoint()
function editBreakpointCondition (line 577) | function editBreakpointCondition()
function setBreakpointEnabled (line 587) | function setBreakpointEnabled(enabled)
function doHide (line 636) | function doHide()
function killHidePopupTimer (line 722) | function killHidePopupTimer()
function showObjectPopup (line 734) | function showObjectPopup(result)
function evaluateCallback (line 773) | function evaluateCallback(result)
function finishEditing (line 789) | function finishEditing(committed, element, newText)
function didFormat (line 856) | function didFormat(formattedContent)
function didEditLine (line 887) | function didEditLine(newContent)
FILE: buildin_modules/weinre/web/client/SourceFrameContent.js
method text (line 39) | get text()
method scriptRanges (line 44) | get scriptRanges()
FILE: buildin_modules/weinre/web/client/SourceHTMLTokenizer.js
method line (line 79) | set line(line) {
FILE: buildin_modules/weinre/web/client/SourceTokenizer.js
method line (line 37) | set line(line) {
method condition (line 41) | set condition(condition)
method condition (line 46) | get condition()
method subTokenizer (line 51) | get subTokenizer()
FILE: buildin_modules/weinre/web/client/StatusBarButton.js
method disabled (line 65) | get disabled()
method disabled (line 70) | set disabled(x)
method title (line 78) | get title()
method title (line 83) | set title(x)
method state (line 91) | get state()
method state (line 96) | set state(x)
method toggled (line 116) | get toggled()
method toggled (line 123) | set toggled(x)
method visible (line 130) | get visible()
method visible (line 135) | set visible(x)
FILE: buildin_modules/weinre/web/client/StylesSidebarPane.js
function stylesCallback (line 153) | function stylesCallback(styles)
function computedStyleCallback (line 159) | function computedStyleCallback(computedStyle)
function insertInheritedNodeSeparator (line 270) | function insertInheritedNodeSeparator(node)
function showInheritedToggleFunction (line 581) | function showInheritedToggleFunction(event)
function linkifyUncopyable (line 635) | function linkifyUncopyable(url, line)
function removeStyleBox (line 828) | function removeStyleBox(element, event)
function moveToNextIfNeeded (line 912) | function moveToNextIfNeeded() {
function successCallback (line 939) | function successCallback(newRule, doesAffectSelectedNode)
function sorter (line 1013) | function sorter(a, b)
function successCallback (line 1089) | function successCallback(newRule, doesSelectorAffectSelectedNode)
method inherited (line 1139) | get inherited()
method inherited (line 1144) | set inherited(x)
method overloaded (line 1152) | get overloaded()
method overloaded (line 1157) | set overloaded(x)
method disabled (line 1165) | get disabled()
method name (line 1170) | get name()
method priority (line 1183) | get priority()
method value (line 1190) | get value()
method parsedOk (line 1207) | get parsedOk()
function processValue (line 1244) | function processValue(regex, processor, nextProcessor, valueText)
function linkifyURL (line 1265) | function linkifyURL(url)
function processColor (line 1284) | function processColor(text)
function callback (line 1426) | function callback(newStyle)
function shouldCommitValueSemicolon (line 1550) | function shouldCommitValueSemicolon(text, cursorPosition)
function nameValueFinishHandler (line 1566) | function nameValueFinishHandler(context, isEditingName, event)
function pasteHandler (line 1588) | function pasteHandler(context, event)
function moveToNextCallback (line 1792) | function moveToNextCallback(alreadyNew, valueChanged, section)
function callback (line 1871) | function callback(newStyle)
FILE: buildin_modules/weinre/web/client/SummaryBar.js
method calculator (line 50) | get calculator() {
method calculator (line 54) | set calculator(x) {
function drawSwatchSquare (line 99) | function drawSwatchSquare() {
function drawPillShadow (line 186) | function drawPillShadow()
function drawPill (line 227) | function drawPill()
FILE: buildin_modules/weinre/web/client/TestController.js
function invokeMethod (line 65) | function invokeMethod()
FILE: buildin_modules/weinre/web/client/TextEditorHighlighter.js
method mimeType (line 41) | set mimeType(mimeType)
FILE: buildin_modules/weinre/web/client/TextEditorModel.js
method linesCount (line 45) | get linesCount()
method changeListener (line 65) | set changeListener(changeListener)
method linesCount (line 70) | get linesCount()
method replaceTabsWithSpaces (line 100) | set replaceTabsWithSpaces(replaceTabsWithSpaces)
FILE: buildin_modules/weinre/web/client/TextPrompt.js
method text (line 50) | get text()
method text (line 55) | set text(x)
function defaultAction (line 80) | function defaultAction()
FILE: buildin_modules/weinre/web/client/TextViewer.js
method mimeType (line 49) | set mimeType(mimeType)
method readOnly (line 54) | set readOnly(readOnly)
method textModel (line 59) | get textModel()
method scrollTop (line 107) | get scrollTop()
method scrollTop (line 112) | set scrollTop(scrollTop)
method scrollLeft (line 117) | get scrollLeft()
method scrollLeft (line 122) | set scrollLeft(scrollLeft)
method textModel (line 205) | get textModel()
method expanded (line 493) | get expanded()
method expanded (line 498) | set expanded(expanded)
method height (line 542) | get height()
method mimeType (line 593) | set mimeType(mimeType)
method readOnly (line 598) | set readOnly(readOnly)
function finishEditing (line 686) | function finishEditing(committed, e, newContent)
method expanded (line 1206) | get expanded()
method expanded (line 1211) | set expanded(expanded)
method height (line 1256) | get height()
FILE: buildin_modules/weinre/web/client/TimelineGrid.js
method itemsGraphsElement (line 53) | get itemsGraphsElement()
FILE: buildin_modules/weinre/web/client/TimelineOverviewPane.js
function markTimeline (line 137) | function markTimeline(record)
method boundarySpan (line 394) | get boundarySpan()
method graphElement (line 419) | get graphElement()
method dimmed (line 438) | set dimmed(dimmed)
method element (line 504) | get element() {
method visible (line 509) | get visible() {
FILE: buildin_modules/weinre/web/client/TimelinePanel.js
method toolbarItemLabel (line 143) | get toolbarItemLabel()
method statusBarItems (line 148) | get statusBarItems()
method categories (line 153) | get categories()
method defaultFocusedElement (line 165) | get defaultFocusedElement()
method _recordStyles (line 170) | get _recordStyles()
method children (line 917) | get children()
FILE: buildin_modules/weinre/web/client/UglifyJS/parse-js.js
function is_alphanumeric_char (line 203) | function is_alphanumeric_char(ch) {
function is_identifier_char (line 210) | function is_identifier_char(ch) {
function is_digit (line 214) | function is_digit(ch) {
function parse_js_number (line 219) | function parse_js_number(num) {
function JS_Parse_Error (line 229) | function JS_Parse_Error(message, line, col, pos) {
function js_error (line 245) | function js_error(message, line, col, pos) {
function is_token (line 249) | function is_token(token, type, val) {
function tokenizer (line 255) | function tokenizer($TEXT) {
function NodeWithToken (line 607) | function NodeWithToken(str, start, end) {
function parse (line 615) | function parse($TEXT, strict_mode, embed_tokens) {
function curry (line 1193) | function curry(f) {
function prog1 (line 1198) | function prog1(ret) {
function array_to_hash (line 1206) | function array_to_hash(a) {
function slice (line 1213) | function slice(a, start) {
function characters (line 1217) | function characters(str) {
function member (line 1221) | function member(name, array) {
function HOP (line 1228) | function HOP(obj, prop) {
FILE: buildin_modules/weinre/web/client/UglifyJS/process.js
function ast_walker (line 70) | function ast_walker(ast) {
function Scope (line 253) | function Scope(parent) {
function ast_add_scope (line 358) | function ast_add_scope(ast) {
function ast_mangle (line 460) | function ast_mangle(ast, do_toplevel) {
function best_of (line 547) | function best_of(ast1, ast2) {
function last_stat (line 551) | function last_stat(b) {
function aborts (line 557) | function aborts(t) {
function boolean_expr (line 565) | function boolean_expr(expr) {
function make_conditional (line 590) | function make_conditional(c, t, e) {
function empty (line 598) | function empty(b) {
function ast_squeeze (line 602) | function ast_squeeze(ast, options) {
function make_string (line 942) | function make_string(str) {
function gen_code (line 964) | function gen_code(ast, beautify) {
function split_lines (line 1394) | function split_lines(code, max_line_length) {
function repeat_string (line 1439) | function repeat_string(str, i) {
function defaults (line 1448) | function defaults(args, defs) {
function is_identifier (line 1458) | function is_identifier(name) {
function HOP (line 1466) | function HOP(obj, prop) {
function AtTop (line 1485) | function AtTop(val) { this.v = val }
FILE: buildin_modules/weinre/web/client/View.js
method visible (line 33) | get visible()
method visible (line 38) | set visible(x)
FILE: buildin_modules/weinre/web/client/WatchExpressionsSidebarPane.js
function appendResult (line 93) | function appendResult(expression, watchIndex, result)
FILE: buildin_modules/weinre/web/client/inspector.js
method platform (line 56) | get platform()
method platformFlavor (line 64) | get platformFlavor()
method port (line 99) | get port()
method previousFocusElement (line 107) | get previousFocusElement()
method currentFocusElement (line 112) | get currentFocusElement()
method currentFocusElement (line 117) | set currentFocusElement(x)
method currentPanel (line 147) | get currentPanel()
method currentPanel (line 152) | set currentPanel(x)
function breakpointAdded (line 197) | function breakpointAdded(event)
function breakpointAdded (line 208) | function breakpointAdded(event)
method attached (line 245) | get attached()
method attached (line 250) | set attached(x)
method errors (line 275) | get errors()
method errors (line 280) | set errors(x)
method warnings (line 290) | get warnings()
method warnings (line 295) | set warnings(x)
method networkResources (line 393) | get networkResources()
function onPopulateScriptObjects (line 554) | function onPopulateScriptObjects()
function propertyNamesCallback (line 570) | function propertyNamesCallback(names)
function delayDispatch (line 611) | function delayDispatch()
function followLink (line 683) | function followLink()
function cubicInOut (line 924) | function cubicInOut(t, b, c, d)
function animateLoop (line 957) | function animateLoop()
function forceComplete (line 993) | function forceComplete()
function cancel (line 1001) | function cancel()
function isLogAvailable (line 1207) | function isLogAvailable()
function flushQueue (line 1213) | function flushQueue()
function flushQueueIfAvailable (line 1227) | function flushQueueIfAvailable()
function logMessage (line 1239) | function logMessage(message)
function callback (line 1473) | function callback(resource)
function blurEventListener (line 1747) | function blurEventListener() {
function getContent (line 1751) | function getContent(element) {
function cleanUpAfterEditing (line 1758) | function cleanUpAfterEditing() {
function editingCancelled (line 1778) | function editingCancelled() {
function editingCommitted (line 1790) | function editingCommitted() {
function defaultFinishHandler (line 1797) | function defaultFinishHandler(event)
function handleEditingResult (line 1810) | function handleEditingResult(result, event)
function pasteEventListener (line 1827) | function pasteEventListener(event)
function keyDownEventListener (line 1833) | function keyDownEventListener(event)
FILE: buildin_modules/weinre/web/client/treeoutline.js
function TreeOutline (line 29) | function TreeOutline(listNode)
function TreeElement (line 443) | function TreeElement(title, representedObject, hasChildren)
method listItemElement (line 471) | get listItemElement() {
method childrenListElement (line 475) | get childrenListElement() {
method title (line 479) | get title() {
method title (line 483) | set title(x) {
method titleHTML (line 488) | get titleHTML() {
method titleHTML (line 492) | set titleHTML(x) {
method tooltip (line 497) | get tooltip() {
method tooltip (line 501) | set tooltip(x) {
method hasChildren (line 507) | get hasChildren() {
method hasChildren (line 511) | set hasChildren(x) {
method hidden (line 528) | get hidden() {
method hidden (line 532) | set hidden(x) {
method shouldRefreshChildren (line 551) | get shouldRefreshChildren() {
method shouldRefreshChildren (line 555) | set shouldRefreshChildren(x) {
FILE: buildin_modules/weinre/web/client/utilities.js
function bound (line 36) | function bound()
function isNodeWhitespace (line 478) | function isNodeWhitespace()
function nodeDisplayName (line 487) | function nodeDisplayName()
function isAncestorNode (line 561) | function isAncestorNode(ancestor, node)
function isDescendantNode (line 575) | function isDescendantNode(descendant)
function traverseNextNode (line 580) | function traverseNextNode(stayWithin)
function traversePreviousNode (line 605) | function traversePreviousNode(stayWithin)
function onlyTextChild (line 619) | function onlyTextChild()
function appropriateSelectorForNode (line 632) | function appropriateSelectorForNode(node, justSelector)
function getDocumentForNode (line 657) | function getDocumentForNode(node)
function parentNode (line 662) | function parentNode(node)
function insertionIndexForObjectInListSortedByFunction (line 825) | function insertionIndexForObjectInListSortedByFunction(anObject, aList, ...
function addStringToken (line 862) | function addStringToken(str)
function addSpecifierToken (line 867) | function addSpecifierToken(specifier, precision, substitutionIndex)
function prettyFunctionName (line 956) | function prettyFunctionName()
function warn (line 961) | function warn(msg)
function error (line 966) | function error(msg)
function isEnterKey (line 1018) | function isEnterKey(event) {
function highlightSearchResult (line 1024) | function highlightSearchResult(element, offset, length)
function createSearchRegex (line 1068) | function createSearchRegex(query)
function offerFileForDownload (line 1080) | function offerFileForDownload(contents)
FILE: buildin_modules/weinre/web/client/weinre/hacks.js
function fixToolbarItem (line 32) | function fixToolbarItem() {
function copyProperties (line 55) | function copyProperties(a, b) {
function findProtoOwner (line 69) | function findProtoOwner(root, proto, depth){
FILE: buildin_modules/weinre/web/demo/weinre-demo-strict.js
function onLoad (line 38) | function onLoad() {
function startStuff (line 70) | function startStuff() {
function stopStuff (line 79) | function stopStuff() {
function intervalStuff (line 84) | function intervalStuff() {
function sqlSuccess (line 117) | function sqlSuccess(tx, resultSet) {
function sqlError (line 122) | function sqlError(tx, error) {
function addClick (line 129) | function addClick(tx) {
function clearDatabase (line 135) | function clearDatabase(tx, resultSet) {
function createDatabase (line 141) | function createDatabase(tx) {
function createDatabase_other (line 149) | function createDatabase_other(tx) {
function openTheDatabase (line 157) | function openTheDatabase() {
function openTheOtherDatabase (line 165) | function openTheOtherDatabase() {
function output (line 175) | function output(string) {
function logXhr (line 182) | function logXhr(xhr) {
FILE: buildin_modules/weinre/web/demo/weinre-demo.js
function onLoad (line 38) | function onLoad() {
function startStuff (line 70) | function startStuff() {
function stopStuff (line 83) | function stopStuff() {
function intervalStuff (line 89) | function intervalStuff() {
function sqlSuccess (line 122) | function sqlSuccess(tx, resultSet) {
function sqlError (line 127) | function sqlError(tx, error) {
function addClick (line 134) | function addClick(tx) {
function clearDatabase (line 140) | function clearDatabase(tx, resultSet) {
function createDatabase (line 146) | function createDatabase(tx) {
function createDatabase_other (line 154) | function createDatabase_other(tx) {
function openTheDatabase (line 162) | function openTheDatabase() {
function openTheOtherDatabase (line 170) | function openTheOtherDatabase() {
function output (line 180) | function output(string) {
function logXhr (line 187) | function logXhr(xhr) {
FILE: buildin_modules/weinre/web/doc/scripts/main.js
function main (line 21) | function main() {
function addClickToExpandImageHandlers (line 26) | function addClickToExpandImageHandlers() {
function clickToExpand (line 42) | function clickToExpand(event) {
function hasClass (line 64) | function hasClass(element, className) {
function addClass (line 73) | function addClass(element, className) {
function removeClass (line 80) | function removeClass(element, className) {
FILE: buildin_modules/weinre/web/index.js
function doReplacements (line 26) | function doReplacements() {
function buildHttpURL (line 54) | function buildHttpURL(uri) {
function targetBookmarkletFunction (line 78) | function targetBookmarkletFunction(e){
function getTargetBookmarklet (line 84) | function getTargetBookmarklet() {
function replaceURL (line 95) | function replaceURL(id, url, linkText) {
function replaceText (line 101) | function replaceText(id, text) {
FILE: buildin_modules/weinre/web/interfaces/interfaces.js
function onLoad (line 47) | function onLoad() {
function setUpShowCheckBoxes (line 60) | function setUpShowCheckBoxes() {
function setUpShowCheckBox (line 67) | function setUpShowCheckBox(element, key) {
function el_showCheckBoxClicked (line 81) | function el_showCheckBoxClicked(event) {
function reapplyDisplayStyles (line 90) | function reapplyDisplayStyles() {
function reapplyDisplayStyle (line 97) | function reapplyDisplayStyle(className, value) {
function populateInterfacesList (line 105) | function populateInterfacesList(intfs) {
function el_interfaceClicked (line 134) | function el_interfaceClicked(event) {
function showInterface (line 141) | function showInterface(interfaceName) {
function showInterfaceIdl (line 160) | function showInterfaceIdl(intf, html) {
function showInterfaceIdlMethod (line 179) | function showInterfaceIdlMethod(method, html) {
function getIdlParameterList (line 190) | function getIdlParameterList(parameters) {
function getIdlType (line 209) | function getIdlType(type) {
function getJavaType (line 237) | function getJavaType(type) {
function showInterfaceIdlAttribute (line 261) | function showInterfaceIdlAttribute(attribute, html) {
function showInterfaceJavaScript (line 271) | function showInterfaceJavaScript(intf, html) {
function showInterfaceJavaScriptMethod (line 288) | function showInterfaceJavaScriptMethod(intf, method, html) {
function getJavaScriptParameterList (line 300) | function getJavaScriptParameterList(parameters, returnType) {
function getJavaScriptParameterListSimple (line 319) | function getJavaScriptParameterListSimple(parameters, returnType) {
function getJavaScriptCallbackParameterListSimple (line 332) | function getJavaScriptCallbackParameterListSimple(parameters) {
function showInterfaceJava (line 344) | function showInterfaceJava(intf, html) {
function showInterfaceJavaMethod (line 355) | function showInterfaceJavaMethod(intf, method, html) {
function getJavaParameterList (line 371) | function getJavaParameterList(parameters, returnType) {
function getJavaParameterListSimple (line 390) | function getJavaParameterListSimple(parameters, returnType) {
function getJavaCallbackParameterListSimple (line 405) | function getJavaCallbackParameterListSimple(parameters) {
function toArray (line 421) | function toArray(arrayLike) {
function exBreak (line 429) | function exBreak() {
function allowExBreak (line 434) | function allowExBreak(func) {
FILE: buildin_modules/weinre/web/modjewel.js
function get_require (line 69) | function get_require(currentModule) {
function hop (line 148) | function hop(object, name) {
function create_module (line 155) | function create_module(id) {
function require_reset (line 168) | function require_reset() {
function require_define (line 190) | function require_define(moduleId, prereqs, factory) {
function getModulePath (line 233) | function getModulePath(module) {
function normalize (line 244) | function normalize(module, file) {
function error (line 276) | function error(message) {
function modjewel_getLoadedModuleIds (line 283) | function modjewel_getLoadedModuleIds() {
function modjewel_getPreloadedModuleIds (line 296) | function modjewel_getPreloadedModuleIds() {
function modjewel_getModule (line 309) | function modjewel_getModule(moduleId) {
function modjewel_getModuleIdsRequired (line 318) | function modjewel_getModuleIdsRequired(moduleId) {
function modjewel_warnOnRecursiveRequire (line 329) | function modjewel_warnOnRecursiveRequire(value) {
function modjewel_module (line 337) | function modjewel_module(require, exports, module) {
function log (line 351) | function log(message) {
FILE: buildin_modules/weinre/web/target/target-script-min.js
function get_require (line 48) | function get_require(currentModule) {
function hop (line 105) | function hop(object, name) {
function create_module (line 109) | function create_module(id) {
function require_reset (line 119) | function require_reset() {
function require_define (line 135) | function require_define(moduleId, prereqs, factory) {
function getModulePath (line 167) | function getModulePath(module) {
function normalize (line 173) | function normalize(module, file) {
function error (line 190) | function error(message) {
function modjewel_getLoadedModuleIds (line 194) | function modjewel_getLoadedModuleIds() {
function modjewel_getPreloadedModuleIds (line 202) | function modjewel_getPreloadedModuleIds() {
function modjewel_getModule (line 210) | function modjewel_getModule(moduleId) {
function modjewel_getModuleIdsRequired (line 215) | function modjewel_getModuleIdsRequired(moduleId) {
function modjewel_warnOnRecursiveRequire (line 221) | function modjewel_warnOnRecursiveRequire(value) {
function modjewel_module (line 226) | function modjewel_module(require, exports, module) {
function log (line 237) | function log(message) {
function Binding (line 252) | function Binding(receiver, method) {
function Callback (line 281) | function Callback() {
function Debug (line 348) | function Debug() {
function EventListeners (line 403) | function EventListeners() {
function Ex (line 475) | function Ex(args, message) {
function HookLib (line 512) | function HookLib() {}
function HookSite (line 552) | function HookSite(object, property) {
function IDGenerator (line 662) | function IDGenerator() {}
function IDLTools (line 701) | function IDLTools() {
function MessageDispatcher (line 845) | function MessageDispatcher(url, id) {
function MethodNamer (line 1021) | function MethodNamer() {}
function StackTrace (line 1059) | function StackTrace(args) {
function WebSocketXhr (line 1131) | function WebSocketXhr(url, id) {
function Weinre (line 1353) | function Weinre() {
function ConsoleLogger (line 1396) | function ConsoleLogger() {}
function CheckForProblems (line 1463) | function CheckForProblems() {}
function Console (line 1528) | function Console() {}
function CSSStore (line 1652) | function CSSStore() {
function ElementHighlighter (line 2015) | function ElementHighlighter() {
function ctor (line 2103) | function ctor() {
function ElementHighlighterDivs2 (line 2122) | function ElementHighlighterDivs2() {
function HookSites (line 2188) | function HookSites() {}
function bind (line 2220) | function bind(thisObject, memberFunction) {
function CommandLineAPI (line 2661) | function CommandLineAPI(commandLineAPIImpl, callFrame) {
function CommandLineAPIImpl (line 2692) | function CommandLineAPIImpl() {}
function InjectedScriptHostImpl (line 2806) | function InjectedScriptHostImpl() {}
function NetworkRequest (line 2868) | function NetworkRequest(xhr, id, method, url, stackTrace) {
function NodeStore (line 3055) | function NodeStore() {
function SqlStepper (line 3283) | function SqlStepper(steps) {
function Target (line 3390) | function Target() {}
function Timeline (line 3614) | function Timeline() {}
function WeinreExtraClientCommandsImpl (line 3961) | function WeinreExtraClientCommandsImpl() {}
function WeinreTargetEventsImpl (line 3984) | function WeinreTargetEventsImpl() {}
function WiConsoleImpl (line 4018) | function WiConsoleImpl() {
function WiCSSImpl (line 4052) | function WiCSSImpl() {
function WiDatabaseImpl (line 4170) | function WiDatabaseImpl() {
function WiDOMImpl (line 4322) | function WiDOMImpl() {}
function WiDOMStorageImpl (line 4504) | function WiDOMStorageImpl() {}
function WiInspectorImpl (line 4664) | function WiInspectorImpl() {}
function WiRuntimeImpl (line 4715) | function WiRuntimeImpl() {}
FILE: buildin_modules/weinre/web/weinre/client/Client.amd.js
function Client (line 31) | function Client() {}
FILE: buildin_modules/weinre/web/weinre/client/ConnectorList.amd.js
function ConnectorList (line 7) | function ConnectorList(title) {
FILE: buildin_modules/weinre/web/weinre/client/ExtensionRegistryImpl.amd.js
function ExtensionRegistryImpl (line 13) | function ExtensionRegistryImpl() {}
FILE: buildin_modules/weinre/web/weinre/client/InspectorBackendImpl.amd.js
function InspectorBackendImpl (line 13) | function InspectorBackendImpl() {
FILE: buildin_modules/weinre/web/weinre/client/InspectorFrontendHostImpl.amd.js
function InspectorFrontendHostImpl (line 11) | function InspectorFrontendHostImpl() {
FILE: buildin_modules/weinre/web/weinre/client/RemotePanel.amd.js
function ctor (line 4) | function ctor() { this.constructor = child; }
function RemotePanel (line 43) | function RemotePanel() {
function TargetList (line 202) | function TargetList() {
function ClientList (line 246) | function ClientList() {
FILE: buildin_modules/weinre/web/weinre/client/WeinreClientEventsImpl.amd.js
function WeinreClientEventsImpl (line 17) | function WeinreClientEventsImpl(client) {
FILE: buildin_modules/weinre/web/weinre/client/WeinreExtraTargetEventsImpl.amd.js
function WeinreExtraTargetEventsImpl (line 5) | function WeinreExtraTargetEventsImpl() {}
FILE: buildin_modules/weinre/web/weinre/common/Binding.amd.js
function Binding (line 7) | function Binding(receiver, method) {
FILE: buildin_modules/weinre/web/weinre/common/Callback.amd.js
function Callback (line 13) | function Callback() {
FILE: buildin_modules/weinre/web/weinre/common/Debug.amd.js
function Debug (line 5) | function Debug() {
FILE: buildin_modules/weinre/web/weinre/common/EventListeners.amd.js
function EventListeners (line 9) | function EventListeners() {
FILE: buildin_modules/weinre/web/weinre/common/Ex.amd.js
function Ex (line 18) | function Ex(args, message) {
FILE: buildin_modules/weinre/web/weinre/common/HookLib.amd.js
function HookLib (line 11) | function HookLib() {}
function HookSite (line 58) | function HookSite(object, property) {
FILE: buildin_modules/weinre/web/weinre/common/IDGenerator.amd.js
function IDGenerator (line 9) | function IDGenerator() {}
FILE: buildin_modules/weinre/web/weinre/common/IDLTools.amd.js
function IDLTools (line 11) | function IDLTools() {
FILE: buildin_modules/weinre/web/weinre/common/MessageDispatcher.amd.js
function MessageDispatcher (line 22) | function MessageDispatcher(url, id) {
FILE: buildin_modules/weinre/web/weinre/common/MethodNamer.amd.js
function MethodNamer (line 6) | function MethodNamer() {}
FILE: buildin_modules/weinre/web/weinre/common/StackTrace.amd.js
function StackTrace (line 5) | function StackTrace(args) {
FILE: buildin_modules/weinre/web/weinre/common/WebSocketXhr.amd.js
function WebSocketXhr (line 21) | function WebSocketXhr(url, id) {
FILE: buildin_modules/weinre/web/weinre/common/Weinre.amd.js
function Weinre (line 17) | function Weinre() {
function ConsoleLogger (line 71) | function ConsoleLogger() {}
FILE: buildin_modules/weinre/web/weinre/target/CSSStore.amd.js
function CSSStore (line 11) | function CSSStore() {
FILE: buildin_modules/weinre/web/weinre/target/CheckForProblems.amd.js
function CheckForProblems (line 5) | function CheckForProblems() {}
FILE: buildin_modules/weinre/web/weinre/target/Console.amd.js
function Console (line 44) | function Console() {}
FILE: buildin_modules/weinre/web/weinre/target/ElementHighlighter.amd.js
function ElementHighlighter (line 18) | function ElementHighlighter() {
FILE: buildin_modules/weinre/web/weinre/target/ElementHighlighterDivs2.amd.js
function ctor (line 4) | function ctor() { this.constructor = child; }
function ElementHighlighterDivs2 (line 25) | function ElementHighlighterDivs2() {
FILE: buildin_modules/weinre/web/weinre/target/HookSites.amd.js
function HookSites (line 7) | function HookSites() {}
FILE: buildin_modules/weinre/web/weinre/target/InjectedScript.js
function bind (line 32) | function bind(thisObject, memberFunction)
function CommandLineAPI (line 601) | function CommandLineAPI(commandLineAPIImpl, callFrame)
function CommandLineAPIImpl (line 642) | function CommandLineAPIImpl()
FILE: buildin_modules/weinre/web/weinre/target/InjectedScriptHostImpl.amd.js
function InjectedScriptHostImpl (line 7) | function InjectedScriptHostImpl() {}
FILE: buildin_modules/weinre/web/weinre/target/NetworkRequest.amd.js
function NetworkRequest (line 23) | function NetworkRequest(xhr, id, method, url, stackTrace) {
FILE: buildin_modules/weinre/web/weinre/target/NodeStore.amd.js
function NodeStore (line 11) | function NodeStore() {
FILE: buildin_modules/weinre/web/weinre/target/SqlStepper.amd.js
function SqlStepper (line 7) | function SqlStepper(steps) {
FILE: buildin_modules/weinre/web/weinre/target/Target.amd.js
function Target (line 49) | function Target() {}
FILE: buildin_modules/weinre/web/weinre/target/Timeline.amd.js
function Timeline (line 47) | function Timeline() {}
FILE: buildin_modules/weinre/web/weinre/target/WeinreExtraClientCommandsImpl.amd.js
function WeinreExtraClientCommandsImpl (line 11) | function WeinreExtraClientCommandsImpl() {}
FILE: buildin_modules/weinre/web/weinre/target/WeinreTargetEventsImpl.amd.js
function WeinreTargetEventsImpl (line 11) | function WeinreTargetEventsImpl() {}
FILE: buildin_modules/weinre/web/weinre/target/WiCSSImpl.amd.js
function WiCSSImpl (line 7) | function WiCSSImpl() {
FILE: buildin_modules/weinre/web/weinre/target/WiConsoleImpl.amd.js
function WiConsoleImpl (line 7) | function WiConsoleImpl() {
FILE: buildin_modules/weinre/web/weinre/target/WiDOMImpl.amd.js
function WiDOMImpl (line 7) | function WiDOMImpl() {}
FILE: buildin_modules/weinre/web/weinre/target/WiDOMStorageImpl.amd.js
function WiDOMStorageImpl (line 9) | function WiDOMStorageImpl() {}
FILE: buildin_modules/weinre/web/weinre/target/WiDatabaseImpl.amd.js
function WiDatabaseImpl (line 17) | function WiDatabaseImpl() {
FILE: buildin_modules/weinre/web/weinre/target/WiInspectorImpl.amd.js
function WiInspectorImpl (line 9) | function WiInspectorImpl() {}
FILE: buildin_modules/weinre/web/weinre/target/WiRuntimeImpl.amd.js
function WiRuntimeImpl (line 7) | function WiRuntimeImpl() {}
FILE: lib/proxy/externalChildProcess.js
function _asyncToGenerator (line 3) | function _asyncToGenerator(fn) { return function () { var gen = fn.apply...
FILE: lib/proxy/spyProxy.js
function chunkReplace (line 179) | function chunkReplace(chunk, injectScriptTag, proxyRes) {
FILE: lib/weinre/weinreDelegate.js
function startWeinreServer (line 61) | function startWeinreServer(port) {
FILE: src/config/config.js
constant SPY_WEINRE_DOMAIN (line 1) | const SPY_WEINRE_DOMAIN = 'spyweinrefortest.com';
constant SPY_DEBUGGER_DOMAIN (line 2) | const SPY_DEBUGGER_DOMAIN = 'spydebugger.com';
FILE: src/proxy/spyProxy.js
method createProxy (line 22) | createProxy({
function chunkReplace (line 191) | function chunkReplace(chunk, injectScriptTag, proxyRes) {
FILE: src/weinre/weinreDelegate.js
function startWeinreServer (line 62) | function startWeinreServer (port) {
Condensed preview — 282 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (3,595K chars).
[
{
"path": ".babelrc",
"chars": 75,
"preview": "{\n \"presets\": [\"es2015\"],\n \"plugins\": [\"transform-async-to-generator\"]\n}\n"
},
{
"path": ".github/FUNDING.yml",
"chars": 675,
"preview": "# These are supported funding model platforms\n\ngithub: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [u"
},
{
"path": ".gitignore",
"chars": 536,
"preview": "# Logs\nlogs\n*.log\n\n# Runtime data\npids\n*.pid\n*.seed\n\n# Directory for instrumented libs generated by jscoverage/JSCover\nl"
},
{
"path": ".travis.yml",
"chars": 118,
"preview": "before_install:\n- npm install babel-cli babel-preset-es2015 mocha\nlanguage: node_js\nnode_js:\n - \"6\"\n - \"8\"\n - \"10\"\n"
},
{
"path": "LICENSE",
"chars": 1078,
"preview": "The MIT License (MIT)\n\nCopyright (c) 2016 wuchangming\n\nPermission is hereby granted, free of charge, to any person obtai"
},
{
"path": "README.md",
"chars": 2921,
"preview": "关于spy-debugger\n==========\n一站式页面调试、抓包工具。远程调试任何手机浏览器页面,任何手机移动端webview(如:微信,HybridApp等)。支持HTTP/HTTPS,无需USB连接设备。 \n\n[ under one\n * or more contributor license agreements. See the N"
},
{
"path": "buildin_modules/weinre/build-info.txt",
"chars": 160,
"preview": "weinre build 2.0.0-pre-IXE4AG4O by wuchangming\ngit: 746a5817d014acdda673115e2ee458ec6c9b7673 fix(console): fixed chrome "
},
{
"path": "buildin_modules/weinre/interfaces/WeinreClientCommands.idl",
"chars": 1421,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/interfaces/WeinreClientEvents.idl",
"chars": 1357,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/interfaces/WeinreExtraClientCommands.idl",
"chars": 987,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/interfaces/WeinreExtraTargetEvents.idl",
"chars": 983,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/interfaces/WeinreTargetCommands.idl",
"chars": 1228,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/interfaces/WeinreTargetEvents.idl",
"chars": 1113,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/lib/Channel.js",
"chars": 3446,
"preview": "// Generated by CoffeeScript 1.8.0\nvar AnonymousId, Channel, MessageQueue, channelManager, genJSON, messageHandler, pars"
},
{
"path": "buildin_modules/weinre/lib/HttpChannelHandler.js",
"chars": 4124,
"preview": "// Generated by CoffeeScript 1.8.0\nvar Channel, HttpChannelHandler, channelManager, handleCreate, handleError, handleGet"
},
{
"path": "buildin_modules/weinre/lib/MessageQueue.js",
"chars": 1838,
"preview": "// Generated by CoffeeScript 1.8.0\nvar MessageQueue, utils, _;\n\n_ = require('underscore');\n\nutils = require('./utils');\n"
},
{
"path": "buildin_modules/weinre/lib/channelManager.js",
"chars": 3677,
"preview": "// Generated by CoffeeScript 1.8.0\nvar ChannelManager, WeinreClientEvents, WeinreTargetEvents, channelManager, serviceMa"
},
{
"path": "buildin_modules/weinre/lib/cli.js",
"chars": 3221,
"preview": "// Generated by CoffeeScript 1.8.0\nvar fs, getDotWeinreServerProperties, getTildeReplacement, nopt, optionDefaults, path"
},
{
"path": "buildin_modules/weinre/lib/dumpingHandler.js",
"chars": 2205,
"preview": "// Generated by CoffeeScript 1.8.0\nvar dumpResponse, dumpingHandler, enhance, utils, _;\n\n_ = require('underscore');\n\nuti"
},
{
"path": "buildin_modules/weinre/lib/extensionManager.js",
"chars": 285,
"preview": "// Generated by CoffeeScript 1.8.0\nvar ExtensionManager, utils;\n\nutils = require('./utils');\n\nutils.registerClass(Extens"
},
{
"path": "buildin_modules/weinre/lib/jsonBodyParser.js",
"chars": 808,
"preview": "// Generated by CoffeeScript 1.8.0\nvar jsonBodyParser, parseBodyAsJSON;\n\njsonBodyParser = function() {\n return function"
},
{
"path": "buildin_modules/weinre/lib/messageHandler.js",
"chars": 1620,
"preview": "// Generated by CoffeeScript 1.8.0\nvar MessageHandler, channelManager, serviceManager, utils,\n __slice = [].slice;\n\nuti"
},
{
"path": "buildin_modules/weinre/lib/service/WeinreClientCommands.js",
"chars": 4493,
"preview": "// Generated by CoffeeScript 1.8.0\nvar WeinreClientCommands, WeinreClientEvents, channelManager, extensionManager, servi"
},
{
"path": "buildin_modules/weinre/lib/service/WeinreTargetCommands.js",
"chars": 2888,
"preview": "// Generated by CoffeeScript 1.8.0\nvar WeinreClientEvents, WeinreTargetCommands, WeinreTargetEvents, channelManager, get"
},
{
"path": "buildin_modules/weinre/lib/serviceManager.js",
"chars": 2494,
"preview": "// Generated by CoffeeScript 1.8.0\nvar ServiceManager, Services, fs, getMethodProxy, getServiceInterface, path, utils, _"
},
{
"path": "buildin_modules/weinre/lib/utils.js",
"chars": 4837,
"preview": "// Generated by CoffeeScript 1.8.0\nvar Program, SequenceNumber, SequenceNumberMax, fs, log, path, utils,\n __hasProp = {"
},
{
"path": "buildin_modules/weinre/lib/weinre.js",
"chars": 6096,
"preview": "// Generated by CoffeeScript 1.8.0\nvar HttpChannelHandler, Version, channelManager, checkForDeath, checkHost, deathTimeo"
},
{
"path": "buildin_modules/weinre/package.json",
"chars": 1135,
"preview": "{\n \"name\": \"weinre\",\n \"description\": \"WEb INspector REmote\",\n \"author\": \"apache.org\",\n "
},
{
"path": "buildin_modules/weinre/web/client/ApplicationCacheItemsView.js",
"chars": 11047,
"preview": "/*\n * Copyright (C) 2010 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/AuditCategories.js",
"chars": 4000,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/AuditFormatters.js",
"chars": 3231,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/AuditLauncherView.js",
"chars": 10934,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/AuditResultView.js",
"chars": 4695,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/AuditRules.js",
"chars": 43041,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/AuditsPanel.js",
"chars": 13055,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/BottomUpProfileDataGridTree.js",
"chars": 10254,
"preview": "/*\n * Copyright (C) 2009 280 North Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, wi"
},
{
"path": "buildin_modules/weinre/web/client/Breakpoint.js",
"chars": 2167,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Re"
},
{
"path": "buildin_modules/weinre/web/client/BreakpointManager.js",
"chars": 22391,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/BreakpointsSidebarPane.js",
"chars": 24740,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/CSSCompletions.js",
"chars": 4199,
"preview": "/*\n * Copyright (C) 2010 Nikita Vasilyev. All rights reserved.\n * Copyright (C) 2010 Joseph Pecoraro. All rights reserve"
},
{
"path": "buildin_modules/weinre/web/client/CSSKeywordCompletions.js",
"chars": 17188,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/CSSStyleModel.js",
"chars": 19393,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/CallStackSidebarPane.js",
"chars": 7051,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/Checkbox.js",
"chars": 2341,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/Color.js",
"chars": 22918,
"preview": "/*\n * Copyright (C) 2009 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistribution and"
},
{
"path": "buildin_modules/weinre/web/client/ConsolePanel.js",
"chars": 3653,
"preview": "/*\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistribution and use in source and binary forms, with or without\n * mod"
},
{
"path": "buildin_modules/weinre/web/client/ConsoleView.js",
"chars": 44788,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistributi"
},
{
"path": "buildin_modules/weinre/web/client/ContextMenu.js",
"chars": 3359,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/CookieItemsView.js",
"chars": 7324,
"preview": "/*\n * Copyright (C) 2009 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistribution and"
},
{
"path": "buildin_modules/weinre/web/client/CookieParser.js",
"chars": 7273,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/CookiesTable.js",
"chars": 7609,
"preview": "/*\n * Copyright (C) 2009 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n * Copyright (C) 2010 Go"
},
{
"path": "buildin_modules/weinre/web/client/DOMAgent.js",
"chars": 17505,
"preview": "/*\n * Copyright (C) 2009, 2010 Google Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistributi"
},
{
"path": "buildin_modules/weinre/web/client/DOMStorage.js",
"chars": 3103,
"preview": "/*\n * Copyright (C) 2008 Nokia Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/DOMStorageItemsView.js",
"chars": 5153,
"preview": "/*\n * Copyright (C) 2008 Nokia Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/DOMSyntaxHighlighter.js",
"chars": 3431,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/DataGrid.js",
"chars": 48601,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/Database.js",
"chars": 4449,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms,"
},
{
"path": "buildin_modules/weinre/web/client/DatabaseQueryView.js",
"chars": 7029,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/DatabaseTableView.js",
"chars": 3432,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/DebuggerModel.js",
"chars": 14598,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/DetailedHeapshotView.js",
"chars": 3189,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/Drawer.js",
"chars": 13800,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistributi"
},
{
"path": "buildin_modules/weinre/web/client/ElementsPanel.js",
"chars": 38235,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com>\n"
},
{
"path": "buildin_modules/weinre/web/client/ElementsTreeOutline.js",
"chars": 53669,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com>\n"
},
{
"path": "buildin_modules/weinre/web/client/EventListenersSidebarPane.js",
"chars": 9469,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistribution and"
},
{
"path": "buildin_modules/weinre/web/client/ExtensionAPI.js",
"chars": 15183,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ExtensionAPISchema.json",
"chars": 16888,
"preview": "[\n {\n \"namespace\": \"experimental.webInspector.inspectedWindow\",\n \"description\": \"Provides access to the window be"
},
{
"path": "buildin_modules/weinre/web/client/ExtensionAuditCategory.js",
"chars": 3588,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ExtensionCommon.js",
"chars": 1908,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ExtensionPanel.js",
"chars": 4423,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ExtensionRegistryStub.js",
"chars": 986,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/client/ExtensionServer.js",
"chars": 17049,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/FontView.js",
"chars": 4615,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms,"
},
{
"path": "buildin_modules/weinre/web/client/GoToLineDialog.js",
"chars": 4578,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/HAREntry.js",
"chars": 8019,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/HeapSnapshot.js",
"chars": 27945,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/HeapSnapshotView.js",
"chars": 38172,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/HelpScreen.js",
"chars": 3619,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ImageView.js",
"chars": 5038,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms,"
},
{
"path": "buildin_modules/weinre/web/client/InjectedFakeWorker.js",
"chars": 11749,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/InspectorBackendStub.js",
"chars": 973,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/client/InspectorBackendStub.qrc",
"chars": 135,
"preview": "<!DOCTYPE RCC><RCC version=\"1.0\">\n<qresource prefix=\"/webkit/inspector\">\n <file>InspectorBackendStub.js</file>\n</qres"
},
{
"path": "buildin_modules/weinre/web/client/InspectorFrontendHostStub.js",
"chars": 993,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/client/KeyboardShortcut.js",
"chars": 7026,
"preview": "/*\n * Copyright (C) 2009 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Re"
},
{
"path": "buildin_modules/weinre/web/client/MetricsSidebarPane.js",
"chars": 9760,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/NetworkItemView.js",
"chars": 3677,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/NetworkManager.js",
"chars": 14203,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/NetworkPanel.js",
"chars": 63337,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2008, 2009 Anthony Ricaud <rik@webkit.o"
},
{
"path": "buildin_modules/weinre/web/client/Object.js",
"chars": 3342,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/ObjectPropertiesSection.js",
"chars": 10600,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistribution and "
},
{
"path": "buildin_modules/weinre/web/client/Panel.js",
"chars": 14274,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms,"
},
{
"path": "buildin_modules/weinre/web/client/PanelEnablerView.js",
"chars": 4048,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/Placard.js",
"chars": 2971,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/PleaseWaitMessage.js",
"chars": 4047,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/Popover.js",
"chars": 9890,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ProfileDataGridTree.js",
"chars": 12359,
"preview": "/*\n * Copyright (C) 2009 280 North Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, wi"
},
{
"path": "buildin_modules/weinre/web/client/ProfileView.js",
"chars": 23294,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/ProfilesPanel.js",
"chars": 26961,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/PropertiesSection.js",
"chars": 2235,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * "
},
{
"path": "buildin_modules/weinre/web/client/PropertiesSidebarPane.js",
"chars": 2844,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/RemoteObject.js",
"chars": 6100,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/Resource.js",
"chars": 22358,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms,"
},
{
"path": "buildin_modules/weinre/web/client/ResourceCategory.js",
"chars": 1824,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms,"
},
{
"path": "buildin_modules/weinre/web/client/ResourceCookiesView.js",
"chars": 3302,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ResourceHeadersView.js",
"chars": 12416,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) IBM Corp. 2009 All rights reserved.\n *"
},
{
"path": "buildin_modules/weinre/web/client/ResourceTimingView.js",
"chars": 6525,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ResourceTreeModel.js",
"chars": 7269,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ResourceView.js",
"chars": 6363,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) IBM Corp. 2009 All rights reserved.\n *"
},
{
"path": "buildin_modules/weinre/web/client/ResourcesPanel.js",
"chars": 43784,
"preview": "/*\n * Copyright (C) 2007, 2008, 2010 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redist"
},
{
"path": "buildin_modules/weinre/web/client/ScopeChainSidebarPane.js",
"chars": 6217,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/Script.js",
"chars": 4019,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/ScriptFormatter.js",
"chars": 9439,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ScriptFormatterWorker.js",
"chars": 2941,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ScriptsPanel.js",
"chars": 42067,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/Section.js",
"chars": 4928,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * "
},
{
"path": "buildin_modules/weinre/web/client/Settings.js",
"chars": 5912,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ShortcutsHelp.js",
"chars": 5496,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/ShowMoreDataGridNode.js",
"chars": 3254,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/SidebarPane.js",
"chars": 4189,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/SidebarTreeElement.js",
"chars": 5971,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/SourceCSSTokenizer.js",
"chars": 61212,
"preview": "/* Generated by re2c 0.13.5 on Mon Dec 20 18:44:30 2010 */\n/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n"
},
{
"path": "buildin_modules/weinre/web/client/SourceCSSTokenizer.re2js",
"chars": 16393,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/SourceFrame.js",
"chars": 34487,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/SourceFrameContent.js",
"chars": 4383,
"preview": "/*\n * Copyright (C) 2011 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/SourceHTMLTokenizer.js",
"chars": 31510,
"preview": "/* Generated by re2c 0.13.5 on Fri Jan 28 18:32:27 2011 */\n/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n"
},
{
"path": "buildin_modules/weinre/web/client/SourceHTMLTokenizer.re2js",
"chars": 16173,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/SourceJavaScriptTokenizer.js",
"chars": 99171,
"preview": "/* Generated by re2c 0.13.5 on Thu Feb 25 21:44:55 2010 */\n/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n"
},
{
"path": "buildin_modules/weinre/web/client/SourceJavaScriptTokenizer.re2js",
"chars": 9177,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/SourceTokenizer.js",
"chars": 3357,
"preview": "/* Generated by re2c 0.13.5 on Tue Jan 26 01:16:33 2010 */\n/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n"
},
{
"path": "buildin_modules/weinre/web/client/StatusBarButton.js",
"chars": 4277,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/StylesSidebarPane.js",
"chars": 80488,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Joseph Pecoraro\n *\n * Redistribution and"
},
{
"path": "buildin_modules/weinre/web/client/SummaryBar.js",
"chars": 12287,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2008, 2009 Anthony Ricaud <rik@webkit.o"
},
{
"path": "buildin_modules/weinre/web/client/TabbedPane.js",
"chars": 3199,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/TestController.js",
"chars": 3038,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/TextEditorHighlighter.js",
"chars": 5666,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n * Copyright (C) 2009 Apple Inc. All rights reserved.\n *\n * Re"
},
{
"path": "buildin_modules/weinre/web/client/TextEditorModel.js",
"chars": 9994,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/TextPrompt.js",
"chars": 16938,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/TextViewer.js",
"chars": 43277,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n * Copyright (C) 2010 Apple Inc. All rights reserved.\n *\n * Re"
},
{
"path": "buildin_modules/weinre/web/client/TimelineAgent.js",
"chars": 2232,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/TimelineGrid.js",
"chars": 7204,
"preview": "/*\n * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2008, 2009 Anthony Ricaud <rik@webkit.o"
},
{
"path": "buildin_modules/weinre/web/client/TimelineOverviewPane.js",
"chars": 22701,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/TimelinePanel.js",
"chars": 53795,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/TopDownProfileDataGridTree.js",
"chars": 4198,
"preview": "/*\n * Copyright (C) 2009 280 North Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, wi"
},
{
"path": "buildin_modules/weinre/web/client/UglifyJS/parse-js.js",
"chars": 41895,
"preview": "/***********************************************************************\n\n A JavaScript tokenizer / parser / beautifier"
},
{
"path": "buildin_modules/weinre/web/client/UglifyJS/process.js",
"chars": 65187,
"preview": "/***********************************************************************\n\n A JavaScript tokenizer / parser / beautifier"
},
{
"path": "buildin_modules/weinre/web/client/View.js",
"chars": 2416,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/WatchExpressionsSidebarPane.js",
"chars": 10167,
"preview": "/*\n * Copyright (C) IBM Corp. 2009 All rights reserved.\n *\n * Redistribution and use in source and binary forms, with o"
},
{
"path": "buildin_modules/weinre/web/client/WebKit.qrc",
"chars": 11857,
"preview": "<!DOCTYPE RCC><RCC version=\"1.0\">\n<qresource prefix=\"/webkit/inspector\">\n <file>inspector.html</file>\n <file>Appli"
},
{
"path": "buildin_modules/weinre/web/client/WelcomeView.js",
"chars": 3302,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All Rights Reserved.\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Re"
},
{
"path": "buildin_modules/weinre/web/client/WorkersSidebarPane.js",
"chars": 3961,
"preview": "/*\n * Copyright (C) 2010 Google Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/audits.css",
"chars": 7175,
"preview": "/*\n * Copyright (C) 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Google Inc. All rights reserved.\n *\n * R"
},
{
"path": "buildin_modules/weinre/web/client/goToLineDialog.css",
"chars": 1085,
"preview": ".go-to-line-dialog {\n position: absolute;\n top: 40%;\n left: 40%;\n z-index: 1900;\n\n background-image: -web"
},
{
"path": "buildin_modules/weinre/web/client/heapProfiler.css",
"chars": 3761,
"preview": "/*\n * Copyright (C) 2009 Google Inc. All rights reserved.\n * Copyright (C) 2010 Apple Inc. All rights reserved.\n *\n * Re"
},
{
"path": "buildin_modules/weinre/web/client/helpScreen.css",
"chars": 3079,
"preview": ".help-window-outer {\n position: absolute;\n top: 60px;\n left: 5%;\n width: 90%;\n bottom: 40px;\n z-index:"
},
{
"path": "buildin_modules/weinre/web/client/index.html",
"chars": 14628,
"preview": "<!--\nCopyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.\n\nRedistribution and use in source and binary forms,"
},
{
"path": "buildin_modules/weinre/web/client/inspector.css",
"chars": 103835,
"preview": "/*\n * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2009 Anthony Ricaud <rik@webkit.o"
},
{
"path": "buildin_modules/weinre/web/client/inspector.html",
"chars": 11865,
"preview": "<!--\nCopyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.\n\nRedistribution and use in source and binary forms,"
},
{
"path": "buildin_modules/weinre/web/client/inspector.js",
"chars": 66487,
"preview": "/*\n * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.\n * Copyright (C) 2007 Matt Lilek (pewtermoose@gmai"
},
{
"path": "buildin_modules/weinre/web/client/inspectorSyntaxHighlight.css",
"chars": 3409,
"preview": "/*\n * Copyright (C) 2009 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/networkPanel.css",
"chars": 18858,
"preview": ".network-larger-resources-status-bar-item .glyph {\n -webkit-mask-image: url(Images/largerResourcesButtonGlyph.png);\n}"
},
{
"path": "buildin_modules/weinre/web/client/popover.css",
"chars": 4340,
"preview": ".popover {\n position: absolute;\n -webkit-border-image: url(Images/popoverBackground.png) 25 25 25 25;\n border-w"
},
{
"path": "buildin_modules/weinre/web/client/textViewer.css",
"chars": 4513,
"preview": ".text-editor {\n position: absolute;\n top:0;\n left:0;\n right:0;\n bottom:0;\n white-space: pre;\n overf"
},
{
"path": "buildin_modules/weinre/web/client/treeoutline.js",
"chars": 29735,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/utilities.js",
"chars": 32332,
"preview": "/*\n * Copyright (C) 2007 Apple Inc. All rights reserved.\n *\n * Redistribution and use in source and binary forms, with "
},
{
"path": "buildin_modules/weinre/web/client/web-inspector-API.js",
"chars": 859,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/client/weinre/browser-support-check.js",
"chars": 1474,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/client/weinre/client.css",
"chars": 2280,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/client/weinre/hacks.js",
"chars": 4247,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/demo/split.html",
"chars": 923,
"preview": "<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the N"
},
{
"path": "buildin_modules/weinre/web/demo/weinre-demo-min.html",
"chars": 1629,
"preview": "<!DOCTYPE html>\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreem"
},
{
"path": "buildin_modules/weinre/web/demo/weinre-demo-strict.html",
"chars": 1673,
"preview": "<!DOCTYPE html>\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreem"
},
{
"path": "buildin_modules/weinre/web/demo/weinre-demo-strict.js",
"chars": 5746,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/demo/weinre-demo.css",
"chars": 1088,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/demo/weinre-demo.html",
"chars": 1629,
"preview": "<!DOCTYPE html>\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreem"
},
{
"path": "buildin_modules/weinre/web/demo/weinre-demo.js",
"chars": 5894,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/doc/Building.html",
"chars": 5118,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/ChangeLog.html",
"chars": 20734,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/Home.html",
"chars": 12033,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/Installing.html",
"chars": 7276,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/License.html",
"chars": 4280,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/MultiUser.html",
"chars": 7280,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/Running.html",
"chars": 13830,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/Security.html",
"chars": 5720,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/UserInterface.html",
"chars": 12912,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/build-info.txt",
"chars": 160,
"preview": "weinre build 2.0.0-pre-IXE4AG4O by wuchangming\ngit: 746a5817d014acdda673115e2ee458ec6c9b7673 fix(console): fixed chrome "
},
{
"path": "buildin_modules/weinre/web/doc/css/main.css",
"chars": 5550,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/doc/index.html",
"chars": 12033,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/doc/scripts/main.js",
"chars": 3041,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/index.html",
"chars": 3539,
"preview": "<!doctype html>\n\n<!--\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agree"
},
{
"path": "buildin_modules/weinre/web/index.js",
"chars": 4057,
"preview": "/*\n * Licensed to the Apache Software Foundation (ASF) under one\n * or more contributor license agreements. See the NOT"
},
{
"path": "buildin_modules/weinre/web/interfaces/InjectedScriptHost.json",
"chars": 6648,
"preview": "{\n \"interfaces\": [\n {\n \"extendedAttributes\": {\n \"Conditional\": \"INSPECTOR\"\n }, \n "
},
{
"path": "buildin_modules/weinre/web/interfaces/Inspector.json",
"chars": 115413,
"preview": "{\n \"interfaces\": [\n {\n \"extendedAttributes\": {\n \"Conditional\": \"INSPECTOR\"\n }, \n "
},
{
"path": "buildin_modules/weinre/web/interfaces/InspectorFrontendHost.json",
"chars": 6587,
"preview": "{\n \"interfaces\": [\n {\n \"extendedAttributes\": {\n \"Conditional\": \"INSPECTOR\"\n }, \n "
},
{
"path": "buildin_modules/weinre/web/interfaces/WeinreClientCommands.json",
"chars": 4816,
"preview": "{\n \"interfaces\": [\n {\n \"name\": \"WeinreClientCommands\", \n \"methods\": [\n {\n "
},
{
"path": "buildin_modules/weinre/web/interfaces/WeinreClientEvents.json",
"chars": 4235,
"preview": "{\n \"interfaces\": [\n {\n \"name\": \"WeinreClientEvents\", \n \"methods\": [\n {\n "
}
]
// ... and 82 more files (download for full content)
About this extraction
This page contains the full source code of the wuchangming/spy-debugger GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 282 files (3.3 MB), approximately 869.6k tokens, and a symbol index with 1022 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.
Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.