-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FEAT] Add primary action floating action button to fragments
- Loading branch information
1 parent
11ec0b1
commit 2526fb2
Showing
22 changed files
with
139 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 0 additions & 3 deletions
3
common/src/main/java/com/peterkrauz/grimoire/common/BaseViewAction.kt
This file was deleted.
Oops, something went wrong.
3 changes: 0 additions & 3 deletions
3
common/src/main/java/com/peterkrauz/grimoire/common/BaseViewState.kt
This file was deleted.
Oops, something went wrong.
3 changes: 3 additions & 0 deletions
3
common/src/main/java/com/peterkrauz/grimoire/common/base/BaseViewAction.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package com.peterkrauz.grimoire.common.base | ||
|
||
interface BaseViewAction |
2 changes: 1 addition & 1 deletion
2
...terkrauz/grimoire/common/BaseViewModel.kt → ...auz/grimoire/common/base/BaseViewModel.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
common/src/main/java/com/peterkrauz/grimoire/common/base/BaseViewState.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package com.peterkrauz.grimoire.common.base | ||
|
||
interface BaseViewState |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<vector xmlns:android="http://schemas.android.com/apk/res/android" | ||
android:width="24dp" | ||
android:height="24dp" | ||
android:viewportWidth="24" | ||
android:viewportHeight="24" | ||
android:tint="?attr/colorControlNormal"> | ||
<path | ||
android:fillColor="@android:color/white" | ||
android:pathData="M4,6L2,6v14c0,1.1 0.9,2 2,2h14v-2L4,20L4,6zM20,2L8,2c-1.1,0 -2,0.9 -2,2v12c0,1.1 0.9,2 2,2h12c1.1,0 2,-0.9 2,-2L22,4c0,-1.1 -0.9,-2 -2,-2zM19,11h-4v4h-2v-4L9,11L9,9h4L13,5h2v4h4v2z"/> | ||
</vector> |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<resources> | ||
<!-- Empty state messages --> | ||
<string name="arcs_empty_state_msg">It seems you haven\'t\ncreated any Arc yet.</string> | ||
<string name="characters_empty_state_msg">It seems you haven\'t\ncreated any Character yet.</string> | ||
<string name="notes_empty_state_msg">It seems you haven\'t\ncreated any Note yet.</string> | ||
<string name="arcs_empty_state_msg">It seems you haven\'t\ncreated any Arc.\n\n\nClick the button below\nto add one!</string> | ||
<string name="characters_empty_state_msg">It seems you haven\'t\ncreated any Character.\n\n\nClick the button below\nto add one!</string> | ||
<string name="notes_empty_state_msg">It seems you haven\'t\ncreated any Note.\n\n\nClick the button below\nto add one!</string> | ||
</resources> |
19 changes: 18 additions & 1 deletion
19
...cters/src/main/java/com/peterkrauz/grimoire/presentation/characters/CharactersFragment.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,24 @@ | ||
package com.peterkrauz.grimoire.presentation.characters | ||
|
||
import android.media.MediaPlayer | ||
import androidx.fragment.app.Fragment | ||
import dagger.hilt.android.AndroidEntryPoint | ||
|
||
@AndroidEntryPoint | ||
class CharactersFragment : Fragment(R.layout.fragment_characters) | ||
class CharactersFragment : Fragment(R.layout.fragment_characters) { | ||
|
||
private var mediaPlayer: MediaPlayer? = null | ||
|
||
override fun onResume() { | ||
super.onResume() | ||
// mediaPlayer = MediaPlayer.create(this, R.raw.arcs_tab_sound).apply { | ||
// setOnCompletionListener { mediaPlayer?.release() } | ||
// } | ||
} | ||
|
||
override fun onPause() { | ||
super.onPause() | ||
mediaPlayer?.release() | ||
} | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 17 additions & 1 deletion
18
presentation/home/src/main/java/com/peterkrauz/grimoire/presentation/home/ArcsFragment.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,23 @@ | ||
package com.peterkrauz.grimoire.presentation.home | ||
|
||
import android.media.MediaPlayer | ||
import androidx.fragment.app.Fragment | ||
import dagger.hilt.android.AndroidEntryPoint | ||
|
||
@AndroidEntryPoint | ||
class ArcsFragment : Fragment(R.layout.fragment_arcs) | ||
class ArcsFragment : Fragment(R.layout.fragment_arcs) { | ||
|
||
private var mediaPlayer: MediaPlayer? = null | ||
|
||
override fun onResume() { | ||
super.onResume() | ||
// mediaPlayer = MediaPlayer.create(this, R.raw.arcs_tab_sound).apply { | ||
// setOnCompletionListener { mediaPlayer?.release() } | ||
// } | ||
} | ||
|
||
override fun onPause() { | ||
super.onPause() | ||
mediaPlayer?.release() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 18 additions & 1 deletion
19
presentation/notes/src/main/java/com/peterkrauz/grimoire/presentation/notes/NotesFragment.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,24 @@ | ||
package com.peterkrauz.grimoire.presentation.notes | ||
|
||
import android.media.MediaPlayer | ||
import androidx.fragment.app.Fragment | ||
import dagger.hilt.android.AndroidEntryPoint | ||
|
||
@AndroidEntryPoint | ||
class NotesFragment : Fragment(R.layout.fragment_notes) | ||
class NotesFragment : Fragment(R.layout.fragment_notes) { | ||
|
||
private var mediaPlayer: MediaPlayer? = null | ||
|
||
override fun onResume() { | ||
super.onResume() | ||
// mediaPlayer = MediaPlayer.create(this, R.raw.arcs_tab_sound).apply { | ||
// setOnCompletionListener { mediaPlayer?.release() } | ||
// } | ||
} | ||
|
||
override fun onPause() { | ||
super.onPause() | ||
mediaPlayer?.release() | ||
} | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters