2
0
forked from Ivasoft/DSView

Merge remote-tracking branch 'source/dev-1.3' into demo

This commit is contained in:
yunyaobaihong
2023-05-22 09:14:41 +08:00
25 changed files with 267 additions and 309 deletions

View File

@@ -60,7 +60,7 @@ AppControl* AppControl::Instance()
}
void AppControl::Destroy(){
delete this;
}
bool AppControl::Init()

View File

@@ -540,7 +540,7 @@ void DecoderStack::decode_data(const uint64_t decode_start, const uint64_t decod
if (!bCheckEnd){
bCheckEnd = true;
uint64_t mipmap_sample_count = _snapshot->get_mipmap_sample_count();
uint64_t mipmap_sample_count = _snapshot->get_ring_sample_count();
if (end_index >= mipmap_sample_count){
end_index = mipmap_sample_count - 1;
@@ -548,14 +548,14 @@ void DecoderStack::decode_data(const uint64_t decode_start, const uint64_t decod
}
}
}
else if (i >= _snapshot->get_mipmap_sample_count())
else if (i >= _snapshot->get_ring_sample_count())
{
// Wait the data is ready.
std::this_thread::sleep_for(std::chrono::milliseconds(100));
continue;
}
if (_is_capture_end && i == _snapshot->get_mipmap_sample_count()){
if (_is_capture_end && i == _snapshot->get_ring_sample_count()){
break;
}
@@ -570,7 +570,7 @@ void DecoderStack::decode_data(const uint64_t decode_start, const uint64_t decod
}
else {
if (_snapshot->has_data(sig_index)) {
auto data_ptr = _snapshot->get_decode_samples(i, chunk_end, sig_index);
auto data_ptr = _snapshot->get_samples(i, chunk_end, sig_index);
chunk.push_back(data_ptr);
chunk_const.push_back(_snapshot->get_sample(i, sig_index));
}
@@ -663,7 +663,7 @@ void DecoderStack::execute_decode_stack()
assert(session);
// Get the intial sample count
_sample_count = _snapshot->get_mipmap_sample_count();
_sample_count = _snapshot->get_ring_sample_count();
// Create the decoders
for(auto dec : _stack)

View File

@@ -55,6 +55,7 @@ LogicSnapshot::LogicSnapshot() :
_total_sample_count = 0;
_is_loop = false;
_loop_offset = 0;
_able_free = true;
}
LogicSnapshot::~LogicSnapshot()
@@ -77,6 +78,11 @@ void LogicSnapshot::free_data()
}
_ch_data.clear();
_sample_count = 0;
for(void *p : _free_block_list){
free(p);
}
_free_block_list.clear();
}
void LogicSnapshot::init()
@@ -94,8 +100,8 @@ void LogicSnapshot::init_all()
_dest_ptr = NULL;
_memory_failed = false;
_last_ended = true;
_mipmap_sample_count = 0;
_loop_offset = 0;
_able_free = true;
}
void LogicSnapshot::clear()
@@ -106,10 +112,16 @@ void LogicSnapshot::clear()
_have_data = false;
}
void LogicSnapshot::first_payload(const sr_datafeed_logic &logic, uint64_t total_sample_count, GSList *channels)
void LogicSnapshot::first_payload(const sr_datafeed_logic &logic, uint64_t total_sample_count, GSList *channels, bool able_free)
{
bool channel_changed = false;
uint16_t channel_num = 0;
_able_free = able_free;
for(void *p : _free_block_list){
free(p);
}
_free_block_list.clear();
for (const GSList *l = channels; l; l = l->next) {
sr_channel *const probe = (sr_channel*)l->data;
@@ -172,7 +184,6 @@ void LogicSnapshot::first_payload(const sr_datafeed_logic &logic, uint64_t total
_sample_count = 0;
_ring_sample_count = 0;
_mipmap_sample_count = 0;
assert(logic.data);
uint64_t *rd_data = (uint64_t*)logic.data;
@@ -268,7 +279,6 @@ void LogicSnapshot::append_cross_payload(const sr_datafeed_logic &logic)
if (_ring_sample_count % LeafBlockSamples == 0){
calc_mipmap(_channel_num - 1, index0, index1, LeafBlockSamples, true);
_mipmap_sample_count = _ring_sample_count - _loop_offset;
}
break;
}
@@ -327,9 +337,6 @@ void LogicSnapshot::append_cross_payload(const sr_datafeed_logic &logic)
{
calc_mipmap(fill_chan, index0, index1, LeafBlockSamples, true);
if (fill_chan + 1 == _channel_num)
_mipmap_sample_count = _ring_sample_count - _loop_offset;
chans_read_addr[fill_chan] = read_ptr;
fill_chan = (fill_chan + 1) % _channel_num;
@@ -428,8 +435,6 @@ void LogicSnapshot::capture_ended()
Snapshot::capture_ended();
_sample_count = _ring_sample_count;
_mipmap_sample_count = _ring_sample_count;
_ring_sample_count += _loop_offset;
uint64_t index0 = _ring_sample_count / LeafBlockSamples / RootScale;
@@ -540,7 +545,12 @@ void LogicSnapshot::calc_mipmap(unsigned int order, uint8_t index0, uint8_t inde
_ch_data[order][index0].tog |= 1ULL << index1;
}
else if (isEnd){
free(_ch_data[order][index0].lbp[index1]);
if (_able_free)
free(_ch_data[order][index0].lbp[index1]);
else
_free_block_list.push_back(_ch_data[order][index0].lbp[index1]);
_ch_data[order][index0].lbp[index1] = NULL;
}
@@ -587,43 +597,6 @@ const uint8_t *LogicSnapshot::get_samples(uint64_t start_sample, uint64_t &end_s
return (uint8_t*)_ch_data[order][index0].lbp[index1] + offset;
}
const uint8_t *LogicSnapshot::get_decode_samples(uint64_t start_sample, uint64_t &end_sample, int sig_index)
{
std::lock_guard<std::mutex> lock(_mutex);
uint64_t sample_count = _mipmap_sample_count;
assert(start_sample < sample_count);
if (end_sample >= sample_count)
end_sample = sample_count - 1;
assert(end_sample <= sample_count);
assert(start_sample <= end_sample);
start_sample += _loop_offset;
_ring_sample_count += _loop_offset;
int order = get_ch_order(sig_index);
uint64_t index0 = start_sample >> (LeafBlockPower + RootScalePower);
uint64_t index1 = (start_sample & RootMask) >> LeafBlockPower;
uint64_t offset = (start_sample & LeafMask) / 8;
end_sample = (index0 << (LeafBlockPower + RootScalePower)) +
(index1 << LeafBlockPower) +
~(~0ULL << LeafBlockPower);
end_sample = min(end_sample + 1, sample_count);
end_sample -= _loop_offset;
_ring_sample_count -= _loop_offset;
if (order == -1 || _ch_data[order][index0].lbp[index1] == NULL)
return NULL;
else
return (uint8_t*)_ch_data[order][index0].lbp[index1] + offset;
}
bool LogicSnapshot::get_sample(uint64_t index, int sig_index)
{
index += _loop_offset;
@@ -1073,8 +1046,6 @@ bool LogicSnapshot::pattern_search_self(int64_t start, int64_t end, int64_t &ind
int count = 0;
bool bEdgeFlag = false;
int64_t to = isNext ? end + 1 : start - 1;
int64_t step = isNext ? 1 : -1;
@@ -1223,12 +1194,6 @@ int LogicSnapshot::get_ch_order(int sig_index)
return -1;
}
uint64_t LogicSnapshot::get_mipmap_sample_count()
{
std::lock_guard<std::mutex> lock(_mutex);
return _mipmap_sample_count;
}
void LogicSnapshot::move_first_node_to_last()
{
for (unsigned int i=0; i<_channel_num; i++)
@@ -1251,5 +1216,15 @@ void LogicSnapshot::move_first_node_to_last()
}
}
void LogicSnapshot::decode_end()
{
std::lock_guard<std::mutex> lock(_mutex);
for(void *p : _free_block_list){
free(p);
}
_free_block_list.clear();
}
} // namespace data
} // namespace pv

View File

@@ -90,14 +90,12 @@ public:
void init();
void first_payload(const sr_datafeed_logic &logic, uint64_t total_sample_count, GSList *channels);
void first_payload(const sr_datafeed_logic &logic, uint64_t total_sample_count, GSList *channels, bool able_free);
void append_payload(const sr_datafeed_logic &logic);
const uint8_t * get_samples(uint64_t start_sample, uint64_t& end_sample, int sig_index);
const uint8_t * get_decode_samples(uint64_t start_sample, uint64_t& end_sample, int sig_index);
bool get_sample(uint64_t index, int sig_index);
void capture_ended();
@@ -122,8 +120,6 @@ public:
bool pattern_search(int64_t start, int64_t end, int64_t& index,
std::map<uint16_t, QString> &pattern, bool isNext);
uint64_t get_mipmap_sample_count();
inline void set_loop(bool bLoop){
_is_loop = bLoop;
}
@@ -132,6 +128,8 @@ public:
return _is_loop;
}
void decode_end();
private:
bool get_sample_self(uint64_t index, int sig_index);
bool get_nxt_edge_self(uint64_t &index, bool last_sample, uint64_t end,
@@ -144,6 +142,7 @@ private:
std::map<uint16_t, QString> &pattern, bool isNext);
int get_ch_order(int sig_index);
void calc_mipmap(unsigned int order, uint8_t index0, uint8_t index1, uint64_t samples, bool isEnd);
void append_cross_payload(const sr_datafeed_logic &logic);
@@ -215,9 +214,10 @@ private:
uint64_t _last_sample[CHANNEL_MAX_COUNT];
uint64_t _last_calc_count[CHANNEL_MAX_COUNT];
uint64_t _mipmap_sample_count;
bool _is_loop;
uint64_t _loop_offset;
bool _able_free;
std::vector<void*> _free_block_list;
friend class LogicSnapshotTest::Pow2;
friend class LogicSnapshotTest::Basic;

View File

@@ -33,8 +33,8 @@
#include "../dsvdef.h"
#include "../appcontrol.h"
#include "../sigsession.h"
#include "../ui/langresource.h"
#include "../ui/msgbox.h"
using namespace std;
@@ -383,14 +383,10 @@ void Calibration::reload_value()
void Calibration::on_reset()
{
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SET_DEF_CAL_SETTING),
"All calibration settings will become the defualt values!"));
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_ATTENTION), "Attention"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SET_DEF_CAL_SETTING), "All calibration settings will become the defualt values!"));
msg.mBox()->addButton(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_OK), "Ok"), QMessageBox::AcceptRole);
msg.mBox()->addButton(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CANCEL), "Cancel"), QMessageBox::RejectRole);
msg.mBox()->setIcon(QMessageBox::Warning);
if (msg.exec()) {
if (MsgBox::Confirm(strMsg)) {
_device_agent->set_config(NULL, NULL, SR_CONF_ZERO_DEFAULT,
g_variant_new_boolean(true));
reload_value();

View File

@@ -517,7 +517,7 @@ void DecoderOptionsDlg::on_trans_pramas()
AppConfig::Instance()._appOptions.transDecoderDlg = ck_box->isChecked();
AppConfig::Instance().SaveApp();
_is_reload_form = true;
this->close();
this->accept();
}
}//dialogs

