From 3bfd7a799ba0cbd0aa918dbc2f50ea592842b74a Mon Sep 17 00:00:00 2001 From: Luke Ceddia Date: Tue, 18 Aug 2015 18:55:08 +1000 Subject: [PATCH] Fixed MessageBox implementation on Linux and presumably Mac to actually do something. --- internal/c/libqb.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/c/libqb.cpp b/internal/c/libqb.cpp index b4fd2bb48..b26bae781 100644 --- a/internal/c/libqb.cpp +++ b/internal/c/libqb.cpp @@ -3608,7 +3608,7 @@ int MessageBox(int ignore,char* message, char* header, int type ) CFStringRef header_ref = CFStringCreateWithCString( NULL, header, kCFStringEncodingASCII ); CFStringRef message_ref = CFStringCreateWithCString( NULL, message, kCFStringEncodingASCII ); CFOptionFlags result; - if (type|MB_SYSTEMMODAL) type-=MB_SYSTEMMODAL; + if (type&MB_SYSTEMMODAL) type-=MB_SYSTEMMODAL; if (type==MB_YESNO){ CFUserNotificationDisplayAlert( 0, // no timeout @@ -3653,7 +3653,7 @@ int MessageBox(int ignore,char* message, char* header, int type ) #else int MessageBox(int ignore,char* message,char* title,int type){ static qbs *s=NULL; if (!s) s=qbs_new(0,0); - if (type|MB_SYSTEMMODAL) type-=MB_SYSTEMMODAL; + if (type&MB_SYSTEMMODAL) type-=MB_SYSTEMMODAL; if (type==MB_YESNO){ qbs_set(s,qbs_new_txt("xmessage -center -title ")); qbs_set(s,qbs_add(s,qbs_new_txt("?"))); s->chr[s->len-1]=34;