mirror of
https://github.com/tonikelope/megabasterd.git
synced 2025-05-01 23:24:32 +02:00
6.72
-Sort wait queue fix
This commit is contained in:
parent
e763c844a7
commit
f99ee8ba9c
2
pom.xml
2
pom.xml
@ -3,7 +3,7 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<groupId>com.tonikelope</groupId>
|
<groupId>com.tonikelope</groupId>
|
||||||
<artifactId>MegaBasterd</artifactId>
|
<artifactId>MegaBasterd</artifactId>
|
||||||
<version>6.71</version>
|
<version>6.72</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -3,7 +3,6 @@ package com.tonikelope.megabasterd;
|
|||||||
import static com.tonikelope.megabasterd.DBTools.*;
|
import static com.tonikelope.megabasterd.DBTools.*;
|
||||||
import static com.tonikelope.megabasterd.MainPanel.*;
|
import static com.tonikelope.megabasterd.MainPanel.*;
|
||||||
import static com.tonikelope.megabasterd.MiscTools.*;
|
import static com.tonikelope.megabasterd.MiscTools.*;
|
||||||
import java.awt.Component;
|
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.concurrent.ConcurrentLinkedQueue;
|
import java.util.concurrent.ConcurrentLinkedQueue;
|
||||||
@ -118,19 +117,6 @@ public class DownloadManager extends TransferenceManager {
|
|||||||
|
|
||||||
getTransference_waitstart_queue().addAll(aux);
|
getTransference_waitstart_queue().addAll(aux);
|
||||||
|
|
||||||
getTransference_waitstart_queue().forEach((t1) -> {
|
|
||||||
swingInvoke(() -> {
|
|
||||||
getScroll_panel().remove((Component) t1.getView());
|
|
||||||
getScroll_panel().add((Component) t1.getView());
|
|
||||||
});
|
|
||||||
});
|
|
||||||
getTransference_finished_queue().forEach((t2) -> {
|
|
||||||
swingInvoke(() -> {
|
|
||||||
getScroll_panel().remove((Component) t2.getView());
|
|
||||||
getScroll_panel().add((Component) t2.getView());
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
@ -53,7 +53,7 @@ import javax.swing.UIManager;
|
|||||||
*/
|
*/
|
||||||
public final class MainPanel {
|
public final class MainPanel {
|
||||||
|
|
||||||
public static final String VERSION = "6.71";
|
public static final String VERSION = "6.72";
|
||||||
public static final int THROTTLE_SLICE_SIZE = 16 * 1024;
|
public static final int THROTTLE_SLICE_SIZE = 16 * 1024;
|
||||||
public static final int DEFAULT_BYTE_BUFFER_SIZE = 16 * 1024;
|
public static final int DEFAULT_BYTE_BUFFER_SIZE = 16 * 1024;
|
||||||
public static final int STREAMER_PORT = 1337;
|
public static final int STREAMER_PORT = 1337;
|
||||||
|
@ -413,7 +413,6 @@ public final class MainPanelView extends javax.swing.JFrame {
|
|||||||
jTabbedPane1.setTitleAt(1, LabelTranslatorSingleton.getInstance().translate("Uploads"));
|
jTabbedPane1.setTitleAt(1, LabelTranslatorSingleton.getInstance().translate("Uploads"));
|
||||||
jTabbedPane1.setDropTarget(new DropTarget() {
|
jTabbedPane1.setDropTarget(new DropTarget() {
|
||||||
|
|
||||||
//Thanks to -> https://stackoverflow.com/users/6286694/abika
|
|
||||||
public boolean canImport(DataFlavor[] flavors) {
|
public boolean canImport(DataFlavor[] flavors) {
|
||||||
for (DataFlavor flavor : flavors) {
|
for (DataFlavor flavor : flavors) {
|
||||||
if (flavor.isFlavorJavaFileListType()) {
|
if (flavor.isFlavorJavaFileListType()) {
|
||||||
|
@ -570,8 +570,9 @@ abstract public class TransferenceManager implements Runnable, SecureSingleThrea
|
|||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
synchronized (getQueue_sort_lock()) {
|
synchronized (getQueue_sort_lock()) {
|
||||||
if (!isPreprocessing_transferences() && !isProvisioning_transferences()) {
|
|
||||||
sortTransferenceWaitStartQueue();
|
sortTransferenceWaitStartQueue();
|
||||||
getTransference_waitstart_queue().forEach((up) -> {
|
getTransference_waitstart_queue().forEach((up) -> {
|
||||||
swingInvoke(() -> {
|
swingInvoke(() -> {
|
||||||
@ -585,8 +586,9 @@ abstract public class TransferenceManager implements Runnable, SecureSingleThrea
|
|||||||
getScroll_panel().add((Component) up.getView());
|
getScroll_panel().add((Component) up.getView());
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
_frozen = false;
|
_frozen = false;
|
||||||
setProvisioning_transferences(false);
|
setProvisioning_transferences(false);
|
||||||
secureNotify();
|
secureNotify();
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
package com.tonikelope.megabasterd;
|
package com.tonikelope.megabasterd;
|
||||||
|
|
||||||
import static com.tonikelope.megabasterd.MiscTools.*;
|
import static com.tonikelope.megabasterd.MiscTools.*;
|
||||||
import java.awt.Component;
|
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.concurrent.ConcurrentLinkedQueue;
|
import java.util.concurrent.ConcurrentLinkedQueue;
|
||||||
@ -54,19 +53,6 @@ public class UploadManager extends TransferenceManager {
|
|||||||
|
|
||||||
getTransference_waitstart_queue().addAll(aux);
|
getTransference_waitstart_queue().addAll(aux);
|
||||||
|
|
||||||
getTransference_waitstart_queue().forEach((t1) -> {
|
|
||||||
swingInvoke(() -> {
|
|
||||||
getScroll_panel().remove((Component) t1.getView());
|
|
||||||
getScroll_panel().add((Component) t1.getView());
|
|
||||||
});
|
|
||||||
});
|
|
||||||
getTransference_finished_queue().forEach((t2) -> {
|
|
||||||
swingInvoke(() -> {
|
|
||||||
getScroll_panel().remove((Component) t2.getView());
|
|
||||||
getScroll_panel().add((Component) t2.getView());
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
getTransference_waitstart_queue().add(upload);
|
getTransference_waitstart_queue().add(upload);
|
||||||
|
Binary file not shown.
Before Width: | Height: | Size: 192 KiB After Width: | Height: | Size: 192 KiB |
Loading…
x
Reference in New Issue
Block a user