Skip to content

Commit eda6416

Browse files
authored
Merge pull request #474 from ThexXTURBOXx/master
Update dependencies (again)
2 parents ca894b3 + 9447f4e commit eda6416

File tree

9 files changed

+237
-330
lines changed

9 files changed

+237
-330
lines changed

pom.xml

Lines changed: 23 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -13,42 +13,42 @@
1313
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
1414

1515
<!-- Dependency versions -->
16-
<annotations.version>24.0.0</annotations.version>
16+
<annotations.version>24.0.1</annotations.version>
1717
<antlr4.version>4.9.3</antlr4.version>
18-
<apktool.version>2.7.0</apktool.version>
19-
<asm.version>9.4</asm.version>
18+
<apktool.version>2.8.0</apktool.version>
19+
<asm.version>9.5</asm.version>
2020
<bined.version>0.2.0</bined.version>
2121
<byteanalysis.version>1.0bcv</byteanalysis.version>
2222
<cfr.version>0.152</cfr.version>
2323
<cloning.version>1.9.12</cloning.version>
2424
<commons-cli.version>1.5.0</commons-cli.version>
25-
<commons-codec.version>1.15</commons-codec.version>
26-
<commons-compiler.version>3.1.9</commons-compiler.version>
27-
<commons-compress.version>1.22</commons-compress.version>
28-
<commons-io.version>2.11.0</commons-io.version>
25+
<commons-codec.version>1.16.0</commons-codec.version>
26+
<commons-compiler.version>3.1.10</commons-compiler.version>
27+
<commons-compress.version>1.23.0</commons-compress.version>
28+
<commons-io.version>2.13.0</commons-io.version>
2929
<commons-lang3.version>3.12.0</commons-lang3.version>
3030
<commons-text.version>1.10.0</commons-text.version>
3131
<darklaf.version>3.0.2</darklaf.version>
3232
<darklaf-extensions-rsta.version>0.4.1</darklaf-extensions-rsta.version>
33-
<decompiler-fernflower.version>6.1.2.Final</decompiler-fernflower.version>
34-
<dex2jar.version>v59</dex2jar.version>
33+
<decompiler-fernflower.version>6.2.5.Final</decompiler-fernflower.version>
34+
<dex2jar.version>v64</dex2jar.version>
3535
<fernflower.version>e0d44f4</fernflower.version>
3636
<gson.version>2.10.1</gson.version>
37-
<guava.version>31.1-jre</guava.version>
38-
<httprequest.version>2.1.0</httprequest.version>
37+
<guava.version>32.1.1-jre</guava.version>
38+
<httprequest.version>2.2.0</httprequest.version>
3939
<imgscalr-lib.version>4.2</imgscalr-lib.version>
40-
<jadx.version>1.4.5</jadx.version>
40+
<jadx.version>1.4.7</jadx.version>
4141
<jd-gui.version>1.6.6bcv</jd-gui.version>
4242
<jgraphx.version>3.4.1.3</jgraphx.version>
4343
<js.version>21.2.0</js.version>
4444
<objenesis.version>3.3</objenesis.version>
4545
<paged-data.version>0.2.0</paged-data.version>
4646
<procyon.version>0.6.0</procyon.version>
47-
<rsyntaxtextarea.version>3.3.2</rsyntaxtextarea.version>
47+
<rsyntaxtextarea.version>3.3.3</rsyntaxtextarea.version>
4848
<semantic-version.version>2.1.1</semantic-version.version>
49-
<slf4j.version>2.0.6</slf4j.version>
50-
<smali.version>403e90375e</smali.version>
51-
<safeyaml.version>1.33.0</safeyaml.version>
49+
<slf4j.version>2.0.7</slf4j.version>
50+
<smali.version>3.0.3</smali.version>
51+
<safeyaml.version>1.34.1</safeyaml.version>
5252
<treelayout.version>1.0.3</treelayout.version>
5353
<webp-imageio.version>0.2.2</webp-imageio.version>
5454
<xpp3.version>1.1.4c</xpp3.version>
@@ -277,13 +277,13 @@
277277
<version>${slf4j.version}</version>
278278
</dependency>
279279
<dependency>
280-
<groupId>com.github.iBotPeaches.smali</groupId>
280+
<groupId>com.android.tools.smali</groupId>
281281
<artifactId>smali</artifactId>
282282
<version>${smali.version}</version>
283283
</dependency>
284284
<dependency>
285-
<groupId>com.github.iBotPeaches.smali</groupId>
286-
<artifactId>baksmali</artifactId>
285+
<groupId>com.android.tools.smali</groupId>
286+
<artifactId>smali-baksmali</artifactId>
287287
<version>${smali.version}</version>
288288
</dependency>
289289
<dependency>
@@ -398,7 +398,7 @@
398398
<plugin>
399399
<groupId>org.apache.maven.plugins</groupId>
400400
<artifactId>maven-compiler-plugin</artifactId>
401-
<version>3.10.1</version>
401+
<version>3.11.0</version>
402402
<configuration>
403403
<source>${maven.compiler.source}</source>
404404
<target>${maven.compiler.target}</target>
@@ -408,15 +408,15 @@
408408
<plugin>
409409
<groupId>org.apache.maven.plugins</groupId>
410410
<artifactId>maven-javadoc-plugin</artifactId>
411-
<version>3.4.0</version>
411+
<version>3.5.0</version>
412412
<configuration>
413413
<source>${maven.compiler.source}</source>
414414
</configuration>
415415
</plugin>
416416
<plugin>
417417
<groupId>org.apache.maven.plugins</groupId>
418418
<artifactId>maven-shade-plugin</artifactId>
419-
<version>3.3.0</version>
419+
<version>3.4.1</version>
420420
<executions>
421421
<execution>
422422
<phase>package</phase>
@@ -437,6 +437,7 @@
437437
<exclude>META-INF/*LICENSE*</exclude>
438438
<exclude>META-INF/*NOTICE*</exclude>
439439
<exclude>META-INF/MANIFEST.MF</exclude>
440+
<exclude>LICENSE</exclude>
440441
</excludes>
441442
</filter>
442443
<!-- Ignore all ASM-related files from d2j-external but MCTLE fix -->

src/main/java/the/bytecode/club/bytecodeviewer/gui/MainViewerGUI.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ public class MainViewerGUI extends JFrame
116116
public final SearchBoxPane searchBoxPane = new SearchBoxPane();
117117
public JSplitPane splitPane1;
118118
public JSplitPane splitPane2;
119-
119+
120120
//the root menu bar
121121
public final JMenuBar rootMenu = new JMenuBar();
122122

@@ -351,16 +351,20 @@ public MainViewerGUI()
351351
searchBoxPane.setPreferredSize(new Dimension(200, 50));
352352
searchBoxPane.setMinimumSize(new Dimension(200, 50));
353353
searchBoxPane.setMaximumSize(new Dimension(200, 2147483647));
354-
354+
355+
workPane.setPreferredSize(new Dimension(1500, 1000));
356+
355357
splitPane1 = new JSplitPane(JSplitPane.VERTICAL_SPLIT, resourcePane, searchBoxPane);
356358
splitPane2 = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, splitPane1, workPane);
359+
357360
getContentPane().add(splitPane2);
358361
splitPane2.setResizeWeight(0.05);
359362
splitPane1.setResizeWeight(0.5);
360363

361364
uiComponents.add(resourcePane);
362365
uiComponents.add(searchBoxPane);
363366
uiComponents.add(workPane);
367+
// uiComponents.add(hierarchy);
364368

365369
viewPane1.setDefault();
366370
viewPane2.setDefault();

src/main/java/the/bytecode/club/bytecodeviewer/gui/components/SearchableRSyntaxTextArea.java

Lines changed: 69 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
import java.awt.Font;
66
import java.awt.event.InputEvent;
77
import java.awt.event.KeyEvent;
8+
import java.awt.event.MouseWheelEvent;
89
import java.awt.event.MouseWheelListener;
910
import javax.swing.JButton;
1011
import javax.swing.JCheckBox;
@@ -13,6 +14,7 @@
1314
import javax.swing.JTextField;
1415
import javax.swing.SwingUtilities;
1516
import javax.swing.text.BadLocationException;
17+
1618
import org.fife.ui.rsyntaxtextarea.RSyntaxTextArea;
1719
import org.fife.ui.rtextarea.RTextScrollPane;
1820
import the.bytecode.club.bytecodeviewer.BytecodeViewer;
@@ -50,9 +52,9 @@
5052
* @author Konloch
5153
* @since 6/25/2021
5254
*/
53-
public class SearchableRSyntaxTextArea extends RSyntaxTextArea
54-
{
55-
private final RTextScrollPane scrollPane = new RTextScrollPane(this);
55+
public class SearchableRSyntaxTextArea extends RSyntaxTextArea {
56+
57+
private RTextScrollPane scrollPane = new RTextScrollPane(this);
5658
private final JPanel searchPanel = new JPanel(new BorderLayout());
5759
private final JTextField searchInput = new JTextField();
5860
private final JCheckBox caseSensitiveSearch = new TranslatedJCheckBox("Match case", TranslatedComponents.MATCH_CASE);
@@ -62,30 +64,26 @@ public class SearchableRSyntaxTextArea extends RSyntaxTextArea
6264
private final Color blackScrollBackground = new Color(0x232323);
6365
private final Color blackScrollForeground = new Color(0x575859);
6466
private Runnable onCtrlS;
65-
66-
public SearchableRSyntaxTextArea()
67-
{
68-
if(Configuration.lafTheme == LAFTheme.HIGH_CONTRAST_DARK)
69-
{
67+
68+
public SearchableRSyntaxTextArea() {
69+
if (Configuration.lafTheme == LAFTheme.HIGH_CONTRAST_DARK) {
7070
//this fixes the white border on the jScrollBar panes
7171
scrollPane.getHorizontalScrollBar().setBackground(blackScrollBackground);
7272
scrollPane.getHorizontalScrollBar().setForeground(blackScrollForeground);
7373
scrollPane.getVerticalScrollBar().setBackground(blackScrollBackground);
7474
scrollPane.getVerticalScrollBar().setForeground(blackScrollForeground);
75-
}
76-
else if(Configuration.lafTheme.isDark())
77-
{
75+
} else if (Configuration.lafTheme.isDark()) {
7876
//this fixes the white border on the jScrollBar panes
7977
scrollPane.getHorizontalScrollBar().setBackground(darkScrollBackground);
8078
scrollPane.getHorizontalScrollBar().setForeground(darkScrollForeground);
8179
scrollPane.getVerticalScrollBar().setBackground(darkScrollBackground);
8280
scrollPane.getVerticalScrollBar().setForeground(darkScrollForeground);
8381
}
84-
82+
8583
setAntiAliasingEnabled(true);
86-
84+
8785
scrollPane.setColumnHeaderView(searchPanel);
88-
86+
8987
JButton searchNext = new JButton();
9088
JButton searchPrev = new JButton();
9189
JPanel buttonPane = new JPanel(new BorderLayout());
@@ -96,133 +94,121 @@ else if(Configuration.lafTheme.isDark())
9694
searchPanel.add(buttonPane, BorderLayout.WEST);
9795
searchPanel.add(searchInput, BorderLayout.CENTER);
9896
searchPanel.add(caseSensitiveSearch, BorderLayout.EAST);
99-
97+
10098
searchNext.addActionListener(arg0 -> search(searchInput.getText(), true, caseSensitiveSearch.isSelected()));
10199
searchPrev.addActionListener(arg0 -> search(searchInput.getText(), false, caseSensitiveSearch.isSelected()));
102-
100+
103101
searchInput.addKeyListener(new ReleaseKeyListener(keyEvent ->
104102
{
105103
if (keyEvent.getKeyCode() == KeyEvent.VK_ENTER)
106104
search(searchInput.getText(), true, caseSensitiveSearch.isSelected());
107105
}));
108-
106+
109107
addKeyListener(new PressKeyListener(keyEvent ->
110108
{
111109
if ((keyEvent.getKeyCode() == KeyEvent.VK_F) && ((keyEvent.getModifiersEx() & KeyEvent.CTRL_DOWN_MASK) != 0))
112110
searchInput.requestFocus();
113-
114-
if (onCtrlS != null && (keyEvent.getKeyCode() == KeyEvent.VK_S) && ((keyEvent.getModifiersEx() & KeyEvent.CTRL_DOWN_MASK) != 0))
115-
{
111+
112+
if (onCtrlS != null && (keyEvent.getKeyCode() == KeyEvent.VK_S) && ((keyEvent.getModifiersEx() & KeyEvent.CTRL_DOWN_MASK) != 0)) {
116113
onCtrlS.run();
117114
return;
118115
}
119-
116+
120117
GlobalHotKeys.keyPressed(keyEvent);
121118
}));
122-
119+
123120
final Font newFont = getFont().deriveFont((float) BytecodeViewer.viewer.getFontSize());
124-
121+
125122
//set number-bar font
126123
setFont(newFont);
127-
128-
SwingUtilities.invokeLater(()-> {
124+
125+
SwingUtilities.invokeLater(() -> {
129126
//attach CTRL + Mouse Wheel Zoom
130127
attachCtrlMouseWheelZoom();
131-
128+
132129
//set text font
133130
setFont(newFont);
134131
});
135-
132+
136133
}
137-
138-
public void search(String search, boolean forwardSearchDirection, boolean caseSensitiveSearch)
139-
{
134+
135+
public void search(String search, boolean forwardSearchDirection, boolean caseSensitiveSearch) {
140136
JTextAreaUtils.search(this, search, forwardSearchDirection, caseSensitiveSearch);
141137
}
142-
143-
public void highlight(String pattern, boolean caseSensitiveSearch)
144-
{
138+
139+
public void highlight(String pattern, boolean caseSensitiveSearch) {
145140
JTextAreaUtils.highlight(this, pattern, caseSensitiveSearch);
146141
}
147-
148-
public void attachCtrlMouseWheelZoom()
149-
{
150-
//get the existing scroll event
151-
MouseWheelListener ogListener = scrollPane.getMouseWheelListeners().length > 0 ?
152-
scrollPane.getMouseWheelListeners()[0] : null;
153-
154-
//remove the existing event
155-
if(ogListener != null)
156-
scrollPane.removeMouseWheelListener(ogListener);
157-
158-
//add a new event
159-
scrollPane.addMouseWheelListener(e ->
160-
{
161-
if (getText().isEmpty())
162-
return;
163-
164-
if ((e.getModifiersEx() & InputEvent.CTRL_DOWN_MASK) != 0)
165-
{
142+
143+
public void attachCtrlMouseWheelZoom() {
144+
scrollPane.addMouseWheelListener(e -> {
145+
if (getText().isEmpty()) return;
146+
if ((e.getModifiersEx() & InputEvent.CTRL_DOWN_MASK) != 0) {
166147
Font font = getFont();
167148
int size = font.getSize();
168-
169-
if (e.getWheelRotation() > 0) //Up
149+
if (e.getWheelRotation() > 0)
170150
setFont(new Font(font.getName(), font.getStyle(), --size >= 2 ? --size : 2));
171-
else //Down
151+
else
172152
setFont(new Font(font.getName(), font.getStyle(), ++size));
173-
153+
174154
e.consume();
175155
}
176-
else if(ogListener != null)
177-
{
178-
ogListener.mouseWheelMoved(e);
179-
}
180156
});
157+
158+
scrollPane = new RTextScrollPane() {
159+
@Override
160+
protected void processMouseWheelEvent(MouseWheelEvent event) {
161+
if (!isWheelScrollingEnabled()) {
162+
if (getParent() != null) {
163+
getParent().dispatchEvent(SwingUtilities.convertMouseEvent(this, event, getParent()));
164+
return;
165+
}
166+
}
167+
168+
super.processMouseWheelEvent(event);
169+
}
170+
};
171+
172+
scrollPane.setWheelScrollingEnabled(false);
181173
}
182-
174+
183175
public String getLineText(int line) {
184176
try {
185177
if (line < getLineCount()) {
186178
int start = getLineStartOffset(line);
187179
int end = getLineEndOffset(line);
188180
return getText(start, end - start).trim();
189181
}
190-
} catch (BadLocationException ignored) { }
182+
} catch (BadLocationException ignored) {
183+
}
191184
return "";
192185
}
193-
194-
public void setOnCtrlS(Runnable onCtrlS)
195-
{
186+
187+
public void setOnCtrlS(Runnable onCtrlS) {
196188
this.onCtrlS = onCtrlS;
197189
}
198-
199-
public RTextScrollPane getScrollPane()
200-
{
190+
191+
public RTextScrollPane getScrollPane() {
201192
return scrollPane;
202193
}
203-
204-
public JPanel getSearchPanel()
205-
{
194+
195+
public JPanel getSearchPanel() {
206196
return searchPanel;
207197
}
208-
209-
public JTextField getSearchInput()
210-
{
198+
199+
public JTextField getSearchInput() {
211200
return searchInput;
212201
}
213-
214-
public JCheckBox getCaseSensitiveSearch()
215-
{
202+
203+
public JCheckBox getCaseSensitiveSearch() {
216204
return caseSensitiveSearch;
217205
}
218-
219-
public JLabel getTitleHeader()
220-
{
206+
207+
public JLabel getTitleHeader() {
221208
return titleHeader;
222209
}
223-
224-
public Runnable getOnCtrlS()
225-
{
210+
211+
public Runnable getOnCtrlS() {
226212
return onCtrlS;
227213
}
228214
}

0 commit comments

Comments
 (0)