Age | Commit message (Collapse) | Author |
|
Python operator api was using WM_operator_name_call() which was confusing things too much.
Added WM_operator_call_py() which ended up being a very small function and split out operator creation into wm_operator_create()
Python operator now runs the poll() function and raises an error if it fails.
Eventually there should be error messages for poll that python can use to give the exact reason for failing (eg - library linked data, no active object...)
|
|
A small round of warning cleanups; unused variables, missing
headers and some const types.
|
|
* [Use nodes] added. For future improvements: a panel which enumerates
materials, textures and scenes for selection and editing in the opened
node-editor without having to set it in Buttons (or 'global' scene).
|
|
* add nodes through header menu (no way to link them yet, though ;)
Note: the adding needs to be properly operatorfied still.
|
|
* when reading an old .blend 2.5 crashed on creating input node menu. type->name is for some reason NULL, so add simple check to prevent from happening again.
|
|
Bugfix: WM gesture manager was not assigning gesture to the
context-defined region, making border select calls from a
header not work.
This fixes Node header option "Border select".
|
|
* bring border select (BKey), works in editor, but draws
badly only in header when initiated from menu, so that's
commented out for now.
|
|
* errors in python called operators are raised as errors
* Python defined operators errors are reported as errors (not full traceback yet)
* added BKE_reports_string, same as BKE_reports_print but it returns a string rather then printing it.
* WM_operator_name_call optionally takes an initialized report struct
|
|
|
|
* zoom in/out added also as menu entry
* view all operator is now only executed, not invoked.
|
|
* invoke View all through header menu :)
|
|
* HOMEKEY enabled (view all), made into operator.
|
|
* enable more code (button callbacks, will probably undergo revision)
|
|
* header: better positioning of buttons, new drawing style was mixing up for old positions.
|
|
* API and usage is basically the same still.
* Panels were moved to region level. I first thought of keeping them at area
level, but having them at region level it's simpler to handle events and do
drawing, and also to integrate with view2d. They can still become area level
overlapping regions, if we make a floating (or docked) region that can
contain panels.
* Added back a few panels from the scene buttons for testing.
Issues still:
* The view2d handling and alignment refresh of panels is not correct yet in the
buttons window.
* I did not yet bring back the block handlers system. It was basically a system
that stored which panel was open and where the events for that panel would go.
Just a few functions, but not sure how it fits in 2.5.
* There was a case where dragging panels would not properly remove the window
level handler, but could not redo anymore even though I don't think I fixed
it.
* Some text in the panels goes past the end of the button, that is due to the
checkmark button drawing, not related to this commit.
Other UI code changes:
* Renamed interface.h to interface_intern.h for consistency.
* Fixed some issues with freeing of blocks when they changed due to context.
* uiDrawBlock now takes a context pointer (mostly for block drawextra).
|
|
* almost all header menu drawing is back, no real actions yet, though.
|
|
* fix warnings for msvc
|
|
* header menu drawing
|
|
Commit of WIP code (what code isn't wip, these days ;)
- only drawing code as basis to work further from (and have less conflicts between different systems I work on)
|
|
Compile fix; MAXFLOAT is not defined uniformly on platforms.
Note for the coders:
ED_types.h: has editor wide defines and structs
ED_util.h: has editor wide functions
Both includes also are containing old cruft to get things
to compile (and work), for later cleanup.
|
|
Context API
This adds the context API as described here. The main practical change
now is that C is not longer directly accessible but has to be accessed
through accessor functions. This basically adds the implementation of
the API and adaption of existing code with some minor changes. The next
task of course is to actually use this design to cleanup of bad level
calls and global access, in blenkernel, blenloader.
http://wiki.blender.org/index.php/BlenderDev/Blender2.5/Context
Error, Warning and Debug Info Reporting
This adds the error reporting API as described here. It should help
clean up error() calls in non-ui code, but eventually can become used
for gathering messages for a console window, and throwing exceptions
in python scripts when an error happens executing something.
http://wiki.blender.org/index.php/BlenderDev/Blender2.5/Reports
|
|
- depricated area "headbutofs" and "headbutlen", which is now fully
replaced with view2d handling.
- needed to add header default V2D_ALIGN_NO_NEG_Y, V2D_LOCKOFS_Y seems
to not do anything atm :)
- new: running blender in debug (blender -d) will print the current
handler and operator in use (not mousemove)
|
|
- Added file space (too) :) Andrea was first, this is more
complete.
- Suggestion from Joshua: move all standard header buttons to
1 function, makes it all easier, less code, and less area/space
stuff needs to be exposed.
|
|
The basics for Node Space.... no complaints sofar :)
|