Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] 디자인 요청 사항 #96

Merged
merged 2 commits into from
Jan 20, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions .idea/sonarlint/issuestore/index.pb

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ class ReportGraphFragment : Fragment() {
private var COUNT_X_LABEL = 5
private var recordCount = ArrayList<String>()
private var monthCount = ArrayList<String>()
private var isFirst = true

override fun onCreateView(
inflater: LayoutInflater,
Expand Down Expand Up @@ -82,7 +83,11 @@ class ReportGraphFragment : Fragment() {
private fun initBarChart(recordCount: ArrayList<String>) {
val data: BarData = createBarChartData(recordCount)
// set bar width
data.barWidth = 0.1f
if (MAX_X_VALUE < 5) {
data.barWidth = 0.06f
} else {
data.barWidth = 0.1f
}
configureChartAppearance()
prepareChartData(data)
}
Expand All @@ -92,13 +97,15 @@ class ReportGraphFragment : Fragment() {
tvGraph3Month.setOnClickListener {
MAX_X_VALUE = 3
COUNT_X_LABEL = 3
isFirst = false
tvGraph5Month.setTextColor(Color.GRAY)
tvGraph3Month.setTextColor(Color.WHITE)
initNetwork()
}
tvGraph5Month.setOnClickListener {
MAX_X_VALUE = 5
COUNT_X_LABEL = 5
isFirst = false
tvGraph5Month.setTextColor(Color.WHITE)
tvGraph3Month.setTextColor(Color.GRAY)
initNetwork()
Expand Down Expand Up @@ -145,13 +152,14 @@ class ReportGraphFragment : Fragment() {
extraBottomOffset = 20f

// X, Y 바의 애니메이션 효과
animateY(2000)
if (isFirst) animateY(300)
// bar background
setDrawBarShadow(true)
// bar touch
setTouchEnabled(false)

// chart label
getLegend().isEnabled = false
legend.isEnabled = false
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ class ReportOnepageFragment : Fragment() {
extraBottomOffset = 45f

// X, Y 바의 애니메이션 효과
animateY(2000)
animateY(1000)
// bar background
setDrawBarShadow(true)
// bar touch
Expand Down