#include <C4EditCursor.h>
Classes | |
struct | ObjselItemDt |
Public Member Functions | |
C4EditCursor () | |
~C4EditCursor () | |
void | Default () |
void | Clear () |
void | Execute () |
void | ClearPointers (C4Object *pObj) |
bool | ToggleMode () |
void | Draw (C4TargetFacet &cgo) |
int32_t | GetMode () |
C4Object * | GetTarget () |
bool | SetMode (int32_t iMode) |
bool | In (const char *szText) |
bool | Duplicate () |
bool | OpenPropTools () |
bool | Delete () |
void | GrabContents () |
bool | LeftButtonUp (DWORD dwKeyState) |
bool | LeftButtonDown (DWORD dwKeyState) |
bool | RightButtonUp (DWORD dwKeyState) |
bool | RightButtonDown (DWORD dwKeyState) |
bool | KeyDown (C4KeyCode KeyCode, DWORD dwKeyState) |
bool | KeyUp (C4KeyCode KeyCode, DWORD dwKeyState) |
bool | Move (float iX, float iY, float zoom, DWORD dwKeyState) |
bool | Move (DWORD new_key_state) |
bool | Init () |
bool | EditingOK (bool for_landscape_drawing=false) |
C4EditCursorSelection & | GetSelection () |
void | SetHold (bool fToState) |
void | OnSelectionChanged (bool by_objectlist=false) |
bool | AltDown () |
bool | AltUp () |
void | SetMouseHover (bool h) |
bool | HasTransformCursor () const |
bool | IsHoveringTransformMarker () const |
void | DoContextObjsel (C4Object *, bool clear) |
void | PerformDuplication (int32_t *object_numbers, int32_t object_count, bool local_call) |
void | PerformDuplicationLegacy (int32_t *pObjects, int32_t iObjectNum, bool fLocalCall) |
void | AddToSelection (C4PropList *add_obj) |
bool | RemoveFromSelection (C4PropList *remove_obj) |
void | ClearSelection (C4PropList *next_selection=nullptr) |
void | SetCreatorDef (C4Def *new_def) |
C4Def * | GetCreatorDef () |
void | EMControl (enum C4PacketType eCtrlType, class C4ControlPacket *pCtrl) |
void | InvalidateSelection () |
void | ValidateSelection () |
bool | IsSelectionInvalidated () const |
bool | GetCurrentSelectionPosition (int32_t *x, int32_t *y) |
void | SetHighlightedObject (C4Object *new_highlight) |
Protected Member Functions | |
void | UpdateStatusBar () |
void | ApplyCreateObject (bool contained) |
void | ApplyToolPicker () |
void | ToolFailure () |
void | PutContents () |
void | UpdateDropTarget (DWORD dwKeyState) |
bool | DoContextMenu (DWORD dwKeyState) |
void | AppendMenuItem (int num, const StdStrBuf &label) |
void | ApplyToolFill () |
void | ApplyToolRect () |
void | ApplyToolLine () |
void | ApplyToolBrush () |
void | DrawObject (C4TargetFacet &cgo, C4Object *cobj, uint32_t select_mark_color, bool highlight, bool draw_transform_marker) |
void | DrawSelectMark (C4Facet &cgo, FLOAT_RECT r, float width, uint32_t color=0xffffffff) |
bool | HasTransformMarker (float *x, float *y, float zoom) const |
void | FrameSelection () |
void | MoveSelection (C4Real iXOff, C4Real iYOff, bool drag_finished) |
void | EMMoveObject (enum C4ControlEMObjectAction eAction, C4Real tx, C4Real ty, C4Object *pTargetObj, const C4EditCursorSelection *pObjs=nullptr, const char *szScript=nullptr, bool drag_finished=false) |
void | DoContextObjCommand (C4Object *, const char *cmd) |
void | ObjselectDelItems () |
Protected Attributes | |
bool | fAltWasDown |
bool | fShiftWasDown |
bool | has_mouse_hover |
bool | selection_invalid |
int32_t | Mode |
float | X |
float | Y |
float | X2 |
float | Y2 |
float | Zoom |
bool | Hold |
bool | DragFrame |
bool | DragLine |
bool | DragShape |
bool | DragTransform |
int32_t | DragRot0 |
int32_t | DragCon0 |
int32_t | DragRotLast |
int32_t | DragConLast |
C4Object * | Target |
C4Object * | DropTarget |
C4Value | highlighted_object |
class C4Def * | creator_def |
std::unique_ptr< C4GraphicsOverlay > | creator_overlay |
std::vector< ObjselItemDt > | itemsObjselect |
C4EditCursorSelection | selection |
Definition at line 43 of file C4EditCursor.h.
struct C4EditCursor::ObjselItemDt |
Definition at line 62 of file C4EditCursor.h.
Class Members | ||
---|---|---|
StdCopyStrBuf | Command | |
C4EditCursor * | EditCursor | |
C4Object * | Object |
C4EditCursor::C4EditCursor | ( | ) |
Definition at line 128 of file C4EditCursor.cpp.
C4EditCursor::~C4EditCursor | ( | ) |
Definition at line 136 of file C4EditCursor.cpp.
References Clear().
void C4EditCursor::AddToSelection | ( | C4PropList * | add_obj | ) |
Definition at line 331 of file C4EditCursor.cpp.
References C4VPropList(), C4PropList::GetObject(), C4EditCursorSelection::IsContained(), selection, and C4PropList::Status.
Referenced by DoContextObjsel(), FrameSelection(), GrabContents(), LeftButtonDown(), and RightButtonDown().
bool C4EditCursor::AltDown | ( | ) |
Definition at line 1419 of file C4EditCursor.cpp.
References C4CNS_ModeDraw, Console, Mode, C4ToolsDlg::SetAlternateTool(), and C4Console::ToolsDlg.
Referenced by KeyDown(), KeyUp(), and Move().
bool C4EditCursor::AltUp | ( | ) |
Definition at line 1430 of file C4EditCursor.cpp.
References C4CNS_ModeDraw, Console, Mode, C4ToolsDlg::ResetAlternateTool(), and C4Console::ToolsDlg.
Referenced by KeyDown(), KeyUp(), and Move().
|
protected |
Definition at line 1116 of file C4EditCursor.cpp.
References IDM_VPORTDYN_FIRST, and itemsObjselect.
Referenced by DoContextMenu().
|
protected |
Definition at line 1075 of file C4EditCursor.cpp.
References CID_EMMoveObj, C4ControlEMMoveObject::CreateObject(), creator_def, DropTarget, EditingOK(), EMControl(), ftofix(), C4Def::id, X, and Y.
Referenced by LeftButtonDown().
|
protected |
Definition at line 1084 of file C4EditCursor.cpp.
References C4ToolsDlg::BackMaterial, C4ToolsDlg::BackTexture, CID_EMDrawTool, Console, EditingOK(), EMControl(), EMDT_Brush, C4Landscape::GetMode(), C4ToolsDlg::Grade, Landscape, C4ToolsDlg::Material, C4ToolsDlg::Texture, C4Console::ToolsDlg, X, and Y.
Referenced by LeftButtonDown(), and Move().
|
protected |
Definition at line 1108 of file C4EditCursor.cpp.
References CID_EMDrawTool, Console, EditingOK(), EMControl(), EMDT_Fill, C4Landscape::GetMode(), C4ToolsDlg::Grade, Landscape, C4ToolsDlg::Material, C4Console::ToolsDlg, X, Y, and Y2.
Referenced by Execute().
|
protected |
Definition at line 1092 of file C4EditCursor.cpp.
References C4ToolsDlg::BackMaterial, C4ToolsDlg::BackTexture, CID_EMDrawTool, Console, EditingOK(), EMControl(), EMDT_Line, C4Landscape::GetMode(), C4ToolsDlg::Grade, Landscape, C4ToolsDlg::Material, C4ToolsDlg::Texture, C4Console::ToolsDlg, X, X2, Y, and Y2.
Referenced by LeftButtonUp().
|
protected |
Definition at line 1313 of file C4EditCursor.cpp.
References C4TLS_MatSky, Console, Exact, GBackMat(), C4Landscape::GetBackMapIndex(), C4Landscape::GetBackPix(), C4TextureMap::GetEntry(), C4Landscape::GetMapIndex(), C4Landscape::GetMapZoom(), C4TexMapEntry::GetMaterialName(), C4Landscape::GetMode(), C4TexMapEntry::GetTextureName(), Hold, C4TexMapEntry::isNull(), Landscape, C4MaterialMap::Map, MaterialMap, MatValid(), C4ToolsDlg::ModeBack, C4MaterialCore::Name, C4ToolsDlg::SelectBackMaterial(), C4ToolsDlg::SelectBackTexture(), C4ToolsDlg::SelectMaterial(), C4ToolsDlg::SelectTexture(), C4ToolsDlg::SetIFT(), Static, TextureMap, C4Console::ToolsDlg, X, and Y.
Referenced by LeftButtonDown().
|
protected |
Definition at line 1100 of file C4EditCursor.cpp.
References C4ToolsDlg::BackMaterial, C4ToolsDlg::BackTexture, CID_EMDrawTool, Console, EditingOK(), EMControl(), EMDT_Rect, C4Landscape::GetMode(), C4ToolsDlg::Grade, Landscape, C4ToolsDlg::Material, C4ToolsDlg::Texture, C4Console::ToolsDlg, X, X2, Y, and Y2.
Referenced by LeftButtonUp().
void C4EditCursor::Clear | ( | ) |
Definition at line 994 of file C4EditCursor.cpp.
References Console, creator_overlay, ObjselectDelItems(), C4ConsoleGUI::PropertyDlgUpdate(), and selection.
Referenced by C4Game::Clear(), C4Console::Clear(), C4Application::Clear(), and ~C4EditCursor().
void C4EditCursor::ClearPointers | ( | C4Object * | pObj | ) |
Definition at line 182 of file C4EditCursor.cpp.
References C4EditCursorSelection::ClearPointers(), OnSelectionChanged(), selection, and Target.
Referenced by C4Console::ClearPointers().
void C4EditCursor::ClearSelection | ( | C4PropList * | next_selection = nullptr | ) |
Definition at line 352 of file C4EditCursor.cpp.
References selection.
Referenced by DoContextObjsel(), FrameSelection(), GrabContents(), LeftButtonDown(), and RightButtonDown().
void C4EditCursor::Default | ( | ) |
Definition at line 975 of file C4EditCursor.cpp.
References C4CNS_ModeEdit, creator_def, creator_overlay, DragCon0, DragConLast, DragFrame, DragLine, DragRot0, DragRotLast, DragShape, DragTransform, DropTarget, fAltWasDown, fShiftWasDown, FullCon, has_mouse_hover, Hold, Mode, selection, selection_invalid, Target, X, X2, Y, and Y2.
Referenced by C4Console::Default().
bool C4EditCursor::Delete | ( | ) |
Definition at line 605 of file C4EditCursor.cpp.
References Control, EditingOK(), EMMO_Remove, EMMoveObject(), Fix0, C4GameControl::isCtrlHost(), OnSelectionChanged(), and selection.
Referenced by DoContextMenu(), and C4Game::InitKeyboard().
|
protected |
Definition at line 1127 of file C4EditCursor.cpp.
References AppendMenuItem(), Console, C4Object::Contents, StdStrBuf::Copy(), Delete(), DoContextObjCommand(), DoContextObjsel(), Duplicate(), C4ConsoleGUI::Editing, C4FindObject::FindMany(), StdStrBuf::Format(), FormatString(), StdStrBuf::getData(), C4String::GetData(), C4Value::getFunction(), C4ValueArray::GetItem(), StdStrBuf::getLength(), C4AulFunc::GetName(), C4PropList::GetName(), C4EditCursorSelection::GetObject(), C4PropList::GetPropertyArray(), C4ValueArray::GetSize(), C4Value::getStr(), C4Object::GetX(), C4Object::GetY(), GrabContents(), IDM_VIEWPORT_CONTENTS, IDM_VIEWPORT_DELETE, IDM_VIEWPORT_DUPLICATE, IDM_VPORTDYN_FIRST, itemsObjselect, LoadResStr(), C4PropListNumbered::Number, C4ObjectList::ObjectCount(), Objects, ObjselectDelItems(), P_EditCursorCommands, C4GameObjects::Sectors, selection, SetMenuItemText(), X, and Y.
Referenced by RightButtonUp().
|
protected |
Definition at line 1447 of file C4EditCursor.cpp.
References FormatString(), StdStrBuf::getData(), In(), and C4PropListNumbered::Number.
Referenced by DoContextMenu().
void C4EditCursor::DoContextObjsel | ( | C4Object * | obj, |
bool | clear | ||
) |
Definition at line 1440 of file C4EditCursor.cpp.
References AddToSelection(), ClearSelection(), and OnSelectionChanged().
Referenced by DoContextMenu().
void C4EditCursor::Draw | ( | C4TargetFacet & | cgo | ) |
Definition at line 839 of file C4EditCursor.cpp.
References C4CNS_ModeCreateObject, C4CNS_ModeDraw, C4GFXBLIT_ADDITIVE, C4MC_Cursor_DropInto, Console, creator_def, creator_overlay, DragFrame, DragLine, C4Draw::DrawCircleDw(), C4Draw::DrawFrameDw(), C4Draw::DrawLineDw(), DrawObject(), C4Facet::DrawX(), DropTarget, C4GraphicsResource::fctMouseCursor, fShiftWasDown, C4Value::getObj(), C4Object::GetX(), C4Object::GetY(), C4ToolsDlg::Grade, C4Def::Graphics, GraphicsResource, has_mouse_hover, C4Facet::Hgt, C4Rect::Hgt, highlighted_object, C4ToolsDlg::IsGradedTool(), Mode, NO_OWNER, pDraw, selection, C4TargetFacet::Set(), C4Def::Shape, C4Object::Shape, C4Facet::Surface, C4TargetFacet::TargetX, C4TargetFacet::TargetY, C4Console::ToolsDlg, C4Facet::Wdt, C4Rect::Wdt, X, C4Facet::X, C4Rect::x, X2, Y, C4Facet::Y, C4Rect::y, Y2, and C4TargetFacet::Zoom.
Referenced by C4Viewport::Draw().
|
protected |
Definition at line 761 of file C4EditCursor.cpp.
References C4Object::BlitMode, C4GFXBLIT_ADDITIVE, C4GFXBLIT_CLRSFC_MOD2, C4Object::ColorMod, DragTransform, C4Facet::Draw(), C4Object::Draw(), DrawSelectMark(), C4Object::DrawTopFace(), C4GraphicsResource::fctTransformKnob, StdSubMeshInstance::FO_NearestToFarthest, C4Object::GetDrawPosition(), GraphicsResource, HasTransformMarker(), C4Facet::Hgt, C4Rect::Hgt, pDraw, C4Object::pMeshInstance, C4Draw::ResetBlitMode(), C4Draw::SetBlitMode(), StdMeshInstance::SetFaceOrdering(), StdMeshInstance::SetFaceOrderingForClrModulation(), C4Object::Shape, C4Facet::Surface, C4Rect::Wdt, X, C4Facet::X, C4Rect::x, X2, Y, C4Facet::Y, C4Rect::y, Y2, and C4TargetFacet::Zoom.
Referenced by Draw().
|
protected |
Definition at line 904 of file C4EditCursor.cpp.
References FLOAT_RECT::bottom, C4Facet::Hgt, FLOAT_RECT::left, pDraw, C4Draw::PerformMultiLines(), FLOAT_RECT::right, C4Facet::Surface, FLOAT_RECT::top, and C4Facet::Wdt.
Referenced by DrawObject().
bool C4EditCursor::Duplicate | ( | ) |
Definition at line 631 of file C4EditCursor.cpp.
References EMMO_Duplicate, EMMoveObject(), Fix0, and selection.
Referenced by DoContextMenu().
bool C4EditCursor::EditingOK | ( | bool | for_landscape_drawing = false | ) |
Definition at line 1290 of file C4EditCursor.cpp.
References Console, C4ConsoleGUI::Editing, Hold, LoadResStr(), and C4Console::Message().
Referenced by ApplyCreateObject(), ApplyToolBrush(), ApplyToolFill(), ApplyToolLine(), ApplyToolRect(), Delete(), C4Console::In(), and ToggleMode().
void C4EditCursor::EMControl | ( | enum C4PacketType | eCtrlType, |
class C4ControlPacket * | pCtrl | ||
) |
Definition at line 1399 of file C4EditCursor.cpp.
References CDT_Decide, Control, and C4GameControl::DoInput().
Referenced by ApplyCreateObject(), ApplyToolBrush(), ApplyToolFill(), ApplyToolLine(), ApplyToolRect(), C4PropertyPath::DoCall(), EMMoveObject(), and C4PropertyPath::SetProperty().
|
protected |
Definition at line 1374 of file C4EditCursor.cpp.
References CID_EMMoveObj, EMControl(), C4PropListNumbered::Number, C4EditCursorSelection::ObjectCount(), and C4PropList::Status.
Referenced by Delete(), Duplicate(), Execute(), GrabContents(), In(), Move(), MoveSelection(), and PutContents().
void C4EditCursor::Execute | ( | ) |
Definition at line 141 of file C4EditCursor.cpp.
References ApplyToolFill(), C4CNS_ModeDraw, C4CNS_ModeEdit, C4TLS_Fill, Console, C4EditCursorSelection::ConsolidateEmpty(), C4Console::EditCursor, C4ConsoleGUI::Editing, EMMO_Move, EMMO_MoveForced, EMMoveObject(), Fix0, fShiftWasDown, Game, C4Game::HaltCount, Hold, IsSelectionInvalidated(), C4Game::iTick35, Mode, C4ConsoleGUI::PropertyDlgUpdate(), selection, C4ToolsDlg::Tool, and C4Console::ToolsDlg.
Referenced by C4Console::Execute().
|
protected |
Definition at line 952 of file C4EditCursor.cpp.
References AddToSelection(), ClearSelection(), Inside(), Objects, OCF_NotContained, OnSelectionChanged(), X, X2, Y, and Y2.
Referenced by LeftButtonUp().
|
inline |
bool C4EditCursor::GetCurrentSelectionPosition | ( | int32_t * | x, |
int32_t * | y | ||
) |
Definition at line 1454 of file C4EditCursor.cpp.
References C4EditCursorSelection::GetObject(), C4Object::GetX(), C4Object::GetY(), selection, and C4PropList::Status.
int32_t C4EditCursor::GetMode | ( | ) |
|
inline |
Definition at line 104 of file C4EditCursor.h.
References selection.
Referenced by PropertyDlgProc().
C4Object * C4EditCursor::GetTarget | ( | ) |
Definition at line 1285 of file C4EditCursor.cpp.
References Target.
void C4EditCursor::GrabContents | ( | ) |
Definition at line 1246 of file C4EditCursor.cpp.
References AddToSelection(), ClearSelection(), C4Object::Contents, EMMO_Exit, EMMoveObject(), Fix0, C4EditCursorSelection::GetObject(), Hold, OnSelectionChanged(), and selection.
Referenced by DoContextMenu().
|
inline |
Definition at line 113 of file C4EditCursor.h.
References DragTransform, and IsHoveringTransformMarker().
|
protected |
Definition at line 821 of file C4EditCursor.cpp.
References C4Object::Def, C4GraphicsResource::fctTransformKnob, FullCon, C4Object::GetCon(), C4EditCursorSelection::GetObject(), GraphicsResource, C4Def::GrowthType, C4Facet::Hgt, C4Rect::Hgt, C4Def::Rotateable, selection, C4Def::Shape, C4Object::Shape, C4Rect::Wdt, and C4Rect::y.
Referenced by DrawObject(), and IsHoveringTransformMarker().
bool C4EditCursor::In | ( | const char * | szText | ) |
Definition at line 966 of file C4EditCursor.cpp.
References Console, C4EditCursorSelection::ConsolidateEmpty(), EMMO_Script, EMMoveObject(), Fix0, C4Console::MRU_Object, C4ConsoleGUI::PropertyDlgUpdate(), C4Console::RegisterRecentInput(), and selection.
Referenced by DoContextObjCommand(), and PropertyDlgProc().
bool C4EditCursor::Init | ( | ) |
Definition at line 170 of file C4EditCursor.cpp.
References Application, Console, IDR_CONTEXTMENUS, Mode, and C4ConsoleGUI::UpdateModeCtrls().
Referenced by C4Console::InitGame().
|
inline |
bool C4EditCursor::IsHoveringTransformMarker | ( | ) | const |
Definition at line 1468 of file C4EditCursor.cpp.
References C4GraphicsResource::fctTransformKnob, C4EditCursorSelection::GetObject(), C4Object::GetX(), C4Object::GetY(), GraphicsResource, HasTransformMarker(), C4Facet::Hgt, selection, X, Y, and Zoom.
Referenced by HasTransformCursor(), and LeftButtonDown().
|
inline |
Definition at line 154 of file C4EditCursor.h.
References selection_invalid.
Referenced by Execute().
Definition at line 528 of file C4EditCursor.cpp.
References AltDown(), AltUp(), fAltWasDown, and fShiftWasDown.
Definition at line 550 of file C4EditCursor.cpp.
References AltDown(), AltUp(), fAltWasDown, and fShiftWasDown.
bool C4EditCursor::LeftButtonDown | ( | DWORD | dwKeyState | ) |
Definition at line 358 of file C4EditCursor.cpp.
References AddToSelection(), ApplyCreateObject(), ApplyToolBrush(), ApplyToolPicker(), C4CNS_ModeCreateObject, C4CNS_ModeDraw, C4CNS_ModeEdit, C4TLS_Brush, C4TLS_Fill, C4TLS_Line, C4TLS_Picker, C4TLS_Rect, ClearSelection(), Console, DragCon0, DragConLast, DragFrame, DragLine, DragRot0, DragRotLast, DragShape, DragTransform, DropTarget, Game, C4Object::GetCon(), C4EditCursorSelection::GetObject(), C4Object::GetR(), C4Game::HaltCount, Hold, IsHoveringTransformMarker(), LoadResStr(), C4Console::Message(), Mode, OnSelectionChanged(), RemoveFromSelection(), selection, Target, C4ToolsDlg::Tool, C4Console::ToolsDlg, X, X2, Y, Y2, and Zoom.
bool C4EditCursor::LeftButtonUp | ( | DWORD | dwKeyState | ) |
Definition at line 483 of file C4EditCursor.cpp.
References ApplyToolLine(), ApplyToolRect(), C4CNS_ModeDraw, C4CNS_ModeEdit, C4TLS_Line, C4TLS_Rect, Console, DragFrame, DragLine, DragShape, DragTransform, DropTarget, Fix0, FrameSelection(), Hold, Mode, MoveSelection(), PutContents(), C4ToolsDlg::Tool, C4Console::ToolsDlg, UpdateStatusBar(), X, and Y.
bool C4EditCursor::Move | ( | DWORD | new_key_state | ) |
Definition at line 290 of file C4EditCursor.cpp.
References Move(), X, Y, and Zoom.
bool C4EditCursor::Move | ( | float | iX, |
float | iY, | ||
float | zoom, | ||
DWORD | dwKeyState | ||
) |
Definition at line 189 of file C4EditCursor.cpp.
References AltDown(), AltUp(), ApplyToolBrush(), C4CNS_ModeCreateObject, C4CNS_ModeDraw, C4CNS_ModeEdit, C4TLS_Brush, C4TLS_Line, C4TLS_Rect, Console, C4Object::Def, DragCon0, DragConLast, DragFrame, DragRot0, DragRotLast, DragShape, DragTransform, EMMO_Transform, EMMoveObject(), fAltWasDown, C4Game::FindObject(), fShiftWasDown, ftofix(), FullCon, Game, C4EditCursorSelection::GetLastObject(), C4EditCursorSelection::GetObject(), C4Def::GrowthType, Hold, C4EditCursorSelection::IsContained(), itofix(), Mode, MoveSelection(), OCF_NotContained, C4Def::Oversize, C4Def::Rotateable, selection, Target, C4ToolsDlg::Tool, C4Console::ToolsDlg, UpdateDropTarget(), UpdateStatusBar(), X, X2, Y, Y2, and Zoom.
Referenced by C4ViewportWindow::EditCursorMove(), Move(), and PerformDuplication().
Definition at line 947 of file C4EditCursor.cpp.
References EMMO_Move, EMMO_MoveForced, EMMoveObject(), fShiftWasDown, and selection.
Referenced by LeftButtonUp(), and Move().
|
protected |
Definition at line 1405 of file C4EditCursor.cpp.
References itemsObjselect.
Referenced by Clear(), and DoContextMenu().
void C4EditCursor::OnSelectionChanged | ( | bool | by_objectlist = false | ) |
Definition at line 325 of file C4EditCursor.cpp.
References Console, C4Console::ObjectListDlg, C4ConsoleGUI::PropertyDlgUpdate(), selection, and C4ObjectListDlg::Update().
Referenced by ClearPointers(), Delete(), DoContextObjsel(), FrameSelection(), GrabContents(), LeftButtonDown(), PerformDuplication(), PerformDuplicationLegacy(), and RightButtonDown().
bool C4EditCursor::OpenPropTools | ( | ) |
Definition at line 616 of file C4EditCursor.cpp.
References C4CNS_ModeDraw, C4CNS_ModeEdit, C4CNS_ModePlay, Console, Mode, C4ToolsDlg::Open(), C4ConsoleGUI::PropertyDlgOpen(), C4ConsoleGUI::PropertyDlgUpdate(), selection, and C4Console::ToolsDlg.
Referenced by SetMode().
void C4EditCursor::PerformDuplication | ( | int32_t * | object_numbers, |
int32_t | object_count, | ||
bool | local_call | ||
) |
Definition at line 637 of file C4EditCursor.cpp.
References C4Object::AddObjectAndContentsToArray(), AulExec, C4V_Nil, C4VArray(), C4VInt(), C4VObj(), C4PropList::Call(), C4AulScriptEngine::CloseUserFile(), C4AulScriptEngine::CreateUserFile(), C4AulExec::DirectExec(), fAltWasDown, fShiftWasDown, C4RefCntPointer< T >::Get(), StdStrBuf::getData(), C4PropListNumbered::GetEnumerationIndex(), C4AulUserFile::GetFileLength(), C4AulScriptEngine::GetPropList(), C4Value::GetType(), C4AulScriptEngine::GetUserFile(), C4AulUserFile::GrabFileContents(), LogF(), Move(), Objects, OnSelectionChanged(), PerformDuplicationLegacy(), PSF_SaveScenarioObjects, C4GameObjects::SafeObjectPointer(), ScriptEngine, selection, SetHold(), X, Y, and Zoom.
void C4EditCursor::PerformDuplicationLegacy | ( | int32_t * | pObjects, |
int32_t | iObjectNum, | ||
bool | fLocalCall | ||
) |
Definition at line 732 of file C4EditCursor.cpp.
References C4VObj(), C4PropList::Call(), C4Game::CreateObject(), Game, C4PropList::GetPrototype(), C4Object::GetX(), C4Object::GetY(), Objects, OnSelectionChanged(), C4Object::Owner, PSF_EditCursorDeselection, PSF_EditCursorSelection, C4GameObjects::SafeObjectPointer(), selection, SetHold(), and C4PropList::Status.
Referenced by PerformDuplication().
|
protected |
Definition at line 1279 of file C4EditCursor.cpp.
References DropTarget, EMMO_Enter, EMMoveObject(), Fix0, and selection.
Referenced by LeftButtonUp().
bool C4EditCursor::RemoveFromSelection | ( | C4PropList * | remove_obj | ) |
Definition at line 341 of file C4EditCursor.cpp.
References C4VPropList(), C4PropList::GetObject(), C4EditCursorSelection::IsContained(), selection, and C4PropList::Status.
Referenced by LeftButtonDown().
bool C4EditCursor::RightButtonDown | ( | DWORD | dwKeyState | ) |
Definition at line 445 of file C4EditCursor.cpp.
References AddToSelection(), C4CNS_ModeEdit, ClearSelection(), C4EditCursorSelection::IsContained(), Mode, OnSelectionChanged(), selection, Target, X, and Y.
bool C4EditCursor::RightButtonUp | ( | DWORD | dwKeyState | ) |
Definition at line 593 of file C4EditCursor.cpp.
References DoContextMenu(), Target, and UpdateStatusBar().
|
inline |
void C4EditCursor::SetHighlightedObject | ( | C4Object * | new_highlight | ) |
Definition at line 1463 of file C4EditCursor.cpp.
References C4VObj(), and highlighted_object.
|
inline |
Definition at line 105 of file C4EditCursor.h.
References Hold.
Referenced by PerformDuplication(), and PerformDuplicationLegacy().
bool C4EditCursor::SetMode | ( | int32_t | iMode | ) |
Definition at line 1010 of file C4EditCursor.cpp.
References C4CNS_ModeCreateObject, C4CNS_ModeDraw, C4CNS_ModeEdit, C4CNS_ModePlay, Console, C4MouseControl::HideCursor(), Mode, MouseControl, OpenPropTools(), C4ConsoleGUI::PropertyDlgClose(), C4MouseControl::ShowCursor(), C4ConsoleGUI::ToolsDlgClose(), and C4ConsoleGUI::UpdateModeCtrls().
Referenced by ConsoleDlgProc(), and ToggleMode().
|
inline |
bool C4EditCursor::ToggleMode | ( | ) |
Definition at line 1049 of file C4EditCursor.cpp.
References C4CNS_ModeCreateObject, C4CNS_ModeDraw, C4CNS_ModeEdit, C4CNS_ModePlay, EditingOK(), Mode, and SetMode().
Referenced by C4Game::InitKeyboard().
|
protected |
Definition at line 1306 of file C4EditCursor.cpp.
References Console, FormatString(), StdStrBuf::getData(), Hold, LoadResStr(), C4ToolsDlg::Material, C4Console::Message(), C4ToolsDlg::Texture, and C4Console::ToolsDlg.
|
protected |
Definition at line 1260 of file C4EditCursor.cpp.
References C4CNS_ModeCreateObject, creator_def, DropTarget, C4EditCursorSelection::GetObject(), C4EditCursorSelection::IsContained(), Mode, Objects, selection, X, and Y.
Referenced by Move().
|
protected |
Definition at line 296 of file C4EditCursor.cpp.
References C4CNS_ModeCreateObject, C4CNS_ModeDraw, C4CNS_ModeEdit, C4CNS_ModePlay, Console, C4ConsoleGUI::CONSOLE_Cursor, StdStrBuf::CopyUntil(), creator_def, C4ConsoleGUI::DisplayInfoText(), StdStrBuf::Format(), C4Landscape::GetBackMat(), C4MouseControl::GetCaption(), C4Landscape::GetMat(), C4PropList::GetName(), C4PropListStatic::GetName(), Landscape, LoadResStr(), C4MaterialMap::Map, MaterialMap, MatValid(), Mode, MouseControl, C4MaterialCore::Name, Target, X, and Y.
Referenced by LeftButtonUp(), Move(), and RightButtonUp().
|
inline |
|
protected |
Definition at line 60 of file C4EditCursor.h.
Referenced by ApplyCreateObject(), Default(), Draw(), GetCreatorDef(), SetCreatorDef(), UpdateDropTarget(), and UpdateStatusBar().
|
protected |
Definition at line 61 of file C4EditCursor.h.
Referenced by Clear(), Default(), Draw(), and SetCreatorDef().
|
protected |
Definition at line 57 of file C4EditCursor.h.
Referenced by Default(), LeftButtonDown(), and Move().
|
protected |
Definition at line 57 of file C4EditCursor.h.
Referenced by Default(), LeftButtonDown(), and Move().
|
protected |
Definition at line 56 of file C4EditCursor.h.
Referenced by Default(), Draw(), LeftButtonDown(), LeftButtonUp(), and Move().
|
protected |
Definition at line 56 of file C4EditCursor.h.
Referenced by Default(), Draw(), LeftButtonDown(), and LeftButtonUp().
|
protected |
Definition at line 57 of file C4EditCursor.h.
Referenced by Default(), LeftButtonDown(), and Move().
|
protected |
Definition at line 57 of file C4EditCursor.h.
Referenced by Default(), LeftButtonDown(), and Move().
|
protected |
Definition at line 56 of file C4EditCursor.h.
Referenced by Default(), LeftButtonDown(), LeftButtonUp(), and Move().
|
protected |
Definition at line 56 of file C4EditCursor.h.
Referenced by Default(), DrawObject(), HasTransformCursor(), LeftButtonDown(), LeftButtonUp(), and Move().
|
protected |
Definition at line 58 of file C4EditCursor.h.
Referenced by ApplyCreateObject(), Default(), Draw(), LeftButtonDown(), LeftButtonUp(), PutContents(), and UpdateDropTarget().
|
protected |
Definition at line 50 of file C4EditCursor.h.
Referenced by Default(), KeyDown(), KeyUp(), Move(), and PerformDuplication().
|
protected |
Definition at line 51 of file C4EditCursor.h.
Referenced by Default(), Draw(), Execute(), KeyDown(), KeyUp(), Move(), MoveSelection(), and PerformDuplication().
|
protected |
Definition at line 52 of file C4EditCursor.h.
Referenced by Default(), Draw(), and SetMouseHover().
|
protected |
Definition at line 59 of file C4EditCursor.h.
Referenced by Draw(), and SetHighlightedObject().
|
protected |
Definition at line 56 of file C4EditCursor.h.
Referenced by ApplyToolPicker(), Default(), EditingOK(), Execute(), GrabContents(), LeftButtonDown(), LeftButtonUp(), Move(), SetHold(), and ToolFailure().
|
protected |
Definition at line 70 of file C4EditCursor.h.
Referenced by AppendMenuItem(), DoContextMenu(), and ObjselectDelItems().
|
protected |
Definition at line 54 of file C4EditCursor.h.
Referenced by AltDown(), AltUp(), Default(), Draw(), Execute(), GetMode(), Init(), LeftButtonDown(), LeftButtonUp(), Move(), OpenPropTools(), RightButtonDown(), SetMode(), ToggleMode(), UpdateDropTarget(), and UpdateStatusBar().
|
protected |
Definition at line 75 of file C4EditCursor.h.
Referenced by AddToSelection(), Clear(), ClearPointers(), ClearSelection(), Default(), Delete(), DoContextMenu(), Draw(), Duplicate(), Execute(), GetCurrentSelectionPosition(), GetSelection(), GrabContents(), HasTransformMarker(), In(), IsHoveringTransformMarker(), LeftButtonDown(), Move(), MoveSelection(), OnSelectionChanged(), OpenPropTools(), PerformDuplication(), PerformDuplicationLegacy(), PutContents(), RemoveFromSelection(), RightButtonDown(), and UpdateDropTarget().
|
protected |
Definition at line 53 of file C4EditCursor.h.
Referenced by Default(), InvalidateSelection(), IsSelectionInvalidated(), and ValidateSelection().
|
protected |
Definition at line 58 of file C4EditCursor.h.
Referenced by ClearPointers(), Default(), GetTarget(), LeftButtonDown(), Move(), RightButtonDown(), RightButtonUp(), and UpdateStatusBar().
|
protected |
Definition at line 55 of file C4EditCursor.h.
Referenced by ApplyCreateObject(), ApplyToolBrush(), ApplyToolFill(), ApplyToolLine(), ApplyToolPicker(), ApplyToolRect(), Default(), DoContextMenu(), Draw(), DrawObject(), FrameSelection(), IsHoveringTransformMarker(), LeftButtonDown(), LeftButtonUp(), Move(), PerformDuplication(), RightButtonDown(), UpdateDropTarget(), and UpdateStatusBar().
|
protected |
Definition at line 55 of file C4EditCursor.h.
Referenced by ApplyToolLine(), ApplyToolRect(), Default(), Draw(), DrawObject(), FrameSelection(), LeftButtonDown(), and Move().
|
protected |
Definition at line 55 of file C4EditCursor.h.
Referenced by ApplyCreateObject(), ApplyToolBrush(), ApplyToolFill(), ApplyToolLine(), ApplyToolPicker(), ApplyToolRect(), Default(), DoContextMenu(), Draw(), DrawObject(), FrameSelection(), IsHoveringTransformMarker(), LeftButtonDown(), LeftButtonUp(), Move(), PerformDuplication(), RightButtonDown(), UpdateDropTarget(), and UpdateStatusBar().
|
protected |
Definition at line 55 of file C4EditCursor.h.
Referenced by ApplyToolFill(), ApplyToolLine(), ApplyToolRect(), Default(), Draw(), DrawObject(), FrameSelection(), LeftButtonDown(), and Move().
|
protected |
Definition at line 55 of file C4EditCursor.h.
Referenced by IsHoveringTransformMarker(), LeftButtonDown(), Move(), and PerformDuplication().