mirror of
https://github.com/Eugeny/tabby.git
synced 2025-10-05 14:34:54 +00:00
nicer touch bar buttons
This commit is contained in:
@@ -24,7 +24,7 @@ title-bar(
|
||||
[index]='idx',
|
||||
[tab]='tab',
|
||||
[active]='tab == app.activeTab',
|
||||
[hasActivity]='tab.hasActivity',
|
||||
[hasActivity]='tab.activity$|async',
|
||||
@animateTab,
|
||||
(click)='app.selectTab(tab)',
|
||||
[class.fully-draggable]='hostApp.platform != Platform.macOS',
|
||||
|
@@ -144,7 +144,7 @@ export class AppRootComponent {
|
||||
if (progress !== null) {
|
||||
this.hostApp.getWindow().setProgressBar(progress / 100.0, 'normal')
|
||||
} else {
|
||||
this.hostApp.getWindow().setProgressBar(0, 'none')
|
||||
this.hostApp.getWindow().setProgressBar(-1, 'none')
|
||||
}
|
||||
})
|
||||
})
|
||||
|
@@ -6,18 +6,20 @@ export abstract class BaseTabComponent {
|
||||
id: number
|
||||
title: string
|
||||
customTitle: string
|
||||
hasActivity = false
|
||||
hasFocus = false
|
||||
hasActivity = false
|
||||
hostView: ViewRef
|
||||
protected titleChange = new Subject<string>()
|
||||
protected focused = new Subject<void>()
|
||||
protected blurred = new Subject<void>()
|
||||
protected progress = new Subject<number>()
|
||||
protected activity = new Subject<boolean>()
|
||||
|
||||
get focused$ (): Observable<void> { return this.focused }
|
||||
get blurred$ (): Observable<void> { return this.blurred }
|
||||
get titleChange$ (): Observable<string> { return this.titleChange }
|
||||
get progress$ (): Observable<number> { return this.progress }
|
||||
get activity$ (): Observable<boolean> { return this.activity }
|
||||
|
||||
constructor () {
|
||||
this.id = BaseTabComponent.lastTabID++
|
||||
@@ -42,6 +44,12 @@ export abstract class BaseTabComponent {
|
||||
|
||||
displayActivity (): void {
|
||||
this.hasActivity = true
|
||||
this.activity.next(true)
|
||||
}
|
||||
|
||||
clearActivity (): void {
|
||||
this.hasActivity = false
|
||||
this.activity.next(false)
|
||||
}
|
||||
|
||||
getRecoveryToken (): any {
|
||||
|
Reference in New Issue
Block a user