Merge pull request #1389 from atom/rename-to-electron

Rename to electron
This commit is contained in:
Cheng Zhao 2015-04-17 15:22:07 +08:00
commit cd0aa4a956
76 changed files with 375 additions and 313 deletions

View file

@ -23,14 +23,14 @@ Under most cases you should just do everything in `ready` event.
## Event: ready
Emitted when atom-shell has done everything initialization.
Emitted when Electron has done everything initialization.
## Event: window-all-closed
Emitted when all windows have been closed.
This event is only emitted when the application is not going to quit. If a
user pressed `Cmd + Q`, or the developer called `app.quit()`, atom-shell would
user pressed `Cmd + Q`, or the developer called `app.quit()`, Electron would
first try to close all windows and then emit the `will-quit` event, and in
this case the `window-all-closed` would not be emitted.
@ -155,7 +155,7 @@ used.
Usually the `name` field of `package.json` is a short lowercased name, according
to the spec of npm modules. So usually you should also specify a `productName`
field, which is your application's full capitalized name, and it will be
preferred over `name` by atom-shell.
preferred over `name` by Electron.
## app.resolveProxy(url, callback)

View file

@ -84,7 +84,7 @@ You can also create a window without chrome by using
* `extra-plugin-dirs` Array - Array of paths that would be searched for
plugins. Note that if you want to add a directory under your app, you
should use `__dirname` or `process.resourcesPath` to join the paths to
make them absolute, using relative paths would make atom-shell search
make them absolute, using relative paths would make Electron search
under current working directory.
* `experimental-features` Boolean
* `experimental-canvas-features` Boolean
@ -116,7 +116,7 @@ would cancel the close.
Usually you would want to use the `beforeunload` handler to decide whether the
window should be closed, which will also be called when the window is
reloaded. In atom-shell, returning an empty string or `false` would cancel the
reloaded. In Electron, returning an empty string or `false` would cancel the
close. An example is:
```javascript
@ -124,7 +124,7 @@ window.onbeforeunload = function(e) {
console.log('I do not want to be closed');
// Unlike usual browsers, in which a string should be returned and the user is
// prompted to confirm the page unload. atom-shell gives the power completely
// prompted to confirm the page unload. Electron gives the power completely
// to the developers, return empty string or false would prevent the unloading
// now. You can also use the dialog API to let user confirm it.
return false;
@ -512,7 +512,7 @@ process.
* `printBackground` Boolean - Also prints the background color and image of
the web page, defaults to `false`.
Prints window's web page. When `silent` is set to `false`, atom-shell will pick
Prints window's web page. When `silent` is set to `false`, Electron will pick
up system's default printer and default settings for printing.
Calling `window.print()` in web page is equivalent to call

View file

@ -1,7 +1,7 @@
# Supported Chrome command line switches
Following command lines switches in Chrome browser are also Supported in
atom-shell, you can use [app.commandLine.appendSwitch][append-switch] to append
Electron, you can use [app.commandLine.appendSwitch][append-switch] to append
them in your app's main script before the [ready][ready] event of [app][app]
module is emitted:

View file

@ -15,7 +15,7 @@ crashReporter.start({
## crashReporter.start(options)
* `options` Object
* `productName` String, default: Atom-Shell
* `productName` String, default: Electron
* `companyName` String, default: GitHub, Inc
* `submitUrl` String, default: http://54.249.141.255:1127/post
* URL that crash reports would be sent to as POST
@ -36,14 +36,14 @@ sent or the crash reporter is not started, `null` will be returned.
The crash reporter will send the following data to the `submitUrl` as `POST`:
* `rept` String - e.g. 'atom-shell-crash-service'
* `ver` String - The version of atom-shell
* `rept` String - e.g. 'electron-crash-service'
* `ver` String - The version of Electron
* `platform` String - e.g. 'win32'
* `process_type` String - e.g. 'renderer'
* `ptime` Number
* `_version` String - The version in `package.json`
* `_productName` String - The product name in the crashReporter `options` object
* `prod` String - Name of the underlying product. In this case Atom-Shell
* `prod` String - Name of the underlying product. In this case Electron
* `_companyName` String - The company name in the crashReporter `options` object
* `upload_file_minidump` File - The crashreport as file
* All level one properties of the `extra` object in the crashReporter `options` object

View file

@ -1,7 +1,7 @@
# `File` object
The DOM's File interface provides abstraction around native files, in order to
let users work on native files directly with HTML5 file API, atom-shell has
let users work on native files directly with HTML5 file API, Electron has
added a `path` attribute to `File` interface which exposes the file's real path
on filesystem.

View file

@ -41,7 +41,7 @@ var win = new BrowserWindow({ transparent: true, frame: false });
## Draggable region
By default, the frameless window is non-draggable. Apps need to specify
`-webkit-app-region: drag` in CSS to tell atom-shell which regions are draggable
`-webkit-app-region: drag` in CSS to tell Electron which regions are draggable
(like the OS's standard titlebar), and apps can also use
`-webkit-app-region: no-drag` to exclude the non-draggable area from the
draggable region. Note that only rectangular shape is currently supported.

View file

@ -33,10 +33,10 @@ Another example of creating the application menu with the simple template API:
// main.js
var template = [
{
label: 'Atom Shell',
label: 'Electron',
submenu: [
{
label: 'About Atom Shell',
label: 'About Electron',
selector: 'orderFrontStandardAboutPanel:'
},
{
@ -50,7 +50,7 @@ var template = [
type: 'separator'
},
{
label: 'Hide Atom Shell',
label: 'Hide Electron',
accelerator: 'Command+H',
selector: 'hide:'
},
@ -228,7 +228,7 @@ Linux, and here are some notes on making your app's menu more native-like.
On OS X there are many system defined standard menus, like the `Services` and
`Windows` menus. To make your menu a standard menu, you can just set your menu's
label to one of followings, and atom-shell will recognize them and make them
label to one of followings, and Electron will recognize them and make them
become standard menus:
* `Window`

View file

@ -1,6 +1,6 @@
# NativeImage
In atom-shell for the APIs that take images, you can pass either file paths or
In Electron for the APIs that take images, you can pass either file paths or
`NativeImage` instances. When passing `null`, an empty image will be used.
For example when creating tray or setting window's icon, you can pass image's

View file

@ -1,9 +1,9 @@
# Process object
The `process` object in atom-shell has following differences between the one in
The `process` object in Electron has following differences between the one in
upstream node:
* `process.type` String - Process's type, can be `browser` (i.e. main process) or `renderer`.
* `process.versions['atom-shell']` String - Version of atom-shell.
* `process.versions['electron']` String - Version of Electron.
* `process.versions['chrome']` String - Version of Chromium.
* `process.resourcesPath` String - Path to JavaScript source code.

View file

@ -3,7 +3,7 @@
The `remote` module provides a simple way to do inter-process communication
between the renderer process and the main process.
In atom-shell, only GUI-related modules are available in the renderer process.
In Electron, only GUI-related modules are available in the renderer process.
Without the `remote` module, users who wanted to call a main process API in
the renderer process would have to explicitly send inter-process messages
to the main process. With the `remote` module, users can invoke methods of
@ -35,7 +35,7 @@ corresponding remote object in the renderer process, namely the `win` object.
## Lifetime of remote objects
Atom-shell makes sure that as long as the remote object in the renderer process
Electron makes sure that as long as the remote object in the renderer process
lives (in other words, has not been garbage collected), the corresponding object
in the main process would never be released. When the remote object has been
garbage collected, the corresponding object in the main process would be

View file

@ -1,10 +1,10 @@
# Synopsis
All [node.js's built-in modules](http://nodejs.org/api/) are available in
atom-shell, and third-party node modules are fully supported too (including the
Electron, and third-party node modules are fully supported too (including the
[native modules](../tutorial/using-native-node-modules.md)).
Atom-shell also provides some extra built-in modules for developing native
Electron also provides some extra built-in modules for developing native
desktop applications. Some modules are only available on the main process, some
are only available on the renderer process, and some can be used on both processes.
The basic rule is: if a module is GUI or low-level system related, then it should

View file

@ -1,7 +1,7 @@
# `<webview>` tag
Use the `webview` tag to embed 'guest' content (such as web pages) in your
atom-shell app. The guest content is contained within the `webview` container;
Electron app. The guest content is contained within the `webview` container;
an embedder page within your app controls how the guest content is laid out and
rendered.