BOP_Merge2.cpp
had same variable name at different scopes so I renamed a couple.
resources.c
added include that was missing. (This maybe was going to move? the old one
was commented out)
ed_markers.c
initalized a var that needed it.
Kent
Fix crashing in pop-up menus when click.
There's something wrong still in handling menu itself, need Brecht
too look at that... probably a wrong return value somewhere.
Fix: the main button handler was swallowing all events. Now every button
type returns 'handled' only if it did something, so other events get nicely
processed.
This will enable MMB pan in dataviewer.
- Made view2d manipulations redraw on area level
- simplified call to send Notifiers:
WM_event_add_notifier(bContext *C, int type, int value, void *data)
This brings back more control to WM, no context messing within
operators. :) Handlers that execute operators will be responsible
for delivering correct contextes.
In general: should lead to making context not exposed, but only
readable via some callbacks.
- View2d bug: it was taking sliders into account for setting the
window matrix, which it shouldn't (glViewport does). This caused
error offset in drawing, like for current-frame scrolling.
- Current frame scrolling in TimeWindow back on window level.
(used to crash, but that was fixed in WM)
- Made UI_view2d_region_to_view accept ints, no shorts
- removed debug function in interface_ops.c
many small changes, but the two bigger ones are:
* Sensors and controllers now use inheritance, rather than pointing
to the data in a separate struct. Had to add some new RNA define
functionality to support this better.
* DNA_meta_types.h was marked as done but still missing many things,
now completed.
- after closing button (having used it), it sends empty mousemove for
invoking new modal handler on same button. Don't know better solution
for now, at least this way WM handles everything. :)
- experiment: moved button handlers to area level, that way it respects
handlers on higher hierarchical level, like moving area edges.
Als interesting is that you can have a button active (texteditor) and
use a similar button in other area.
This can also be done on region level even.
On todo: proper notifier events for redraw! Don't want all areas to draw
on simple refreshes
* RNA_property_enum_value
* RNA_property_enum_identifier
To get an enum string from a value and a value from an enum.
BPy_StructRNA types (objects, meshes, images etc) can now be used as dictionary keys.
* Changes in interface/ module
This commit brings back the way how buttons/menus work under control
of WM event system. The previous implementation extended usage of
handlers and operators in an interesting but confusing way. Better to
try it first according the design specs. :)
Most obviously:
- modal-handler operators are not stored anymore in regions/areas/windows.
such modal handlers own their operator, and should remove it themselves.
- removed code to move handlers from one queue to another.
(needs review with brecht!)
- WM fix: the API call to remove a modal handler got removed. This was a
dangerous thing anyway, and you should leave that to the event system.
Now, if a handler modal() call gets a cancel/finish return, it frees
itself in event system. WM_event_remove_modal_handler was a confusing
call anyway!
Todo:
- allow button-activate to refresh after using button
- re-enable arrow keys for menus
(do both after commit)
- review return values of operator callbacks in interface_ops.c
* Fixes in WM system
- Freeing areas/regions/windows, also on quit, now correctly closes
running modal handlers
- On starting a modal handler, the handler now stores previous area
and region context, so they send proper notifiers etc.
* Other fixes
- Area-split operator had bug, wrong minimal size checking. This
solves error when trying to split a very narrow area.
- removed DNA_USHORT_FIX from screen_types.h, gave warning
- operators didn't get ID name copied when activated, needed for
later re-use or saving.
* Improved scrollbar drawing a bit more - only cosmetic lines
* Added new view2d view-matrix api method to only use 'cur' coordinates on one axis, for use when drawing markers, etc. that need to be glued to a certain time but stay fixed in space in another dimension. This should improve the sitation for drawing markers
* To aid testing, adding markers now sets the marker to have frame number as it's "name". This will need to be removed later...
source\blender\python\intern\bpy_rna.c:1018: error: initializer element is not constant
source\blender\python\intern\bpy_rna.c:1018: error: (near initialization for `pyrna_prop_Type.tp_get
Assign get generic get/sets before PyType_Ready runs
* DNA_packedFile_types: added rna definitions for packed files
* also experimentally filled in correct struct 'PackedFile' in image rna for testing.
* updated MSVC projectfiles (also for rna_curve.c and rna_vfont.c)
Note:
I removed PackedFile->flags, I did grep through source and a complete recompile of blender trunk svn without them too, so they obviously aren't needed anymore. A bit of cleaning up :)
Implemented RNA wrappers for curves and VFont. Only issue I could
not yet solve is related to struct CharInfo curinfo; . This particular
line proved to be hard to wrap and I therefore marked it as a TODO
should someone want to fix this issue.
I also cleaned up makesrna.c a bit by unifying brush/meta parts
under one call just the way it is done in the case of other
wrappers.
Implemented RNA wrapper for ModifierData.
Note that actual interface to access data of any specific modifier is
still missing. I also marked a couple of parts as TODO that should be
reviewed to decide whether or not to expose those specific parts
via RNA.
* Added basic (non-modal) zoom operators that use a uniform scale factor, with zoom centered using the view center as scaling point. Use Scrollwheel up/down and Pad +/- to use this.
* Added back the 'button'/bubble for the scrollbars. I've added dark lines on either end of it for some later work on zooming widgets.
This is not the final form they'll take. I still need to decide how to handle those scrollbars which act as grid-markers too (showing timescale, etc.), before trying to integrate that with some fancy scrollbar drawing (rounded, etc.)
Assorted changes:
* Moved vertical scrollbar for Outliner to right hand side
* Made Timeline use standard scrollbars, and turned on various clamping options
* Fixed ortho-matrix corrections for scrollbars, and added pixel offsets
* Made Timeline markers sit more snugly on the scrollbar. They were a bit far out...
* Fixed memory leak with view2d keymaps not being freed when Blender exited
Wrapped most of brush. Brush is still missing a link to texture and to
BrushClone. Also PAINT_TOOL_DRAW etc. flags found on DNA_brush_types.h
need to be associated to a brush somehow. Currently they are linked
to a brush via ImagePaintSettings.
Also changed identifiers in metaball wrapping to conform with the
standards.
* Start of basic scrollbar drawing. This will be improved. Only Outliner shows these for now, as although the Timeline should show them, the old files didn't have them turned on.
* Tidied up the view-panning operator
- Fixed naming convention
- Added user-adjustable properties (deltax, deltay in screenspace)
* Added ctrl-scrollwheel (horizontal) and shift-scrollwheel (vertical) scroll operators. These use the view-panning code too.
Unfortunately, I haven't been able to figure out why the WHEELMOUSEDOWN events don't seem to be triggering the operators!
* added rna_property.c and rna_actuator
* enabled access to properties and actuators from object
Note that because we have RNA_Property in the RNA itself, you can find
properties in gamelogic of and object under the name of RNA_GameProperty
* DNA_radio_types.h: done. (patch by Jorge Bernal). Also adds
some #defines in the radiosity DNA since it was using hardcoded
values.
* Added an "UnknownType" which has no properties, useful as a
placeholder for pointers that have no defined type yet.
* Sort a few lists in the code alphabetically.
examples...
RNA Lamp: Lamp
==============
@ivar rna_type: RNA type definition. *readonly*
@type rna_type: PyRNA PointerProperty
@ivar name: Unique datablock ID name. (22 maximum length)
@type name: string
@ivar adapt_thresh: Threshold for Adaptive Sampling. in (0.000, 1.000)
@type adapt_thresh: float
@ivar area_shape: Shape of the Area lamp
@type area_shape: enum in [SQUARE, RECTANGLE]
@ivar area_size: Size of the area of the Area Lamp. in (0.000, 100.000)
@type area_size: float
@ivar area_sizey: Size of the area of the Area Lamp. in (0.000, 100.000)
@type area_sizey: float
- snip
RNA Object: Object
==================
@ivar rna_type: RNA type definition. *readonly*
@type rna_type: PyRNA PointerProperty
@ivar name: Unique datablock ID name. (22 maximum length)
@type name: string
@ivar data: Object data. *readonly*
@type data: PyRNA PointerProperty
@ivar fake_user: Saves this datablock even if it has no users
@type fake_user: bool
@ivar library: Library file the datablock is linked from. *readonly*
@type library: PyRNA PointerProperty
@ivar loc: in (-inf, inf)
@type loc: float[3]
== MSVC projectfiles ==
- update for python RNA API
- update for editors: ed_util.c
- fixed RNA_rna library project, doesn't need the c files included in rna.c
* Moved View2D data from space-data to ARegion (aka regions). This has been done because drawing occurs in regions not areas anymore. The View2D struct is currently stored in the ARegion struct (not as pointer), given that most of the regions in use will be 2D anyway (only the 3d-view's "window" region is the exception).
Added version patch code for outliner and timeline only for now. Headers are also likely to need this.
* Added separate keymap for View2D operators. All regions that use View2D will need this added. This includes headers too.
* Pan view operator (ED_View2D_OT_view_pan), currently works for Outliner and Timeline. Use MMB-drag as before.
- It currently doesn't exposed any parameters for redo (via RNA-ID-Props), but only uses some customdata. Suggestions on what these parameters could be are welcomed.
- I've yet to implement the necessary axis-locking features for this panning (which is required in Timeline for example to prevent vertical panning, which moves the markers out of view).
Can now assign RNA arrays from python lists of bools/ints/floats
eg -> rna.scenes["Scene"].layer = [True] * 20
Also added exceptions when trying to set readonly properties.