projects
/
pulseview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
4e7f5ba
)
Session: Renamed pv::SigSession to Session
author
Joel Holdsworth
<joel@airwebreathe.org.uk>
Sat, 22 Nov 2014 16:02:34 +0000
(16:02 +0000)
committer
Joel Holdsworth
<joel@airwebreathe.org.uk>
Sat, 22 Nov 2014 16:02:34 +0000
(16:02 +0000)
30 files changed:
pv/data/decoderstack.cpp
patch
|
blob
|
history
pv/data/decoderstack.hpp
patch
|
blob
|
history
pv/devicemanager.hpp
patch
|
blob
|
history
pv/dialogs/storeprogress.cpp
patch
|
blob
|
history
pv/dialogs/storeprogress.hpp
patch
|
blob
|
history
pv/mainwindow.cpp
patch
|
blob
|
history
pv/mainwindow.hpp
patch
|
blob
|
history
pv/popups/channels.cpp
patch
|
blob
|
history
pv/popups/channels.hpp
patch
|
blob
|
history
pv/sigsession.cpp
patch
|
blob
|
history
pv/sigsession.hpp
patch
|
blob
|
history
pv/storesession.cpp
patch
|
blob
|
history
pv/storesession.hpp
patch
|
blob
|
history
pv/toolbars/samplingbar.cpp
patch
|
blob
|
history
pv/toolbars/samplingbar.hpp
patch
|
blob
|
history
pv/view/analogsignal.cpp
patch
|
blob
|
history
pv/view/analogsignal.hpp
patch
|
blob
|
history
pv/view/decodetrace.cpp
patch
|
blob
|
history
pv/view/decodetrace.hpp
patch
|
blob
|
history
pv/view/logicsignal.cpp
patch
|
blob
|
history
pv/view/logicsignal.hpp
patch
|
blob
|
history
pv/view/rowitemowner.hpp
patch
|
blob
|
history
pv/view/signal.cpp
patch
|
blob
|
history
pv/view/signal.hpp
patch
|
blob
|
history
pv/view/tracegroup.cpp
patch
|
blob
|
history
pv/view/tracegroup.hpp
patch
|
blob
|
history
pv/view/view.cpp
patch
|
blob
|
history
pv/view/view.hpp
patch
|
blob
|
history
pv/view/viewport.hpp
patch
|
blob
|
history
test/data/decoderstack.cpp
patch
|
blob
|
history
diff --git
a/pv/data/decoderstack.cpp
b/pv/data/decoderstack.cpp
index 5e30faa73c810e7d64e9bfb936e7cb6e8656daa8..da831e3be097fe6446bb688ae953860f9964ef10 100644
(file)
--- a/
pv/data/decoderstack.cpp
+++ b/
pv/data/decoderstack.cpp
@@
-59,7
+59,7
@@
const unsigned int DecoderStack::DecodeNotifyPeriod = 65536;
mutex DecoderStack::global_decode_mutex_;
mutex DecoderStack::global_decode_mutex_;
-DecoderStack::DecoderStack(pv::S
igS
ession &session,
+DecoderStack::DecoderStack(pv::Session &session,
const srd_decoder *const dec) :
session_(session),
sample_count_(0),
const srd_decoder *const dec) :
session_(session),
sample_count_(0),
diff --git
a/pv/data/decoderstack.hpp
b/pv/data/decoderstack.hpp
index 979a56fa0699f306075609f1e5959cbd65056624..e8aeed10f2b09da3db62e8fbc82c317c383ed536 100644
(file)
--- a/
pv/data/decoderstack.hpp
+++ b/
pv/data/decoderstack.hpp
@@
-50,7
+50,7
@@
struct TwoDecoderStack;
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
namespace view {
class LogicSignal;
namespace view {
class LogicSignal;
@@
-78,7
+78,7
@@
private:
static const unsigned int DecodeNotifyPeriod;
public:
static const unsigned int DecodeNotifyPeriod;
public:
- DecoderStack(pv::S
igS
ession &session_,
+ DecoderStack(pv::Session &session_,
const srd_decoder *const decoder);
virtual ~DecoderStack();
const srd_decoder *const decoder);
virtual ~DecoderStack();
@@
-129,7
+129,7
@@
Q_SIGNALS:
void new_decode_data();
private:
void new_decode_data();
private:
- pv::S
igS
ession &session_;
+ pv::Session &session_;
/**
* This mutex prevents more than one decode operation occuring
/**
* This mutex prevents more than one decode operation occuring
diff --git
a/pv/devicemanager.hpp
b/pv/devicemanager.hpp
index 823cb2bc9542ee8632690be4780db421a8bcc1de..fa116223305a179884c27d400d76b25c53e87caa 100644
(file)
--- a/
pv/devicemanager.hpp
+++ b/
pv/devicemanager.hpp
@@
-40,7
+40,7
@@
namespace sigrok {
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
class DeviceManager
{
class DeviceManager
{
diff --git
a/pv/dialogs/storeprogress.cpp
b/pv/dialogs/storeprogress.cpp
index 7cc40a75667994405d4ab26a937872ddb4819128..b041dcdb1508455576399f824121c8598db743c8 100644
(file)
--- a/
pv/dialogs/storeprogress.cpp
+++ b/
pv/dialogs/storeprogress.cpp
@@
-28,7
+28,7
@@
namespace pv {
namespace dialogs {
StoreProgress::StoreProgress(const QString &file_name,
namespace dialogs {
StoreProgress::StoreProgress(const QString &file_name,
- const S
igS
ession &session, QWidget *parent) :
+ const Session &session, QWidget *parent) :
QProgressDialog(tr("Saving..."), tr("Cancel"), 0, 0, parent),
session_(file_name.toStdString(), session)
{
QProgressDialog(tr("Saving..."), tr("Cancel"), 0, 0, parent),
session_(file_name.toStdString(), session)
{
diff --git
a/pv/dialogs/storeprogress.hpp
b/pv/dialogs/storeprogress.hpp
index ca14dfb21182b4846707b5f29fbfe9f8b1b24f4b..92634b4247110d1c781d78ccaaa3d188d388914f 100644
(file)
--- a/
pv/dialogs/storeprogress.hpp
+++ b/
pv/dialogs/storeprogress.hpp
@@
-30,7
+30,7
@@
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
namespace dialogs {
namespace dialogs {
@@
-39,7
+39,7
@@
class StoreProgress : public QProgressDialog
Q_OBJECT
public:
Q_OBJECT
public:
- StoreProgress(const QString &file_name, const S
igS
ession &session,
+ StoreProgress(const QString &file_name, const Session &session,
QWidget *parent = 0);
virtual ~StoreProgress();
QWidget *parent = 0);
virtual ~StoreProgress();
diff --git
a/pv/mainwindow.cpp
b/pv/mainwindow.cpp
index 97717b5abe3493fd16ec2f285cd11955c5ce18a3..f9aa81dfdc4e7bc2e4e843543091709821d96a0a 100644
(file)
--- a/
pv/mainwindow.cpp
+++ b/
pv/mainwindow.cpp
@@
-98,13
+98,13
@@
MainWindow::MainWindow(DeviceManager &device_manager,
void MainWindow::run_stop()
{
switch(session_.get_capture_state()) {
void MainWindow::run_stop()
{
switch(session_.get_capture_state()) {
- case S
igS
ession::Stopped:
+ case Session::Stopped:
session_.start_capture([&](QString message) {
session_error("Capture failed", message); });
break;
session_.start_capture([&](QString message) {
session_error("Capture failed", message); });
break;
- case S
igS
ession::AwaitingTrigger:
- case S
igS
ession::Running:
+ case Session::AwaitingTrigger:
+ case Session::Running:
session_.stop_capture();
break;
}
session_.stop_capture();
break;
}
@@
-556,7
+556,7
@@
void MainWindow::add_decoder(srd_decoder *decoder)
void MainWindow::capture_state_changed(int state)
{
void MainWindow::capture_state_changed(int state)
{
- sampling_bar_->set_capture_state((pv::S
igS
ession::capture_state)state);
+ sampling_bar_->set_capture_state((pv::Session::capture_state)state);
}
void MainWindow::device_selected()
}
void MainWindow::device_selected()
diff --git
a/pv/mainwindow.hpp
b/pv/mainwindow.hpp
index eee1d855d072c561e123c935aca1301bb0168c56..c7859d0a4cb43ec9f7256d8fcdaf5153c4e931a6 100644
(file)
--- a/
pv/mainwindow.hpp
+++ b/
pv/mainwindow.hpp
@@
-120,7
+120,7
@@
private:
DeviceManager &device_manager_;
DeviceManager &device_manager_;
- S
igS
ession session_;
+ Session session_;
pv::view::View *view_;
pv::view::View *view_;
diff --git
a/pv/popups/channels.cpp
b/pv/popups/channels.cpp
index 4598f1239185219a9ce088ae7dccbd4d16ada088..f8061d9ac2c3514ba72cf2bea5cc06a316373238 100644
(file)
--- a/
pv/popups/channels.cpp
+++ b/
pv/popups/channels.cpp
@@
-53,7
+53,7
@@
using pv::view::Signal;
namespace pv {
namespace popups {
namespace pv {
namespace popups {
-Channels::Channels(S
igS
ession &session, QWidget *parent) :
+Channels::Channels(Session &session, QWidget *parent) :
Popup(parent),
session_(session),
updating_channels_(false),
Popup(parent),
session_(session),
updating_channels_(false),
diff --git
a/pv/popups/channels.hpp
b/pv/popups/channels.hpp
index e472fdffae05dece304a2c8330a2dac7d49fd164..0ebe333f5f4836484ebf547f364e735445e50338 100644
(file)
--- a/
pv/popups/channels.hpp
+++ b/
pv/popups/channels.hpp
@@
-41,7
+41,7
@@
namespace sigrok {
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
namespace prop {
namespace binding {
namespace prop {
namespace binding {
@@
-60,7
+60,7
@@
class Channels : public pv::widgets::Popup
Q_OBJECT
public:
Q_OBJECT
public:
- Channels(S
igS
ession &session_, QWidget *parent);
+ Channels(Session &session_, QWidget *parent);
private:
void set_all_channels(bool set);
private:
void set_all_channels(bool set);
@@
-81,7
+81,7
@@
private Q_SLOTS:
void disable_all_channels();
private:
void disable_all_channels();
private:
- pv::S
igS
ession &session_;
+ pv::Session &session_;
QFormLayout layout_;
QFormLayout layout_;
diff --git
a/pv/sigsession.cpp
b/pv/sigsession.cpp
index 80830214877148f38a6100c06dc43bbc56c0a134..87ba9afa5d484eace490524d5d9247a0ab5061ef 100644
(file)
--- a/
pv/sigsession.cpp
+++ b/
pv/sigsession.cpp
@@
-82,7
+82,7
@@
using Glib::VariantBase;
using Glib::Variant;
namespace pv {
using Glib::Variant;
namespace pv {
-S
igSession::Sig
Session(DeviceManager &device_manager) :
+S
ession::
Session(DeviceManager &device_manager) :
device_manager_(device_manager),
session_(device_manager.context()->create_session()),
capture_state_(Stopped)
device_manager_(device_manager),
session_(device_manager.context()->create_session()),
capture_state_(Stopped)
@@
-90,33
+90,33
@@
SigSession::SigSession(DeviceManager &device_manager) :
set_default_device();
}
set_default_device();
}
-S
igSession::~Sig
Session()
+S
ession::~
Session()
{
// Stop and join to the thread
stop_capture();
}
{
// Stop and join to the thread
stop_capture();
}
-DeviceManager& S
igS
ession::device_manager()
+DeviceManager& Session::device_manager()
{
return device_manager_;
}
{
return device_manager_;
}
-const DeviceManager& S
igS
ession::device_manager() const
+const DeviceManager& Session::device_manager() const
{
return device_manager_;
}
{
return device_manager_;
}
-const shared_ptr<sigrok::Session>& S
igS
ession::session() const
+const shared_ptr<sigrok::Session>& Session::session() const
{
return session_;
}
{
return session_;
}
-shared_ptr<Device> S
igS
ession::device() const
+shared_ptr<Device> Session::device() const
{
return device_;
}
{
return device_;
}
-void S
igS
ession::set_device(shared_ptr<Device> device)
+void Session::set_device(shared_ptr<Device> device)
{
// Ensure we are not capturing before setting the device
stop_capture();
{
// Ensure we are not capturing before setting the device
stop_capture();
@@
-157,7
+157,7
@@
void SigSession::set_device(shared_ptr<Device> device)
device_selected();
}
device_selected();
}
-void S
igS
ession::set_file(const string &name)
+void Session::set_file(const string &name)
{
session_ = device_manager_.context()->load_session(name);
device_ = session_->devices()[0];
{
session_ = device_manager_.context()->load_session(name);
device_ = session_->devices()[0];
@@
-171,7
+171,7
@@
void SigSession::set_file(const string &name)
device_selected();
}
device_selected();
}
-void S
igS
ession::set_default_device()
+void Session::set_default_device()
{
shared_ptr<HardwareDevice> default_device;
const list< shared_ptr<HardwareDevice> > &devices =
{
shared_ptr<HardwareDevice> default_device;
const list< shared_ptr<HardwareDevice> > &devices =
@@
-192,13
+192,13
@@
void SigSession::set_default_device()
}
}
}
}
-S
igSession::capture_state Sig
Session::get_capture_state() const
+S
ession::capture_state
Session::get_capture_state() const
{
lock_guard<mutex> lock(sampling_mutex_);
return capture_state_;
}
{
lock_guard<mutex> lock(sampling_mutex_);
return capture_state_;
}
-void S
igS
ession::start_capture(function<void (const QString)> error_handler)
+void Session::start_capture(function<void (const QString)> error_handler)
{
stop_capture();
{
stop_capture();
@@
-220,11
+220,11
@@
void SigSession::start_capture(function<void (const QString)> error_handler)
// Begin the session
sampling_thread_ = std::thread(
// Begin the session
sampling_thread_ = std::thread(
- &S
igS
ession::sample_thread_proc, this, device_,
+ &Session::sample_thread_proc, this, device_,
error_handler);
}
error_handler);
}
-void S
igS
ession::stop_capture()
+void Session::stop_capture()
{
if (get_capture_state() != Stopped)
session_->stop();
{
if (get_capture_state() != Stopped)
session_->stop();
@@
-234,7
+234,7
@@
void SigSession::stop_capture()
sampling_thread_.join();
}
sampling_thread_.join();
}
-set< shared_ptr<data::SignalData> > S
igS
ession::get_data() const
+set< shared_ptr<data::SignalData> > Session::get_data() const
{
shared_lock<shared_mutex> lock(signals_mutex_);
set< shared_ptr<data::SignalData> > data;
{
shared_lock<shared_mutex> lock(signals_mutex_);
set< shared_ptr<data::SignalData> > data;
@@
-246,18
+246,18
@@
set< shared_ptr<data::SignalData> > SigSession::get_data() const
return data;
}
return data;
}
-boost::shared_mutex& S
igS
ession::signals_mutex() const
+boost::shared_mutex& Session::signals_mutex() const
{
return signals_mutex_;
}
{
return signals_mutex_;
}
-const vector< shared_ptr<view::Signal> >& S
igS
ession::signals() const
+const vector< shared_ptr<view::Signal> >& Session::signals() const
{
return signals_;
}
#ifdef ENABLE_DECODE
{
return signals_;
}
#ifdef ENABLE_DECODE
-bool S
igS
ession::add_decoder(srd_decoder *const dec)
+bool Session::add_decoder(srd_decoder *const dec)
{
map<const srd_channel*, shared_ptr<view::LogicSignal> > channels;
shared_ptr<data::DecoderStack> decoder_stack;
{
map<const srd_channel*, shared_ptr<view::LogicSignal> > channels;
shared_ptr<data::DecoderStack> decoder_stack;
@@
-313,13
+313,13
@@
bool SigSession::add_decoder(srd_decoder *const dec)
return true;
}
return true;
}
-vector< shared_ptr<view::DecodeTrace> > S
igS
ession::get_decode_signals() const
+vector< shared_ptr<view::DecodeTrace> > Session::get_decode_signals() const
{
shared_lock<shared_mutex> lock(signals_mutex_);
return decode_traces_;
}
{
shared_lock<shared_mutex> lock(signals_mutex_);
return decode_traces_;
}
-void S
igS
ession::remove_decode_signal(view::DecodeTrace *signal)
+void Session::remove_decode_signal(view::DecodeTrace *signal)
{
for (auto i = decode_traces_.begin(); i != decode_traces_.end(); i++)
if ((*i).get() == signal)
{
for (auto i = decode_traces_.begin(); i != decode_traces_.end(); i++)
if ((*i).get() == signal)
@@
-331,7
+331,7
@@
void SigSession::remove_decode_signal(view::DecodeTrace *signal)
}
#endif
}
#endif
-void S
igS
ession::set_capture_state(capture_state state)
+void Session::set_capture_state(capture_state state)
{
lock_guard<mutex> lock(sampling_mutex_);
const bool changed = capture_state_ != state;
{
lock_guard<mutex> lock(sampling_mutex_);
const bool changed = capture_state_ != state;
@@
-340,7
+340,7
@@
void SigSession::set_capture_state(capture_state state)
capture_state_changed(state);
}
capture_state_changed(state);
}
-void S
igS
ession::update_signals(shared_ptr<Device> device)
+void Session::update_signals(shared_ptr<Device> device)
{
assert(device);
assert(capture_state_ == Stopped);
{
assert(device);
assert(capture_state_ == Stopped);
@@
-407,7
+407,7
@@
void SigSession::update_signals(shared_ptr<Device> device)
signals_changed();
}
signals_changed();
}
-shared_ptr<view::Signal> S
igS
ession::signal_from_channel(
+shared_ptr<view::Signal> Session::signal_from_channel(
shared_ptr<Channel> channel) const
{
lock_guard<boost::shared_mutex> lock(signals_mutex_);
shared_ptr<Channel> channel) const
{
lock_guard<boost::shared_mutex> lock(signals_mutex_);
@@
-419,7
+419,7
@@
shared_ptr<view::Signal> SigSession::signal_from_channel(
return shared_ptr<view::Signal>();
}
return shared_ptr<view::Signal>();
}
-void S
igS
ession::read_sample_rate(shared_ptr<Device> device)
+void Session::read_sample_rate(shared_ptr<Device> device)
{
const auto keys = device_->config_keys(ConfigKey::DEVICE_OPTIONS);
const auto iter = keys.find(ConfigKey::SAMPLERATE);
{
const auto keys = device_->config_keys(ConfigKey::DEVICE_OPTIONS);
const auto iter = keys.find(ConfigKey::SAMPLERATE);
@@
-436,7
+436,7
@@
void SigSession::read_sample_rate(shared_ptr<Device> device)
}
}
}
}
-void S
igS
ession::sample_thread_proc(shared_ptr<Device> device,
+void Session::sample_thread_proc(shared_ptr<Device> device,
function<void (const QString)> error_handler)
{
assert(device);
function<void (const QString)> error_handler)
{
assert(device);
@@
-465,12
+465,12
@@
void SigSession::sample_thread_proc(shared_ptr<Device> device,
}
}
}
}
-void S
igS
ession::feed_in_header(shared_ptr<Device> device)
+void Session::feed_in_header(shared_ptr<Device> device)
{
read_sample_rate(device);
}
{
read_sample_rate(device);
}
-void S
igS
ession::feed_in_meta(shared_ptr<Device> device,
+void Session::feed_in_meta(shared_ptr<Device> device,
shared_ptr<Meta> meta)
{
(void)device;
shared_ptr<Meta> meta)
{
(void)device;
@@
-489,13
+489,13
@@
void SigSession::feed_in_meta(shared_ptr<Device> device,
signals_changed();
}
signals_changed();
}
-void S
igS
ession::feed_in_frame_begin()
+void Session::feed_in_frame_begin()
{
if (cur_logic_snapshot_ || !cur_analog_snapshots_.empty())
frame_began();
}
{
if (cur_logic_snapshot_ || !cur_analog_snapshots_.empty())
frame_began();
}
-void S
igS
ession::feed_in_logic(shared_ptr<Logic> logic)
+void Session::feed_in_logic(shared_ptr<Logic> logic)
{
lock_guard<mutex> lock(data_mutex_);
{
lock_guard<mutex> lock(data_mutex_);
@@
-540,7
+540,7
@@
void SigSession::feed_in_logic(shared_ptr<Logic> logic)
data_received();
}
data_received();
}
-void S
igS
ession::feed_in_analog(shared_ptr<Analog> analog)
+void Session::feed_in_analog(shared_ptr<Analog> analog)
{
lock_guard<mutex> lock(data_mutex_);
{
lock_guard<mutex> lock(data_mutex_);
@@
-608,7
+608,7
@@
void SigSession::feed_in_analog(shared_ptr<Analog> analog)
data_received();
}
data_received();
}
-void S
igS
ession::data_feed_in(shared_ptr<Device> device, shared_ptr<Packet> packet)
+void Session::data_feed_in(shared_ptr<Device> device, shared_ptr<Packet> packet)
{
assert(device);
assert(packet);
{
assert(device);
assert(packet);
diff --git
a/pv/sigsession.hpp
b/pv/sigsession.hpp
index 5f613bf93af4fe5c6e87bef1509383e9c01be79b..c6a317def7b61b5f1b61a6bef5ffa65847372fc4 100644
(file)
--- a/
pv/sigsession.hpp
+++ b/
pv/sigsession.hpp
@@
-65,7
+65,7
@@
class LogicSignal;
class Signal;
}
class Signal;
}
-class S
igS
ession : public QObject
+class Session : public QObject
{
Q_OBJECT
{
Q_OBJECT
@@
-77,9
+77,9
@@
public:
};
public:
};
public:
- S
igS
ession(DeviceManager &device_manager);
+ Session(DeviceManager &device_manager);
- ~S
igS
ession();
+ ~Session();
DeviceManager& device_manager();
DeviceManager& device_manager();
diff --git
a/pv/storesession.cpp
b/pv/storesession.cpp
index 058b46a99ee8d1d5b6434cd33e6da93c91d080fd..f6fef4635c630fadcb772c14e1013b96c2d61a17 100644
(file)
--- a/
pv/storesession.cpp
+++ b/
pv/storesession.cpp
@@
-53,7
+53,7
@@
namespace pv {
const size_t StoreSession::BlockSize = 1024 * 1024;
StoreSession::StoreSession(const std::string &file_name,
const size_t StoreSession::BlockSize = 1024 * 1024;
StoreSession::StoreSession(const std::string &file_name,
- const S
igS
ession &session) :
+ const Session &session) :
file_name_(file_name),
session_(session),
interrupt_(false),
file_name_(file_name),
session_(session),
interrupt_(false),
diff --git
a/pv/storesession.hpp
b/pv/storesession.hpp
index 8eaddaa60f50ebb3138870a6463d5937973d5e54..62cf18958e251229e02b19abb29a189fd999dda1 100644
(file)
--- a/
pv/storesession.hpp
+++ b/
pv/storesession.hpp
@@
-36,7
+36,7
@@
class Output;
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
namespace data {
class LogicSnapshot;
namespace data {
class LogicSnapshot;
@@
-51,7
+51,7
@@
private:
public:
StoreSession(const std::string &file_name,
public:
StoreSession(const std::string &file_name,
- const S
igS
ession &session);
+ const Session &session);
~StoreSession();
~StoreSession();
@@
-73,7
+73,7
@@
Q_SIGNALS:
private:
const std::string file_name_;
private:
const std::string file_name_;
- const S
igS
ession &session_;
+ const Session &session_;
std::shared_ptr<sigrok::Output> output_;
std::shared_ptr<sigrok::Output> output_;
diff --git
a/pv/toolbars/samplingbar.cpp
b/pv/toolbars/samplingbar.cpp
index 2002dd237b4f88ce3dd5edb012ae6a1ee81b6c01..cddfa5f5d39f8d9a8b327038757e690d598d877e 100644
(file)
--- a/
pv/toolbars/samplingbar.cpp
+++ b/
pv/toolbars/samplingbar.cpp
@@
-56,7
+56,7
@@
const uint64_t SamplingBar::MinSampleCount = 100ULL;
const uint64_t SamplingBar::MaxSampleCount = 1000000000000ULL;
const uint64_t SamplingBar::DefaultSampleCount = 1000000;
const uint64_t SamplingBar::MaxSampleCount = 1000000000000ULL;
const uint64_t SamplingBar::DefaultSampleCount = 1000000;
-SamplingBar::SamplingBar(S
igS
ession &session, MainWindow &main_window) :
+SamplingBar::SamplingBar(Session &session, MainWindow &main_window) :
QToolBar("Sampling Bar", &main_window),
session_(session),
main_window_(main_window),
QToolBar("Sampling Bar", &main_window),
session_(session),
main_window_(main_window),
@@
-88,7
+88,7
@@
SamplingBar::SamplingBar(SigSession &session, MainWindow &main_window) :
sample_count_.show_min_max_step(0, UINT64_MAX, 1);
sample_count_.show_min_max_step(0, UINT64_MAX, 1);
- set_capture_state(pv::S
igS
ession::Stopped);
+ set_capture_state(pv::Session::Stopped);
configure_button_.setIcon(QIcon::fromTheme("configure",
QIcon(":/icons/configure.png")));
configure_button_.setIcon(QIcon::fromTheme("configure",
QIcon(":/icons/configure.png")));
@@
-153,11
+153,11
@@
shared_ptr<Device> SamplingBar::get_selected_device() const
return device_selector_.itemData(index).value<shared_ptr<Device>>();
}
return device_selector_.itemData(index).value<shared_ptr<Device>>();
}
-void SamplingBar::set_capture_state(pv::S
igS
ession::capture_state state)
+void SamplingBar::set_capture_state(pv::Session::capture_state state)
{
const QIcon *icons[] = {&icon_grey_, &icon_red_, &icon_green_};
run_stop_button_.setIcon(*icons[state]);
{
const QIcon *icons[] = {&icon_grey_, &icon_red_, &icon_green_};
run_stop_button_.setIcon(*icons[state]);
- run_stop_button_.setText((state == pv::S
igS
ession::Stopped) ?
+ run_stop_button_.setText((state == pv::Session::Stopped) ?
tr("Run") : tr("Stop"));
run_stop_button_.setShortcut(QKeySequence(Qt::Key_Space));
}
tr("Run") : tr("Stop"));
run_stop_button_.setShortcut(QKeySequence(Qt::Key_Space));
}
diff --git
a/pv/toolbars/samplingbar.hpp
b/pv/toolbars/samplingbar.hpp
index af2743118ad7441d1140869b5989632bb46e8762..25ce23ae9ccffb9463966652e988eb3d8092e9f4 100644
(file)
--- a/
pv/toolbars/samplingbar.hpp
+++ b/
pv/toolbars/samplingbar.hpp
@@
-46,7
+46,7
@@
class QAction;
namespace pv {
class MainWindow;
namespace pv {
class MainWindow;
-class S
igS
ession;
+class Session;
namespace toolbars {
namespace toolbars {
@@
-60,7
+60,7
@@
private:
static const uint64_t DefaultSampleCount;
public:
static const uint64_t DefaultSampleCount;
public:
- SamplingBar(S
igS
ession &session, pv::MainWindow &main_window);
+ SamplingBar(Session &session, pv::MainWindow &main_window);
void set_device_list(
const std::list< std::pair<std::shared_ptr<sigrok::Device>, std::string> > &devices,
void set_device_list(
const std::list< std::pair<std::shared_ptr<sigrok::Device>, std::string> > &devices,
@@
-68,7
+68,7
@@
public:
std::shared_ptr<sigrok::Device> get_selected_device() const;
std::shared_ptr<sigrok::Device> get_selected_device() const;
- void set_capture_state(pv::S
igS
ession::capture_state state);
+ void set_capture_state(pv::Session::capture_state state);
Q_SIGNALS:
void run_stop();
Q_SIGNALS:
void run_stop();
@@
-93,7
+93,7
@@
protected:
bool eventFilter(QObject *watched, QEvent *event);
private:
bool eventFilter(QObject *watched, QEvent *event);
private:
- S
igS
ession &session_;
+ Session &session_;
MainWindow &main_window_;
QComboBox device_selector_;
MainWindow &main_window_;
QComboBox device_selector_;
diff --git
a/pv/view/analogsignal.cpp
b/pv/view/analogsignal.cpp
index abbb94c57f1d94225db6ae7c53fb9c611899db68..8a19cc210180abeedaedeb6305e96942b046686a 100644
(file)
--- a/
pv/view/analogsignal.cpp
+++ b/
pv/view/analogsignal.cpp
@@
-53,7
+53,7
@@
const QColor AnalogSignal::SignalColours[4] = {
const float AnalogSignal::EnvelopeThreshold = 256.0f;
AnalogSignal::AnalogSignal(
const float AnalogSignal::EnvelopeThreshold = 256.0f;
AnalogSignal::AnalogSignal(
- pv::S
igS
ession &session,
+ pv::Session &session,
shared_ptr<Channel> channel,
shared_ptr<data::Analog> data) :
Signal(session, channel),
shared_ptr<Channel> channel,
shared_ptr<data::Analog> data) :
Signal(session, channel),
diff --git
a/pv/view/analogsignal.hpp
b/pv/view/analogsignal.hpp
index 91a8e5c2810665ea6a4f445b187426d0d66d5343..5295fe32eed6f6229d62b3abb5a79f632a393787 100644
(file)
--- a/
pv/view/analogsignal.hpp
+++ b/
pv/view/analogsignal.hpp
@@
-43,7
+43,7
@@
private:
static const float EnvelopeThreshold;
public:
static const float EnvelopeThreshold;
public:
- AnalogSignal(pv::S
igS
ession &session,
+ AnalogSignal(pv::Session &session,
std::shared_ptr<sigrok::Channel> channel,
std::shared_ptr<pv::data::Analog> data);
std::shared_ptr<sigrok::Channel> channel,
std::shared_ptr<pv::data::Analog> data);
diff --git
a/pv/view/decodetrace.cpp
b/pv/view/decodetrace.cpp
index 6947491a285ead6b3317e166e4ca645354d627c6..790589568582003b70f2ceb948a7803b4ae07fc1 100644
(file)
--- a/
pv/view/decodetrace.cpp
+++ b/
pv/view/decodetrace.cpp
@@
-123,7
+123,7
@@
const QColor DecodeTrace::OutlineColours[16] = {
QColor(0x6B, 0x23, 0x37)
};
QColor(0x6B, 0x23, 0x37)
};
-DecodeTrace::DecodeTrace(pv::S
igS
ession &session,
+DecodeTrace::DecodeTrace(pv::Session &session,
std::shared_ptr<pv::data::DecoderStack> decoder_stack, int index) :
Trace(QString::fromUtf8(
decoder_stack->stack().front()->decoder()->name)),
std::shared_ptr<pv::data::DecoderStack> decoder_stack, int index) :
Trace(QString::fromUtf8(
decoder_stack->stack().front()->decoder()->name)),
diff --git
a/pv/view/decodetrace.hpp
b/pv/view/decodetrace.hpp
index 0e2ce1464e2faf337b3fa37c0cf0c5283f5b6d55..e3d8d68c04feb45e50c8780f8f480dfa45b001b1 100644
(file)
--- a/
pv/view/decodetrace.hpp
+++ b/
pv/view/decodetrace.hpp
@@
-39,7
+39,7
@@
class QComboBox;
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
namespace data {
class DecoderStack;
namespace data {
class DecoderStack;
@@
-82,7
+82,7
@@
private:
static const QColor OutlineColours[16];
public:
static const QColor OutlineColours[16];
public:
- DecodeTrace(pv::S
igS
ession &session,
+ DecodeTrace(pv::Session &session,
std::shared_ptr<pv::data::DecoderStack> decoder_stack,
int index);
std::shared_ptr<pv::data::DecoderStack> decoder_stack,
int index);
@@
-192,7
+192,7
@@
private Q_SLOTS:
void on_show_hide_decoder(int index);
private:
void on_show_hide_decoder(int index);
private:
- pv::S
igS
ession &session_;
+ pv::Session &session_;
std::shared_ptr<pv::data::DecoderStack> decoder_stack_;
uint64_t decode_start_, decode_end_;
std::shared_ptr<pv::data::DecoderStack> decoder_stack_;
uint64_t decode_start_, decode_end_;
diff --git
a/pv/view/logicsignal.cpp
b/pv/view/logicsignal.cpp
index 5beb39df4fa6b4f126686b97aec6d35ecab731a2..b3901363548cff82686412fe070bad4f60c2d254 100644
(file)
--- a/
pv/view/logicsignal.cpp
+++ b/
pv/view/logicsignal.cpp
@@
-82,7
+82,7
@@
const QColor LogicSignal::SignalColours[10] = {
};
LogicSignal::LogicSignal(
};
LogicSignal::LogicSignal(
- pv::S
igS
ession &session,
+ pv::Session &session,
shared_ptr<Device> device,
shared_ptr<Channel> channel,
shared_ptr<data::Logic> data) :
shared_ptr<Device> device,
shared_ptr<Channel> channel,
shared_ptr<data::Logic> data) :
diff --git
a/pv/view/logicsignal.hpp
b/pv/view/logicsignal.hpp
index a4f64e6bddc83b09da242b85b94d9ee23d629775..0d422d7ce5b1534ef47b1b620f7b6f1d35d7ad5a 100644
(file)
--- a/
pv/view/logicsignal.hpp
+++ b/
pv/view/logicsignal.hpp
@@
-57,7
+57,7
@@
private:
static const QColor SignalColours[10];
public:
static const QColor SignalColours[10];
public:
- LogicSignal(pv::S
igS
ession &session,
+ LogicSignal(pv::Session &session,
std::shared_ptr<sigrok::Device> device,
std::shared_ptr<sigrok::Channel> channel,
std::shared_ptr<pv::data::Logic> data);
std::shared_ptr<sigrok::Device> device,
std::shared_ptr<sigrok::Channel> channel,
std::shared_ptr<pv::data::Logic> data);
diff --git
a/pv/view/rowitemowner.hpp
b/pv/view/rowitemowner.hpp
index 8c63aa565da3eb372df1a215a8a81d4db9784481..10d6e99ba3512bfc381f4d575fb3760e8aaa5b2d 100644
(file)
--- a/
pv/view/rowitemowner.hpp
+++ b/
pv/view/rowitemowner.hpp
@@
-28,7
+28,7
@@
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
namespace view {
namespace view {
@@
-46,12
+46,12
@@
public:
/**
* Returns the session of the onwer.
*/
/**
* Returns the session of the onwer.
*/
- virtual pv::S
igS
ession& session() = 0;
+ virtual pv::Session& session() = 0;
/**
* Returns the session of the owner.
*/
/**
* Returns the session of the owner.
*/
- virtual const pv::S
igS
ession& session() const = 0;
+ virtual const pv::Session& session() const = 0;
/**
* Returns the view of the owner.
/**
* Returns the view of the owner.
diff --git
a/pv/view/signal.cpp
b/pv/view/signal.cpp
index 35e1cdbfc840b1bb8e5fde6178f7dbfafc26b09e..767896f2ccda2d75b5063d55a0c17afaf6b7adda 100644
(file)
--- a/
pv/view/signal.cpp
+++ b/
pv/view/signal.cpp
@@
-58,7
+58,7
@@
const char *const ChannelNames[] = {
"SCL"
};
"SCL"
};
-Signal::Signal(pv::S
igS
ession &session,
+Signal::Signal(pv::Session &session,
std::shared_ptr<sigrok::Channel> channel) :
Trace(channel->name().c_str()),
session_(session),
std::shared_ptr<sigrok::Channel> channel) :
Trace(channel->name().c_str()),
session_(session),
diff --git
a/pv/view/signal.hpp
b/pv/view/signal.hpp
index dd3af0b3abc704d339859ecf4449eb23734e04da..910b2e699e055582466d2b59d0de8c6589a7495d 100644
(file)
--- a/
pv/view/signal.hpp
+++ b/
pv/view/signal.hpp
@@
-36,7
+36,7
@@
namespace sigrok {
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
namespace data {
class SignalData;
namespace data {
class SignalData;
@@
-49,7
+49,7
@@
class Signal : public Trace
Q_OBJECT
protected:
Q_OBJECT
protected:
- Signal(pv::S
igS
ession &session,
+ Signal(pv::Session &session,
std::shared_ptr<sigrok::Channel> channel);
public:
std::shared_ptr<sigrok::Channel> channel);
public:
@@
-79,7
+79,7
@@
private Q_SLOTS:
void on_disable();
protected:
void on_disable();
protected:
- pv::S
igS
ession &session_;
+ pv::Session &session_;
std::shared_ptr<sigrok::Channel> channel_;
QComboBox *name_widget_;
std::shared_ptr<sigrok::Channel> channel_;
QComboBox *name_widget_;
diff --git
a/pv/view/tracegroup.cpp
b/pv/view/tracegroup.cpp
index 665b4ad186c1403cb3a888f9f73e4e94851c37df..272fc1a1e3b341823e82133c099d4f35f392c617 100644
(file)
--- a/
pv/view/tracegroup.cpp
+++ b/
pv/view/tracegroup.cpp
@@
-52,13
+52,13
@@
bool TraceGroup::enabled() const
[](const shared_ptr<RowItem> &r) { return r->enabled(); });
}
[](const shared_ptr<RowItem> &r) { return r->enabled(); });
}
-pv::S
igS
ession& TraceGroup::session()
+pv::Session& TraceGroup::session()
{
assert(owner_);
return owner_->session();
}
{
assert(owner_);
return owner_->session();
}
-const pv::S
igS
ession& TraceGroup::session() const
+const pv::Session& TraceGroup::session() const
{
assert(owner_);
return owner_->session();
{
assert(owner_);
return owner_->session();
diff --git
a/pv/view/tracegroup.hpp
b/pv/view/tracegroup.hpp
index 960a15d9a23105bd314ae090bee1bc680792c816..f89ea437f33c8026ad1ab9898055bf145b9867d8 100644
(file)
--- a/
pv/view/tracegroup.hpp
+++ b/
pv/view/tracegroup.hpp
@@
-51,12
+51,12
@@
public:
/**
* Returns the session of the onwer.
*/
/**
* Returns the session of the onwer.
*/
- pv::S
igS
ession& session();
+ pv::Session& session();
/**
* Returns the session of the onwer.
*/
/**
* Returns the session of the onwer.
*/
- const pv::S
igS
ession& session() const;
+ const pv::Session& session() const;
/**
* Returns the view of the owner.
/**
* Returns the view of the owner.
diff --git
a/pv/view/view.cpp
b/pv/view/view.cpp
index d621e7143f8a2f189bd06329fb020d0cf26cfb7d..c96063536c0e917bc86336bbf2d7cb071a63b3c6 100644
(file)
--- a/
pv/view/view.cpp
+++ b/
pv/view/view.cpp
@@
-79,7
+79,7
@@
const QColor View::CursorAreaColour(220, 231, 243);
const QSizeF View::LabelPadding(4, 0);
const QSizeF View::LabelPadding(4, 0);
-View::View(S
igS
ession &session, QWidget *parent) :
+View::View(Session &session, QWidget *parent) :
QAbstractScrollArea(parent),
session_(session),
viewport_(new Viewport(*this)),
QAbstractScrollArea(parent),
session_(session),
viewport_(new Viewport(*this)),
@@
-149,12
+149,12
@@
View::View(SigSession &session, QWidget *parent) :
header_->raise();
}
header_->raise();
}
-S
igS
ession& View::session()
+Session& View::session()
{
return session_;
}
{
return session_;
}
-const S
igS
ession& View::session() const
+const Session& View::session() const
{
return session_;
}
{
return session_;
}
diff --git
a/pv/view/view.hpp
b/pv/view/view.hpp
index c6e585b7cbdd4cae86290b4e142395c908cb5fc9..e763da7e398a9b563b8fc5927088ad3ed391a2aa 100644
(file)
--- a/
pv/view/view.hpp
+++ b/
pv/view/view.hpp
@@
-39,7
+39,7
@@
namespace pv {
namespace pv {
-class S
igS
ession;
+class Session;
namespace view {
namespace view {
@@
-69,10
+69,10
@@
public:
static const QSizeF LabelPadding;
public:
static const QSizeF LabelPadding;
public:
- explicit View(S
igS
ession &session, QWidget *parent = 0);
+ explicit View(Session &session, QWidget *parent = 0);
- S
igS
ession& session();
- const S
igS
ession& session() const;
+ Session& session();
+ const Session& session() const;
/**
* Returns the view of the owner.
/**
* Returns the view of the owner.
@@
-236,7
+236,7
@@
private Q_SLOTS:
void on_hover_point_changed();
private:
void on_hover_point_changed();
private:
- S
igS
ession &session_;
+ Session &session_;
Viewport *viewport_;
Ruler *ruler_;
Viewport *viewport_;
Ruler *ruler_;
diff --git
a/pv/view/viewport.hpp
b/pv/view/viewport.hpp
index 1171a70730c8ed9490e5de549c19b46b250de8a0..07bfcad9c5263a49b2fa5d22e9992dbf0541add5 100644
(file)
--- a/
pv/view/viewport.hpp
+++ b/
pv/view/viewport.hpp
@@
-27,7
+27,7
@@
class QPainter;
class QPaintEvent;
class QPainter;
class QPaintEvent;
-class S
igS
ession;
+class Session;
namespace pv {
namespace view {
namespace pv {
namespace view {
diff --git
a/test/data/decoderstack.cpp
b/test/data/decoderstack.cpp
index 09f047d5d07549ce4d4e928f74d4801af2509e34..baeec2d6d11b69f36713d996b9991d86fc3cde07 100644
(file)
--- a/
test/data/decoderstack.cpp
+++ b/
test/data/decoderstack.cpp
@@
-49,7
+49,7
@@
BOOST_AUTO_TEST_CASE(TwoDecoderStack)
{
pv::DeviceManager dm(ctx);
{
pv::DeviceManager dm(ctx);
- pv::S
igS
ession ss(dm);
+ pv::Session ss(dm);
const GSList *l = srd_decoder_list();
BOOST_REQUIRE(l);
const GSList *l = srd_decoder_list();
BOOST_REQUIRE(l);