Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

[CC Overview] Empty State

  • Loading branch information
Tim Palade authored and sharath-cliqz committed Sep 7, 2018
1 parent cf2a5f3 commit 912c0585cea5ac8b565bb43fdfdc5a27db95224b
Showing with 7 additions and 0 deletions.
  1. +7 −0 Cliqz/Privacy/UI/ControlCenter/OverviewViewController.swift
@@ -1087,6 +1087,13 @@ class OverviewViewController: UIViewController {
colors.append(touple.1)
}
}

//Handle the empty case
if values.count == 0 {
colors = [UIColor.cliqzGrayFunctional]
values.append(PieChartDataEntry(value: 1.0))
}

let dataSet = PieChartDataSet(values: values, label: "")
dataSet.drawIconsEnabled = false
dataSet.drawValuesEnabled = false

0 comments on commit 912c058

Please sign in to comment.