update code style

This commit is contained in:
vcaesar 2018-02-11 19:03:35 +08:00
parent 35f5016d33
commit 15233120e0
4 changed files with 37 additions and 41 deletions

View File

@ -8,8 +8,7 @@
// #include "../base/xdisplay_c.h"
#endif
MMSize getMainDisplaySize(void)
{
MMSize getMainDisplaySize(void){
#if defined(IS_MACOSX)
CGDirectDisplayID displayID = CGMainDisplayID();
return MMSizeMake(CGDisplayPixelsWide(displayID),
@ -26,8 +25,7 @@ MMSize getMainDisplaySize(void)
#endif
}
bool pointVisibleOnMainDisplay(MMPoint point)
{
bool pointVisibleOnMainDisplay(MMPoint point){
MMSize displaySize = getMainDisplaySize();
return point.x < displaySize.width && point.y < displaySize.height;
}

View File

@ -17,8 +17,7 @@
#include <string.h>
#endif
MMBitmapRef copyMMBitmapFromDisplayInRect(MMRect rect)
{
MMBitmapRef copyMMBitmapFromDisplayInRect(MMRect rect){
#if defined(IS_MACOSX)
MMBitmapRef bitmap = NULL;

View File

@ -609,8 +609,7 @@ void SetActive(const MData win){
if (WM_ACTIVE != None){
// Retrieve the screen number
XWindowAttributes attr = { 0 };
XGetWindowAttributes (rDisplay,
win.XWin, &attr);
XGetWindowAttributes(rDisplay, win.XWin, &attr);
int s = XScreenNumberOfScreen(attr.screen);
// Prepare an event