Merge branch 'master' into jgrpp
# Conflicts: # src/blitter/32bpp_anim.cpp # src/blitter/8bpp_optimized.cpp # src/gfx.cpp # src/gfx_func.h # src/gfxinit.cpp # src/network/core/os_abstraction.cpp # src/spritecache.cpp
This commit is contained in:
		| @@ -665,7 +665,7 @@ void VideoDriver_CocoaQuartz::AllocateBackingStore(bool) | ||||
| 		kCGImageAlphaNoneSkipFirst | kCGBitmapByteOrder32Host | ||||
| 	); | ||||
|  | ||||
| 	assert(this->cgcontext != NULL); | ||||
| 	assert(this->cgcontext != nullptr); | ||||
| 	CGContextSetShouldAntialias(this->cgcontext, FALSE); | ||||
| 	CGContextSetAllowsAntialiasing(this->cgcontext, FALSE); | ||||
| 	CGContextSetInterpolationQuality(this->cgcontext, kCGInterpolationNone); | ||||
|   | ||||
| @@ -932,16 +932,16 @@ void CocoaDialog(const char *title, const char *message, const char *buttonLabel | ||||
|  | ||||
| 	NSString *s = [ aString isKindOfClass:[ NSAttributedString class ] ] ? [ aString string ] : (NSString *)aString; | ||||
|  | ||||
| 	const char *insert_point = NULL; | ||||
| 	const char *replace_range = NULL; | ||||
| 	const char *insert_point = nullptr; | ||||
| 	const char *replace_range = nullptr; | ||||
| 	if (replacementRange.location != NSNotFound) { | ||||
| 		/* Calculate the part to be replaced. */ | ||||
| 		insert_point = Utf8AdvanceByUtf16Units(_focused_window->GetFocusedTextbuf()->GetText(), replacementRange.location); | ||||
| 		replace_range = Utf8AdvanceByUtf16Units(insert_point, replacementRange.length); | ||||
| 	} | ||||
|  | ||||
| 	HandleTextInput(NULL, true); | ||||
| 	HandleTextInput([ s UTF8String ], false, NULL, insert_point, replace_range); | ||||
| 	HandleTextInput(nullptr, true); | ||||
| 	HandleTextInput([ s UTF8String ], false, nullptr, insert_point, replace_range); | ||||
| } | ||||
|  | ||||
| /** Insert the given text at the caret. */ | ||||
| @@ -958,9 +958,9 @@ void CocoaDialog(const char *title, const char *message, const char *buttonLabel | ||||
| 	NSString *s = [ aString isKindOfClass:[ NSAttributedString class ] ] ? [ aString string ] : (NSString *)aString; | ||||
|  | ||||
| 	const char *utf8 = [ s UTF8String ]; | ||||
| 	if (utf8 != NULL) { | ||||
| 		const char *insert_point = NULL; | ||||
| 		const char *replace_range = NULL; | ||||
| 	if (utf8 != nullptr) { | ||||
| 		const char *insert_point = nullptr; | ||||
| 		const char *replace_range = nullptr; | ||||
| 		if (replacementRange.location != NSNotFound) { | ||||
| 			/* Calculate the part to be replaced. */ | ||||
| 			NSRange marked = [ self markedRange ]; | ||||
|   | ||||
| @@ -277,7 +277,7 @@ static bool DrawIMECompositionString() | ||||
| static void SetCompositionPos(HWND hwnd) | ||||
| { | ||||
| 	HIMC hIMC = ImmGetContext(hwnd); | ||||
| 	if (hIMC != NULL) { | ||||
| 	if (hIMC != nullptr) { | ||||
| 		COMPOSITIONFORM cf; | ||||
| 		cf.dwStyle = CFS_POINT; | ||||
|  | ||||
| @@ -299,7 +299,7 @@ static void SetCompositionPos(HWND hwnd) | ||||
| static void SetCandidatePos(HWND hwnd) | ||||
| { | ||||
| 	HIMC hIMC = ImmGetContext(hwnd); | ||||
| 	if (hIMC != NULL) { | ||||
| 	if (hIMC != nullptr) { | ||||
| 		CANDIDATEFORM cf; | ||||
| 		cf.dwIndex = 0; | ||||
| 		cf.dwStyle = CFS_EXCLUDE; | ||||
| @@ -334,7 +334,7 @@ static LRESULT HandleIMEComposition(HWND hwnd, WPARAM wParam, LPARAM lParam) | ||||
| { | ||||
| 	HIMC hIMC = ImmGetContext(hwnd); | ||||
|  | ||||
| 	if (hIMC != NULL) { | ||||
| 	if (hIMC != nullptr) { | ||||
| 		if (lParam & GCS_RESULTSTR) { | ||||
| 			/* Read result string from the IME. */ | ||||
| 			LONG len = ImmGetCompositionString(hIMC, GCS_RESULTSTR, nullptr, 0); // Length is always in bytes, even in UNICODE build. | ||||
| @@ -393,7 +393,7 @@ static LRESULT HandleIMEComposition(HWND hwnd, WPARAM wParam, LPARAM lParam) | ||||
| static void CancelIMEComposition(HWND hwnd) | ||||
| { | ||||
| 	HIMC hIMC = ImmGetContext(hwnd); | ||||
| 	if (hIMC != NULL) ImmNotifyIME(hIMC, NI_COMPOSITIONSTR, CPS_CANCEL, 0); | ||||
| 	if (hIMC != nullptr) ImmNotifyIME(hIMC, NI_COMPOSITIONSTR, CPS_CANCEL, 0); | ||||
| 	ImmReleaseContext(hwnd, hIMC); | ||||
| 	/* Clear any marked string from the current edit box. */ | ||||
| 	HandleTextInput(nullptr, true); | ||||
| @@ -690,7 +690,7 @@ LRESULT CALLBACK WndProcGdi(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) | ||||
| 			/* Resize the window to match the new DPI setting. */ | ||||
| 			RECT *prcNewWindow = (RECT *)lParam; | ||||
| 			SetWindowPos(hwnd, | ||||
| 				NULL, | ||||
| 				nullptr, | ||||
| 				prcNewWindow->left, | ||||
| 				prcNewWindow->top, | ||||
| 				prcNewWindow->right - prcNewWindow->left, | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Jonathan G Rennison
					Jonathan G Rennison