Skip to content
This repository has been archived by the owner on Apr 15, 2024. It is now read-only.

Commit

Permalink
refactor rm unused imports
Browse files Browse the repository at this point in the history
  • Loading branch information
exoad committed Jun 1, 2023
1 parent cfbc4db commit 8717969
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 14 deletions.
3 changes: 1 addition & 2 deletions pkg/src/com/jackmeng/prismix/jm_Prismix.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

package com.jackmeng.prismix;

import java.lang.management.ManagementFactory;
import java.util.HashMap;
import java.util.Map;
import java.util.TimerTask;
Expand Down Expand Up @@ -46,7 +45,7 @@ public class jm_Prismix
}
}

public static void main(String... args) // !! fuck pre Java 11 users, fuck their dumb shit
public static void main(String... x) // !! fuck pre Java 11 users, fuck their dumb shit
{
_1const.add(ux.ux, 10L);
stl_Wrap< stl_In > reader = new stl_Wrap<>(new stl_In(System.in));
Expand Down
6 changes: 0 additions & 6 deletions pkg/src/com/jackmeng/prismix/ux/gui_Container.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,9 @@

package com.jackmeng.prismix.ux;

import javax.management.MXBean;
import javax.management.RuntimeMBeanException;
import javax.swing.*;

import com.jackmeng.prismix._1const;
import com.jackmeng.prismix.jm_Prismix;
import com.jackmeng.prismix.use_Maker;
import com.jackmeng.prismix.stl.extend_stl_Colors;
import com.jackmeng.stl.stl_Colors;
import com.jackmeng.stl.stl_Function;
Expand All @@ -18,8 +14,6 @@
import static com.jackmeng.prismix._1const.*;

import java.awt.*;
import java.lang.management.ManagementFactory;
import java.lang.management.RuntimeMXBean;

/**
* Represents the inner shell of the content of the GUI. The parent is the ux
Expand Down
2 changes: 1 addition & 1 deletion pkg/src/com/jackmeng/prismix/ux/ui_ColorPicker.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
import com.jackmeng.prismix._1const;
import com.jackmeng.prismix.use_Maker;
import com.jackmeng.prismix.stl.extend_stl_Colors;
import com.jackmeng.stl.stl_Callback;
import com.jackmeng.stl.stl_Listener;
import com.jackmeng.stl.stl_Struct;
import com.jackmeng.stl.stl_Struct.struct_Pair;
Expand Down Expand Up @@ -40,6 +39,7 @@ public static final class CPick_GenericDisp
public CPick_GenericDisp()
{
setFocusable(true);
setBorder(new ui_RoundBorder(10));
}

@Override public void paintComponent(Graphics g)
Expand Down
31 changes: 31 additions & 0 deletions pkg/src/com/jackmeng/prismix/ux/ui_RoundBorder.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// Software created by Jack Meng (AKA exoad). Licensed by the included "LICENSE" file. If this file is not found, the project is fully copyrighted.

package com.jackmeng.prismix.ux;

import javax.swing.border.Border;
import java.awt.*;

public class ui_RoundBorder implements Border
{
private int radius;

ui_RoundBorder(int radius)
{
this.radius = radius;
}

@Override public Insets getBorderInsets(Component c)
{
return new Insets(this.radius + 1, this.radius + 1, this.radius + 2, this.radius);
}

@Override public boolean isBorderOpaque()
{
return true;
}

@Override public void paintBorder(Component c, Graphics g, int x, int y, int width, int height)
{
g.drawRoundRect(x, y, width - 1, height - 1, radius, radius);
}
}
5 changes: 0 additions & 5 deletions pkg/src/com/jackmeng/prismix/ux/ux.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,6 @@
import java.awt.event.AWTEventListener;
import java.util.Arrays;
import java.util.TimerTask;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.CompletionService;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.Future;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicReference;

Expand Down

0 comments on commit 8717969

Please sign in to comment.