summaryrefslogtreecommitdiff
path: root/kotlin/res
diff options
context:
space:
mode:
Diffstat (limited to 'kotlin/res')
-rw-r--r--kotlin/res/drawable/kscope_audio_preview_pause_ic.xml10
-rw-r--r--kotlin/res/drawable/kscope_audio_preview_play_ic.xml10
-rw-r--r--kotlin/res/layout/kscope_audio_preview.xml118
-rw-r--r--kotlin/res/values-night/kscope_themes.xml18
-rw-r--r--kotlin/res/values/kscope_strings.xml18
-rw-r--r--kotlin/res/values/kscope_themes.xml18
6 files changed, 192 insertions, 0 deletions
diff --git a/kotlin/res/drawable/kscope_audio_preview_pause_ic.xml b/kotlin/res/drawable/kscope_audio_preview_pause_ic.xml
new file mode 100644
index 0000000..6d9f364
--- /dev/null
+++ b/kotlin/res/drawable/kscope_audio_preview_pause_ic.xml
@@ -0,0 +1,10 @@
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+ android:width="24dp"
+ android:height="24dp"
+ android:viewportWidth="24"
+ android:tint="?android:colorControlNormal"
+ android:viewportHeight="24">
+ <path
+ android:fillColor="@android:color/white"
+ android:pathData="M6,19h4L10,5L6,5v14zM14,5v14h4L18,5h-4z" />
+</vector>
diff --git a/kotlin/res/drawable/kscope_audio_preview_play_ic.xml b/kotlin/res/drawable/kscope_audio_preview_play_ic.xml
new file mode 100644
index 0000000..6338e3d
--- /dev/null
+++ b/kotlin/res/drawable/kscope_audio_preview_play_ic.xml
@@ -0,0 +1,10 @@
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+ android:width="24dp"
+ android:height="24dp"
+ android:viewportWidth="24"
+ android:tint="?android:colorControlNormal"
+ android:viewportHeight="24">
+ <path
+ android:fillColor="@android:color/white"
+ android:pathData="M8,5v14l11,-7z" />
+</vector>
diff --git a/kotlin/res/layout/kscope_audio_preview.xml b/kotlin/res/layout/kscope_audio_preview.xml
new file mode 100644
index 0000000..fb38e75
--- /dev/null
+++ b/kotlin/res/layout/kscope_audio_preview.xml
@@ -0,0 +1,118 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2022 Project Kaleidoscope
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:minWidth="500dp"
+ android:orientation="vertical"
+ android:padding="15dp">
+
+ <ProgressBar
+ android:id="@+id/spinner"
+ style="?android:attr/progressBarStyleLarge"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_gravity="center" />
+
+ <TextView
+ android:id="@+id/loading"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_gravity="center"
+ android:paddingTop="5dp"
+ android:textColor="#ffffffff"
+ android:textSize="14sp" />
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="vertical"
+ android:paddingLeft="8dp"
+ android:paddingRight="8dp">
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginLeft="8dp"
+ android:gravity="center_horizontal"
+ android:orientation="vertical">
+
+ <TextView
+ android:id="@+id/line1"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:ellipsize="end"
+ android:paddingTop="5dp"
+ android:singleLine="true"
+ android:textAppearance="?android:textAppearanceLarge" />
+
+ <TextView
+ android:id="@+id/line2"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:ellipsize="end"
+ android:paddingTop="5dp"
+ android:textAppearance="?android:textAppearanceSmall" />
+
+ </LinearLayout>
+
+ <SeekBar
+ android:id="@+id/progress"
+ android:layout_width="match_parent"
+ android:layout_marginTop="15dp"
+ android:layout_height="wrap_content"
+ android:visibility="gone" />
+
+ <RelativeLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content">
+
+ <TextView
+ android:id="@+id/audio_played_time"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentStart="true" />
+
+ <TextView
+ android:id="@+id/audio_total_time"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_alignParentEnd="true" />
+
+ </RelativeLayout>
+
+ </LinearLayout>
+
+ <LinearLayout
+ android:id="@+id/titleandbuttons"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="vertical"
+ android:visibility="gone">
+
+ <ImageButton
+ android:id="@+id/playpause"
+ android:layout_width="48dp"
+ android:layout_height="48dp"
+ android:layout_gravity="center_horizontal"
+ android:background="?android:selectableItemBackgroundBorderless"
+ android:onClick="playPauseClicked"
+ android:src="@drawable/kscope_audio_preview_pause_ic" />
+
+ </LinearLayout>
+
+</LinearLayout>
diff --git a/kotlin/res/values-night/kscope_themes.xml b/kotlin/res/values-night/kscope_themes.xml
new file mode 100644
index 0000000..f3befc2
--- /dev/null
+++ b/kotlin/res/values-night/kscope_themes.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2022 Project Kaleidoscope
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<resources>
+ <style name="Theme.Kscope.AudioPreview" parent="android:Theme.DeviceDefault.Dialog" />
+</resources>
diff --git a/kotlin/res/values/kscope_strings.xml b/kotlin/res/values/kscope_strings.xml
new file mode 100644
index 0000000..4e52507
--- /dev/null
+++ b/kotlin/res/values/kscope_strings.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2022 Project Kaleidoscope
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<resources>
+ <string name="kscope_audio_preview_artist_unknown">Unknown Artist</string>
+</resources>
diff --git a/kotlin/res/values/kscope_themes.xml b/kotlin/res/values/kscope_themes.xml
new file mode 100644
index 0000000..36a1f65
--- /dev/null
+++ b/kotlin/res/values/kscope_themes.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2022 Project Kaleidoscope
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<resources>
+ <style name="Theme.Kscope.AudioPreview" parent="android:Theme.DeviceDefault.Light.Dialog" />
+</resources>