mirror of
https://github.com/oxen-io/session-android.git
synced 2025-08-26 02:58:08 +00:00
Use waveform seek bar for audio message view.
This commit is contained in:
@@ -70,10 +70,18 @@
|
||||
|
||||
</org.thoughtcrime.securesms.components.AnimatingToggle>
|
||||
|
||||
<SeekBar android:id="@+id/seek"
|
||||
<!-- TODO: Extract styling attributes into a theme. -->
|
||||
<org.thoughtcrime.securesms.components.WaveformSeekBar
|
||||
android:id="@+id/seek"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"/>
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
app:wave_background_color="#bbb"
|
||||
app:wave_progress_color="?colorPrimary"
|
||||
app:wave_gravity="center"
|
||||
app:wave_width="4dp"
|
||||
app:wave_corner_radius="2dp"
|
||||
app:wave_gap="1dp"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
@@ -287,4 +287,20 @@
|
||||
<attr name="labeledEditText_background" format="color" />
|
||||
<attr name="labeledEditText_textLayout" format="reference" />
|
||||
</declare-styleable>
|
||||
|
||||
<declare-styleable name="WaveformSeekBar">
|
||||
<attr name="wave_progress" format="float"/>
|
||||
<attr name="wave_width" format="dimension"/>
|
||||
<attr name="wave_gap" format="dimension"/>
|
||||
<attr name="wave_min_height" format="dimension"/>
|
||||
<attr name="wave_corner_radius" format="dimension"/>
|
||||
<attr name="wave_background_color" format="color"/>
|
||||
<attr name="wave_progress_color" format="color"/>
|
||||
<!-- Corresponds to WaveformSeekBar.WaveGravity enum. -->
|
||||
<attr name="wave_gravity" format="enum">
|
||||
<enum name="top" value="1" />
|
||||
<enum name="center" value="2" />
|
||||
<enum name="bottom" value="3" />
|
||||
</attr>
|
||||
</declare-styleable>
|
||||
</resources>
|
||||
|
Reference in New Issue
Block a user