View File

@@ -212,12 +212,8 @@ void DeviceOptions::accept()
QDialog::accept();
}
else {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_ATTENTION), "Attention"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_ALL_CHANNEL_DISABLE), "All channel disabled! Please enable at least one channel."));
msg.mBox()->addButton(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_OK), "Ok"), QMessageBox::AcceptRole);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_ALL_CHANNEL_DISABLE), "All channel disabled! Please enable at least one channel."));
MsgBox::Show(strMsg);
}
}
@@ -447,17 +443,14 @@ void DeviceOptions::zero_adj()
using namespace Qt;
QDialog::accept();
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_INFORMATION), "Information"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_AUTO_CALIB_START),
"Auto Calibration program will be started. Don't connect any probes. It can take a while!"));
msg.mBox()->addButton(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_OK), "Ok"), QMessageBox::AcceptRole);
msg.mBox()->addButton(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CANCEL), "Cancel") ,QMessageBox::RejectRole);
msg.mBox()->setIcon(QMessageBox::Information);
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_AUTO_CALIB_START),
"Auto Calibration program will be started. Don't connect any probes. \nIt can take a while!"));
bool bRet = MsgBox::Confirm(strMsg);
if (msg.exec()) {
if (bRet) {
_device_agent->set_config(NULL, NULL, SR_CONF_ZERO, g_variant_new_boolean(true));
} else {
}
else {
_device_agent->set_config(NULL, NULL, SR_CONF_ZERO, g_variant_new_boolean(false));
}
}
@@ -580,7 +573,7 @@ void DeviceOptions::channel_checkbox_clicked(QCheckBox *sc)
if (cur_ch_num > vld_ch_num) {
QString msg_str(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_MAX_CHANNEL_COUNT_WARNING), "max count of channels!"));
msg_str = msg_str.replace("{0}", QString::number(vld_ch_num) );
MsgBox::Show("", msg_str);
MsgBox::Show(msg_str);
sc->setChecked(false);
}

View File

@@ -233,16 +233,12 @@ void DsoTriggerDock::pos_changed(int pos)
ret = _session->get_device()->set_config(NULL, NULL,
SR_CONF_HORIZ_TRIGGERPOS,
g_variant_new_byte((uint8_t)pos));
if (!ret) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TRI_SET_ISSUE), "Trigger Setting Issue"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_HOR_TRI_POS_FAIL),
"Change horiz trigger position failed!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
if (!ret) {
if (_session->get_device()->is_hardware()){
msg.exec();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_HOR_TRI_POS_FAIL),
"Change horiz trigger position failed!"));
MsgBox::Show(strMsg);
}
return;
@@ -267,13 +263,9 @@ void DsoTriggerDock::hold_changed(int hold)
g_variant_new_uint64(holdoff));
if (!ret) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TRI_SET_ISSUE), "Trigger Setting Issue"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_TRI_HOLDOFF_TIME_FAIL),
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_TRI_HOLDOFF_TIME_FAIL),
"Change trigger hold off time failed!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
MsgBox::Show(strMsg);
}
}
@@ -284,13 +276,9 @@ void DsoTriggerDock::margin_changed(int margin)
SR_CONF_TRIGGER_MARGIN,
g_variant_new_byte(margin));
if (!ret) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText((L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TRI_SET_ISSUE), "Trigger Setting Issue")));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_SENSITIVITY_FAIL),
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_SENSITIVITY_FAIL),
"Change trigger value sensitivity failed!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
MsgBox::Show(strMsg);
}
}
@@ -303,7 +291,7 @@ void DsoTriggerDock::source_changed()
_ch0o1_radioButton->setChecked(false);
QString msg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_DISABLED_CHANNEL_TRIG), "Disabled channels cannot be used for triggering!"));
MsgBox::Show("", msg);
MsgBox::Show(msg);
}
int id = _source_group->checkedId();
@@ -315,13 +303,9 @@ void DsoTriggerDock::source_changed()
SR_CONF_TRIGGER_SOURCE,
g_variant_new_byte(id));
if (!ret) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TRI_SET_ISSUE), "Trigger Setting Issue"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_SOURCE_FAIL),
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_SOURCE_FAIL),
"Change trigger source failed!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
MsgBox::Show(strMsg);
}
}
@@ -370,13 +354,9 @@ void DsoTriggerDock::channel_changed(int ch)
SR_CONF_TRIGGER_CHANNEL,
g_variant_new_byte(_channel_comboBox->currentData().toInt()));
if (!ret) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TRI_SET_ISSUE), "Trigger Setting Issue"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_CHANNEL_FAIL),
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_CHANNEL_FAIL),
"Change trigger channel failed!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
MsgBox::Show(strMsg);
}
}
@@ -389,13 +369,9 @@ void DsoTriggerDock::type_changed()
SR_CONF_TRIGGER_SLOPE,
g_variant_new_byte(id));
if (!ret) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TRI_SET_ISSUE), "Trigger Setting Issue"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_TYPE_FAIL),
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_CHANGE_TYPE_FAIL),
"Change trigger type failed!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
MsgBox::Show(strMsg);
}
}

View File

@@ -33,13 +33,11 @@
#include "../data/snapshot.h"
#include "../dialogs/dsdialog.h"
#include "../dialogs/dsmessagebox.h"
#include "../config/appconfig.h"
#include "../ui/langresource.h"
#include "../ui/msgbox.h"
#include <QObject>
#include <QPainter>
#include <QMessageBox>
#include "../config/appconfig.h"
#include "../ui/langresource.h"
using namespace boost;
@@ -477,14 +475,9 @@ void MeasureDock::show_all_coursor()
auto &cursor_list = _view.get_cursorList();
if (cursor_list.empty()) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_INFORMATION), "Information"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_PLEASE_INSERT_CURSOR),
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_PLEASE_INSERT_CURSOR),
"Please insert cursor before using cursor measure."));
msg.mBox()->addButton(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_OK), "Ok"), QMessageBox::AcceptRole);
msg.mBox()->setIcon(QMessageBox::Information);
msg.exec();
MsgBox::Show(strMsg);
return;
}

View File

@@ -421,8 +421,9 @@ bool ProtocolDock::add_protocol_by_id(QString id, bool silent, std::list<pv::dat
return;
}
if (MsgBox::Confirm(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_DECODER_CONFIRM_DEL_ALL), "Are you sure to remove all decoder?"), this)){
del_all_protocol();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_DECODER_CONFIRM_DEL_ALL), "Are you sure to remove all decoder?"));
if (MsgBox::Confirm(strMsg, this)){
del_all_protocol();
}
}
@@ -842,8 +843,10 @@ void ProtocolDock::OnProtocolSetting(void *handle){
}
void ProtocolDock::OnProtocolDelete(void *handle){
if (!MsgBox::Confirm(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_DECODER_CONFIRM_DEL), "Are you sure to remove this decoder?"), this)){
return;
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_DECODER_CONFIRM_DEL), "Are you sure to remove this decoder?"));
if (!MsgBox::Confirm(strMsg, this)){
return;
}
for (auto it = _protocol_lay_items.begin(); it != _protocol_lay_items.end(); it++)

View File

@@ -39,8 +39,8 @@
#include <QtConcurrent/QtConcurrent>
#include <stdint.h>
#include "../config/appconfig.h"
#include "../ui/langresource.h"
#include "../ui/msgbox.h"
namespace pv {
namespace dock {
@@ -131,12 +131,8 @@ void SearchDock::on_previous()
const auto logic_snapshot = dynamic_cast<data::LogicSnapshot*>(snapshot);
if (logic_snapshot == NULL || logic_snapshot->empty()) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH), "Search"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_NO_SAMPLE_DATA), "No Sample data!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_NO_SAMPLE_DATA), "No Sample data!"));
MsgBox::Show(strMsg);
return;
}
@@ -144,14 +140,11 @@ void SearchDock::on_previous()
last_pos = _view.get_search_pos();
last_hit = _view.get_search_hit();
if (last_pos == 0) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH), "Search"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH_AT_START), "Search cursor at the start position!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH_AT_START), "Search cursor at the start position!"));
MsgBox::Show(strMsg);
return;
} else {
}
else {
QFuture<void> future;
future = QtConcurrent::run([&]{
last_pos -= last_hit;
@@ -171,12 +164,8 @@ void SearchDock::on_previous()
dlg.exec();
if (!ret) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH), "Search"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_PATTERN_NOT_FOUND), "Pattern not found!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_PATTERN_NOT_FOUND), "Pattern not found!"));
MsgBox::Show(strMsg);
return;
} else {
_view.set_search_pos(last_pos, true);
@@ -193,24 +182,16 @@ void SearchDock::on_next()
const auto logic_snapshot = dynamic_cast<data::LogicSnapshot*>(snapshot);
if (logic_snapshot == NULL || logic_snapshot->empty()) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH), "Search"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_NO_SAMPLE_DATA), "No Sample data!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_NO_SAMPLE_DATA), "No Sample data!"));
MsgBox::Show(strMsg);
return;
}
const int64_t end = logic_snapshot->get_sample_count() - 1;
last_pos = _view.get_search_pos() + _view.get_search_hit();
if (last_pos >= end) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH), "Search"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH_AT_END), "Search cursor at the end position!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH_AT_END), "Search cursor at the end position!"));
MsgBox::Show(strMsg);
return;
} else {
QFuture<void> future;
@@ -231,12 +212,8 @@ void SearchDock::on_next()
dlg.exec();
if (!ret) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SEARCH), "Search"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_PATTERN_NOT_FOUND), "Pattern not found!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_PATTERN_NOT_FOUND), "Pattern not found!"));
MsgBox::Show(strMsg);
return;
} else {
_view.set_search_pos(last_pos, true);

View File

@@ -34,12 +34,13 @@
#include <QApplication>
#include <math.h>
#include <libsigrok.h>
#include <QRegExp>
#include <QRegExpValidator>
#include "../config/appconfig.h"
#include "../deviceagent.h"
#include "../view/logicsignal.h"
#include "../ui/langresource.h"
#include <QRegExp>
#include <QRegExpValidator>
#include "../ui/msgbox.h"
namespace pv {
namespace dock {
@@ -199,13 +200,9 @@ void TriggerDock::adv_trigger()
}
if (stream) {
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TRIGGER), "Trigger"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_STREAM_NO_AD_TRIGGER),
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_STREAM_NO_AD_TRIGGER),
"Stream Mode Don't Support Advanced Trigger!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
MsgBox::Show(strMsg);
_simple_radioButton->setChecked(true);
}
else {
@@ -213,13 +210,9 @@ void TriggerDock::adv_trigger()
}
}
else if (_session->get_device()->is_file() == false){
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TRIGGER), "Trigger"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_AD_TRIGGER_NEED_HARDWARE),
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_AD_TRIGGER_NEED_HARDWARE),
"Advanced Trigger need DSLogic Hardware Support!"));
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
MsgBox::Show(strMsg);
_simple_radioButton->setChecked(true);
}
}

View File

@@ -26,8 +26,7 @@
class ISessionCallback
{
public:
virtual void show_error(QString error)=0;
public:
virtual void session_error()=0;
virtual void session_save()=0;
virtual void data_updated()=0;
@@ -47,6 +46,7 @@ public:
virtual void receive_header()=0;
virtual void trigger_message(int msg)=0;
virtual void delay_prop_msg(QString strMsg)=0;
};
class ISessionDataGetter

View File

@@ -42,6 +42,7 @@
#include <QTextStream>
#include <QJsonValue>
#include <QJsonArray>
#include <functional>
#include <QDesktopWidget>
@@ -97,6 +98,7 @@
#include "ui/langresource.h"
#include "mainframe.h"
#include "dsvdef.h"
#include <thread>
namespace pv
{
@@ -283,6 +285,8 @@ namespace pv
//
connect(_dso_trigger_widget, SIGNAL(set_trig_pos(int)), _view, SLOT(set_trig_pos(int)));
_delay_prop_msg_timer.SetCallback(std::bind(&MainWindow::on_delay_prop_msg, this));
_logo_bar->set_mainform_callback(this);
// Try load from file.
@@ -329,17 +333,14 @@ namespace pv
_session->set_file(file_name);
}
catch (QString e)
{
show_error(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_FAIL_TO_LOAD), "Failed to load ") + file_name);
{
QString strMsg(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_FAIL_TO_LOAD), "Failed to load "));
strMsg += file_name;
MsgBox::Show(strMsg);
_session->set_default_device();
}
}
void MainWindow::show_error(QString error)
{
MsgBox::Show(NULL, error.toStdString().c_str(), this);
}
void MainWindow::session_error()
{
_event.session_error();
@@ -387,21 +388,10 @@ namespace pv
break;
}
dialogs::DSMessageBox msg(this);
connect(_session->device_event_object(), SIGNAL(device_updated()), &msg, SLOT(accept()));
QFont font("Monaco");
font.setStyleHint(QFont::Monospace);
font.setFixedPitch(true);
msg.mBox()->setFont(font);
msg.mBox()->setText(title);
msg.mBox()->setInformativeText(details);
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
dialogs::DSMessageBox *box = NULL;
MsgBox::Show("", title, details, this, &box, false);
connect(_session->device_event_object(), SIGNAL(device_updated()), box, SLOT(accept()));
box->exec();
_session->clear_error();
}
@@ -1483,9 +1473,11 @@ namespace pv
dsv_info("The cable's USB port version: %d.0", cable_ver);
if (usb30_support && usb_speed == LIBUSB_SPEED_HIGH)
show_error(L_S(STR_PAGE_DLG, S_ID(IDS_DLG_CHECK_USB_SPEED_ERROR),
"Plug it into a USB 2.0 port will seriously affect its performance.\nPlease replug it into a USB 3.0 port."));
if (usb30_support && usb_speed == LIBUSB_SPEED_HIGH){
QString str_err(L_S(STR_PAGE_DLG, S_ID(IDS_DLG_CHECK_USB_SPEED_ERROR),
"Plug the device into a USB 2.0 port will seriously affect its performance.\nPlease replug it into a USB 3.0 port."));
delay_prop_msg(str_err);
}
}
}
}
@@ -1558,8 +1550,9 @@ namespace pv
g_variant_unref(gvar);
if (version == 1)
{
show_error(L_S(STR_PAGE_DLG, S_ID(IDS_DLG_CHECK_SESSION_FILE_VERSION_ERROR),
QString strMsg(L_S(STR_PAGE_DLG, S_ID(IDS_DLG_CHECK_SESSION_FILE_VERSION_ERROR),
"Current loading file has an old format. \nThis will lead to a slow loading speed. \nPlease resave it after loaded."));
MsgBox::Show(strMsg);
}
}
}
@@ -1723,18 +1716,17 @@ namespace pv
break;
case DSV_MSG_CURRENT_DEVICE_CHANGE_PREV:
if (_msg != NULL){
_msg->close();
_msg = NULL;
}
_protocol_widget->del_all_protocol();
_view->reload();
break;
case DSV_MSG_CURRENT_DEVICE_CHANGED:
{
if (_msg != NULL)
{
_msg->close();
_msg = NULL;
}
reset_all_view();
load_device_config();
_sampling_bar->update_device_list();
@@ -1746,8 +1738,7 @@ namespace pv
if (_device_agent->is_hardware())
{
_session->on_load_config_end();
}
}
if (_device_agent->get_work_mode() == LOGIC && _device_agent->is_file() == false)
_view->auto_set_max_scale();
@@ -1853,6 +1844,11 @@ namespace pv
case DSV_MSG_NEW_USB_DEVICE:
{
if (_msg != NULL){
_msg->close();
_msg = NULL;
}
_sampling_bar->update_device_list();
if (_session->get_device()->is_demo() == false)
@@ -1890,17 +1886,21 @@ namespace pv
break;
case DSV_MSG_CURRENT_DEVICE_DETACHED:
if (_msg != NULL){
_msg->close();
_msg = NULL;
}
// Save current config, and switch to the last device.
_session->device_event_object()->device_updated();
session_save();
_view->hide_calibration();
if (confirm_to_store_data())
{
if (confirm_to_store_data()){
_is_auto_switch_device = true;
on_save();
}
else
{
else{
_session->set_default_device();
}
break;
@@ -1998,4 +1998,22 @@ namespace pv
}
}
void MainWindow::delay_prop_msg(QString strMsg)
{
_strMsg = strMsg;
if (_strMsg != ""){
_delay_prop_msg_timer.Start(500);
}
}
void MainWindow::on_delay_prop_msg()
{
_delay_prop_msg_timer.Stop();
if (_strMsg != ""){
MsgBox::Show("", _strMsg, this, &_msg);
_msg = NULL;
}
}
} // namespace pv

View File

@@ -32,6 +32,7 @@
#include "eventobject.h"
#include <QJsonDocument>
#include <chrono>
#include "dstimer.h"
class QAction;
class QMenuBar;
@@ -120,6 +121,7 @@ private slots:
void on_receive_data_len(quint64 len);
void on_cur_snap_samplerate_changed();
void on_trigger_message(int msg);
void on_delay_prop_msg();
signals:
void prgRate(int progress);
@@ -146,28 +148,26 @@ private:
QJsonDocument get_session_json_from_file(QString file);
QJsonArray get_decoder_json_from_file(QString file);
void calc_min_height();
void session_save();
private:
//ISessionCallback
void show_error(QString error);
//ISessionCallback
void session_error();
void data_updated();
void update_capture();
void cur_snap_samplerate_changed();
void cur_snap_samplerate_changed();
void signals_changed();
void receive_trigger(quint64 trigger_pos);
void frame_ended();
void frame_began();
void show_region(uint64_t start, uint64_t end, bool keep);
void show_wait_trigger();
void repeat_hold(int percent);
void decode_done();
void receive_data_len(quint64 len);
void receive_header();
void trigger_message(int msg);
void session_save();
void trigger_message(int msg);
void delay_prop_msg(QString strMsg);
//ISessionDataGetter
bool genSessionData(std::string &str);
@@ -223,6 +223,8 @@ private:
bool _is_save_confirm_msg;
std::string _pattern_mode;
QWidget *_frame;
DsTimer _delay_prop_msg_timer;
QString _strMsg;
int _key_value;
bool _key_vaild;

View File

@@ -125,8 +125,7 @@ namespace pv
_feed_timer.SetCallback(std::bind(&SigSession::feed_timeout, this));
_repeat_timer.SetCallback(std::bind(&SigSession::repeat_capture_wait_timeout, this));
_repeat_wait_prog_timer.SetCallback(std::bind(&SigSession::repeat_wait_prog_timeout, this));
_refresh_rt_timer.SetCallback(std::bind(&SigSession::realtime_refresh_timeout, this));
_delay_prop_msg_timer.SetCallback(std::bind(&SigSession::on_delay_prop_msg, this));
_refresh_rt_timer.SetCallback(std::bind(&SigSession::realtime_refresh_timeout, this));
}
SigSession::SigSession(SigSession &o)
@@ -216,6 +215,8 @@ namespace pv
assert(!_is_working);
assert(_callback);
ds_device_handle old_dev = _device_agent.handle();
set_operation_mode(OPT_SINGLE);
_callback->trigger_message(DSV_MSG_CURRENT_DEVICE_CHANGE_PREV);
@@ -225,8 +226,6 @@ namespace pv
_device_status = ST_INIT;
ds_device_handle old_dev = _device_agent.handle();
if (ds_active_device(dev_handle) != SR_OK)
{
dsv_err("%s", "Switch device error!");
@@ -259,13 +258,13 @@ namespace pv
if (_device_agent.is_hardware() && _device_agent.check_firmware_version() == false)
{
QString strMsg = L_S(STR_PAGE_MSG, S_ID(IDS_MSG_TO_RECONNECT_FOR_FIRMWARE), "Please reconnect the device!");
delay_prop_msg(strMsg);
_callback->delay_prop_msg(strMsg);
}
if (_device_agent.handle() != dev_handle && old_dev != NULL_HANDLE)
{
QString strMsg = L_S(STR_PAGE_MSG, S_ID(IDS_MSG_DEVICE_BUSY_SWITCH_FAILED), "Device is busy!");
MsgBox::Show("",strMsg);
MsgBox::Show(strMsg);
}
return true;
@@ -577,7 +576,7 @@ namespace pv
if (_device_agent.have_enabled_channel() == false)
{
QString err_str(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_NO_ENABLED_CHANNEL), "No channels enabled!"));
_callback->show_error(err_str);
MsgBox::Show(err_str);
return false;
}
@@ -1104,9 +1103,16 @@ namespace pv
}
if (_capture_data->get_logic()->last_ended())
{
{
_capture_data->get_logic()->set_loop(is_loop_mode());
_capture_data->get_logic()->first_payload(o, _device_agent.get_sample_limit(), _device_agent.get_channels());
bool bNotFree = _is_decoding && _view_data == _capture_data;
_capture_data->get_logic()->first_payload(o,
_device_agent.get_sample_limit(),
_device_agent.get_channels(),
!bNotFree);
// @todo Putting this here means that only listeners querying
// for logic will be notified. Currently the only user of
// frame_began is DecoderStack, but in future we need to signal
@@ -1851,8 +1857,10 @@ namespace pv
task = get_top_decode_task();
}
_view_data->get_logic()->decode_end();
dsv_info("%s", "------->decode thread end");
_is_decoding = false;
_is_decoding = false;
}
Snapshot *SigSession::get_signal_snapshot()
@@ -2288,20 +2296,4 @@ namespace pv
set_cur_samplelimits(_device_agent.get_sample_limit());
}
void SigSession::delay_prop_msg(QString strMsg)
{
_strMsg = strMsg;
if (_strMsg != ""){
_delay_prop_msg_timer.Start(1000);
}
}
void SigSession::on_delay_prop_msg()
{
_delay_prop_msg_timer.Stop();
if (_strMsg != "")
MsgBox::Show("", _strMsg);
}
} // namespace pv

View File

@@ -410,8 +410,7 @@ public:
}
void on_load_config_end();
void init_signals();
void delay_prop_msg(QString strMsg);
void init_signals();
inline bool is_doing_action(){
return _is_action;
@@ -496,8 +495,7 @@ private:
void repeat_wait_prog_timeout();
void realtime_refresh_timeout();
void clear_signals();
void on_delay_prop_msg();
void clear_signals();
inline void data_lock(){
_data_lock = true;
@@ -527,7 +525,7 @@ private:
DsTimer _repeat_timer;
DsTimer _repeat_wait_prog_timer;
DsTimer _refresh_rt_timer;
DsTimer _delay_prop_msg_timer;
int _noData_cnt;
bool _data_lock;
bool _data_updated;
@@ -562,7 +560,7 @@ private:
uint64_t _rt_ck_refresh_time_id;
COLLECT_OPT_MODE _opt_mode;
bool _is_stream_mode;
QString _strMsg;
bool _is_action;
uint64_t _dso_packet_count;

View File

@@ -889,15 +889,11 @@ namespace pv
if (zero)
{
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_AUTO_CALIB), "Auto Calibration"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_ADJUST_SAVE), "Please adjust zero skew and save the result"));
// msg.setStandardButtons(QMessageBox::Ok);
msg.mBox()->addButton(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_OK), "Ok"), QMessageBox::AcceptRole);
msg.mBox()->addButton(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_SKIP), "Skip"), QMessageBox::RejectRole);
msg.mBox()->setIcon(QMessageBox::Warning);
QString str1(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_AUTO_CALIB), "Auto Calibration"));
QString str2(L_S(STR_PAGE_MSG, S_ID(IDS_MSG_ADJUST_SAVE), "Please adjust zero skew and save the result"));
bool bRet = MsgBox::Confirm(str1, str2);
if (msg.exec())
if (bRet)
{
zero_adj();
}
@@ -960,15 +956,9 @@ namespace pv
if (zero)
{
dialogs::DSMessageBox msg(this);
msg.mBox()->setText(L_S(STR_PAGE_MSG,S_ID(IDS_MSG_AUTO_CALIB), "Auto Calibration"));
msg.mBox()->setInformativeText(L_S(STR_PAGE_MSG,S_ID(IDS_MSG_AUTO_CALIB_START), "Auto Calibration program will be started. Don't connect any probes. It can take a while!"));
QString strMsg(L_S(STR_PAGE_MSG,S_ID(IDS_MSG_AUTO_CALIB_START), "Auto Calibration program will be started. Don't connect any probes. \nIt can take a while!"));
msg.mBox()->addButton(L_S(STR_PAGE_MSG,S_ID(IDS_MSG_OK), "Ok"), QMessageBox::AcceptRole);
msg.mBox()->addButton(L_S(STR_PAGE_MSG,S_ID(IDS_MSG_SKIP), "Skip"), QMessageBox::RejectRole);
msg.mBox()->setIcon(QMessageBox::Warning);
if (msg.exec())
if (MsgBox::Confirm(strMsg))
{
zero_adj();
}

View File

@@ -32,7 +32,27 @@
//QMessageBox::information(NULL, "Title", "Content");
//QMessageBox::information(NULL, "Title", "Content",QMessageBox::Yes|QMessageBox::No|QMessageBox::Abort);
void MsgBox::Show(const QString text)
{
MsgBox::Show("", text, "", NULL, NULL, true);
}
void MsgBox::Show(const QString title, const QString text, QWidget *parent)
{
MsgBox::Show(title, text, "", parent,NULL, true);
}
void Show(const QString title, const QString text, const QString infoText)
{
MsgBox::Show(title, text, infoText, NULL, NULL, true);
}
void MsgBox::Show(const QString title, const QString text, QWidget *parent, pv::dialogs::DSMessageBox **box)
{
MsgBox::Show(title, text, "", parent, box, true);
}
void MsgBox::Show(const QString title, const QString text, const QString infoText, QWidget *parent, pv::dialogs::DSMessageBox **box, bool bExecute)
{
assert(!text.isEmpty());
@@ -45,14 +65,30 @@ void MsgBox::Show(const QString title, const QString text, QWidget *parent)
}
pv::dialogs::DSMessageBox msg(parent, title);
msg.mBox()->setText(str);
// msg.mBox()->setInformativeText(QString(text));
if (box != NULL){
*box = &msg;
}
msg.mBox()->setText(str);
msg.mBox()->setStandardButtons(QMessageBox::Ok);
msg.mBox()->setIcon(QMessageBox::Warning);
msg.exec();
if (infoText != ""){
msg.mBox()->setInformativeText(infoText);
}
if (bExecute){
msg.exec();
}
}
bool MsgBox::Confirm(const QString text, QWidget *parent)
{
return MsgBox::Confirm(text, "", parent);
}
bool MsgBox::Confirm(const QString text, const QString infoText, QWidget *parent)
{
assert(!text.isEmpty());
@@ -69,6 +105,11 @@ bool MsgBox::Confirm(const QString text, QWidget *parent)
msg.mBox()->setText(str);
msg.mBox()->setStandardButtons(QMessageBox::Yes | QMessageBox::No);
msg.mBox()->setIcon(QMessageBox::Question);
if (infoText != ""){
msg.mBox()->setInformativeText(infoText);
}
msg.exec();
return msg.IsYes();
}

View File

@@ -25,10 +25,21 @@
class QWidget;
namespace pv{
namespace dialogs{
class DSMessageBox;
}
}
class MsgBox
{
public:
static void Show(const QString text);
static void Show(const QString title, const QString text, QWidget *parent=0);
static void Show(const QString title, const QString text, const QString infoText);
static void Show(const QString title, const QString text, QWidget *parent, pv::dialogs::DSMessageBox **box);
static void Show(const QString title, const QString text, const QString infoText, QWidget *parent, pv::dialogs::DSMessageBox **box, bool bExecute=true);
static bool Confirm(const QString text, QWidget *parent=0);
static bool Confirm(const QString text, const QString infoText, QWidget *parent=0);
};

View File

@@ -697,7 +697,7 @@ bool DecodeTrace::create_popup(bool isnew)
dlg.get_cursor_range(_decode_cursor1, _decode_cursor2);
}
if (QDialog::Accepted == dlg_ret || dlg.is_reload_form() == false){
if (QDialog::Rejected == dlg_ret || dlg.is_reload_form() == false){
break;
}
}

View File

@@ -49,11 +49,11 @@
},
{
"id": "IDS_DLG_CHECK_USB_SPEED_ERROR",
"text": " 将其插入USB 2.0端口严重影响其性能.\n 请将其重新插入USB 3.0端口."
"text": "将该设备插入USB 2.0端口严重影响其性能.\n重新插入USB 3.0端口."
},
{
"id": "IDS_DLG_CHECK_SESSION_FILE_VERSION_ERROR",
"text": " 当前加载文件具有旧格式 . \n这将导致加载速度变慢. \n请在加载后重新保存."
"text": "当前加载文件具有旧格式 . \n这将导致加载速度变慢. \n请在加载后重新保存."
},
{
"id": "IDS_DLG_ABOUT",
@@ -89,7 +89,7 @@
},
{
"id": "IDS_DLG_SAVE_CALIBRATION_RESULTS",
"text": " 保存校准结果...可能需要一段时间."
"text": "保存校准结果...可能需要一段时间."
},
{
"id": "IDS_DLG_CANCEL",
@@ -97,7 +97,7 @@
},
{
"id": "IDS_DLG_RELOAD_CALIBRATION_RESULTS",
"text": " 重新加载上次校准...可能需要一段时间."
"text": "重新加载上次校准...可能需要一段时间."
},
{
"id": "IDS_DLG_DECODER_OPTIONS",
@@ -253,7 +253,7 @@
},
{
"id": "IDS_DLG_EXPORT_PROTOCOL_LIST_RESULT",
"text": " 导出协议列表结果...可能需要一段时间 ."
"text": "导出协议列表结果...可能需要一段时间 ."
},
{
"id": "IDS_DLG_FIT_TO_WINDOW",

View File

@@ -28,7 +28,7 @@
},
{
"id": "IDS_MSG_AUTO_CALIB_START",
"text": "自动校准程序将启动。不要连接任何探针。这可能需要一段时间!"
"text": "自动校准程序将启动。不要连接任何探针。\n这可能需要一段时间!"
},
{
"id": "IDS_MSG_AUTO_CALIB",
@@ -108,7 +108,7 @@
},
{
"id": "IDS_MSG_MAX_CHANNEL_COUNT_WARNING",
"text": "当前模式仅支持最大 {0}\n通道数!"
"text": "当前模式仅支持最大 {0} 通道数!"
},
{
"id": "IDS_MSG_TRI_SET_ISSUE",

View File

@@ -49,7 +49,7 @@
},
{
"id": "IDS_DLG_CHECK_USB_SPEED_ERROR",
"text": "Plug it into a USB 2.0 port will seriously affect its performance.\n Please replug it into a USB 3.0 port."
"text": "Plug the device into a USB 2.0 port will seriously affect its performance.\n Please replug it into a USB 3.0 port."
},
{
"id": "IDS_DLG_CHECK_SESSION_FILE_VERSION_ERROR",

View File

@@ -29,7 +29,7 @@
},
{
"id": "IDS_MSG_AUTO_CALIB_START",
"text": "Auto Calibration program will be started. Don't connect any probes. It can take a while!"
"text": "Auto Calibration program will be started. Don't connect any probes. \nIt can take a while!"
},
{
"id": "IDS_MSG_AUTO_CALIB",
@@ -109,7 +109,7 @@
},
{
"id": "IDS_MSG_MAX_CHANNEL_COUNT_WARNING",
"text": "Current mode only suppport max {0}\nchannels!"
"text": "Current mode only suppport max {0} channels!"
},
{
"id": "IDS_MSG_TRI_SET_ISSUE",