Skip to content

Commit

Permalink
Feature/nicks (#33)
Browse files Browse the repository at this point in the history
* Introducing nicks

* Improve tokio vs std threads distinction

Move MIDI play to seperate standard thread, making blocking tokio thread
free for other activities.

Use tokio intervals instead of sleeps

* Merge artifacts

* Finish
  • Loading branch information
RobertBendun authored Nov 15, 2024
1 parent 245fec1 commit 61d09f7
Show file tree
Hide file tree
Showing 9 changed files with 309 additions and 208 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added

- Nicks, saved in seperate file from blocks state

## [0.4.2] - 2024-11-15

### Added
Expand Down
29 changes: 18 additions & 11 deletions Cargo.lock

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

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ bson = "2.11.0"
anyhow = "1.0.75"
dirs = "5.0.1"
clap = { version = "4.5.3", features = ["derive", "string"] }
gethostname = "0.4.3"
chrono = "0.4.35"
tokio-util = { version = "0.7.10", features = ["net", "codec"] }
bincode = "1.3.3"
Expand All @@ -60,6 +59,7 @@ rust-embed = "8.3.0"
mime_guess = "2.0.4"
tracing-appender = "0.2.3"
shared_memory = "0.12.4"
whoami = "1.5.2"

[target.'cfg(windows)'.dependencies]
winapi = { version = "0.3.8", features = ["winbase", "consoleapi", "processenv", "handleapi", "synchapi", "impl-default"] }
Expand Down
1 change: 1 addition & 0 deletions public/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ aside button:focus {
main {
display: flex;
flex-direction: column;
overflow-y: scroll;
}

.block {
Expand Down
5 changes: 4 additions & 1 deletion public/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,16 @@ async function init_websocket() {
const registered_key_bindings = {};

/**
* @param {KeyboardEvent} input_element
* @param {KeyboardEvent} ev
*/
async function keyup(ev) {
if (ev.target.nodeName == "INPUT") {
return;
}

if (ev.metaKey || ev.altKey || ev.ctrlKey)
return;

if (ev.key == ' ') {
await fetch('/interrupt', { method: 'POST' });
ev.preventDefault();
Expand Down
Loading

0 comments on commit 61d09f7

Please sign in to comment.