mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-07-11 16:58:51 +00:00
cleanup
This commit is contained in:
@@ -54,17 +54,12 @@ import com.jpexs.decompiler.flash.abc.usages.MethodParamsMultinameUsage;
|
||||
import com.jpexs.decompiler.flash.abc.usages.MethodReturnTypeMultinameUsage;
|
||||
import com.jpexs.decompiler.flash.abc.usages.MultinameUsage;
|
||||
import com.jpexs.decompiler.flash.abc.usages.TypeNameMultinameUsage;
|
||||
import com.jpexs.decompiler.flash.configuration.Configuration;
|
||||
import com.jpexs.decompiler.flash.exporters.modes.ScriptExportMode;
|
||||
import com.jpexs.decompiler.flash.helpers.GraphTextWriter;
|
||||
import com.jpexs.decompiler.flash.helpers.HilightedTextWriter;
|
||||
import com.jpexs.decompiler.flash.helpers.SWFDecompilerPlugin;
|
||||
import com.jpexs.decompiler.flash.helpers.collections.MyEntry;
|
||||
import com.jpexs.decompiler.flash.tags.ABCContainerTag;
|
||||
import com.jpexs.decompiler.flash.tags.SymbolClassTag;
|
||||
import com.jpexs.decompiler.flash.tags.Tag;
|
||||
import com.jpexs.decompiler.graph.CompilationException;
|
||||
import com.jpexs.decompiler.graph.TranslateStack;
|
||||
import com.jpexs.helpers.utf8.Utf8PrintWriter;
|
||||
import java.io.IOException;
|
||||
import java.io.OutputStream;
|
||||
|
||||
@@ -37,6 +37,7 @@ import java.awt.LinearGradientPaint;
|
||||
import java.awt.MultipleGradientPaint;
|
||||
import java.awt.Paint;
|
||||
import java.awt.RadialGradientPaint;
|
||||
import java.awt.Shape;
|
||||
import java.awt.Stroke;
|
||||
import java.awt.TexturePaint;
|
||||
import java.awt.geom.AffineTransform;
|
||||
@@ -44,7 +45,6 @@ import java.awt.geom.GeneralPath;
|
||||
import java.awt.geom.NoninvertibleTransformException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.awt.Shape;
|
||||
|
||||
/**
|
||||
*
|
||||
@@ -77,17 +77,17 @@ public class BitmapExporter extends ShapeExporterBase {
|
||||
/**
|
||||
* the AffineTransform used to transform the shape before stroking.
|
||||
*/
|
||||
private AffineTransform transform;
|
||||
private final AffineTransform transform;
|
||||
/**
|
||||
* The inverse of {@link #transform}, used to transform back after
|
||||
* stroking.
|
||||
*/
|
||||
private AffineTransform inverse;
|
||||
private final AffineTransform inverse;
|
||||
|
||||
/**
|
||||
* Our base stroke.
|
||||
*/
|
||||
private Stroke stroke;
|
||||
private final Stroke stroke;
|
||||
|
||||
/**
|
||||
* Creates a TransformedStroke based on another Stroke and an
|
||||
@@ -106,7 +106,8 @@ public class BitmapExporter extends ShapeExporterBase {
|
||||
* This outline is distorted by our AffineTransform relative to the
|
||||
* outline which would be given by the base stroke, but only in terms of
|
||||
* scaling (i.e. thickness of the lines), as translation and rotation
|
||||
* are undone after the stroking.
|
||||
* are undone after the stro @Override
|
||||
king.
|
||||
*/
|
||||
public Shape createStrokedShape(Shape s) {
|
||||
Shape sTrans = transform.createTransformedShape(s);
|
||||
|
||||
@@ -18,8 +18,6 @@ package com.jpexs.decompiler.flash.types;
|
||||
|
||||
import com.jpexs.decompiler.flash.types.annotations.Internal;
|
||||
import com.jpexs.decompiler.flash.types.annotations.SWFType;
|
||||
import java.awt.Color;
|
||||
import java.awt.color.ColorSpace;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
|
||||
@@ -46,7 +46,6 @@ import java.awt.event.ActionEvent;
|
||||
import java.awt.event.ActionListener;
|
||||
import java.awt.event.WindowAdapter;
|
||||
import java.awt.event.WindowEvent;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import javax.swing.JButton;
|
||||
|
||||
@@ -37,19 +37,11 @@ import java.awt.BasicStroke;
|
||||
import java.awt.BorderLayout;
|
||||
import java.awt.Color;
|
||||
import java.awt.Cursor;
|
||||
import java.awt.FlowLayout;
|
||||
import java.awt.Graphics;
|
||||
import java.awt.Graphics2D;
|
||||
import java.awt.Image;
|
||||
import java.awt.Point;
|
||||
import java.awt.Rectangle;
|
||||
import java.awt.Shape;
|
||||
import java.awt.Toolkit;
|
||||
import java.awt.datatransfer.Clipboard;
|
||||
import java.awt.datatransfer.ClipboardOwner;
|
||||
import java.awt.datatransfer.DataFlavor;
|
||||
import java.awt.datatransfer.Transferable;
|
||||
import java.awt.datatransfer.UnsupportedFlavorException;
|
||||
import java.awt.event.ActionEvent;
|
||||
import java.awt.event.ActionListener;
|
||||
import java.awt.event.MouseAdapter;
|
||||
@@ -61,7 +53,6 @@ import java.awt.geom.AffineTransform;
|
||||
import java.awt.image.BufferedImage;
|
||||
import java.io.ByteArrayInputStream;
|
||||
import java.io.IOException;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
@@ -72,8 +63,6 @@ import java.util.logging.Logger;
|
||||
import javax.imageio.ImageIO;
|
||||
import javax.sound.sampled.LineUnavailableException;
|
||||
import javax.sound.sampled.UnsupportedAudioFileException;
|
||||
import javax.swing.JButton;
|
||||
import javax.swing.JColorChooser;
|
||||
import javax.swing.JLabel;
|
||||
import javax.swing.JPanel;
|
||||
|
||||
@@ -423,6 +412,7 @@ public final class ImagePanel extends JPanel implements ActionListener, MediaDis
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public void zoomToFit() {
|
||||
if (timelined instanceof BoundedTag) {
|
||||
RECT bounds = ((BoundedTag) timelined).getRect(new HashSet<BoundedTag>());
|
||||
|
||||
@@ -67,7 +67,6 @@ import java.awt.BorderLayout;
|
||||
import java.awt.CardLayout;
|
||||
import java.awt.Color;
|
||||
import java.awt.Component;
|
||||
import java.awt.FlowLayout;
|
||||
import java.awt.Insets;
|
||||
import java.awt.event.ActionEvent;
|
||||
import java.awt.event.ActionListener;
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
package com.jpexs.decompiler.flash.gui.player;
|
||||
|
||||
import com.jpexs.decompiler.flash.gui.AppStrings;
|
||||
import com.jpexs.decompiler.flash.gui.ImagePanel;
|
||||
import com.jpexs.decompiler.flash.gui.View;
|
||||
import java.awt.BorderLayout;
|
||||
import java.awt.Color;
|
||||
@@ -73,13 +72,13 @@ public class PlayerControls extends JPanel implements ActionListener {
|
||||
private static final Icon pauseIcon = View.getIcon("pause16");
|
||||
private static final Icon playIcon = View.getIcon("play16");
|
||||
|
||||
private JLabel percentLabel = new JLabel("100%");
|
||||
private JPanel zoomPanel;
|
||||
private JPanel graphicControls;
|
||||
private JPanel playbackControls;
|
||||
private final JLabel percentLabel = new JLabel("100%");
|
||||
private final JPanel zoomPanel;
|
||||
private final JPanel graphicControls;
|
||||
private final JPanel playbackControls;
|
||||
private double realZoom = 1.0;
|
||||
|
||||
private JButton zoomFitButton;
|
||||
private final JButton zoomFitButton;
|
||||
|
||||
public static final int ZOOM_DECADE_STEPS = 10;
|
||||
public static final double ZOOM_MULTIPLIER = Math.pow(10, 1.0 / ZOOM_DECADE_STEPS);
|
||||
@@ -335,6 +334,7 @@ public class PlayerControls extends JPanel implements ActionListener {
|
||||
this.img = img;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object getTransferData(DataFlavor flavor)
|
||||
throws UnsupportedFlavorException, IOException {
|
||||
if (flavor.equals(DataFlavor.imageFlavor) && img != null) {
|
||||
|
||||
Reference in New Issue
Block a user