Compare commits
No commits in common. "d030f1360ac95b98a78cbae4c67c4e2b7643ed01" and "b518572d0fc0fea02030326f1110debb55389762" have entirely different histories.
d030f1360a
...
b518572d0f
@ -12,6 +12,9 @@ jobs:
|
|||||||
update-pkgver:
|
update-pkgver:
|
||||||
runs-on: moonarch
|
runs-on: moonarch
|
||||||
steps:
|
steps:
|
||||||
|
- name: Install dependencies
|
||||||
|
run: pacman -Sy --noconfirm git
|
||||||
|
|
||||||
- name: Checkout source repo
|
- name: Checkout source repo
|
||||||
run: |
|
run: |
|
||||||
git clone --bare http://gitea:3000/nevaforget/moonset.git source.git
|
git clone --bare http://gitea:3000/nevaforget/moonset.git source.git
|
||||||
|
|||||||
2
Cargo.lock
generated
2
Cargo.lock
generated
@ -616,7 +616,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "moonset"
|
name = "moonset"
|
||||||
version = "0.8.2"
|
version = "0.8.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"dirs",
|
"dirs",
|
||||||
"gdk-pixbuf",
|
"gdk-pixbuf",
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "moonset"
|
name = "moonset"
|
||||||
version = "0.8.2"
|
version = "0.8.1"
|
||||||
edition = "2024"
|
edition = "2024"
|
||||||
description = "Wayland session power menu with GTK4 and Layer Shell"
|
description = "Wayland session power menu with GTK4 and Layer Shell"
|
||||||
license = "MIT"
|
license = "MIT"
|
||||||
|
|||||||
14
src/panel.rs
14
src/panel.rs
@ -292,7 +292,6 @@ pub fn create_panel_window(texture: Option<&gdk::Texture>, blur_radius: Option<f
|
|||||||
&confirm_area,
|
&confirm_area,
|
||||||
&confirm_box,
|
&confirm_box,
|
||||||
&error_label,
|
&error_label,
|
||||||
&button_box,
|
|
||||||
);
|
);
|
||||||
button_box.append(&button);
|
button_box.append(&button);
|
||||||
}
|
}
|
||||||
@ -376,7 +375,6 @@ fn create_action_button(
|
|||||||
confirm_area: >k::Box,
|
confirm_area: >k::Box,
|
||||||
confirm_box: &Rc<RefCell<Option<gtk::Box>>>,
|
confirm_box: &Rc<RefCell<Option<gtk::Box>>>,
|
||||||
error_label: >k::Label,
|
error_label: >k::Label,
|
||||||
button_box: >k::Box,
|
|
||||||
) -> gtk::Button {
|
) -> gtk::Button {
|
||||||
let button_content = gtk::Box::new(gtk::Orientation::Vertical, 4);
|
let button_content = gtk::Box::new(gtk::Orientation::Vertical, 4);
|
||||||
button_content.set_halign(gtk::Align::Center);
|
button_content.set_halign(gtk::Align::Center);
|
||||||
@ -406,8 +404,6 @@ fn create_action_button(
|
|||||||
confirm_box,
|
confirm_box,
|
||||||
#[weak]
|
#[weak]
|
||||||
error_label,
|
error_label,
|
||||||
#[weak]
|
|
||||||
button_box,
|
|
||||||
move |_| {
|
move |_| {
|
||||||
on_action_clicked(
|
on_action_clicked(
|
||||||
&action_def,
|
&action_def,
|
||||||
@ -416,7 +412,6 @@ fn create_action_button(
|
|||||||
&confirm_area,
|
&confirm_area,
|
||||||
&confirm_box,
|
&confirm_box,
|
||||||
&error_label,
|
&error_label,
|
||||||
&button_box,
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
));
|
));
|
||||||
@ -439,7 +434,6 @@ fn on_action_clicked(
|
|||||||
confirm_area: >k::Box,
|
confirm_area: >k::Box,
|
||||||
confirm_box: &Rc<RefCell<Option<gtk::Box>>>,
|
confirm_box: &Rc<RefCell<Option<gtk::Box>>>,
|
||||||
error_label: >k::Label,
|
error_label: >k::Label,
|
||||||
button_box: >k::Box,
|
|
||||||
) {
|
) {
|
||||||
dismiss_confirm(confirm_area, confirm_box);
|
dismiss_confirm(confirm_area, confirm_box);
|
||||||
error_label.set_visible(false);
|
error_label.set_visible(false);
|
||||||
@ -449,7 +443,7 @@ fn on_action_clicked(
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
show_confirm(action_def, strings, app, confirm_area, confirm_box, error_label, button_box);
|
show_confirm(action_def, strings, app, confirm_area, confirm_box, error_label);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Show inline confirmation below the action buttons.
|
/// Show inline confirmation below the action buttons.
|
||||||
@ -460,7 +454,6 @@ fn show_confirm(
|
|||||||
confirm_area: >k::Box,
|
confirm_area: >k::Box,
|
||||||
confirm_box: &Rc<RefCell<Option<gtk::Box>>>,
|
confirm_box: &Rc<RefCell<Option<gtk::Box>>>,
|
||||||
error_label: >k::Label,
|
error_label: >k::Label,
|
||||||
button_box: >k::Box,
|
|
||||||
) {
|
) {
|
||||||
let new_box = gtk::Box::new(gtk::Orientation::Vertical, 8);
|
let new_box = gtk::Box::new(gtk::Orientation::Vertical, 8);
|
||||||
new_box.set_halign(gtk::Align::Center);
|
new_box.set_halign(gtk::Align::Center);
|
||||||
@ -508,13 +501,8 @@ fn show_confirm(
|
|||||||
confirm_area,
|
confirm_area,
|
||||||
#[strong]
|
#[strong]
|
||||||
confirm_box,
|
confirm_box,
|
||||||
#[weak]
|
|
||||||
button_box,
|
|
||||||
move |_| {
|
move |_| {
|
||||||
dismiss_confirm(&confirm_area, &confirm_box);
|
dismiss_confirm(&confirm_area, &confirm_box);
|
||||||
if let Some(first) = button_box.first_child() {
|
|
||||||
first.grab_focus();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
));
|
));
|
||||||
button_row.append(&no_btn);
|
button_row.append(&no_btn);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user