Rev 1689 | Rev 1717 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1689 | Rev 1707 | ||
---|---|---|---|
Line 228... | Line 228... | ||
228 | 228 | ||
229 | active_console = KERNEL_CONSOLE; /* Set to kernel console */ |
229 | active_console = KERNEL_CONSOLE; /* Set to kernel console */ |
230 | vp_switch(0); |
230 | vp_switch(0); |
231 | } |
231 | } |
232 | 232 | ||
- | 233 | ||
- | 234 | static inline int limit(int a,int left, int right) |
|
- | 235 | { |
|
- | 236 | if (a < left) |
|
- | 237 | a = left; |
|
- | 238 | if (a >= right) |
|
- | 239 | a = right - 1; |
|
- | 240 | return a; |
|
- | 241 | } |
|
- | 242 | ||
- | 243 | void gcons_mouse_move(int dx, int dy) |
|
- | 244 | { |
|
- | 245 | static int x = 0; |
|
- | 246 | static int y = 0; |
|
- | 247 | ||
- | 248 | x = limit(x+dx, 0, xres); |
|
- | 249 | y = limit(y+dy, 0, yres); |
|
- | 250 | ||
- | 251 | async_msg_2(fbphone, FB_POINTER_MOVE, x, y); |
|
- | 252 | } |
|
- | 253 | ||
- | 254 | ||
233 | /** Draw a PPM pixmap to framebuffer |
255 | /** Draw a PPM pixmap to framebuffer |
234 | * |
256 | * |
235 | * @param logo Pointer to PPM data |
257 | * @param logo Pointer to PPM data |
236 | * @param size Size of PPM data |
258 | * @param size Size of PPM data |
237 | * @param x Coordinate of upper left corner |
259 | * @param x Coordinate of upper left corner |