Mercurial > hg > svgui
comparison view/View.h @ 808:40c6c9344ff6 warnfix_no_size_t
Merge from branch tony_integration
author | Chris Cannam |
---|---|
date | Wed, 18 Jun 2014 08:40:46 +0100 |
parents | 4c8ca536b54f edada332c374 |
children | 9ad718fdc369 |
comparison
equal
deleted
inserted
replaced
807:e4773943c9c1 | 808:40c6c9344ff6 |
---|---|
26 | 26 |
27 // #define DEBUG_VIEW_WIDGET_PAINT 1 | 27 // #define DEBUG_VIEW_WIDGET_PAINT 1 |
28 | 28 |
29 class Layer; | 29 class Layer; |
30 class ViewPropertyContainer; | 30 class ViewPropertyContainer; |
31 | |
32 class QPushButton; | |
31 | 33 |
32 #include <map> | 34 #include <map> |
33 #include <set> | 35 #include <set> |
34 | 36 |
35 /** | 37 /** |
307 virtual void selectionChanged(); | 309 virtual void selectionChanged(); |
308 virtual void toolModeChanged(); | 310 virtual void toolModeChanged(); |
309 virtual void overlayModeChanged(); | 311 virtual void overlayModeChanged(); |
310 virtual void zoomWheelsEnabledChanged(); | 312 virtual void zoomWheelsEnabledChanged(); |
311 | 313 |
314 virtual void cancelClicked(); | |
315 | |
312 virtual void progressCheckStalledTimerElapsed(); | 316 virtual void progressCheckStalledTimerElapsed(); |
313 | 317 |
314 protected: | 318 protected: |
315 View(QWidget *, bool showProgress); | 319 View(QWidget *, bool showProgress); |
316 virtual void paintEvent(QPaintEvent *e); | 320 virtual void paintEvent(QPaintEvent *e); |
350 int m_centreFrame; | 354 int m_centreFrame; |
351 int m_zoomLevel; | 355 int m_zoomLevel; |
352 bool m_followPan; | 356 bool m_followPan; |
353 bool m_followZoom; | 357 bool m_followZoom; |
354 PlaybackFollowMode m_followPlay; | 358 PlaybackFollowMode m_followPlay; |
355 int m_playPointerFrame; | 359 bool m_followPlayIsDetached; |
360 int m_playPointerFrame; | |
356 bool m_lightBackground; | 361 bool m_lightBackground; |
357 bool m_showProgress; | 362 bool m_showProgress; |
358 | 363 |
359 QPixmap *m_cache; | 364 QPixmap *m_cache; |
360 int m_cacheCentreFrame; | 365 int m_cacheCentreFrame; |
370 | 375 |
371 // caches for use in getScrollableBackLayers, getNonScrollableFrontLayers | 376 // caches for use in getScrollableBackLayers, getNonScrollableFrontLayers |
372 mutable LayerList m_lastScrollableBackLayers; | 377 mutable LayerList m_lastScrollableBackLayers; |
373 mutable LayerList m_lastNonScrollableBackLayers; | 378 mutable LayerList m_lastNonScrollableBackLayers; |
374 | 379 |
375 class LayerProgressBar : public QProgressBar { | |
376 public: | |
377 LayerProgressBar(QWidget *parent); | |
378 virtual QString text() const { return m_text; } | |
379 virtual void setText(QString text) { m_text = text; } | |
380 protected: | |
381 QString m_text; | |
382 }; | |
383 | |
384 struct ProgressBarRec { | 380 struct ProgressBarRec { |
381 QPushButton *cancel; | |
385 QProgressBar *bar; | 382 QProgressBar *bar; |
386 int lastCheck; | 383 int lastCheck; |
387 QTimer *checkTimer; | 384 QTimer *checkTimer; |
388 }; | 385 }; |
389 typedef std::map<Layer *, ProgressBarRec> ProgressMap; | 386 typedef std::map<Layer *, ProgressBarRec> ProgressMap; |