mirror of
https://github.com/Eugeny/tabby.git
synced 2025-07-15 16:09:56 +00:00
Some docking fixes (fixed #13)
This commit is contained in:
parent
9badd88c80
commit
d4840bafaf
terminus-core/src/services
terminus-settings/src/components
@ -40,12 +40,12 @@ export class DockingService {
|
|||||||
newBounds.height = Math.round(fill * display.bounds.height)
|
newBounds.height = Math.round(fill * display.bounds.height)
|
||||||
}
|
}
|
||||||
if (dockSide === 'right') {
|
if (dockSide === 'right') {
|
||||||
newBounds.x = display.bounds.x + display.bounds.width * (1.0 - fill)
|
newBounds.x = display.bounds.x + Math.round(display.bounds.width * (1.0 - fill))
|
||||||
} else {
|
} else {
|
||||||
newBounds.x = display.bounds.x
|
newBounds.x = display.bounds.x
|
||||||
}
|
}
|
||||||
if (dockSide === 'bottom') {
|
if (dockSide === 'bottom') {
|
||||||
newBounds.y = display.bounds.y + display.bounds.height * (1.0 - fill)
|
newBounds.y = display.bounds.y + Math.round(display.bounds.height * (1.0 - fill))
|
||||||
} else {
|
} else {
|
||||||
newBounds.y = display.bounds.y
|
newBounds.y = display.bounds.y
|
||||||
}
|
}
|
||||||
|
@ -109,17 +109,17 @@ ngb-tabset.vertical(type='tabs')
|
|||||||
label Display on
|
label Display on
|
||||||
br
|
br
|
||||||
div(
|
div(
|
||||||
'[(ngModel)]'='config.store.appearance.dockScreen'
|
[(ngModel)]='config.store.appearance.dockScreen',
|
||||||
'(ngModelChange)'='config.save(); docking.dock()'
|
(ngModelChange)='config.save(); docking.dock()',
|
||||||
ngbRadioGroup
|
ngbRadioGroup
|
||||||
)
|
)
|
||||||
label.btn.btn-secondary
|
label.btn.btn-secondary
|
||||||
input(
|
input(
|
||||||
type='radio',
|
type='radio',
|
||||||
[value]='"current"'
|
value='current'
|
||||||
)
|
)
|
||||||
| Current
|
| Current
|
||||||
label.btn.btn-secondary(*ngFor='let screen of docking.getScreens()')
|
label.btn.btn-secondary(*ngFor='let screen of screens')
|
||||||
input(
|
input(
|
||||||
type='radio',
|
type='radio',
|
||||||
[value]='screen.id'
|
[value]='screen.id'
|
||||||
|
@ -14,6 +14,7 @@ import { SettingsTabProvider } from '../api'
|
|||||||
export class SettingsTabComponent extends BaseTabComponent {
|
export class SettingsTabComponent extends BaseTabComponent {
|
||||||
hotkeyFilter = ''
|
hotkeyFilter = ''
|
||||||
private hotkeyDescriptions: IHotkeyDescription[]
|
private hotkeyDescriptions: IHotkeyDescription[]
|
||||||
|
private screens
|
||||||
|
|
||||||
constructor (
|
constructor (
|
||||||
public config: ConfigService,
|
public config: ConfigService,
|
||||||
@ -28,6 +29,7 @@ export class SettingsTabComponent extends BaseTabComponent {
|
|||||||
this.hotkeyDescriptions = hotkeyProviders.map(x => x.hotkeys).reduce((a, b) => a.concat(b))
|
this.hotkeyDescriptions = hotkeyProviders.map(x => x.hotkeys).reduce((a, b) => a.concat(b))
|
||||||
this.title$.next('Settings')
|
this.title$.next('Settings')
|
||||||
this.scrollable = true
|
this.scrollable = true
|
||||||
|
this.screens = this.docking.getScreens()
|
||||||
}
|
}
|
||||||
|
|
||||||
getRecoveryToken (): any {
|
getRecoveryToken (): any {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user