remove dead file

This commit is contained in:
Scott Pfeil 2023-10-04 17:09:04 -04:00
parent 1455e83b58
commit c86fe17500

View File

@ -1,43 +0,0 @@
//
// ActionTopScrollModel.swift
// MVMCoreUI
//
// Created by Nadigadda, Sumanth on 31/03/22.
// Copyright © 2022 Verizon Wireless. All rights reserved.
//
import Foundation
import MVMCore
import MVMCoreUI
public protocol MVMCoreActionScrollProtocol: MVMCoreActionDelegateProtocol {
@MainActor
func handleScrollTopAction(action: ActionModelProtocol, additionalData: [AnyHashable: Any]?)
}
public struct ActionScrollToTopModel: ActionModelProtocol {
//--------------------------------------------------
// MARK: - Properties
//--------------------------------------------------
public static var identifier: String = "scrollToTop"
public var actionType: String = ActionScrollToTopModel.identifier
public var extraParameters: JSONValueDictionary?
public var analyticsData: JSONValueDictionary?
}
public struct ScrollToTopActionHandler: MVMCoreActionHandlerProtocol {
public init(){}
public func execute(with model: ActionModelProtocol, delegateObject: DelegateObject?, additionalData: [AnyHashable : Any]?) async throws {
guard let model = model as? ActionScrollToTopModel else { return }
await (delegateObject?.actionDelegate as? MVMCoreActionScrollProtocol)?.handleScrollTopAction(action: model, additionalData: additionalData)
}
}
extension ScrollingViewController: MVMCoreActionScrollProtocol {
@MainActor
public func handleScrollTopAction(action: ActionModelProtocol, additionalData: [AnyHashable: Any]?) {
scrollView.setContentOffset(CGPoint(x: 0, y: -scrollView.adjustedContentInset.top), animated: true)
}
}