Changeset 8565a42 in mainline for uspace/lib/draw/cursor/embedded.c
- Timestamp:
- 2018-03-02T20:34:50Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- a1a81f69, d5e5fd1
- Parents:
- 3061bc1 (diff), 34e1206 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - git-author:
- Jiří Zárevúcky <zarevucky.jiri@…> (2018-03-02 20:34:50)
- git-committer:
- GitHub <noreply@…> (2018-03-02 20:34:50)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/draw/cursor/embedded.c
r3061bc1 r8565a42 47 47 assert(state_count); 48 48 assert(data); 49 49 50 50 (*state_count) = 1; 51 51 (*data) = NULL; … … 56 56 if (state != 0) 57 57 return NULL; 58 58 59 59 surface_t *surface = surface_create(CURSOR_WIDTH, CURSOR_HEIGHT, NULL, 0); 60 60 if (!surface) 61 61 return NULL; 62 62 63 63 for (unsigned int y = 0; y < CURSOR_HEIGHT; ++y) { 64 64 for (unsigned int x = 0; x < CURSOR_WIDTH; ++x) { … … 67 67 pixel_t pixel = (cursor_texture[offset] & (1 << (x % 8))) ? 68 68 PIXEL(255, 0, 0, 0) : PIXEL(255, 255, 255, 255); 69 69 70 70 if (visible) 71 71 surface_put_pixel(surface, x, y, pixel); 72 72 } 73 73 } 74 74 75 75 return surface; 76 76 }
Note:
See TracChangeset
for help on using the changeset viewer.