refactor: typos
This commit is contained in:
parent
54a01db216
commit
f4dc72b61f
|
|
@ -41,7 +41,7 @@ final public class LoggingPresenter {
|
|||
|
||||
private init() { }
|
||||
|
||||
/// binds openning and closing of logging list view to a shacking motion.
|
||||
/// binds openning and closing of logging list view to a shaking motion.
|
||||
public func bind(_ scene: UIWindowScene? = nil) {
|
||||
if let scene = scene {
|
||||
window.windowScene = scene
|
||||
|
|
@ -51,7 +51,7 @@ final public class LoggingPresenter {
|
|||
loggingViewController.setVisible(isVisible: false)
|
||||
}
|
||||
|
||||
/// unbinds openning and closing of logging list view by shacking motion.
|
||||
/// unbinds openning and closing of logging list view by shaking motion.
|
||||
public func unbind() {
|
||||
window.isHidden = true
|
||||
loggingViewController.setVisible(isVisible: true)
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ open class LoggingTogglingViewController: BaseInitializeableViewController {
|
|||
|
||||
private var initialCenter = CGPoint()
|
||||
|
||||
private var isRegisteredForShackingEvent: Bool {
|
||||
private var isRegisteredForShakingEvent: Bool {
|
||||
!isVisibleState
|
||||
}
|
||||
|
||||
|
|
@ -68,7 +68,7 @@ open class LoggingTogglingViewController: BaseInitializeableViewController {
|
|||
button.addGestureRecognizer(panGesture)
|
||||
button.addTarget(self, action: #selector(openLoggingScreenAction), for: .touchUpInside)
|
||||
|
||||
// Needed for catching shacking motion
|
||||
// Needed for catching shaking motion
|
||||
becomeFirstResponder()
|
||||
}
|
||||
|
||||
|
|
@ -88,7 +88,7 @@ open class LoggingTogglingViewController: BaseInitializeableViewController {
|
|||
// MARK: - Overrided methods
|
||||
|
||||
open override func motionEnded(_ motion: UIEvent.EventSubtype, with event: UIEvent?) {
|
||||
if !isLogsPresented, isRegisteredForShackingEvent {
|
||||
if motion == .motionShake, !isLogsPresented, isRegisteredForShakingEvent {
|
||||
openLoggingScreen()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue