mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
Make sure ctrl+shift+s works same as clicking UI
Do not overwrite the current map when saving as a new file closed #1972
This commit is contained in:
parent
baf10236d0
commit
7d87089acd
|
@ -5995,8 +5995,14 @@ void CEditor::Render()
|
|||
}
|
||||
}
|
||||
|
||||
// ctrl+shift+alt+s to save as
|
||||
if(Input()->KeyPress(KEY_S) && CtrlPressed && ShiftPressed && AltPressed)
|
||||
InvokeFileDialog(IStorage::TYPE_SAVE, FILETYPE_MAP, "Save map", "Save", "maps", "", CallbackSaveCopyMap, this);
|
||||
// ctrl+shift+s to save as
|
||||
else if(Input()->KeyPress(KEY_S) && CtrlPressed && ShiftPressed)
|
||||
InvokeFileDialog(IStorage::TYPE_SAVE, FILETYPE_MAP, "Save map", "Save", "maps", "", CallbackSaveMap, this);
|
||||
// ctrl+s to save
|
||||
if(Input()->KeyPress(KEY_S) && CtrlPressed)
|
||||
else if(Input()->KeyPress(KEY_S) && CtrlPressed)
|
||||
{
|
||||
if(m_aFileName[0] && m_ValidSaveFilename)
|
||||
{
|
||||
|
@ -6009,14 +6015,6 @@ void CEditor::Render()
|
|||
else
|
||||
InvokeFileDialog(IStorage::TYPE_SAVE, FILETYPE_MAP, "Save map", "Save", "maps", "", CallbackSaveMap, this);
|
||||
}
|
||||
|
||||
// ctrl+shift+s to save as
|
||||
if(Input()->KeyPress(KEY_S) && CtrlPressed && ShiftPressed)
|
||||
InvokeFileDialog(IStorage::TYPE_SAVE, FILETYPE_MAP, "Save map", "Save", "maps", "", CallbackSaveMap, this);
|
||||
|
||||
// ctrl+shift+alt+s to save as
|
||||
if(Input()->KeyPress(KEY_S) && CtrlPressed && ShiftPressed && AltPressed)
|
||||
InvokeFileDialog(IStorage::TYPE_SAVE, FILETYPE_MAP, "Save map", "Save", "maps", "", CallbackSaveCopyMap, this);
|
||||
}
|
||||
|
||||
if(m_GuiActive)
|
||||
|
|
Loading…
Reference in a new issue