1
0
mirror of https://github.com/etesync/android synced 2024-11-22 16:08:13 +00:00

Kotlin: more kotlin migration.

This commit is contained in:
Tom Hacohen 2019-01-05 15:40:17 +00:00
parent f0a0717541
commit e38c720d1a
8 changed files with 16 additions and 16 deletions

View File

@ -46,7 +46,7 @@ import java.util.logging.Level
class AccountActivity : BaseActivity(), Toolbar.OnMenuItemClickListener, PopupMenu.OnMenuItemClickListener, LoaderManager.LoaderCallbacks<AccountActivity.AccountInfo>, Refreshable { class AccountActivity : BaseActivity(), Toolbar.OnMenuItemClickListener, PopupMenu.OnMenuItemClickListener, LoaderManager.LoaderCallbacks<AccountActivity.AccountInfo>, Refreshable {
private var account: Account? = null private lateinit var account: Account
private var accountInfo: AccountInfo? = null private var accountInfo: AccountInfo? = null
internal var listCalDAV: ListView? = null internal var listCalDAV: ListView? = null

View File

@ -31,7 +31,7 @@ import com.etesync.syncadapter.ui.setup.LoginCredentials
import com.etesync.syncadapter.ui.setup.LoginCredentialsChangeFragment import com.etesync.syncadapter.ui.setup.LoginCredentialsChangeFragment
class AccountSettingsActivity : BaseActivity() { class AccountSettingsActivity : BaseActivity() {
private var account: Account? = null private lateinit var account: Account
override fun onCreate(savedInstanceState: Bundle?) { override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState) super.onCreate(savedInstanceState)

View File

@ -19,13 +19,13 @@ import com.etesync.syncadapter.model.CollectionInfo
import okhttp3.HttpUrl import okhttp3.HttpUrl
class AddMemberFragment : DialogFragment() { class AddMemberFragment : DialogFragment() {
private var account: Account? = null private lateinit var account: Account
private var settings: AccountSettings? = null private var settings: AccountSettings? = null
private var ctx: Context? = null private var ctx: Context? = null
private var remote: HttpUrl? = null private var remote: HttpUrl? = null
private var info: CollectionInfo? = null private lateinit var info: CollectionInfo
private var memberEmail: String? = null private lateinit var memberEmail: String
private var memberPubKey: ByteArray? = null private lateinit var memberPubKey: ByteArray
override fun onCreate(savedInstanceState: Bundle?) { override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState) super.onCreate(savedInstanceState)
@ -62,7 +62,7 @@ class AddMemberFragment : DialogFragment() {
val userInfo = userInfoManager[memberEmail!!] val userInfo = userInfoManager[memberEmail!!]
?: throw Exception(getString(R.string.collection_members_error_user_not_found, memberEmail)) ?: throw Exception(getString(R.string.collection_members_error_user_not_found, memberEmail))
memberPubKey = userInfo.pubkey memberPubKey = userInfo.pubkey!!
return AddResult(null) return AddResult(null)
} catch (e: Exception) { } catch (e: Exception) {
return AddResult(e) return AddResult(e)

View File

@ -39,8 +39,8 @@ import java.io.IOException
class ImportFragment : DialogFragment() { class ImportFragment : DialogFragment() {
private var account: Account? = null private lateinit var account: Account
private var info: CollectionInfo? = null private lateinit var info: CollectionInfo
private var importFile: File? = null private var importFile: File? = null
override fun onCreate(savedInstanceState: Bundle?) { override fun onCreate(savedInstanceState: Bundle?) {

View File

@ -24,8 +24,8 @@ import com.etesync.syncadapter.resource.LocalEvent
class LocalCalendarImportFragment : ListFragment() { class LocalCalendarImportFragment : ListFragment() {
private var account: Account? = null private lateinit var account: Account
private var info: CollectionInfo? = null private lateinit var info: CollectionInfo
override fun onCreate(savedInstanceState: Bundle?) { override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState) super.onCreate(savedInstanceState)

View File

@ -31,8 +31,8 @@ import java.util.*
class LocalContactImportFragment : Fragment() { class LocalContactImportFragment : Fragment() {
private var account: Account? = null private lateinit var account: Account
private var info: CollectionInfo? = null private lateinit var info: CollectionInfo
private var recyclerView: RecyclerView? = null private var recyclerView: RecyclerView? = null
override fun onCreate(savedInstanceState: Bundle?) { override fun onCreate(savedInstanceState: Bundle?) {

View File

@ -28,7 +28,7 @@ import com.etesync.syncadapter.ui.setup.BaseConfigurationFinder.Configuration
import java.util.logging.Level import java.util.logging.Level
class LoginCredentialsChangeFragment : DialogFragment(), LoaderManager.LoaderCallbacks<Configuration> { class LoginCredentialsChangeFragment : DialogFragment(), LoaderManager.LoaderCallbacks<Configuration> {
private var account: Account? = null private lateinit var account: Account
override fun onCreateDialog(savedInstanceState: Bundle?): Dialog { override fun onCreateDialog(savedInstanceState: Bundle?): Dialog {
val progress = ProgressDialog(activity) val progress = ProgressDialog(activity)

View File

@ -16,8 +16,8 @@ import com.etesync.syncadapter.journalmanager.UserInfoManager
import okhttp3.HttpUrl import okhttp3.HttpUrl
class SetupUserInfoFragment : DialogFragment() { class SetupUserInfoFragment : DialogFragment() {
private var account: Account? = null private lateinit var account: Account
private var settings: AccountSettings? = null private lateinit var settings: AccountSettings
override fun onCreateDialog(savedInstanceState: Bundle?): Dialog { override fun onCreateDialog(savedInstanceState: Bundle?): Dialog {
val progress = ProgressDialog(activity) val progress = ProgressDialog(activity)