Skip to content

Commit c6be74a

Browse files
authored
Optimize imports and remove unused AppBarState (#387)
optimize imports and remove unused AppBarState
1 parent 02f9809 commit c6be74a

File tree

7 files changed

+3
-11
lines changed

7 files changed

+3
-11
lines changed

lib/src/main/java/com/shopify/checkoutsheetkit/BaseWebView.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ import androidx.webkit.WebSettingsCompat
4747
import androidx.webkit.WebViewFeature
4848
import com.shopify.checkoutsheetkit.ShopifyCheckoutSheetKit.log
4949
import java.net.HttpURLConnection.HTTP_GONE
50-
import java.net.HttpURLConnection.HTTP_NOT_FOUND
5150

5251
@SuppressLint("SetJavaScriptEnabled")
5352
internal abstract class BaseWebView(context: Context, attributeSet: AttributeSet? = null) :

lib/src/main/java/com/shopify/checkoutsheetkit/CheckoutDialog.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ import androidx.appcompat.content.res.AppCompatResources
4747
import androidx.appcompat.widget.Toolbar
4848
import androidx.core.graphics.drawable.DrawableCompat
4949
import androidx.core.graphics.drawable.toDrawable
50-
import androidx.core.net.toUri
5150
import androidx.core.view.children
5251
import com.shopify.checkoutsheetkit.ShopifyCheckoutSheetKit.log
5352

lib/src/main/java/com/shopify/checkoutsheetkit/CheckoutWebView.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ import android.util.AttributeSet
3131
import android.webkit.WebResourceRequest
3232
import android.webkit.WebView
3333
import androidx.activity.ComponentActivity
34+
import androidx.core.net.toUri
3435
import com.shopify.checkoutsheetkit.ShopifyCheckoutSheetKit.log
3536
import java.util.concurrent.CountDownLatch
3637
import kotlin.math.abs
3738
import kotlin.time.Duration.Companion.minutes
38-
import androidx.core.net.toUri
3939

4040
internal class CheckoutWebView(context: Context, attributeSet: AttributeSet? = null) :
4141
BaseWebView(context, attributeSet) {

lib/src/main/java/com/shopify/checkoutsheetkit/ShopifyCheckoutSheetKit.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ package com.shopify.checkoutsheetkit
2525
import androidx.activity.ComponentActivity
2626
import androidx.lifecycle.DefaultLifecycleObserver
2727
import androidx.lifecycle.LifecycleOwner
28-
import kotlin.jvm.JvmOverloads
2928

3029
/**
3130
* Entrypoint to the library, allows configuring, preloading, and presenting Shopify checkouts.

samples/MobileBuyIntegration/app/src/main/java/com/shopify/checkout_sdk_mobile_buy_integration_sample/CheckoutSdkApp.kt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,10 +186,6 @@ fun CheckoutSdkAppRoot(
186186
}
187187
}
188188

189-
data class AppBarState(
190-
val actions: @Composable RowScope.() -> Unit = {},
191-
)
192-
193189
private fun SettingsUiState.isDarkTheme(isSystemInDarkTheme: Boolean) = when (this) {
194190
is SettingsUiState.Loading -> isSystemInDarkTheme
195191
is SettingsUiState.Loaded -> {

samples/MobileBuyIntegration/app/src/main/java/com/shopify/checkout_sdk_mobile_buy_integration_sample/cart/data/CheckoutAppAuthenticationService.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@
2323
package com.shopify.checkout_sdk_mobile_buy_integration_sample.cart.data
2424

2525
import android.util.Base64
26-
import java.time.Instant
2726
import kotlinx.coroutines.Dispatchers
2827
import kotlinx.coroutines.sync.Mutex
2928
import kotlinx.coroutines.sync.withLock
@@ -39,6 +38,7 @@ import okhttp3.OkHttpClient
3938
import okhttp3.Request
4039
import okhttp3.RequestBody.Companion.toRequestBody
4140
import timber.log.Timber
41+
import java.time.Instant
4242
import kotlin.time.Duration.Companion.minutes
4343

4444
/**
@@ -184,4 +184,4 @@ class CheckoutAppAuthenticationService(
184184
@SerialName("access_token")
185185
val accessToken: String,
186186
)
187-
}
187+
}

samples/MobileBuyIntegration/app/src/main/java/com/shopify/checkout_sdk_mobile_buy_integration_sample/logs/details/PixelEventDetails.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ import com.shopify.checkoutsheetkit.pixelevents.CustomPixelEvent
3232
import com.shopify.checkoutsheetkit.pixelevents.PixelEvent
3333
import com.shopify.checkoutsheetkit.pixelevents.StandardPixelEvent
3434
import com.shopify.checkoutsheetkit.pixelevents.StandardPixelEventData
35-
import kotlinx.serialization.encodeToString
3635
import kotlinx.serialization.json.Json
3736

3837
@Composable

0 commit comments

Comments
 (0)