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:
authorJacques Lucke <mail@jlucke.com>2019-05-07 16:09:14 +0300
committerJacques Lucke <mail@jlucke.com>2019-05-07 16:09:14 +0300
commitf2b7582b27fa1235a013b2d92af72428c0fc1623 (patch)
tree6585abf521e82cc1933aa498fc6688970be9f5a8 /source/blender/editors/space_sequencer
parente4669199bf9c819d82072f7dd93ff7156e9e72aa (diff)
UI: Animation editor scrubbing area
The main reason for this change is to allow setting the active frame with the left mouse button, while still being able to select e.g. keyframes with the same mouse button. The solution is to introduce a new scrubbing region with a specialized keymap. There are a couple of related todos, that will be handled in separate commits. Those are listed in D4654. This solves T63193. Differential Revision: https://developer.blender.org/D4654 Reviewers: brecht, billreynish
Diffstat (limited to 'source/blender/editors/space_sequencer')
-rw-r--r--source/blender/editors/space_sequencer/sequencer_draw.c16
-rw-r--r--source/blender/editors/space_sequencer/space_sequencer.c2
2 files changed, 7 insertions, 11 deletions
diff --git a/source/blender/editors/space_sequencer/sequencer_draw.c b/source/blender/editors/space_sequencer/sequencer_draw.c
index a3b02407a9e..efae873a86c 100644
--- a/source/blender/editors/space_sequencer/sequencer_draw.c
+++ b/source/blender/editors/space_sequencer/sequencer_draw.c
@@ -60,6 +60,7 @@
#include "ED_mask.h"
#include "ED_sequencer.h"
#include "ED_screen.h"
+#include "ED_scrubbing.h"
#include "ED_space_api.h"
#include "BIF_glutil.h"
@@ -2085,19 +2086,14 @@ void draw_timeline_seq(const bContext *C, ARegion *ar)
/* reset view matrix */
UI_view2d_view_restore(C);
+ /* scrubbing region */
+ ED_scrubbing_draw(ar, scene, !(sseq->flag & SEQ_DRAWFRAMES), true);
+
/* scrollers */
scrollers = UI_view2d_scrollers_calc(v2d, NULL);
UI_view2d_scrollers_draw(v2d, scrollers);
UI_view2d_scrollers_free(scrollers);
- /* scale numbers */
- UI_view2d_draw_scale_x__discrete_frames_or_seconds(
- ar, v2d, &v2d->hor, scene, !(sseq->flag & SEQ_DRAWFRAMES), TH_TEXT);
- UI_view2d_draw_scale_y__block(ar, v2d, &v2d->vert, TH_TEXT);
-
- /* draw current frame number-indicator on top of scrollers */
- if ((sseq->flag & SEQ_NO_DRAW_CFRANUM) == 0) {
- UI_view2d_view_orthoSpecial(ar, v2d, 1);
- ANIM_draw_cfra_number(C, v2d, cfra_flag);
- }
+ /* channel numbers */
+ UI_view2d_draw_scale_y__block(ar, v2d, &v2d->vert, TH_SCROLL_TEXT);
}
diff --git a/source/blender/editors/space_sequencer/space_sequencer.c b/source/blender/editors/space_sequencer/space_sequencer.c
index 2b0c29a02ad..daeaf962039 100644
--- a/source/blender/editors/space_sequencer/space_sequencer.c
+++ b/source/blender/editors/space_sequencer/space_sequencer.c
@@ -816,7 +816,7 @@ void ED_spacetype_sequencer(void)
art->draw = sequencer_main_region_draw;
art->listener = sequencer_main_region_listener;
art->message_subscribe = sequencer_main_region_message_subscribe;
- art->keymapflag = ED_KEYMAP_VIEW2D | ED_KEYMAP_MARKERS | ED_KEYMAP_FRAMES | ED_KEYMAP_ANIMATION;
+ art->keymapflag = ED_KEYMAP_VIEW2D | ED_KEYMAP_FRAMES | ED_KEYMAP_ANIMATION;
BLI_addhead(&st->regiontypes, art);