Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
1
1weather
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dmitriy Stepanets
1weather
Commits
d14ca90c
Commit
d14ca90c
authored
Oct 13, 2021
by
Demid Merzlyakov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
IOS-316 / IOS-317: Minutely events: fix MINUTELY_PRECIP_TODAY_TAP not fired.
parent
0b5e2c29
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
0 deletions
+13
-0
1Weather/UI/SharedCells/PrecipCell/PrecipitationCell.swift
+11
-0
1Weather/UI/View controllers/Today/Cells/TodayCellFactory.swift
+1
-0
1Weather/UI/View controllers/Today/Cells/TodayForecastTimePeriodCell.swift
+1
-0
No files found.
1Weather/UI/SharedCells/PrecipCell/PrecipitationCell.swift
View file @
d14ca90c
...
...
@@ -26,6 +26,7 @@ class PrecipitationCell: UITableViewCell {
private
let
descriptionView
=
ForecastDescriptionView
(
lightStyleBackgroundColor
:
UIColor
(
hex
:
0xd9ebfe
),
gradientColors
:
[
UIColor
(
hex
:
0x44a4ff
)
.
withAlphaComponent
(
0.65
)
.
cgColor
,
UIColor
(
hex
:
0x73bbff
)
.
withAlphaComponent
(
0
)
.
cgColor
])
public
var
onTodayScreen
:
Bool
=
false
override
init
(
style
:
UITableViewCell
.
CellStyle
,
reuseIdentifier
:
String
?)
{
super
.
init
(
style
:
style
,
reuseIdentifier
:
reuseIdentifier
)
...
...
@@ -191,6 +192,13 @@ class PrecipitationCell: UITableViewCell {
AppAnalytics
.
shared
.
log
(
event
:
.
ANALYTICS_MINUTELY_PRECIP_TODAY_SEEN
)
}
}
@objc
private
func
handleTapOnGraph
()
{
if
onTodayScreen
{
analytics
(
log
:
.
ANALYTICS_MINUTELY_PRECIP_TODAY_TAP
)
}
}
}
//MARK:- Prepare
...
...
@@ -259,6 +267,9 @@ private extension PrecipitationCell {
make
.
top
.
equalTo
(
periodSegmentedControl
.
snp
.
bottom
)
.
offset
(
40
)
.
priority
(
.
medium
)
make
.
height
.
equalTo
(
240
)
}
let
tapGestureRecognizer
=
UITapGestureRecognizer
(
target
:
self
,
action
:
#selector(
handleTapOnGraph
)
)
minutelyForecastView
.
addGestureRecognizer
(
tapGestureRecognizer
)
}
func
prepareStackView
()
{
...
...
1Weather/UI/View controllers/Today/Cells/TodayCellFactory.swift
View file @
d14ca90c
...
...
@@ -160,6 +160,7 @@ class TodayCellFactory: CellFactory {
return
cell
case
.
precipitation
:
let
cell
=
dequeueReusableCell
(
type
:
PrecipitationCell
.
self
,
tableView
:
tableView
,
indexPath
:
indexPath
)
cell
.
onTodayScreen
=
true
cell
.
delegate
=
self
if
cellsToUpdate
.
contains
(
.
precipitation
)
{
if
let
location
=
todayViewModel
.
location
{
...
...
1Weather/UI/View controllers/Today/Cells/TodayForecastTimePeriodCell.swift
View file @
d14ca90c
...
...
@@ -122,6 +122,7 @@ private extension TodayForecastTimePeriodCell {
@objc
private
func
handleMinutelyTap
()
{
AppCoordinator
.
instance
.
openForecast
(
timePeriod
:
.
minutely
)
analytics
.
(
log
:
.
ANALYTICS_MINUTELY_TEMP_TODAY_TAP
)
}
func
prepareDescriptionView
()
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment