Replace "Url" in API names with "URL"
This commit is contained in:
parent
8f56387bd9
commit
fbb8e61958
57 changed files with 251 additions and 212 deletions
|
@ -73,7 +73,7 @@ You can also display a web page in an `asar` archive with `BrowserWindow`:
|
|||
```javascript
|
||||
const BrowserWindow = require('electron').BrowserWindow;
|
||||
var win = new BrowserWindow({width: 800, height: 600});
|
||||
win.loadUrl('file:///path/to/example.asar/static/index.html');
|
||||
win.loadURL('file:///path/to/example.asar/static/index.html');
|
||||
```
|
||||
|
||||
### Web API
|
||||
|
|
|
@ -13,7 +13,7 @@ const BrowserWindow = electron.BrowserWindow;
|
|||
var onlineStatusWindow;
|
||||
app.on('ready', function() {
|
||||
onlineStatusWindow = new BrowserWindow({ width: 0, height: 0, show: false });
|
||||
onlineStatusWindow.loadUrl('file://' + __dirname + '/online-status.html');
|
||||
onlineStatusWindow.loadURL('file://' + __dirname + '/online-status.html');
|
||||
});
|
||||
```
|
||||
|
||||
|
@ -54,7 +54,7 @@ const BrowserWindow = electron.BrowserWindow;
|
|||
var onlineStatusWindow;
|
||||
app.on('ready', function() {
|
||||
onlineStatusWindow = new BrowserWindow({ width: 0, height: 0, show: false });
|
||||
onlineStatusWindow.loadUrl('file://' + __dirname + '/online-status.html');
|
||||
onlineStatusWindow.loadURL('file://' + __dirname + '/online-status.html');
|
||||
});
|
||||
|
||||
ipcMain.on('online-status-changed', function(event, status) {
|
||||
|
|
|
@ -105,7 +105,7 @@ app.on('ready', function() {
|
|||
mainWindow = new BrowserWindow({width: 800, height: 600});
|
||||
|
||||
// and load the index.html of the app.
|
||||
mainWindow.loadUrl('file://' + __dirname + '/index.html');
|
||||
mainWindow.loadURL('file://' + __dirname + '/index.html');
|
||||
|
||||
// Open the DevTools.
|
||||
mainWindow.webContents.openDevTools();
|
||||
|
|
|
@ -36,7 +36,7 @@ app.on('ready', function() {
|
|||
'plugins': true
|
||||
}
|
||||
});
|
||||
mainWindow.loadUrl('file://' + __dirname + '/index.html');
|
||||
mainWindow.loadURL('file://' + __dirname + '/index.html');
|
||||
// Something else
|
||||
});
|
||||
```
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue