clojure-android / neko

The Clojure/Android Toolkit
Other
297 stars 36 forks source link

Enable :on-drag trait and tweak project.clj #67

Closed satchit8 closed 7 years ago

satchit8 commented 7 years ago

The functionality for the :on-drag trait seems to have existed since the initial commit, but for whatever reason wasn't enabled. This was an attempt at enabling it.

Along the way a couple of additional bits turned up:

1) With build-tools >= 24 + leiningen 2.7.x (and possibly other bits), something didn't work right for neko (may be it was the local tests that didn't run and possibly other things). Changing the lein-droid version in project.clj to 0.4.6 seems to cope with the issue.

2) When building a coa project with an updated local neko jar, got a "Unsupported Class file version 52.0" error [1] during dex creation. Tweaking neko's project.clj by adding the following seems to help:

  :javac-options ["-target" "1.6" "-source" "1.6" "-Xlint:-options"]

Note the line is just cribbed from what typically appears in a fresh coa project's project.cljl

Sorry about the vagueness. If it's desirable, I can try to track down the specifics.

At any rate, with the included changes, I was able to use the :on-drag trait successfully.

[1] https://stackoverflow.com/questions/37902840/got-unsupported-class-file-version-52-0-after-including-a-module-to-a-project https://github.com/phax/ph-css/issues/28

coveralls commented 7 years ago

Coverage Status

Changes Unknown when pulling 64663a3965abcd950d0c3799b8133973ce97c968 on satchit8:master into \ on clojure-android:master**.

alexander-yakushev commented 7 years ago

Thanks for investigating the build issues!

As for the on-drag event, I think it was added by Daniel long time ago when 2.x was still prevalent. It's good that we are past those days now:).