Skip to content

Commit bf0aecf

Browse files
committed
github link & rust 1.85.0
1 parent 6e48535 commit bf0aecf

File tree

5 files changed

+86
-47
lines changed

5 files changed

+86
-47
lines changed

Cargo.lock

+78-39
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "draw-together"
3-
version = "2.2.4"
4-
edition = "2021"
3+
version = "2.2.5"
4+
edition = "2024"
55

66
[[bin]]
77
name = "draw-together"

src/data.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ impl Data {
135135
None => None,
136136
};
137137

138-
let mut data: Vec<u8> = vec![0xff; RESOLUTION * 3];
138+
let mut data: Vec<u8> = vec![0xFF; RESOLUTION * 3];
139139
if file.is_some() {
140140
data.clear();
141141
file.as_mut().unwrap().read_to_end(&mut data).await.unwrap();
@@ -209,7 +209,7 @@ impl Data {
209209
let row_start = y * RESOLUTION_WIDTH * 3;
210210
for x in start_x..=end_x {
211211
let index = row_start + x * 3;
212-
self_data[index..index + 3].copy_from_slice(&[0xff, 0xff, 0xff]);
212+
self_data[index..index + 3].copy_from_slice(&[0xFF, 0xFF, 0xFF]);
213213
}
214214
}
215215
}

src/main.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
mod data;
22

33
use axum::{
4+
Router,
45
body::{Body, Bytes},
56
extract::{
6-
ws::{Message, WebSocketUpgrade},
77
ConnectInfo, State,
8+
ws::{Message, WebSocketUpgrade},
89
},
910
http::HeaderMap,
1011
response::Response,
1112
routing::{any, get},
12-
Router,
1313
};
14-
use futures_util::{stream::StreamExt, SinkExt};
14+
use futures_util::{SinkExt, stream::StreamExt};
1515
use std::{net::SocketAddr, path::Path, sync::Arc};
1616
use tokio::sync::Mutex;
1717

static/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
</div>
2626

2727
<div class="flex flex-col items-center text-white text-right pr-2">
28-
<h1>Draw Together!</h1>
28+
<a href="https://github.com/0x7d8/draw-together" target="_blank" class="hover:underline text-blue-400">Draw Together!</a>
2929
<span id="status">Connecting...</span>
3030
</div>
3131
</nav>

0 commit comments

Comments
 (0)