Skip to content

Commit

Permalink
Remove override snap timer feature (doesn't work).
Browse files Browse the repository at this point in the history
Bump version (1.6.4)
  • Loading branch information
rodit committed May 15, 2022
1 parent 995f6cc commit 4507d85
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 21 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ android {
applicationId "xyz.rodit.snapmod"
minSdk 24
targetSdk 32
versionCode 22
versionName "1.6.3"
versionCode 23
versionName "1.6.4"

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
Expand Down
1 change: 0 additions & 1 deletion app/src/main/java/xyz/rodit/snapmod/SettingsActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@ class SettingsActivity : SettingsActivity(R.xml.root_preferences) {
}
}

setNumericInput(fragment, "override_snap_timer")
setNumericInput(fragment, "public_dp_resolution")
setNumericInput(fragment, "location_share_lat")
setNumericInput(fragment, "location_share_long")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,19 +20,11 @@ class SnapOverrides(context: FeatureContext) : Feature(context) {
if (!GallerySnapMedia.isInstance(message.instance)) return@before

val id = GallerySnapMedia.wrap(message.instance).media.id
val snap = LiveSnapMedia()
val timer = context.config.getDouble("override_snap_timer", 0.0)
snap.mediaId = id
if (context.config.getBoolean("enable_snap_type_override")) {
val overrideType = context.config.getString("snap_type_override", "IMAGE")
snap.mediaType = MediaType.valueOf(overrideType)
} else {
snap.mediaType = MediaType.IMAGE()
}
val snap = LiveSnapMedia().apply { mediaId = id }

val paramPackage = ParameterPackage(
timer == 0.0,
timer,
true,
0.0,
null,
null,
null,
Expand Down
7 changes: 0 additions & 7 deletions app/src/main/res/xml/root_preferences.xml
Original file line number Diff line number Diff line change
Expand Up @@ -186,13 +186,6 @@
app:summary="@string/override_snap_description"
app:iconSpaceReserved="false" />

<EditTextPreference
app:key="override_snap_timer"
app:title="@string/gallery_snap_time_title"
app:summary="@string/override_snap_timer_description"
app:iconSpaceReserved="false"
app:defaultValue="0" />

<SwitchPreferenceCompat
app:key="allow_save_snaps"
app:title="@string/allow_save_snaps_title"
Expand Down

0 comments on commit 4507d85

Please sign in to comment.