Skip to content

Commit

Permalink
feat(Windows): custom titlebar (onivim#1801)
Browse files Browse the repository at this point in the history
* Titlebar: Added custom titlebar for Windows

* Dependencies: dune=2.4.0 revery=8b399ed

* Titlebar: wire up buttons to respective functions

* Root: add WindowResizers for Windows [WIP]

* WindowResizers: refactor into a component

* Images: add titlebar icon

* WindowResizers: removed background colors

* Titlebar: use new icon

* Titlebar: fix `esy b dune build @check` errors

* Formatting

Co-authored-by: Bryan Phelps <[email protected]>
  • Loading branch information
zbaylin and bryphe authored May 23, 2020
1 parent 4b24747 commit fd19667
Show file tree
Hide file tree
Showing 18 changed files with 1,460 additions and 45 deletions.
Binary file added assets/fonts/codicon.ttf
Binary file not shown.
2 changes: 1 addition & 1 deletion assets/fonts/dune
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(install
(section bin)
(package Oni2)
(files Inconsolata-Bold.ttf Inconsolata-Regular.ttf Inter-UI-Medium.ttf Inter-UI-MediumItalic.ttf Inter-UI-Regular.ttf Inter-UI-Italic.ttf Inter-UI-SemiBoldItalic.ttf Inter-UI-SemiBold.ttf Inter-UI-Bold.ttf FiraCode-Regular.ttf FontAwesome5FreeRegular.otf FontAwesome5FreeSolid.otf selawk.ttf selawkb.ttf selawkl.ttf selawksb.ttf selawksl.ttf seti.ttf))
(files Inconsolata-Bold.ttf Inconsolata-Regular.ttf Inter-UI-Medium.ttf Inter-UI-MediumItalic.ttf Inter-UI-Regular.ttf Inter-UI-Italic.ttf Inter-UI-SemiBoldItalic.ttf Inter-UI-SemiBold.ttf Inter-UI-Bold.ttf FiraCode-Regular.ttf FontAwesome5FreeRegular.otf FontAwesome5FreeSolid.otf selawk.ttf selawkb.ttf selawkl.ttf selawksb.ttf selawksl.ttf seti.ttf codicon.ttf))
2 changes: 1 addition & 1 deletion assets/images/dune
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(install
(section bin)
(package Oni2)
(files logo.png background-grid.png title-logo.png))
(files logo.png logo-titlebar.png background-grid.png title-logo.png))
Binary file added assets/images/logo-titlebar.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
61 changes: 61 additions & 0 deletions bench.esy.lock/opam/dune.2.4.0/opam

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

61 changes: 61 additions & 0 deletions esy.lock/opam/dune.2.4.0/opam

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions integration_test/lib/Oni_IntegrationTestLib.re
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,15 @@ let setVsync = vsync => _currentVsync := vsync;

let maximize = () => _currentMaximized := true;
let minimize = () => _currentMinimized := true;
let restore = () => {
_currentMaximized := false;
_currentMinimized := false;
};

let quit = code => exit(code);

let close = () => quit(0) |> ignore;

exception TestAssetNotFound(string);

let getAssetPath = path =>
Expand Down Expand Up @@ -165,6 +171,8 @@ let runTest =
~setVsync,
~maximize,
~minimize,
~restore,
~close,
~executingDirectory=Revery.Environment.getExecutingDirectory(),
~getState=() => currentState^,
~onStateChanged,
Expand Down
61 changes: 61 additions & 0 deletions integrationtest.esy.lock/opam/dune.2.4.0/opam

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit fd19667

Please sign in to comment.