Skip to content

Commit

Permalink
Remove comments
Browse files Browse the repository at this point in the history
  • Loading branch information
peyman-mohtashami committed Jun 18, 2021
1 parent 767ab17 commit 9cbb317
Show file tree
Hide file tree
Showing 10 changed files with 29 additions and 71 deletions.
1 change: 0 additions & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
<uses-permission android:name="android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS" />
<uses-permission android:name="android.permission.WAKE_LOCK" />

<!-- <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />-->
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" />

<supports-screens android:largeScreens="true"
Expand Down
1 change: 0 additions & 1 deletion app/src/main/java/org/radarcns/detail/InfoActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ class InfoActivity : AppCompatActivity() {
findViewById<TextView>(R.id.version).text = BuildConfig.VERSION_NAME

radarConfig.config.observe(this, { config ->

findViewById<TextView>(R.id.server_base_url).text = config.getString(BASE_URL_KEY, "")

policyUrl = config.optString(PRIVACY_POLICY)
Expand Down
38 changes: 25 additions & 13 deletions app/src/main/res/layout/activity_settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,38 +22,50 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/network_settings_header"
android:textColor="?attr/colorPrimaryDark"

android:textStyle="bold"
app:layout_constraintEnd_toEndOf="@+id/enableDataSwitch"
app:layout_constraintStart_toStartOf="@+id/enableDataSwitch"
app:layout_constraintTop_toTopOf="parent" />
android:layout_marginStart="5dp"
android:layout_marginTop="10dp"
android:layout_marginBottom="5dp"
app:layout_constraintStart_toStartOf="@id/constraintLayout"
app:layout_constraintTop_toTopOf="@id/constraintLayout"
app:layout_constraintBottom_toTopOf="@id/enableDataSwitch"
android:textColor="?attr/colorPrimaryDark"/>

<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enableDataSwitch"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="2dp"
android:text="@string/enable_data_for_sending"
app:layout_constraintTop_toBottomOf="@+id/network_settings_header" />
android:layout_marginBottom="5dp"
android:layout_marginTop="5dp"
android:layout_marginStart="5dp"
app:layout_constraintStart_toStartOf="@id/network_settings_header"
app:layout_constraintTop_toBottomOf="@id/network_settings_header"
app:layout_constraintBottom_toTopOf="@id/enableDataHighPrioritySwitch"/>

<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enableDataHighPrioritySwitch"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:enabled="false"
android:text="@string/enable_data_high_priority_only"
app:layout_constraintTop_toBottomOf="@id/enableDataSwitch" />
android:enabled="false"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:layout_marginStart="35dp"
app:layout_constraintTop_toBottomOf="@id/enableDataSwitch"
app:layout_constraintStart_toStartOf="@id/enableDataSwitch"/>

<Button
android:id="@+id/resetSettingsButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:onClick="startReset"
android:layout_marginTop="10dp"
android:layout_marginStart="5dp"
android:text="@string/button_reset"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/enableDataHighPrioritySwitch" />
android:onClick="startReset"
app:layout_constraintTop_toBottomOf="@id/enableDataHighPrioritySwitch"
app:layout_constraintBottom_toBottomOf="@id/constraintLayout"
app:layout_constraintStart_toStartOf="@id/constraintLayout"/>

</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.core.widget.NestedScrollView>
Expand Down
50 changes: 3 additions & 47 deletions app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -122,59 +122,15 @@
<string name="bootstart_title">Please start RADAR pRMT</string>
<string name="bootstart_text">RADAR pRMT has automatically been stopped. Please press this notification to start it again.</string>

<!-- Auto update -->
<!-- <string name="update_notification_title">Auto Update App</string>-->
<string name="update_notification_content">New version is available.\nClick to download.</string>
<!-- <string name="notification_update_channel_id">com.example.autoupdatetest1</string>-->
<!-- <string name="notification_update_channel_name">auto_update_test</string>-->
<string name="action_favorite">Favorites</string>
<string name="action_settings">Settings</string>
<string name="title_activity_main">MainActivity</string>
<!-- Strings used for fragments for navigation -->
<string name="first_fragment_label">First Fragment</string>
<string name="second_fragment_label">Second Fragment</string>
<string name="next">Next</string>
<string name="previous">Previous</string>

<string name="hello_first_fragment">Hello first fragment</string>
<string name="hello_second_fragment">Hello second fragment. Arg: %1$s</string>
<string name="title_activity_settings">SettingsActivity</string>

<!-- Preference Titles -->
<string name="messages_header">Messages</string>
<string name="sync_header">Sync</string>

<!-- Messages Preferences -->
<string name="signature_title">Your signature</string>
<string name="reply_title">Default reply action</string>

<!-- Updates -->
<!-- Updates -->
<string name="updates">Updates</string>
<string name="update_notification_content">New version is available.\nClick to download.</string>
<string name="currentVersion">Version: %1$s</string>
<string name="new_version_available">A new version of %1$s App (%2$s) is available.</string>
<string name="new_version_not_available">You installed the latest version of %1$s App.</string>
<string name="check_for_updates">Check For Updates</string>
<string name="no">No</string>
<string name="dont_show_again">Don\'t Show Again</string>
<string name="start_downloading">Start Downloading</string>
<string name="install">Install</string>
<string name="update_settings">Update Settings</string>
<string name="setting_update_header">Auto Update Settings</string>
<string name="settings_update_enable_disable_auto_check_update">Automatically check for updates</string>
<string name="settings_update_enable_disable_notification">Receive notifications on new updates</string>
<string name="settings_update_frequency">Check for updates every:</string>
<string name="settings_update_time">Check for updates at:</string>
<string name="settings_update_notification_time">Notification Time</string>
<string name="last_check">Last check on %1$s</string>
<string name="update_settings_header">Update settings</string>
<string name="enable_update_notification">Receive notifications on new updates</string>
<string name="enable_check_for_update">Automatically check for updates</string>
<string name="update_question">Do you want to install it?</string>
<string name="title_activity_updates">Updates</string>
<string name="hour">Hour</string>
<string name="day">Day</string>
<string name="week">Week</string>
<string name="setting_update_time_hint">Enter Time</string>
<string name="setting_update_time">Check for updates at:</string>
<string name="error_in_package_name_or_signature">Error in package name or signature!</string>
<string name="error_in_package_name">Error in package name!</string>
</resources>
4 changes: 0 additions & 4 deletions app/src/main/res/xml/remote_config_defaults.xml
Original file line number Diff line number Diff line change
Expand Up @@ -98,10 +98,6 @@
<key>update_check_frequency</key>
<value>day</value>
</entry>
<entry>
<key>update_check_time</key>
<value>600</value>
</entry>
<entry>
<key>update_releases_url</key>
<value>https://api.github.com/repos/RADAR-base/radar-prmt-android/releases</value>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import org.radarbase.android.MainActivityView
import org.radarbase.android.RadarApplication.Companion.radarApp

class MainActivityImpl : MainActivity() {

override fun onCreate(savedInstanceState: Bundle?) {
radarApp.notificationHandler.cancel(MainActivityBootStarter.BOOT_START_NOTIFICATION_ID)
super.onCreate(savedInstanceState)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import org.radarbase.android.MainActivityView
import org.radarbase.android.RadarApplication.Companion.radarApp

class MainActivityImpl : MainActivity() {

override fun onCreate(savedInstanceState: Bundle?) {
radarApp.notificationHandler.cancel(MainActivityBootStarter.BOOT_START_NOTIFICATION_ID)
super.onCreate(savedInstanceState)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ import org.radarbase.passive.weather.WeatherApiProvider
import java.util.*

class RadarServiceImpl : RadarService() {

override val plugins: List<SourceProvider<*>> = listOf(
ApplicationStatusProvider(this),
OpenSmileAudioProvider(this),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ class UpdatesActivity : AppCompatActivity(), TaskDelegate {
progressBarContainerLayout.visibility = View.GONE
updateLinearLayout.visibility = View.VISIBLE
}else{
updateStatus.text = getString(R.string.error_in_package_name_or_signature)
updateStatus.text = getString(R.string.error_in_package_name)
progressBarContainerLayout.visibility = View.GONE
}
}
Expand Down
1 change: 0 additions & 1 deletion app/src/selfRelease/res/layout/compact_overview.xml
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,6 @@
android:contentDescription="@string/info"
android:onClick="showInfo"
android:src="@drawable/ic_info_black" />

<ImageButton
android:id="@+id/updateButton"
android:layout_width="40dp"
Expand Down

0 comments on commit 9cbb317

Please sign in to comment.