mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-19 09:00:54 +00:00
cleanup trait implementation to match modifications
remove mutability from get_pixel
This commit is contained in:
parent
ebd9b6e823
commit
4710b416be
1 changed files with 2 additions and 2 deletions
|
|
@ -314,8 +314,8 @@ impl FrameBuffer for XousDisplay {
|
||||||
///
|
///
|
||||||
/// Note: this has not be carefully tested as this API is not used by the legacy code base.
|
/// Note: this has not be carefully tested as this API is not used by the legacy code base.
|
||||||
/// Anyone using this API for the first time may benefit in checking that it is correct.
|
/// Anyone using this API for the first time may benefit in checking that it is correct.
|
||||||
fn get_pixel(&mut self, p: Point) -> Option<ColorNative> {
|
fn get_pixel(&self, p: Point) -> Option<ColorNative> {
|
||||||
let fb: &mut [u32] = unsafe { self.fb.as_slice_mut() };
|
let fb: &[u32] = unsafe { self.fb.as_slice() };
|
||||||
let clip_y: usize;
|
let clip_y: usize;
|
||||||
if p.y >= LCD_LINES {
|
if p.y >= LCD_LINES {
|
||||||
return None;
|
return None;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue