-
Notifications
You must be signed in to change notification settings - Fork 94
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1960 from nextcloud/feat/noid/improve-context-menu
Feat/noid/improve context menu
- Loading branch information
Showing
6 changed files
with
187 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
// | ||
// SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors | ||
// SPDX-License-Identifier: GPL-3.0-or-later | ||
// | ||
|
||
import UIKit | ||
import Foundation | ||
import SwiftyAttributes | ||
|
||
@objcMembers class MessageTextViewController: UIViewController { | ||
|
||
@IBOutlet public weak var messageTextView: UITextView! | ||
|
||
private var messageText = "" | ||
|
||
init(messageText: String) { | ||
super.init(nibName: "MessageTextViewController", bundle: nil) | ||
|
||
self.messageText = messageText | ||
} | ||
|
||
required init?(coder: NSCoder) { | ||
super.init(coder: coder) | ||
} | ||
|
||
override func viewDidLoad() { | ||
super.viewDidLoad() | ||
|
||
NCAppBranding.styleViewController(self) | ||
|
||
self.navigationItem.leftBarButtonItem = UIBarButtonItem(title: NSLocalizedString("Close", comment: ""), primaryAction: UIAction { [unowned self] _ in | ||
self.dismiss(animated: true) | ||
}) | ||
|
||
self.messageTextView.layer.cornerRadius = 8 | ||
self.messageTextView.layer.masksToBounds = true | ||
self.messageTextView.textContainerInset = UIEdgeInsets(top: 10, left: 10, bottom: 10, right: 10) | ||
self.messageTextView.text = messageText | ||
} | ||
|
||
} |
Oops, something went wrong.