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

Changed default file type to MP3 (#35) #36

Merged
merged 2 commits into from
Sep 20, 2024
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
Original file line number Diff line number Diff line change
Expand Up @@ -147,8 +147,8 @@ class SettingsActivity : SimpleActivity() {
binding.settingsExtension.text = config.getExtensionText()
binding.settingsExtensionHolder.setOnClickListener {
val items = arrayListOf(
RadioItem(EXTENSION_M4A, getString(R.string.m4a)),
RadioItem(EXTENSION_MP3, getString(R.string.mp3))
RadioItem(EXTENSION_MP3, getString(R.string.mp3)),
RadioItem(EXTENSION_M4A, getString(R.string.m4a))
)

if (isQPlus()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class Config(context: Context) : BaseConfig(context) {
set(saveRecordingsFolder) = prefs.edit().putString(SAVE_RECORDINGS, saveRecordingsFolder).apply()

var extension: Int
get() = prefs.getInt(EXTENSION, EXTENSION_M4A)
get() = prefs.getInt(EXTENSION, EXTENSION_MP3)
set(extension) = prefs.edit().putInt(EXTENSION, extension).apply()

var audioSource: Int
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const val EXTENSION_MP3 = 1
const val EXTENSION_OGG = 2

val BITRATES = arrayListOf(32000, 64000, 96000, 128000, 160000, 192000, 256000, 320000)
const val DEFAULT_BITRATE = 128000
const val DEFAULT_BITRATE = 192000
const val SAMPLE_RATE = 44100

const val RECORDING_RUNNING = 0
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/res/layout/activity_settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/settings_extension_label"
tools:text="@string/m4a" />
tools:text="@string/mp3" />

</RelativeLayout>

Expand Down Expand Up @@ -265,7 +265,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/settings_bitrate_label"
tools:text="128 kbps" />
tools:text="192 kbps" />

</RelativeLayout>

Expand Down