mirror of
https://github.com/atsunatsu/Look4Sat.git
synced 2026-10-04 19:47:22 +00:00
Optimized transmitters adapter, changes to the recycler and ViewHolders
This commit is contained in:
1 parent
69b3e4f70b
commit
810fa5b85c
12 files changed
+152
-303
No files matched your search
@@ -1,22 +1,3 @@
|
||||
<!--
|
||||
~ Look4Sat. Amateur radio and weather satellite tracker and passes predictor for Android.
|
||||
~ Copyright (C) 2019, 2020 Arty Bishop (bishop.arty@gmail.com)
|
||||
~
|
||||
~ This program is free software; you can redistribute it and/or modify
|
||||
~ it under the terms of the GNU General Public License as published by
|
||||
~ the Free Software Foundation; either version 2 of the License, or
|
||||
~ (at your option) any later version.
|
||||
~
|
||||
~ This program is distributed in the hope that it will be useful,
|
||||
~ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
~ GNU General Public License for more details.
|
||||
~
|
||||
~ You should have received a copy of the GNU General Public License along
|
||||
~ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
~ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
-->
|
||||
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
@@ -24,5 +5,5 @@
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="@color/themeLight"
|
||||
android:pathData="M7.41,15.41L12,10.83l4.59,4.58L18,14l-6,-6 -6,6z" />
|
||||
android:pathData="M8,5v14l11,-7z" />
|
||||
</vector>
|
||||
@@ -28,10 +28,7 @@
|
||||
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
android:id="@+id/entries_bar"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="48dp"
|
||||
app:cardCornerRadius="0dp"
|
||||
app:cardElevation="1dp"
|
||||
style="@style/TopBar"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
@@ -29,10 +29,7 @@
|
||||
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
android:id="@+id/passes_bar"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="48dp"
|
||||
app:cardCornerRadius="0dp"
|
||||
app:cardElevation="1dp"
|
||||
style="@style/TopBar"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
@@ -23,6 +23,13 @@
|
||||
android:layout_height="match_parent"
|
||||
android:keepScreenOn="true">
|
||||
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
android:id="@+id/polar_bar"
|
||||
style="@style/TopBar"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/frame"
|
||||
android:layout_width="match_parent"
|
||||
@@ -30,7 +37,7 @@
|
||||
app:layout_constraintDimensionRatio="1:1"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
app:layout_constraintTop_toBottomOf="@+id/polar_bar" />
|
||||
|
||||
<com.google.android.material.textview.MaterialTextView
|
||||
android:id="@+id/azimuth"
|
||||
@@ -76,7 +83,7 @@
|
||||
android:id="@+id/recycler"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:paddingBottom="4dp"
|
||||
android:padding="2dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
@@ -92,7 +99,6 @@
|
||||
android:textSize="15sp"
|
||||
android:visibility="invisible"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/frame" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -19,177 +19,120 @@
|
||||
|
||||
<com.google.android.material.card.MaterialCardView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/trans_card"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="4dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:layout_marginEnd="4dp"
|
||||
app:cardElevation="1dp">
|
||||
app:cardCornerRadius="0dp">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<com.google.android.material.textview.MaterialTextView
|
||||
android:id="@+id/trans_description"
|
||||
android:layout_width="wrap_content"
|
||||
android:id="@+id/description"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="4dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:ellipsize="end"
|
||||
android:maxLines="1"
|
||||
android:text="@string/trans_description"
|
||||
android:textSize="15sp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/trans_img"
|
||||
app:layout_constraintStart_toEndOf="@+id/trans_img"
|
||||
app:layout_constraintTop_toTopOf="@+id/trans_img" />
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_chainStyle="spread_inside"
|
||||
app:layout_constraintStart_toEndOf="@+id/img_trans"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.google.android.material.textview.MaterialTextView
|
||||
android:id="@+id/trans_downlink"
|
||||
android:id="@+id/downlink"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/trans_down_lowHigh"
|
||||
android:textSize="15sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/trans_img_downlink"
|
||||
app:layout_constraintTop_toBottomOf="@+id/trans_description" />
|
||||
|
||||
<com.google.android.material.textview.MaterialTextView
|
||||
android:id="@+id/trans_uplink"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/trans_up_lowHigh"
|
||||
android:textSize="15sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/trans_img_uplink"
|
||||
app:layout_constraintTop_toBottomOf="@+id/trans_downlink" />
|
||||
|
||||
<View
|
||||
android:id="@+id/separator"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginStart="8dp"
|
||||
android:layout_marginTop="2dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:background="@color/greyLight"
|
||||
android:padding="15dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:layout_marginTop="4dp"
|
||||
android:fontFamily="@font/digital_dismay"
|
||||
android:text="@string/trans_down_low_doppler"
|
||||
android:textColor="@color/themeLight"
|
||||
android:textSize="30sp"
|
||||
app:layout_constraintEnd_toStartOf="@+id/img_downlink"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/trans_uplink" />
|
||||
app:layout_constraintTop_toBottomOf="@+id/description" />
|
||||
|
||||
<com.google.android.material.textview.MaterialTextView
|
||||
android:id="@+id/trans_downlink_doppler"
|
||||
android:id="@+id/uplink"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="1dp"
|
||||
android:text="@string/trans_down_lowHigh_doppler"
|
||||
android:textSize="15sp"
|
||||
android:fontFamily="@font/digital_dismay"
|
||||
android:text="@string/trans_down_low_doppler"
|
||||
android:textColor="@color/themeLight"
|
||||
android:textSize="30sp"
|
||||
app:layout_constraintBaseline_toBaselineOf="@+id/downlink"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/trans_img_downlink_doppler"
|
||||
app:layout_constraintTop_toBottomOf="@+id/separator" />
|
||||
app:layout_constraintStart_toEndOf="@+id/img_uplink" />
|
||||
|
||||
<com.google.android.material.textview.MaterialTextView
|
||||
android:id="@+id/trans_uplink_doppler"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/trans_up_lowHigh_doppler"
|
||||
android:textSize="15sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/trans_img_uplink_doppler"
|
||||
app:layout_constraintTop_toBottomOf="@+id/trans_downlink_doppler" />
|
||||
|
||||
<com.google.android.material.textview.MaterialTextView
|
||||
android:id="@+id/trans_mode"
|
||||
android:id="@+id/mode"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="6dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:layout_marginBottom="2dp"
|
||||
android:text="@string/trans_mode"
|
||||
android:textSize="15sp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/isInverted"
|
||||
app:layout_constraintHorizontal_chainStyle="spread_inside"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/trans_uplink_doppler" />
|
||||
app:layout_constraintTop_toBottomOf="@+id/downlink" />
|
||||
|
||||
<com.google.android.material.textview.MaterialTextView
|
||||
android:id="@+id/trans_inverted"
|
||||
android:id="@+id/isInverted"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:text="@string/trans_inverted"
|
||||
android:textSize="15sp"
|
||||
app:layout_constraintBaseline_toBaselineOf="@+id/trans_mode"
|
||||
app:layout_constraintEnd_toEndOf="parent" />
|
||||
app:layout_constraintBaseline_toBaselineOf="@+id/mode"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/mode" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/trans_img"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:id="@+id/img_trans"
|
||||
android:layout_width="18dp"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginStart="4dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:contentDescription="@string/placeholder"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/description"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/description"
|
||||
app:srcCompat="@drawable/ic_trans" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/trans_img_downlink"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginTop="1dp"
|
||||
android:id="@+id/img_downlink"
|
||||
android:layout_width="18dp"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginEnd="4dp"
|
||||
android:contentDescription="@string/placeholder"
|
||||
android:rotation="180"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/trans_downlink"
|
||||
app:layout_constraintEnd_toStartOf="@+id/trans_downlink"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/trans_downlink"
|
||||
android:rotation="90"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/downlink"
|
||||
app:layout_constraintEnd_toStartOf="@+id/guideline"
|
||||
app:layout_constraintTop_toTopOf="@+id/downlink"
|
||||
app:srcCompat="@drawable/ic_arrow" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/trans_img_uplink"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginTop="1dp"
|
||||
android:id="@+id/img_uplink"
|
||||
android:layout_width="18dp"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginStart="4dp"
|
||||
android:contentDescription="@string/placeholder"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/trans_uplink"
|
||||
app:layout_constraintEnd_toStartOf="@+id/trans_uplink"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
android:rotation="270"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/uplink"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/trans_downlink"
|
||||
app:layout_constraintStart_toStartOf="@+id/guideline"
|
||||
app:layout_constraintTop_toTopOf="@+id/uplink"
|
||||
app:srcCompat="@drawable/ic_arrow" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/trans_img_downlink_doppler"
|
||||
android:layout_width="16dp"
|
||||
android:layout_height="16dp"
|
||||
android:layout_marginTop="1dp"
|
||||
android:layout_marginEnd="2dp"
|
||||
android:contentDescription="@string/placeholder"
|
||||
android:rotation="180"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/trans_downlink_doppler"
|
||||
app:layout_constraintEnd_toStartOf="@+id/trans_downlink_doppler"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/trans_downlink_doppler"
|
||||
app:srcCompat="@drawable/ic_trans_doppler" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/trans_img_uplink_doppler"
|
||||
android:layout_width="16dp"
|
||||
android:layout_height="16dp"
|
||||
android:layout_marginTop="1dp"
|
||||
android:layout_marginEnd="2dp"
|
||||
android:contentDescription="@string/placeholder"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/trans_uplink_doppler"
|
||||
app:layout_constraintEnd_toStartOf="@+id/trans_uplink_doppler"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/trans_downlink_doppler"
|
||||
app:srcCompat="@drawable/ic_trans_doppler" />
|
||||
|
||||
<androidx.constraintlayout.widget.Guideline
|
||||
android:id="@+id/guideline"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintGuide_percent="0.5" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</com.google.android.material.card.MaterialCardView>
|
||||
@@ -45,10 +45,7 @@
|
||||
<string name="pref_time_utc_title">Показывать время пролета по UTC</string>
|
||||
|
||||
<string name="no_mode">Модуляция: нет</string>
|
||||
<string name="no_uplink">Восход: нет</string>
|
||||
<string name="no_downlink">Нисход: нет</string>
|
||||
<string name="no_uplink_doppler">Тек. восход: нет</string>
|
||||
<string name="no_downlink_doppler">Тек. нисход: нет</string>
|
||||
<string name="no_downlink_doppler">нет</string>
|
||||
<string name="no_trans">Не найдены трансиверы для этого спутника</string>
|
||||
|
||||
<string name="error_updating_data">Ошибка импорта спутников</string>
|
||||
@@ -63,14 +60,6 @@
|
||||
|
||||
<string name="trans_mode">Модуляция: %s</string>
|
||||
<string name="trans_inverted">Инверсия: %s</string>
|
||||
<string name="trans_up_low">Восход: %.4fMHz</string>
|
||||
<string name="trans_up_lowHigh">Восход: %.4f - %.4fMHz</string>
|
||||
<string name="trans_down_low">Нисход: %.4f MHz</string>
|
||||
<string name="trans_down_lowHigh">Нисход: %.4f - %.4fMHz</string>
|
||||
<string name="trans_up_low_doppler">Тек. восход: %.4fMHz</string>
|
||||
<string name="trans_up_lowHigh_doppler">Тек. восход: %.4f - %.4fMHz</string>
|
||||
<string name="trans_down_low_doppler">Тек. нисход: %.4fMHz</string>
|
||||
<string name="trans_down_lowHigh_doppler">Тек. нисход: %.4f - %.4fMHz</string>
|
||||
|
||||
<string name="about_subtitle">Приложение для слежения за спутниками радио и погоды
|
||||
для платформы Android</string>
|
||||
|
||||
@@ -22,9 +22,9 @@
|
||||
<color name="themeLight">#FFE082</color>
|
||||
<color name="themeDark">#FFCA28</color>
|
||||
<color name="greyDark">#121212</color>
|
||||
<color name="greyLight">#C0C0C0</color>
|
||||
<color name="greyLight">#D0D0D0</color>
|
||||
<color name="greyDivider">#808080</color>
|
||||
<color name="greySurface">#1d1d1d</color>
|
||||
<color name="greySurface">#1e1e1e</color>
|
||||
<!-- map colors -->
|
||||
<color name="satTrack">#B00020</color>
|
||||
<color name="satFootprint">#26FFE082</color>
|
||||
|
||||
@@ -46,10 +46,7 @@
|
||||
<string name="pref_time_utc_title">Show pass time in UTC</string>
|
||||
|
||||
<string name="no_mode">Mode: null</string>
|
||||
<string name="no_uplink">Uplink: null</string>
|
||||
<string name="no_downlink">Downlink: null</string>
|
||||
<string name="no_uplink_doppler">Curr. uplink: null</string>
|
||||
<string name="no_downlink_doppler">Curr. downlink: null</string>
|
||||
<string name="no_downlink_doppler">null</string>
|
||||
<string name="no_trans">No transceivers found for this satellite</string>
|
||||
|
||||
<string name="error_updating_data">Error importing satellite data</string>
|
||||
@@ -69,17 +66,11 @@
|
||||
<string name="pat_osm_latLon">Lat: %.1f°, Lon: %.1f°</string>
|
||||
<string name="pat_osm_vel">Vel: %.2f km/s</string>
|
||||
|
||||
<string name="trans_description" translatable="false">%s</string>
|
||||
<string name="trans_mode">Mode: %s</string>
|
||||
<string name="trans_inverted">Inverted: %s</string>
|
||||
<string name="trans_up_low">Uplink: %.4fMHz</string>
|
||||
<string name="trans_up_lowHigh">Uplink: %.4f - %.4fMHz</string>
|
||||
<string name="trans_down_low">Downlink: %.4fMHz</string>
|
||||
<string name="trans_down_lowHigh">Downlink: %.4f - %.4fMHz</string>
|
||||
<string name="trans_up_low_doppler">Curr. uplink: %.4fMHz</string>
|
||||
<string name="trans_up_lowHigh_doppler">Curr. uplink: %.4f - %.4fMHz</string>
|
||||
<string name="trans_down_low_doppler">Curr. downlink: %.4fMHz</string>
|
||||
<string name="trans_down_lowHigh_doppler">Curr. downlink: %.4f - %.4fMHz</string>
|
||||
<string name="trans_description" translatable="false">%s</string>
|
||||
<string name="trans_down_low_doppler" translatable="false">%.4f</string>
|
||||
<string name="trans_down_lowHigh_doppler" translatable="false">%.4f - %.4f</string>
|
||||
|
||||
<string name="about_subtitle">
|
||||
Amateur radio and weather satellites passes calculator for Android</string>
|
||||
|
||||
@@ -26,4 +26,10 @@
|
||||
<item name="android:statusBarColor">@android:color/transparent</item>
|
||||
</style>
|
||||
|
||||
<style name="TopBar">
|
||||
<item name="android:layout_width">match_parent</item>
|
||||
<item name="android:layout_height">48dp</item>
|
||||
<item name="cardCornerRadius">0dp</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
||||
Reference in new issue
Block a user