-
Notifications
You must be signed in to change notification settings - Fork 664
feat(windows): add custom Windows title bar to replace the default #9133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
SilkePilon
wants to merge
51
commits into
gitbutlerapp:master
Choose a base branch
from
SilkePilon:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 42 commits
Commits
Show all changes
51 commits
Select commit
Hold shift + click to select a range
7bea2f3
feat(windows): add custom Windows title bar and hide default
SilkePilon 1831aa0
Merge pull request #2 from SilkePilon/feat-windows-custom-titlebar
SilkePilon 188f5dd
Apply `cargo fmt` and auto-fix node lints
Byron 8187f90
feat: add WindowsTitleBar component with app info and controls
SilkePilon 129c157
Merge branch 'master' into feat-add-windows-titlebar-component
SilkePilon 246c517
Merge pull request #3 from SilkePilon/feat-add-windows-titlebar-compo…
SilkePilon ed9722e
Merge branch 'master' into master
SilkePilon 08abe9b
feat(windows-title-bar): add keyboard shortcuts and reactive project
SilkePilon c5ad4f3
Merge pull request #4 from SilkePilon/feat-add-windows-titlebar-compo…
SilkePilon b294960
feat(window): hide default title bar on Windows
SilkePilon 7d9038d
Merge pull request #5 from SilkePilon/feat-add-windows-titlebar-compo…
SilkePilon 537b015
feat(windows-title-bar): add editor badge to title bar
SilkePilon 0492aa5
Merge pull request #6 from SilkePilon/feat/windows-title-bar-editor-b…
SilkePilon 814132a
93522e9
refactor: move Windows title bar toggle to bottom of appearance settings
SilkePilon a54f238
Merge branch 'master' into add-custom-titlebar-setting
SilkePilon bc0f8cb
Merge pull request #7 from SilkePilon/add-custom-titlebar-setting
SilkePilon 6221cce
Merge branch 'master' into master
SilkePilon c2f2059
fix(desktop): apply padding only with custom title bar on Windows
SilkePilon 2ab80c1
Merge pull request #8 from SilkePilon/fix-windows-custom-titlebar-pad…
SilkePilon 54e8acf
Merge branch 'master' into master
SilkePilon 0aa1d8e
feat(ui,desktop): add borderRadius to Badge and improve title bar menus
SilkePilon ecec3fc
Merge pull request #9 from SilkePilon/feat-ui-borderradius-titlebar-m…
SilkePilon 704aff2
Merge branch 'master' into master
SilkePilon 70df29e
feat(windows): always use custom title bar and remove toggle
SilkePilon 7a80706
style(desktop): adjust WindowsTitleBar menu button spacing
SilkePilon 6329bcc
refactor: reorganize imports and streamline project state logic
SilkePilon db676b0
Merge pull request #10 from SilkePilon/windows-custom-titlebar-ui-ref…
SilkePilon d35fa4d
fix(desktop): remove extraneous closing braces in WindowsTitleBar
SilkePilon 3d2a717
Merge pull request #11 from SilkePilon/fix-windows-titlebar-braces
SilkePilon 30be9c4
refactor: improve window handling and code organization
SilkePilon 7d27f90
Merge pull request #12 from SilkePilon/refactor-improve-window-handli…
SilkePilon cda86c0
refactor(ui): improve badge components and title bar UI
SilkePilon 2a8b6cd
refactor: improve WindowsTitleBar component zoom handling
SilkePilon 085d2ea
Merge pull request #13 from SilkePilon/refactor-badge-and-titlebar-co…
SilkePilon 090c4ac
Merge branch 'master' into master
SilkePilon 0f410aa
refactor: remove unused imports in AppearanceSettings.svelte
SilkePilon 2147815
Merge pull request #14 from SilkePilon/refactor-remove-unused-imports…
SilkePilon ce9a5e2
Merge branch 'master' into master
SilkePilon c982a17
Merge branch 'master' into master
SilkePilon 2789912
Merge branch 'master' into master
SilkePilon 7c841ad
some style tweaks
PavelLaptev ea202ad
Refactor WindowsTitleBar badge and update styles
PavelLaptev a337322
ui fixes
PavelLaptev 61366be
remove social net icons
PavelLaptev 7b998e3
Merge branch 'master' into master
SilkePilon 4aa7814
fix: simplify Badge component class logic
SilkePilon 5fbbeaf
feat: add dropdown visibility tracking
SilkePilon 18f0a0f
refactor: streamline dropdown management in WindowsTitleBar
SilkePilon 65a3574
Merge pull request #15 from SilkePilon/sp-branch-2
SilkePilon 848491e
remove extra platform check
PavelLaptev File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,34 @@ | ||
import { invoke as invokeIpc, listen as listenIpc } from '$lib/backend/ipc'; | ||
import { getVersion } from '@tauri-apps/api/app'; | ||
import { getCurrentWindow } from '@tauri-apps/api/window'; | ||
import { check } from '@tauri-apps/plugin-updater'; | ||
|
||
export class Tauri { | ||
invoke = invokeIpc; | ||
listen = listenIpc; | ||
checkUpdate = check; | ||
currentVersion = getVersion; | ||
|
||
private window = getCurrentWindow(); | ||
|
||
async minimize() { | ||
await this.window.minimize(); | ||
} | ||
|
||
async toggleMaximize() { | ||
const isMaximized = await this.window.isMaximized(); | ||
if (isMaximized) { | ||
await this.window.unmaximize(); | ||
} else { | ||
await this.window.maximize(); | ||
} | ||
} | ||
|
||
async close() { | ||
await this.window.close(); | ||
} | ||
|
||
async setDecorations(decorations: boolean) { | ||
await this.window.setDecorations(decorations); | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this not identical to below?