mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Update popups.cpp
This commit is contained in:
parent
544f564044
commit
249c8572ae
|
@ -1632,7 +1632,7 @@ CUi::EPopupMenuFunctionResult CEditor::PopupImage(void *pContext, CUIRect View,
|
||||||
CEditor *pEditor = static_cast<CEditor *>(pContext);
|
CEditor *pEditor = static_cast<CEditor *>(pContext);
|
||||||
|
|
||||||
static int s_ExternalButton = 0;
|
static int s_ExternalButton = 0;
|
||||||
static int s_ReloadButton = 0;
|
static int s_ReimportButton = 0;
|
||||||
static int s_ReplaceButton = 0;
|
static int s_ReplaceButton = 0;
|
||||||
static int s_RemoveButton = 0;
|
static int s_RemoveButton = 0;
|
||||||
static int s_ExportButton = 0;
|
static int s_ExportButton = 0;
|
||||||
|
@ -1686,7 +1686,7 @@ CUi::EPopupMenuFunctionResult CEditor::PopupImage(void *pContext, CUIRect View,
|
||||||
static CUi::SSelectionPopupContext s_SelectionPopupContext;
|
static CUi::SSelectionPopupContext s_SelectionPopupContext;
|
||||||
static CScrollRegion s_SelectionPopupScrollRegion;
|
static CScrollRegion s_SelectionPopupScrollRegion;
|
||||||
s_SelectionPopupContext.m_pScrollRegion = &s_SelectionPopupScrollRegion;
|
s_SelectionPopupContext.m_pScrollRegion = &s_SelectionPopupScrollRegion;
|
||||||
if(pEditor->DoButton_MenuItem(&s_ReloadButton, "Reload", 0, &Slot, 0, "Reloads the image from the mapres folder"))
|
if(pEditor->DoButton_MenuItem(&s_ReimportButton, "Re-import", 0, &Slot, 0, "Re-imports the image from the mapres folder"))
|
||||||
{
|
{
|
||||||
char aFilename[IO_MAX_PATH_LENGTH];
|
char aFilename[IO_MAX_PATH_LENGTH];
|
||||||
str_format(aFilename, sizeof(aFilename), "%s.png", pImg->m_aName);
|
str_format(aFilename, sizeof(aFilename), "%s.png", pImg->m_aName);
|
||||||
|
@ -1754,7 +1754,7 @@ CUi::EPopupMenuFunctionResult CEditor::PopupSound(void *pContext, CUIRect View,
|
||||||
{
|
{
|
||||||
CEditor *pEditor = static_cast<CEditor *>(pContext);
|
CEditor *pEditor = static_cast<CEditor *>(pContext);
|
||||||
|
|
||||||
static int s_ReloadButton = 0;
|
static int s_ReimportButton = 0;
|
||||||
static int s_ReplaceButton = 0;
|
static int s_ReplaceButton = 0;
|
||||||
static int s_RemoveButton = 0;
|
static int s_RemoveButton = 0;
|
||||||
static int s_ExportButton = 0;
|
static int s_ExportButton = 0;
|
||||||
|
@ -1785,7 +1785,7 @@ CUi::EPopupMenuFunctionResult CEditor::PopupSound(void *pContext, CUIRect View,
|
||||||
View.HSplitTop(5.0f, nullptr, &View);
|
View.HSplitTop(5.0f, nullptr, &View);
|
||||||
View.HSplitTop(RowHeight, &Slot, &View);
|
View.HSplitTop(RowHeight, &Slot, &View);
|
||||||
|
|
||||||
if(pEditor->DoButton_MenuItem(&s_ReloadButton, "Reload", 0, &Slot, 0, "Reloads the sound from the mapres folder"))
|
if(pEditor->DoButton_MenuItem(&s_ReimportButton, "Re-import", 0, &Slot, 0, "Re-imports the sound from the mapres folder"))
|
||||||
{
|
{
|
||||||
char aFilename[IO_MAX_PATH_LENGTH];
|
char aFilename[IO_MAX_PATH_LENGTH];
|
||||||
str_format(aFilename, sizeof(aFilename), "%s.opus", pSound->m_aName);
|
str_format(aFilename, sizeof(aFilename), "%s.opus", pSound->m_aName);
|
||||||
|
|
Loading…
Reference in a new issue