The first frame no longer waits for the saved sign-in to open (0.108.56)
0.108.55's start on the box: Displayed +6.4 s, from 2.1 s. The screen asks the store for a ticket as it first draws, and ticket() shared the lock that the background open holds. The generation is now volatile and read without the lock. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -40,8 +40,10 @@ internal class RememberedConnectionStore(path: File, private val alias: String,
|
||||
}
|
||||
@Synchronized fun invalidate() { generation++; lastRead = null }
|
||||
private val file = AtomicFile(path)
|
||||
private var generation = 0L
|
||||
@Synchronized fun ticket() = generation
|
||||
// Read without the lock: the screen asks for a ticket as it first draws, and must not wait while the sign-in is opened in
|
||||
// the background (that wait held Orbit's first frame back by four seconds on the box, 6 November 2026).
|
||||
@Volatile private var generation = 0L
|
||||
fun ticket() = generation
|
||||
private fun key(create: Boolean): SecretKey {
|
||||
val store = KeyStore.getInstance("AndroidKeyStore").apply { load(null) }
|
||||
(store.getKey(alias, null) as? SecretKey)?.let { return it }
|
||||
|
||||
Reference in New Issue
Block a user