1
0
mirror of https://github.com/arduino/Arduino.git synced 2025-01-18 07:52:14 +01:00

Changing Windows file association code from .pde to .ino.

It doesn't seem to work properly on my Windows Vista machine, but neither does the .pde association for Processing.
This commit is contained in:
David Mellis 2010-11-06 16:38:23 -04:00
parent 1240b5d911
commit 1fbffaf7be

View File

@ -44,8 +44,8 @@ public class Platform extends processing.app.Platform {
static final String openCommand = static final String openCommand =
System.getProperty("user.dir").replace('/', '\\') + System.getProperty("user.dir").replace('/', '\\') +
"\\processing.exe \"%1\""; "\\arduino.exe \"%1\"";
static final String DOC = "Processing.Document"; static final String DOC = "Arduino.Document";
public void init(Base base) { public void init(Base base) {
super.init(base); super.init(base);
@ -86,13 +86,13 @@ public class Platform extends processing.app.Platform {
*/ */
protected void setAssociations() throws UnsupportedEncodingException { protected void setAssociations() throws UnsupportedEncodingException {
if (Registry.createKey(REGISTRY_ROOT_KEY.CLASSES_ROOT, if (Registry.createKey(REGISTRY_ROOT_KEY.CLASSES_ROOT,
"", ".pde") && "", ".ino") &&
Registry.setStringValue(REGISTRY_ROOT_KEY.CLASSES_ROOT, Registry.setStringValue(REGISTRY_ROOT_KEY.CLASSES_ROOT,
".pde", "", DOC) && ".ino", "", DOC) &&
Registry.createKey(REGISTRY_ROOT_KEY.CLASSES_ROOT, "", DOC) && Registry.createKey(REGISTRY_ROOT_KEY.CLASSES_ROOT, "", DOC) &&
Registry.setStringValue(REGISTRY_ROOT_KEY.CLASSES_ROOT, DOC, "", Registry.setStringValue(REGISTRY_ROOT_KEY.CLASSES_ROOT, DOC, "",
"Processing Source Code") && "Arduino Source Code") &&
Registry.createKey(REGISTRY_ROOT_KEY.CLASSES_ROOT, Registry.createKey(REGISTRY_ROOT_KEY.CLASSES_ROOT,
DOC, "shell") && DOC, "shell") &&