This commit is contained in:
parent
c2f8fb3f82
commit
960db8d3e3
4 changed files with 4 additions and 6 deletions
|
|
@ -45,7 +45,6 @@ static void MWAPI tick(MwWidget handle, void* user_data, void* call_data) {
|
||||||
MwGetClipboard(handle, MwCLIPBOARD_MAIN);
|
MwGetClipboard(handle, MwCLIPBOARD_MAIN);
|
||||||
cur_text = text2;
|
cur_text = text2;
|
||||||
MwGetClipboard(handle, MwCLIPBOARD_PRIMARY);
|
MwGetClipboard(handle, MwCLIPBOARD_PRIMARY);
|
||||||
MwForceRender(window);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int main() {
|
int main() {
|
||||||
|
|
|
||||||
|
|
@ -44,11 +44,10 @@ int main() {
|
||||||
NULL);
|
NULL);
|
||||||
text_listbox = MwVaCreateWidget(MwListBoxClass, "label", box, 25, 150, 750, 700,
|
text_listbox = MwVaCreateWidget(MwListBoxClass, "label", box, 25, 150, 750, 700,
|
||||||
MwNtext, "",
|
MwNtext, "",
|
||||||
MwNacceptsDnD, 1,
|
|
||||||
NULL);
|
NULL);
|
||||||
|
|
||||||
MwAddUserHandler(window, MwNresizeHandler, resize, NULL);
|
MwAddUserHandler(window, MwNresizeHandler, resize, NULL);
|
||||||
MwAddUserHandler(window, MwNdragAndDropHandler, dnd, NULL);
|
MwAddUserHandler(instructions, MwNdragAndDropHandler, dnd, NULL);
|
||||||
|
|
||||||
resize(window, NULL, NULL);
|
resize(window, NULL, NULL);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -257,8 +257,8 @@ void vulkan_setup(MwWidget handle) {
|
||||||
swapchainCreateInfo.imageExtent = (VkExtent2D){.width = ow, .height = oh},
|
swapchainCreateInfo.imageExtent = (VkExtent2D){.width = ow, .height = oh},
|
||||||
swapchainCreateInfo.imageArrayLayers = 1,
|
swapchainCreateInfo.imageArrayLayers = 1,
|
||||||
swapchainCreateInfo.imageUsage = VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT |
|
swapchainCreateInfo.imageUsage = VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT |
|
||||||
VK_IMAGE_USAGE_TRANSFER_DST_BIT |
|
VK_IMAGE_USAGE_TRANSFER_DST_BIT |
|
||||||
VK_IMAGE_USAGE_SAMPLED_BIT;
|
VK_IMAGE_USAGE_SAMPLED_BIT;
|
||||||
// th is how we specify no transformation.
|
// th is how we specify no transformation.
|
||||||
swapchainCreateInfo.preTransform = VK_SURFACE_TRANSFORM_IDENTITY_BIT_KHR;
|
swapchainCreateInfo.preTransform = VK_SURFACE_TRANSFORM_IDENTITY_BIT_KHR;
|
||||||
swapchainCreateInfo.compositeAlpha = VK_COMPOSITE_ALPHA_OPAQUE_BIT_KHR;
|
swapchainCreateInfo.compositeAlpha = VK_COMPOSITE_ALPHA_OPAQUE_BIT_KHR;
|
||||||
|
|
|
||||||
|
|
@ -679,7 +679,7 @@ void MwSetInteger(MwWidget handle, const char* key, int n) {
|
||||||
if(h->lowlevel != NULL) MwLLSetDarkTheme(h->lowlevel, n);
|
if(h->lowlevel != NULL) MwLLSetDarkTheme(h->lowlevel, n);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(strcmp(key, MwNacceptsDnD) == 0) {
|
if(strcmp(key, MwNacceptsDnD) == 0 && n) {
|
||||||
if(handle->lowlevel != NULL) MwLLSetupDragAndDrop(handle->lowlevel);
|
if(handle->lowlevel != NULL) MwLLSetupDragAndDrop(handle->lowlevel);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue