mirror of https://github.com/rusefi/rusefi.git
refactoring
This commit is contained in:
parent
4b66100202
commit
681cbef891
|
@ -1,6 +1,7 @@
|
|||
package com.rusefi.maintenance;
|
||||
|
||||
import com.opensr5.ini.IniFileModel;
|
||||
import com.rusefi.FileLog;
|
||||
import com.rusefi.Launcher;
|
||||
import com.rusefi.Timeouts;
|
||||
import com.rusefi.autodetect.PortDetector;
|
||||
|
@ -63,7 +64,7 @@ public class DfuFlasher {
|
|||
if (isSignatureValidated == null)
|
||||
return;
|
||||
if (isSignatureValidated.get()) {
|
||||
if (!ProgramSelector.IS_WIN) {
|
||||
if (!FileLog.isWindows()) {
|
||||
wnd.append("Switched to DFU mode!");
|
||||
wnd.append("rusEFI console can only program on Windows");
|
||||
return;
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package com.rusefi.maintenance;
|
||||
|
||||
import com.rusefi.FileLog;
|
||||
import com.rusefi.Launcher;
|
||||
import com.rusefi.SerialPortScanner;
|
||||
import com.rusefi.autodetect.PortDetector;
|
||||
|
@ -30,8 +31,6 @@ public class ProgramSelector {
|
|||
private static final String ST_LINK = "ST-LINK Update";
|
||||
private static final String OPENBLT_CAN = "OpenBLT via CAN";
|
||||
|
||||
public static final boolean IS_WIN = System.getProperty("os.name").toLowerCase().contains("win");
|
||||
|
||||
private static final String HELP = "https://github.com/rusefi/rusefi/wiki/HOWTO-Update-Firmware";
|
||||
public static final String BOOT_COMMANDER_EXE = "BootCommander.exe";
|
||||
public static final String OPENBLT_BINARY_LOCATION = Launcher.TOOLS_PATH + File.separator + "openblt";
|
||||
|
@ -126,7 +125,7 @@ public class ProgramSelector {
|
|||
controls.setVisible(!currentHardware.isEmpty());
|
||||
|
||||
mode.removeAllItems();
|
||||
if (IS_WIN) {
|
||||
if (FileLog.isWindows()) {
|
||||
if (!currentHardware.getKnownPorts().isEmpty())
|
||||
mode.addItem(AUTO_DFU);
|
||||
if (currentHardware.isDfuFound()) {
|
||||
|
|
Loading…
Reference in New Issue