Skip to content

Commit 22de34f

Browse files
committed
Replaced imports with require's.
1 parent b6fc151 commit 22de34f

File tree

11 files changed

+50
-54
lines changed

11 files changed

+50
-54
lines changed

clecs-tetris/project.clj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
:license {:name "GNU GPL v3"
55
:url "http://www.gnu.org/licenses/gpl-3.0.en.html"}
66
:dependencies [[org.clojure/clojure "1.6.0"]
7-
[clecs "1.0.2-SNAPSHOT"]
8-
[seesaw "1.4.4"]]
7+
[clecs "1.1.0-SNAPSHOT"]
8+
[seesaw "1.4.5"]]
99
:main ^:skip-aot clecs-tetris.core
1010
:target-path "target/%s"
1111
:profiles {:dev {:dependencies [[midje "1.6.3"]]}

clecs-tetris/src/clecs_tetris/world/system/gravity.clj

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,10 @@
33
[clecs.world :as world]
44
[clecs-tetris.world.component :refer [->CurrentShapeComponent
55
->GlassTileComponent
6-
->TargetLocationComponent]])
7-
(:import [clecs_tetris.world.component
8-
CurrentShapeComponent
9-
GlassTileComponent
10-
TargetLocationComponent]))
6+
->TargetLocationComponent
7+
CurrentShapeComponent
8+
GlassTileComponent
9+
TargetLocationComponent]]))
1110

1211

1312
(declare -move-target-location)

clecs-tetris/src/clecs_tetris/world/system/new_shape.clj

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
(ns clecs-tetris.world.system.new-shape
22
(:require [clecs-tetris.world.component :refer [->CurrentShapeComponent
3-
->TargetLocationComponent]]
3+
->TargetLocationComponent
4+
CurrentShapeComponent
5+
NextShapeComponent
6+
TargetLocationComponent]]
47
[clecs.query :as query]
5-
[clecs.world :as world])
6-
(:import (clecs_tetris.world.component CurrentShapeComponent
7-
NextShapeComponent
8-
TargetLocationComponent)))
8+
[clecs.world :as world]))
99

1010

1111
(defn -can-create-new-shape? [w]

clecs-tetris/src/clecs_tetris/world/system/next_shape.clj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
(ns clecs-tetris.world.system.next-shape
2-
(:require [clecs-tetris.world.component :refer [->NextShapeComponent]]
2+
(:require [clecs-tetris.world.component :refer [->NextShapeComponent
3+
NextShapeComponent]]
34
[clecs.query :as query]
4-
[clecs.world :as world])
5-
(:import (clecs_tetris.world.component NextShapeComponent)))
5+
[clecs.world :as world]))
66

77

88
(defn -add-shape [shape]

clecs-tetris/src/clecs_tetris/world/system/rendering.clj

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
(ns clecs-tetris.world.system.rendering
2-
(:require [clecs-tetris.world.component]
2+
(:require [clecs-tetris.world.component :refer [GlassTileComponent
3+
LevelComponent
4+
LinesDroppedComponent
5+
NextShapeComponent
6+
ScoreComponent]]
37
[clecs-tetris.world.protocol :as protocol]
48
[clecs.query :as query]
5-
[clecs.world :as world])
6-
(:import (clecs_tetris.world.component GlassTileComponent
7-
LevelComponent
8-
LinesDroppedComponent
9-
NextShapeComponent
10-
ScoreComponent)))
9+
[clecs.world :as world]))
1110

1211

1312
(defn -get-next-shape [w]

clecs-tetris/src/clecs_tetris/world/system/update_shape.clj

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
(ns clecs-tetris.world.system.update-shape
22
(:require [clecs-tetris.world.component :refer [->CurrentShapeComponent
33
->GlassTileComponent
4-
->TargetLocationComponent]]
4+
->TargetLocationComponent
5+
CurrentShapeComponent
6+
GlassTileComponent
7+
TargetLocationComponent]]
58
[clecs.query :as query]
6-
[clecs.world :as world])
7-
(:import (clecs_tetris.world.component CurrentShapeComponent
8-
GlassTileComponent
9-
TargetLocationComponent)))
9+
[clecs.world :as world]))
1010

1111

1212
(defn -set-glass-tile [w x y tile]

clecs-tetris/test/clecs_tetris/world/system/gravity_test.clj

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@
1010
[clecs.world :as world]
1111
[clecs-tetris.world.component :refer [->CurrentShapeComponent
1212
->GlassTileComponent
13-
->TargetLocationComponent]]
13+
->TargetLocationComponent
14+
CurrentShapeComponent
15+
GlassTileComponent
16+
TargetLocationComponent]]
1417
[clecs-tetris.world.system.gravity :refer :all]
15-
[midje.sweet :refer :all])
16-
(:import [clecs_tetris.world.component CurrentShapeComponent
17-
GlassTileComponent
18-
TargetLocationComponent]))
18+
[midje.sweet :refer :all]))
1919

2020

2121

clecs-tetris/test/clecs_tetris/world/system/new_shape_test.clj

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,12 @@
99
[clecs.world :as world]
1010
[clecs-tetris.world.component :refer [->CurrentShapeComponent
1111
->NextShapeComponent
12-
->TargetLocationComponent]]
12+
->TargetLocationComponent
13+
CurrentShapeComponent
14+
NextShapeComponent
15+
TargetLocationComponent]]
1316
[clecs-tetris.world.system.new-shape :refer :all]
14-
[midje.sweet :refer :all])
15-
(:import [clecs_tetris.world.component
16-
CurrentShapeComponent
17-
NextShapeComponent
18-
TargetLocationComponent]))
17+
[midje.sweet :refer :all]))
1918

2019

2120
(fact "-can-create-new-shape? does nothing if there is a current shape."

clecs-tetris/test/clecs_tetris/world/system/next_shape_test.clj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77
mock-world]]
88
[clecs.query :as query]
99
[clecs.world :as world]
10-
[clecs-tetris.world.component :refer [->NextShapeComponent]]
10+
[clecs-tetris.world.component :refer [->NextShapeComponent
11+
NextShapeComponent]]
1112
[clecs-tetris.world.system.next-shape :refer :all]
12-
[midje.sweet :refer :all])
13-
(:import [clecs_tetris.world.component NextShapeComponent]))
13+
[midje.sweet :refer :all]))
1414

1515

1616
(fact "-add-shape creates transaction that adds a new NextShapeComponent."

clecs-tetris/test/clecs_tetris/world/system/rendering_test.clj

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,14 @@
88
->LinesDroppedComponent
99
->NextShapeComponent
1010
->ScoreComponent
11-
->GlassTileComponent]]
11+
->GlassTileComponent
12+
LevelComponent
13+
LinesDroppedComponent
14+
NextShapeComponent
15+
ScoreComponent
16+
GlassTileComponent]]
1217
[clecs-tetris.world.system.rendering :refer :all]
13-
[midje.sweet :refer :all])
14-
(:import [clecs_tetris.world.component
15-
LevelComponent
16-
LinesDroppedComponent
17-
NextShapeComponent
18-
ScoreComponent
19-
GlassTileComponent]))
18+
[midje.sweet :refer :all]))
2019

2120

2221
(fact "-get-next-shape returns 4x4 tile grid of next shape."

0 commit comments

Comments
 (0)