Skip to content
This repository has been archived by the owner on Jan 23, 2018. It is now read-only.

Commit

Permalink
Rearrange still more files
Browse files Browse the repository at this point in the history
  • Loading branch information
Xaeroxe committed Mar 18, 2017
1 parent 01c60bf commit 7b89ace
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 12 deletions.
2 changes: 1 addition & 1 deletion nitro/src/app.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ use math::Vector;
use audio::Audio;
use audio;
use math::Transform;
use Canvas;
use graphics::Canvas;
use camera::Camera;
use nphysics2d::world::World;
use std::sync::Arc;
Expand Down
2 changes: 1 addition & 1 deletion nitro/src/component/component.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use Canvas;
use graphics::Canvas;
use app::App;
use game_object::GameObject;
use component::Message;
Expand Down
4 changes: 2 additions & 2 deletions nitro/src/canvas.rs → nitro/src/graphics_private/canvas.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use graphics_private::texture;
use graphics_private::texture::Texture;
use rect::Rect;
use graphics::Texture;
use math::Rect;
use sdl2::rect::Rect as SdlRect;
use sdl2::rect::Point;
use math::Vector;
Expand Down
1 change: 1 addition & 0 deletions nitro/src/graphics_private/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ pub mod texture;
pub mod sprite_sheet;
mod sprite;
pub use self::sprite::Sprite;
pub mod canvas;
2 changes: 1 addition & 1 deletion nitro/src/graphics_private/sprite_sheet.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use sdl2::render::Texture as SdlTexture;
use std::sync::Arc;
use Rect;
use math::Rect;

pub struct SpriteSheet {
pub animations: Vec<Vec<SpriteSheetFrame>>,
Expand Down
8 changes: 2 additions & 6 deletions nitro/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,15 @@ pub mod graphics {
pub use graphics_private::texture::Texture;
pub use graphics_private::Sprite;
pub use graphics_private::sprite_sheet::SpriteSheet;
pub use graphics_private::canvas::Canvas;
}

mod canvas;
pub use canvas::Canvas;

mod rect;
pub use rect::Rect;

mod math_private;
pub mod math {
pub use math_private::vector::Vector;
pub use math_private::transform::Transform;
pub use math_private::polar_coords::PolarCoords;
pub use math_private::Rect;
}

mod input_private;
Expand Down
2 changes: 2 additions & 0 deletions nitro/src/math_private/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,5 @@ pub mod transform;
pub mod polar_coords;
mod check_and_use;
pub use self::check_and_use::check_and_use;
mod rect;
pub use self::rect::Rect;
File renamed without changes.
2 changes: 1 addition & 1 deletion src/spinny.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
use nitro::App;
use nitro::Canvas;
use nitro::graphics::Canvas;
use nitro::component::Component;
use nitro::component::Message;
use nitro::GameObject;
Expand Down

0 comments on commit 7b89ace

Please sign in to comment.