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:
authorJoshua Leung <aligorith@gmail.com>2009-03-09 10:00:40 +0300
committerJoshua Leung <aligorith@gmail.com>2009-03-09 10:00:40 +0300
commit6475e462fa1d3da30baac9a91b45779078169716 (patch)
tree537c58dad242141a7d3ee57225363443aad6b3c6 /source/blender/editors/interface/view2d.c
parentf73d7c697cc092fa4e3239f2a3f62ed190509287 (diff)
Graph Editor: Frame numbers in horizontal scrollbar are no longer restricted to 1.0 frame intervals.
Diffstat (limited to 'source/blender/editors/interface/view2d.c')
-rw-r--r--source/blender/editors/interface/view2d.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/source/blender/editors/interface/view2d.c b/source/blender/editors/interface/view2d.c
index 693f540128f..6e738942e29 100644
--- a/source/blender/editors/interface/view2d.c
+++ b/source/blender/editors/interface/view2d.c
@@ -1468,10 +1468,14 @@ void UI_view2d_scrollers_draw(const bContext *C, View2D *v2d, View2DScrollers *v
/* draw numbers in the appropriate range */
if (dfac > 0.0f) {
for (; fac < hor.xmax; fac+=dfac, val+=grid->dx) {
- switch (vs->xunits) {
+ switch (vs->xunits) {
case V2D_UNIT_FRAMES: /* frames (as whole numbers)*/
scroll_printstr(vs, scene, fac, 3.0f+(float)(hor.ymin), val, grid->powerx, V2D_UNIT_FRAMES, 'h');
break;
+
+ case V2D_UNIT_FRAMESCALE: /* frames (not always as whole numbers) */
+ scroll_printstr(vs, scene, fac, 3.0f+(float)(hor.ymin), val, grid->powerx, V2D_UNIT_FRAMESCALE, 'h');
+ break;
case V2D_UNIT_SECONDS: /* seconds */
fac2= val/(float)FPS;
@@ -1490,7 +1494,7 @@ void UI_view2d_scrollers_draw(const bContext *C, View2D *v2d, View2DScrollers *v
}
break;
- case V2D_UNIT_DEGREES: /* IPO-Editor for rotation IPO-Drivers */
+ case V2D_UNIT_DEGREES: /* Graph Editor for rotation Drivers */
/* HACK: although we're drawing horizontal, we make this draw as 'vertical', just to get degree signs */
scroll_printstr(vs, scene, fac, 3.0f+(float)(hor.ymin), val, grid->powerx, V2D_UNIT_DEGREES, 'v');
break;