Mercurial > hg > svgui
comparison widgets/CSVFormatDialog.h @ 1318:b149b53df365 import-audio-data
Support audio-format CSV format selection in dialog
author | Chris Cannam |
---|---|
date | Thu, 06 Sep 2018 11:49:31 +0100 |
parents | fcc1f45f7bd5 |
children | fbda05431ce0 |
comparison
equal
deleted
inserted
replaced
1317:c2fa7bb1eca9 | 1318:b149b53df365 |
---|---|
27 class CSVFormatDialog : public QDialog | 27 class CSVFormatDialog : public QDialog |
28 { | 28 { |
29 Q_OBJECT | 29 Q_OBJECT |
30 | 30 |
31 public: | 31 public: |
32 CSVFormatDialog(QWidget *parent, CSVFormat initialFormat, | 32 CSVFormatDialog(QWidget *parent, |
33 CSVFormat initialFormat, | |
33 int maxDisplayCols = 5); | 34 int maxDisplayCols = 5); |
34 ~CSVFormatDialog(); | 35 ~CSVFormatDialog(); |
35 | 36 |
36 CSVFormat getFormat() const; | 37 CSVFormat getFormat() const; |
37 | 38 |
43 | 44 |
44 void updateFormatFromDialog(); | 45 void updateFormatFromDialog(); |
45 void updateModelLabel(); | 46 void updateModelLabel(); |
46 | 47 |
47 protected: | 48 protected: |
49 enum DialogType { | |
50 AnnotationDataDialog, | |
51 AudioDataDialog | |
52 }; | |
53 DialogType m_dialogType; | |
54 | |
48 CSVFormat m_format; | 55 CSVFormat m_format; |
49 int m_maxDisplayCols; | 56 int m_maxDisplayCols; |
50 | 57 |
51 enum TimingOption { | 58 enum TimingOption { |
52 TimingExplicitSeconds = 0, | 59 TimingExplicitSeconds = 0, |
53 TimingExplicitMsec, | 60 TimingExplicitMsec, |
54 TimingExplicitSamples, | 61 TimingExplicitSamples, |
55 TimingImplicit | 62 TimingImplicit |
56 }; | 63 }; |
57 std::map<TimingOption, QString> m_timingLabels; | 64 std::map<TimingOption, QString> m_timingLabels; |
58 TimingOption m_initialTimingOption; | 65 TimingOption m_initialTimingOption; |
59 | 66 |
67 void columnPurposeChangedForAnnotationType(QComboBox *, int purpose); | |
60 void updateComboVisibility(); | 68 void updateComboVisibility(); |
61 void applyStartTimePurpose(); | 69 void applyStartTimePurpose(); |
62 void removeStartTimePurpose(); | 70 void removeStartTimePurpose(); |
63 | 71 |
64 QComboBox *m_timingTypeCombo; | 72 QComboBox *m_timingTypeCombo; |