summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKirill Chibisov <contact@kchibisov.com>2020-12-11 03:40:32 +0300
committerGitHub <noreply@github.com>2020-12-11 00:40:32 +0000
commit6b208a6958a32594cf1248f5336f8a8f79d17fe3 (patch)
tree1e1269dd829e8cc6688eed8b60cafabc97108c0e
parentb0022047542de5979895ae0957e958b8cd5b6020 (diff)
Bump glutin to 0.26.0
Fixes #4530. Fixes #4072. Fixes #1927.
-rw-r--r--CHANGELOG.md7
-rw-r--r--Cargo.lock10
-rw-r--r--alacritty/Cargo.toml2
-rw-r--r--alacritty/src/config/bindings.rs4
-rw-r--r--alacritty/src/event.rs2
-rw-r--r--alacritty/src/wayland_theme.rs4
-rw-r--r--alacritty/src/window.rs21
7 files changed, 22 insertions, 28 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 707fa41a..873dc279 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -13,6 +13,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- New `cursor.style.blinking` option to set the default blinking state
- New `cursor.blink_interval` option to configure the blinking frequency
- Support for cursor blinking escapes (`CSI ? 12 h`, `CSI ? 12 l` and `CSI Ps SP q`)
+- IME support on Windows
+- Urgency support on Windows
### Changed
@@ -26,6 +28,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- Dimming colors which use the indexed `CSI 38 : 5 : Ps m` notation
- Slow rendering performance with a lot of cells with underline/strikeout attributes
- Performance of scrolling regions with offset from the bottom
+- Extra mouse buttons are no longer ignored on Wayland
+- Numpad arrow keys are now properly recognized on Wayland
+- Compilation when targetting aarch64-apple-darwin
+- Window not being completely opaque on Windows
+- Window being always on top during alt-tab on Windows
### Removed
diff --git a/Cargo.lock b/Cargo.lock
index 72997288..a526f0b0 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -848,9 +848,9 @@ checksum = "9b919933a397b79c37e33b77bb2aa3dc8eb6e165ad809e58ff75bc7db2e34574"
[[package]]
name = "glutin"
-version = "0.25.1"
+version = "0.26.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d8bae26a39a728b003e9fad473ea89527de0de050143b4df866f18bb154bc86e"
+checksum = "1ae1cbb9176b9151c4ce03f012e3cd1c6c18c4be79edeaeb3d99f5d8085c5fa3"
dependencies = [
"android_glue",
"cgl",
@@ -2362,12 +2362,12 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
[[package]]
name = "winit"
-version = "0.23.0"
+version = "0.24.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b5bc559da567d8aa671bbcd08304d49e982c7bf2cb91e10288b9188931c1b772"
+checksum = "da4eda6fce0eb84bd0a33e3c8794eb902e1033d0a1d5a31bc4f19b1b4bbff597"
dependencies = [
"bitflags",
- "cocoa 0.23.0",
+ "cocoa 0.24.0",
"core-foundation 0.9.1",
"core-graphics 0.22.1",
"core-video-sys",
diff --git a/alacritty/Cargo.toml b/alacritty/Cargo.toml
index 8de19196..a4f774b1 100644
--- a/alacritty/Cargo.toml
+++ b/alacritty/Cargo.toml
@@ -21,7 +21,7 @@ fnv = "1"
serde = { version = "1", features = ["derive"] }
serde_yaml = "0.8"
serde_json = "1"
-glutin = { version = "0.25.1", default-features = false, features = ["serde"] }
+glutin = { version = "0.26.0", default-features = false, features = ["serde"] }
notify = "4"
parking_lot = "0.11.0"
crossfont = { version = "0.1.0", features = ["force_system_fontconfig"] }
diff --git a/alacritty/src/config/bindings.rs b/alacritty/src/config/bindings.rs
index 62da0e6c..f5b63561 100644
--- a/alacritty/src/config/bindings.rs
+++ b/alacritty/src/config/bindings.rs
@@ -638,7 +638,7 @@ impl<'a> Deserialize<'a> for MouseButtonWrapper {
type Value = MouseButtonWrapper;
fn expecting(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
- f.write_str("Left, Right, Middle, or a number from 0 to 255")
+ f.write_str("Left, Right, Middle, or a number from 0 to 65536")
}
fn visit_u64<E>(self, value: u64) -> Result<MouseButtonWrapper, E>
@@ -646,7 +646,7 @@ impl<'a> Deserialize<'a> for MouseButtonWrapper {
E: de::Error,
{
match value {
- 0..=255 => Ok(MouseButtonWrapper(MouseButton::Other(value as u8))),
+ 0..=65536 => Ok(MouseButtonWrapper(MouseButton::Other(value as u16))),
_ => Err(E::invalid_value(Unexpected::Unsigned(value), &self)),
}
}
diff --git a/alacritty/src/event.rs b/alacritty/src/event.rs
index 8ecf6f00..441cb21e 100644
--- a/alacritty/src/event.rs
+++ b/alacritty/src/event.rs
@@ -19,7 +19,7 @@ use std::time::{Duration, Instant};
use glutin::dpi::PhysicalSize;
use glutin::event::{ElementState, Event as GlutinEvent, ModifiersState, MouseButton, WindowEvent};
use glutin::event_loop::{ControlFlow, EventLoop, EventLoopProxy, EventLoopWindowTarget};
-use glutin::platform::desktop::EventLoopExtDesktop;
+use glutin::platform::run_return::EventLoopExtRunReturn;
#[cfg(all(feature = "wayland", not(any(target_os = "macos", windows))))]
use glutin::platform::unix::EventLoopWindowTargetExtUnix;
use log::info;
diff --git a/alacritty/src/wayland_theme.rs b/alacritty/src/wayland_theme.rs
index c18044f9..b9c4381e 100644
--- a/alacritty/src/wayland_theme.rs
+++ b/alacritty/src/wayland_theme.rs
@@ -67,10 +67,6 @@ impl WaylandTheme for AlacrittyWaylandTheme {
(_, Button::Close) => self.hovered_close_icon,
}
}
-
- fn font(&self) -> Option<(String, f32)> {
- Some((String::from("sans-serif"), 17.))
- }
}
trait IntoARGBColor {
diff --git a/alacritty/src/window.rs b/alacritty/src/window.rs
index 953fffd9..e43e5c95 100644
--- a/alacritty/src/window.rs
+++ b/alacritty/src/window.rs
@@ -27,10 +27,12 @@ use std::fmt::{self, Display, Formatter};
use glutin::dpi::{PhysicalPosition, PhysicalSize};
use glutin::event_loop::EventLoop;
#[cfg(target_os = "macos")]
-use glutin::platform::macos::{RequestUserAttentionType, WindowBuilderExtMacOS, WindowExtMacOS};
+use glutin::platform::macos::{WindowBuilderExtMacOS, WindowExtMacOS};
#[cfg(windows)]
use glutin::platform::windows::IconExtWindows;
-use glutin::window::{CursorIcon, Fullscreen, Window as GlutinWindow, WindowBuilder, WindowId};
+use glutin::window::{
+ CursorIcon, Fullscreen, UserAttentionType, Window as GlutinWindow, WindowBuilder, WindowId,
+};
use glutin::{self, ContextBuilder, PossiblyCurrent, WindowedContext};
#[cfg(windows)]
use winapi::shared::minwindef::WORD;
@@ -328,23 +330,12 @@ impl Window {
}
}
- #[cfg(all(feature = "x11", not(any(target_os = "macos", windows))))]
- pub fn set_urgent(&self, is_urgent: bool) {
- self.window().set_urgent(is_urgent);
- }
-
- #[cfg(target_os = "macos")]
pub fn set_urgent(&self, is_urgent: bool) {
- if !is_urgent {
- return;
- }
+ let attention = if is_urgent { Some(UserAttentionType::Critical) } else { None };
- self.window().request_user_attention(RequestUserAttentionType::Critical);
+ self.window().request_user_attention(attention);
}
- #[cfg(any(windows, not(any(feature = "x11", target_os = "macos"))))]
- pub fn set_urgent(&self, _is_urgent: bool) {}
-
pub fn set_outer_position(&self, pos: PhysicalPosition<i32>) {
self.window().set_outer_position(pos);
}