mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-17 08:40:52 +00:00
fix dirty rectangles on resume
This commit is contained in:
parent
4882016d08
commit
9aef2eb7b4
1 changed files with 2 additions and 3 deletions
|
|
@ -115,10 +115,9 @@ impl XousDisplay {
|
||||||
if drew_note {
|
if drew_note {
|
||||||
let note = crate::sleep_note::LOGO_MAP;
|
let note = crate::sleep_note::LOGO_MAP;
|
||||||
let note_lines = note.len() / FB_WIDTH_WORDS;
|
let note_lines = note.len() / FB_WIDTH_WORDS;
|
||||||
let start_line = (FB_LINES - note_lines) / 2;
|
|
||||||
let hwfb: *mut [u32; FB_SIZE] = self.hwfb.as_mut_ptr() as *mut [u32; FB_SIZE];
|
let hwfb: *mut [u32; FB_SIZE] = self.hwfb.as_mut_ptr() as *mut [u32; FB_SIZE];
|
||||||
for lines in start_line..start_line + note_lines {
|
for lines in 0..FB_LINES {
|
||||||
// set the dirty bits to force a redraw of the restored data
|
// set the dirty bits of all lines to force a redraw of the restored data
|
||||||
unsafe {
|
unsafe {
|
||||||
(*hwfb)[lines * FB_WIDTH_WORDS + (FB_WIDTH_WORDS - 1)] |= 0x1_0000;
|
(*hwfb)[lines * FB_WIDTH_WORDS + (FB_WIDTH_WORDS - 1)] |= 0x1_0000;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue