Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHoward Trickey <howard.trickey@gmail.com>2021-10-24 15:31:22 +0300
committerHoward Trickey <howard.trickey@gmail.com>2021-10-24 15:31:22 +0300
commit1aa953bd1913c81b22c80a00edbf4ad88a32c52f (patch)
tree7fa65e43d5a9bac6496555b723f37e0031e2737e /source/blender/editors/space_view3d/space_view3d.c
parentfc171c1be9da36485e892339b86dc8d4251914af (diff)
parent6ce383a9dfba5c49a48676c3a651804fde3dfe34 (diff)
Merge branch 'master' into soc-2020-io-performance
Diffstat (limited to 'source/blender/editors/space_view3d/space_view3d.c')
-rw-r--r--source/blender/editors/space_view3d/space_view3d.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/source/blender/editors/space_view3d/space_view3d.c b/source/blender/editors/space_view3d/space_view3d.c
index bda6fa05a63..7999018a6b6 100644
--- a/source/blender/editors/space_view3d/space_view3d.c
+++ b/source/blender/editors/space_view3d/space_view3d.c
@@ -30,6 +30,7 @@
#include "DNA_material_types.h"
#include "DNA_object_types.h"
#include "DNA_scene_types.h"
+#include "DNA_view3d_types.h"
#include "MEM_guardedalloc.h"
@@ -473,7 +474,7 @@ static void view3d_main_region_exit(wmWindowManager *wm, ARegion *region)
static bool view3d_drop_in_main_region_poll(bContext *C, const wmEvent *event)
{
ScrArea *area = CTX_wm_area(C);
- return ED_region_overlap_isect_any_xy(area, &event->x) == false;
+ return ED_region_overlap_isect_any_xy(area, event->xy) == false;
}
static ID_Type view3d_drop_id_in_main_region_poll_get_id_type(bContext *C,
@@ -482,7 +483,7 @@ static ID_Type view3d_drop_id_in_main_region_poll_get_id_type(bContext *C,
{
const ScrArea *area = CTX_wm_area(C);
- if (ED_region_overlap_isect_any_xy(area, &event->x)) {
+ if (ED_region_overlap_isect_any_xy(area, event->xy)) {
return 0;
}
if (!view3d_drop_in_main_region_poll(C, event)) {
@@ -563,7 +564,7 @@ static char *view3d_object_data_drop_tooltip(bContext *UNUSED(C),
static bool view3d_ima_drop_poll(bContext *C, wmDrag *drag, const wmEvent *event)
{
- if (ED_region_overlap_isect_any_xy(CTX_wm_area(C), &event->x)) {
+ if (ED_region_overlap_isect_any_xy(CTX_wm_area(C), event->xy)) {
return false;
}
if (drag->type == WM_DRAG_PATH) {
@@ -1569,10 +1570,7 @@ static void space_view3d_listener(const wmSpaceTypeListenerParams *params)
case NC_SCENE:
switch (wmn->data) {
case ND_WORLD: {
- const bool use_scene_world = ((v3d->shading.type == OB_MATERIAL) &&
- (v3d->shading.flag & V3D_SHADING_SCENE_WORLD)) ||
- ((v3d->shading.type == OB_RENDER) &&
- (v3d->shading.flag & V3D_SHADING_SCENE_WORLD_RENDER));
+ const bool use_scene_world = V3D_USES_SCENE_WORLD(v3d);
if (v3d->flag2 & V3D_HIDE_OVERLAYS || use_scene_world) {
ED_area_tag_redraw_regiontype(area, RGN_TYPE_WINDOW);
}