comparison view/View.h @ 1496:d09345e578a7

Separate out handling of alignment progress bar from the layer progress bars and fix tendency to have them hanging around even when alignment has completed
author Chris Cannam
date Wed, 14 Aug 2019 10:58:24 +0100
parents c83504eb2649
children 4eafe5a1b655
comparison
equal deleted inserted replaced
1495:6bb0afa607f5 1496:d09345e578a7
511 bool setCentreFrame(sv_frame_t f, bool doEmit); 511 bool setCentreFrame(sv_frame_t f, bool doEmit);
512 512
513 void movePlayPointer(sv_frame_t f); 513 void movePlayPointer(sv_frame_t f);
514 514
515 void checkProgress(ModelId); 515 void checkProgress(ModelId);
516 void checkAlignmentProgress(ModelId);
517
516 int getProgressBarWidth() const; // if visible 518 int getProgressBarWidth() const; // if visible
517 519
518 int effectiveDevicePixelRatio() const; 520 int effectiveDevicePixelRatio() const;
519 521
520 sv_frame_t m_centreFrame; 522 sv_frame_t m_centreFrame;
549 mutable LayerList m_lastNonScrollableBackLayers; 551 mutable LayerList m_lastNonScrollableBackLayers;
550 552
551 struct ProgressBarRec { 553 struct ProgressBarRec {
552 QPushButton *cancel; 554 QPushButton *cancel;
553 QProgressBar *bar; 555 QProgressBar *bar;
554 int lastCheck; 556 int lastStallCheckValue;
555 QTimer *checkTimer; 557 QTimer *stallCheckTimer;
556 }; 558 };
557 typedef std::map<Layer *, ProgressBarRec> ProgressMap; 559 typedef std::map<Layer *, ProgressBarRec> ProgressMap;
558 ProgressMap m_progressBars; // I own the ProgressBars 560 ProgressMap m_progressBars; // I own the ProgressBarRecs and their contents
561
562 struct AlignmentProgressBarRec {
563 ModelId alignedModel;
564 QProgressBar *bar;
565 };
566 AlignmentProgressBarRec m_alignmentProgressBar;
559 567
560 ViewManager *m_manager; // I don't own this 568 ViewManager *m_manager; // I don't own this
561 ViewPropertyContainer *m_propertyContainer; // I own this 569 ViewPropertyContainer *m_propertyContainer; // I own this
562 }; 570 };
563 571