mirror of
https://github.com/arduino/Arduino.git
synced 2024-11-28 09:24:14 +01:00
Removed bundled offline docs
The offline documentation is hard to update and gets outdated very quickly. Fix #8860
This commit is contained in:
parent
eb1e2ca235
commit
89eba8cf61
@ -2169,60 +2169,6 @@ public class Base {
|
||||
// .................................................................
|
||||
|
||||
|
||||
static public void showReference(String filename) {
|
||||
showReference("reference/www.arduino.cc/en", filename);
|
||||
}
|
||||
|
||||
static public void showReference(String prefix, String filename) {
|
||||
File referenceFolder = getContentFile(prefix);
|
||||
File referenceFile = new File(referenceFolder, filename);
|
||||
if (!referenceFile.exists())
|
||||
referenceFile = new File(referenceFolder, filename + ".html");
|
||||
|
||||
if(referenceFile.exists()){
|
||||
openURL(referenceFile.getAbsolutePath());
|
||||
}else{
|
||||
showWarning(tr("Problem Opening URL"), format(tr("Could not open the URL\n{0}"), referenceFile), null);
|
||||
}
|
||||
}
|
||||
|
||||
public static void showEdisonGettingStarted() {
|
||||
showReference("reference/Edison_help_files", "ArduinoIDE_guide_edison");
|
||||
}
|
||||
|
||||
static public void showArduinoGettingStarted() {
|
||||
if (OSUtils.isMacOS()) {
|
||||
showReference("Guide/MacOSX");
|
||||
} else if (OSUtils.isWindows()) {
|
||||
showReference("Guide/Windows");
|
||||
} else {
|
||||
openURL("http://www.arduino.cc/playground/Learning/Linux");
|
||||
}
|
||||
}
|
||||
|
||||
static public void showReference() {
|
||||
showReference("Reference/HomePage");
|
||||
}
|
||||
|
||||
|
||||
static public void showEnvironment() {
|
||||
showReference("Guide/Environment");
|
||||
}
|
||||
|
||||
|
||||
static public void showTroubleshooting() {
|
||||
showReference("Guide/Troubleshooting");
|
||||
}
|
||||
|
||||
|
||||
static public void showFAQ() {
|
||||
showReference("Main/FAQ");
|
||||
}
|
||||
|
||||
|
||||
// .................................................................
|
||||
|
||||
|
||||
/**
|
||||
* "No cookie for you" type messages. Nothing fatal or all that
|
||||
* much of a bummer, but something to notify the user about.
|
||||
|
@ -46,9 +46,11 @@ import java.io.File;
|
||||
import java.io.FileFilter;
|
||||
import java.io.FilenameFilter;
|
||||
import java.io.IOException;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.ConnectException;
|
||||
import java.net.URL;
|
||||
import java.net.URLClassLoader;
|
||||
import java.net.URLEncoder;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
@ -1134,29 +1136,29 @@ public class Editor extends JFrame implements RunnerListener {
|
||||
menu.setMnemonic(KeyEvent.VK_H);
|
||||
|
||||
JMenuItem item = new JMenuItem(tr("Getting Started"));
|
||||
item.addActionListener(event -> Base.showArduinoGettingStarted());
|
||||
item.addActionListener(event -> Base.openURL("https://www.arduino.cc/en/Guide"));
|
||||
menu.add(item);
|
||||
|
||||
item = new JMenuItem(tr("Environment"));
|
||||
item.addActionListener(event -> Base.showEnvironment());
|
||||
item.addActionListener(event -> Base.openURL("https://www.arduino.cc/en/Guide/Environment"));
|
||||
menu.add(item);
|
||||
|
||||
item = new JMenuItem(tr("Troubleshooting"));
|
||||
item.addActionListener(event -> Base.showTroubleshooting());
|
||||
item.addActionListener(event -> Base.openURL("https://support.arduino.cc/hc/en-us"));
|
||||
menu.add(item);
|
||||
|
||||
item = new JMenuItem(tr("Reference"));
|
||||
item.addActionListener(event -> Base.showReference());
|
||||
item.addActionListener(event -> Base.openURL("https://www.arduino.cc/reference/en/"));
|
||||
menu.add(item);
|
||||
|
||||
menu.addSeparator();
|
||||
|
||||
item = newJMenuItemShift(tr("Find in Reference"), 'F');
|
||||
item.addActionListener(event -> handleFindReference(event));
|
||||
item.addActionListener(event -> handleFindReference(getCurrentTab().getCurrentKeyword()));
|
||||
menu.add(item);
|
||||
|
||||
item = new JMenuItem(tr("Frequently Asked Questions"));
|
||||
item.addActionListener(event -> Base.showFAQ());
|
||||
item.addActionListener(event -> Base.openURL("https://support.arduino.cc/hc/en-us"));
|
||||
menu.add(item);
|
||||
|
||||
item = new JMenuItem(tr("Visit Arduino.cc"));
|
||||
@ -1553,20 +1555,25 @@ public class Editor extends JFrame implements RunnerListener {
|
||||
tabs.remove(index);
|
||||
}
|
||||
|
||||
|
||||
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
||||
|
||||
void handleFindReference(ActionEvent e) {
|
||||
String text = getCurrentTab().getCurrentKeyword();
|
||||
|
||||
void handleFindReference(String text) {
|
||||
String referenceFile = base.getPdeKeywords().getReference(text);
|
||||
String q;
|
||||
if (referenceFile == null) {
|
||||
statusNotice(I18n.format(tr("No reference available for \"{0}\""), text));
|
||||
q = text;
|
||||
} else if (referenceFile.startsWith("Serial_")) {
|
||||
q = referenceFile.substring(7);
|
||||
} else {
|
||||
if (referenceFile.startsWith("Serial_")) {
|
||||
Base.showReference("Serial/" + referenceFile.substring("Serial_".length()));
|
||||
} else {
|
||||
Base.showReference("Reference/" + referenceFile);
|
||||
}
|
||||
q = referenceFile;
|
||||
}
|
||||
try {
|
||||
Base.openURL("https://www.arduino.cc/search?tab=&q="
|
||||
+ URLEncoder.encode(q, "UTF-8"));
|
||||
} catch (UnsupportedEncodingException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -247,7 +247,7 @@ public class EditorTab extends JPanel implements SketchFile.TextStorage {
|
||||
menu.add(item);
|
||||
|
||||
final JMenuItem referenceItem = new JMenuItem(tr("Find in Reference"));
|
||||
referenceItem.addActionListener(editor::handleFindReference);
|
||||
referenceItem.addActionListener(ev -> editor.handleFindReference(getCurrentKeyword()));
|
||||
menu.add(referenceItem);
|
||||
|
||||
final JMenuItem openURLItem = new JMenuItem(tr("Open URL"));
|
||||
|
@ -214,10 +214,6 @@
|
||||
|
||||
<antcall target="assemble-examples" />
|
||||
|
||||
<mkdir dir="${target.path}/reference"/>
|
||||
|
||||
<antcall target="assemble-docs" />
|
||||
|
||||
<!-- Write the revision file! -->
|
||||
<echo file="${target.path}/lib/version.txt" message="${version}" />
|
||||
|
||||
@ -254,16 +250,6 @@
|
||||
</copy>
|
||||
</target>
|
||||
|
||||
<target name="assemble-docs" unless="no_docs">
|
||||
<!-- Unzip documentation -->
|
||||
<antcall target="unzip">
|
||||
<param name="archive_file" value="shared/reference-1.6.6-3.zip" />
|
||||
<param name="archive_url" value="https://downloads.arduino.cc/reference-1.6.6-3.zip" />
|
||||
<param name="final_folder" value="${target.path}/reference/www.arduino.cc" />
|
||||
<param name="dest_folder" value="${target.path}/reference/" />
|
||||
</antcall>
|
||||
</target>
|
||||
|
||||
<!-- copy library folder -->
|
||||
<target name="assemble-libraries" unless="light_bundle">
|
||||
<download-library name="Ethernet" version="2.0.0"/>
|
||||
|
@ -1 +0,0 @@
|
||||
cc4f36c9783772f07c9a1bb4a60d7be3b504c69e
|
@ -1,5 +1,8 @@
|
||||
ARDUINO 1.8.15 Not yet release
|
||||
|
||||
[ide]
|
||||
* Removed the very outdated off-line documentation.
|
||||
|
||||
[wifi-firmware]
|
||||
* Added latest firmwares (up to version 1.4.8) for NINA-based boards
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user