Compare commits

..
2 Commits
Author SHA1 Message Date
Ansho Rei d90191618d fix: centre the logo on the login screen 2026-11-04 13:05:46 +01:00
Ansho Rei 936e28b483 feat: add an Exit button to the login screen
The login screen could only be left with Ctrl+Q, which a gamepad cannot
press. Exit sits below Connect as the last focus stop and goes through
Action::Quit.
2026-11-04 13:05:45 +01:00
6 changed files with 42 additions and 5 deletions
+12
View File
@@ -2,6 +2,18 @@
One section per version, newest first.
## v0.6.1 (2026-11-04)
### Bug fixes
- The logo is centred on the login screen.
## v0.6.0 (2026-11-04)
### Features
- The login screen has an Exit button below Connect, so remus can be closed from a controller before logging in.
## v0.5.0 (2026-11-04)
### Features
Generated
+1 -1
View File
@@ -4385,7 +4385,7 @@ checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4"
[[package]]
name = "remus"
version = "0.5.0"
version = "0.6.1"
dependencies = [
"anyhow",
"directories",
+1 -1
View File
@@ -1,6 +1,6 @@
[package]
name = "remus"
version = "0.5.0"
version = "0.6.1"
edition = "2024"
license = "MIT"
@@ -20,6 +20,8 @@
</supports>
<content_rating type="oars-1.1"/>
<releases>
<release version="0.6.1" date="2026-11-04"/>
<release version="0.6.0" date="2026-11-04"/>
<release version="0.5.0" date="2026-11-04"/>
<release version="0.4.0" date="2026-11-04"/>
<release version="0.3.0" date="2026-11-04"/>
+8 -2
View File
@@ -370,7 +370,7 @@ impl App {
}
fn set_login_focus(&mut self, i: i32) {
self.login_focus = i.clamp(0, 3);
self.login_focus = i.clamp(0, 4);
self.ui.set_login_focus(self.login_focus);
self.ui.invoke_focus_login(self.login_focus);
self.render_hints();
@@ -381,6 +381,7 @@ impl App {
Action::Up | Action::SectionPrev => self.set_login_focus(self.login_focus - 1),
Action::Down | Action::SectionNext => self.set_login_focus(self.login_focus + 1),
Action::Activate if self.login_focus < 2 => self.set_login_focus(self.login_focus + 1),
Action::Activate if self.login_focus == 4 => self.action(Action::Quit),
Action::Activate => self.login_submit(),
_ => {}
}
@@ -1306,7 +1307,12 @@ impl App {
};
match self.screen {
Screen::Login => {
h(Control::Activate, if self.login_focus < 2 { "Next" } else { "Connect" });
let label = match self.login_focus {
0 | 1 => "Next",
4 => "Exit",
_ => "Connect",
};
h(Control::Activate, label);
}
Screen::Browse => match self.area {
Area::Sidebar => {
+18 -1
View File
@@ -641,6 +641,7 @@ component LoginView inherits Rectangle {
in property <string> error;
in property <bool> busy;
callback submit;
callback exit;
callback field-clicked(int);
public function focus-field(i: int) {
if (i == 0) {
@@ -665,7 +666,7 @@ component LoginView inherits Rectangle {
spacing: 20px * Theme.s;
HorizontalLayout {
alignment: start;
alignment: center;
Image {
source: @image-url("../branding/svg/remus-logo.svg");
height: 68px * Theme.s;
@@ -711,6 +712,21 @@ component LoginView inherits Rectangle {
clicked => { root.submit(); }
}
}
// Secondary to Connect: outlined, no fill, and only lit when focused.
Rectangle {
height: 46px * Theme.s;
border-radius: 12px * Theme.s;
border-width: 2px * Theme.s;
border-color: root.focus-index == 4 ? Theme.focus : Theme.line;
Text {
text: "Exit";
font-size: 17px * Theme.s;
color: root.focus-index == 4 ? Theme.text : Theme.muted;
}
TouchArea {
clicked => { root.exit(); }
}
}
if root.error != "": Text {
text: root.error;
font-size: 15px * Theme.s;
@@ -999,6 +1015,7 @@ export component AppWindow inherits Window {
error: root.login-error;
busy: root.login-busy;
submit => { root.login-submit(); }
exit => { root.action(Action.quit); }
field-clicked(i) => { root.login-field-clicked(i); }
}