Skip to content

Commit

Permalink
Change dialog size
Browse files Browse the repository at this point in the history
  • Loading branch information
trixon committed Mar 7, 2024
1 parent 8208535 commit 647ffde
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 43 deletions.
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
MSG_LogTab_name=&Log
MSG_ShortLogTab_name=Log
Binary file added cric.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 3 additions & 1 deletion main/src/main/java/se/trixon/cric/core/ExecutorManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
*/
package se.trixon.cric.core;

import java.awt.Dimension;
import java.util.HashMap;
import java.util.ResourceBundle;
import javafx.scene.Scene;
Expand All @@ -39,6 +40,7 @@ public class ExecutorManager {
private final ResourceBundle mBundle = NbBundle.getBundle(ExecutorManager.class);
private final HashMap<String, Executor> mExecutors = new HashMap<>();
private InputOutput mInputOutput;
private final Dimension mPreferredSize = SwingHelper.getUIScaledDim(800, 600);

public static ExecutorManager getInstance() {
return Holder.INSTANCE;
Expand All @@ -62,7 +64,7 @@ protected void fxConstructor() {
setScene(new Scene(taskInfoPane));
}
};
dialogPanel.setPreferredSize(SwingHelper.getUIScaledDim(640, 300));
dialogPanel.setPreferredSize(mPreferredSize);

SwingUtilities.invokeLater(() -> {
var title = Dict.Dialog.TITLE_TASK_RUN_S.toString().formatted(task.getName());
Expand Down
2 changes: 1 addition & 1 deletion main/src/main/java/se/trixon/cric/ui/TaskListEditor.java
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public class TaskListEditor {

private EditableList<Task> mEditableList;
private final ExecutorManager mExecutorManager = ExecutorManager.getInstance();
private final Dimension mPreferredSize = SwingHelper.getUIScaledDim(740, 480);
private final Dimension mPreferredSize = SwingHelper.getUIScaledDim(800, 600);
private final TaskEditor mTaskEditor;
private final Scene mTaskEditorScene;
private final TaskManager mTaskManager = TaskManager.getInstance();
Expand Down
2 changes: 1 addition & 1 deletion packaging/snap/snap/gui/cric.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ Icon=${SNAP}/meta/gui/cric.png
Terminal=false
Categories=Development;
StartupNotify=true
StartupWMClass=se.trixon.cric.app
StartupWMClass=CRIC
7 changes: 0 additions & 7 deletions packaging/snap/snap/local/launcher

This file was deleted.

53 changes: 20 additions & 33 deletions packaging/snap/snap/snapcraft.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: cric
title: CRIC
base: core18
version: 1.0.2
base: core22
version: 'REPLACE_WITH_VERSION'
summary: A Java jlink ui - a Custom Runtime Image Creator
description: |
**CRIC** is a gui for the Java jlink command.
Expand All @@ -20,44 +20,31 @@ license: Apache-2.0

apps:
cric:
command: bin/launcher
extensions:
- gnome-3-34
command: cric/bin/cric
extensions: [gnome]
plugs:
- home
- removable-media
- network

parts:
cric:
plugin: dump
#source: https://github.com/trixon/cric/releases/download/v$SNAPCRAFT_PROJECT_VERSION/cric-$SNAPCRAFT_PROJECT_VERSION-bin.zip
source: /root/project/cric-$SNAPCRAFT_PROJECT_VERSION-bin.zip
#source: https://github.com/trixon/cric/releases/download/v$SNAPCRAFT_PROJECT_VERSION/cric-$SNAPCRAFT_PROJECT_VERSION-linux.zip
source: /root/project/cric-$SNAPCRAFT_PROJECT_VERSION-linux.zip
source-type: zip
organize:
'*' : cric

launcher:
plugin: dump
source: snap/local
organize:
'launcher': 'bin/'

apt:
plugin: nil
override-build: |
apt install openjdk-11-jdk -y
jlink:
config:
after: [cric]
plugin: nil
after: [apt]
override-build: |
rm -rf $SNAPCRAFT_PRIME/jre
jlink --no-header-files \
--no-man-pages \
--strip-debug \
--compress=1 \
--add-modules java.base,java.datatransfer,java.desktop,java.logging,java.prefs,java.sql,java.xml,jdk.jfr,jdk.unsupported,jdk.unsupported.desktop \
--output $SNAPCRAFT_PRIME/yaya/jre
strip -p --strip-unneeded $SNAPCRAFT_PRIME/jre/lib/server/libjvm.so
override-prime: |
craftctl default
sed -i 's/${HOME}\/.${APPNAME}/${SNAP_USER_COMMON}\/.cric/' /root/prime/cric/bin/cric
sed -i 's/${HOME}\/.cache\/${APPNAME}/${SNAP_USER_COMMON}\/.cache\/cric/' /root/prime/cric/bin/cric
rm -r /root/prime/cric/platform/modules/lib/i386
rm -r /root/prime/cric/platform/modules/lib/x86
rm /root/prime/cric/platform/lib/*.dll
rm /root/prime/cric/platform/lib/*.exe
lint:
ignore: [library]

0 comments on commit 647ffde

Please sign in to comment.