Update as upstream
This commit is contained in:
parent
ccd17f060d
commit
b5b6e30c8b
2 changed files with 11 additions and 5 deletions
|
@ -12,7 +12,9 @@ var globalShortcut = require('global-shortcut');
|
||||||
|
|
||||||
app.on('ready', function() {
|
app.on('ready', function() {
|
||||||
// 'ctrl+x' 단축키를 리스너에 등록합니다.
|
// 'ctrl+x' 단축키를 리스너에 등록합니다.
|
||||||
var ret = globalShortcut.register('ctrl+x', function() { console.log('ctrl+x is pressed'); })
|
var ret = globalShortcut.register('ctrl+x', function() {
|
||||||
|
console.log('ctrl+x is pressed');
|
||||||
|
});
|
||||||
|
|
||||||
if (!ret) {
|
if (!ret) {
|
||||||
console.log('registration failed');
|
console.log('registration failed');
|
||||||
|
@ -56,4 +58,4 @@ app.on('will-quit', function() {
|
||||||
|
|
||||||
### `globalShortcut.unregisterAll()`
|
### `globalShortcut.unregisterAll()`
|
||||||
|
|
||||||
모든 전역 단축키 등록을 해제합니다.
|
모든 전역 단축키의 등록을 해제합니다.
|
||||||
|
|
|
@ -56,9 +56,13 @@ Electron 문서 구조를 이해하는 데 참고할 수 있는 유용한 도움
|
||||||
메서드 이름은 인수가 무엇을 받는지에 따라 결정됩니다. 선택적 인수는 브라켓([, ])으로 묶어
|
메서드 이름은 인수가 무엇을 받는지에 따라 결정됩니다. 선택적 인수는 브라켓([, ])으로 묶어
|
||||||
이 인수가 다른 인수뒤에서 선택적으로 사용될 수 있다는 것을 표시합니다.
|
이 인수가 다른 인수뒤에서 선택적으로 사용될 수 있다는 것을 표시합니다.
|
||||||
|
|
||||||
메서드의 밑에선 각 인수에 대해 자세한 설명을 합니다. 인수의 타입은 일반적인 타입 중 하나를 받거나:
|
메서드 이름 하단에선 각 인수에 대해 자세한 설명을 합니다.
|
||||||
[`String`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String), [`Number`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number), [`Object`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object), [`Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)
|
인수의 타입은 일반적인 타입 중 하나를 받거나:
|
||||||
Electron의 [`webContent`](api/web-content.md)같은 커스텀 타입을 받습니다.
|
[`String`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String),
|
||||||
|
[`Number`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number),
|
||||||
|
[`Object`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object),
|
||||||
|
[`Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)
|
||||||
|
와 같은 일반적으로 쓰이는 타입 중 하나를 받거나 Electron의 [`webContent`](api/web-content.md)같은 커스텀 타입을 받습니다.
|
||||||
|
|
||||||
### Events
|
### Events
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue