mirror of
https://github.com/octopusYan/alist-gui.git
synced 2024-11-21 19:56:41 +08:00
chore: 调整
This commit is contained in:
parent
08f0473814
commit
9c75f9bf3a
8
pom.xml
8
pom.xml
@ -101,12 +101,14 @@
|
||||
<version>${hutool.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!-- lombok -->
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>${lombok.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!-- jackson -->
|
||||
<dependency>
|
||||
<groupId>com.fasterxml.jackson.dataformat</groupId>
|
||||
<artifactId>jackson-dataformat-yaml</artifactId>
|
||||
@ -253,7 +255,11 @@
|
||||
<generateInstaller>false</generateInstaller>
|
||||
<copyDependencies>true</copyDependencies>
|
||||
<assetsDir>${project.basedir}/src/main/resources/assets</assetsDir>
|
||||
<vmArgs>--enable-preview</vmArgs>
|
||||
<vmArgs>
|
||||
<arg>--enable-preview</arg>
|
||||
<arg>-Xmx100m</arg>
|
||||
<!-- <arg>-Djava.awt.headless=false</arg>-->
|
||||
</vmArgs>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
|
@ -97,7 +97,7 @@ public class Application extends javafx.application.Application {
|
||||
|
||||
private void showErrorDialog(Thread t, Throwable e) {
|
||||
logger.error("", e);
|
||||
AlertUtil.exception(new Exception(e)).show();
|
||||
Platform.runLater(() -> AlertUtil.exception(new Exception(e)).show());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -189,12 +189,16 @@ public class ConfigManager {
|
||||
}
|
||||
|
||||
public static void checkProxy(BiConsumer<Boolean, String> consumer) {
|
||||
if (ProxySetup.SYSTEM.equals(proxySetup())) {
|
||||
consumer.accept(true, "");
|
||||
return;
|
||||
}
|
||||
if (!hasProxy()) return;
|
||||
|
||||
ThreadPoolManager.getInstance().execute(() -> {
|
||||
try {
|
||||
InetSocketAddress address = NetUtil.createAddress(proxyHost(), getProxyPort());
|
||||
if (NetUtil.isOpen(address, 5000)) {
|
||||
if (NetUtil.isOpen(address, 1000)) {
|
||||
Platform.runLater(() -> consumer.accept(true, "success"));
|
||||
} else {
|
||||
Platform.runLater(() -> consumer.accept(false, "connection timed out"));
|
||||
|
@ -129,7 +129,7 @@ public class ConsoleLog {
|
||||
String regex = STR.".*(\{AListManager.scheme()}|\{URL_IP_REX}).*";
|
||||
if (ReUtil.isMatch(regex, message)) {
|
||||
String text = ReUtil.get(regex, message, 1);
|
||||
String url = text.startsWith("http") ? STR."http://\{text}" : text;
|
||||
String url = text.startsWith("http") ? text : STR."http://\{text}";
|
||||
url = url.replace("0.0.0.0", "127.0.0.1");
|
||||
message = message.replace(text, STR."[url=\{url}]\{text}[/url]");
|
||||
}
|
||||
|
@ -115,7 +115,7 @@ public class SetupViewModel extends BaseViewModel {
|
||||
ConfigManager.checkProxy((success, msg) -> {
|
||||
if (!success) {
|
||||
final var tmp = Context.getLanguageBinding("proxy.test.result.failed").getValue();
|
||||
AlertUtil.error(STR."\{tmp}:\{msg}").show();
|
||||
AlertUtil.error(STR."\{tmp}\{msg}").show();
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -23,18 +23,16 @@
|
||||
}
|
||||
|
||||
#startButton {
|
||||
-color-button-bg-hover: -color-button-bg;
|
||||
-color-button-bg-focused: -color-button-bg;
|
||||
-fx-border-color: -color-button-bg;
|
||||
-fx-border-color-hover: -color-button-bg;
|
||||
}
|
||||
|
||||
#passwordButton {
|
||||
-color-button-bg: -color-success-3;
|
||||
-color-button-bg-hover: -color-button-bg;
|
||||
-color-button-bg-focused: -color-success-3;
|
||||
-color-button-bg-focused: -color-button-bg;
|
||||
-color-button-bg-pressed: -color-button-bg;
|
||||
-fx-border-color: -color-success-3;
|
||||
-fx-border-color: -color-button-bg;
|
||||
}
|
||||
|
||||
#restartButton {
|
||||
|
Loading…
Reference in New Issue
Block a user