Skip to content

Commit

Permalink
wearos fix
Browse files Browse the repository at this point in the history
  • Loading branch information
phillipthelen committed Sep 23, 2024
1 parent dd6577f commit 8c45c06
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 17 deletions.
2 changes: 1 addition & 1 deletion common/src/main/res/values/colors.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<color name="white">#ffffff</color>
<color name="black">#000000</color>
<color name="watch_white">#ffffff</color>
<color name="watch_black">#000000FF</color>
<color name="watch_black">#000000</color>

<color name="brand_50">#36205D</color>
<color name="brand_100">#432874</color>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,14 @@ class TaskResultViewModel
exceptionBuilder: ExceptionHandlerBuilder,
appStateManager: AppStateManager,
) : BaseViewModel(userRepository, taskRepository, exceptionBuilder, appStateManager) {
val user = userRepository.getUser().asLiveData()
val hasLeveledUp: Boolean
get() = result?.hasLeveledUp == true
val hasDied: Boolean
get() = result?.hasDied == true
val hasDrop: Boolean
get() {
return result?.drop?.key?.isNotBlank() == true // || (result?.questItemsFound ?: 0) > 0
}
val result = savedStateHandle.get<TaskScoringResult>("result")
}
val user = userRepository.getUser().asLiveData()
val hasLeveledUp: Boolean
get() = result?.hasLeveledUp == true
val hasDied: Boolean
get() = result?.hasDied == true
val hasDrop: Boolean
get() {
return result?.drop?.key?.isNotBlank() == true // || (result?.questItemsFound ?: 0) > 0
}
val result = savedStateHandle.get<TaskScoringResult>("result")
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class ConnectedActionChipView(context: Context, attrs: AttributeSet? = null) :
capabilityClient.addListener({
launch(Dispatchers.Main) {
isEnabled = it.nodes.firstOrNull { it.isNearby } != null
alpha = if (isEnabled) 1.0f else 0.7f
alpha = if (isEnabled) 1.0f else 0.5f
}
}, "open_activity")
}
Expand Down
6 changes: 2 additions & 4 deletions wearos/src/main/res/anim/move_away.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
<set xmlns:android="http://schemas.android.com/apk/res/android"
android:duration="@integer/activity_transition_time"
>
<scale android:fromXScale="1" android:toXScale="0.8" android:pivotX="50%"
android:fromYScale="1" android:toYScale="0.8" android:pivotY="50%" />
<alpha
android:fromAlpha="1"
android:toAlpha="0.2"/>
</set>
android:toAlpha="0.0"/>
</set>

0 comments on commit 8c45c06

Please sign in to comment.