Blame view

build2/epsilon-master/apps/statistics/histogram_parameter_controller.h 1.08 KB
6663b6c9   adorian   projet complet av...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
  #ifndef STATISTICS_HISTOGRAM_PARAMETER_CONTROLLER_H
  #define STATISTICS_HISTOGRAM_PARAMETER_CONTROLLER_H
  
  #include <escher.h>
  #include "../shared/float_parameter_controller.h"
  #include "store.h"
  
  namespace Statistics {
  
  class HistogramParameterController : public Shared::FloatParameterController {
  public:
    HistogramParameterController(Responder * parentResponder, Store * store);
    const char * title() override;
    int numberOfRows() override { return 1+k_numberOfCells; }
    void willDisplayCellForIndex(HighlightCell * cell, int index) override;
  private:
    constexpr static int k_numberOfCells = 2;
    HighlightCell * reusableParameterCell(int index, int type) override;
    int reusableParameterCellCount(int type) override { return k_numberOfCells; }
    double parameterAtIndex(int index) override;
    bool setParameterAtIndex(int parameterIndex, double f) override;
    View * loadView() override;
    void unloadView(View * view) override;
    char m_draftTextBuffer[MessageTableCellWithEditableText::k_bufferLength];
    MessageTableCellWithEditableText * m_cells[k_numberOfCells];
    Store * m_store;
  };
  
  }
  
  #endif