mirror of https://github.com/zlatinb/muwire
add button for downloading full collection
parent
c27a09473f
commit
65e96eacc2
|
@ -15,6 +15,11 @@ class CollectionTabController {
|
||||||
@MVCMember @Nonnull
|
@MVCMember @Nonnull
|
||||||
CollectionTabView view
|
CollectionTabView view
|
||||||
|
|
||||||
|
@ControllerAction
|
||||||
|
void downloadCollection() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
@ControllerAction
|
@ControllerAction
|
||||||
void download() {
|
void download() {
|
||||||
|
|
||||||
|
|
|
@ -546,3 +546,4 @@ DELETE=Delete
|
||||||
## Collection tab
|
## Collection tab
|
||||||
COLLECTION_SELECT=Select a collection to view it's description
|
COLLECTION_SELECT=Select a collection to view it's description
|
||||||
DESCRIPTION=Description
|
DESCRIPTION=Description
|
||||||
|
COLLECTION_DOWNLOAD=Download Full Collection
|
||||||
|
|
|
@ -45,6 +45,7 @@ class CollectionTabModel {
|
||||||
@Observable int totalCollections
|
@Observable int totalCollections
|
||||||
@Observable boolean viewCommentButtonEnabled
|
@Observable boolean viewCommentButtonEnabled
|
||||||
@Observable boolean downloadItemButtonEnabled
|
@Observable boolean downloadItemButtonEnabled
|
||||||
|
@Observable boolean downloadCollectionButtonEnabled
|
||||||
|
|
||||||
void mvcGroupInit(Map<String,String> args) {
|
void mvcGroupInit(Map<String,String> args) {
|
||||||
root = new DefaultMutableTreeNode()
|
root = new DefaultMutableTreeNode()
|
||||||
|
|
|
@ -44,8 +44,6 @@ class CollectionTabView {
|
||||||
p = builder.panel {
|
p = builder.panel {
|
||||||
gridLayout(rows : 3, cols: 1)
|
gridLayout(rows : 3, cols: 1)
|
||||||
panel {
|
panel {
|
||||||
borderLayout()
|
|
||||||
panel(constraints : BorderLayout.NORTH) {
|
|
||||||
borderLayout()
|
borderLayout()
|
||||||
panel(constraints : BorderLayout.NORTH) {
|
panel(constraints : BorderLayout.NORTH) {
|
||||||
label(text : trans("STATUS") + ":")
|
label(text : trans("STATUS") + ":")
|
||||||
|
@ -63,6 +61,8 @@ class CollectionTabView {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
panel(constraints : BorderLayout.SOUTH) {
|
||||||
|
button(text : trans("COLLECTION_DOWNLOAD"), enabled : bind{model.downloadCollectionButtonEnabled}, downloadCollectionAction)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
panel {
|
panel {
|
||||||
|
@ -161,6 +161,7 @@ class CollectionTabView {
|
||||||
int row = selectedCollection()
|
int row = selectedCollection()
|
||||||
if (row < 0)
|
if (row < 0)
|
||||||
return
|
return
|
||||||
|
model.downloadCollectionButtonEnabled = true
|
||||||
FileCollection selected = model.collections.get(row)
|
FileCollection selected = model.collections.get(row)
|
||||||
model.comment = selected.comment
|
model.comment = selected.comment
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue