Skip to content

Commit 01aadca

Browse files
committed
restore cross-build versions
- build with 2.11, 2.12, 2.13, 3.0.0-M1 - update travis - update readme - restore MainFrame constructor argument - remove unused import
1 parent f4ecfe3 commit 01aadca

File tree

6 files changed

+8
-7
lines changed

6 files changed

+8
-7
lines changed

.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ scala:
88
- 2.11.12
99
- 2.12.11
1010
- 2.13.3
11+
- 3.0.0-M1
1112

1213
env:
1314
- ADOPTOPENJDK=8

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,15 @@
55
[<img src="https://img.shields.io/maven-central/v/org.scala-lang.modules/scala-swing_2.12.svg?label=latest%20release%20for%202.12"/>](http://search.maven.org/#search%7Cga%7C1%7Cg%3Aorg.scala-lang.modules%20a%3Ascala-swing_2.12)
66
[<img src="https://img.shields.io/maven-central/v/org.scala-lang.modules/scala-swing_2.13.svg?label=latest%20release%20for%202.13"/>](http://search.maven.org/#search%7Cga%7C1%7Cg%3Aorg.scala-lang.modules%20a%3Ascala-swing_2.13)
77

8-
This is now community maintained by [@Sciss](https://github.com/Sciss) and [@benhutchison](https://github.com/benhutchison). If you are interested in helping then contact them or [@adriaanm](https://github.com/adriaanm).
8+
This is now community maintained by [@Sciss](https://github.com/Sciss) and [@benhutchison](https://github.com/benhutchison).
9+
If you are interested in helping then contact them or [@adriaanm](https://github.com/adriaanm).
910

1011
## Adding an sbt dependency
1112

1213
To use scala-swing from sbt, add this to your `build.sbt`:
1314

1415
```
15-
libraryDependencies += "org.scala-lang.modules" %% "scala-swing" % "2.1.1"
16+
libraryDependencies += "org.scala-lang.modules" %% "scala-swing" % "2.2.0"
1617
```
1718

1819
## About scala-swing
@@ -113,6 +114,7 @@ new Frame {
113114
- When using Scala 2.11, you can use the Scala swing 2.0.x releases on JDK 6 or newer.
114115
- Scala 2.12 requires you to use JDK 8 (that has nothing to do with scala-swing).
115116
- The `2.1.x` series adds support for Scala 2.13, while dropping Scala 2.10.
117+
- The `2.2.x` series adds support for Scala 3.0.
116118

117119
The reason to have different major versions is to allow for binary incompatible changes. Also, some java-swing classes were
118120
generified in JDK 7 (see [SI-3634](https://issues.scala-lang.org/browse/SI-3634)) and require the scala-swing sources to be adjusted.

build.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
lazy val scalaTestVersion = "3.2.3"
22

33
lazy val commonSettings = Seq(
4-
crossScalaVersions += "3.0.0-M1",
4+
crossScalaVersions := Seq("3.0.0-M1", "2.13.3", "2.12.12", "2.11.12"),
55
scalaVersion := "2.13.3",
66
scalacOptions ++= Seq("-deprecation", "-feature"),
77
)

src/main/scala/scala/swing/Action.scala

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@
1212

1313
package scala.swing
1414

15-
import java.awt.event.ActionListener
16-
1715
import javax.swing.{Icon, KeyStroke}
1816

1917
object Action {

src/main/scala/scala/swing/MainFrame.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ package scala.swing
1616
* A frame that can be used for main application windows. It shuts down the
1717
* framework and quits the application when closed.
1818
*/
19-
class MainFrame(/*gc: java.awt.GraphicsConfiguration = null*/) extends Frame /*(gc)*/ {
19+
class MainFrame(gc: java.awt.GraphicsConfiguration = null) extends Frame(gc) {
2020
override def closeOperation(): Unit = sys.exit(0)
2121
}

src/main/scala/scala/swing/Publisher.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ private[swing] trait LazyPublisher extends Publisher {
7979

8080
import scala.ref._
8181

82-
private[swing] trait SingleRefCollection[/*+*/ A <: AnyRef] extends Iterable[A] { self =>
82+
private[swing] trait SingleRefCollection[A <: AnyRef] extends Iterable[A] { self =>
8383

8484
trait Ref[+B <: AnyRef] extends Reference[B] {
8585
override def hashCode(): Int = get match {

0 commit comments

Comments
 (0)