summaryrefslogtreecommitdiff
path: root/src/editor/editor_menubar.cpp
diff options
context:
space:
mode:
authoraura <nw@moneybot.cc>2026-03-16 12:51:06 +0100
committeraura <nw@moneybot.cc>2026-03-16 12:51:06 +0100
commitf1882249843caa8bd931ecb76bb489615e079b10 (patch)
tree15d0e3f7d775684ff91d85cc37843138e72b1735 /src/editor/editor_menubar.cpp
parentb71bb14c7dec546304e3396d7040d88c6c86a3a7 (diff)
editor work
Diffstat (limited to 'src/editor/editor_menubar.cpp')
-rw-r--r--src/editor/editor_menubar.cpp22
1 files changed, 2 insertions, 20 deletions
diff --git a/src/editor/editor_menubar.cpp b/src/editor/editor_menubar.cpp
index cfb12a3..cef2650 100644
--- a/src/editor/editor_menubar.cpp
+++ b/src/editor/editor_menubar.cpp
@@ -66,24 +66,6 @@ void editor_raise_header_toolbar( GAME_EDITOR* e ) {
parent->children.push( bar );
}
-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
-) {
- if( !item )
- return;
-
- item->items.clear();
- snprintf( item->text, sizeof( item->text ), "%s", text ? text : "" );
- item->cb = cb;
- item->data = data;
- item->enabled = 1;
- item->enabled_cb = enabled_cb;
-}
-
void editor_contextmenu_save_cb( void* ) {
if( editor )
editor_save_map( editor );
@@ -107,11 +89,11 @@ void editor_contextmenu_set_tool_cb( void* data ) {
editor_settool( (U8)(I64)data );
}
-U8 editor_contextmenu_undo_enabled( const EDITOR_CONTEXTMENU_ITEM* ) {
+U8 editor_contextmenu_undo_enabled( EDITOR_CONTEXTMENU_ITEM* ) {
return editor && editor->undo_actions.size > 0;
}
-U8 editor_contextmenu_redo_enabled( const EDITOR_CONTEXTMENU_ITEM* ) {
+U8 editor_contextmenu_redo_enabled( EDITOR_CONTEXTMENU_ITEM* ) {
return editor && editor->redo_actions.size > 0;
}