Skip to content

Commit

Permalink
move disallowReloadKeybinding under the electron subsection
Browse files Browse the repository at this point in the history
Signed-off-by: Luca Jaeger <owl.jaeger@gmail.com>
  • Loading branch information
owlJaeger committed May 13, 2020
1 parent 8700cae commit 981e251
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Breaking changes:

- [scm] support file tree mode in Source Control view. Classes that extend ScmWidget will likely require changes [#7505](https://github.com/eclipse-theia/theia/pull/7505)
- [task] removed `taskId` from `TaskTerminalWidgetOpenerOptions` [#7765](https://github.com/eclipse-theia/theia/pull/7765)
- [application-package] moved `disallowReloadKeybinding` under the `electron` subsection [#7803](https://github.com/eclipse-theia/theia/pull/7803)

## v1.1.0

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,10 @@ const { ElectronSecurityToken } = require('@theia/core/lib/electron-common/elect
const applicationName = \`${this.pck.props.frontend.config.applicationName}\`;
const isSingleInstance = ${this.pck.props.backend.config.singleInstance === true ? 'true' : 'false'};
const disallowReloadKeybinding = ${this.pck.props.frontend.config.disallowReloadKeybinding === true ? 'true' : 'false'};
const disallowReloadKeybinding = ${this.pck.props.frontend.config.electron?.disallowReloadKeybinding === true ? 'true' : 'false'};
const defaultWindowOptionsAdditions = ${this.prettyStringify(this.pck.props.frontend.config.electron?.windowOptions || {})};
if (isSingleInstance && !app.requestSingleInstanceLock()) {
// There is another instance running, exit now. The other instance will request focus.
app.quit();
Expand Down
12 changes: 6 additions & 6 deletions dev-packages/application-package/src/application-props.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,12 +115,6 @@ export interface FrontendApplicationConfig extends ApplicationConfig {
*/
readonly applicationName: string;

/**
* If set to `true`, reloading the current browser window won't be possible with the `Ctrl/Cmd + R` keybinding.
* It is `false` by default. Has no effect if not in an electron environment.
*/
readonly disallowReloadKeybinding?: boolean;

/**
* Electron specific configuration.
*/
Expand All @@ -129,6 +123,12 @@ export interface FrontendApplicationConfig extends ApplicationConfig {

export interface ElectronFrontendApplicationConfig {

/**
* If set to `true`, reloading the current browser window won't be possible with the `Ctrl/Cmd + R` keybinding.
* It is `false` by default. Has no effect if not in an electron environment.
*/
readonly disallowReloadKeybinding?: boolean;

/**
* Override or add properties to the electron `windowOptions`.
*/
Expand Down

0 comments on commit 981e251

Please sign in to comment.