forked from GitHub-Mirror/riotX-android
Code quality: split long lines
This commit is contained in:
@ -26,7 +26,8 @@ import javax.inject.Inject
|
||||
* Test that the application is started on boot
|
||||
*/
|
||||
class TestAutoStartBoot @Inject constructor(private val context: AppCompatActivity,
|
||||
private val stringProvider: StringProvider) : TroubleshootTest(R.string.settings_troubleshoot_test_service_boot_title) {
|
||||
private val stringProvider: StringProvider)
|
||||
: TroubleshootTest(R.string.settings_troubleshoot_test_service_boot_title) {
|
||||
|
||||
override fun perform() {
|
||||
if (PreferencesManager.autoStartOnBoot(context)) {
|
||||
|
@ -25,7 +25,8 @@ import im.vector.riotx.features.settings.troubleshoot.TroubleshootTest
|
||||
import javax.inject.Inject
|
||||
|
||||
class TestBackgroundRestrictions @Inject constructor(private val context: AppCompatActivity,
|
||||
private val stringProvider: StringProvider) : TroubleshootTest(R.string.settings_troubleshoot_test_bg_restricted_title) {
|
||||
private val stringProvider: StringProvider)
|
||||
: TroubleshootTest(R.string.settings_troubleshoot_test_bg_restricted_title) {
|
||||
|
||||
override fun perform() {
|
||||
(context.getSystemService(Context.CONNECTIVITY_SERVICE) as ConnectivityManager).apply {
|
||||
|
@ -28,7 +28,8 @@ import javax.inject.Inject
|
||||
* Check that the play services APK is available an up-to-date. If needed provide quick fix to install it.
|
||||
*/
|
||||
class TestPlayServices @Inject constructor(private val context: AppCompatActivity,
|
||||
private val stringProvider: StringProvider) : TroubleshootTest(R.string.settings_troubleshoot_test_play_services_title) {
|
||||
private val stringProvider: StringProvider)
|
||||
: TroubleshootTest(R.string.settings_troubleshoot_test_play_services_title) {
|
||||
|
||||
override fun perform() {
|
||||
val apiAvailability = GoogleApiAvailability.getInstance()
|
||||
|
@ -34,7 +34,8 @@ import javax.inject.Inject
|
||||
class TestTokenRegistration @Inject constructor(private val context: AppCompatActivity,
|
||||
private val stringProvider: StringProvider,
|
||||
private val pushersManager: PushersManager,
|
||||
private val activeSessionHolder: ActiveSessionHolder) : TroubleshootTest(R.string.settings_troubleshoot_test_token_registration_title) {
|
||||
private val activeSessionHolder: ActiveSessionHolder)
|
||||
: TroubleshootTest(R.string.settings_troubleshoot_test_token_registration_title) {
|
||||
|
||||
override fun perform() {
|
||||
//Check if we have a registered pusher for this token
|
||||
|
@ -178,7 +178,8 @@ class MessageMenuViewModel @AssistedInject constructor(@Assisted initialState: M
|
||||
|
||||
this.add(SimpleAction(VIEW_SOURCE, R.string.view_source, R.drawable.ic_view_source,event.root.toContentStringWithIndent()))
|
||||
if (event.isEncrypted()) {
|
||||
val decryptedContent = event.root.toClearContentStringWithIndent() ?: stringProvider.getString(R.string.encryption_information_decryption_error)
|
||||
val decryptedContent = event.root.toClearContentStringWithIndent()
|
||||
?: stringProvider.getString(R.string.encryption_information_decryption_error)
|
||||
this.add(SimpleAction(VIEW_DECRYPTED_SOURCE, R.string.view_decrypted_source, R.drawable.ic_view_source, decryptedContent))
|
||||
}
|
||||
this.add(SimpleAction(ACTION_COPY_PERMALINK, R.string.permalink, R.drawable.ic_permalink, event.root.eventId))
|
||||
|
Reference in New Issue
Block a user