зеркало из https://github.com/nextcloud/desktop.git
Add close action to lock view controller
Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
Родитель
10f37d3af1
Коммит
4edbb4b50d
|
@ -21,6 +21,10 @@ class LockViewController: NSViewController {
|
|||
@IBOutlet weak var closeButton: NSButton!
|
||||
@IBOutlet weak var loadingIndicator: NSProgressIndicator!
|
||||
|
||||
var actionViewController: DocumentActionViewController! {
|
||||
return parent as? DocumentActionViewController
|
||||
}
|
||||
|
||||
init(_ itemIdentifiers: [NSFileProviderItemIdentifier], locking: Bool) {
|
||||
self.itemIdentifiers = itemIdentifiers
|
||||
self.locking = locking
|
||||
|
@ -30,4 +34,8 @@ class LockViewController: NSViewController {
|
|||
required init?(coder: NSCoder) {
|
||||
fatalError("init(coder:) has not been implemented")
|
||||
}
|
||||
|
||||
@IBAction func closeAction(_ sender: Any) {
|
||||
actionViewController.extensionContext.completeRequest()
|
||||
}
|
||||
}
|
||||
|
|
|
@ -80,6 +80,9 @@
|
|||
<constraint firstAttribute="width" secondItem="7qN-mr-hAh" secondAttribute="height" multiplier="1:1" id="K00-Bi-dEy"/>
|
||||
<constraint firstAttribute="width" constant="32" id="zVJ-h1-QXJ"/>
|
||||
</constraints>
|
||||
<connections>
|
||||
<action selector="closeAction:" target="-2" id="E6h-U9-2eB"/>
|
||||
</connections>
|
||||
</button>
|
||||
</subviews>
|
||||
<edgeInsets key="edgeInsets" left="10" right="10" top="10" bottom="10"/>
|
||||
|
|
Загрузка…
Ссылка в новой задаче