[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [60293] trunk/blender: style cleanup: whitespace & odd indentation
Campbell Barton
ideasman42 at gmail.com
Sat Sep 21 12:46:59 CEST 2013
Revision: 60293
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=60293
Author: campbellbarton
Date: 2013-09-21 10:46:58 +0000 (Sat, 21 Sep 2013)
Log Message:
-----------
style cleanup: whitespace & odd indentation
Modified Paths:
--------------
trunk/blender/intern/ghost/intern/GHOST_DisplayManagerCocoa.mm
trunk/blender/intern/ghost/intern/GHOST_SystemCocoa.mm
trunk/blender/intern/ghost/intern/GHOST_SystemWin32.cpp
trunk/blender/intern/ghost/intern/GHOST_WindowWin32.cpp
trunk/blender/intern/locale/boost_locale_wrapper.cpp
trunk/blender/source/blender/blenloader/intern/writefile.c
trunk/blender/source/blender/collada/DocumentImporter.cpp
trunk/blender/source/blender/collada/MeshImporter.cpp
trunk/blender/source/blender/freestyle/intern/stroke/StrokeRep.cpp
trunk/blender/source/blender/quicktime/apple/qtkit_export.m
trunk/blender/source/blender/quicktime/apple/qtkit_import.m
trunk/blender/source/blender/render/intern/include/texture.h
trunk/blender/source/blender/render/intern/source/rayshade.c
Modified: trunk/blender/intern/ghost/intern/GHOST_DisplayManagerCocoa.mm
===================================================================
--- trunk/blender/intern/ghost/intern/GHOST_DisplayManagerCocoa.mm 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/intern/ghost/intern/GHOST_DisplayManagerCocoa.mm 2013-09-21 10:46:58 UTC (rev 60293)
@@ -74,7 +74,7 @@
else
askedDisplay = [[NSScreen screens] objectAtIndex:display];
- if(askedDisplay == nil) {
+ if (askedDisplay == nil) {
[pool drain];
return GHOST_kFailure;
}
@@ -109,7 +109,7 @@
else
askedDisplay = [[NSScreen screens] objectAtIndex:display];
- if(askedDisplay == nil) {
+ if (askedDisplay == nil) {
[pool drain];
return GHOST_kFailure;
}
Modified: trunk/blender/intern/ghost/intern/GHOST_SystemCocoa.mm
===================================================================
--- trunk/blender/intern/ghost/intern/GHOST_SystemCocoa.mm 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/intern/ghost/intern/GHOST_SystemCocoa.mm 2013-09-21 10:46:58 UTC (rev 60293)
@@ -1541,8 +1541,8 @@
window->clientToScreenIntern(x_warp+x_accum, y_warp+y_accum, x, y);
pushEvent(new GHOST_EventCursor([event timestamp] * 1000, GHOST_kEventCursorMove, window, x, y));
+ break;
}
- break;
case GHOST_kGrabWrap: //Wrap cursor at area/window boundaries
{
NSPoint mousePos = [cocoawindow mouseLocationOutsideOfEventStream];
@@ -1552,7 +1552,7 @@
GHOST_Rect bounds, windowBounds, correctedBounds;
/* fallback to window bounds */
- if(window->getCursorGrabBounds(bounds)==GHOST_kFailure)
+ if (window->getCursorGrabBounds(bounds) == GHOST_kFailure)
window->getClientBounds(bounds);
//Switch back to Cocoa coordinates orientation (y=0 at botton,the same as blender internal btw!), and to client coordinates
@@ -1586,8 +1586,8 @@
window->getCursorGrabInitPos(x_cur, y_cur);
window->clientToScreenIntern(x_cur + x_accum, y_cur + y_accum, x, y);
pushEvent(new GHOST_EventCursor([event timestamp] * 1000, GHOST_kEventCursorMove, window, x, y));
+ break;
}
- break;
default:
{
//Normal cursor operation: send mouse position in window
@@ -1599,8 +1599,8 @@
m_cursorDelta_x=0;
m_cursorDelta_y=0; //Mouse motion occurred between two cursor warps, so we can reset the delta counter
+ break;
}
- break;
}
}
break;
@@ -1854,7 +1854,7 @@
[pool drain];
- if(temp_buff) {
+ if (temp_buff) {
return temp_buff;
}
else {
@@ -1866,7 +1866,7 @@
{
NSString *textToCopy;
- if(selection) {return;} // for copying the selection, used on X11
+ if (selection) return; // for copying the selection, used on X11
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
Modified: trunk/blender/intern/ghost/intern/GHOST_SystemWin32.cpp
===================================================================
--- trunk/blender/intern/ghost/intern/GHOST_SystemWin32.cpp 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/intern/ghost/intern/GHOST_SystemWin32.cpp 2013-09-21 10:46:58 UTC (rev 60293)
@@ -599,17 +599,19 @@
case VK_GR_LESS: key = GHOST_kKeyGrLess; break;
case VK_SHIFT:
- /* Check single shift presses */
- if (scanCode == 0x36) {
- key = GHOST_kKeyRightShift;
- } else if (scanCode == 0x2a) {
- key = GHOST_kKeyLeftShift;
- } else {
- /* Must be a combination SHIFT (Left or Right) + a Key
- * Ignore this as the next message will contain
- * the desired "Key" */
- key = GHOST_kKeyUnknown;
- }
+ /* Check single shift presses */
+ if (scanCode == 0x36) {
+ key = GHOST_kKeyRightShift;
+ }
+ else if (scanCode == 0x2a) {
+ key = GHOST_kKeyLeftShift;
+ }
+ else {
+ /* Must be a combination SHIFT (Left or Right) + a Key
+ * Ignore this as the next message will contain
+ * the desired "Key" */
+ key = GHOST_kKeyUnknown;
+ }
break;
case VK_CONTROL:
key = (extend) ? GHOST_kKeyRightControl : GHOST_kKeyLeftControl;
@@ -1162,7 +1164,7 @@
* message without calling DefWindowProc.
*/
/* we get first WM_SIZE before we fully init. So, do not dispatch before we continiously resizng */
- if(window->m_inLiveResize) {
+ if (window->m_inLiveResize) {
system->pushEvent(processWindowEvent(GHOST_kEventWindowSize, window));
system->dispatchEvents();
}
Modified: trunk/blender/intern/ghost/intern/GHOST_WindowWin32.cpp
===================================================================
--- trunk/blender/intern/ghost/intern/GHOST_WindowWin32.cpp 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/intern/ghost/intern/GHOST_WindowWin32.cpp 2013-09-21 10:46:58 UTC (rev 60293)
@@ -179,12 +179,12 @@
RECT rect, desktop;
int wintype = WS_OVERLAPPEDWINDOW;
- if (m_parentWindowHwnd != 0)
- {
+ if (m_parentWindowHwnd != 0) {
wintype = WS_CHILD;
/* check against parent window if given */
GetWindowRect((HWND)m_parentWindowHwnd, &rect);
- } else {
+ }
+ else {
int framex = GetSystemMetrics(SM_CXSIZEFRAME);
int framey = GetSystemMetrics(SM_CYSIZEFRAME);
int caption = GetSystemMetrics(SM_CYCAPTION);
@@ -203,10 +203,10 @@
desktop.bottom = GetSystemMetrics(SM_CYVIRTUALSCREEN);
/* virtual screen (desktop) bound checks */
- if(rect.left < desktop.left) rect.left = desktop.left;
- if(rect.top < desktop.top) rect.top = desktop.top;
- if(rect.bottom > desktop.bottom) rect.bottom = desktop.bottom;
- if(rect.right > desktop.right) rect.right = desktop.right;
+ if (rect.left < desktop.left) rect.left = desktop.left;
+ if (rect.top < desktop.top) rect.top = desktop.top;
+ if (rect.bottom > desktop.bottom) rect.bottom = desktop.bottom;
+ if (rect.right > desktop.right) rect.right = desktop.right;
/* dimension vars to use in window creation */
left = rect.left;
Modified: trunk/blender/intern/locale/boost_locale_wrapper.cpp
===================================================================
--- trunk/blender/intern/locale/boost_locale_wrapper.cpp 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/intern/locale/boost_locale_wrapper.cpp 2013-09-21 10:46:58 UTC (rev 60293)
@@ -109,7 +109,7 @@
std::locale l;
char_message_facet const &facet = std::use_facet<char_message_facet>(l);
char const *r = facet.get(0, msgctxt, msgid);
- if(r)
+ if (r)
return r;
return msgid;
}
Modified: trunk/blender/source/blender/blenloader/intern/writefile.c
===================================================================
--- trunk/blender/source/blender/blenloader/intern/writefile.c 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/source/blender/blenloader/intern/writefile.c 2013-09-21 10:46:58 UTC (rev 60293)
@@ -2449,7 +2449,8 @@
/* restore old treestore */
so->treestore = ts;
- } else {
+ }
+ else {
writestruct(wd, DATA, "SpaceOops", 1, so);
}
}
Modified: trunk/blender/source/blender/collada/DocumentImporter.cpp
===================================================================
--- trunk/blender/source/blender/collada/DocumentImporter.cpp 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/source/blender/collada/DocumentImporter.cpp 2013-09-21 10:46:58 UTC (rev 60293)
@@ -944,7 +944,7 @@
return true;
}
- if(et && et->isProfile("blender")) {
+ if (et && et->isProfile("blender")) {
et->setData("shiftx",&(cam->shiftx));
et->setData("shifty",&(cam->shifty));
et->setData("YF_dofdist",&(cam->YF_dofdist));
Modified: trunk/blender/source/blender/collada/MeshImporter.cpp
===================================================================
--- trunk/blender/source/blender/collada/MeshImporter.cpp 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/source/blender/collada/MeshImporter.cpp 2013-09-21 10:46:58 UTC (rev 60293)
@@ -665,9 +665,10 @@
v[0] = (*values)[i++];
v[1] = (*values)[i++];
- if(stride>=3) {
+ if (stride>=3) {
v[2] = (*values)[i];
- } else {
+ }
+ else {
v[2] = 0.0f;
}
@@ -680,9 +681,10 @@
v[0] = (float)(*values)[i++];
v[1] = (float)(*values)[i++];
- if(stride>=3) {
+ if (stride >= 3) {
v[2] = (float)(*values)[i];
- } else {
+ }
+ else {
v[2] = 0.0f;
}
}
Modified: trunk/blender/source/blender/freestyle/intern/stroke/StrokeRep.cpp
===================================================================
--- trunk/blender/source/blender/freestyle/intern/stroke/StrokeRep.cpp 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/source/blender/freestyle/intern/stroke/StrokeRep.cpp 2013-09-21 10:46:58 UTC (rev 60293)
@@ -149,7 +149,8 @@
if (dp < 0)
userDir = userDir * (-1.0f);
stripDir = userDir;
- } else {
+ }
+ else {
++orientationErrors;
}
}
@@ -207,7 +208,8 @@
if (dp < 0)
userDir = userDir * (-1.0f);
stripDir = userDir;
- } else {
+ }
+ else {
++orientationErrors;
}
}
@@ -226,7 +228,8 @@
if (dp < 0)
userDir = userDir * (-1.0f);
stripDirPrev = userDir;
- } else {
+ }
+ else {
++orientationErrors;
}
}
@@ -302,7 +305,8 @@
if (dp < 0)
userDir = userDir * (-1.0f);
stripDirLast = userDir;
- } else {
+ }
+ else {
++orientationErrors;
}
}
Modified: trunk/blender/source/blender/quicktime/apple/qtkit_export.m
===================================================================
--- trunk/blender/source/blender/quicktime/apple/qtkit_export.m 2013-09-21 08:50:19 UTC (rev 60292)
+++ trunk/blender/source/blender/quicktime/apple/qtkit_export.m 2013-09-21 10:46:58 UTC (rev 60293)
@@ -317,7 +317,7 @@
int success = 1;
OSStatus err = noErr;
- if(qtexport == NULL) qtexport = MEM_callocN(sizeof(QuicktimeExport), "QuicktimeExport");
+ if (qtexport == NULL) qtexport = MEM_callocN(sizeof(QuicktimeExport), "QuicktimeExport");
[QTMovie enterQTKitOnThread];
@@ -476,7 +476,7 @@
err = AudioFileCreateWithURL(outputFileURL, audioFileType, &qtexport->audioOutputFormat, kAudioFileFlags_EraseFile, &qtexport->audioFile);
CFRelease(outputFileURL);
- if(err)
+ if (err)
BKE_report(reports, RPT_ERROR, "\nQuicktime: unable to create temporary audio file. Format error ?");
else {
err = AudioConverterNew(&qtexport->audioInputFormat, &qtexport->audioOutputFormat, &qtexport->audioConverter);
@@ -542,7 +542,7 @@
else
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list