FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

split welcome, add menu option for debug · tiwawan/processing@421dcdf · GitHub

Repository navigation

Commit 421dcdf

Browse files
committed
split welcome, add menu option for debug
1 parent 77c7f5b commit 421dcdf

2 files changed

Lines changed: 10 additions & 26 deletions

File tree

‎app/src/processing/app/ui/WebFrame.java‎

Lines changed: 1 addition & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222
package processing.app.ui;
2323

2424
import java.awt.Dimension;
25-
import java.awt.EventQueue;
2625
import java.awt.event.ActionEvent;
2726
import java.awt.event.ActionListener;
2827
import java.io.File;
@@ -38,29 +37,6 @@
3837

3938
public class WebFrame extends JFrame {
4039

41-
static public void main(String[] args) {
42-
Base.initPlatform();
43-
44-
//File indexFile = Base.getLibFile("welcome/index.html");
45-
final File indexFile = new File("../build/shared/lib/welcome/index.html");
46-
47-
EventQueue.invokeLater(new Runnable() {
48-
public void run() {
49-
new WebFrame(indexFile, 400) {
50-
public void handleSubmit(StringDict dict) {
51-
dict.print();
52-
handleClose();
53-
}
54-
55-
public void handleClose() {
56-
System.exit(0);
57-
}
58-
};
59-
}
60-
});
61-
}
62-
63-
6440
public WebFrame(File file, int width) {
6541
//setDefaultCloseOperation(javax.swing.JFrame.EXIT_ON_CLOSE);
6642

@@ -89,7 +65,6 @@ public void actionPerformed(ActionEvent e) {
8965
}
9066

9167
textPane.addHyperlinkListener(new HyperlinkListener() {
92-
9368
@Override
9469
public void hyperlinkUpdate(HyperlinkEvent e) {
9570
//System.out.println(e);
@@ -115,7 +90,7 @@ public void hyperlinkUpdate(HyperlinkEvent e) {
11590
});
11691
pack();
11792
setLocationRelativeTo(null);
118-
setVisible(true);
93+
//setVisible(true);
11994
}
12095

12196

‎java/src/processing/mode/java/JavaEditor.java‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
import processing.app.ui.EditorState;
4040
import processing.app.ui.EditorToolbar;
4141
import processing.app.ui.Toolkit;
42+
import processing.app.ui.Welcome;
4243
import processing.mode.java.debug.LineBreakpoint;
4344
import processing.mode.java.debug.LineHighlight;
4445
import processing.mode.java.debug.LineID;
@@ -349,6 +350,14 @@ public void actionPerformed(ActionEvent e) {
349350
menu.add(item);
350351
}
351352

353+
item = new JMenuItem("Welcome to Processing 3");
354+
item.addActionListener(new ActionListener() {
355+
public void actionPerformed(ActionEvent e) {
356+
new Welcome();
357+
}
358+
});
359+
menu.add(item);
360+
352361
item = new JMenuItem(Language.text("menu.help.environment"));
353362
item.addActionListener(new ActionListener() {
354363
public void actionPerformed(ActionEvent e) {

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL