Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2016-06-10 00:45:39 +0300
committerCampbell Barton <ideasman42@gmail.com>2016-06-10 00:50:45 +0300
commita5788a9c477cdafbd2d3e31a458b6aaebb474efb (patch)
tree1edf7d787fb4298ae9d142e5f0fb8e8b25236d1d
parent8529b2f925c2a0f0cfa3ffe9218519b55223107e (diff)
Cleanup: brace-placement
-rw-r--r--intern/ghost/intern/GHOST_ContextGLX.cpp3
-rw-r--r--intern/ghost/intern/GHOST_ContextWGL.cpp4
-rw-r--r--intern/ghost/intern/GHOST_DropTargetWin32.cpp12
-rw-r--r--intern/ghost/intern/GHOST_EventManager.cpp12
-rw-r--r--intern/ghost/intern/GHOST_NDOFManager.cpp3
-rw-r--r--intern/ghost/intern/GHOST_SystemPathsWin32.cpp6
-rw-r--r--intern/ghost/intern/GHOST_SystemWin32.cpp3
-rw-r--r--intern/ghost/intern/GHOST_SystemX11.cpp6
8 files changed, 17 insertions, 32 deletions
diff --git a/intern/ghost/intern/GHOST_ContextGLX.cpp b/intern/ghost/intern/GHOST_ContextGLX.cpp
index 4b735bbd07c..d4f67da1242 100644
--- a/intern/ghost/intern/GHOST_ContextGLX.cpp
+++ b/intern/ghost/intern/GHOST_ContextGLX.cpp
@@ -287,8 +287,7 @@ const bool GLXEW_ARB_create_context_robustness =
attribs[i++] = 0;
/* Create a GL 3.x context */
- if (m_fbconfig)
- {
+ if (m_fbconfig) {
m_context = glXCreateContextAttribsARB(m_display, m_fbconfig, s_sharedContext, true, attribs);
}
else {
diff --git a/intern/ghost/intern/GHOST_ContextWGL.cpp b/intern/ghost/intern/GHOST_ContextWGL.cpp
index 75e2f94c3a3..eeb6a2469ee 100644
--- a/intern/ghost/intern/GHOST_ContextWGL.cpp
+++ b/intern/ghost/intern/GHOST_ContextWGL.cpp
@@ -63,7 +63,7 @@ static bool is_crappy_intel_card()
GHOST_ContextWGL::GHOST_ContextWGL(
bool stereoVisual,
- bool alphaBackground,
+ bool alphaBackground,
GHOST_TUns16 numOfAASamples,
HWND hWnd,
HDC hDC,
@@ -79,7 +79,7 @@ GHOST_ContextWGL::GHOST_ContextWGL(
m_contextMajorVersion(contextMajorVersion),
m_contextMinorVersion(contextMinorVersion),
m_contextFlags(contextFlags),
- m_alphaBackground(alphaBackground),
+ m_alphaBackground(alphaBackground),
m_contextResetNotificationStrategy(contextResetNotificationStrategy),
m_hGLRC(NULL)
#ifdef WITH_GLEW_MX
diff --git a/intern/ghost/intern/GHOST_DropTargetWin32.cpp b/intern/ghost/intern/GHOST_DropTargetWin32.cpp
index 96ff79aa65a..cbf37bf1b16 100644
--- a/intern/ghost/intern/GHOST_DropTargetWin32.cpp
+++ b/intern/ghost/intern/GHOST_DropTargetWin32.cpp
@@ -125,8 +125,7 @@ HRESULT __stdcall GHOST_DropTargetWin32::DragEnter(IDataObject *pDataObject, DWO
*/
HRESULT __stdcall GHOST_DropTargetWin32::DragOver(DWORD grfKeyState, POINTL pt, DWORD *pdwEffect)
{
- if (m_window->canAcceptDragOperation())
- {
+ if (m_window->canAcceptDragOperation()) {
*pdwEffect = allowedDropEffect(*pdwEffect);
}
else {
@@ -154,8 +153,7 @@ HRESULT __stdcall GHOST_DropTargetWin32::DragLeave(void)
HRESULT __stdcall GHOST_DropTargetWin32::Drop(IDataObject *pDataObject, DWORD grfKeyState, POINTL pt, DWORD *pdwEffect)
{
void *data = getGhostData(pDataObject);
- if (m_window->canAcceptDragOperation())
- {
+ if (m_window->canAcceptDragOperation()) {
*pdwEffect = allowedDropEffect(*pdwEffect);
}
@@ -189,15 +187,13 @@ GHOST_TDragnDropTypes GHOST_DropTargetWin32::getGhostType(IDataObject *pDataObje
* conversion, but we do the conversion ourself with WC_NO_BEST_FIT_CHARS.
*/
FORMATETC fmtetc = { CF_TEXT, 0, DVASPECT_CONTENT, -1, TYMED_HGLOBAL };
- if (pDataObject->QueryGetData(&fmtetc) == S_OK)
- {
+ if (pDataObject->QueryGetData(&fmtetc) == S_OK) {
return GHOST_kDragnDropTypeString;
}
// Filesnames
fmtetc.cfFormat = CF_HDROP;
- if (pDataObject->QueryGetData(&fmtetc) == S_OK)
- {
+ if (pDataObject->QueryGetData(&fmtetc) == S_OK) {
return GHOST_kDragnDropTypeFilenames;
}
diff --git a/intern/ghost/intern/GHOST_EventManager.cpp b/intern/ghost/intern/GHOST_EventManager.cpp
index bc531bd515b..0675ac734ed 100644
--- a/intern/ghost/intern/GHOST_EventManager.cpp
+++ b/intern/ghost/intern/GHOST_EventManager.cpp
@@ -167,11 +167,9 @@ void GHOST_EventManager::removeWindowEvents(GHOST_IWindow *window)
{
TEventStack::iterator iter;
iter = m_events.begin();
- while (iter != m_events.end())
- {
+ while (iter != m_events.end()) {
GHOST_IEvent *event = *iter;
- if (event->getWindow() == window)
- {
+ if (event->getWindow() == window) {
GHOST_PRINT("GHOST_EventManager::removeWindowEvents(): removing event\n");
/*
* Found an event for this window, remove it.
@@ -191,11 +189,9 @@ void GHOST_EventManager::removeTypeEvents(GHOST_TEventType type, GHOST_IWindow *
{
TEventStack::iterator iter;
iter = m_events.begin();
- while (iter != m_events.end())
- {
+ while (iter != m_events.end()) {
GHOST_IEvent *event = *iter;
- if ((event->getType() == type) && (!window || (event->getWindow() == window)))
- {
+ if ((event->getType() == type) && (!window || (event->getWindow() == window))) {
GHOST_PRINT("GHOST_EventManager::removeTypeEvents(): removing event\n");
/*
* Found an event of this type for the window, remove it.
diff --git a/intern/ghost/intern/GHOST_NDOFManager.cpp b/intern/ghost/intern/GHOST_NDOFManager.cpp
index f18b7911f45..c8e14ad357f 100644
--- a/intern/ghost/intern/GHOST_NDOFManager.cpp
+++ b/intern/ghost/intern/GHOST_NDOFManager.cpp
@@ -378,8 +378,7 @@ void GHOST_NDOFManager::updateButton(int button_number, bool press, GHOST_TUns64
NDOF_ButtonT button = (button_number < m_buttonCount) ? m_hidMap[button_number] : NDOF_BUTTON_NONE;
- switch (button)
- {
+ switch (button) {
case NDOF_BUTTON_NONE:
#ifdef DEBUG_NDOF_BUTTONS
printf("discarded\n");
diff --git a/intern/ghost/intern/GHOST_SystemPathsWin32.cpp b/intern/ghost/intern/GHOST_SystemPathsWin32.cpp
index 2bd380050f1..7d0ce5158fe 100644
--- a/intern/ghost/intern/GHOST_SystemPathsWin32.cpp
+++ b/intern/ghost/intern/GHOST_SystemPathsWin32.cpp
@@ -76,8 +76,7 @@ const GHOST_TUns8 *GHOST_SystemPathsWin32::getSystemDir(int, const char *version
HRESULT hResult = SHGetFolderPathW(NULL, CSIDL_COMMON_APPDATA, NULL, SHGFP_TYPE_CURRENT, knownpath_16);
- if (hResult == S_OK)
- {
+ if (hResult == S_OK) {
conv_utf_16_to_8(knownpath_16, knownpath, MAX_PATH * 3);
strcat(knownpath, "\\Blender Foundation\\Blender\\");
strcat(knownpath, versionstr);
@@ -94,8 +93,7 @@ const GHOST_TUns8 *GHOST_SystemPathsWin32::getUserDir(int, const char *versionst
HRESULT hResult = SHGetFolderPathW(NULL, CSIDL_APPDATA, NULL, SHGFP_TYPE_CURRENT, knownpath_16);
- if (hResult == S_OK)
- {
+ if (hResult == S_OK) {
conv_utf_16_to_8(knownpath_16, knownpath, MAX_PATH * 3);
strcat(knownpath, "\\Blender Foundation\\Blender\\");
strcat(knownpath, versionstr);
diff --git a/intern/ghost/intern/GHOST_SystemWin32.cpp b/intern/ghost/intern/GHOST_SystemWin32.cpp
index ed08ce02f47..1ce8002520f 100644
--- a/intern/ghost/intern/GHOST_SystemWin32.cpp
+++ b/intern/ghost/intern/GHOST_SystemWin32.cpp
@@ -1545,8 +1545,7 @@ static bool isStartedFromCommandPrompt()
int GHOST_SystemWin32::toggleConsole(int action)
{
- switch (action)
- {
+ switch (action) {
case 3: // startup: hide if not started from command prompt
{
if (isStartedFromCommandPrompt()) {
diff --git a/intern/ghost/intern/GHOST_SystemX11.cpp b/intern/ghost/intern/GHOST_SystemX11.cpp
index 25daa8ce2a7..aeda95d5d4d 100644
--- a/intern/ghost/intern/GHOST_SystemX11.cpp
+++ b/intern/ghost/intern/GHOST_SystemX11.cpp
@@ -420,8 +420,7 @@ static Bool init_timestamp_scanner(Display *, XEvent *event, XPointer arg)
{
init_timestamp_data *data =
reinterpret_cast<init_timestamp_data *>(arg);
- switch (event->type)
- {
+ switch (event->type) {
case ButtonPress:
case ButtonRelease:
data->timestamp = event->xbutton.time;
@@ -1964,8 +1963,7 @@ int GHOST_X11_ApplicationIOErrorHandler(Display * /*display*/)
static bool match_token(const char *haystack, const char *needle)
{
const char *p, *q;
- for (p = haystack; *p; )
- {
+ for (p = haystack; *p; ) {
while (*p && isspace(*p))
p++;
if (!*p)