Age | Commit message (Collapse) | Author |
|
* Allow operators to show a "disabled hint" in red text explaining why dropping
at the current location and in current context doesn't work. Should greatly
help users to understand what's the problem.
* Show a "stop" cursor when dropping isn't possible, like it's common on OSes.
Differential Revision: https://developer.blender.org/D10358
|
|
No functional changes.
This commit adds 3 callbacks for `wmDropBox` which allow custom drawing
without affecting the internal dropbox API.
Differential Revision: https://developer.blender.org/D12948
|
|
This adds an offscreen View3D window area for the VR view in order to
execute XR events/operators in the proper context. The area is created
as runtime data before XR events are dispatched and set as the active
area during XR event handling.
Since the area is runtime-only, it will not be saved in files and since
the area is offscreen, it will not interfere with regular window areas.
The area is removed with the rest of the XR runtime data on exit, file
read, or when stopping the VR session.
Note: This also adds internal types (EVT_DATA_XR, EVT_XR_ACTION) and
structs (wmXrActionData) for XR events.
Reviewed By: Severin
Differential Revision: https://developer.blender.org/D12472
|
|
This replaces header include guards with `#pragma once`.
A couple of include guards are not removed yet (e.g. `__RNA_TYPES_H__`),
because they are used in other places.
This patch has been generated by P1561 followed by `make format`.
Differential Revision: https://developer.blender.org/D8466
|
|
This removes extern-C blocks around other includes and adds
such blocks for some headers that need them.
|
|
Pressing 'E' over a number button to pick a distance was keeping
left-right arrows instead of using the eye-dropper cursor.
Workaround this by clearing the active button before setting the cursor.
|
|
The old convention was easy to confuse with ScrArea.
Part of https://developer.blender.org/T74432.
This is mostly a batch rename with some manual fixing. Only single word
variable names are changed, no prefixed/suffixed names.
Brecht van Lommel and Campbell Barton both gave me a green light for
this convention change.
Also ran clan clang format on affected files.
|
|
Previously the window manager would receive the GHOST event and then query the
latest tablet data from the window to go along with it. If multiple events were
queued, it would then use too new tablet data for handling older events.
Fixes T62565: tablet pressure not working on macOS with some devices
|
|
|
|
Steps to reproduce were:
* Ensure //Render//->//Display Mode// is //New Window//
* F12
* In the opened Image Editor, Alt+S to save the image
* Save the image
The saving would fail silently.
Issue was that wm_handler_op_context() would fail to find the correct
area to activate, as the wrong window was active in context. So allow
overriding this window and do so when creating the file-select handler.
|
|
Respect do_time flag in on_visible_update, matching behavior of old
dependency graph and avoids unwanted animation updates.
Reviewers: brecht
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D5026
|
|
|
|
Previously only a fixed bounding box could be used.
This was not flexible enough.
T63193 will benefit from this refactor.
Reviewers: brecht, campbellbarton
|
|
Apply clang format as proposed in T53211.
For details on usage and instructions for migrating branches
without conflicts, see:
https://wiki.blender.org/wiki/Tools/ClangFormat
|
|
Now there are two callbacks, the name 'keymap_callback' is too vague.
|
|
Add getter callback support for 'WM_HANDLER_TYPE_KEYMAP' type handlers
this is needed for key-maps which change based on the active tool.
Replaces 'sneaky_handler' hack which temporarily inserted a handler.
|
|
Makes it more clear it's the header/start of the struct.
|
|
|
|
Illuminate dead code, using wmEventHandler_KeymapFn from gizmo handler
type where it was never set.
|
|
|
|
|
|
|
|
|
|
Currently it's effectively a boolean for file-select handlers.
Prepare for refactoring event handlers into their own types (keymap,
operator, gizmo, ui & dropbox) to help make logic easier to follow.
|
|
While \file doesn't need an argument, it can't have another doxy
command after it.
|
|
Move \ingroup onto same line to be more compact and
make it clear the file is in the group.
|
|
Needed for clan-format not to wrap onto one line.
|
|
BF-admins agree to remove header information that isn't useful,
to reduce noise.
- BEGIN/END license blocks
Developers should add non license comments as separate comment blocks.
No need for separator text.
- Contributors
This is often invalid, outdated or misleading
especially when splitting files.
It's more useful to git-blame to find out who has developed the code.
See P901 for script to perform these edits.
|
|
Done using:
source/tools/utils_maintenance/c_sort_blocks.py
|
|
Grease Pencil already implements support for full-featured
per-brush pressure curves, but it is useful to have some
basic global settings that affect all brushes and tools.
This adds two simple options:
- Raw pressure required to achieve full brush intensity.
- Softness control, using a gamma curve internally.
The most important one is the max pressure setting, because it is
critical for ergonomics, but the Linux Wacom driver lacks it.
The softness option internally converts to gamma = 4^-softness.
Reviewers: brecht, campbellbarton
Differential Revision: https://developer.blender.org/D3967
|
|
Differential Revision: https://developer.blender.org/D3719
|
|
|
|
Will help entering sculpt mode on file load by making it possible
to fully initialize sculpt session. The goal is to make sure PBVH
exists since the very beginning of file open (missing PBVH is a
reason why object is not visible before first stroke).
This is not enough yet to fully solve the issue, since entering
sculpt mode tags object for Copy-on-Write update, which frees
PBVH.
|
|
|
|
Strip unindented comment blocks - mainly headers to avoid conflicts.
|
|
Was introduced in e7895bac07f32
Only certain actions caused this, reported as T55155
|
|
This replaces last-used property use which wasn't reliable since
properties were not considered 'set' - causing them to be ignored.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This avoids obscure bugs where operators could run from
events that happen before the UI and depsgraph have been initialized.
See: D2809 for details.
|
|
This reverts commit 82ba89b042e7067 (which caused T51969) and adds an
alternative fix (don't unset area stored in modal handler for fileselect
handlers).
|
|
Caused by 4811b2d3565cf which caused the event handler hack that is used to fire up the file browser from other operators to fail. Basically the context from before the file browser is opened gets stored and used later for executing the actual file read/write operation (in this case, saving image). This context storage is cleared when exiting an editor since 4811b2d3565cf, which is technically correct, but causes usage of NULLed context data in this case, because the file browser is exited before the file read/write operation is executed.
For now I solved this by moving the fileselect handler to list of normal handlers, instead of modal ones. 4811b2d3565cf only touches list of modal handlers so we avoid the crash. Ideally we'd completely refactor how the file browser opening works to get rid of these event handler hacks.
Note that I wouldn't be suprised if this causes other regressions, but I couldn't find one so worth a try.
|
|
This commit lands the core backend of the Custom Manipulators project onto the blender2.8 branch. It is a generic backend for managinig interactive on-screen controls that can be integrated into any 2D or 3D edito. It's also already integrated into the window-manager and editor code where needed.
NOTE: The changes here should not be visible for users at all. It's really just a back-end patch. Neither does this include any RNA or Python integration.
Of course, there's still lots of work ahead for custom manipulators, but this is a big milestone. WIP code that actually uses this backend can be found in the 'custom-manipulators' branch (previously called 'wiggly-widgets').
The work here isn't completely my own, all the initial work was done by @Antony Riakiotakis (psy-fi) and - although it has changed a lot since them - it's still the same in essence. He definitely deserves a big credit! Some changes in this patch were also done by @Campbell Barton (campbellbarton). Thank you guys!
Merge accepted by @brecht and @merwin.
Patch: https://developer.blender.org/D2232
Code documentation: https://wiki.blender.org/index.php/Dev:2.8/Source/Custom_Manipulator
Main task: https://developer.blender.org/T47343
More info: https://code.blender.org/2015/09/the-custom-manipulator-project-widget-project/
|
|
It was possible to perform actions while performing a drag-toggle.
|
|
This is a kind of sloppy-focus,
resolving long standing bug with loop-cut/knife/ruler /w quad-view.
Where activating a tool would lock onto one of quad-views,
especially problematic when activating from the toolbar or menus.
|
|
Adds support for stacked fullscreens. This basically means, if a user opens a
temporary fullscreen mode, such as the File Browser or the Image Editor render
view, from a different fullscreen, the "Back to Previous" function or the other
ways to escape those temporary fullscreens don't return to the split screen
layout but to the previous fullscreen he has been in.
I already committed something similar (f7e844570fea862) but that was only
supposed as a fix, it didn't work for the "Back to Previous" operator and the
implementation wasn't really reusable. This one looks a bit nicer + makes some
older hacks unnecessary :)
|