2 * ***** BEGIN GPL LICENSE BLOCK *****
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version 2
7 * of the License, or (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software Foundation,
16 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 * The Original Code is Copyright (C) 2007 Blender Foundation.
19 * All rights reserved.
22 * Contributor(s): Blender Foundation
24 * ***** END GPL LICENSE BLOCK *****
27 /** \file blender/windowmanager/wm.h
37 typedef struct wmPaintCursor {
38 struct wmPaintCursor *next, *prev;
42 int (*poll)(struct bContext *C);
43 void (*draw)(bContext *C, int, int, void *customdata);
46 extern void wm_close_and_free(bContext *C, wmWindowManager *);
47 extern void wm_close_and_free_all(bContext *C, ListBase *);
49 extern void wm_add_default(bContext *C);
50 extern void wm_clear_default_size(bContext *C);
52 /* register to windowmanager for redo or macro */
53 void wm_operator_register(bContext *C, wmOperator *op);
55 extern void wm_report_free(wmReport *report);
57 /* wm_operator.c, for init/exit */
58 void wm_operatortype_free(void);
59 void wm_operatortype_init(void);
60 void wm_window_keymap(wmKeyConfig *keyconf);
62 void wm_tweakevent_test(bContext *C, wmEvent *event, int action);
65 #define WM_LASSO_MIN_POINTS 1024
66 void wm_gesture_draw(struct wmWindow *win);
67 int wm_gesture_evaluate(wmGesture *gesture);
68 void wm_gesture_tag_redraw(bContext *C);
71 void wm_jobs_timer(const bContext *C, wmWindowManager *wm, wmTimer *wt);
72 void wm_jobs_timer_ended(wmWindowManager *wm, wmTimer *wt);
75 void wm_autosave_timer(const bContext *C, wmWindowManager *wm, wmTimer *wt);
76 void wm_autosave_timer_ended(wmWindowManager *wm);
77 void wm_autosave_delete(void);
78 void wm_autosave_read(bContext *C, struct ReportList *reports);
79 void wm_autosave_location(char *filepath);
81 /* hack to store circle select size - campbell, must replace with nice operator memory */
82 #define GESTURE_MEMORY
85 extern int circle_select_size;