Blender V4.3
object_modes.cc File Reference
#include "DNA_object_enums.h"
#include "DNA_object_types.h"
#include "DNA_scene_types.h"
#include "BLI_time.h"
#include "BLI_utildefines.h"
#include "BKE_context.hh"
#include "BKE_layer.hh"
#include "BKE_modifier.hh"
#include "BKE_object.hh"
#include "BKE_object_types.hh"
#include "BKE_paint.hh"
#include "BKE_report.hh"
#include "BLI_math_vector.h"
#include "WM_api.hh"
#include "WM_types.hh"
#include "RNA_access.hh"
#include "RNA_define.hh"
#include "DEG_depsgraph.hh"
#include "DEG_depsgraph_query.hh"
#include "ED_armature.hh"
#include "ED_gpencil_legacy.hh"
#include "ED_outliner.hh"
#include "ED_paint.hh"
#include "ED_physics.hh"
#include "ED_sculpt.hh"
#include "ED_undo.hh"
#include "ED_view3d.hh"
#include "WM_toolsystem.hh"
#include "ED_object.hh"
#include "object_intern.hh"

Go to the source code of this file.

Namespaces

namespace  blender
 
namespace  blender::ed
 
namespace  blender::ed::object
 

Functions

High Level Mode Operations
static const char * blender::ed::object::object_mode_op_string (eObjectMode mode)
 
bool blender::ed::object::mode_compat_test (const Object *ob, eObjectMode mode)
 
bool blender::ed::object::mode_compat_set (bContext *C, Object *ob, eObjectMode mode, ReportList *reports)
 
Generic Mode Enter/Exit

Supports exiting a mode without it being in the current context. This could be done for entering modes too if it's needed.

bool blender::ed::object::mode_set_ex (bContext *C, eObjectMode mode, bool use_undo, ReportList *reports)
 
bool blender::ed::object::mode_set (bContext *C, eObjectMode mode)
 
static bool blender::ed::object::ed_object_mode_generic_exit_ex (Main *bmain, Depsgraph *depsgraph, Scene *scene, Object *ob, bool only_test)
 
static void blender::ed::object::ed_object_posemode_set_for_weight_paint_ex (bContext *C, Main *bmain, Object *ob_arm, const bool is_mode_set)
 
void blender::ed::object::posemode_set_for_weight_paint (bContext *C, Main *bmain, Object *ob, bool is_mode_set)
 
void blender::ed::object::mode_generic_exit (Main *bmain, Depsgraph *depsgraph, Scene *scene, Object *ob)
 
bool blender::ed::object::mode_generic_has_data (Depsgraph *depsgraph, const Object *ob)
 
Transfer Mode

Enters the same mode of the current active object in another object, leaving the mode of the current object.

static bool blender::ed::object::object_transfer_mode_poll (bContext *C)
 
static void blender::ed::object::object_transfer_mode_reposition_view_pivot (ARegion *region, Scene *scene, const int mval[2])
 
static void blender::ed::object::object_overlay_mode_transfer_animation_start (bContext *C, Object *ob_dst)
 
static bool blender::ed::object::object_transfer_mode_to_base (bContext *C, wmOperator *op, Scene *scene, Object *, Object *ob_dst, const eObjectMode mode_dst)
 
static int blender::ed::object::object_transfer_mode_invoke (bContext *C, wmOperator *op, const wmEvent *event)
 
void blender::ed::object::OBJECT_OT_transfer_mode (wmOperatorType *ot)
 

Detailed Description

General utils to handle mode switching, actual mode switching logic is per-object type.

Definition in file object_modes.cc.