diff --git a/.gitignore b/.gitignore
index 0cd337029..fcbd322e5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -32,7 +32,7 @@ build/linux/libastylej*
test-bin
*.iml
.idea
-
-hardware/arduino/avr/libraries/Bridge/examples/XivelyClient/passwords.h
.DS_Store
-
+build/windows/launch4j-*
+build/windows/launcher/launch4j
+build/windows/WinAVR-*.zip
diff --git a/app/src/processing/app/Sketch.java b/app/src/processing/app/Sketch.java
index 41ba75fcf..9d7bbbbc2 100644
--- a/app/src/processing/app/Sketch.java
+++ b/app/src/processing/app/Sketch.java
@@ -2066,9 +2066,10 @@ public class Sketch {
for (int i = 0; i < c.length; i++) {
if (((c[i] >= '0') && (c[i] <= '9')) ||
((c[i] >= 'a') && (c[i] <= 'z')) ||
- ((c[i] >= 'A') && (c[i] <= 'Z'))) {
+ ((c[i] >= 'A') && (c[i] <= 'Z')) ||
+ ((i > 0) && (c[i] == '-')) ||
+ ((i > 0) && (c[i] == '.'))) {
buffer.append(c[i]);
-
} else {
buffer.append('_');
}
diff --git a/app/src/processing/app/SketchCode.java b/app/src/processing/app/SketchCode.java
index 37e63ed71..b496755ec 100644
--- a/app/src/processing/app/SketchCode.java
+++ b/app/src/processing/app/SketchCode.java
@@ -87,7 +87,7 @@ public class SketchCode {
protected void makePrettyName() {
prettyName = file.getName();
- int dot = prettyName.indexOf('.');
+ int dot = prettyName.lastIndexOf('.');
prettyName = prettyName.substring(0, dot);
}
diff --git a/build/build.xml b/build/build.xml
index 22e597392..faad33eb8 100644
--- a/build/build.xml
+++ b/build/build.xml
@@ -37,6 +37,9 @@
+
+
+
@@ -655,6 +658,7 @@
diff --git a/libraries/Esplora/examples/Beginners/EsploraJoystickMouse/EsploraJoystickMouse.ino b/libraries/Esplora/examples/Beginners/EsploraJoystickMouse/EsploraJoystickMouse.ino
index 12faf5292..9324fb5bc 100644
--- a/libraries/Esplora/examples/Beginners/EsploraJoystickMouse/EsploraJoystickMouse.ino
+++ b/libraries/Esplora/examples/Beginners/EsploraJoystickMouse/EsploraJoystickMouse.ino
@@ -17,6 +17,10 @@
Created on 22 Dec 2012
by Tom Igoe
+ Updated 8 March 2014
+ by Scott Fitzgerald
+
+ http://arduino.cc/en/Reference/EsploraReadJoystickSwitch
This example is in the public domain.
*/
@@ -41,10 +45,16 @@ void loop()
Serial.print("\tButton: "); // print a tab character and a label for the button
Serial.print(button); // print the button value
- int mouseX = map( xValue, -512, 512, 10, -10); // map the X value to a range of movement for the mouse X
- int mouseY = map( yValue, -512, 512, -10, 10); // map the Y value to a range of movement for the mouse Y
+ int mouseX = map(xValue, -512, 512, 10, -10); // map the X value to a range of movement for the mouse X
+ int mouseY = map(yValue, -512, 512, -10, 10); // map the Y value to a range of movement for the mouse Y
Mouse.move(mouseX, mouseY, 0); // move the mouse
+ if (button == 0) { // if the joystick button is pressed
+ Mouse.press(); // send a mouse click
+ } else {
+ Mouse.release(); // if it's not pressed, release the mouse button
+ }
+
delay(10); // a short delay before moving again
}