tonikelope 2021-06-22 19:59:11 +02:00
parent dbc4af5945
commit 8713e79ccd
4 changed files with 214 additions and 201 deletions

View File

@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.tonikelope</groupId>
<artifactId>MegaBasterd</artifactId>
<version>7.41</version>
<version>7.42</version>
<packaging>jar</packaging>
<dependencies>
<dependency>

View File

@ -554,6 +554,8 @@ public class Download implements Transference, Runnable, SecureSingleThreadNotif
path.mkdirs();
}
if (!_file.exists() || _file.length() != _file_size) {
if (_file.exists()) {
_file_name = _file_name.replaceFirst("\\..*$", "_" + MiscTools.genID(8) + "_$0");
@ -843,6 +845,16 @@ public class Download implements Transference, Runnable, SecureSingleThreadNotif
getView().printStatusError(_status_error);
}
} else {
getView().hideAllExceptStatus();
_status_error = "FILE WITH SAME NAME AND SIZE ALREADY EXISTS";
_auto_retry_on_error = false;
getView().printStatusError(_status_error);
}
} else if (_status_error != null) {
getView().hideAllExceptStatus();
@ -995,7 +1007,7 @@ public class Download implements Transference, Runnable, SecureSingleThreadNotif
File file = new File(filename);
if (file.exists()) {
if (file.exists() && file.length() != _file_size) {
_file_name = _file_name.replaceFirst("\\..*$", "_" + MiscTools.genID(8) + "_$0");
}
@ -1019,7 +1031,7 @@ public class Download implements Transference, Runnable, SecureSingleThreadNotif
File temp_file = new File(filename + ".mctemp");
if (file.exists() && !temp_file.exists()) {
if (file.exists() && !temp_file.exists() && file.length() != _file_size) {
_file_name = _file_name.replaceFirst("\\..*$", "_" + MiscTools.genID(8) + "_$0");
}

View File

@ -38,6 +38,7 @@ public class LabelTranslatorSingleton {
private void Spanish() {
_addTranslation("FILE WITH SAME NAME AND SIZE ALREADY EXISTS", "YA EXISTE UN FICHERO CON EL MISMO NOMBRE Y TAMAÑO");
_addTranslation("WARNING: USING MEGA API WITHOUT API KEY MAY VIOLATE ITS TERM OF USE. YOU SHOULD GET A KEY -> https://mega.nz/sdk", "AVISO: USAR LA API DE MEGA SIN UNA API KEY PUEDE VIOLAR SUS TÉRMINOS DE USO. DEBES CONSEGUIR UNA API KEY -> https://mega.nz/sdk");
_addTranslation("WARNING: USING MEGA API WITHOUT API KEY MAY VIOLATE ITS TERM OF USE.\n\nYOU SHOULD GET A KEY -> https://mega.nz/sdk (and set it in MegaBasterd ADVANCED SETTINGS).\n\nCREATE API KEY NOW?", "AVISO: USAR LA API DE MEGA SIN UNA API KEY PUEDE VIOLAR SUS TÉRMINOS DE USO.\n\nDEBES CONSEGUIR UNA API KEY -> https://mega.nz/sdk (e introducirla en AJUSTES AVANZADOS de MegaBasterd).\n\n¿CREAR AHORA UNA API KEY?");
_addTranslation("WARNING: Using proxies or VPN to bypass MEGA's daily download limitation may violate its Terms of Use. USE THIS OPTION AT YOUR OWN RISK.", "AVISO: El uso de proxies o VPN para saltar el límite diario de descarga de MEGA podría violar sus Términos de Uso. UTILIZA ESTA OPCIÓN BAJO TU RESPONSABILIDAD.");

View File

@ -60,7 +60,7 @@ import javax.swing.UIManager;
*/
public final class MainPanel {
public static final String VERSION = "7.41";
public static final String VERSION = "7.42";
public static final boolean FORCE_SMART_PROXY = false; //TRUE FOR DEBUGING SMART PROXY
public static final int THROTTLE_SLICE_SIZE = 16 * 1024;
public static final int DEFAULT_BYTE_BUFFER_SIZE = 16 * 1024;