Created
February 23, 2014 21:23
-
-
Save mariusk/9177506 to your computer and use it in GitHub Desktop.
This file contains 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
(module-name net.kjeldahl.kawatest) | |
(define-alias Bundle android.os.Bundle) | |
(define-alias Activity android.app.Activity) | |
(define-alias View android.view.View) | |
(define-alias TextView android.widget.TextView) | |
(define-alias LinearLayout android.widget.LinearLayout) | |
(define-alias Override java.lang.Override) | |
(define-alias Date java.util.Date) | |
(define-simple-class MainActivity (Activity) | |
((onCreate (savedInstanceState::Bundle)) (@Override) | |
(invoke-special Activity (this) 'onCreate savedInstanceState) | |
(define tv::TextView (TextView (this) text: "Kawa hello.")) | |
(define my-view::View (LinearLayout (this) | |
orientation: LinearLayout:VERTICAL | |
tv)) | |
((this):setContentView my-view) | |
(define str (string-append "KawaActivity - " | |
((tv:getText):toString) | |
" - " | |
((Date):toString))) | |
(tv:setText str))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment