remove/comment unused defines.
[blender.git] / source / blender / blenkernel / BKE_report.h
index 26853866ebbc1ca9f395d223604bfa82f9acfa6a..b84808a7ddd84e24649e60e4f73e04db4b70ce1a 100644 (file)
@@ -15,7 +15,7 @@
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  *
  * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
  * All rights reserved.
 extern "C" {
 #endif
 
-#include "DNA_listBase.h"
+#include "DNA_windowmanager_types.h"
 
 /* Reporting Information and Errors
  *
  * These functions also accept NULL in case no error reporting
  * is needed. */
 
-typedef enum ReportType {
-       RPT_DEBUG                                       = 1<<0,
-       RPT_INFO                                        = 1<<1,
-       RPT_OPERATOR                            = 1<<2,
-       RPT_WARNING                                     = 1<<3,
-       RPT_ERROR                                       = 1<<4,
-       RPT_ERROR_INVALID_INPUT         = 1<<5,
-       RPT_ERROR_INVALID_CONTEXT       = 1<<6,
-       RPT_ERROR_OUT_OF_MEMORY         = 1<<7
-} ReportType;
-
-#define RPT_DEBUG_ALL          (RPT_DEBUG)
-#define RPT_INFO_ALL           (RPT_INFO)
-#define RPT_OPERATOR_ALL       (RPT_OPERATOR)
-#define RPT_WARNING_ALL                (RPT_WARNING)
-#define RPT_ERROR_ALL          (RPT_ERROR|RPT_ERROR_INVALID_INPUT|RPT_ERROR_INVALID_CONTEXT|RPT_ERROR_OUT_OF_MEMORY)
-
-enum ReportListFlags {
-       RPT_PRINT = 1,
-       RPT_STORE = 2,
-};
-
-typedef struct Report {
-       struct Report *next, *prev;
-       ReportType type;
-       char *typestr;
-       char *message;
-} Report;
-
-typedef struct ReportList {
-       ListBase list;
-       ReportType printlevel;
-       ReportType storelevel;
-       int flag;
-} ReportList;
+/* report structures are stored in DNA */
 
 void BKE_reports_init(ReportList *reports, int flag);
 void BKE_reports_clear(ReportList *reports);
 
 void BKE_report(ReportList *reports, ReportType type, const char *message);
-void BKE_reportf(ReportList *reports, ReportType type, const char *format, ...);
+void BKE_reportf(ReportList *reports, ReportType type, const char *format, ...)
+#ifdef __GNUC__
+__attribute__ ((format (printf, 3, 4)));
+#endif
+;
 
 void BKE_reports_prepend(ReportList *reports, const char *prepend);
 void BKE_reports_prependf(ReportList *reports, const char *prepend, ...);
@@ -93,6 +63,8 @@ void BKE_report_store_level_set(ReportList *reports, ReportType level);
 char *BKE_reports_string(ReportList *reports, ReportType level);
 void BKE_reports_print(ReportList *reports, ReportType level);
 
+Report *BKE_reports_last_displayable(ReportList *reports);
+       
 #ifdef __cplusplus
 }
 #endif