Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/tsukinaha/tsukimi into feat…
Browse files Browse the repository at this point in the history
…ure/win
  • Loading branch information
Kosette committed Apr 4, 2024
2 parents 19a060a + 179fd52 commit 82ae545
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion resources/ui/settings.ui
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
<property name="adjustment">
<object class="GtkAdjustment">
<property name="lower">350</property>
<property name="upper">1000</property>
<property name="upper">1500</property>
<property name="value">700</property>
<property name="page-increment">10</property>
<property name="step-increment">50</property>
Expand Down
8 changes: 5 additions & 3 deletions src/ui/widgets/window.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
use std::env;

use adw::prelude::NavigationPageExt;
use gio::Settings;
use gtk::prelude::*;
use gtk::subclass::prelude::*;
use std::env;
mod imp {
use std::cell::OnceCell;

Expand Down Expand Up @@ -97,7 +96,6 @@ mod imp {
obj.setup_settings();
obj.load_window_size();
obj.loginenter();
obj.homepage();
self.selectlist
.connect_row_selected(glib::clone!(@weak obj => move |_, row| {
if let Some(row) = row {
Expand Down Expand Up @@ -146,6 +144,7 @@ mod imp {
use glib::Object;
use gtk::{gio, glib};

use crate::config::load_cfg;
use crate::ui::network::runtime;
use crate::APP_ID;

Expand Down Expand Up @@ -298,7 +297,9 @@ impl Window {
match receiver.recv().await {
Ok(_) => {
loginbutton.set_sensitive(false);
load_cfg();
obj.mainpage();
obj.homepage();
}
Err(_) => {
loginbutton.set_sensitive(true);
Expand All @@ -317,6 +318,7 @@ impl Window {
.join("tsukimi.toml");
if path.exists() {
self.mainpage();
self.homepage();
}
}
}

0 comments on commit 82ae545

Please sign in to comment.