From d565cd125b45a594b0bbb3662fe40e99abd01c37 Mon Sep 17 00:00:00 2001 From: proudmuslim-dev <69869443+proudmuslim-dev@users.noreply.github.com> Date: Thu, 4 Jul 2024 19:15:21 +0000 Subject: [PATCH] Move import to sensible location in chapter 3 It served no purpose in the previous code block and would only confuse the user --- blog/content/edition-3/posts/03-screen-output/index.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/blog/content/edition-3/posts/03-screen-output/index.md b/blog/content/edition-3/posts/03-screen-output/index.md index b81ea861..bc768223 100644 --- a/blog/content/edition-3/posts/03-screen-output/index.md +++ b/blog/content/edition-3/posts/03-screen-output/index.md @@ -149,8 +149,6 @@ In the new module, we create basic structs for representing pixel positions and ```rust ,hl_lines=3-16 // in new kernel/src/framebuffer.rs file -use bootloader_api::info::FrameBuffer; - #[derive(Debug, Clone, Copy, PartialEq, Eq)] pub struct Position { pub x: usize, @@ -180,7 +178,7 @@ Next, we create a function for setting a specific pixel in the framebuffer to a ```rust ,hl_lines=3 5-39 // in new kernel/src/framebuffer.rs file -use bootloader_api::info::PixelFormat; +use bootloader_api::info::{FrameBuffer, PixelFormat}; pub fn set_pixel_in(framebuffer: &mut FrameBuffer, position: Position, color: Color) { let info = framebuffer.info();