mirror of https://github.com/zlatinb/muwire
option to disable sending paths
parent
844462602b
commit
75151e39db
|
@ -126,6 +126,10 @@ class OptionsController {
|
|||
model.browseFiles = browseFiles
|
||||
settings.browseFiles = browseFiles
|
||||
|
||||
boolean showPaths = view.showPathsCheckbox.model.isSelected()
|
||||
model.showPaths = showPaths
|
||||
settings.showPaths = showPaths
|
||||
|
||||
boolean allowTracking = view.allowTrackingCheckbox.model.isSelected()
|
||||
model.allowTracking = allowTracking
|
||||
settings.allowTracking = allowTracking
|
||||
|
|
|
@ -289,6 +289,7 @@ OPTIONS_SEARCH_SETTINGS=Search Settings
|
|||
OPTIONS_SEARCH_IN_COMMENTS=Search in comments
|
||||
OPTIONS_SEARCH_IN_COLLECTIONS=Search in collections
|
||||
OPTIONS_ALLOW_BROWSING=Allow browsing
|
||||
OPTIONS_SHOW_PATHS=Send folder information with results
|
||||
OPTIONS_ALLOW_TRACKING=Allow tracking
|
||||
OPTIONS_DOWNLOAD_SETTINGS=Download Settings
|
||||
OPTIONS_RETRY_FAILED_DOWNLOADS=Retry failed downloads every (seconds)
|
||||
|
|
|
@ -25,6 +25,8 @@ class OptionsModel {
|
|||
@Observable boolean searchComments
|
||||
@Observable boolean searchCollections
|
||||
@Observable boolean browseFiles
|
||||
@Observable boolean showPaths
|
||||
@Observable boolean showPathsCheckboxEnabled
|
||||
@Observable boolean allowTracking
|
||||
@Observable int speedSmoothSeconds
|
||||
@Observable int totalUploadSlots
|
||||
|
@ -111,6 +113,8 @@ class OptionsModel {
|
|||
searchComments = settings.searchComments
|
||||
searchCollections = settings.searchCollections
|
||||
browseFiles = settings.browseFiles
|
||||
showPaths = settings.showPaths
|
||||
setShowPathsCheckboxEnabled(browseFiles)
|
||||
allowTracking = settings.allowTracking
|
||||
speedSmoothSeconds = settings.speedSmoothSeconds
|
||||
totalUploadSlots = settings.totalUploadSlots
|
||||
|
|
|
@ -55,6 +55,7 @@ class OptionsView {
|
|||
def searchCommentsCheckbox
|
||||
def searchCollectionsCheckbox
|
||||
def browseFilesCheckbox
|
||||
def showPathsCheckbox
|
||||
def allowTrackingCheckbox
|
||||
def speedSmoothSecondsField
|
||||
def totalUploadSlotsField
|
||||
|
@ -132,9 +133,13 @@ class OptionsView {
|
|||
fill : GridBagConstraints.HORIZONTAL, weightx: 100))
|
||||
browseFilesCheckbox = checkBox(selected : bind {model.browseFiles}, constraints : gbc(gridx : 1, gridy : 2,
|
||||
anchor : GridBagConstraints.LINE_END, fill : GridBagConstraints.HORIZONTAL, weightx: 0))
|
||||
label(text : trans("OPTIONS_ALLOW_TRACKING"), constraints : gbc(gridx: 0, gridy: 3, anchor: GridBagConstraints.LINE_START,
|
||||
label(text : trans("OPTIONS_SHOW_PATHS"), enabled: bind{model.showPathsCheckboxEnabled}, constraints: gbc(gridx:0, gridy:3, anchor: GridBagConstraints.LINE_START,
|
||||
fill : GridBagConstraints.HORIZONTAL, weightx: 100))
|
||||
showPathsCheckbox = checkBox(selected : bind {model.showPaths}, enabled : bind{model.showPathsCheckboxEnabled}, constraints : gbc(gridx: 1, gridy : 3,
|
||||
anchor : GridBagConstraints.LINE_END, fill : GridBagConstraints.HORIZONTAL, weightx : 0))
|
||||
label(text : trans("OPTIONS_ALLOW_TRACKING"), constraints : gbc(gridx: 0, gridy: 4, anchor: GridBagConstraints.LINE_START,
|
||||
fill : GridBagConstraints.HORIZONTAL, weightx: 100))
|
||||
allowTrackingCheckbox = checkBox(selected : bind {model.allowTracking}, constraints : gbc(gridx: 1, gridy : 3,
|
||||
allowTrackingCheckbox = checkBox(selected : bind {model.allowTracking}, constraints : gbc(gridx: 1, gridy : 4,
|
||||
anchor : GridBagConstraints.LINE_END, fill : GridBagConstraints.HORIZONTAL, weightx : 0))
|
||||
}
|
||||
|
||||
|
@ -444,6 +449,10 @@ class OptionsView {
|
|||
allowUntrustedCheckbox.addActionListener {
|
||||
model.searchExtraHopCheckboxEnabled = allowUntrustedCheckbox.model.isSelected()
|
||||
}
|
||||
|
||||
browseFilesCheckbox.addActionListener {
|
||||
model.showPathsCheckboxEnabled = browseFilesCheckbox.model.isSelected()
|
||||
}
|
||||
}
|
||||
|
||||
boolean isAqua() {
|
||||
|
|
Loading…
Reference in New Issue