Compare commits
5 Commits
separate-h
...
muwire-0.6
Author | SHA1 | Date | |
---|---|---|---|
![]() |
c11d81c6c3 | ||
![]() |
ee5e90c4ab | ||
![]() |
64d2a87d26 | ||
![]() |
f0304dbe7d | ||
![]() |
bdad8d9309 |
@@ -32,7 +32,7 @@ import com.muwire.core.UILoadedEvent
|
|||||||
import com.muwire.core.files.AllFilesLoadedEvent
|
import com.muwire.core.files.AllFilesLoadedEvent
|
||||||
|
|
||||||
class CliLanterna {
|
class CliLanterna {
|
||||||
private static final String MW_VERSION = "0.6.8"
|
private static final String MW_VERSION = "0.6.9"
|
||||||
|
|
||||||
private static volatile Core core
|
private static volatile Core core
|
||||||
|
|
||||||
|
@@ -3,6 +3,7 @@ package com.muwire.clilanterna
|
|||||||
import com.googlecode.lanterna.gui2.TextGUIThread
|
import com.googlecode.lanterna.gui2.TextGUIThread
|
||||||
import com.googlecode.lanterna.gui2.table.TableModel
|
import com.googlecode.lanterna.gui2.table.TableModel
|
||||||
import com.muwire.core.Core
|
import com.muwire.core.Core
|
||||||
|
import com.muwire.core.InfoHash
|
||||||
import com.muwire.core.SharedFile
|
import com.muwire.core.SharedFile
|
||||||
import com.muwire.core.files.AllFilesLoadedEvent
|
import com.muwire.core.files.AllFilesLoadedEvent
|
||||||
import com.muwire.core.files.DirectoryWatchedEvent
|
import com.muwire.core.files.DirectoryWatchedEvent
|
||||||
@@ -72,7 +73,7 @@ class FilesModel {
|
|||||||
sharedFiles.each {
|
sharedFiles.each {
|
||||||
long size = it.getCachedLength()
|
long size = it.getCachedLength()
|
||||||
boolean comment = it.comment != null
|
boolean comment = it.comment != null
|
||||||
boolean certified = core.certificateManager.hasLocalCertificate(it.getInfoHash())
|
boolean certified = core.certificateManager.hasLocalCertificate(new InfoHash(it.getRoot()))
|
||||||
String hits = String.valueOf(it.getHits())
|
String hits = String.valueOf(it.getHits())
|
||||||
String downloaders = String.valueOf(it.getDownloaders().size())
|
String downloaders = String.valueOf(it.getDownloaders().size())
|
||||||
model.addRow(new SharedFileWrapper(it), DataHelper.formatSize2(size, false)+"B", comment, certified, hits, downloaders)
|
model.addRow(new SharedFileWrapper(it), DataHelper.formatSize2(size, false)+"B", comment, certified, hits, downloaders)
|
||||||
|
@@ -469,7 +469,7 @@ public class Core {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Core core = new Core(props, home, "0.6.8")
|
Core core = new Core(props, home, "0.6.9")
|
||||||
core.startServices()
|
core.startServices()
|
||||||
|
|
||||||
// ... at the end, sleep or execute script
|
// ... at the end, sleep or execute script
|
||||||
|
@@ -255,7 +255,6 @@ abstract class Connection implements Closeable {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: make this mandatory at some point
|
|
||||||
byte[] sig2 = null
|
byte[] sig2 = null
|
||||||
long queryTime = 0
|
long queryTime = 0
|
||||||
if (search.sig2 != null) {
|
if (search.sig2 != null) {
|
||||||
@@ -278,8 +277,10 @@ abstract class Connection implements Closeable {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else
|
} else {
|
||||||
log.info("no extended signature in query")
|
log.info("no extended signature in query")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
SearchEvent searchEvent = new SearchEvent(searchTerms : search.keywords,
|
SearchEvent searchEvent = new SearchEvent(searchTerms : search.keywords,
|
||||||
searchHash : infohash,
|
searchHash : infohash,
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
group = com.muwire
|
group = com.muwire
|
||||||
version = 0.6.8
|
version = 0.6.9
|
||||||
i2pVersion = 0.9.44
|
i2pVersion = 0.9.44
|
||||||
groovyVersion = 2.4.15
|
groovyVersion = 2.4.15
|
||||||
slf4jVersion = 1.7.25
|
slf4jVersion = 1.7.25
|
||||||
|
@@ -363,6 +363,8 @@ class MainFrameModel {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void onFileLoadedEvent(FileLoadedEvent e) {
|
void onFileLoadedEvent(FileLoadedEvent e) {
|
||||||
|
if (e.source == "PersisterService")
|
||||||
|
return
|
||||||
runInsideUIAsync {
|
runInsideUIAsync {
|
||||||
shared << e.loadedFile
|
shared << e.loadedFile
|
||||||
loadedFiles = shared.size()
|
loadedFiles = shared.size()
|
||||||
|
@@ -912,7 +912,7 @@ class MainFrameView {
|
|||||||
String roots = ""
|
String roots = ""
|
||||||
for (Iterator<SharedFile> iterator = selectedFiles.iterator(); iterator.hasNext(); ) {
|
for (Iterator<SharedFile> iterator = selectedFiles.iterator(); iterator.hasNext(); ) {
|
||||||
SharedFile selected = iterator.next()
|
SharedFile selected = iterator.next()
|
||||||
String root = Base64.encode(selected.infoHash.getRoot())
|
String root = Base64.encode(selected.getRoot())
|
||||||
roots += root
|
roots += root
|
||||||
if (iterator.hasNext())
|
if (iterator.hasNext())
|
||||||
roots += "\n"
|
roots += "\n"
|
||||||
|
Reference in New Issue
Block a user