Blender V5.3
workspace_listen.cc
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9#include "BLI_listbase.hh"
10
11#include "BKE_context.hh"
12#include "BKE_viewer_path.hh"
13
14#include "ED_screen.hh"
15#include "ED_viewer_path.hh"
16
17#include "WM_api.hh"
18
19namespace blender {
20
26static void validate_viewer_paths(bContext &C, WorkSpace &workspace)
27{
28 if (workspace.viewer_path.path.is_empty()) {
29 return;
30 }
31
32 using namespace blender::ed::viewer_path;
33
35 C, workspace.viewer_path);
36 switch (result) {
38 return;
40 break;
43 break;
44 }
45
47}
48
50{
51 WorkSpace *workspace = CTX_wm_workspace(C);
52 validate_viewer_paths(*C, *workspace);
53}
54
55} // namespace blender
#define C
Definition RandGen.cpp:29
#define NC_VIEWER_PATH
Definition WM_types.hh:419
UpdateActiveGeometryNodesViewerResult update_active_geometry_nodes_viewer(const bContext &C, ViewerPath &viewer_path)
BMesh Iterators.
void ED_workspace_do_listen(bContext *C, const wmNotifier *note)
WorkSpace * CTX_wm_workspace(const bContext *C)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
static void validate_viewer_paths(bContext &C, WorkSpace &workspace)
void BKE_viewer_path_clear(ViewerPath *viewer_path)
ListBaseT< ViewerPathElem > path