MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / OnObjbutton

Method OnObjbutton

editor/MainFrm.cpp:3219–3236  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3217 dlg.DoModal();
3218}
3219
3220void CMainFrame::OnObjbutton() {
3221 if (m_ObjModeless) {
3222 RECT rect;
3223 m_ObjModeless->GetWindowRect(&rect);
3224 GetActiveFrame()->ScreenToClient(&rect);
3225 D3EditState.objmodeless_x = rect.left;
3226 D3EditState.objmodeless_y = rect.top;
3227 D3EditState.objmodeless_on = false;
3228 m_ObjModeless->DestroyWindow();
3229 m_ObjModeless = NULL;
3230 } else {
3231 m_ObjModeless = new CObjectListModeless(this);
3232 m_ObjModeless->Create();
3233 m_ObjModeless->SetWindowPos(this, D3EditState.objmodeless_x, D3EditState.objmodeless_y, -1, -1, SWP_NOSIZE);
3234 m_ObjModeless->ShowWindow(SW_SHOW);
3235 D3EditState.objmodeless_on = true;
3236 }
3237}
3238
3239void CMainFrame::OnUpdateObjbutton(CCmdUI *pCmdUI) {

Callers

nothing calls this directly

Calls 2

DestroyWindowMethod · 0.45
CreateMethod · 0.45

Tested by

no test coverage detected