style cleanup


git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53190 954f8c5b-7b00-dc11-b283-0030488c597c
SVN maintenance.


git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53191 954f8c5b-7b00-dc11-b283-0030488c597c
py api: be more strict with boolean assignment, only accept 0 or 1, True/False. Would allow any nonzero value.


git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53192 954f8c5b-7b00-dc11-b283-0030488c597c
add a test to the addons loaded that tries to load all addons then lists addons that fail.


git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53193 954f8c5b-7b00-dc11-b283-0030488c597c
py api: add restrict state context manager (thats python's context not blenders context),
which restricts bpy.context and bpy.data.

enable this for loading scripts in 'startup' too.


git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53194 954f8c5b-7b00-dc11-b283-0030488c597c
must use permutation table

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53195 954f8c5b-7b00-dc11-b283-0030488c597c
add a comment

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53196 954f8c5b-7b00-dc11-b283-0030488c597c
Scons / Windows Release Builds:
* Don't put -release- string into the final .exe name.
blender-2.65-release-windows32.exe --> blender-2.65-windows32.exe

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53198 954f8c5b-7b00-dc11-b283-0030488c597c
Support for actual class methods in the RNA/bpy. Previously all functions with FUNC_NO_SELF were treated as static methods, which is not sufficient for getting actual type information if the function can not be generated in advance in makesrna. Now the FUNC_USE_SELF_TYPE flag can be set in addition to FUNC_NO_SELF (if FUNC_NO_SELF is not set, FUNC_USE_SELF_TYPE has no effect). Such functions will be interpreted as class methods and must take a StructRNA pointer argument. This pointer is the same as the type member in PointerRNA, but can be passed without an actual data/id instance.

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53199 954f8c5b-7b00-dc11-b283-0030488c597c
Associate Node RNA subtypes with their respective bNodeType on registration. This has to be done in blenkernel, since RNA node types are actually registered before the node types. Future dynamic node types registered using the API will register their own explicit RNA types and don't need this hack.

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53200 954f8c5b-7b00-dc11-b283-0030488c597c
Make the get_node_type method in Node subtype an actual classmethod by setting the new FUNC_USE_SELF_TYPE flag.

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53201 954f8c5b-7b00-dc11-b283-0030488c597c
Camera tracking: synchronize changes with own branch

Should be no functional changes.

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53202 954f8c5b-7b00-dc11-b283-0030488c597c
Mac Retina fix:

Mouse coordinates were not mapped correctly for code that allows to use
multiple windows efficiently (mouse over not-active windows).

Apple's high-density display mode works a bit strange, requiring some hacks :/

- Desktop coordinate system (mouse pos and for windows) is as usual
  (set by display resolution settings)
- However, the available pixels in a window is always on 'retina' level.
  (full screen - 2880 wide, but window can be 1440 or 1920 wide)

In order to get this to work for opengl and Blender, we use internally the
coordinates on pixel level. That means that window positions and sizes have
to mappend in our code.

Once all issues for retinas have been tackled, I'll check on clean API for 
it, so you can also use it in future for other high density screens.



git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53203 954f8c5b-7b00-dc11-b283-0030488c597c
Bug fix #28915 and #33538

Mac OS X trackpad and 'mighty mouse' fix.

An old commit from Damien in 2010 tried to make mighty mouse touches work as if
this is a scrollwheel. The error in that code was that the "kinetic scrolling"
feature failed. When releasing your fingers, the events passed on to Blender
then switched from "trackpad pan" to "mousewheel zoom".

This commit makes trackpads and mighty mouse behave identical. Only difference
is that trackpad panning needs 2 fingers, mighty mouse only one.

Note that trackpad and mighty mouse 3d zoom works with holding ctrl!

All works nice with this kinetic feature now. Fun :)



git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53205 954f8c5b-7b00-dc11-b283-0030488c597c
Updated icon svg and bitmaps. Now has the movieclip editor again :)



git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53206 954f8c5b-7b00-dc11-b283-0030488c597c
Change region drawing callbacks to work much closer to how blender manages them internally.
- yes, this does break scripts, but the api is marked experimental.


ED_region_draw_cb_activate() adds a callback to a region type whereas the api made it look like the callback was being added to the region instance.
Use a class method on bpy.types.Space to manage region drawing, eg.

was:
  self._handle = context.region.callback_add(draw_callback_px, args, 'POST_PIXEL')

is now:
  self._handle = bpy.types.SpaceView3D.draw_handler_add(draw_callback_px, args, 'WINDOW', 'POST_PIXEL')


git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53207 954f8c5b-7b00-dc11-b283-0030488c597c
Bug fix:

Laptop trackpad scroll was inverted for 3d window.
Now movement is consistent among editors and follows system prefs.



git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53208 954f8c5b-7b00-dc11-b283-0030488c597c
Fix #33629: DDS DXT5 with alpha not loaded correctly, Y flipping code was wrong.

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53209 954f8c5b-7b00-dc11-b283-0030488c597c
Fix #33630: DDS compressed textures were not actually using mipmaps for minification.

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53210 954f8c5b-7b00-dc11-b283-0030488c597c
Better cursor centering for text editor

git-svn-id: https://svn.blender.org/svnroot/bf-blender/trunk/blender@53211 954f8c5b-7b00-dc11-b283-0030488c597c