Wireshark  4.3.0
The Wireshark network protocol analyzer
lte_rlc_graph_dialog.h
Go to the documentation of this file.
1 
10 #ifndef LTE_RLC_GRAPH_DIALOG_H
11 #define LTE_RLC_GRAPH_DIALOG_H
12 
13 #include "wireshark_dialog.h"
14 #include <ui/tap-rlc-graph.h>
15 
16 #include <ui/qt/widgets/qcustomplot.h>
17 
18 class QMenu;
19 class QRubberBand;
20 
21 namespace Ui {
22 class LteRlcGraphDialog;
23 }
24 
26 {
27  Q_OBJECT
28 
29 public:
30  // TODO: will need to add another constructor option to give channel explicitly,
31  // rather than find in currently selected packet, for when launch graph from
32  // RLC statistics dialog.
33  explicit LteRlcGraphDialog(QWidget &parent, CaptureFile &cf, bool channelKnown);
35 
36  void setChannelInfo(uint8_t rat, uint16_t ueid, uint8_t rlcMode,
37  uint16_t channelType, uint16_t channelId, uint8_t direction,
38  bool maybe_empty=false);
39 
40 signals:
41  void goToPacket(int packet_num);
42 
43 protected:
44  void showEvent(QShowEvent *event);
45  void keyPressEvent(QKeyEvent *event);
46 
47 private:
48  Ui::LteRlcGraphDialog *ui;
49  bool mouse_drags_;
50  QRubberBand *rubber_band_;
51  QPoint rb_origin_;
52  QMenu *ctx_menu_;
53 
54  // Data gleaned directly from tapping packets
55  struct rlc_graph graph_;
56 
57  // Data
58  QMultiMap<double, struct rlc_segment *> time_stamp_map_; // used for mapping clicks back to segment/frame
59  QMap<double, struct rlc_segment *> sequence_num_map_;
60 
61  QCPGraph *base_graph_; // Data SNs - clickable packets
62  QCPGraph *reseg_graph_;
63  QCPGraph *acks_graph_;
64  QCPGraph *nacks_graph_;
65  QCPItemTracer *tracer_;
66  uint32_t packet_num_;
67 
68  void completeGraph(bool may_be_empty=false);
69 
70  bool compareHeaders(rlc_segment *seg);
71 
72  void findChannel(bool may_fail=false);
73  void fillGraph();
74 
75  void zoomAxes(bool in);
76  void zoomXAxis(bool in);
77  void zoomYAxis(bool in);
78 
79  void panAxes(int x_pixels, int y_pixels);
80  QRectF getZoomRanges(QRect zoom_rect);
81 
82  void toggleTracerStyle(bool force_default);
83 
84 private slots:
85  void showContextMenu(const QPoint &pos);
86  void graphClicked(QMouseEvent *event);
87  void mouseMoved(QMouseEvent *event);
88  void mouseReleased(QMouseEvent *event);
89  void resetAxes();
90 
91  void on_dragRadioButton_toggled(bool checked);
92  void on_zoomRadioButton_toggled(bool checked);
93  void on_resetButton_clicked();
94  void on_otherDirectionButton_clicked();
95 
96  void on_actionReset_triggered();
97  void on_actionZoomIn_triggered();
98  void on_actionZoomOut_triggered();
99  void on_actionMoveUp10_triggered();
100  void on_actionMoveLeft10_triggered();
101  void on_actionMoveRight10_triggered();
102  void on_actionMoveDown10_triggered();
103  void on_actionMoveUp1_triggered();
104  void on_actionMoveLeft1_triggered();
105  void on_actionMoveRight1_triggered();
106  void on_actionMoveDown1_triggered();
107  void on_actionDragZoom_triggered();
108  void on_actionMoveUp100_triggered();
109  void on_actionMoveDown100_triggered();
110  void on_actionGoToPacket_triggered();
111  void on_actionCrosshairs_triggered();
112  void on_actionSwitchDirection_triggered();
113 
114  void on_buttonBox_accepted();
115 };
116 
117 #endif // LTE_RLC_GRAPH_DIALOG_H
Definition: capture_file.h:21
Definition: lte_rlc_graph_dialog.h:26
Definition: wireshark_dialog.h:35
Definition: tap-rlc-graph.h:56
Definition: packet-rlc-lte.c:380