This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

A seemingly simple problem with methods and Android


Hello all,

I am trying to use the below:

(require 'android-defs)
(define-simple-class <RobotCanvas> (android.view.View))

(activity KawaActivity
  (on-create-view
   (RobotCanvas (this)
    )))

And the Kawa compiler spits out the bug:

scompile:
     [java] (compiling C:\Users\nilocnag\Dropbox\Projects\kawadroid\src\org\coli
g\kawadroid\KawaActivity.scm to kawa.android.KawaActivity)
     [java] C:\Users\nilocnag\Dropbox\Projects\kawadroid\src\org\colig\kawadroid
\KawaActivity.scm:4:1: more than one possibly applicable method 'setContentView'
 in kawa.android.KawaActivity
     [java]   candidate: void kawa.android.KawaActivity.setContentView(android.v
iew.View)
     [java]   candidate: void kawa.android.KawaActivity.setContentView(int)

BUILD FAILED
C:\Users\nilocnag\Dropbox\Projects\kawadroid\build.xml:84: Java returned: -1

Total time: 2 seconds
C:\Users\nilocnag\Dropbox\Projects\kawadroid>


The script is based off the example provided in Per's blog, which does
build properly for me. I'm not quite sure how to tell the compiler to
specifically use the setContentView method that accepts Views.


Regards,


Colin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]