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:
authorRichard Antalik <richardantalik@gmail.com>2022-04-04 15:25:13 +0300
committerRichard Antalik <richardantalik@gmail.com>2022-04-04 15:28:55 +0300
commite49fef45cef7d53ae856a943e125838cdfcea0a0 (patch)
treeb2b299823e5fa423788784da9741c2d27b06c211 /source/blender/editors/include/UI_view2d.h
parent3ce6c5adfc6e9afd8a4db8d91084ae707db9b262 (diff)
VSE: Use edge panning
Add edge panning feature to transform operator. It works in same way as in node editor, but Y axis is limited by usable range up to 128 channels. Reviewed By: Severin Differential Revision: https://developer.blender.org/D14310
Diffstat (limited to 'source/blender/editors/include/UI_view2d.h')
-rw-r--r--source/blender/editors/include/UI_view2d.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/editors/include/UI_view2d.h b/source/blender/editors/include/UI_view2d.h
index 4282465c0ca..56b0bd04a71 100644
--- a/source/blender/editors/include/UI_view2d.h
+++ b/source/blender/editors/include/UI_view2d.h
@@ -447,6 +447,8 @@ typedef struct View2DEdgePanData {
struct ARegion *region;
/** View2d we're operating in. */
struct View2D *v2d;
+ /* Limit maximum pannable area */
+ struct rctf limit;
/** Panning should only start once being in the inside rect once (e.g. adding nodes can happen
* outside). */
@@ -492,6 +494,12 @@ void UI_view2d_edge_pan_init(struct bContext *C,
float delay,
float zoom_influence);
+/**
+ * Set area which can be panned
+ */
+void UI_view2d_edge_pan_set_limits(
+ struct View2DEdgePanData *vpd, float xmin, float xmax, float ymin, float ymax);
+
void UI_view2d_edge_pan_reset(struct View2DEdgePanData *vpd);
/**