diff --git a/UI/DisplayLayoutScreen.cpp b/UI/DisplayLayoutScreen.cpp index 074c0c8454..432e3b5eaa 100644 --- a/UI/DisplayLayoutScreen.cpp +++ b/UI/DisplayLayoutScreen.cpp @@ -329,6 +329,14 @@ void DisplayLayoutScreen::CreateViews() { }); } + auto removeButton = shaderRow->Add(new Choice(ImageID("I_TRASHCAN"), new LinearLayoutParams(0.0f))); + removeButton->OnClick.Add([=](EventParams &e) -> UI::EventReturn { + g_Config.vPostShaderNames.erase(g_Config.vPostShaderNames.begin() + i); + NativeMessageReceived("gpu_configChanged", ""); + RecreateViews(); + return UI::EVENT_DONE; + }); + auto moreButton = shaderRow->Add(new Choice(ImageID("I_THREE_DOTS"), new LinearLayoutParams(0.0f))); moreButton->OnClick.Add([=](EventParams &e) -> UI::EventReturn { PopupContextMenuScreen *contextMenu = new UI::PopupContextMenuScreen(postShaderContextMenu, ARRAY_SIZE(postShaderContextMenu), di.get(), moreButton);