Skip to content

Commit df15e84

Browse files
author
Joe Wegner
committed
Fix Codacy checks
1 parent 380ebf7 commit df15e84

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

app/src/cc/arduino/contributions/ContributionsSelfCheck.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
import cc.arduino.contributions.packages.filters.UpdatablePlatformPredicate;
3737
import cc.arduino.view.NotificationPopup;
3838
import com.sun.javafx.binding.Logging;
39+
import org.apache.logging.log4j.LogManager;
3940
import processing.app.*;
4041

4142
import javax.swing.*;
@@ -178,7 +179,7 @@ private void goToManager(String link) {
178179
((UpdatableBoardsLibsFakeURLsHandler) hyperlinkListener).openBoardLibManager(new URL(link));
179180
}
180181
catch (Exception e){
181-
Logging.getLogger().warning("Exception while attempting to go to board manager", e);
182+
LogManager.getLogger(ContributionsSelfCheck.class).warn("Exception while attempting to go to board manager", e);
182183
}
183184
}
184185
// callback for boards button

app/src/cc/arduino/view/NotificationPopup.java

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,15 @@
5858
import static processing.app.I18n.tr;
5959

6060
public class NotificationPopup extends JDialog {
61+
private Timer autoCloseTimer = new Timer(false);
62+
private boolean autoClose = true;
63+
private OptionalButtonCallbacks optionalButtonCallbacks;
64+
6165
public interface OptionalButtonCallbacks {
6266
void onOptionalButton1Callback();
6367
void onOptionalButton2Callback();
6468
}
6569

66-
private Timer autoCloseTimer = new Timer(false);
67-
private boolean autoClose = true;
68-
private OptionalButtonCallbacks optionalButtonCallbacks;
69-
7070
public NotificationPopup(Frame parent, HyperlinkListener hyperlinkListener,
7171
String message) {
7272
this(parent, hyperlinkListener, message, true, null, null, null);
@@ -153,9 +153,11 @@ public void mouseClicked(MouseEvent e) {
153153

154154
KeyListener button2Key = new KeyListener() {
155155
public void keyTyped(KeyEvent e) {
156+
// do nothing here, wait until the key is released
156157
}
157158

158159
public void keyPressed(KeyEvent e) {
160+
// do nothing here, wait until the key is released
159161
}
160162

161163
public void keyReleased(KeyEvent e) {

0 commit comments

Comments
 (0)