mirror of
https://github.com/SimpleMobileTools/Simple-Voice-Recorder.git
synced 2025-06-05 21:59:31 +02:00
adding a frame at the main screen to make it a bit more interesting
This commit is contained in:
@ -10,6 +10,7 @@ import com.simplemobiletools.commons.helpers.*
|
|||||||
import com.simplemobiletools.commons.models.FAQItem
|
import com.simplemobiletools.commons.models.FAQItem
|
||||||
import com.simplemobiletools.voicerecorder.BuildConfig
|
import com.simplemobiletools.voicerecorder.BuildConfig
|
||||||
import com.simplemobiletools.voicerecorder.R
|
import com.simplemobiletools.voicerecorder.R
|
||||||
|
import com.simplemobiletools.voicerecorder.extensions.config
|
||||||
import com.simplemobiletools.voicerecorder.helpers.GET_RECORDER_INFO
|
import com.simplemobiletools.voicerecorder.helpers.GET_RECORDER_INFO
|
||||||
import com.simplemobiletools.voicerecorder.helpers.STOP_AMPLITUDE_UPDATE
|
import com.simplemobiletools.voicerecorder.helpers.STOP_AMPLITUDE_UPDATE
|
||||||
import com.simplemobiletools.voicerecorder.models.Events
|
import com.simplemobiletools.voicerecorder.models.Events
|
||||||
@ -50,6 +51,7 @@ class MainActivity : SimpleActivity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
visualizer.chunkColor = adjustedPrimaryColor
|
visualizer.chunkColor = adjustedPrimaryColor
|
||||||
|
recording_duration.setTextColor(config.textColor)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onDestroy() {
|
override fun onDestroy() {
|
||||||
|
13
app/src/main/res/drawable/frame_background.xml
Normal file
13
app/src/main/res/drawable/frame_background.xml
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:shape="rectangle">
|
||||||
|
|
||||||
|
<stroke
|
||||||
|
android:width="@dimen/one_dp"
|
||||||
|
android:color="@color/divider_grey" />
|
||||||
|
|
||||||
|
<corners android:radius="@dimen/normal_margin" />
|
||||||
|
|
||||||
|
<solid android:color="@color/activated_item_foreground" />
|
||||||
|
|
||||||
|
</shape>
|
@ -11,9 +11,8 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_above="@+id/recording_duration"
|
android:layout_above="@+id/recording_duration"
|
||||||
android:layout_marginTop="@dimen/activity_margin"
|
android:layout_margin="@dimen/big_margin"
|
||||||
android:layout_marginEnd="@dimen/activity_margin"
|
android:background="@drawable/frame_background"
|
||||||
android:layout_marginBottom="@dimen/activity_margin"
|
|
||||||
app:chunkAlignTo="center"
|
app:chunkAlignTo="center"
|
||||||
app:chunkMaxHeight="200dp"
|
app:chunkMaxHeight="200dp"
|
||||||
app:chunkMinHeight="2dp"
|
app:chunkMinHeight="2dp"
|
||||||
@ -22,7 +21,7 @@
|
|||||||
app:chunkSpace="1dp"
|
app:chunkSpace="1dp"
|
||||||
app:chunkWidth="3dp" />
|
app:chunkWidth="3dp" />
|
||||||
|
|
||||||
<TextView
|
<com.simplemobiletools.commons.views.MyTextView
|
||||||
android:id="@+id/recording_duration"
|
android:id="@+id/recording_duration"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
Reference in New Issue
Block a user