Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
InstiApp
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
RAHUL SHARMA
InstiApp
Commits
d1d071ed
Commit
d1d071ed
authored
Feb 02, 2019
by
Varun Patil
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add heat map to calendar
parent
811c6f55
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
215 additions
and
33 deletions
+215
-33
app/build.gradle
app/build.gradle
+2
-0
app/src/main/java/app/insti/fragment/CalendarFragment.java
app/src/main/java/app/insti/fragment/CalendarFragment.java
+176
-27
app/src/main/res/color/mcv_text_date_light.xml
app/src/main/res/color/mcv_text_date_light.xml
+16
-0
app/src/main/res/layout/fragment_calendar.xml
app/src/main/res/layout/fragment_calendar.xml
+11
-6
app/src/main/res/values/styles.xml
app/src/main/res/values/styles.xml
+10
-0
No files found.
app/build.gradle
View file @
d1d071ed
...
@@ -36,6 +36,7 @@ ext {
...
@@ -36,6 +36,7 @@ ext {
sectionedRecyclerViewVersion
=
'1.2.0'
sectionedRecyclerViewVersion
=
'1.2.0'
lottieVersion
=
'2.7.0'
lottieVersion
=
'2.7.0'
shortcutBadgerVersion
=
'1.1.22@aar'
shortcutBadgerVersion
=
'1.1.22@aar'
materialCalendarViewVersion
=
'2.0.1'
}
}
dependencies
{
dependencies
{
...
@@ -61,5 +62,6 @@ dependencies {
...
@@ -61,5 +62,6 @@ dependencies {
implementation
"io.github.luizgrp.sectionedrecyclerviewadapter:sectionedrecyclerviewadapter:${sectionedRecyclerViewVersion}"
implementation
"io.github.luizgrp.sectionedrecyclerviewadapter:sectionedrecyclerviewadapter:${sectionedRecyclerViewVersion}"
implementation
"com.airbnb.android:lottie:$lottieVersion"
implementation
"com.airbnb.android:lottie:$lottieVersion"
implementation
"me.leolin:ShortcutBadger:$shortcutBadgerVersion"
implementation
"me.leolin:ShortcutBadger:$shortcutBadgerVersion"
implementation
"com.github.prolificinteractive:material-calendarview:${materialCalendarViewVersion}"
}
}
apply
plugin:
'com.google.gms.google-services'
apply
plugin:
'com.google.gms.google-services'
app/src/main/java/app/insti/fragment/CalendarFragment.java
View file @
d1d071ed
This diff is collapsed.
Click to expand it.
app/src/main/res/color/mcv_text_date_light.xml
0 → 100644
View file @
d1d071ed
<?xml version="1.0" encoding="utf-8"?>
<selector
xmlns:android=
"http://schemas.android.com/apk/res/android"
android:enterFadeDuration=
"@android:integer/config_shortAnimTime"
android:exitFadeDuration=
"@android:integer/config_shortAnimTime"
>
<item
android:state_checked=
"true"
android:color=
"@color/secondaryTextColor"
/>
<item
android:state_pressed=
"true"
android:color=
"@color/secondaryTextColor"
/>
<item
android:state_enabled=
"false"
android:color=
"#BBBBBB"
/>
<item
android:color=
"@color/secondaryTextColor"
/>
</selector>
app/src/main/res/layout/fragment_calendar.xml
View file @
d1d071ed
...
@@ -21,14 +21,19 @@
...
@@ -21,14 +21,19 @@
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
android:layout_height=
"60dp"
android:layout_height=
"60dp"
android:background=
"@color/colorPrimary"
/>
android:background=
"@color/colorPrimary"
/>
<CalendarView
<
com.prolificinteractive.materialcalendarview.Material
CalendarView
xmlns:app=
"http://schemas.android.com/apk/res-auto"
android:id=
"@+id/simpleCalendarView"
android:id=
"@+id/simpleCalendarView"
android:layout_width=
"
fill
_parent"
android:layout_width=
"
match
_parent"
android:layout_height=
"wrap_content"
android:layout_height=
"wrap_content"
android:focusedMonthDateColor=
"#000000"
app:mcv_showOtherDates=
"all"
android:unfocusedMonthDateColor=
"#FFFFFF"
/>
app:mcv_selectionColor=
"@color/colorPrimary"
app:mcv_headerTextAppearance=
"@style/MatCalendarHeader"
app:mcv_leftArrow=
"@color/primaryTextColor"
app:mcv_rightArrow=
"@color/primaryTextColor"
app:mcv_dateTextAppearance=
"@style/CalendarDateAppearance"
android:padding=
"5dp"
/>
<View
<View
android:layout_width=
"match_parent"
android:layout_width=
"match_parent"
...
...
app/src/main/res/values/styles.xml
View file @
d1d071ed
...
@@ -77,4 +77,14 @@
...
@@ -77,4 +77,14 @@
<item
name=
"android:windowEnterAnimation"
>
@android:anim/fade_in
</item>
<item
name=
"android:windowEnterAnimation"
>
@android:anim/fade_in
</item>
<item
name=
"android:windowExitAnimation"
>
@android:anim/fade_out
</item>
<item
name=
"android:windowExitAnimation"
>
@android:anim/fade_out
</item>
</style>
</style>
<style
name=
"MatCalendarHeader"
parent=
"TextAppearance.MaterialCalendarWidget.Header"
>
<item
name=
"android:textColor"
>
@color/primaryTextColor
</item>
<item
name=
"android:textStyle"
>
normal
</item>
</style>
<style
name=
"CalendarDateAppearance"
parent=
"TextAppearance.AppCompat.Medium"
>
<item
name=
"android:textColor"
>
@color/mcv_text_date_light
</item>
<item
name=
"android:textSize"
>
14sp
</item>
</style>
</resources>
</resources>
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