summaryrefslogtreecommitdiff
path: root/src/editor/editor.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/editor/editor.h')
-rw-r--r--src/editor/editor.h16
1 files changed, 12 insertions, 4 deletions
diff --git a/src/editor/editor.h b/src/editor/editor.h
index 828f2e4..33396df 100644
--- a/src/editor/editor.h
+++ b/src/editor/editor.h
@@ -66,7 +66,7 @@ enum EditorObjectType_t {
typedef void( *EDITOR_CONTEXTMENU_CALLBACK )( void* data );
struct EDITOR_CONTEXTMENU_ITEM;
-typedef U8( *EDITOR_CONTEXTMENU_ENABLED_CALLBACK )( const EDITOR_CONTEXTMENU_ITEM* item );
+typedef U8( *EDITOR_CONTEXTMENU_ENABLED_CALLBACK )( EDITOR_CONTEXTMENU_ITEM* item );
struct EDITOR_CONTEXTMENU_ITEM {
char text[64]{};
@@ -209,9 +209,6 @@ extern void editor_create_map_view( GAME_EDITOR* e );
extern void editor_update_properties_column( GAME_EDITOR* e );
extern const char* editor_tool_name();
extern void editor_set_view_mode( I32 mode );
-extern void editor_show_contextmenu( I32 x, I32 y, LIST<EDITOR_CONTEXTMENU_ITEM>* items, const char* title = 0 );
-extern void editor_hide_contextmenu();
-extern U8 editor_contextmenu_open();
extern void editor_undo_clear( GAME_EDITOR* e );
extern void editor_undo_record_create_walls( GAME_EDITOR* e, I32 start_idx, I32 count );
extern void editor_undo_record_create_poly( GAME_EDITOR* e, I32 start_idx );
@@ -220,6 +217,17 @@ extern void editor_undo_record_create_entity( GAME_EDITOR* e, I32 start_idx );
extern U8 editor_undo( GAME_EDITOR* e );
extern U8 editor_redo( GAME_EDITOR* e );
+extern void editor_show_contextmenu( I32 x, I32 y, LIST<EDITOR_CONTEXTMENU_ITEM>* items, const char* title = 0 );
+extern void editor_hide_contextmenu();
+extern U8 editor_contextmenu_open();
+extern void editor_contextmenu_set_item(
+ EDITOR_CONTEXTMENU_ITEM* item,
+ const char* text,
+ EDITOR_CONTEXTMENU_CALLBACK cb = 0,
+ void* data = 0,
+ EDITOR_CONTEXTMENU_ENABLED_CALLBACK enabled_cb = 0
+);
+
struct GUI_EDITORWINDOW : GUI_WINDOW {};
struct GUI_EDITOR_3DVIEW : GUI_VIEW {
U8 heldoutbounds;