Skip to content

Commit

Permalink
feat: add App log folder open button. (#135)
Browse files Browse the repository at this point in the history
  • Loading branch information
hizumiaoba authored Oct 26, 2024
1 parent cfc7e2d commit d7c5e6e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -503,6 +503,19 @@ private void runConcurrentTask(ExecutorService service, Runnable task) {
service.execute(task);
}

public void onOpenAppLogFolderBtnClick() {
runConcurrentTask(es, () -> {
try {
log.debug("Opening the App Log folder.");
Desktop.getDesktop().open(Paths.get("").toAbsolutePath().toFile());
} catch (IOException e) {
ExceptionPopup popup = new ExceptionPopup(e, "フォルダを開けませんでした。",
"MainController#onOpenBackupSavingFolderBtnClick()$lambda");
popup.pop();
}
});
}

@RequiredArgsConstructor
static class GlobalShortcutKeyListener implements HotkeyListener {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@
<Button fx:id="openConfigEditorBtn" disable="true" mnemonicParsing="false" onAction="#onOpenConfigEditorBtnClick" prefHeight="40.0" prefWidth="170.0" text="コンフィグエディター" />
<Button fx:id="openRelatedFolderBtn" disable="true" layoutX="30.0" layoutY="17.0" mnemonicParsing="false" onAction="#onOpenRelatedFolderBtnClick" prefHeight="40.0" prefWidth="170.0" text="各種フォルダを開く" />
<Button fx:id="checkVersionUpdateBtn" layoutX="215.0" layoutY="17.0" mnemonicParsing="false" onAction="#onOpenReleasePageOnWebBtnClick" prefHeight="40.0" prefWidth="170.0" text="最新リリースをwebで確認" />
<Button fx:id="openAppLogFolderBtn" layoutX="400.0" layoutY="17.0" mnemonicParsing="false" onAction="#onOpenAppLogFolderBtnClick" prefHeight="40.0" prefWidth="170.0" text="MCTMログフォルダを開く" />
</children>
<padding>
<Insets left="20.0" />
Expand Down

0 comments on commit d7c5e6e

Please sign in to comment.