diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-01-23 14:42:29 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-01-23 14:42:29 +0300 |
commit | d75216ba1c0fbaae1f2fe20741f23b9c35816eca (patch) | |
tree | a3fe06755315972a3101cd75efaafdcb5c4d334b /source | |
parent | 552b36733bb2015aa64933bf3c57f1ad90c87b5a (diff) |
- fix problem with cmake, windows 'RelWithDebInfo' target, was giving error: "ImportError: No module named _socket" because of copying wrong files over.
- move test -> tests, this name is used elsewhere in lib/tests.
- change interface code not to loop on a float value (clang warning), harmless, but with extreme cases an eternal loop would still be possible though unlikely.
Diffstat (limited to 'source')
-rw-r--r-- | source/CMakeLists.txt | 2 | ||||
-rw-r--r-- | source/blender/editors/interface/interface_draw.c | 8 | ||||
-rw-r--r-- | source/creator/CMakeLists.txt | 3 | ||||
-rw-r--r-- | source/tests/CMakeLists.txt (renamed from source/test/CMakeLists.txt) | 2 | ||||
-rw-r--r-- | source/tests/bl_test.py (renamed from source/test/bl_test.py) | 0 | ||||
-rw-r--r-- | source/tests/pep8.py (renamed from source/test/pep8.py) | 0 | ||||
-rw-r--r-- | source/tests/rna_array.py (renamed from source/test/rna_array.py) | 0 | ||||
-rw-r--r-- | source/tests/rna_info_dump.py (renamed from source/test/rna_info_dump.py) | 0 |
8 files changed, 9 insertions, 6 deletions
diff --git a/source/CMakeLists.txt b/source/CMakeLists.txt index 46e1405df84..1929f19f38f 100644 --- a/source/CMakeLists.txt +++ b/source/CMakeLists.txt @@ -35,4 +35,4 @@ if(WINDOWS) add_subdirectory(icons) endif() -add_subdirectory(test) +add_subdirectory(tests) diff --git a/source/blender/editors/interface/interface_draw.c b/source/blender/editors/interface/interface_draw.c index cf6b0652b22..4ea0c01d15c 100644 --- a/source/blender/editors/interface/interface_draw.c +++ b/source/blender/editors/interface/interface_draw.c @@ -1576,6 +1576,7 @@ void uiDrawBoxShadow(unsigned char alpha, float minx, float miny, float maxx, fl void ui_dropshadow(rctf *rct, float radius, float aspect, int select) { + int i; float rad; float a; char alpha= 2; @@ -1586,9 +1587,10 @@ void ui_dropshadow(rctf *rct, float radius, float aspect, int select) rad= (rct->ymax-rct->ymin-10.0f)/2.0f; else rad= radius; - - if(select) a= 12.0f*aspect; else a= 12.0f*aspect; - for(; a>0.0f; a-=aspect) { + + i= 12; + if(select) a= i*aspect; else a= i*aspect; + for(; i--; a-=aspect) { /* alpha ranges from 2 to 20 or so */ glColor4ub(0, 0, 0, alpha); alpha+= 2; diff --git a/source/creator/CMakeLists.txt b/source/creator/CMakeLists.txt index 8db4954d876..2c89c3b6b9f 100644 --- a/source/creator/CMakeLists.txt +++ b/source/creator/CMakeLists.txt @@ -305,6 +305,7 @@ if(WITH_INSTALL) endif() if(WITH_PYTHON) + # note, as far as python is concerned 'RelWithDebInfo' is not debug since its without debug flags. if(NOT CMAKE_BUILD_TYPE) # hack: with multi-configuration generator this is "", so for now copy both python31.dll/zip and python31_d.dll/zip add_custom_command(TARGET blender POST_BUILD @@ -322,7 +323,7 @@ if(WITH_INSTALL) COMMAND if \"$(ConfigurationName)\" == \"MinSizeRel\" xcopy /E /Y \"${LIBDIR}\\release\\python31\\*.*\" \"${TARGETDIR}\\${BLENDER_VERSION}\\python\\lib\\\" ) else() - if(CMAKE_BUILD_TYPE STREQUAL Debug OR CMAKE_BUILD_TYPE STREQUAL RelWithDebInfo) + if(CMAKE_BUILD_TYPE STREQUAL Debug) add_custom_command(TARGET blender POST_BUILD MAIN_DEPENDENCY blender diff --git a/source/test/CMakeLists.txt b/source/tests/CMakeLists.txt index b9c0d73fa6c..f0771f5fa0f 100644 --- a/source/test/CMakeLists.txt +++ b/source/tests/CMakeLists.txt @@ -81,7 +81,7 @@ add_test(export_obj_all_objects ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS --run={'FINISHED'}&bpy.ops.export_scene.obj\(filepath='${TEST_OUT_DIR}/export_obj_all_objects.obj',use_selection=False,use_nurbs=True\) --md5_source=${TEST_OUT_DIR}/export_obj_all_objects.obj --md5_source=${TEST_OUT_DIR}/export_obj_all_objects.mtl - --md5=c835899ca8993495af8a13c2f229629b --md5_method=FILE + --md5=6e033a6a9c923d7aa3613b36e373f55b --md5_method=FILE ) diff --git a/source/test/bl_test.py b/source/tests/bl_test.py index 86c5cf81e79..86c5cf81e79 100644 --- a/source/test/bl_test.py +++ b/source/tests/bl_test.py diff --git a/source/test/pep8.py b/source/tests/pep8.py index 3ccd7dd79b6..3ccd7dd79b6 100644 --- a/source/test/pep8.py +++ b/source/tests/pep8.py diff --git a/source/test/rna_array.py b/source/tests/rna_array.py index 06b4735cc0d..06b4735cc0d 100644 --- a/source/test/rna_array.py +++ b/source/tests/rna_array.py diff --git a/source/test/rna_info_dump.py b/source/tests/rna_info_dump.py index 62c1248d733..62c1248d733 100644 --- a/source/test/rna_info_dump.py +++ b/source/tests/rna_info_dump.py |