зеркало из https://github.com/nextcloud/desktop.git
Add basic properties to lock view controller
Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
Родитель
ec66bcd19b
Коммит
e3b6cd9935
|
@ -40,9 +40,9 @@ class DocumentActionViewController: FPUIActionExtensionViewController {
|
|||
case "com.nextcloud.desktopclient.FileProviderUIExt.ShareAction":
|
||||
prepare(childViewController: ShareViewController(itemIdentifiers))
|
||||
case "com.nextcloud.desktopclient.FileProviderUIExt.LockFileAction":
|
||||
prepare(childViewController: LockViewController(itemIdentifiers))
|
||||
prepare(childViewController: LockViewController(itemIdentifiers, locking: true))
|
||||
case "com.nextcloud.desktopclient.FileProviderUIExt.UnlockFileAction":
|
||||
prepare(childViewController: LockViewController(itemIdentifiers))
|
||||
prepare(childViewController: LockViewController(itemIdentifiers, locking: false))
|
||||
default:
|
||||
return
|
||||
}
|
||||
|
|
|
@ -12,5 +12,16 @@ import OSLog
|
|||
import QuickLookThumbnailing
|
||||
|
||||
class LockViewController: NSViewController {
|
||||
let itemIdentifiers: [NSFileProviderItemIdentifier]
|
||||
let locking: Bool
|
||||
|
||||
init(_ itemIdentifiers: [NSFileProviderItemIdentifier], locking: Bool) {
|
||||
self.itemIdentifiers = itemIdentifiers
|
||||
self.locking = locking
|
||||
super.init(nibName: nil, bundle: nil)
|
||||
}
|
||||
|
||||
required init?(coder: NSCoder) {
|
||||
fatalError("init(coder:) has not been implemented")
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче