MCPcopy Create free account
hub / github.com/DreamSourceLab/DSView / MainWindow

Method MainWindow

DSView/pv/mainwindow.cpp:114–143  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

112 }
113
114 MainWindow::MainWindow(toolbars::TitleBar *title_bar, QWidget *parent)
115 : QMainWindow(parent)
116 {
117 _msg = NULL;
118 _frame = parent;
119
120 assert(title_bar);
121 assert(_frame);
122
123 _title_bar = title_bar;
124
125 _session = AppControl::Instance()->GetSession();
126 _session->set_callback(this);
127 _device_agent = _session->get_device();
128 _session->add_msg_listener(this);
129
130 _is_auto_switch_device = false;
131 _is_save_confirm_msg = false;
132
133 _pattern_mode = "random";
134
135 setup_ui();
136
137 setContextMenuPolicy(Qt::NoContextMenu);
138
139 _key_vaild = false;
140 _last_key_press_time = high_resolution_clock::now();
141
142 update_title_bar_text();
143 }
144
145 void MainWindow::setup_ui()
146 {

Callers

nothing calls this directly

Calls 4

GetSessionMethod · 0.80
get_deviceMethod · 0.80
add_msg_listenerMethod · 0.80
set_callbackMethod · 0.45

Tested by

no test coverage detected