Merge commit 'e059d93e0eff44288dc8328c4c03ded0608647dc'

This commit is contained in:
Ali
2020-03-30 20:26:59 +04:00
6 changed files with 6 additions and 6 deletions

View File

@@ -135,7 +135,7 @@ public class BaseLinesChartController: BaseChartController {
}
public override func didTapZoomIn(date: Date, pointIndex: Int) {
guard isZoomed == false else { return }
guard !isZoomed, isZoomable else { return }
setDetailsViewModel?(chartDetailsViewModel(closestDate: date, pointIndex: pointIndex, loading: true), false, false)

View File

@@ -245,7 +245,7 @@ public class PercentPieChartController: BaseChartController {
}
func didTapZoomIn(date: Date, animated: Bool) {
guard isZoomed == false else { return }
guard !isZoomed, isZoomable else { return }
cancelChartInteraction()
let currentCollection = percentController.chartsCollection
let range: Int = Constants.zoomedRange

View File

@@ -206,7 +206,7 @@ public class DailyBarsChartController: BaseChartController {
}
public override func didTapZoomIn(date: Date, pointIndex: Int) {
guard isZoomed == false else { return }
guard !isZoomed, isZoomable else { return }
if isZoomed {
return linesController.hideDetailsView(animated: true)
}

View File

@@ -221,7 +221,7 @@ public class StackedBarsChartController: BaseChartController {
}
public override func didTapZoomIn(date: Date, pointIndex: Int) {
guard isZoomed == false else { return }
guard !isZoomed, isZoomable else { return }
if isZoomed {
return zoomedBarsController.hideDetailsView(animated: true)
}

View File

@@ -229,7 +229,7 @@ public class StepBarsChartController: BaseChartController {
}
public override func didTapZoomIn(date: Date, pointIndex: Int) {
guard isZoomed == false else { return }
guard !isZoomed, isZoomable else { return }
if isZoomed {
return zoomedBarsController.hideDetailsView(animated: true)
}

View File

@@ -215,7 +215,7 @@ private final class ChatListViewSpaceState {
if let lastMessage = lowerOrAtAnchorMessages.min(by: { $0.entryIndex < $1.entryIndex }) {
nextLowerIndex = lastMessage.entryIndex
} else {
nextLowerIndex = resolvedAnchorIndex.predecessor
nextLowerIndex = resolvedAnchorIndex
}
let loadedLowerMessages = postbox.chatListTable.entries(groupId: groupId, from: (nextLowerIndex.index, nextLowerIndex.isMessage), to: (lowerBound.index, lowerBound.isMessage), peerChatInterfaceStateTable: postbox.peerChatInterfaceStateTable, count: self.halfLimit - lowerOrAtAnchorMessages.count, predicate: filterPredicate.flatMap { mappedChatListFilterPredicate(postbox: postbox, groupId: groupId, predicate: $0) }).map(mapEntry)
lowerOrAtAnchorMessages.append(contentsOf: loadedLowerMessages)