mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
switching to screenWidth/Height instead of screenW/H as per casey's suggestion
This commit is contained in:
@@ -273,13 +273,7 @@ public class PApplet extends Applet
|
||||
* not all instances of PApplet will necessarily be started on a screen of
|
||||
* the same size.
|
||||
*/
|
||||
static public int screenW;
|
||||
static public int screenH;
|
||||
static {
|
||||
Dimension size = Toolkit.getDefaultToolkit().getScreenSize();
|
||||
screenW = size.width;
|
||||
screenH = size.height;
|
||||
}
|
||||
public int screenWidth, screenHeight;
|
||||
|
||||
/**
|
||||
* Use screenW and screenH instead.
|
||||
@@ -670,6 +664,10 @@ public class PApplet extends Applet
|
||||
public void init() {
|
||||
// println("Calling init()");
|
||||
|
||||
Dimension screen = Toolkit.getDefaultToolkit().getScreenSize();
|
||||
screenWidth = screen.width;
|
||||
screenHeight = screen.height;
|
||||
|
||||
// send tab keys through to the PApplet
|
||||
setFocusTraversalKeysEnabled(false);
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
0179 core
|
||||
X screenWidth/Height instead of screenW/H
|
||||
|
||||
|
||||
big ones
|
||||
|
||||
Reference in New Issue
Block a user