summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/vulkan/vulkan_context.cpp8
-rw-r--r--scene/gui/file_dialog.cpp2
2 files changed, 7 insertions, 3 deletions
diff --git a/drivers/vulkan/vulkan_context.cpp b/drivers/vulkan/vulkan_context.cpp
index 3feed2b109..7c52447e44 100644
--- a/drivers/vulkan/vulkan_context.cpp
+++ b/drivers/vulkan/vulkan_context.cpp
@@ -1818,7 +1818,7 @@ Error VulkanContext::_update_swap_chain(Window *window) {
if (window->width == 0 || window->height == 0) {
free(presentModes);
// Likely window minimized, no swapchain created.
- return OK;
+ return ERR_SKIP;
}
// The FIFO present mode is guaranteed by the spec to be supported
// and to have no tearing. It's a great default present mode to use.
@@ -2275,8 +2275,10 @@ Error VulkanContext::prepare_buffers() {
// Swapchain is not as optimal as it could be, but the platform's
// presentation engine will still present the image correctly.
print_verbose("Vulkan: Early suboptimal swapchain, recreating.");
- _update_swap_chain(w);
- break;
+ Error swap_chain_err = _update_swap_chain(w);
+ if (swap_chain_err == ERR_SKIP) {
+ break;
+ }
} else if (err != VK_SUCCESS) {
ERR_BREAK_MSG(err != VK_SUCCESS, "Vulkan: Did not create swapchain successfully. Error code: " + String(string_VkResult(err)));
} else {
diff --git a/scene/gui/file_dialog.cpp b/scene/gui/file_dialog.cpp
index e1309020a7..f7507640c8 100644
--- a/scene/gui/file_dialog.cpp
+++ b/scene/gui/file_dialog.cpp
@@ -833,6 +833,8 @@ void FileDialog::set_file_mode(FileMode p_mode) {
} else {
tree->set_select_mode(Tree::SELECT_SINGLE);
}
+
+ get_ok_button()->set_disabled(_is_open_should_be_disabled());
}
FileDialog::FileMode FileDialog::get_file_mode() const {