Mouse cursors now work again

- centralized screen-level cursor changes, no more operator
  running for it.
- spacetypes have callback to check/set individual cursor
  types. Use notifier SCREEN_CHANGED to make sure it works
  on mode changes etc.
- new calls WM_cursor_modal() and WM_cursor_restore() to
  make temporarily cursor types during modes.
- used above for view2d cursors.
This commit is contained in:
2008-12-15 16:54:47 +00:00
parent c13bb258b1
commit a16df53619
12 changed files with 157 additions and 133 deletions

View File

@@ -55,10 +55,11 @@ void WM_read_autosavefile(struct bContext *C);
void WM_write_autosave (struct bContext *C);
/* mouse cursors */
void WM_init_cursor_data (void);
void WM_set_cursor (struct bContext *C, int curs);
void WM_waitcursor (struct bContext *C, int val);
void WM_timecursor (struct bContext *C, int nr);
void WM_cursor_set (struct wmWindow *win, int curs);
void WM_cursor_modal (struct wmWindow *win, int curs);
void WM_cursor_restore (struct wmWindow *win);
void WM_cursor_wait (struct wmWindow *win, int val);
void WM_timecursor (struct wmWindow *win, int nr);
/* keymap and handlers */
wmKeymapItem *WM_keymap_set_item (ListBase *lb, char *idname, short type,