android kitche最新版,Lattekit

软件简介

Lattekit 是采用Kotlin编写的一个Android UI 框架。

快速示例学习 :

402bfc16ca0640736baf6d9838c99dc2.gif

package io.lattekit.helloworld

import android.app.Activity

import android.os.Bundle

import android.view.View

import android.widget.EditText

import io.lattekit.annotation.Bind

import io.lattekit.plugin.css.declaration.css

import io.lattekit.render

import io.lattekit.view.LatteView

class MainActivity : Activity() {

override fun onCreate(savedInstanceState: Bundle?) {

super.onCreate(savedInstanceState)

render("")

}

}

open class MyApp : LatteView() {

@Bind("@id/myText") var myText : EditText? = null;

init {

css("""

.question { font-size: 20sp; font-weight: bold;  }

.input { font-size: 14sp; margin-top:8dp;  width: match_parent; }

.answer { font-size: 20sp; font-weight: bold; margin-top: 10dp; color: #00AADE; }

""")

// or: css("com.my.package/file.css")

}

override fun layout() = xml("""

onTextChanged=${{ notifyStateChanged() }} class="input"/>

visibility=${if (myText?.text?.toString() == "") View.GONE else View.VISIBLE} class="answer"/>

""")

}

其他示例:

3d7ad6f028173030d02241cc7a8bf713.gif

My original intent was to have this package dependency-free, but as you can see, I did have to include Cygwin. Initially just for mkbootimg since the huaixzk standalone version wouldn't work (it wasn't loading the kernel as binary, thanks trevd); then I discovered that using the GNUWin32 cpio to unpack somehow didn't play nice with repacking the ramdisk in a usable state, so at that point I decided I might as well go Cygwin across the board. As it is, I've included the latest Cygwin-dependent executables and required libraries from their repos and built my own custom Cygwin image and ramdisk utilities built from the latest sources. Originally only for Google Pixel/Nexus/AOSP standard boot.img files, built-in support has now expanded to Android Verified Boot (AVBv1)/ChromeOS/SignBlob signed boot.img files, Barnes & Noble Nook "Green Loader" signed boot.img files, Samsung/Spreadtrum DHTB header signed boot.img files, the Samsung/Marvell PXA1088/1908 board boot.img variant (AOSP-PXA), Loki patched boot.img files, Sony SIN signed/packaged kernel.elf extraction, Sony ELF kernel.elf files, Intel OSIP Android image files, DENX U-Boot uImage files, Rockchip KRNL signed ramdisk image files, MTK headers for zImage/ramdisk, and LG Bump/Samsung SEAndroid footers for boot.img. The main advantage here is you don't need Cygwin shell or PERL scripts. Other guides exist but none of them are universal for target device, compression and/or developed for Windows, Android ARM/x86/MIPS + ARM64/x86_64/MIPS64, and now macOS. With this universality in mind I've automated the whole process with batch/shell scripts. My development work on my many projects comes out of my free time, so if you enjoy this project or anything else I've done on xda, please do hit the donate link from my profile. Thank you for your support!
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值