This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package top.ntutn.mindmap | |
| import androidx.compose.material3.Text | |
| import androidx.compose.runtime.LaunchedEffect | |
| import androidx.compose.runtime.getValue | |
| import androidx.compose.runtime.mutableStateOf | |
| import androidx.compose.runtime.remember | |
| import androidx.compose.runtime.setValue | |
| import androidx.compose.ui.ExperimentalComposeUiApi | |
| import androidx.compose.ui.platform.LocalFontFamilyResolver |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package top.ntutn.sevenzip.toast | |
| import androidx.compose.runtime.mutableStateListOf | |
| import kotlinx.coroutines.CoroutineScope | |
| import kotlinx.coroutines.delay | |
| import kotlinx.coroutines.launch | |
| class DefaultToastController(private val coroutineScope: CoroutineScope): IToastController { | |
| private val messages = mutableStateListOf<ToastMessage>() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import androidx.compose.foundation.layout.Arrangement | |
| import androidx.compose.foundation.layout.Column | |
| import androidx.compose.foundation.layout.fillMaxSize | |
| import androidx.compose.foundation.layout.padding | |
| import androidx.compose.material3.Button | |
| import androidx.compose.material3.MaterialTheme | |
| import androidx.compose.material3.Text | |
| import androidx.compose.runtime.getValue | |
| import androidx.compose.runtime.mutableStateOf | |
| import androidx.compose.runtime.remember |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import androidx.lifecycle.ViewModel | |
| import androidx.lifecycle.viewModelScope | |
| import kotlinx.coroutines.Dispatchers | |
| import kotlinx.coroutines.flow.MutableStateFlow | |
| import kotlinx.coroutines.flow.StateFlow | |
| import kotlinx.coroutines.launch | |
| import kotlinx.coroutines.runBlocking | |
| import net.sf.sevenzipjbinding.IInArchive | |
| import net.sf.sevenzipjbinding.SevenZip | |
| import net.sf.sevenzipjbinding.SevenZipException |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 应用发生了崩溃 | |
| 以下信息有助于我们排查问题: | |
| 线程名:AWT-EventQueue-0 | |
| java.lang.IllegalStateException: Vertically scrollable component was measured with an infinity maximum height constraints, which is disallowed. One of the common reasons is nesting layouts like LazyColumn and Column(Modifier.verticalScroll()). If you want to add a header before the list of items please add a header as a separate item() before the main items() inside the LazyColumn scope. There are could be other reasons for this to happen: your ComposeView was added into a LinearLayout with some weight, you applied Modifier.wrapContentSize(unbounded = true) or wrote a custom layout. Please try to remove the source of infinite constraints in the hierarchy above the scrolling container. | |
| at androidx.compose.foundation.CheckScrollableContainerConstraintsKt.checkScrollableContainerConstraints-K40F9xA(CheckScrollableContainerConstraints.kt:35) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package top.ntutn.floatcompose | |
| import android.content.Context | |
| import android.graphics.PixelFormat | |
| import android.os.Bundle | |
| import android.util.AttributeSet | |
| import android.util.Log | |
| import android.view.Gravity | |
| import android.view.View | |
| import android.view.ViewGroup |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package top.ntutn.textviewdemo | |
| import android.content.Context | |
| import android.graphics.Canvas | |
| import android.graphics.Color | |
| import android.graphics.Paint | |
| import android.util.AttributeSet | |
| import androidx.appcompat.widget.AppCompatTextView | |
| class DemoTextView @JvmOverloads constructor(context: Context, defStyleAttr: AttributeSet? = null, defStyleRes: Int = 0) : AppCompatTextView(context, defStyleAttr, defStyleRes) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package top.ntutn.swipeselectview | |
| import android.annotation.SuppressLint | |
| import android.content.Context | |
| import android.graphics.Rect | |
| import android.util.AttributeSet | |
| import android.view.MotionEvent | |
| import android.view.View | |
| import androidx.core.view.children | |
| import com.google.android.material.chip.ChipGroup |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import android.os.Bundle | |
| import androidx.fragment.app.Fragment | |
| import kotlin.properties.ReadWriteProperty | |
| class FragmentBundleDataDelegate<T : Any>(private val clazz: Class<T>, private val defaultValue: T? = null) : | |
| ReadWriteProperty<Fragment, T?> { | |
| @Suppress("UNCHECKED_CAST") | |
| override fun getValue( | |
| thisRef: Fragment, |